package com.steerinfo.dil.controller; import com.fasterxml.jackson.annotation.JsonFormat; import com.steerinfo.dil.annotaion.LogAround; import com.steerinfo.dil.feign.AmsFeign; import com.steerinfo.dil.util.BaseRESTfulController; import com.steerinfo.dil.util.ExcelToolUtils; import com.steerinfo.framework.controller.RESTfulResult; import io.swagger.annotations.ApiImplicitParam; import io.swagger.annotations.ApiImplicitParams; import io.swagger.annotations.ApiModelProperty; import io.swagger.annotations.ApiOperation; import org.apache.tools.ant.util.DateUtils; import org.springframework.beans.factory.annotation.Autowired; import org.springframework.format.annotation.DateTimeFormat; import org.springframework.web.bind.annotation.*; import org.springframework.web.multipart.MultipartFile; import java.math.BigDecimal; import java.text.ParseException; import java.text.SimpleDateFormat; import java.util.Date; import java.util.HashMap; import java.util.List; import java.util.Map; /** * @author luobang * @create 2021-09-17 14:10 */ @RestController @RequestMapping("${api.version}/ams") public class AMScontroller extends BaseRESTfulController { @Autowired AmsFeign amsFeign; @ApiOperation(value = "展示采购订单详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getPurchaseOrderList") Map getPurchaseOrderList(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getPurchaseOrderList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "同步采购订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/purchaseOrderSync") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"采购订单"}) public Map purchaseOrderSync(@RequestBody(required = false) Map map) { return amsFeign.purchaseOrderSync(map); } @ApiOperation(value = "新增采购订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/purchaseOrderAdd") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"采购订单"}) public Map purchaseOrderAdd(@RequestBody(required = false) Map map) { return amsFeign.purchaseOrderAdd(map); } @ApiOperation(value = "修改采购订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/purchaseOrderUpdate") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"采购订单"}) public Map purchaseOrderUpdate(@RequestBody(required = false) Map map) { return amsFeign.purchaseOrderUpdate(map); } @ApiOperation(value = "删除采购订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/purchaseOrderDelete") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"采购订单"}) public Map purchaseOrderDelete(@RequestBody(required = false) Map map) { return amsFeign.purchaseOrderDelete(map); } @ApiOperation(value = "采购需求新增接口", notes = "采购需求新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchaseRequirementAdd") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"采购需求"}) public Map purchaseRequirementAdd(@RequestBody(required = false) Map map) throws ParseException { return amsFeign.purchaseRequirementAdd(map); } @ApiOperation(value = "同步生产调拨订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/productionOrderSync") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"采购订单"}) public Map productionOrderSync(@RequestBody(required = false) Map map) { return amsFeign.productionOrderSync(map); } @ApiOperation(value = "生产需求新增接口", notes = "生产需求新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionRequirementAdd") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"采购需求"}) public Map productionRequirementAdd(@RequestBody(required = false) Map map) throws ParseException { map.put("insertUsername", map.get("userName").toString()); if (map.containsKey("requirementStartTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementStartTime = simpleDateFormat.parse(map.get("requirementStartTime").toString()); map.put("requirementStartTime", requirementStartTime); } if (map.containsKey("requirementEndTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementEndTime = simpleDateFormat.parse(map.get("requirementEndTime").toString()); map.put("requirementEndTime", requirementEndTime); } if (map.containsKey("dueTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date dueTime = simpleDateFormat.parse(map.get("dueTime").toString()); map.put("dueTime", dueTime); } return amsFeign.productionRequirementAdd(map); } @ApiOperation(value = "采购需求修改接口", notes = "采购需求修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchaseRequirementUpdate") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"采购需求"}) public Map purchaseRequirementUpdate(@RequestBody(required = false) Map map) { return amsFeign.purchaseRequirementUpdate(map); } @ApiOperation(value = "采购需求修改接口", notes = "采购需求修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchaseRequirementReturn") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"采购需求"}) public Map purchaseRequirementReturn(@RequestBody(required = false) Map map) { return amsFeign.purchaseRequirementReturn(map); } @ApiOperation(value = "采购需求修改状态接口", notes = "采购需求修改状态接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchaseRequirementChange") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"采购需求"}) public Map purchaseRequirementChange(@RequestBody(required = false) Map map) { return amsFeign.purchaseRequirementChange(map); } @ApiOperation(value = "生产需求修改接口", notes = "生产需求修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionStatusUpdate") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map productionStatusUpdate(@RequestBody(required = false) Map map) { return amsFeign.productionStatusUpdate(map); } @ApiOperation(value = "生产需求批量修改接口", notes = "生产需求批量修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) @PostMapping(value = "/productionRequirementBatchUpdate") public Map productionRequirementBatchUpdate(@RequestBody(required = false) Map map) throws ParseException { map.put("insertUsername", map.get("userName").toString()); if (map.containsKey("requirementStartTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementStartTime = simpleDateFormat.parse(map.get("requirementStartTime").toString()); map.put("requirementStartTime", requirementStartTime); } if (map.containsKey("requirementEndTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementEndTime = simpleDateFormat.parse(map.get("requirementEndTime").toString()); map.put("requirementEndTime", requirementEndTime); } if (map.containsKey("dueTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date dueTime = simpleDateFormat.parse(map.get("dueTime").toString()); map.put("dueTime", dueTime); } return amsFeign.productionRequirementBatchUpdate(map); } @ApiOperation(value = "生产需求状态修改接口", notes = "生产需求状态修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionRequirementChange") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map productionRequirementChange(@RequestBody(required = false) Map map) { return amsFeign.productionRequirementChange(map); } @ApiOperation(value = "生产需求状态修改接口批量", notes = "生产需求状态修改接口批量") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionRequirementChangeList") public Map productionRequirementChangeList(@RequestBody(required = false) Map map) { return amsFeign.productionRequirementChangeList(map); } @ApiOperation(value = "展示生产需求详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getproductionRequirementList") Map getproductionRequirementList(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getproductionRequirementList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "展示生产需求详情-大宗") @PostMapping(value = "/getProductionRequirementListDz") Map getProductionRequirementListDz(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getProductionRequirementListDz(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "修改通知单环保状态") @PostMapping(value = "/updateEnvironmentStatus") @LogAround(foreignKeys = {"transRequirementId"},foreignKeyTypes = {"调拨通知单"},description = "修改通知单环保状态") Map updateEnvironmentStatus(@RequestBody(required = false) Map mapValue) { return amsFeign.updateEnvironmentStatus(mapValue); } @ApiOperation(value = "修改通知单环保状态") @PostMapping(value = "/transProductRequirementFromDz") @LogAround(foreignKeys = {"transRequirementId"},foreignKeyTypes = {"调拨通知单"},description = "修改通知单环保状态") Map transProductRequirementFromDz(@RequestBody(required = false) Map mapValue) { return amsFeign.transProductRequirementFromDz(mapValue); } @ApiOperation(value = "展示采购需求详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getPurchaseRequirementList") Map getPurchaseRequirementList(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getPurchaseRequirementList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "展示采购计划详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getPurchasePlanList") Map getPurchasePlanList(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getPurchasePlanList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "采购计划新增接口", notes = "采购计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchasePlanAdd") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"采购计划"}) public Map purchasePlanAdd(@RequestBody(required = false) Map map) { return amsFeign.purchasePlanAdd(map); } @ApiOperation(value = "采购计划修改接口", notes = "采购计划修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchasePlanUpdate") @LogAround(foreignKeys = {"transPlanId"},foreignKeyTypes = {"采购计划"}) public Map purchasePlanUpdate(@RequestBody(required = false) Map map) { return amsFeign.purchasePlanUpdate(map); } @ApiOperation(value = "采购计划修改状态接口", notes = "采购计划修改状态接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchasePlanChange") @LogAround(foreignKeys = {"transPlanId"},foreignKeyTypes = {"采购计划"}) public Map purchasePlanChange(@RequestBody(required = false) Map map) { return amsFeign.purchasePlanChange(map); } @ApiOperation(value = "采购火运计划删除接口", notes = "采购火运计划删除接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/purchaseTrainPlanDelete") @LogAround(foreignKeys = {"transPlanId"},foreignKeyTypes = {"采购计划"}) public Map purchaseTrainPlanDelete(@RequestBody(required = false) Map map) { return amsFeign.purchaseTrainPlanDelete(map); } @ApiOperation(value = "采购火运计划批量删除接口", notes = "采购火运计划批量删除接口") @PostMapping(value = "/purchaseTrainPlanBatchDel") @LogAround(foreignKeys = {"transPlanId"},foreignKeyTypes = {"采购计划"}) public Map purchaseTrainPlanBatchDel(@RequestBody(required = false) Map map) { return amsFeign.purchaseTrainPlanBatchDel(map); } @ApiOperation(value="同步销售订单") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/saleOrderSync") @LogAround(foreignKeys = {"orderId"}, foreignKeyTypes = {"销售订单"}) public Map saleOrderSync(@RequestBody(required = false) Map map) { return amsFeign.saleOrderSync(map); } @ApiOperation(value = "承运合同") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getAmsTransPriceList") public Map getAmsTransPriceList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize) { return amsFeign.list(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "新增承运合同") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @LogAround(foreignKeys = {"priceId"}, foreignKeyTypes = {"承运合同"}) @PostMapping("/addAmsTransPrice") public Map insertTransPrice(@RequestBody(required = false) Map map) throws ParseException { if (map.containsKey("priceDate")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date priceDate = simpleDateFormat.parse(map.get("priceDate").toString()); map.put("priceDate", priceDate); } return amsFeign.addAmsTransPrice(map); } @ApiOperation(value = "修改承运合同") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PutMapping(value = "/{id}") @LogAround(foreignKeys = {"priceId"}, foreignKeyTypes = {"承运合同"}) public Map purchaseOrderUpdate(@PathVariable BigDecimal id, @RequestBody(required = false) Map map) { map.put("updateUsername", map.get("userName").toString()); return amsFeign.update(id, map); } @ApiOperation(value = "承运合同逻辑删除") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PutMapping(value = "/logicdelete") @LogAround(foreignKeys = {"priceId"}, foreignKeyTypes = {"承运合同"}) public Map purchaseOrderLogicDelete(@RequestBody(required = false) Map map) { return amsFeign.logicdelete(map); } @ApiOperation(value="同步NC销售合同") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PostMapping(value = "/saleContractSync") @LogAround(foreignKeys = {"orderId"},foreignKeyTypes = {"销售合同"}) public Map saleContractSync(@RequestBody(required = false) HashMap map) { return amsFeign.saleContractSync(map); } //工资合同 @ApiOperation(value = "工资合同") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getSalaryContrac") public Map getAmsSalaryContracList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize) { return amsFeign.getAmsSalaryContracList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "新增工资合同") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @LogAround(foreignKeys = {"contractId"}, foreignKeyTypes = {"工资合同"}) @PostMapping("/insertSalaryContrac") public Map insertAmsSalaryContrac(@RequestBody(required = false) Map map) throws ParseException { if (!map.isEmpty()) { if (!map.get("contractSignDate").toString().isEmpty()) { SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd"); Date contractSignDate = simpleDateFormat.parse(map.get("contractSignDate").toString()); map.put("contractSignDate", contractSignDate); } } map.put("insertUsername", map.get("userName").toString()); return amsFeign.insertAmsSalaryContrac(map); } @ApiOperation(value = "修改工资合同") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PutMapping(value = "/updateSalaryContrac/{id}") @LogAround(foreignKeys = {"contractId"}, foreignKeyTypes = {"工资合同"}) public Map updateAmsSalaryContrac(@PathVariable BigDecimal id, @RequestBody(required = false) Map map) { map.put("updateUsername", map.get("userName").toString()); return amsFeign.updateAmsSalaryContrac(id, map); } @ApiOperation(value = "工资合同逻辑删除") @ApiImplicitParam(name = "map", value = "JSON格式数据", required = true, dataType = "Map") @PutMapping(value = "/SalaryContraclogicdelete") @LogAround(foreignKeys = {"contractId"}, foreignKeyTypes = {"工资合同"}) public Map logicdeleteAmsSaalryContrac(@RequestBody(required = false) Map map) { return amsFeign.logicdeleteAmsSaalryContrac(map); } @ApiOperation(value = "销售需求新增接口", notes = "销售需求新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/saleAdd") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"销售需求"}) public Map saleAdd(@RequestBody(required = false) Map map) { return amsFeign.saleAdd(map); } @PostMapping(value = "/readExcel") public RESTfulResult readExcel(MultipartFile file,@RequestParam("userCode") String userCode) { return amsFeign.readExcel(file, userCode); } @ApiOperation(value="展示销售需求") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/selectDlivDirNo") Map selectDlivDirNo(@RequestBody(required=false) HashMap mapValue, Integer apiId, Integer pageNum, Integer pageSize){ return amsFeign.selectDlivDirNo(mapValue == null ? new HashMap<>() : mapValue,apiId,pageNum,pageSize); } @ApiOperation(value = "修改发货单状态", notes = "修改发货单状态") @ApiImplicitParam(name = "params", value = "修改内容", required = false, dataType = "ArrayList>") @PostMapping(value = "/updateOrder") public RESTfulResult udpateOrder(@RequestBody(required = false) HashMap parmas) { return amsFeign.udpateOrder(parmas); } @ApiOperation(value = "退货", notes = "根据填写的数据将发货单进行退货") @ApiImplicitParam(name = "params", value = "查询内容", required = false, dataType = "HashMap") @PostMapping(value = "/returnGoods") public RESTfulResult returnGoods(@RequestBody(required = false) HashMap params) { return amsFeign.returnGoods(params); } @ApiOperation(value = "撤销退货", notes = "根据发货单号将发货单的退货记录清除") @ApiImplicitParam(name = "id", value = "查询内容", required = false, dataType = "String") @PostMapping(value = "revokeReturnGoods") public RESTfulResult revokeReturnGoods(@RequestBody Map params) { return amsFeign.revokeReturnGoods(params); } @ApiOperation(value = "查询发货单第几次退库", notes = "查询发货单第几次退库") @ApiImplicitParam(name = "dlivDirno", value = "查询内容", required = false, dataType = "String") @GetMapping(value = "/getcut/{dlivDirno}") public RESTfulResult getcut(@PathVariable String dlivDirno) { return amsFeign.getcut(dlivDirno); } @ApiOperation(value = "修改发货单信息", notes = "根据填写的数据将发货单进行修改") @ApiImplicitParam(name = "params", value = "查询内容", required = false, dataType = "HashMap") @PostMapping(value = "/editButton") public RESTfulResult editButton(@RequestBody(required = false) HashMap params) { return amsFeign.editButton(params); } @ApiOperation(value = "删除发货单信息", notes = "根据填写的数据将发货单进行删除") @ApiImplicitParam(name = "params", value = "查询内容", required = false, dataType = "HashMap") @PostMapping(value = "/deleteDlivDirno") public RESTfulResult deleteDlivDirno(@RequestBody(required = false) HashMap params) { return amsFeign.deleteDlivDirno(params); } @ApiOperation(value="展示销售合同") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/selectSaleContractPage") Map selectSaleContractPage(@RequestBody(required=false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize){ return amsFeign.selectSaleContractPage(mapValue == null ? new HashMap<>() : mapValue,apiId,pageNum,pageSize); } @ApiOperation(value="展示销售订单") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/selectSaleOrderPage") Map selectSaleOrderPage(@RequestBody(required=false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize){ return amsFeign.selectSaleOrderPage(mapValue == null ? new HashMap<>() : mapValue,apiId,pageNum,pageSize); } @ApiOperation(value = "生产计划新增接口", notes = "生产计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionPlanAdd") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"生产计划"}) public Map productionPlanAdd(@RequestBody(required = false) Map map) { return amsFeign.productionPlanAdd(map); } @ApiOperation(value = "生产计划批量新增接口", notes = "生产计划批量新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionPlanAddList") public Map productionPlanAddList(@RequestBody Map map) { return amsFeign.productionPlanAddList(map); } @ApiOperation(value = "展示生产订单详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getproductionPlanList") Map getproductionPlanList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getproductionPlanList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "生产计划新增接口", notes = "生产计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionPlanChange") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"生产计划"}) public Map productionPlanChange(@RequestBody(required = false) Map map) { return amsFeign.productionPlanChange(map); } @ApiOperation(value = "生产计划新增接口", notes = "生产计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PutMapping(value = "/productionPlanlogicdelete") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"生产计划"}) public Map productionPlanlogicdelete(@RequestBody(required = false) Map map) { return amsFeign.productionPlanlogicdelete(map); } @ApiOperation(value = "生产需求逻辑删除", notes = "生产需求逻辑删除") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/getProductiveRequirementDelete") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map getProductiveRequirementDelete(@RequestBody(required = false) Map map) { return amsFeign.getProductiveRequirementDelete(map); } @ApiOperation(value = "需求计划新增接口", notes = "需求计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/salePlanAdd") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"需求计划"}) public Map salePlanAdd(@RequestBody(required = false) Map map) { return amsFeign.salePlanAdd(map); } @ApiOperation(value = "需求计划修改接口", notes = "需求计划修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/salePlanUpdate") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"需求计划"}) public Map salePlanUpdate(@RequestBody(required = false) Map map) { return amsFeign.salePlanUpdate(map); } @ApiOperation(value = "需求计划新增接口", notes = "需求计划新增接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/salePlanDelete") @LogAround(foreignKeys = {"transPlanId"}, foreignKeyTypes = {"需求计划"}) public Map salePlanDelete(@RequestBody(required = false) Map map) { return amsFeign.salePlanDelete(map); } @ApiOperation(value = "展示销售计划详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getSalePlanList") Map getSalePlanList(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getSalePlanList(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation(value = "发运单绑定接口", notes = "发运单绑定接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/bindSale") public RESTfulResult bindSale(@RequestBody(required = false) Map map) { return amsFeign.bindSale(map); } @ApiOperation(value = "获取物资数据", notes = "获取物资数据") @ApiImplicitParams({ @ApiImplicitParam(name = "id", value = "物料编码", required = true, dataType = "String") }) @PostMapping(value = "/getMaterial") public RESTfulResult bindSale(@RequestParam String prodCode, Integer apiId, Integer pageNum, Integer pageSize) { return amsFeign.getMaterial(prodCode, apiId, pageNum, pageSize); } @ApiOperation(value = "批量生产需求状态修改接口", notes = "生产需求状态修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/productionRequirementChanges/{id}") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map productionRequirementChanges(@PathVariable String id,@RequestBody(required = false) Map map) { return amsFeign.productionRequirementChanges(id,map); } @ApiOperation(value = "查询派单时需要的发运单信息", notes = "查询派单时需要的发运单信息") @ApiImplicitParams({ @ApiImplicitParam(name = "planChildId", value = "json格式具体参数", required = true, dataType = "Integer") }) @PostMapping(value = "/selectPlanChildById/{planChildId}") public RESTfulResult selectPlanChildById(@PathVariable("planChildId") String planChildId) { return amsFeign.selectPlanChildById(planChildId); } @ApiOperation(value = "展示生产订单审批详情") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getproductionRequirementworkflowList") Map getproductionRequirementworkflowList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getproductionRequirementworkflowList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value="展示销售合同") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getProductPlanList") Map getProductPlanList(@RequestBody(required=false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize){ return amsFeign.getProductPlanList(mapValue == null ? new HashMap<>() : mapValue,apiId,pageNum,pageSize); } @ApiOperation("停用计划") @PostMapping("/deactivatedPlan") Map deactivatedPlan(@RequestBody Map map) { return amsFeign.deactivatedPlan(map); } @ApiOperation("需求审批详情") @PostMapping("/requirementApproveDetails") Map requirementApproveDetails(@RequestBody Map map) { return amsFeign.requirementApproveDetails(map); } @ApiOperation(value = "展示订单执行情况") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getOrderStatus") RESTfulResult getOrderStatus(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getOrderStatus(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "展示调拨订单信息") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getProductOrderList") Map getProductOrderList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getProductOrderList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "查询发运通知单修改需要内容", notes = "查询发运通知单修改需要内容") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/getUpdateDlivDirno") public RESTfulResult getUpdateDlivDirno(@RequestBody Map map) { return amsFeign.getUpdateDlivDirno(map); } @ApiOperation(value = "发运通知单修改", notes = "发运通知单修改") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/saleUpdate") public RESTfulResult saleUpdate(@RequestBody Map map) { return amsFeign.saleUpdate(map); } @ApiOperation(value = "批量新增发运通知单", notes = "批量新增发运通知单") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/saleAddPl") public RESTfulResult saleAddPl(@RequestBody Map map) { return amsFeign.saleAddPl(map); } @ApiOperation(value = "打印获取退货重量", notes = "打印获取退货重量") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/getMoney/{id}") public RESTfulResult getMoney(@PathVariable String id) { return amsFeign.getprintstr(id); } @ApiOperation(value = "查询临时货位") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/selectcar") RESTfulResult selectcar(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.selectcar(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "查询临时货位详细信息") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/selectcarList") RESTfulResult selectcarList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.selectcarList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation("上传凭证") @PostMapping("/transPlanupload") Map transPlanupload(@RequestBody Map map) { return amsFeign.transPlanupload(map); } @ApiOperation("新增生产需求编号") @PostMapping("/getSerialNumber") Map addSerialNumber(@RequestBody Map map) { return amsFeign.getSerialNumber(map); } @ApiOperation("批量审批运输单价") @PostMapping("approvePriceData") Map approvePriceData(@RequestBody Map map) {return amsFeign.approvePriceData(map);} @ApiOperation("匹配运输单价") @PostMapping("/selectUnitPrice") Map selectUnitPrice(@RequestBody Map map) {return amsFeign.selectUnitPrice(map);} @ApiOperation("不分页查询派车证") @PostMapping(value = "/amsScheduleDispatchNoPage") public Map amsScheduleDispatchNoPage(@RequestBody HashMap parmas){ return amsFeign.amsScheduleDispatchNoPage(parmas); } @ApiOperation("查询司磅地点") @PostMapping("/getSBDDList") RESTfulResult getMaterialOperation(@RequestBody Map map) {return amsFeign.getSBDDList(map);} @ApiOperation("获取提货单打印备注") @PostMapping("/selectBalanceRemark") RESTfulResult selectBalanceRemark(@RequestBody Map map) { return amsFeign.selectBalanceRemark(map); } @ApiOperation("获取退货打印备注") @PostMapping("/selectReturnGoodsRemark") RESTfulResult selectReturnGoodsRemark(@RequestBody Map map) { return amsFeign.selectReturnGoodsRemark(map); } @ApiOperation("销售物流单停用或启用") @PostMapping("/deactivateOrEnable") RESTfulResult deactivateOrEnable(@RequestBody Map map) { return amsFeign.deactivateOrEnable(map); } @ApiOperation("销售物流单停用或启用") @PostMapping("/updateBalancePl") RESTfulResult updateBalancePl(@RequestBody Map map) { return amsFeign.updateBalancePl(map); } @ApiOperation("重导WMS") @PostMapping("/addWMS") RESTfulResult addWMS(@RequestBody Map map) { return amsFeign.addWMS(map); } @ApiOperation("固定需求新增") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @LogAround(foreignKeys = {"fixedNeedsId"}, foreignKeyTypes = {"固定生产需求"}) @PostMapping("/fixedNeedsAdd") RESTfulResult fixedNeedsAdd(@RequestBody(required = false) Map map) throws ParseException { map.put("insertUsername", map.get("userName").toString()); if (map.containsKey("requirementStartTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementStartTime = simpleDateFormat.parse(map.get("requirementStartTime").toString()); map.put("requirementStartTime", requirementStartTime); } if (map.containsKey("requirementEndTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementEndTime = simpleDateFormat.parse(map.get("requirementEndTime").toString()); map.put("requirementEndTime", requirementEndTime); } if (map.containsKey("dueTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date dueTime = simpleDateFormat.parse(map.get("dueTime").toString()); map.put("dueTime", dueTime); } return amsFeign.fixedNeedsAdd(map);}; @ApiOperation(value = "查询固定需求") @ApiImplicitParams({ @ApiImplicitParam(name = "mapValue", value = "参数", required = false, dataType = "map"), @ApiImplicitParam(name = "apiId()", value = "动态表头", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageNum", value = "页码", required = false, dataType = "Integer"), @ApiImplicitParam(name = "pageSize", value = "页", required = false, dataType = "Integer"), }) @PostMapping(value = "/getfixdNeedsList") RESTfulResult getfixdNeedsList(@RequestBody(required = false) Map map, Integer apiId, Integer pageNum, Integer pageSize ) { return amsFeign.getfixdNeedsList(map == null ? new HashMap<>() : map, apiId, pageNum, pageSize); } @ApiOperation(value = "生产固定需求批量修改接口", notes = "生产固定需求批量修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) @PostMapping(value = "/fixedNeedsUpdate") public Map fixedNeedsUpdate(@RequestBody(required = false) Map map) throws ParseException { map.put("insertUsername", map.get("userName").toString()); if (map.containsKey("requirementStartTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementStartTime = simpleDateFormat.parse(map.get("requirementStartTime").toString()); map.put("requirementStartTime", requirementStartTime); } if (map.containsKey("requirementEndTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date requirementEndTime = simpleDateFormat.parse(map.get("requirementEndTime").toString()); map.put("requirementEndTime", requirementEndTime); } if (map.containsKey("dueTime")){ SimpleDateFormat simpleDateFormat = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss"); Date dueTime = simpleDateFormat.parse(map.get("dueTime").toString()); map.put("dueTime", dueTime); } return amsFeign.fixedNeedsUpdate(map); } @ApiOperation(value = "生产固定需求逻辑删除", notes = "生产固定需求逻辑删除") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/getfixedNeedsDelete") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map getfixedNeedsDelete(@RequestBody(required = false) Map map) { return amsFeign.getfixedNeedsDelete(map); } @ApiOperation(value = "批量生产需求状态修改接口", notes = "生产需求状态修改接口") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/fixedNeedsChangeList") @LogAround(foreignKeys = {"transRequirementId"}, foreignKeyTypes = {"生产需求"}) public Map fixedNeedsChangeList(@RequestBody(required = false) Map map) { return amsFeign.fixedNeedsChangeList(map); } @ApiOperation(value = "导入固定需求", notes = "导入固定需求") @ApiImplicitParams({ @ApiImplicitParam(name = "map", value = "json格式具体参数", required = true, dataType = "Map") }) @PostMapping(value = "/readFixedNeedsExcel") public Map readFixedNeedsExcel(MultipartFile file) throws Exception { return amsFeign.readFixedNeedsExcel(file); } @ApiOperation("导入") @PostMapping("/importTransPrice") public Map importTransPrice(@RequestBody MultipartFile file, String userId, String userName) throws Exception { Map map = new HashMap<>(); //获取Excel中包含的对象数组 List> list = ExcelToolUtils.getExcelList(file, 0); map.put("list", list); map.put("setList",list); map.put("userId",userId); map.put("userName",userName); return amsFeign.importTransPrice(map); } @ApiOperation("派车") @PostMapping("/dispatch") public Map dispatch() throws Exception { return amsFeign.dispatch(); } @ApiOperation("强制修改") @PostMapping("/forcedModification") public Map forcedModification(@RequestBody Map params) throws Exception { return amsFeign.forcedModification(params); } @ApiOperation("新增绑定关系") @PostMapping("/addAmsFixedBindRequirement") public Map addAmsFixedBindRequirement(@RequestBody Map params) throws Exception { return amsFeign.addAmsFixedBindRequirement(params); } @ApiOperation("请求撤回需求") @PostMapping("/withdrawRequirement") public Map withdrawRequirement(@RequestBody Map params) throws Exception { return amsFeign.withdrawRequirement(params); } @ApiOperation(value = "展示生产需求详情-绑定") @PostMapping(value = "/getProductionRequirementListBind") Map getProductionRequirementListBind(@RequestBody(required = false) Map mapValue, Integer apiId, Integer pageNum, Integer pageSize) { return amsFeign.getProductionRequirementListBind(mapValue == null ? new HashMap<>() : mapValue, apiId, pageNum, pageSize); } @ApiOperation("修改绑定需求") @PostMapping("/updateBindRequirement") public Map updateBindRequirement(@RequestBody Map params) throws Exception { return amsFeign.updateBindRequirement(params); } @ApiOperation("汽运传火运清洁能源") @PostMapping("/qjnyChange") public Map qjnyChange(@RequestBody Map params) throws Exception { return amsFeign.qjnyChange(params); } }