123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334 |
- package com.steerinfo.dil.controller;
- import com.steerinfo.dil.feign.BmsshipFeign;
- import com.steerinfo.dil.feign.BmstrainFeign;
- import com.steerinfo.dil.feign.BmstruckFeign;
- import com.steerinfo.dil.util.BaseRESTfulController;
- import com.steerinfo.framework.controller.RESTfulResult;
- import io.swagger.annotations.ApiOperation;
- import org.springframework.beans.factory.annotation.Autowired;
- import org.springframework.web.bind.annotation.*;
- import java.math.BigDecimal;
- import java.util.HashMap;
- import java.util.List;
- import java.util.Map;
- /**
- * @author hujianguo
- * @create 2021-09-22 17:10
- */
- @RestController
- @RequestMapping("${api.version}/bms")
- public class BMSController extends BaseRESTfulController {
- @Autowired
- BmsshipFeign bmsshipFeign;
- @Autowired
- BmstrainFeign bmstrainFeign;
- @Autowired
- BmstruckFeign bmstruckFeign;
- /**
- * 水运结算
- *
- * @param mapValue
- * @param apiId
- * @param pageNum
- * @param pageSize
- * @return
- */
- @PostMapping("getDetailsOrderList")
- @ApiOperation(value = "展示详单列表")
- public RESTfulResult getDetailsOrderList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getDetailsOrderList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getBatch")
- @ApiOperation(value = "展示批次信息")
- public RESTfulResult getBatch(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getBatch(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getPortHandlingFeeList")
- @ApiOperation(value = "展示批次信息")
- public RESTfulResult getPortHandlingFeeList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getPortHandlingFeeList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("addPortHandlingFee")
- @ApiOperation(value = "生成港口装卸费")
- RESTfulResult addPortHandlingFee(@RequestBody Map<String, Object> portHandlingFee) throws Exception {
- return bmsshipFeign.addPortHandlingFee(portHandlingFee);
- }
- @PostMapping("updatePortHandlingFee")
- @ApiOperation(value = "修改港口装卸费信息")
- RESTfulResult updatePortHandlingFee(@RequestBody Map<String, Object> portHandlingFee) {
- return bmsshipFeign.updatePortHandlingFee(portHandlingFee);
- }
- @PostMapping("getFeeToUpdate/{feeId}")
- @ApiOperation(value = "查询修改港口装卸费数据渲染表单")
- RESTfulResult getFeeToUpdate(@PathVariable("feeId") BigDecimal feeId) {
- return bmsshipFeign.getFeeToUpdate(feeId);
- }
- @PostMapping("deletePortHandlingFee/{feeId}")
- @ApiOperation(value = "逻辑删除港口装卸费")
- RESTfulResult deletePortHandlingFee(@PathVariable("feeId") String feeId) {
- return bmsshipFeign.deletePortHandlingFee(feeId);
- }
- @PostMapping("getUncomplateDetailsOrderList")
- @ApiOperation(value = "展示未生成账单的详单信息")
- public RESTfulResult getUncomplateDetailsOrderList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getUncomplateDetailsOrderList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("addDetailsOrder/{resultId}")
- @ApiOperation(value = "生成水运计费详单")
- RESTfulResult addDetailsOrder(@PathVariable("resultId") BigDecimal resultId) throws Exception {
- return bmsshipFeign.addDetailsOrder(resultId);
- }
- @PostMapping("getStatementList")
- @ApiOperation(value = "展示水运费和水分质检费账单信息")
- public RESTfulResult getStatementList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getStatementList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getLossStatementList")
- @ApiOperation(value = "展示途损费账单信息")
- public RESTfulResult getLossStatementList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getLossStatementList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getWaterResult")
- @ApiOperation(value = "展示水分质检实绩")
- public RESTfulResult getWaterResult(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getWaterResult(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("addStatement")
- @ApiOperation(value = "生成水运费账单")
- RESTfulResult addStatement(@RequestBody List<Map<String, Object>> mapList) throws Exception {
- return bmsshipFeign.addStatement(mapList);
- }
- @PostMapping("addWaterStatement")
- @ApiOperation(value = "生成水分质检账单")
- RESTfulResult addWaterStatement(@RequestBody List<Map<String, Object>> mapList) throws Exception {
- return bmsshipFeign.addWaterStatement(mapList);
- }
- @PostMapping("addLossStatement")
- @ApiOperation(value = "生成途损账单")
- RESTfulResult addLossStatement(@RequestBody Map<String, Object> map) throws Exception {
- return bmsshipFeign.addLossStatement(map);
- }
- @PostMapping("getStatementDetailsOrderList")
- @ApiOperation(value = "展示账单下的详单")
- public RESTfulResult getStatementDetailsOrderList(@RequestBody(required = false) Map<String, Object> mapValue,
- BigDecimal batchId,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getStatementDetailsOrderList(batchId, mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getShipResult")
- @ApiOperation(value = "展示详单下的船运实绩")
- public RESTfulResult getShipResult(@RequestBody(required = false) Map<String, Object> mapValue,
- BigDecimal batchId,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmsshipFeign.getShipResult(batchId, mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getShipFeesFormula")
- @ApiOperation(value = "查询水运费计算公式")
- public RESTfulResult getShipFeesFormula() {
- return bmsshipFeign.getShipFeesFormula();
- }
- @PostMapping("getLossFeesFormula")
- @ApiOperation(value = "查询途损费计算公式")
- public RESTfulResult getLossFeesFormula() {
- return bmsshipFeign.getLossFeesFormula();
- }
- @PostMapping("getWaterFeesFormula")
- @ApiOperation(value = "查询水分质检计算公式")
- public RESTfulResult getWaterFeesFormula() {
- return bmsshipFeign.getWaterFeesFormula();
- }
- @PostMapping("getTrainDetailsOrderList")
- @ApiOperation(value = "展示火运详单")
- public RESTfulResult getTrainDetailsOrderList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getTrainDetailsOrderList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getUncomplateTrainDetailsList")
- @ApiOperation(value = "展示未转账单的火运详单")
- public RESTfulResult getUncomplateTrainDetailsList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getUncomplateTrainDetailsList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getTrainResultList")
- @ApiOperation(value = "展示火运实绩")
- public RESTfulResult getTrainResultList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getTrainResultList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("addTrainDetails")
- @ApiOperation(value = "生成火运详单")
- RESTfulResult addTrainDetails(@RequestBody Map<String, Object> map) {
- return bmstrainFeign.addTrainDetails(map);
- }
- @PostMapping("getTrainStatementList")
- @ApiOperation(value = "展示火运账单列表")
- public RESTfulResult getTrainStatementList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getTrainStatementList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getStatementTrainResultList")
- @ApiOperation(value = "展示未转账单的火运详单")
- public RESTfulResult getStatementTrainResultList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId,
- Integer detailsId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getStatementTrainResultList(mapValue, pageNum, pageSize, apiId, detailsId);
- }
- @PostMapping("getComplateTrainDetailsList")
- @ApiOperation(value = "展示账单下的详单")
- public RESTfulResult getComplateTrainDetailsList(BigDecimal batchId,
- @RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId,
- BigDecimal statementId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstrainFeign.getComplateTrainDetailsList(batchId,mapValue, pageNum, pageSize, apiId,statementId);
- }
- @PostMapping("addTrainStatement")
- @ApiOperation(value = "生成火运费账单")
- RESTfulResult addTrainStatement(@RequestBody Map<String, Object> map) {
- return bmstrainFeign.addTrainStatement(map);
- }
- @PostMapping("getTruckDetailsOrderList")
- @ApiOperation(value = "展示汽运详单信息")
- public RESTfulResult getTruckDetailsOrderList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstruckFeign.getTruckDetailsOrderList(mapValue, pageNum, pageSize, apiId);
- }
- @PostMapping("getTruckResultList")
- @ApiOperation(value = "展示汽运详单信息")
- public RESTfulResult getTruckResultList(@RequestBody(required = false) Map<String, Object> mapValue,
- Integer pageNum,
- Integer pageSize,
- Integer apiId,
- Integer orderId) {
- if (mapValue == null) {
- mapValue = new HashMap<>();
- }
- return bmstruckFeign.getTruckResultList(mapValue, pageNum, pageSize, apiId, new BigDecimal(orderId));
- }
- @PostMapping("addTruckDetailsOrder/{orderId}")
- @ApiOperation(value = "新增汽运详单")
- RESTfulResult addTruckDetailsOrder(@PathVariable("orderId") BigDecimal orderId) {
- return bmstruckFeign.addTruckDetailsOrder(orderId);
- }
- }
|