作者 陈志颖

feat:分红退货单增加批量删除接口

@@ -67,6 +67,19 @@ func (controller *DividendsReturnedOrderController) RemoveDividendsReturnedOrder @@ -67,6 +67,19 @@ func (controller *DividendsReturnedOrderController) RemoveDividendsReturnedOrder
67 controller.Response(data, err) 67 controller.Response(data, err)
68 } 68 }
69 69
  70 +func (controller *DividendsReturnedOrderController) BatchRemoveDividendsReturnedOrder() {
  71 + dividendsReturnedOrderService := service.NewDividendsReturnedOrderService(nil)
  72 + batchRemoveDividendsReturnedOrderCommand := &command.BatchRemoveDividendsReturnedOrderCommand{}
  73 + _ = controller.Unmarshal(batchRemoveDividendsReturnedOrderCommand)
  74 + header := controller.GetRequestHeader(controller.Ctx)
  75 + batchRemoveDividendsReturnedOrderCommand.CompanyId = header.CompanyId
  76 + batchRemoveDividendsReturnedOrderCommand.OrgId = header.OrgId
  77 + batchRemoveDividendsReturnedOrderCommand.UserId = header.UserId
  78 + batchRemoveDividendsReturnedOrderCommand.UserBaseId = header.UserBaseId
  79 + data, err := dividendsReturnedOrderService.BatchRemoveDividendsReturnedOrder(batchRemoveDividendsReturnedOrderCommand)
  80 + controller.Response(data, err)
  81 +}
  82 +
70 func (controller *DividendsReturnedOrderController) SearchDividendsReturnedOrder() { 83 func (controller *DividendsReturnedOrderController) SearchDividendsReturnedOrder() {
71 dividendsReturnedOrderService := service.NewDividendsReturnedOrderService(nil) 84 dividendsReturnedOrderService := service.NewDividendsReturnedOrderService(nil)
72 searchDividendsReturnedOrderQuery := &query.SearchDividendsReturnedOrderQuery{} 85 searchDividendsReturnedOrderQuery := &query.SearchDividendsReturnedOrderQuery{}
@@ -10,6 +10,7 @@ func init() { @@ -10,6 +10,7 @@ func init() {
10 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Put:UpdateDividendsReturnedOrder") 10 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Put:UpdateDividendsReturnedOrder")
11 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Get:GetDividendsReturnedOrder") 11 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Get:GetDividendsReturnedOrder")
12 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Delete:RemoveDividendsReturnedOrder") 12 web.Router("/dividends-returned-orders/:dividendsReturnedOrderId", &controllers.DividendsReturnedOrderController{}, "Delete:RemoveDividendsReturnedOrder")
  13 + web.Router("/dividends-returned-orders/batch-remove", &controllers.DividendsReturnedOrderController{}, "Post:BatchRemoveDividendsReturnedOrder")
13 web.Router("/dividends-returned-orders/search", &controllers.DividendsReturnedOrderController{}, "Post:SearchDividendsReturnedOrder") 14 web.Router("/dividends-returned-orders/search", &controllers.DividendsReturnedOrderController{}, "Post:SearchDividendsReturnedOrder")
14 web.Router("/dividends-returned-orders/import", &controllers.DividendsReturnedOrderController{}, "Post:ImportDividendsReturnedOrder") 15 web.Router("/dividends-returned-orders/import", &controllers.DividendsReturnedOrderController{}, "Post:ImportDividendsReturnedOrder")
15 web.Router("/dividends-returned-orders/", &controllers.DividendsReturnedOrderController{}, "Get:ListDividendsReturnedOrder") 16 web.Router("/dividends-returned-orders/", &controllers.DividendsReturnedOrderController{}, "Get:ListDividendsReturnedOrder")