| 1234567891011121314151617181920212223242526272829303132333435363738394041424344454647484950515253545556575859606162636465666768697071727374757677787980 |
- package com.goafanti.order.controller;
- import java.math.BigDecimal;
- import javax.annotation.Resource;
- import org.springframework.web.bind.annotation.RequestMapping;
- import org.springframework.web.bind.annotation.RequestMethod;
- import org.springframework.web.bind.annotation.RestController;
- import com.goafanti.common.bo.Result;
- import com.goafanti.common.controller.CertifyApiController;
- import com.goafanti.common.model.TOrderNew;
- import com.goafanti.order.bo.TOrderNewBo;
- import com.goafanti.order.service.FundManageOrderService;
- import com.goafanti.order.service.OrderBonusService;
- @RestController
- @RequestMapping(value = "/open/api/admin/bonus")
- public class OrderBonusStatisticsApiController extends CertifyApiController {
- @Resource
- private FundManageOrderService fundManageOrderServiceImpl;
- @Resource
- private OrderBonusService orderBonusServiceImpl;
-
- /**
- * 财务专员校对单量
- * @param orderNew
- * @return
- */
- @RequestMapping(value="/proofreading", method = RequestMethod.POST)
- public Result proofreading(TOrderNew orderNew){
- Result res = new Result();
- res.setData(fundManageOrderServiceImpl.updateProofreading(orderNew));
- return res;
- }
-
- /**
- * 营销员奖金统计
- * @param orderNewBo
- * @return
- */
- @RequestMapping(value="/saleBonusStatistics", method = RequestMethod.GET)
- public Result saleBonusStatistics(TOrderNewBo orderNewBo){
- Result res = new Result();
- System.out.println(orderNewBo.getFirstAmount().add(new BigDecimal("-3")));
- //res.setData(fundManageOrderServiceImpl.updateProofreading(orderNew));
- return res;
- }
-
- /**
- * 财务专员发放奖金
- * @param id
- * @return
- */
- @RequestMapping(value="/bonusPayment", method = RequestMethod.POST)
- public Result bonusPayment(String id,String orderNo){
- Result res = new Result();
- Integer i = orderBonusServiceImpl.updateBounsPaymnetStatus(id, orderNo);
- if(i>0){
- res.setData("发放成功!");
- }else{
- res.getError().add(buildError("", "没有校对单量,不能发放"));
- }
- return res;
- }
-
- /**
- *
- * @param orderNewBo
- * @return
- */
- @RequestMapping(value="/technicianBonusStatistics", method = RequestMethod.GET)
- public Result technicianBonusStatistics(TOrderNewBo orderNewBo){
- Result res = new Result();
- return res;
- }
-
- }
|