修改过期时间,以及修改套餐已用量
Some checks failed
构建并部署到测试环境(无 SSH) / build-and-deploy (push) Has been cancelled

This commit is contained in:
Break
2026-06-12 10:41:24 +08:00
parent c437593a8c
commit 016e7bee79
8 changed files with 501 additions and 85 deletions

View File

@@ -56,6 +56,24 @@ func registerAssetRoutes(router fiber.Router, handler *admin.AssetHandler, walle
Auth: true,
})
Register(assets, doc, groupPath, "PATCH", "/:identifier/packages/:package_usage_id/expires-at", handler.UpdatePackageExpiresAt, RouteSpec{
Summary: "修改资产套餐过期时间",
Description: "修改指定资产下某条套餐使用记录的过期时间。仅账号ID为2的账号可调用。",
Tags: []string{"资产管理"},
Input: new(dto.UpdateAssetPackageExpiresAtRequest),
Output: new(dto.AssetPackageResponse),
Auth: true,
})
Register(assets, doc, groupPath, "PATCH", "/:identifier/packages/:package_usage_id/used-data", handler.UpdatePackageUsage, RouteSpec{
Summary: "修改资产套餐已用量",
Description: "修改指定资产下某条套餐使用记录的真实已用量(MB)。仅账号ID为2的账号可调用。",
Tags: []string{"资产管理"},
Input: new(dto.UpdateAssetPackageUsageRequest),
Output: new(dto.AssetPackageResponse),
Auth: true,
})
Register(assets, doc, groupPath, "POST", "/:identifier/stop", handler.Stop, RouteSpec{
Summary: "停机",
Description: "设备批量停机设备下所有已实名卡;单卡手动停机。",