完善配送点合同附件管理

This commit is contained in:
czl231
2026-08-23 01:08:25 +08:00
parent 4334719051
commit bebf9b52b7
17 changed files with 740 additions and 13 deletions

View File

@@ -63,7 +63,10 @@ func RegisterDelivery(serviceKey string, engine *gin.Engine) {
contract := protected.Group("/gasorder_contract")
contract.GET("", deliverylogic.ListContract)
contract.POST("", deliverylogic.CreateContract)
contract.POST("/attachment/upload", deliverylogic.UploadContractAttachment)
contract.POST("/attachment/cleanup", deliverylogic.CleanupContractAttachment)
contract.GET("/:identity", deliverylogic.GetContract)
contract.GET("/:identity/attachment", deliverylogic.ServeContractAttachment)
contract.PUT("/:identity", deliverylogic.UpdateContract)
contract.POST("/:identity/activate", deliverylogic.ActivateContract)
contract.POST("/:identity/renew", deliverylogic.RenewContract)

View File

@@ -47,6 +47,9 @@ func TestDeliveryOrderActionBoundary(t *testing.T) {
"GET /heqi/delivery/v1/wallet_recharge/:identity",
"GET /heqi/delivery/v1/staff_account/:identity/avatar",
"GET /heqi/delivery/v1/user_account/:identity/avatar",
"POST /heqi/delivery/v1/gasorder_contract/attachment/upload",
"POST /heqi/delivery/v1/gasorder_contract/attachment/cleanup",
"GET /heqi/delivery/v1/gasorder_contract/:identity/attachment",
} {
if !routes[required] {
t.Fatalf("missing confirmed delivery action %s", required)