作者 陈志颖

fix:导入接口增加版本号

... ... @@ -1074,7 +1074,7 @@ func (c *OrderInfoController) ImportOrderFromExcel() {
// 产品数量校验
productNumberError := make([]interface{}, 0)
// 批量创建订单命令集
// 批量创建订单命令集和产品数量校验
var createOrderCommands []*orderCmd.CreateOrderCommand
for _, orderCommand := range orderCommands {
if len(orderCommand.Goods) > 50 { // 产品数量校验
... ...
... ... @@ -6,10 +6,6 @@ import (
)
func init() {
// 导入相关
beego.Router("/fileImportTemplate", &controllers.OrderInfoController{}, "POST:DownloadTemplate") // 下载导入模板
beego.Router("/fileImport", &controllers.OrderInfoController{}, "POST:ImportOrderFromExcel") // 导入订单数据
adminRouter := beego.NewNamespace("/v1",
beego.NSNamespace("/auth",
beego.NSRouter("/login", &controllers.AdminLoginController{}, "POST:Login"),
... ... @@ -45,6 +41,8 @@ func init() {
beego.NSRouter("/actual/del", &controllers.OrderInfoController{}, "POST:RemoveOrderReal"), // 删除实际订单
beego.NSRouter("/actual/update", &controllers.OrderInfoController{}, "POST:UpdateOrderReal"), // 新增实际订单
beego.NSRouter("/actual/close", &controllers.OrderInfoController{}, "POST:OrderDisable"),
beego.NSRouter("/fileImportTemplate", &controllers.OrderInfoController{}, "POST:DownloadTemplate"), // 下载导入模板
beego.NSRouter("/fileImport", &controllers.OrderInfoController{}, "POST:ImportOrderFromExcel"), // 导入订单数据
),
beego.NSNamespace("/common",
beego.NSRouter("/partner", &controllers.CommonController{}, "POST:GetPartnerList"),
... ...