fix(pl): show recharge type fuel as 油卡 in API labels.
Co-authored-by: Cursor <cursoragent@cursor.com>
This commit is contained in:
1 parent
658bd3df5c
commit
a3a32ccaaa
6 files changed
+10
-10
No files matched your search
@@ -1,4 +1,4 @@
|
|||||||
"""车辆 ETC/加油充值 API"""
|
"""车辆 ETC/油卡充值 API"""
|
||||||
from datetime import date, datetime
|
from datetime import date, datetime
|
||||||
from typing import Any, List, Optional
|
from typing import Any, List, Optional
|
||||||
|
|
||||||
@@ -31,10 +31,10 @@ from app.schemas.pl.vehicle_recharge import (
|
|||||||
)
|
)
|
||||||
from app.services import pl_vehicle_recharge_service as svc
|
from app.services import pl_vehicle_recharge_service as svc
|
||||||
|
|
||||||
apply_router = APIRouter(prefix="/vehicle-recharge-apply", tags=["运输计划-ETC加油申请"])
|
apply_router = APIRouter(prefix="/vehicle-recharge-apply", tags=["运输计划-ETC油卡申请"])
|
||||||
record_router = APIRouter(prefix="/vehicle-recharge-record", tags=["运输计划-ETC加油发放"])
|
record_router = APIRouter(prefix="/vehicle-recharge-record", tags=["运输计划-ETC油卡发放"])
|
||||||
|
|
||||||
RECHARGE_TYPE_LABELS = {"etc": "ETC", "fuel": "加油"}
|
RECHARGE_TYPE_LABELS = {"etc": "ETC", "fuel": "油卡"}
|
||||||
RECHARGE_APPLY_STATUS_LABELS = {
|
RECHARGE_APPLY_STATUS_LABELS = {
|
||||||
"draft": "草稿",
|
"draft": "草稿",
|
||||||
"pending": "待发放",
|
"pending": "待发放",
|
||||||
|
|||||||
@@ -17,7 +17,7 @@ from app.schemas.pl.vehicle_recharge import (
|
|||||||
from app.services import pl_vehicle_recharge_approval_service as approval_svc
|
from app.services import pl_vehicle_recharge_approval_service as approval_svc
|
||||||
|
|
||||||
approval_router = APIRouter(
|
approval_router = APIRouter(
|
||||||
prefix="/vehicle-recharge-approval", tags=["运输计划-ETC加油充值审批"]
|
prefix="/vehicle-recharge-approval", tags=["运输计划-ETC油卡充值审批"]
|
||||||
)
|
)
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -21,7 +21,7 @@ _DEFAULT_WORKFLOWS = {
|
|||||||
"remark": "报销申请默认审批流程",
|
"remark": "报销申请默认审批流程",
|
||||||
},
|
},
|
||||||
"vehicle_recharge": {
|
"vehicle_recharge": {
|
||||||
"wf_name": "ETC/加油充值审批流程",
|
"wf_name": "ETC/油卡充值审批流程",
|
||||||
"remark": "充值申请默认审批流程",
|
"remark": "充值申请默认审批流程",
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
"""车辆 ETC/加油充值业务逻辑"""
|
"""车辆 ETC/油卡充值业务逻辑"""
|
||||||
from __future__ import annotations
|
from __future__ import annotations
|
||||||
|
|
||||||
from datetime import date, datetime
|
from datetime import date, datetime
|
||||||
@@ -456,7 +456,7 @@ def _resolve_apply_for_record(
|
|||||||
if apply.status == "in_approval":
|
if apply.status == "in_approval":
|
||||||
raise HTTPException(
|
raise HTTPException(
|
||||||
status_code=400,
|
status_code=400,
|
||||||
detail="审批中的申请请在「ETC/加油充值审批」中完成发放登记",
|
detail="审批中的申请请在「ETC/油卡充值审批」中完成发放登记",
|
||||||
)
|
)
|
||||||
if apply.status != "pending":
|
if apply.status != "pending":
|
||||||
raise HTTPException(status_code=400, detail="仅待发放申请可关联")
|
raise HTTPException(status_code=400, detail="仅待发放申请可关联")
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
"""首页「ETC/加油充值发放管理」角标统计全部待发放申请(ETC + 加油)。"""
|
"""首页「ETC/油卡充值发放管理」角标统计全部待发放申请(ETC + 油卡)。"""
|
||||||
from datetime import date
|
from datetime import date
|
||||||
|
|
||||||
from sqlalchemy import create_engine
|
from sqlalchemy import create_engine
|
||||||
|
|||||||
@@ -1,4 +1,4 @@
|
|||||||
"""首页「ETC/加油充值审批」角标:统计当前用户待审批单据数。"""
|
"""首页「ETC/油卡充值审批」角标:统计当前用户待审批单据数。"""
|
||||||
from datetime import date
|
from datetime import date
|
||||||
from typing import Optional
|
from typing import Optional
|
||||||
|
|
||||||
|
|||||||
Reference in new issue
Block a user