作者 唐旭辉

Merge branch 'dev' of http://gitlab.fjmaimaimai.com/mmm-go/partnermg into dev

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