Compare commits
439
Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
4a0ac011b9 | ||
|
|
0363e6fdc5 | ||
|
|
ee873473fb | ||
|
|
b7233d4052 | ||
|
|
afc47230df | ||
|
|
4917dcb154 | ||
|
|
144a5f625a | ||
|
|
b136e6a55e | ||
|
|
1eb2f4c816 | ||
|
|
8ca0b289fa | ||
|
|
457fceb0b1 | ||
|
|
7ab77cfbf7 | ||
|
|
4f16713c03 | ||
|
|
5d89fdc0a6 | ||
|
|
9cdb5a8896 | ||
|
|
bea406051f | ||
|
|
af540c67f9 | ||
|
|
598a8b89e3 | ||
|
|
f149b7322d | ||
|
|
cbe6283009 | ||
|
|
ea8739d178 | ||
|
|
d40556c0be | ||
|
|
244b8d7e6e | ||
|
|
e7162e1877 | ||
|
|
cad9445ec8 | ||
|
|
67d9da9c5d | ||
|
|
de7c40e6ce | ||
|
|
ea4b53b041 | ||
|
|
fed9d449af | ||
|
|
848c92576d | ||
|
|
c652ccd087 | ||
|
|
52a34779ec | ||
|
|
d1135022c8 | ||
|
|
48a2a28025 | ||
|
|
33532bb92d | ||
|
|
5b85d5c3e1 | ||
|
|
ad063713a4 | ||
|
|
d3dbeb5858 | ||
|
|
44d295f702 | ||
|
|
fe1aadd8ac | ||
|
|
98c4c08a8f | ||
|
|
5170a2d96f | ||
|
|
fa68e9dc0e | ||
|
|
93099ce1c0 | ||
|
|
7974fefd96 | ||
|
|
0322b325f6 | ||
|
|
f62eed296f | ||
|
|
a25e56f9b6 | ||
|
|
102fec9ccd | ||
|
|
10c071d17b | ||
|
|
1de84cfedb | ||
|
|
4327b83c82 | ||
|
|
f9b2d212b2 | ||
|
|
f404ef7516 | ||
|
|
78c10abe4f | ||
|
|
5e50398687 | ||
|
|
d1e982b9d4 | ||
|
|
73e7811b13 | ||
|
|
c0c75e2db0 | ||
|
|
8f8bda4a87 | ||
|
|
55a41408b3 | ||
|
|
42ec30eb42 | ||
|
|
cac5c16d3b | ||
|
|
3d3c978c1d | ||
|
|
2f1e6dff42 | ||
|
|
e4e953fb59 | ||
|
|
3cbaec35df | ||
|
|
31acfe0aa9 | ||
|
|
fc1ddec2ba | ||
|
|
5acc1059c1 | ||
|
|
d9e5d5187e | ||
|
|
44916f5460 | ||
|
|
8114bf79e2 | ||
|
|
1e6173c74f | ||
|
|
3e178a53ff | ||
|
|
28afb0b8dc | ||
|
|
df6c9ae6e0 | ||
|
|
532d163f7a | ||
|
|
14dcecb5d4 | ||
|
|
46f53855f9 | ||
|
|
5e16ca2436 | ||
|
|
669583d20a | ||
|
|
f4ff722b96 | ||
|
|
ab4067dd74 | ||
|
|
37dd75622a | ||
|
|
459ac0a809 | ||
|
|
da439c9127 | ||
|
|
147856b289 | ||
|
|
33657ae3c7 | ||
|
|
675799100d | ||
|
|
2ff7b8fd6a | ||
|
|
54510f73cd | ||
|
|
d3428a7b57 | ||
|
|
5f230d03ea | ||
|
|
e6244b94fe | ||
|
|
c1cf09c6c4 | ||
|
|
ae8bfcafcb | ||
|
|
d58411eef9 | ||
|
|
62c42b3aaa | ||
|
|
f2fb43432e | ||
|
|
99e5258017 | ||
|
|
07df495135 | ||
|
|
16b99eb43f | ||
|
|
4149e4b15a | ||
|
|
a55ac20f0e | ||
|
|
b5c29925a8 | ||
|
|
02b64d8f96 | ||
|
|
06830c2fc1 | ||
|
|
9e63ca1e8d | ||
|
|
5189806635 | ||
|
|
a7e0a00d88 | ||
|
|
8cfd6d435a | ||
|
|
296f9a2818 | ||
|
|
09c612bbd9 | ||
|
|
eb015c79d3 | ||
|
|
eb46fb1cc3 | ||
|
|
4cbb338425 | ||
|
|
b8e61e097b | ||
|
|
0ce069af7b | ||
|
|
d436601507 | ||
|
|
10fc266705 | ||
|
|
db313639db | ||
|
|
939d15b521 | ||
|
|
910e1bac83 | ||
|
|
0194adc794 | ||
|
|
0e87b0d4b1 | ||
|
|
54631a0101 | ||
|
|
e495aae1a1 | ||
|
|
a655870fbe | ||
|
|
99602b3782 | ||
|
|
3d24f32c9d | ||
|
|
a2780dc9dc | ||
|
|
2b0a582a5a | ||
|
|
2c27ce7031 | ||
|
|
2ee208c50e | ||
|
|
d4f6965fb5 | ||
|
|
b34b7d8792 | ||
|
|
3c3f6a2bc8 | ||
|
|
0fd00ed65d | ||
|
|
60825ebe9d | ||
|
|
9b9ea1c0a5 | ||
|
|
38e7606a71 | ||
|
|
20422aeb83 | ||
|
|
558fdde064 | ||
|
|
56db83a80d | ||
|
|
6af1bd8aa0 | ||
|
|
99d0e2593d | ||
|
|
821f1bf956 | ||
|
|
29aa101654 | ||
|
|
2190fcf623 | ||
|
|
e439b71467 | ||
|
|
d91779cf5c | ||
|
|
2b70f25fae | ||
|
|
440129373c | ||
|
|
7f6d04e122 | ||
|
|
ef698c2fa1 | ||
|
|
caf926f503 | ||
|
|
7644dc8fc5 | ||
|
|
4363235bfb | ||
|
|
089b7535b5 | ||
|
|
81633720e3 | ||
|
|
fe096a498f | ||
|
|
9aa72e44d7 | ||
|
|
d914f48ef0 | ||
|
|
32dbc85026 | ||
|
|
fe5880890e | ||
|
|
43b3773e3e | ||
|
|
480d50f9da | ||
|
|
cd79abeb32 | ||
|
|
43aec4ac0d | ||
|
|
2a9f715406 | ||
|
|
52779f0196 | ||
|
|
db86df135a | ||
|
|
e0d3e40847 | ||
|
|
6787c17b00 | ||
|
|
49cdce7b9c | ||
|
|
5786521755 | ||
|
|
6bea09744f | ||
|
|
62b779d1f0 | ||
|
|
58f2e70f21 | ||
|
|
9dd3be3507 | ||
|
|
6adcc406b9 | ||
|
|
5b2d4569a7 | ||
|
|
126a826513 | ||
|
|
373600aba2 | ||
|
|
d143ca2840 | ||
|
|
0652ccecf4 | ||
|
|
e5476beb07 | ||
|
|
04ed2148a7 | ||
|
|
dc09743357 | ||
|
|
347767ffc2 | ||
|
|
7926235114 | ||
|
|
2710c97f42 | ||
|
|
4b9c2978ae | ||
|
|
ff682a47f4 | ||
|
|
b72134a936 | ||
|
|
7c6745bdd1 | ||
|
|
17e1937be4 | ||
|
|
8dbbaa54b9 | ||
|
|
addb2fd96e | ||
|
|
db34025a4b | ||
|
|
59df615137 | ||
|
|
d9ec7cd352 | ||
|
|
e26dc853d5 | ||
|
|
8a3af8a13e | ||
|
|
7dde79c61f | ||
|
|
1c83d70437 | ||
|
|
c88d22c185 | ||
|
|
115eb3f791 | ||
|
|
d7e5699410 | ||
|
|
00dacdae19 | ||
|
|
bbbb0b835d | ||
|
|
3b9983c68f | ||
|
|
277dc19988 | ||
|
|
76fff6437d | ||
|
|
0738c939ae | ||
|
|
da34a284d2 | ||
|
|
15b5c5443d | ||
|
|
a52984b103 | ||
|
|
79ca006214 | ||
|
|
d25a957f13 | ||
|
|
714bb1cce4 | ||
|
|
2afe2061af | ||
|
|
18d479b55e | ||
|
|
d9faab242a | ||
|
|
7f35e4b375 | ||
|
|
0512713541 | ||
|
|
04a7dedbca | ||
|
|
797f2db7c1 | ||
|
|
1f8f89264b | ||
|
|
93a4afbacc | ||
|
|
bc4e60a408 | ||
|
|
5b86965586 | ||
|
|
b62a8eb7cf | ||
|
|
1fadbbdec5 | ||
|
|
df671374b3 | ||
|
|
985effdaa3 | ||
|
|
cf19750fe0 | ||
|
|
5c83fd1559 | ||
|
|
732bfa1f5a | ||
|
|
1997aa2e8d | ||
|
|
574bd553e7 | ||
|
|
31dae7ecf6 | ||
|
|
12a5cc6129 | ||
|
|
5bde552f18 | ||
|
|
03860eb30a | ||
|
|
276138394e | ||
|
|
fea66b5e28 | ||
|
|
d641a757f6 | ||
|
|
2fc8fa8331 | ||
|
|
b3eb3f9963 | ||
|
|
254fa94512 | ||
|
|
02736c16f2 | ||
|
|
186c5d1b94 | ||
|
|
b2d0602a6b | ||
|
|
16c46565f5 | ||
|
|
3196c3416a | ||
|
|
a51e6e3f3d | ||
|
|
6255279979 | ||
|
|
7802b28143 | ||
|
|
ca4b1ce2a3 | ||
|
|
581421da33 | ||
|
|
bf4b1d9568 | ||
|
|
805740f78c | ||
|
|
fa650c7ef7 | ||
|
|
e1411e1fe7 | ||
|
|
65a3d4d5c9 | ||
|
|
d9d75bd0cf | ||
|
|
4dfa961a58 | ||
|
|
5cae9b8fa7 | ||
|
|
55b6554216 | ||
|
|
9e8f0f195a | ||
|
|
f3f10d10db | ||
|
|
db28bab895 | ||
|
|
fe174b45ef | ||
|
|
a2e3f23798 | ||
|
|
2cf42f6e06 | ||
|
|
7a45568be6 | ||
|
|
8ba0c64b62 | ||
|
|
bd9cfe50f8 | ||
|
|
a52049eab3 | ||
|
|
f283c66278 | ||
|
|
23964e5e6d | ||
|
|
22d5a1ea3f | ||
|
|
258417cac7 | ||
|
|
a7b7e2c82d | ||
|
|
1655d57057 | ||
|
|
88ac989ced | ||
|
|
aab59723f9 | ||
|
|
7f8732dd02 | ||
|
|
56356839bf | ||
|
|
1837337488 | ||
|
|
e342fa92a8 | ||
|
|
ae76596503 | ||
|
|
b25c795d4e | ||
|
|
b6f5ed6dab | ||
|
|
90e6ec8086 | ||
|
|
ff334b155c | ||
|
|
2fa97d50e1 | ||
|
|
9efd0426d4 | ||
|
|
f6231256d5 | ||
|
|
e6d91c8d1d | ||
|
|
7e50d8d5c6 | ||
|
|
ea771777bb | ||
|
|
84e1767812 | ||
|
|
744cbc532b | ||
|
|
355953940a | ||
|
|
70dd99d497 | ||
|
|
eb98e9e4bd | ||
|
|
52f5b6e0d6 | ||
|
|
0b584352cb | ||
|
|
dfd7b34172 | ||
|
|
015162d5c9 | ||
|
|
e6b81b38ee | ||
|
|
b3355cd1d0 | ||
|
|
9da953619f | ||
|
|
781d530c21 | ||
|
|
419cb53845 | ||
|
|
f73f74939f | ||
|
|
8ea215c58c | ||
|
|
4bde2aee3d | ||
|
|
9996f59fe4 | ||
|
|
e5f8ddd8b6 | ||
|
|
0533d1a941 | ||
|
|
536079a024 | ||
|
|
a648c4a50d | ||
|
|
a484296ab8 | ||
|
|
1708b4384c | ||
|
|
8d89f5ec27 | ||
|
|
84ab2c8bf9 | ||
|
|
14cfad6b50 | ||
|
|
abf2847475 | ||
|
|
65552144eb | ||
|
|
2558e1ab2a | ||
|
|
64d2a5e001 | ||
|
|
801a7c3b9c | ||
|
|
932c432eff | ||
|
|
6606c65d73 | ||
|
|
89b5d544c6 | ||
|
|
8f0d4ed687 | ||
|
|
e77897c597 | ||
|
|
931d63a5da | ||
|
|
8924757467 | ||
|
|
7476599ffd | ||
|
|
bb43850227 | ||
|
|
32d638730d | ||
|
|
c4bd6d18d4 | ||
|
|
035593b419 | ||
|
|
d7df2da828 | ||
|
|
935c154136 | ||
|
|
c8493dd658 | ||
|
|
d2e8d6ab30 | ||
|
|
540a687f7e | ||
|
|
c337a7ed49 | ||
|
|
f7e6f70321 | ||
|
|
4b427e1b2e | ||
|
|
2e284f450d | ||
|
|
af7dda73de | ||
|
|
3ec71c4a88 | ||
|
|
0db01980b8 | ||
|
|
865610fda3 | ||
|
|
8b98c54d11 | ||
|
|
fd579a6f42 | ||
|
|
f14547eb53 | ||
|
|
e71c9d6e58 | ||
|
|
6cb96410a2 | ||
|
|
2ddb557bcc | ||
|
|
29b24e8450 | ||
|
|
04d5ef1645 | ||
|
|
dae359655a | ||
|
|
40744bb5c1 | ||
|
|
d9113d0523 | ||
|
|
6f9b1a6026 | ||
|
|
be97110b3c | ||
|
|
3ea4bb8170 | ||
|
|
4c560ef88c | ||
|
|
50069a27b0 | ||
|
|
5aa70ed41b | ||
|
|
1259c189b0 | ||
|
|
a044117187 | ||
|
|
dfcac0b5a5 | ||
|
|
b29d0b1f3e | ||
|
|
5182db6528 | ||
|
|
c8fdea2c3a | ||
|
|
55196b1c14 | ||
|
|
7e6b464432 | ||
|
|
98af145acb | ||
|
|
1d9629127a | ||
|
|
b55a782473 | ||
|
|
b11a0be679 | ||
|
|
88c3548129 | ||
|
|
9bc90fe601 | ||
|
|
d805e2d642 | ||
|
|
d2da556697 | ||
|
|
3ee81a06eb | ||
|
|
b8799a1ec7 | ||
|
|
b00308b729 | ||
|
|
84a4ee1e76 | ||
|
|
2c0882ae2d | ||
|
|
09880952cf | ||
|
|
e3f242f97b | ||
|
|
bcabed521d | ||
|
|
2199c8c739 | ||
|
|
8bc07e8090 | ||
|
|
7ed03628fa | ||
|
|
2b3fa73db1 | ||
|
|
c78b9c325c | ||
|
|
6c2fb7c013 | ||
|
|
5cc3b9a62f | ||
|
|
c27e2b624d | ||
|
|
21157b70ed | ||
|
|
89e68566bf | ||
|
|
088460459b | ||
|
|
4a7d28350e | ||
|
|
04e26568ae | ||
|
|
52cdfbe6d9 | ||
|
|
2b385f45cd | ||
|
|
51b5ae5d13 | ||
|
|
927b5a4411 | ||
|
|
0beab25b52 | ||
|
|
c830009948 | ||
|
|
4248a334ab | ||
|
|
97330de8ba | ||
|
|
133824fb53 | ||
|
|
f8399951b3 | ||
|
|
3447d2f7bc | ||
|
|
8affee1409 | ||
|
|
a18fd9d59b | ||
|
|
74e735353f | ||
|
|
afc49be45f | ||
|
|
61e52aa744 | ||
|
|
f485b040e1 | ||
|
|
3d4df0a154 | ||
|
|
d58b948c3a | ||
|
|
c6709936f9 | ||
|
|
df299a21ae | ||
|
|
7b10ff2b25 | ||
|
|
0b361ba2b7 | ||
|
|
a950417939 |
@@ -275,6 +275,12 @@ public interface SystemServiceFeign {
|
||||
@GetMapping("/associationWarehouseApi/setWarehouseInfo")
|
||||
public AjaxResult setWarehouseInfo(@RequestBody AssociationWarehouseFeign associationWarehouseFeign);
|
||||
|
||||
/**
|
||||
* 查询仓库关联的用户ID集合
|
||||
*/
|
||||
@GetMapping("/associationWarehouseApi/queryListCorrelationId")
|
||||
public AjaxResult queryListCorrelationId(@RequestParam(value = "warehouseId", required = false) Long warehouseId);
|
||||
|
||||
|
||||
/**
|
||||
* 根据code编码查询费用科目
|
||||
|
||||
@@ -109,6 +109,13 @@ public interface UserServiceFeign {
|
||||
@GetMapping("/userApi/getInfo/{userId}")
|
||||
public AjaxResult getInfo(@PathVariable("userId") Long userId);
|
||||
|
||||
/**
|
||||
* 根据用户ID查询用户详细信息
|
||||
*/
|
||||
@ApiOperation("根据用户ID查询用户详细信息")
|
||||
@GetMapping("/userApi/getInfoByName/{userName}")
|
||||
public AjaxResult getInfoByName(@PathVariable("userName") String userName);
|
||||
|
||||
|
||||
/**
|
||||
* 查询车辆绑定的承运人列表
|
||||
@@ -180,4 +187,8 @@ public interface UserServiceFeign {
|
||||
@ApiOperation("查询承运人汇总数据")
|
||||
@GetMapping("/userShipperApi/getShipperSummaryData/{userId}")
|
||||
public AjaxResult<?> getShipperSummaryData(@PathVariable("userId") Long userId);
|
||||
}
|
||||
|
||||
@ApiOperation("根据用户ID查询货主信息")
|
||||
@GetMapping("/userShipperApi/getShipperByUserId/{userId}")
|
||||
public AjaxResult<?> getShipperByUserId(@PathVariable("userId") Long userId);
|
||||
}
|
||||
@@ -14,6 +14,7 @@ import com.mhd.common.core.domain.entity.RevenueExpensesRecord;
|
||||
import com.mhd.common.core.domain.entity.SysConfigSwitch;
|
||||
import com.mhd.common.core.domain.entity.TmsOrder;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import com.mhd.common.core.utils.sms.Result;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import com.mhd.system.api.feign.FeignAutoConfiguration;
|
||||
@@ -302,7 +303,13 @@ public interface WlhyServiceFeign {
|
||||
@GetMapping(value = "/feign/transportNote/selectByOrderNum")
|
||||
public R<TmsTransportNote> selectByOrderNum(@RequestParam(value = "orderNo") String orderNo);
|
||||
|
||||
|
||||
/**
|
||||
* 根据发票id查询发票信息
|
||||
* @param id
|
||||
* @return
|
||||
*/
|
||||
@GetMapping(value = "/feign/invoiceList/selectById")
|
||||
public R<TmsInvoiceListDetailsVO> selectInvoiceListById(@RequestParam(value = "id") String id);
|
||||
/**
|
||||
* 运输单表-支付回调
|
||||
* @param tmsPayCallbackList
|
||||
@@ -509,4 +516,17 @@ public interface WlhyServiceFeign {
|
||||
@PostMapping(value = "/feign/outBoundSummary/getOrderListByReconciliation")
|
||||
public R<List<TmsOrder>> getOrderListByReconciliation(@RequestBody ReconciliationDTO reconciliationDTO);
|
||||
|
||||
@GetMapping(value = "/ntocc/tmsSettlementExchangeRate/queryById")
|
||||
public Result<?> queryById(@RequestParam(name="id",required=true) String id);
|
||||
|
||||
/**
|
||||
* 数字物流同步网货订单
|
||||
* @param tmsOrderAddDTO
|
||||
* @return
|
||||
*/
|
||||
@PostMapping("/feign/order/add")
|
||||
public AjaxResult add(@RequestBody TmsOrderAddDTO tmsOrderAddDTO);
|
||||
|
||||
@GetMapping("/feign/order/cancelIssueDocuments")
|
||||
public AjaxResult cancelIssueDocuments(@RequestParam(name="executeOrderId") String executeOrderId);
|
||||
}
|
||||
|
||||
@@ -3,12 +3,15 @@ package com.mhd.system.api;
|
||||
import com.mhd.common.core.constant.ServiceNameConstants;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.domain.MaterialBaseInfoFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.domain.NoticeOrderDTO;
|
||||
import com.mhd.system.api.factory.RemoteTicketFeignFallbackFactory;
|
||||
import com.mhd.system.api.feign.FeignAutoConfiguration;
|
||||
import org.springframework.cloud.openfeign.FeignClient;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title WmsServiceFeign
|
||||
@@ -57,4 +60,9 @@ public interface WmsServiceFeign {
|
||||
@PostMapping("/noticeOrderApi/insert")
|
||||
public AjaxResult stockOutOrInInsert(@RequestBody NoticeOrderDTO noticeOrderDTO);
|
||||
|
||||
/**
|
||||
* 查询物料库存列表不分页
|
||||
*/
|
||||
@GetMapping("/materialInventoryApi/listAll")
|
||||
public AjaxResult materialInventoryApiListAll(MaterialInventoryDTO materialInventoryDTO);
|
||||
}
|
||||
|
||||
@@ -44,6 +44,10 @@ public class BatchDetailFeignPO extends BaseVOEntity{
|
||||
@Excel(name = "批次标签")
|
||||
private String batchLabels;
|
||||
|
||||
@ApiModelProperty("字段名称")
|
||||
@Excel(name = "字段名称")
|
||||
private String fieldName;
|
||||
|
||||
@ApiModelProperty("输入控制: 1-必填 2-可选")
|
||||
@Excel(name = "输入控制: 1-必填 2-可选")
|
||||
private String inputControl;
|
||||
@@ -56,6 +60,10 @@ public class BatchDetailFeignPO extends BaseVOEntity{
|
||||
@Excel(name = "属性选项")
|
||||
private String attributeOption;
|
||||
|
||||
@ApiModelProperty("是否显示: 0-不显示 1-显示")
|
||||
@Excel(name = "是否显示: 0-不显示 1-显示")
|
||||
private Integer isDisplay;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
+30
@@ -181,5 +181,35 @@ public class MaterialBaseInfoFeign extends BaseVOEntity{
|
||||
@ApiModelProperty("是否公用: 1-是 2-否")
|
||||
@Excel(name = "是否公用: 1-是 2-否")
|
||||
private Integer common;
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("单价")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("HS码")
|
||||
private String hsCode;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("法定单位")
|
||||
private String statutoryUnit;
|
||||
|
||||
@ApiModelProperty("法定第二单位")
|
||||
private String statutorySecondUnit;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
|
||||
@ApiModelProperty("币制")
|
||||
private String currency;
|
||||
}
|
||||
|
||||
|
||||
+149
@@ -0,0 +1,149 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 物料库存对象 material_inventory
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-29
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class MaterialInventoryDTO {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("物料库存id")
|
||||
private Long materialInventoryId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("物料基础信息id")
|
||||
@Excel(name = "物料基础信息id")
|
||||
private Long materialBaseInfoId;
|
||||
|
||||
@ApiModelProperty("上架单物料明细id")
|
||||
@Excel(name = "上架单物料明细id")
|
||||
private Long materialDetailId;
|
||||
|
||||
@ApiModelProperty("仓库id")
|
||||
@Excel(name = "仓库id")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库编码")
|
||||
@Excel(name = "仓库编码")
|
||||
private String warehouseCode;
|
||||
|
||||
@ApiModelProperty("仓库名称")
|
||||
@Excel(name = "仓库名称")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("库区id")
|
||||
@Excel(name = "库区id")
|
||||
private Long storageSectionId;
|
||||
|
||||
@ApiModelProperty("库区编码")
|
||||
@Excel(name = "库区编码")
|
||||
private String storageCode;
|
||||
|
||||
@ApiModelProperty("库区名称")
|
||||
@Excel(name = "库区名称")
|
||||
private String storageName;
|
||||
|
||||
@ApiModelProperty("库位id")
|
||||
@Excel(name = "库位id")
|
||||
private Long storageLocationId;
|
||||
|
||||
@ApiModelProperty("库位编码")
|
||||
@Excel(name = "库位编码")
|
||||
private String storageLocationCode;
|
||||
|
||||
@ApiModelProperty("库位名称")
|
||||
@Excel(name = "库位名称")
|
||||
private String storageLocationName;
|
||||
|
||||
@ApiModelProperty("批次号")
|
||||
@Excel(name = "批次号")
|
||||
private String batchNumber;
|
||||
|
||||
@ApiModelProperty("物料状态编码")
|
||||
@Excel(name = "物料状态编码")
|
||||
private String materialStatusCode;
|
||||
|
||||
@ApiModelProperty("物料状态名称")
|
||||
@Excel(name = "物料状态名称")
|
||||
private String materialStatusName;
|
||||
|
||||
@ApiModelProperty("容器id")
|
||||
@Excel(name = "容器id")
|
||||
private Long containerId;
|
||||
|
||||
@ApiModelProperty("容器编码")
|
||||
@Excel(name = "容器编码")
|
||||
private String containerCode;
|
||||
|
||||
@ApiModelProperty("容器类型 数据字典")
|
||||
@Excel(name = "容器类型 数据字典")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("容器类型名称 数据字典")
|
||||
@Excel(name = "容器类型名称 数据字典")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("库存数量")
|
||||
@Excel(name = "库存数量")
|
||||
private BigDecimal inventoryQuantity;
|
||||
|
||||
@ApiModelProperty("可用数量")
|
||||
@Excel(name = "可用数量")
|
||||
private BigDecimal allocationQuantity;
|
||||
|
||||
@ApiModelProperty("冻结数量")
|
||||
@Excel(name = "冻结数量")
|
||||
private BigDecimal freezeQuantity;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
|
||||
@ApiModelProperty("盘点是否可用:0-禁用 1-可用")
|
||||
@Excel(name = "盘点是否可用:0-禁用 1-可用")
|
||||
private Integer isAble;
|
||||
|
||||
@ApiModelProperty("货主信息")
|
||||
@Excel(name = "货主信息")
|
||||
private String shipperInfo;
|
||||
|
||||
@ApiModelProperty("物料信息")
|
||||
@Excel(name = "物料信息")
|
||||
private String materialInfo;
|
||||
|
||||
@ApiModelProperty("物料/库位信息")
|
||||
@Excel(name = "物料/库位信息")
|
||||
private String storageInfo;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
}
|
||||
@@ -0,0 +1,226 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Description: 销项发票表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-19 08:50:47
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("tms_invoice_list")
|
||||
public class TmsInvoiceList implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ID_WORKER_STR)
|
||||
private String id;
|
||||
/**发票抬头*/
|
||||
@ApiModelProperty(value = "发票抬头")
|
||||
private String invoiceTitle;
|
||||
/**发票金额*/
|
||||
@ApiModelProperty(value = "发票金额")
|
||||
|
||||
private BigDecimal invoiceValue;
|
||||
/**发票备注*/
|
||||
@ApiModelProperty(value = "发票备注")
|
||||
|
||||
private String remark;
|
||||
/**发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)*/
|
||||
@ApiModelProperty(value = "发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)")
|
||||
|
||||
private Integer invoiceState;
|
||||
/**发票申请时间*/
|
||||
@ApiModelProperty(value = "发票申请时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date invoiceApplyTime;
|
||||
/**申请人ID*/
|
||||
@ApiModelProperty(value = "申请人ID")
|
||||
|
||||
private String applicantId;
|
||||
/**发票申请单号*/
|
||||
@ApiModelProperty(value = "发票申请单号")
|
||||
|
||||
private String applyNumber;
|
||||
/**驳回原因*/
|
||||
@ApiModelProperty(value = "驳回原因")
|
||||
|
||||
private String rejectReason;
|
||||
/**运输单ids*/
|
||||
@ApiModelProperty(value = "运输单ids")
|
||||
|
||||
private String transportationIds;
|
||||
/**退票备注*/
|
||||
@ApiModelProperty(value = "退票备注")
|
||||
|
||||
private String refundRemark;
|
||||
/**处理人ID(取消申请/开票/驳回)*/
|
||||
@ApiModelProperty(value = "处理人ID(取消申请/开票/驳回)")
|
||||
|
||||
private String managerId;
|
||||
/**处理时间*/
|
||||
@ApiModelProperty(value = "处理时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date managerTime;
|
||||
/**寄出人ID*/
|
||||
@ApiModelProperty(value = "寄出人ID")
|
||||
|
||||
private String sendById;
|
||||
/**寄出时间*/
|
||||
@ApiModelProperty(value = "寄出时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date sendTime;
|
||||
/**寄出邮费*/
|
||||
@ApiModelProperty(value = "寄出邮费")
|
||||
|
||||
private BigDecimal sendPostage;
|
||||
/**快递公司*/
|
||||
@ApiModelProperty(value = "快递公司")
|
||||
|
||||
private String courierServicesCompany;
|
||||
/**收件地址id*/
|
||||
@ApiModelProperty(value = "收件地址id")
|
||||
|
||||
private String receivingAddressId;
|
||||
/**手机号*/
|
||||
@ApiModelProperty(value = "手机号")
|
||||
|
||||
private String phone;
|
||||
/**收件人姓名*/
|
||||
@ApiModelProperty(value = "收件人姓名")
|
||||
|
||||
private String receivingName;
|
||||
/**邮政编码*/
|
||||
@ApiModelProperty(value = "邮政编码")
|
||||
|
||||
private String postalCode;
|
||||
/**所在地区*/
|
||||
@ApiModelProperty(value = "所在地区")
|
||||
|
||||
private String location;
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
|
||||
private String createBy;
|
||||
/**创建日期*/
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
|
||||
private String updateBy;
|
||||
/**更新日期*/
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date updateTime;
|
||||
/**是否删除(0-否,1-是)*/
|
||||
@ApiModelProperty(value = "是否删除(0-否,1-是)")
|
||||
|
||||
private Integer isDelete;
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
|
||||
private String sysOrgCode;
|
||||
/**发票类型(0-增值税专用发票,1-普通发票)*/
|
||||
@ApiModelProperty(value = "发票类型(0-增值税专用发票,1-普通发票)")
|
||||
|
||||
private Integer invoiceType;
|
||||
/**发票性质(0-纸质发票,1-电子发票)*/
|
||||
@ApiModelProperty(value = "发票性质(0-纸质发票,1-电子发票)")
|
||||
|
||||
private Integer invoiceNature;
|
||||
/**发票号*/
|
||||
@ApiModelProperty(value = "发票号")
|
||||
|
||||
private String invoiceNumber;
|
||||
/**快递单号*/
|
||||
@ApiModelProperty(value = "快递单号")
|
||||
|
||||
private String trackingNumber;
|
||||
/**开票代码*/
|
||||
@ApiModelProperty(value = "开票代码")
|
||||
|
||||
private String invoiceCode;
|
||||
/**发票详情信息上报状态:0-未上报,1-已上报,2-上报失败*/
|
||||
@ApiModelProperty(value = "发票详情信息上报状态:0-未上报,1-已上报,2-上报失败")
|
||||
|
||||
private Integer isReport;
|
||||
/**发票详情信息上报失败原因*/
|
||||
@ApiModelProperty(value = "发票详情信息上报失败原因")
|
||||
|
||||
private String errMsg;
|
||||
|
||||
/**发票详情信息上报时间*/
|
||||
@ApiModelProperty(value = "发票详情信息上报时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reportTime;
|
||||
|
||||
@ApiModelProperty(value = "运单事实创建人ID(创建运单时的当前登录人USER-ID)")
|
||||
private String realCreateBy;
|
||||
|
||||
@ApiModelProperty(value = "运单事实创建人名称(创建运单时的当前登录人REAL-NAME)")
|
||||
private String realCreateName;
|
||||
|
||||
@ApiModelProperty(value = "开票时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date invoiceMakeTime;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主信息id")
|
||||
|
||||
private String shipperId;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主姓名")
|
||||
|
||||
private String shipperName;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主公司名称")
|
||||
|
||||
private String companyName;
|
||||
|
||||
/**税务登记证号*/
|
||||
@ApiModelProperty(value = "税务登记证号")
|
||||
|
||||
private String taxRegAccount;
|
||||
|
||||
/**组织ID*/
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
|
||||
private Long organizationId;
|
||||
|
||||
/**组织名称*/
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
|
||||
private String organizationName;
|
||||
|
||||
/**一级组织ID*/
|
||||
@ApiModelProperty(value = "一级组织ID")
|
||||
|
||||
private Long topOrganizationId;
|
||||
}
|
||||
+176
@@ -0,0 +1,176 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @Description: 销项发票表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-19 08:50:47
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
public class TmsInvoiceListDetailsVO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ID_WORKER_STR)
|
||||
private String id;
|
||||
/**发票抬头*/
|
||||
@ApiModelProperty(value = "发票抬头")
|
||||
|
||||
private String invoiceTitle;
|
||||
/**发票金额*/
|
||||
@ApiModelProperty(value = "发票金额")
|
||||
|
||||
private BigDecimal invoiceValue;
|
||||
/**发票备注*/
|
||||
@ApiModelProperty(value = "发票备注")
|
||||
|
||||
private String remark;
|
||||
/**发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)*/
|
||||
@ApiModelProperty(value = "发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)")
|
||||
|
||||
private Integer invoiceState;
|
||||
/**发票申请时间*/
|
||||
@ApiModelProperty(value = "发票申请时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date invoiceApplyTime;
|
||||
/**申请人ID*/
|
||||
@ApiModelProperty(value = "申请人ID")
|
||||
|
||||
private String applicantId;
|
||||
/**驳回原因*/
|
||||
@ApiModelProperty(value = "驳回原因")
|
||||
|
||||
private String rejectReason;
|
||||
/**退票备注*/
|
||||
@ApiModelProperty(value = "退票备注")
|
||||
|
||||
private String refundRemark;
|
||||
/**处理人ID(取消申请/开票/驳回)*/
|
||||
@ApiModelProperty(value = "处理人ID(取消申请/开票/驳回)")
|
||||
|
||||
private String managerId;
|
||||
/**处理时间*/
|
||||
@ApiModelProperty(value = "处理时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date managerTime;
|
||||
/**寄出人ID*/
|
||||
@ApiModelProperty(value = "寄出人ID")
|
||||
|
||||
private String sendById;
|
||||
/**寄出时间*/
|
||||
@ApiModelProperty(value = "寄出时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date sendTime;
|
||||
/**寄出邮费*/
|
||||
@ApiModelProperty(value = "寄出邮费")
|
||||
|
||||
private BigDecimal sendPostage;
|
||||
/**快递公司*/
|
||||
@ApiModelProperty(value = "快递公司")
|
||||
|
||||
private String courierServicesCompany;
|
||||
/**收件地址id*/
|
||||
@ApiModelProperty(value = "收件地址id")
|
||||
|
||||
private String receivingAddressId;
|
||||
/**收件姓名*/
|
||||
@ApiModelProperty(value = "收件姓名")
|
||||
|
||||
private String receivingName;
|
||||
/**收件地址*/
|
||||
@ApiModelProperty(value = "收件地址")
|
||||
|
||||
private String location;
|
||||
/**手机号*/
|
||||
@ApiModelProperty(value = "手机号")
|
||||
|
||||
private String phone;
|
||||
/**运输单ids*/
|
||||
@ApiModelProperty(value = "运输单ids")
|
||||
|
||||
private String transportationIds;
|
||||
/**创建日期*/
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
/**税务登记证号*/
|
||||
@ApiModelProperty(value = "税务登记证号")
|
||||
|
||||
private String taxRegAccount;
|
||||
/**运输单列表*/
|
||||
/* @ApiModelProperty(value = "运输单列表")
|
||||
|
||||
private List<TmsOrderVO> tmsOrderVOList;*/
|
||||
/**发票类型(0-增值税专用发票,1-普通发票)*/
|
||||
@ApiModelProperty(value = "发票类型(0-增值税专用发票,1-普通发票)")
|
||||
|
||||
private String invoiceType;
|
||||
/**发票性质(0-纸质发票,1-电子发票)*/
|
||||
@ApiModelProperty(value = "发票性质(0-纸质发票,1-电子发票)")
|
||||
|
||||
private String invoiceNature;
|
||||
/**发票号*/
|
||||
@ApiModelProperty(value = "发票号")
|
||||
|
||||
private String invoiceNumber;
|
||||
/**快递单号*/
|
||||
@ApiModelProperty(value = "快递单号")
|
||||
|
||||
private String trackingNumber;
|
||||
|
||||
/**开票表集合*/
|
||||
@ApiModelProperty(value = "开票表集合")
|
||||
|
||||
private List<TmsMakeOutInvoice> tmsMakeOutInvoices;
|
||||
|
||||
/**账单项目费用*/
|
||||
@ApiModelProperty(value = "账单项目费用")
|
||||
|
||||
private List<Map<String, Object>> feeList;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主信息id")
|
||||
|
||||
private String shipperId;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主姓名")
|
||||
|
||||
private String shipperName;
|
||||
|
||||
/**货主电话*/
|
||||
@ApiModelProperty(value = "货主电话")
|
||||
|
||||
private String shipperPhone;
|
||||
|
||||
/**货主信息id*/
|
||||
@ApiModelProperty(value = "货主公司名称")
|
||||
|
||||
private String companyName;
|
||||
|
||||
@ApiModelProperty(value = "统一社会信用代码")
|
||||
private String regAccount;
|
||||
|
||||
|
||||
|
||||
}
|
||||
+130
@@ -0,0 +1,130 @@
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.baomidou.mybatisplus.annotation.TableName;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* @Description: 销项发票表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-19 08:50:47
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
@TableName("tms_make_out_invoice")
|
||||
public class TmsMakeOutInvoice implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/**主键*/
|
||||
@TableId(type = IdType.ID_WORKER_STR)
|
||||
private String id;
|
||||
/**发票ID*/
|
||||
@ApiModelProperty(value = "发票ID")
|
||||
|
||||
private String invoiceId;
|
||||
/**发票抬头*/
|
||||
@ApiModelProperty(value = "发票抬头")
|
||||
|
||||
private String invoiceTitle;
|
||||
/**发票金额*/
|
||||
@ApiModelProperty(value = "发票金额")
|
||||
|
||||
private BigDecimal invoiceValue;
|
||||
/**发票备注*/
|
||||
@ApiModelProperty(value = "发票备注")
|
||||
|
||||
private String remark;
|
||||
/**发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)*/
|
||||
@ApiModelProperty(value = "发票状态(0-未开票,1-已取消申请,2-已开票,3-已驳回,4-已寄出,5-已作废)")
|
||||
|
||||
private Integer invoiceState;
|
||||
/**发票申请时间*/
|
||||
@ApiModelProperty(value = "发票申请时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date invoiceApplyTime;
|
||||
/**创建人*/
|
||||
@ApiModelProperty(value = "创建人")
|
||||
|
||||
private String createBy;
|
||||
/**创建日期*/
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
/**更新人*/
|
||||
@ApiModelProperty(value = "更新人")
|
||||
|
||||
private String updateBy;
|
||||
/**更新日期*/
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date updateTime;
|
||||
/**是否删除(0-否,1-是)*/
|
||||
@ApiModelProperty(value = "是否删除(0-否,1-是)")
|
||||
|
||||
private Integer isDelete;
|
||||
/**所属部门*/
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
|
||||
private String sysOrgCode;
|
||||
/**开票号码*/
|
||||
@ApiModelProperty(value = "开票号码")
|
||||
|
||||
private String invoiceNumber;
|
||||
/**开票人ID*/
|
||||
@ApiModelProperty(value = "开票人ID")
|
||||
|
||||
private String makeOutInvoiceId;
|
||||
/**开票时间*/
|
||||
@ApiModelProperty(value = "开票时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date makeOutInvoiceTime;
|
||||
/**开票代码*/
|
||||
@ApiModelProperty(value = "开票代码")
|
||||
|
||||
private String invoiceCode;
|
||||
|
||||
/**上报状态:0-未上报,1-已上报,2-上报失败*/
|
||||
@ApiModelProperty(value = "上报状态:0-未上报,1-已上报,2-上报失败")
|
||||
|
||||
private Integer isReport;
|
||||
/**上报时间*/
|
||||
@ApiModelProperty(value = "上报时间")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date reportTime;
|
||||
/**失败原因*/
|
||||
@ApiModelProperty(value = "失败原因")
|
||||
|
||||
private String errMsg;
|
||||
|
||||
@ApiModelProperty(value = "电子发票地址")
|
||||
private String invoiceFileUrl;
|
||||
|
||||
@ApiModelProperty(value = "发票摘要")
|
||||
private String invoiceAbstract;
|
||||
|
||||
@ApiModelProperty(value = "开票项目")
|
||||
private String invoiceItem;
|
||||
@ApiModelProperty(value = "实际开票客户id")
|
||||
private String actualInvoiceCustomerId;
|
||||
@ApiModelProperty(value = "实际开票客户名称")
|
||||
private String actualInvoiceCustomerName;
|
||||
}
|
||||
@@ -0,0 +1,771 @@
|
||||
/*
|
||||
package com.mhd.system.api.domain;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
*/
|
||||
/**
|
||||
* @Description: 货源表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-14 09:49:27
|
||||
* @Version: V1.0
|
||||
*//*
|
||||
|
||||
@Data
|
||||
public class TmsOrderVO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@TableId(type = IdType.ID_WORKER_STR)
|
||||
private String id = "";
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createBy = "";
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String createrAvatar = "";
|
||||
@ApiModelProperty(value = "创建日期")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
@ApiModelProperty(value = "更新人")
|
||||
private String updateBy = "";
|
||||
@ApiModelProperty(value = "更新日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date updateTime;
|
||||
@ApiModelProperty(value = "所属部门")
|
||||
private String sysOrgCode = "";
|
||||
@ApiModelProperty(value = "货源单号")
|
||||
|
||||
private String goodsNumber = "";
|
||||
@ApiModelProperty(value = "线路名称ID")
|
||||
private String lineNameId = "";
|
||||
@ApiModelProperty(value = "线路名称")
|
||||
private String lineName = "";
|
||||
@ApiModelProperty(value = "运距(千米)")
|
||||
|
||||
private BigDecimal haulDistance = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "装货地名称")
|
||||
|
||||
private String loadingName = "";
|
||||
@ApiModelProperty(value = "装货地县区编码")
|
||||
private String loadingAreaId = "";
|
||||
@ApiModelProperty(value = "装货地详细地址")
|
||||
|
||||
private String loadingAddress = "";
|
||||
@ApiModelProperty(value = "装货地经度")
|
||||
private String loadingLongitude = "";
|
||||
@ApiModelProperty(value = "装货地纬度")
|
||||
private String loadingLatitude = "";
|
||||
@ApiModelProperty(value = "装货单位")
|
||||
private String loadingUnit = "";
|
||||
@ApiModelProperty(value = "发货人姓名")
|
||||
|
||||
private String freighterName = "";
|
||||
@ApiModelProperty(value = "装货电话")
|
||||
|
||||
private String loadingPhone = "";
|
||||
@ApiModelProperty(value = "装货时间日期(年月日)")
|
||||
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date loadingDate;
|
||||
@ApiModelProperty(value = "装货时间(上午、下午、24小时)")
|
||||
|
||||
private String loadingTime = "";
|
||||
@ApiModelProperty(value = "装货时间id")
|
||||
private String loadingTimeId;
|
||||
@ApiModelProperty(value = "卸货地名称")
|
||||
|
||||
private String unloadName = "";
|
||||
@ApiModelProperty(value = "卸货地县区编码")
|
||||
private String unloadAreaId = "";
|
||||
@ApiModelProperty(value = "卸货地详细地址")
|
||||
|
||||
private String unloadAddress = "";
|
||||
@ApiModelProperty(value = "卸货地经度")
|
||||
private String unloadLongitude = "";
|
||||
@ApiModelProperty(value = "卸货地纬度")
|
||||
private String unloadLatitude = "";
|
||||
@ApiModelProperty(value = "卸货单位")
|
||||
private String unloadUnit = "";
|
||||
@ApiModelProperty(value = "收货人姓名")
|
||||
|
||||
private String dischargerName = "";
|
||||
@ApiModelProperty(value = "卸货电话")
|
||||
|
||||
private String unloadPhone = "";
|
||||
@ApiModelProperty(value = "卸货时间日期(年月日)")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date unloadingData;
|
||||
@ApiModelProperty(value = "卸货时间(上午、下午、24小时)")
|
||||
private String unloadingTime = "";
|
||||
@ApiModelProperty(value = "卸货时间Id")
|
||||
private String unloadingTimeId = "";
|
||||
@ApiModelProperty(value = "货物名称ID")
|
||||
private String goodsNameId = "";
|
||||
@ApiModelProperty(value = "货物大类型")
|
||||
private String goodsType="";
|
||||
@ApiModelProperty(value = "货物小类型")
|
||||
private String goodsName="";
|
||||
@ApiModelProperty(value = "重量小(吨)")
|
||||
private BigDecimal weightMin = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "重量大(吨)")
|
||||
private BigDecimal weightMax = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "货物数量单位(吨/方/件)")
|
||||
|
||||
private String goodsUntis = "";
|
||||
@ApiModelProperty(value = "货物数量单位(吨/方/件)ID")
|
||||
private String goodsUntisId = "";
|
||||
@ApiModelProperty(value = "配载方式ID(0-数量,1-车次)")
|
||||
private Integer transportationModeId =0;
|
||||
@ApiModelProperty(value = "是否接单(0-否,1-是)")
|
||||
private Integer isOrder = 0;
|
||||
@ApiModelProperty(value = "配载方式名称")
|
||||
|
||||
private String transportationName= "";
|
||||
@ApiModelProperty(value = "现已承运车次")
|
||||
private Integer realTrainNumber = 0;
|
||||
@ApiModelProperty(value = "车型车长ID")
|
||||
private String carType = "";
|
||||
@ApiModelProperty(value = "车型车长名称")
|
||||
|
||||
private String carTypeName="";
|
||||
@ApiModelProperty(value = "指定司机ID")
|
||||
private String appointDriverId = "";
|
||||
@ApiModelProperty(value = "指定司机姓名")
|
||||
private String appointDriver = "";
|
||||
@ApiModelProperty(value = "指定司机电话")
|
||||
private String appointDriverPhone = "";
|
||||
@ApiModelProperty(value = "指定司机车牌号")
|
||||
private String appointDriverLicense = "";
|
||||
@ApiModelProperty(value = "服务要求ID")
|
||||
private String serviceRequireId = "";
|
||||
@ApiModelProperty(value = "服务要求名称")
|
||||
|
||||
private String serviceRequire = "";
|
||||
@ApiModelProperty(value = "备注")
|
||||
|
||||
private String remarks = "";
|
||||
@ApiModelProperty(value = "上游客户ID")
|
||||
private String upstreamCustomersId = "";
|
||||
@ApiModelProperty(value = "上游客户姓名")
|
||||
private String upstreamCustomersName = "";
|
||||
@ApiModelProperty(value = "上游客户电话")
|
||||
private String upstreamCustomersPhone = "";
|
||||
@ApiModelProperty(value = "运单类型(0-企业普货、1-企业批量货、2-撮合货、3-客服运单、4-线下运单)")
|
||||
private Integer waybillType ;
|
||||
@ApiModelProperty(value = "运单类型(0-企业普货、1-企业批量货、2-撮合货、3-客服运单、4-线下运单)")
|
||||
private String waybillTypeName = "";
|
||||
@ApiModelProperty(value = "运单来源(0-后台发布、1-app发布、2-导入)")
|
||||
private Integer waybillFrom;
|
||||
@ApiModelProperty(value = "定金")
|
||||
private BigDecimal earnestMoney = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "确认协议重量和")
|
||||
private BigDecimal agreementWeights = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "装货重量和")
|
||||
private BigDecimal loadingNumbers = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "货源是否关闭(0-否,1-是)")
|
||||
private Integer isSource = 0;
|
||||
@ApiModelProperty(value = "货源关闭时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date sourceCloseTime;
|
||||
@ApiModelProperty(value = "货源关闭人用户ID")
|
||||
private String executorId = "";
|
||||
@ApiModelProperty(value = "是否删除(0-否,1-是)")
|
||||
private Integer isDelete = 0;
|
||||
@ApiModelProperty(value = "运输单号")
|
||||
private String waybillNumber="";
|
||||
@ApiModelProperty(value = "公司名称")
|
||||
private String companyName="";
|
||||
@ApiModelProperty(value = "姓名")
|
||||
|
||||
private String shipperName="";
|
||||
@ApiModelProperty(value = "电话")
|
||||
private String shipperPhone="";
|
||||
@ApiModelProperty(value = "用户ID")
|
||||
private String shipperId = "";
|
||||
@ApiModelProperty(value = "运输司机ID")
|
||||
private String transportationDriverId ="";
|
||||
@ApiModelProperty(value = "运输司机姓名")
|
||||
private String transportationDriver ="";
|
||||
@ApiModelProperty(value = "运输司机电话")
|
||||
private String transportationPhone ="";
|
||||
@ApiModelProperty(value = "运输车辆ID")
|
||||
private String transportationCarId ="";
|
||||
@ApiModelProperty(value = "运输车辆车牌号")
|
||||
private String transportationPlate = "";
|
||||
@ApiModelProperty(value = "货源单创建企业ID")
|
||||
private String createCompanyId = "";
|
||||
@ApiModelProperty(value = "期望运费")
|
||||
|
||||
private BigDecimal freightHope = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "运输状态(0-待确认,1-运输中,2-已完成,3-待评价,4-已评价,5-已取消,6-已关闭)")
|
||||
private Integer waybillStatus;
|
||||
@ApiModelProperty(value = "承运货物数量")
|
||||
private String loadingNumber ="";
|
||||
@ApiModelProperty(value = "车队名称")
|
||||
private String motorcadeName="";
|
||||
@ApiModelProperty(value = "货物类型ID")
|
||||
private String goodsTypeId="";
|
||||
@ApiModelProperty(value = "创建人手机号")
|
||||
private String phone="";
|
||||
@ApiModelProperty(value = "创建人名称")
|
||||
private String realname="";
|
||||
@ApiModelProperty(value = "货运线路(装货市县)")
|
||||
private String lineTitleLeft="";
|
||||
@ApiModelProperty(value = "货运线路(卸货市县)")
|
||||
private String lineTitleRight="";
|
||||
@ApiModelProperty(value = "发货时间距当前时间差")
|
||||
private String daysAgo="";
|
||||
@ApiModelProperty(value = "交易量")
|
||||
private String transportCount = "";
|
||||
@ApiModelProperty(value = "好评率")
|
||||
private String praiseNumber ="100%";
|
||||
@ApiModelProperty(value = "装货时间日期(年月日)")
|
||||
private String loadingDateDay="";
|
||||
@ApiModelProperty(value = "装货时间日期(年-月-日)")
|
||||
private String loadingDateTime="";
|
||||
@ApiModelProperty(value = "卸货时间日期(年-月-日)")
|
||||
private String unloadingDateTime="";
|
||||
@ApiModelProperty(value = "卸货时间日期(年月日)")
|
||||
private String unloadingDateDay="";
|
||||
@ApiModelProperty(value = "是否为常发货源(0-否,1-是)")
|
||||
private Integer isCommon = 0;
|
||||
@ApiModelProperty(value = "审核状态")
|
||||
private String auditStatus;
|
||||
@ApiModelProperty(value = "审核状态中文")
|
||||
private String auditStatusName ="";
|
||||
@ApiModelProperty(value = "运输单号")
|
||||
private String transportationNumber="";
|
||||
@ApiModelProperty(value = "发货运费")
|
||||
private BigDecimal deliveryFreight = new BigDecimal("0");
|
||||
@ApiModelProperty(value = "审核人手机号")
|
||||
private String auditByPhone="";
|
||||
@ApiModelProperty(value = "审核人")
|
||||
private String auditBy="";
|
||||
@ApiModelProperty(value = "审核人名称")
|
||||
private String auditByName="";
|
||||
@ApiModelProperty(value = "审核人公司名称")
|
||||
private String auditByCompanyName="";
|
||||
@ApiModelProperty(value = "所属公司名称")
|
||||
private String platformCompanyName;
|
||||
@ApiModelProperty(value = "运费单价(元/吨)")
|
||||
private BigDecimal transportationUnitPrice;
|
||||
@ApiModelProperty(value = "赫达订单号")
|
||||
private String orderNumber="";
|
||||
@ApiModelProperty(value = "是否长期货源:0-否,1-是")
|
||||
private Integer isLongOrder = 0;
|
||||
@ApiModelProperty(value = "微信小程序图片地址")
|
||||
private String wxaQrcode="";
|
||||
@ApiModelProperty(value = "微信小程序AppID")
|
||||
private String wxaAppID="";
|
||||
@ApiModelProperty(value = "代运营人员用户ID")
|
||||
private String orderAgentUserId="";
|
||||
@ApiModelProperty(value = "代运营人员名称")
|
||||
private String orderAgentUserName="";
|
||||
@ApiModelProperty(value = "代运营人员手机")
|
||||
private String orderAgentUserPhone="";
|
||||
|
||||
@ApiModelProperty(value = "公司经营模式(0-总公司,1-总+分公司)")
|
||||
private Integer isTypeInsuranceUse = 0;
|
||||
@ApiModelProperty(value = "指定平台公司")
|
||||
private String appointCompanyId;
|
||||
@ApiModelProperty(value = "指定平台公司名称")
|
||||
private String appointCompanyName;
|
||||
@ApiModelProperty(value = "服务费")
|
||||
private String serviceRate;
|
||||
@ApiModelProperty(value = "指定货主编号")
|
||||
private String appointShipperId;
|
||||
@ApiModelProperty(value = "指定货主")
|
||||
private String appointShipper;
|
||||
@ApiModelProperty(value = "结算方式:1-按趟结算,2-按数量结算")
|
||||
private Integer radioValue;
|
||||
|
||||
@ApiModelProperty(value = "指定平台公司名称")
|
||||
private String appointCompany;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "短驳装货地址")
|
||||
private String shortLoadingAddress;
|
||||
|
||||
@ApiModelProperty(value = "短驳卸货地址")
|
||||
private String shortUnloadAddress;
|
||||
|
||||
@ApiModelProperty(value = "指定设备号")
|
||||
private String appointVehicleDevice;
|
||||
|
||||
@ApiModelProperty(value = "车牌号")
|
||||
private String vehicleLicenseNumber;
|
||||
|
||||
@ApiModelProperty(value = "司机")
|
||||
private String driverName;
|
||||
|
||||
@ApiModelProperty(value = "指定车辆")
|
||||
private String appointVehicle;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "发布货源方式 0-未指定;1-企业货源;2-平台货源")
|
||||
private Integer publishOrderType;
|
||||
|
||||
@ApiModelProperty(value = "剩余吨数")
|
||||
private BigDecimal surplusTonnage;
|
||||
|
||||
*/
|
||||
/**是否开启路耗(0-否 1-是)*//*
|
||||
|
||||
@ApiModelProperty(value = "是否开启路耗(0-否 1-是)")
|
||||
@Excel(name = "是否开启路耗(0-否 1-是)", width = 15)
|
||||
private Integer isRoadLoss;
|
||||
*/
|
||||
/**货物价值(元/吨)*//*
|
||||
|
||||
@ApiModelProperty(value = "货物价值(元/吨)")
|
||||
@Excel(name = "货物价值(元/吨)", width = 15)
|
||||
private BigDecimal goodsValue=BigDecimal.ZERO;
|
||||
*/
|
||||
/**路耗模式(0-按比例% 1-按数量(吨))*//*
|
||||
|
||||
@ApiModelProperty(value = "路耗模式(0-按比例% 1-按数量(吨))")
|
||||
@Excel(name = "路耗模式(0-按比例% 1-按数量(吨))", width = 15)
|
||||
private Integer roadLossMode;
|
||||
*/
|
||||
/**路耗结算方式(0-无 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)*//*
|
||||
|
||||
@ApiModelProperty(value = "路耗结算方式(0-无 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)")
|
||||
@Excel(name = "路耗结算方式(0-无 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)", width = 15)
|
||||
private Integer roadLossSettlementMethod;
|
||||
|
||||
*/
|
||||
/**允许货物亏损*//*
|
||||
|
||||
@ApiModelProperty(value = "允许货物亏损(吨或%)")
|
||||
@Excel(name = "允许货物亏损(吨或%)", width = 15)
|
||||
private BigDecimal allowableLoss=BigDecimal.ZERO;
|
||||
|
||||
*/
|
||||
/**超出亏损扣除金额(元/吨)*//*
|
||||
|
||||
@ApiModelProperty(value = "超出亏损扣除金额(元/吨)")
|
||||
@Excel(name = "超出亏损扣除金额(元/吨)", width = 15)
|
||||
private BigDecimal lossDeductionAmount=BigDecimal.ZERO;
|
||||
@ApiModelProperty(value = "上游客户id")
|
||||
@Excel(name = "上游客户id", width = 15)
|
||||
private String upClientId="";
|
||||
|
||||
@ApiModelProperty(value = "货单二维码图片地址")
|
||||
private String qrCodeImgUrl;
|
||||
|
||||
*/
|
||||
/**回单付金额*//*
|
||||
|
||||
@ApiModelProperty(value = "回单付金额")
|
||||
@Excel(name = "回单付金额", width = 15)
|
||||
private BigDecimal receiptPaymentAmount=BigDecimal.ZERO;
|
||||
*/
|
||||
/**预付运费金额*//*
|
||||
|
||||
@ApiModelProperty(value = "预付现金金额")
|
||||
@Excel(name = "预付现金金额", width = 15)
|
||||
private BigDecimal cashAdvance=BigDecimal.ZERO;
|
||||
*/
|
||||
/**到付运费金额*//*
|
||||
|
||||
@ApiModelProperty(value = "到付运费金额")
|
||||
@Excel(name = "到付运费金额", width = 15)
|
||||
private BigDecimal freightAmount=BigDecimal.ZERO;
|
||||
*/
|
||||
/**预付平台油卡金额*//*
|
||||
|
||||
@ApiModelProperty(value = "预付平台油卡金额")
|
||||
@Excel(name = "预付平台油卡金额", width = 15)
|
||||
private BigDecimal oilCardOnline=BigDecimal.ZERO;
|
||||
@ApiModelProperty(value = "是否协议费用生成:0否 1是")
|
||||
private Integer isAutoGenerateProtocol;
|
||||
|
||||
*/
|
||||
/**单车重量*//*
|
||||
|
||||
@ApiModelProperty(value = "单车重量",required = true)
|
||||
private BigDecimal singleVehicleWeight;
|
||||
|
||||
*/
|
||||
/**单车总费用*//*
|
||||
|
||||
@ApiModelProperty(value = "单车总费用")
|
||||
@Excel(name = "单车总费用", width = 15)
|
||||
private BigDecimal freightGross=BigDecimal.ZERO;
|
||||
|
||||
@ApiModelProperty(value = "运费抹零 0-不抹零 ,1-抹零小数位,2-抹零个位,3-抹零十位")
|
||||
private Integer isFreightNullification;
|
||||
|
||||
@ApiModelProperty(value = "运费抹零 0-不抹零 ,1-抹零小数位,2-抹零个位,3-抹零十位")
|
||||
private String isFreightNullificationName;
|
||||
|
||||
@ApiModelProperty(value = "是否允许接多单:0否 1是")
|
||||
private Integer isMultipleOrdersAllowed;
|
||||
|
||||
@ApiModelProperty(value = "发货备注")
|
||||
private String shippingNote;
|
||||
|
||||
@ApiModelProperty(value = "绑卡状态 0-未绑卡 1-已绑卡未完成回填 2-已绑卡已完成回填")
|
||||
private Integer strappedStatus=2;
|
||||
|
||||
@ApiModelProperty("应收结算类型:1-月结,2-现结")
|
||||
private Integer receivableType;
|
||||
|
||||
@ApiModelProperty("项目表ID")
|
||||
private Long projectManagementId;
|
||||
|
||||
@ApiModelProperty(value = "接单司机ID")
|
||||
private String orderDriverId;
|
||||
|
||||
@ApiModelProperty(value = "货物数量")
|
||||
private String goodsQuantity;
|
||||
@ApiModelProperty(value = "货物数量单位code")
|
||||
private String goodsQuantityUnitId;
|
||||
@ApiModelProperty(value = "货物数量单位")
|
||||
private String goodsQuantityUnit;
|
||||
|
||||
@ApiModelProperty(value = "运单数量")
|
||||
private Integer transportNoteCount=0;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "常用货主id")
|
||||
private String topOrder;
|
||||
|
||||
|
||||
//=================批量货派单相关=============================
|
||||
@ApiModelProperty(value = "需求车次")
|
||||
private Integer demandTrainNumber;
|
||||
@ApiModelProperty(value = "承运车次默认0")
|
||||
private Integer carriageNumber;
|
||||
@ApiModelProperty(value = "剩余需求车次")
|
||||
private Integer remainingDemandTrainNumber;
|
||||
|
||||
*/
|
||||
/**货物重量*//*
|
||||
|
||||
@ApiModelProperty(value = "货物重量")
|
||||
private BigDecimal goodsWeight;
|
||||
@ApiModelProperty(value = "货源剩余货物数量")
|
||||
private BigDecimal residueGoodsWeight;
|
||||
@ApiModelProperty(value = "承运货物数量")
|
||||
private BigDecimal transportGoodsWeight;
|
||||
|
||||
//=================竞价相关=============================
|
||||
@ApiModelProperty(value = "查看报价数量")
|
||||
private Integer quotationQuantity = 0;
|
||||
@ApiModelProperty(value = "运单模式(0-普通模式,1-竞价模式)")
|
||||
private Integer waybillMode;
|
||||
@ApiModelProperty(value = "竞价截止时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date latestBiddingTime;
|
||||
@ApiModelProperty(value = "预设竞标价")
|
||||
private BigDecimal presetPrice;
|
||||
@ApiModelProperty(value = "竞价单位(元/车,元/吨)")
|
||||
private String biddingUnit;
|
||||
@ApiModelProperty(value = "最高心理价")
|
||||
private BigDecimal highestPrice;
|
||||
|
||||
@ApiModelProperty(value = "订单状态(1-未审核,2-未通过,3-进行中,4-已完成,5-已关闭)")
|
||||
private Integer orderStatus;
|
||||
|
||||
@ApiModelProperty(value = "货源对应运单数量")
|
||||
private Integer transportNum = 0;
|
||||
@ApiModelProperty(value = "货源对应货运单数量")
|
||||
private Integer truckOrderCount = 0;
|
||||
@ApiModelProperty(value = "订单模式(0-手动竞价,1-自动竞价,2-普通模式,其他-全部)")
|
||||
private Integer orderMode;
|
||||
@ApiModelProperty(value = "评标类型(0-自动评标,1-手动评标)")
|
||||
private Integer bidEvaluationType;
|
||||
|
||||
@ApiModelProperty(value = "订单类型:0-自有订单,1-tms订单")
|
||||
private Integer orderType;
|
||||
|
||||
@ApiModelProperty(value = "多装多卸类型")
|
||||
private String layType;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "拼单类型(0-不拼单(主单),1-拼单-子单,2-拼单-合单)")
|
||||
private Integer splicingOrderType;
|
||||
|
||||
@ApiModelProperty(value = "拼单发布状态(0-否,1-是)")
|
||||
private Integer splicingStatus;
|
||||
|
||||
@ApiModelProperty(value = "拼单主单id")
|
||||
private String mainOrderId;
|
||||
|
||||
@ApiModelProperty(value = "拼单主单号")
|
||||
private String mainOrderNum;
|
||||
|
||||
@ApiModelProperty(value = "拼单合单id")
|
||||
private String mergeOrderId;
|
||||
|
||||
@ApiModelProperty(value = "拼单合单号")
|
||||
private String mergeOrderNum;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "来源系统")
|
||||
private String orderSource;
|
||||
|
||||
@ApiModelProperty(value = "通知单号")
|
||||
private String noticeNumber;
|
||||
|
||||
@ApiModelProperty(value = "司机税率")
|
||||
private BigDecimal driverTaxRate;
|
||||
|
||||
@ApiModelProperty(value = "tms到付运费金额")
|
||||
private BigDecimal tmsFreightAmount;
|
||||
|
||||
@ApiModelProperty(value = "订单其他信息")
|
||||
private Map<String,String> otherOrderInfo;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty(value = "订单类型")
|
||||
private Integer orderShippingType;
|
||||
@ApiModelProperty(value = "订单类型")
|
||||
private String orderShippingName;
|
||||
@ApiModelProperty(value = "付款方")
|
||||
private String payerTypeName;
|
||||
|
||||
@ApiModelProperty(value = "付款方类型(0-委托方,1-收货方)")
|
||||
@Excel(name = "付款方类型(0-委托方,1-收货方)", width = 15)
|
||||
private Integer payerType;
|
||||
|
||||
@ApiModelProperty(value = "整机编号")
|
||||
private String machineNumber;
|
||||
|
||||
@ApiModelProperty(value = "收货方")
|
||||
private String recipientName;
|
||||
@ApiModelProperty(value = "委托方")
|
||||
private String appointDriverEnterprise;
|
||||
@ApiModelProperty(value = "收货方id")
|
||||
private String recipientId;
|
||||
@ApiModelProperty(value = "委托方id")
|
||||
private String appointDriverEnterpriseId;
|
||||
|
||||
@ApiModelProperty(value = "数字物流平台用户Id")
|
||||
private Long szwlUserId;
|
||||
|
||||
@ApiModelProperty("运费单价")
|
||||
private BigDecimal freightUnitPrice;
|
||||
|
||||
@ApiModelProperty(value = "信息费")
|
||||
private BigDecimal infoFee;
|
||||
|
||||
@ApiModelProperty(value = "信息费状态")
|
||||
private BigDecimal infoFeeStatus;
|
||||
|
||||
@ApiModelProperty(value = "信息费应付单据号")
|
||||
private String infoFeeDocumentNumber;
|
||||
|
||||
@ApiModelProperty(value = "车辆类型Id")
|
||||
private String vehicleTypeId;
|
||||
|
||||
@ApiModelProperty(value = "承运人Id(订单为济南专线使用)")
|
||||
private String carrier;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "第三方订单号")
|
||||
private String thirdPartyOrderNumber;
|
||||
@ApiModelProperty(value = "电子回单状态(0-无状态 1-未上传 2-已上传 3-已拒绝 4-已确认)")
|
||||
private Integer receiptTotalStatus;
|
||||
@ApiModelProperty(value = "已收运费")
|
||||
private BigDecimal collectedFreight;
|
||||
@ApiModelProperty(value = "未收运费")
|
||||
private BigDecimal uncollectedFreight;
|
||||
@ApiModelProperty(value = "订单结算状态:1未出账、2已出账、3部分结算、4已结算")
|
||||
private Integer settlementStatus;
|
||||
@ApiModelProperty(value = "订单运费结算时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date settlementTime;
|
||||
@ApiModelProperty(value = "运单发票开具状态(0-未索取,1-已索取,2-已开票,3-部分索取)")
|
||||
private Integer isInvoice;
|
||||
@ApiModelProperty(value = "签收时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date signTime;
|
||||
@ApiModelProperty(value = "创建人")
|
||||
private String realCreateName;
|
||||
|
||||
@ApiModelProperty(value = "主运单单号")
|
||||
private String mainOrderNumber;
|
||||
@ApiModelProperty(value = "信息费账单号")
|
||||
private String recordNumber;
|
||||
@ApiModelProperty(value = "信息费收款方")
|
||||
private String infoFeePayee;
|
||||
@ApiModelProperty(value = "信息费收款方方式")
|
||||
private Integer infoFeePayeeType;
|
||||
|
||||
@ApiModelProperty(value = "竞价状态 0-竞价中,1-已完成,2-已关闭")
|
||||
private Integer biddingStatus;
|
||||
|
||||
@ApiModelProperty(value = "目的地")
|
||||
private String destination;
|
||||
|
||||
@ApiModelProperty("运费")
|
||||
private BigDecimal freightCharges;
|
||||
|
||||
@ApiModelProperty(value = "开票时间")
|
||||
@Excel(name = "开票时间", width = 25, format = "yyyy-MM-dd HH:mm:ss")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date invoiceMakeTime;
|
||||
|
||||
@ApiModelProperty("业务员ID")
|
||||
private String salesmanId;
|
||||
|
||||
@ApiModelProperty("业务员ID")
|
||||
private String salesmanName;
|
||||
|
||||
@ApiModelProperty(value = "组织id")
|
||||
private String orgId;
|
||||
|
||||
@ApiModelProperty(value = "所属组织")
|
||||
@Excel(name = "所属组织", width = 15)
|
||||
private String orgName;
|
||||
|
||||
@ApiModelProperty("是否报关(0:否,1:是)")
|
||||
private Integer isDeclare;
|
||||
|
||||
@ApiModelProperty("线路")
|
||||
private String route;
|
||||
|
||||
@ApiModelProperty("柜类型")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("柜类型名称")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("卡类型")
|
||||
private String cardType;
|
||||
|
||||
@ApiModelProperty("卡类型名称")
|
||||
private String cardTypeName;
|
||||
|
||||
@ApiModelProperty("外来柜号")
|
||||
private String externalContainerNo;
|
||||
|
||||
@ApiModelProperty("中转地")
|
||||
private String transitPlace;
|
||||
|
||||
@ApiModelProperty("托运人ID")
|
||||
private String shipper;
|
||||
|
||||
@ApiModelProperty("托运人ID")
|
||||
private String customsShipper;
|
||||
|
||||
@ApiModelProperty("托运人电话")
|
||||
private String customsShipperTel;
|
||||
|
||||
@ApiModelProperty("卸货单位")
|
||||
private String unloadingCompany;
|
||||
|
||||
@ApiModelProperty("合同编号")
|
||||
private String contractNo;
|
||||
|
||||
@ApiModelProperty("运费")
|
||||
private BigDecimal freightFee;
|
||||
|
||||
@ApiModelProperty("卸货费")
|
||||
private BigDecimal unloadingFee;
|
||||
|
||||
@ApiModelProperty("报关费")
|
||||
private BigDecimal customsFee;
|
||||
|
||||
@ApiModelProperty("差货费")
|
||||
private BigDecimal shortageFee;
|
||||
|
||||
@ApiModelProperty("杂费")
|
||||
private BigDecimal miscellaneousFee;
|
||||
|
||||
@ApiModelProperty("其他费用")
|
||||
private BigDecimal otherFee;
|
||||
|
||||
@ApiModelProperty("滞车费")
|
||||
private BigDecimal detentionFee;
|
||||
|
||||
@ApiModelProperty("税率")
|
||||
private BigDecimal taxRate;
|
||||
|
||||
@ApiModelProperty("结算币种")
|
||||
private String settlementCurrency;
|
||||
|
||||
@ApiModelProperty("体积")
|
||||
private BigDecimal volume;
|
||||
|
||||
@ApiModelProperty("内容详情")
|
||||
private String detailContent;
|
||||
|
||||
@ApiModelProperty("报关线路")
|
||||
private String customsRoute;
|
||||
|
||||
@ApiModelProperty("报关关口")
|
||||
private String customsPort;
|
||||
|
||||
@ApiModelProperty("报关联系人")
|
||||
private String customsContact;
|
||||
|
||||
@ApiModelProperty("报关联系人电话")
|
||||
private String customsContactPhone;
|
||||
|
||||
@ApiModelProperty("报关备注")
|
||||
private String customsRemark;
|
||||
@ApiModelProperty(value = "单据日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date documentDate;
|
||||
|
||||
@ApiModelProperty("组织ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("上级组织ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
//订单审核相关
|
||||
@ApiModelProperty("审核业务员ID")
|
||||
private String auditSalesmanId;
|
||||
@ApiModelProperty("审核业务员")
|
||||
private String auditSalesmanName;
|
||||
@ApiModelProperty("业务确认状态")
|
||||
private Integer businessConfirmStatus;
|
||||
@ApiModelProperty("业务审核状态")
|
||||
private Integer businessAuditStatus;
|
||||
@ApiModelProperty("确认意见")
|
||||
private String opinion;
|
||||
@ApiModelProperty("业务主管id")
|
||||
private String businessManagerId;
|
||||
@ApiModelProperty("业务主管名称")
|
||||
private String businessManagerName;
|
||||
@ApiModelProperty("审核意见")
|
||||
private String auditOpinion;
|
||||
|
||||
|
||||
@ApiModelProperty("费用科目明细")
|
||||
private String tmsOrderAccountListJsonStr;
|
||||
|
||||
}
|
||||
*/
|
||||
@@ -37,5 +37,7 @@ public class UserDTO extends BaseVOEntity {
|
||||
private Integer userStatus;
|
||||
@ApiModelProperty(name = "业务类型:0.无状态,1.托运业务,2.承运业务,3.托运、承运业务,4.无业务,5.不确定业务默认为托运业务")
|
||||
private Integer businessType;
|
||||
@ApiModelProperty(name = "用户角色")
|
||||
private String userRole;
|
||||
|
||||
}
|
||||
|
||||
+5
@@ -219,6 +219,11 @@ public class RemoteSystemFeignFallbackFactory implements FallbackFactory<SystemS
|
||||
return AjaxResult.error("查询关联仓库列表根据关联id查询失败");
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult queryListCorrelationId(Long warehouseId) {
|
||||
return AjaxResult.error("查询仓库关联的用户ID集合失败");
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult getSubInfoByCode(String subjectCode) {
|
||||
return AjaxResult.error("获取科目信息失败" + throwable.getMessage());
|
||||
|
||||
+13
-1
@@ -14,6 +14,7 @@ import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.cloud.openfeign.FallbackFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestBody;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
@@ -78,11 +79,17 @@ public class RemoteUserFeignFallbackFactory implements FallbackFactory<UserServi
|
||||
return AjaxResult.error("根据车辆id查询司机失败:" + throwable.getMessage());
|
||||
}
|
||||
|
||||
@GetMapping("/userApi/getInfo/{userId}")
|
||||
@Override
|
||||
public AjaxResult getInfo(Long userId) {
|
||||
return AjaxResult.error("根据用户ID查询用户详细信息失败:" + throwable.getMessage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult getInfoByName(String userName) {
|
||||
return AjaxResult.error("根据用户userName查询用户详细信息失败:" + throwable.getMessage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult bindDriverShipList(Long vehicleId) {
|
||||
return AjaxResult.error("查询车辆绑定的承运人列表信息失败:" + throwable.getMessage());
|
||||
@@ -169,6 +176,11 @@ public class RemoteUserFeignFallbackFactory implements FallbackFactory<UserServi
|
||||
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult<?> getShipperByUserId(Long userId) {
|
||||
return AjaxResult.error("查询失败" + throwable.getMessage());
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
}
|
||||
+24
@@ -12,6 +12,7 @@ import com.mhd.common.core.domain.entity.R;
|
||||
import com.mhd.common.core.domain.entity.SysConfigSwitch;
|
||||
import com.mhd.common.core.domain.entity.TmsOrder;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import com.mhd.common.core.utils.sms.Result;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.WlhyServiceFeign;
|
||||
import com.mhd.system.api.domain.*;
|
||||
@@ -211,6 +212,14 @@ public class RemoteWlhyFallbackFactory implements FallbackFactory<WlhyServiceFei
|
||||
return res;
|
||||
}
|
||||
|
||||
@Override
|
||||
public R<TmsInvoiceListDetailsVO> selectInvoiceListById(String id) {
|
||||
R<TmsInvoiceListDetailsVO> res = new R<>();
|
||||
res.setMsg("获取发票信息失败"+cause.getMessage());
|
||||
res.setCode(R.FAIL);
|
||||
return res;
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult payCallback(List<TmsPayCallbackDTO> tmsPayCallbackList) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
@@ -509,6 +518,21 @@ public class RemoteWlhyFallbackFactory implements FallbackFactory<WlhyServiceFei
|
||||
res.setCode(R.FAIL);
|
||||
return res;
|
||||
}
|
||||
|
||||
@Override
|
||||
public Result<?> queryById(String id) {
|
||||
return null;
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult add(TmsOrderAddDTO tmsOrderAddDTO) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult cancelIssueDocuments(String executeOrderId) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
+8
@@ -5,6 +5,7 @@ import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.system.api.WlhyServiceFeign;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.MaterialBaseInfoFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.domain.NoticeOrderDTO;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
@@ -12,6 +13,8 @@ import org.springframework.cloud.openfeign.FallbackFactory;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
/**
|
||||
* @author ZhouGY
|
||||
* @title RemoteWmsFallbackFactory
|
||||
@@ -46,6 +49,11 @@ public class RemoteWmsFallbackFactory implements FallbackFactory<WmsServiceFeign
|
||||
public AjaxResult stockOutOrInInsert(NoticeOrderDTO noticeOrderDTO) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
}
|
||||
|
||||
@Override
|
||||
public AjaxResult materialInventoryApiListAll(MaterialInventoryDTO materialInventoryDTO) {
|
||||
return AjaxResult.error(cause.getMessage());
|
||||
}
|
||||
};
|
||||
}
|
||||
}
|
||||
|
||||
@@ -38,6 +38,10 @@ public class LoginUser implements Serializable
|
||||
* 用户名
|
||||
*/
|
||||
private String username;
|
||||
/**
|
||||
* 用户名
|
||||
*/
|
||||
private String realname;
|
||||
|
||||
/**
|
||||
* 登录时间
|
||||
|
||||
@@ -12,19 +12,18 @@ spring:
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
server-addr: 10.33.0.129:6010
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
config:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
server-addr: 10.33.0.129:6010
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
group: DEFAULT_GROUP # 默认分组就是DEFAULT_GROUP,如果使用默认分组可以不配置
|
||||
file-extension: yml #默认properties
|
||||
# 共享配置
|
||||
shared-configs:
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
@@ -156,7 +156,7 @@
|
||||
<dependency>
|
||||
<groupId>org.projectlombok</groupId>
|
||||
<artifactId>lombok</artifactId>
|
||||
<version>1.18.4</version>
|
||||
<version>1.18.22</version>
|
||||
</dependency>
|
||||
|
||||
<dependency>
|
||||
|
||||
+75
@@ -0,0 +1,75 @@
|
||||
package com.mhd.common.core.domain.dto;
|
||||
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 【请填写功能名称】对象 reconciliation_account
|
||||
*
|
||||
* @author gen
|
||||
* @date 2026-01-14
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ReconciliationAccountDTO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("$column.columnComment")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("所属组织")
|
||||
@Excel(name = "所属组织")
|
||||
private String orgName;
|
||||
|
||||
@ApiModelProperty("组织ID")
|
||||
@Excel(name = "组织ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("一级组织ID")
|
||||
@Excel(name = "一级组织ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("应收账单id")
|
||||
@Excel(name = "应收账单id")
|
||||
private Long reconciliationId;
|
||||
|
||||
@ApiModelProperty("科目id")
|
||||
@Excel(name = "科目id")
|
||||
private Long accountId;
|
||||
|
||||
@ApiModelProperty("科目收支类型(1-应收,2-应付")
|
||||
@Excel(name = "科目收支类型", readConverterExp = "科目收支类型(1-应收,2-应付")
|
||||
private Long accountType;
|
||||
|
||||
@ApiModelProperty("科目编码")
|
||||
@Excel(name = "科目编码")
|
||||
private String subjectCode;
|
||||
|
||||
@ApiModelProperty("科目名称")
|
||||
@Excel(name = "科目名称")
|
||||
private String subjectName;
|
||||
|
||||
@ApiModelProperty("科目费率")
|
||||
@Excel(name = "科目费率")
|
||||
private BigDecimal rate;
|
||||
|
||||
@ApiModelProperty("金额")
|
||||
@Excel(name = "金额")
|
||||
private BigDecimal amount;
|
||||
|
||||
|
||||
@ApiModelProperty(name = "组织ID集合")
|
||||
private List<Long> organizationIdList;
|
||||
|
||||
@ApiModelProperty(name = "权限菜单ID")
|
||||
private Long permissionMenuId;
|
||||
}
|
||||
+8
@@ -22,6 +22,11 @@ import java.util.List;
|
||||
public class ReconciliationDTO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("创建时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
|
||||
@ApiModelProperty("对账单表id")
|
||||
private Long reconciliationId;
|
||||
|
||||
@@ -233,4 +238,7 @@ public class ReconciliationDTO extends BaseVOEntity{
|
||||
@ApiModelProperty("nc同步状态 0-未同步 1-已同步")
|
||||
private Integer skSynchronousStatus;
|
||||
|
||||
@ApiModelProperty(value = "账单科目明细")
|
||||
public List<ReconciliationAccountDTO> reconciliationAccountDTOList;
|
||||
|
||||
}
|
||||
|
||||
+49
@@ -0,0 +1,49 @@
|
||||
package com.mhd.common.core.domain.dto.wlhy;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* TODO 多装多卸地址DTO
|
||||
*
|
||||
* @author LianZhijian
|
||||
* @version 1.0
|
||||
* @date 2022-12-16 14:23:22
|
||||
*/
|
||||
@Data
|
||||
public class TmsAddressMultiDTO {
|
||||
|
||||
@ApiModelProperty(value = "装卸货地县区编码")
|
||||
private String areaCode;
|
||||
@ApiModelProperty(value = "装卸货地名称")
|
||||
private String areaName;
|
||||
@ApiModelProperty(value = "装卸货详细地址")
|
||||
private String address;
|
||||
@ApiModelProperty(value = "装卸货地经度")
|
||||
private String longitude;
|
||||
@ApiModelProperty(value = "装货地纬度")
|
||||
private String latitude;
|
||||
@ApiModelProperty(value = "装卸货联系人")
|
||||
private String contactName;
|
||||
@ApiModelProperty(value = "装卸货联系人电话")
|
||||
private String contactPhone;
|
||||
@ApiModelProperty(value = "装卸货日期(年月日)")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date layDate;
|
||||
@ApiModelProperty(value = "装卸货时间(上午、下午、24小时)")
|
||||
private String layTime;
|
||||
@ApiModelProperty(value = "装卸货时间id")
|
||||
private String layTimeId;
|
||||
@ApiModelProperty(value = "装卸货类型:0无状态1装货地址2卸货地址")
|
||||
private Integer layType;
|
||||
@ApiModelProperty(value = "序号")
|
||||
private Integer sort;
|
||||
@ApiModelProperty(value = "简称")
|
||||
private String shortName;
|
||||
|
||||
}
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
package com.mhd.common.core.domain.dto.wlhy;
|
||||
|
||||
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
|
||||
|
||||
/**
|
||||
* @Description: 货源表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-14 09:49:27
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
public class TmsCargoInfoDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty(value = "货单号")
|
||||
private String orderId;
|
||||
@ApiModelProperty(value = "物料ID 库存ID 货物类型ID")
|
||||
private String goodsTypeId;
|
||||
@ApiModelProperty(value = "货物类型")
|
||||
private String goodsType;
|
||||
@ApiModelProperty(value = "货物名称ID")
|
||||
private String goodsNameId;
|
||||
@ApiModelProperty(value = "货物名称")
|
||||
private String goodsName;
|
||||
@ApiModelProperty(value = "货物数量")
|
||||
private BigDecimal cargoNum;
|
||||
@ApiModelProperty(value = "货物重量")
|
||||
private BigDecimal cargoWeight;
|
||||
private BigDecimal weight;
|
||||
@ApiModelProperty(value = "重量单位ID")
|
||||
private String weightUnitId;
|
||||
@ApiModelProperty(value = "重量单位名称")
|
||||
private String weightUnit;
|
||||
|
||||
|
||||
@ApiModelProperty(value = "数量单位ID")
|
||||
private String quantityUnitId;
|
||||
@ApiModelProperty(value = "数量单位名称")
|
||||
private String quantityUnit;
|
||||
|
||||
@ApiModelProperty("货物名称")
|
||||
private String cargoName;
|
||||
|
||||
@ApiModelProperty("货物单位ID")
|
||||
private String cargoUnitId;
|
||||
|
||||
@ApiModelProperty("货物单位名字")
|
||||
private String cargoUnitName;
|
||||
|
||||
@ApiModelProperty("整机表编号")
|
||||
private String machineCode;
|
||||
|
||||
@ApiModelProperty("")
|
||||
private String materialCode;
|
||||
|
||||
@ApiModelProperty("体积")
|
||||
private BigDecimal materialVolume;
|
||||
|
||||
@ApiModelProperty("内容")
|
||||
private String materialContent;
|
||||
|
||||
@ApiModelProperty("是否为库存")
|
||||
private boolean stockFlag;
|
||||
|
||||
@ApiModelProperty("货物重量 罐车运输专有字段")
|
||||
private BigDecimal cargoTonnage;
|
||||
|
||||
@ApiModelProperty("价格")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("货物类型标识:STOCK-库存,MATERIAL-物料,MANUAL-手动输入")
|
||||
private String cargoType;
|
||||
|
||||
@ApiModelProperty("货物备注")
|
||||
private String remark;
|
||||
}
|
||||
+476
@@ -0,0 +1,476 @@
|
||||
package com.mhd.common.core.domain.dto.wlhy;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.io.Serializable;
|
||||
import java.math.BigDecimal;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: 货源表
|
||||
* @Author: lfs
|
||||
* @Date: 2020-02-14 09:49:27
|
||||
* @Version: V1.0
|
||||
*/
|
||||
@Data
|
||||
public class
|
||||
|
||||
TmsOrderAddDTO implements Serializable {
|
||||
private static final long serialVersionUID = 1L;
|
||||
@TableId(type = IdType.ID_WORKER_STR)
|
||||
private String id;
|
||||
// @ApiModelProperty(value = "线路名称ID")
|
||||
// private java.lang.String lineNameId="";
|
||||
// @ApiModelProperty(value = "线路名称")
|
||||
// private java.lang.String lineName="";
|
||||
//
|
||||
// @ApiModelProperty(value = "运距(千米)")
|
||||
// private BigDecimal haulDistance;
|
||||
@ApiModelProperty(value = "装货地县区编码",required = true)
|
||||
private String loadingAreaId="";
|
||||
@ApiModelProperty(value = "装货地详细地址")
|
||||
private String loadingAddress="";
|
||||
|
||||
@ApiModelProperty(value = "发货人姓名")
|
||||
private String freighterName="";
|
||||
@ApiModelProperty(value = "装货电话")
|
||||
private String loadingPhone="";
|
||||
@ApiModelProperty(value = "装货时间日期(年月日)",required = true)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private java.util.Date loadingDate;
|
||||
// @ApiModelProperty(value = "装货时间(上午、下午、24小时)")
|
||||
// private String loadingTime="";
|
||||
@ApiModelProperty(value = "卸货地县区编码",required = true)
|
||||
private String unloadAreaId="";
|
||||
@ApiModelProperty(value = "卸货地详细地址")
|
||||
private String unloadAddress="";
|
||||
@ApiModelProperty(value = "收货人姓名")
|
||||
private String dischargerName="";
|
||||
@ApiModelProperty(value = "卸货电话")
|
||||
private String unloadPhone="";
|
||||
@ApiModelProperty(value = "卸货时间日期(年月日)",required = true)
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private java.util.Date unloadingData;
|
||||
|
||||
// @ApiModelProperty(value = "装货时间id",required = true)
|
||||
// private String loadingTimeId;
|
||||
// @ApiModelProperty(value = "卸货时间id",required = true)
|
||||
// private String unloadingTimeId;
|
||||
// @ApiModelProperty(value = "卸货时间(上午、下午、24小时)")
|
||||
// private java.lang.String unloadingTime;
|
||||
@ApiModelProperty(value = "货物名称ID")
|
||||
private String goodsNameId;
|
||||
@ApiModelProperty(value = "货物名称")
|
||||
private String goodsName;
|
||||
@ApiModelProperty(value = "货物名称ID",required = true)
|
||||
private String goodsTypeId;
|
||||
@ApiModelProperty(value = "货物大类型")
|
||||
private String goodsType="";
|
||||
@ApiModelProperty(value = "重量小(吨)",required = true)
|
||||
private BigDecimal weightMin;
|
||||
@ApiModelProperty(value = "重量大(吨)",required = true)
|
||||
private BigDecimal weightMax;
|
||||
|
||||
@ApiModelProperty(value = "货物数量单位(吨/方/件)id",required = true)
|
||||
private String goodsUntisId;
|
||||
@ApiModelProperty(value = "配载方式ID(0-数量,1-车次)",required = true)
|
||||
private Integer transportationModeId = 1;
|
||||
@ApiModelProperty(value = "车型车长ID")
|
||||
private String carType;
|
||||
// @ApiModelProperty(value = "指定司机ID")
|
||||
// private String appointDriverId;
|
||||
// @ApiModelProperty(value = "司机姓名")
|
||||
// private String appointDriver;
|
||||
// @ApiModelProperty(value = "司机手机号")
|
||||
// private String appointDriverPhone;
|
||||
// @ApiModelProperty(value = "司机车牌号")
|
||||
// private String appointDriverLicense;
|
||||
@ApiModelProperty(value = "服务要求ID")
|
||||
private String serviceRequireId;
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String remarks;
|
||||
|
||||
@ApiModelProperty(value = "备注")
|
||||
private String orderRemark;
|
||||
// @ApiModelProperty(value = "运单类型(0-企业普货、1-企业批量货、2-撮合货(普通货源)、3-客服运单,4-线下运单)")
|
||||
// private Integer waybillType ;
|
||||
@ApiModelProperty(value = "运单类型:0-pc端发货,1-pc端导入,2-货主端app发货")
|
||||
private Integer waybillFrom = 2 ;
|
||||
// @ApiModelProperty(value = "期望运费")
|
||||
// private java.math.BigDecimal freightHope;
|
||||
// @ApiModelProperty(value = "占用车长")
|
||||
// private String occupyConductor;
|
||||
@ApiModelProperty(value = "运单模式(0-普通模式,1-竞价模式)")
|
||||
private Integer waybillMode = 0;
|
||||
@ApiModelProperty(value = "竞价截止时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private java.util.Date latestBiddingTime;
|
||||
@ApiModelProperty(value = "发货运费")
|
||||
private BigDecimal deliveryFreight;
|
||||
@ApiModelProperty(value = "运费单价(元/吨)")
|
||||
private BigDecimal transportationUnitPrice;
|
||||
@ApiModelProperty(value = "结算方式,1-按趟结算,2-按数量结算")
|
||||
private Integer radioValue;
|
||||
@ApiModelProperty(value = "合同物流导入(0-默认,1-合同,2-普通导入)")
|
||||
private Integer isContract = 0;
|
||||
|
||||
// @ApiModelProperty(value = "是否长期货源:0-否,1-是")
|
||||
// private Integer isLongOrder=0;
|
||||
|
||||
// @ApiModelProperty(value = "卸货单位")
|
||||
// private java.lang.String unloadUnit;
|
||||
// @ApiModelProperty(value = "收货人身份证号")
|
||||
// private String unloadIdentificationNumber;
|
||||
// @ApiModelProperty(value = "代运营人员用户ID")
|
||||
// private String orderAgentUserId;
|
||||
|
||||
@ApiModelProperty(value = "指定货主编号")
|
||||
private String appointShipperId;
|
||||
@ApiModelProperty(value = "指定货主")
|
||||
private String appointShipper;
|
||||
// @ApiModelProperty(value = "指定平台公司")
|
||||
// private String appointCompanyId;
|
||||
// @ApiModelProperty(value = "指定平台公司名称")
|
||||
// private String appointCompanyName;
|
||||
// @ApiModelProperty(value = "指定车辆ID")
|
||||
// private String appointVehicleId;
|
||||
// @ApiModelProperty(value = "指定车辆设备号")
|
||||
// private String appointVehicleDevice;
|
||||
|
||||
|
||||
/**是否开启路耗(0-否 1-是)*/
|
||||
// @ApiModelProperty(value = "是否开启路耗(0-否 1-是)")
|
||||
// @Excel(name = "是否开启路耗(0-否 1-是)", width = 15)
|
||||
// private Integer isRoadLoss=0;
|
||||
/**货物价值(元/吨)*/
|
||||
// @ApiModelProperty(value = "货物价值(元/吨)")
|
||||
// @Excel(name = "货物价值(元/吨)", width = 15)
|
||||
// private BigDecimal goodsValue=BigDecimal.ZERO;
|
||||
/**路耗模式( 0-按比例% 1-按数量(吨))*/
|
||||
// @ApiModelProperty(value = "路耗模式( 0-按比例% 1-按数量(吨))")
|
||||
// @Excel(name = "路耗模式( 0-按比例% 1-按数量(吨))", width = 15)
|
||||
// private Integer roadLossMode;
|
||||
// /**路耗结算方式( 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)*/
|
||||
// @ApiModelProperty(value = "路耗结算方式(0-无 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)")
|
||||
// @Excel(name = "路耗结算方式( 1-取装货重量 2-取卸货重量 3-装卸货取大 4-装卸货取小)", width = 15)
|
||||
// private Integer roadLossSettlementMethod;
|
||||
/**允许货物亏损*/
|
||||
// @ApiModelProperty(value = "允许货物亏损(吨或%)")
|
||||
// @Excel(name = "允许货物亏损(吨或%)", width = 15)
|
||||
// private BigDecimal allowableLoss=BigDecimal.ZERO;
|
||||
|
||||
/**超出亏损扣除金额(元/吨)*/
|
||||
// @ApiModelProperty(value = "超出亏损扣除金额(元/吨)")
|
||||
// @Excel(name = "超出亏损扣除金额(元/吨)", width = 15)
|
||||
// private BigDecimal lossDeductionAmount=BigDecimal.ZERO;
|
||||
|
||||
// @ApiModelProperty(value = "上游客户id")
|
||||
// @Excel(name = "上游客户id", width = 15)
|
||||
// private String upClientId;
|
||||
|
||||
// @ApiModelProperty(value = "运费抹零 0-不抹零 ,1-抹零小数位,2-抹零个位,3-抹零十位")
|
||||
// private Integer isFreightNullification ;
|
||||
|
||||
@ApiModelProperty(value = "加油宝计算模式 0-按比例 1-按数值")
|
||||
private Integer oilValue ;
|
||||
|
||||
// @ApiModelProperty(value = "是否允许接多单:0否 1是")
|
||||
// private Integer isMultipleOrdersAllowed;
|
||||
|
||||
@ApiModelProperty(value = "发货备注")
|
||||
private String shippingNote;
|
||||
|
||||
// @ApiModelProperty(value = "涨吨是否计算费用 0-否 1-是 ")
|
||||
// private Integer isTonnageIncreaseCharge;
|
||||
@ApiModelProperty(value = "装货地经度")
|
||||
private String loadingLongitude;
|
||||
@ApiModelProperty(value = "装货地纬度")
|
||||
private String loadingLatitude;
|
||||
|
||||
@ApiModelProperty(value = "卸货地经度")
|
||||
private String unloadLongitude;
|
||||
@ApiModelProperty(value = "卸货地纬度")
|
||||
private String unloadLatitude;
|
||||
|
||||
@ApiModelProperty(value = "预设竞标价")
|
||||
@Excel(name = "预设竞标价", width = 15)
|
||||
private BigDecimal highestPrice;
|
||||
|
||||
@ApiModelProperty(value = "预设竞标价")
|
||||
private BigDecimal presetPrice;
|
||||
|
||||
@ApiModelProperty(value = "竞价单位(元/车,元/吨)")
|
||||
private String biddingUnit;
|
||||
|
||||
@ApiModelProperty(value = "竞价最高可输入价格")
|
||||
@Excel(name = "竞价最高可输入价格", width = 15)
|
||||
private BigDecimal maximumBidPrice;
|
||||
|
||||
@ApiModelProperty(value = "评标类型(0-自动评标,1-手动评标)")
|
||||
private Integer bidEvaluationType = 1;
|
||||
|
||||
@ApiModelProperty("应收结算类型:1-月结,2-现结")
|
||||
private Integer receivableType;
|
||||
|
||||
@ApiModelProperty(value = "货物数量")
|
||||
private String goodsQuantity;
|
||||
@ApiModelProperty(value = "货物数量单位code")
|
||||
private String goodsQuantityUnitId;
|
||||
@ApiModelProperty(value = "货物数量单位")
|
||||
private String goodsQuantityUnit;
|
||||
|
||||
// @ApiModelProperty("项目表ID")
|
||||
// private Long projectManagementId;
|
||||
|
||||
// @ApiModelProperty(value = "服务费率")
|
||||
// private BigDecimal serviceRate;
|
||||
|
||||
@ApiModelProperty("是否自动生成协议 0-否 1-是")
|
||||
@Excel(name = "是否自动生成协议 0-否 1-是")
|
||||
private Integer isAutoGenerateProtocol;
|
||||
|
||||
// @ApiModelProperty(value = "单车总费用")
|
||||
// @Excel(name = "单车总费用", width = 15)
|
||||
// private BigDecimal freightGross = BigDecimal.ZERO;
|
||||
|
||||
// @ApiModelProperty(value = "协议费用:回单付金额")
|
||||
// @Excel(name = "协议费用:回单付金额", width = 15)
|
||||
// private BigDecimal receiptPaymentAmount = BigDecimal.ZERO;
|
||||
//
|
||||
// @ApiModelProperty(value = "协议费用:预付现金金额")
|
||||
// @Excel(name = "协议费用:预付现金金额", width = 15)
|
||||
// private BigDecimal cashAdvance = BigDecimal.ZERO;
|
||||
//
|
||||
// @ApiModelProperty(value = "协议费用:到付运费金额")
|
||||
// @Excel(name = "协议费用:到付运费金额", width = 15)
|
||||
// private BigDecimal freightAmount = BigDecimal.ZERO;
|
||||
//
|
||||
// @ApiModelProperty(value = "协议费用:预付平台油卡金额")
|
||||
// @Excel(name = "协议费用:预付平台油卡金额", width = 15)
|
||||
// private BigDecimal oilCardOnline = BigDecimal.ZERO;
|
||||
|
||||
// @ApiModelProperty(value = "单车重量", required = true)
|
||||
// private BigDecimal singleVehicleWeight;
|
||||
|
||||
|
||||
|
||||
//=================批量货派单相关=============================
|
||||
// @ApiModelProperty(value = "需求车次")
|
||||
// private Integer demandTrainNumber;
|
||||
// @ApiModelProperty(value = "承运车次默认0")
|
||||
// private Integer carriageNumber;
|
||||
// @ApiModelProperty(value = "剩余需求车次")
|
||||
// private Integer remainingDemandTrainNumber;
|
||||
|
||||
/**货物重量*/
|
||||
// @ApiModelProperty(value = "货物重量")
|
||||
// private BigDecimal goodsWeight;
|
||||
// @ApiModelProperty(value = "货源剩余货物数量")
|
||||
// private BigDecimal residueGoodsWeight;
|
||||
// @ApiModelProperty(value = "承运货物数量")
|
||||
// private BigDecimal transportGoodsWeight;
|
||||
|
||||
@ApiModelProperty(value = "货物信息表")
|
||||
private List<TmsCargoInfoDTO> cargoInfoList;
|
||||
@ApiModelProperty(value = "装货地址集合")
|
||||
private List<TmsAddressMultiDTO> loadingAddressList;
|
||||
@ApiModelProperty(value = "卸货地址集合")
|
||||
private List<TmsAddressMultiDTO> unloadAddressList;
|
||||
|
||||
|
||||
|
||||
|
||||
// @ApiModelProperty(value = "来源系统")
|
||||
// private String orderSource;
|
||||
|
||||
//========================================新增字段==========================================
|
||||
@ApiModelProperty(value = "付款方类型(0-委托方,1-收货方)")
|
||||
@Excel(name = "付款方类型(0-委托方,1-收货方)", width = 15)
|
||||
private Integer payerType;
|
||||
|
||||
@ApiModelProperty(value = "收货方编码")
|
||||
private String recipientId;
|
||||
@ApiModelProperty(value = "收货方")
|
||||
private String recipientName;
|
||||
|
||||
@ApiModelProperty(value = "整机编号")
|
||||
private String machineNumber;
|
||||
|
||||
@ApiModelProperty(value = "是否库存(0-是,1-否)")
|
||||
@Excel(name = "是否库存(0-是,1-否)", width = 15)
|
||||
private Integer stockFlag;
|
||||
|
||||
@ApiModelProperty(value = "信息费")
|
||||
private BigDecimal infoFee;
|
||||
|
||||
@ApiModelProperty(value = "订单类型(1-普货运输,2-危化运输,3-罐车运输,4-济南专线,5-江西专线)")
|
||||
private Integer orderShippingType;
|
||||
|
||||
@ApiModelProperty(value = "单号")
|
||||
private String thirdPartyOrderNumber;
|
||||
|
||||
@ApiModelProperty(value = "车辆类型Id")
|
||||
private String vehicleTypeId;
|
||||
|
||||
@ApiModelProperty(value = "车辆类型名称")
|
||||
private String vehicleTypeName;
|
||||
|
||||
@ApiModelProperty(value = "承运人Id(订单为济南专线使用)")
|
||||
private String carrier;
|
||||
|
||||
@ApiModelProperty(value = "承运人姓名(订单为济南专线使用)")
|
||||
private String carrierName;
|
||||
|
||||
@ApiModelProperty("运费单价")
|
||||
private BigDecimal freightUnitPrice;
|
||||
|
||||
@ApiModelProperty("数字物流平台用户id")
|
||||
private Long szwlUserId;
|
||||
|
||||
@ApiModelProperty(value = "信息费收款方")
|
||||
private String infoFeePayee;
|
||||
|
||||
@ApiModelProperty(value = "信息费收款方方式(0-委托方,1-收货方,2-第三方)")
|
||||
private Integer infoFeePayeeType;
|
||||
|
||||
@ApiModelProperty("业务员ID")
|
||||
private String salesmanId;
|
||||
|
||||
@ApiModelProperty("业务员ID")
|
||||
private String salesmanName;
|
||||
|
||||
@ApiModelProperty("是否报关(0:否,1:是)")
|
||||
private Integer isDeclare;
|
||||
|
||||
@ApiModelProperty("线路")
|
||||
private String route;
|
||||
|
||||
@ApiModelProperty("柜类型")
|
||||
private String containerType;
|
||||
|
||||
@ApiModelProperty("柜类型名称")
|
||||
private String containerTypeName;
|
||||
|
||||
@ApiModelProperty("卡类型")
|
||||
private String cardType;
|
||||
|
||||
@ApiModelProperty("卡类型名称")
|
||||
private String cardTypeName;
|
||||
|
||||
@ApiModelProperty("外来柜号")
|
||||
private String externalContainerNo;
|
||||
|
||||
@ApiModelProperty("中转地")
|
||||
private String transitPlace;
|
||||
|
||||
@ApiModelProperty("托运人ID")
|
||||
private String shipper;
|
||||
|
||||
@ApiModelProperty("托运人ID")
|
||||
private String customsShipper;
|
||||
|
||||
@ApiModelProperty("托运人电话")
|
||||
private String customsShipperTel;
|
||||
|
||||
@ApiModelProperty("卸货单位")
|
||||
private String unloadingCompany;
|
||||
|
||||
@ApiModelProperty("合同编号")
|
||||
private String contractNo;
|
||||
|
||||
@ApiModelProperty("运费")
|
||||
private BigDecimal freightFee;
|
||||
|
||||
@ApiModelProperty("卸货费")
|
||||
private BigDecimal unloadingFee;
|
||||
|
||||
@ApiModelProperty("报关费")
|
||||
private BigDecimal customsFee;
|
||||
|
||||
@ApiModelProperty("差货费")
|
||||
private BigDecimal shortageFee;
|
||||
|
||||
@ApiModelProperty("杂费")
|
||||
private BigDecimal miscellaneousFee;
|
||||
|
||||
@ApiModelProperty("其他费用")
|
||||
private BigDecimal otherFee;
|
||||
|
||||
@ApiModelProperty("滞车费")
|
||||
private BigDecimal detentionFee;
|
||||
|
||||
@ApiModelProperty("税率")
|
||||
private BigDecimal taxRate;
|
||||
|
||||
@ApiModelProperty("结算币种")
|
||||
private String settlementCurrency;
|
||||
|
||||
@ApiModelProperty("体积")
|
||||
private BigDecimal volume;
|
||||
|
||||
@ApiModelProperty("内容详情")
|
||||
private String detailContent;
|
||||
|
||||
@ApiModelProperty("报关线路")
|
||||
private String customsRoute;
|
||||
|
||||
@ApiModelProperty("报关关口")
|
||||
private String customsPort;
|
||||
|
||||
@ApiModelProperty("报关联系人")
|
||||
private String customsContact;
|
||||
|
||||
@ApiModelProperty("报关联系人电话")
|
||||
private String customsContactPhone;
|
||||
|
||||
@ApiModelProperty("报关备注")
|
||||
private String customsRemark;
|
||||
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
private String orgId;
|
||||
|
||||
@ApiModelProperty(value = "所属组织")
|
||||
@Excel(name = "所属组织", width = 15)
|
||||
private String orgName;
|
||||
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty(value = "上级组织ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("客户编码nc")
|
||||
private String customerCodeNc;
|
||||
|
||||
@ApiModelProperty("制单人编码nc")
|
||||
private String makerCodeNc;
|
||||
|
||||
@ApiModelProperty("业务员编码nc")
|
||||
private String salesmanCodeNc;
|
||||
|
||||
@ApiModelProperty(value = "单据日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private java.util.Date documentDate;
|
||||
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty("执行单id")
|
||||
private String executeOrderId;
|
||||
|
||||
@ApiModelProperty("执行单号")
|
||||
private String executeOrderNumber;
|
||||
}
|
||||
+41
@@ -475,6 +475,7 @@ public class TmsOrder implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "已收运费")
|
||||
private BigDecimal collectedFreight;
|
||||
|
||||
@ApiModelProperty(value = "未收运费")
|
||||
private BigDecimal uncollectedFreight;
|
||||
@ApiModelProperty(value = "少收运费")
|
||||
@@ -522,4 +523,44 @@ public class TmsOrder implements Serializable {
|
||||
|
||||
@ApiModelProperty(value = "付款方名称")
|
||||
private String payer;
|
||||
|
||||
|
||||
@ApiModelProperty("制单人编码nc")
|
||||
private String makerCodeNc;
|
||||
|
||||
@ApiModelProperty("业务员编码nc")
|
||||
private String salesmanCodeNc;
|
||||
|
||||
@ApiModelProperty("税率")
|
||||
private BigDecimal taxRate;
|
||||
|
||||
@ApiModelProperty("结算币种")
|
||||
private String settlementCurrency;
|
||||
|
||||
@ApiModelProperty("合同编号")
|
||||
private String contractNo;
|
||||
|
||||
@ApiModelProperty("客户编码nc")
|
||||
private String customerCodeNc;
|
||||
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
private String orgId;
|
||||
|
||||
@ApiModelProperty(value = "所属组织")
|
||||
private String orgName;
|
||||
|
||||
@ApiModelProperty(value = "组织ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty(value = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty(value = "上级组织ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty(value = "单据日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private java.util.Date documentDate;
|
||||
|
||||
}
|
||||
|
||||
+2
@@ -99,6 +99,8 @@ public class Verification extends BaseVOEntity implements Serializable,Cloneable
|
||||
private Long topOrganizationId;
|
||||
@ApiModelProperty("组织表ID")
|
||||
private Long organizationId;
|
||||
@ApiModelProperty("组织名称")
|
||||
private String organizationName;
|
||||
// @ApiModelProperty("是否月结:1-是,2-否")
|
||||
// private Integer receivableType;
|
||||
@ApiModelProperty("部门id")
|
||||
|
||||
+3
@@ -56,4 +56,7 @@ public class AddressBookPo extends BaseVOEntity implements Serializable
|
||||
private String synthesize;
|
||||
@ApiModelProperty(name = "单位名称")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty(name = "组织ID(用于数据权限过滤,内部使用)", hidden = true)
|
||||
private Long organizationId;
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package com.mhd.common.core.domain.po;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
@@ -24,6 +25,10 @@ public class RolePO extends BaseVOEntity implements Serializable {
|
||||
private String roleTypeName = "";
|
||||
@ApiModelProperty(name = "组织表ID")
|
||||
private Long organizationId = 0L;
|
||||
@ApiModelProperty(name = "组织名称")
|
||||
private String organizationName = "";
|
||||
@ApiModelProperty(name = "一级组织表ID")
|
||||
private Long topOrganizationId = 0L;
|
||||
@ApiModelProperty(name = "职务/角色权限字符,控制器中定义的权限字符,如:@PreAuthorize(`@ss.hasRole('admin')`)")
|
||||
private String roleCode = "";
|
||||
@ApiModelProperty(name = "职务/角色名称")
|
||||
@@ -42,6 +47,9 @@ public class RolePO extends BaseVOEntity implements Serializable {
|
||||
|
||||
@Override
|
||||
public boolean equals(Object o) {
|
||||
if (ObjectUtil.isNull(o)) {
|
||||
return false;
|
||||
}
|
||||
RolePO rolePO = (RolePO) o;
|
||||
return roleCode.equals(rolePO.getRoleCode());
|
||||
}
|
||||
|
||||
+11
@@ -28,6 +28,8 @@ public class UserDriverListPo {
|
||||
private String driverEnterpriseName="";
|
||||
@ApiModelProperty(name = "登录账号(2-20位)")
|
||||
private String userAccount = "";
|
||||
@ApiModelProperty(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
@ApiModelProperty(name = "组织名称")
|
||||
private String organizationName = "";
|
||||
@ApiModelProperty(name = "身份证号")
|
||||
@@ -301,4 +303,13 @@ public class UserDriverListPo {
|
||||
@ApiModelProperty(value = "是否允许竞价(0-不允许竞价,1-允许参与竞价,2-允许查看竞价)")
|
||||
private Integer isDriverBidding;
|
||||
|
||||
@ApiModelProperty(value = "用户身份")
|
||||
private Integer userIdentity;
|
||||
|
||||
@ApiModelProperty(name = "车辆主体")
|
||||
private String vehicleBody;
|
||||
|
||||
@ApiModelProperty(name = "")
|
||||
private String wlhydriverId;
|
||||
|
||||
}
|
||||
|
||||
+3
@@ -185,6 +185,9 @@ public class UserDriverPo {
|
||||
@ApiModelProperty(name = "用户实名认证状态:0-无状态,1-已注册未认证,2-已认证待审核,3-审核通过,4-已驳回")
|
||||
private Integer userAuthStatus;
|
||||
|
||||
@ApiModelProperty(name = "车辆主体")
|
||||
private String vehicleBody;
|
||||
|
||||
|
||||
//===================车队司机参数===============
|
||||
@ApiModelProperty("车队队长userId")
|
||||
|
||||
@@ -220,4 +220,34 @@ public class UserPo {
|
||||
|
||||
@ApiModelProperty(name = "制单员nc编码")
|
||||
private String documentPreparerNcCode;
|
||||
|
||||
@ApiModelProperty("法人代表")
|
||||
private String legalRepresentative;
|
||||
|
||||
@ApiModelProperty("统一编码")
|
||||
private String unifiedCode;
|
||||
|
||||
@ApiModelProperty("注册电话")
|
||||
private String registeredPhone;
|
||||
|
||||
@ApiModelProperty("注册地址")
|
||||
private String registeredAddress;
|
||||
|
||||
@ApiModelProperty("传真")
|
||||
private String fax;
|
||||
|
||||
@ApiModelProperty("付款银行")
|
||||
private String paymentBank;
|
||||
|
||||
@ApiModelProperty("付款账户")
|
||||
private String paymentAccount;
|
||||
|
||||
@ApiModelProperty("发票抬头")
|
||||
private String invoiceTitle;
|
||||
|
||||
@ApiModelProperty("税号")
|
||||
private String taxNumber;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
}
|
||||
|
||||
+2
@@ -99,6 +99,8 @@ public class VerificationPo extends BaseVOEntity implements Serializable
|
||||
private Long topOrganizationId;
|
||||
@ApiModelProperty("组织表ID")
|
||||
private Long organizationId;
|
||||
@ApiModelProperty("组织名称")
|
||||
private String organizationName;
|
||||
// @ApiModelProperty("是否月结:1-是,2-否")
|
||||
// private Integer receivableType;
|
||||
@ApiModelProperty("部门id")
|
||||
|
||||
@@ -4,6 +4,7 @@ import com.aliyun.oss.ServiceException;
|
||||
import io.minio.MinioClient;
|
||||
import io.minio.PutObjectArgs;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.util.UriUtils;
|
||||
|
||||
@@ -15,9 +16,11 @@ import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.UUID;
|
||||
|
||||
@Service
|
||||
public class MinIoUploadService {
|
||||
@Autowired
|
||||
|
||||
private MinioClient minioClient;
|
||||
|
||||
private static String bucket="ngwl";
|
||||
private static String host="http://10.102.192.5:6000";
|
||||
private static String accessKey="minioadmin";
|
||||
@@ -64,7 +67,7 @@ public class MinIoUploadService {
|
||||
.stream(inputStream,inputStream.available(),-1).build();
|
||||
//文件名称相同会覆盖
|
||||
minioClient.putObject(objectArgs);
|
||||
String url =host+ "/"+bucket + "/"+fileName;
|
||||
String url =host+"/browser/"+bucket + "/"+fileName;
|
||||
|
||||
//
|
||||
return url;
|
||||
|
||||
@@ -1,240 +0,0 @@
|
||||
package minio;
|
||||
|
||||
import com.aliyun.oss.ServiceException;
|
||||
import io.minio.MinioClient;
|
||||
import io.minio.errors.InvalidEndpointException;
|
||||
import io.minio.errors.InvalidPortException;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import net.coobird.thumbnailator.Thumbnails;
|
||||
import org.jeecg.modules.oss.dto.WaterMarkDTO;
|
||||
import org.jeecg.modules.system.entity.SysDepartInterfaceInfo;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
import org.springframework.web.util.UriUtils;
|
||||
|
||||
import java.io.ByteArrayInputStream;
|
||||
import java.io.ByteArrayOutputStream;
|
||||
import java.io.IOException;
|
||||
import java.io.InputStream;
|
||||
import java.nio.charset.StandardCharsets;
|
||||
import java.text.SimpleDateFormat;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* @Description: minio oss 上传工具类
|
||||
*/
|
||||
@Slf4j
|
||||
public class MinioBootUtil {
|
||||
|
||||
private static String bucket;
|
||||
private static String host;
|
||||
private static String accessKey;
|
||||
private static String secretKey;
|
||||
/**
|
||||
* minio 工具客户端
|
||||
*/
|
||||
private static MinioClient minioClient = null;
|
||||
|
||||
private static String FILE_URL;
|
||||
|
||||
/**
|
||||
* @Description 强制初始化minio
|
||||
* @Author Alex
|
||||
* @Date 2023/10/25 11:12
|
||||
*/
|
||||
public static MinioClient forceInitMinio(List<SysDepartInterfaceInfo> sysDepartInterfaceInfoList) throws InvalidPortException, InvalidEndpointException {
|
||||
for (SysDepartInterfaceInfo sysDepartInterfaceInfo : sysDepartInterfaceInfoList) {
|
||||
String interfaceTypeKey = sysDepartInterfaceInfo.getInterfaceTypeKey();//接口参数
|
||||
String interfaceTypeValue = sysDepartInterfaceInfo.getInterfaceTypeValue();//接口参数值
|
||||
switch (interfaceTypeKey) {
|
||||
case "bucket":
|
||||
bucket = interfaceTypeValue;
|
||||
break;
|
||||
case "host":
|
||||
host = interfaceTypeValue;
|
||||
break;
|
||||
case "accessKey":
|
||||
accessKey = interfaceTypeValue;
|
||||
break;
|
||||
case "secretKey":
|
||||
secretKey = interfaceTypeValue;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
minioClient = new MinioClient(host, accessKey, secretKey);
|
||||
return minioClient;
|
||||
}
|
||||
private static MinioClient initMinio() throws InvalidPortException, InvalidEndpointException {
|
||||
if (minioClient == null) {
|
||||
minioClient = new MinioClient(host, accessKey, secretKey);
|
||||
}
|
||||
return minioClient;
|
||||
}
|
||||
/**
|
||||
* 上传文件
|
||||
* 文件上传成功,返回文件完整访问路径
|
||||
* 文件上传失败,返回 null
|
||||
*
|
||||
* @param multipartFile 待上传文件
|
||||
* @param fileDir 文件保存目录
|
||||
* @return oss 中的相对文件路径
|
||||
*/
|
||||
public static String upload(MultipartFile multipartFile, String fileDir, List<SysDepartInterfaceInfo> sysDepartInterfaceInfoList) {
|
||||
for (SysDepartInterfaceInfo sysDepartInterfaceInfo : sysDepartInterfaceInfoList) {
|
||||
String interfaceTypeKey = sysDepartInterfaceInfo.getInterfaceTypeKey();//接口参数
|
||||
String interfaceTypeValue = sysDepartInterfaceInfo.getInterfaceTypeValue();//接口参数值
|
||||
switch (interfaceTypeKey) {
|
||||
case "bucket":
|
||||
bucket = interfaceTypeValue;
|
||||
break;
|
||||
case "host":
|
||||
host = interfaceTypeValue;
|
||||
break;
|
||||
case "accessKey":
|
||||
accessKey = interfaceTypeValue;
|
||||
break;
|
||||
case "secretKey":
|
||||
secretKey = interfaceTypeValue;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
try (InputStream inputStream = multipartFile.getInputStream()) {
|
||||
//初始化minio
|
||||
initMinio();
|
||||
// bucket 不存在,创建
|
||||
if (!minioClient.bucketExists(bucket)) {
|
||||
minioClient.makeBucket(bucket);
|
||||
}
|
||||
// 上传文件的名称
|
||||
String fileName = multipartFile.getOriginalFilename();
|
||||
long timestamp = Calendar.getInstance().getTimeInMillis();
|
||||
// PutObjectOptions,上传配置(文件大小,内存中文件分片大小)
|
||||
// PutObjectOptions putObjectOptions = new PutObjectOptions(multipartFile.getSize(), PutObjectOptions.MIN_MULTIPART_SIZE);
|
||||
// // 文件的ContentType
|
||||
// putObjectOptions.setContentType(multipartFile.getContentType());
|
||||
|
||||
SimpleDateFormat sdYear = new SimpleDateFormat("yyyy");
|
||||
SimpleDateFormat sdMonth = new SimpleDateFormat("MM");
|
||||
SimpleDateFormat sdDay = new SimpleDateFormat("dd");
|
||||
String year = sdYear.format(new Date());
|
||||
String month = sdMonth.format(new Date());
|
||||
String day = sdDay.format(new Date());
|
||||
String filrDir = "wlhy/" + year + "/" + month + "/" + day + "/";
|
||||
|
||||
// minioClient.putObject(bucket, filrDir+timestamp+fileName, inputStream, putObjectOptions);
|
||||
minioClient.putObject(bucket, filrDir+timestamp+fileName, inputStream, multipartFile.getContentType());
|
||||
// 返回访问路径
|
||||
String fileurl = host+ "/"+bucket + "/"+filrDir+timestamp+ UriUtils.encode(fileName, StandardCharsets.UTF_8);
|
||||
System.out.println("fileurl===="+fileurl);
|
||||
FILE_URL = fileurl;
|
||||
return fileurl;
|
||||
} catch (ServiceException e){
|
||||
log.error(e.getErrorMessage());
|
||||
} catch (Exception e){
|
||||
log.error(e.getMessage());
|
||||
}
|
||||
return FILE_URL;
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传文件 带时间水印
|
||||
* 文件上传成功,返回文件完整访问路径
|
||||
* 文件上传失败,返回 null
|
||||
*
|
||||
* @param multipartFile 待上传文件
|
||||
* @param fileDir 文件保存目录
|
||||
* @return oss 中的相对文件路径
|
||||
*/
|
||||
public static String uploadWaterMark(MultipartFile multipartFile, WaterMarkDTO waterMarkDTO, String fileDir, List<SysDepartInterfaceInfo> sysDepartInterfaceInfoList) {
|
||||
for (SysDepartInterfaceInfo sysDepartInterfaceInfo : sysDepartInterfaceInfoList) {
|
||||
String interfaceTypeKey = sysDepartInterfaceInfo.getInterfaceTypeKey();//接口参数
|
||||
String interfaceTypeValue = sysDepartInterfaceInfo.getInterfaceTypeValue();//接口参数值
|
||||
switch (interfaceTypeKey) {
|
||||
case "bucket":
|
||||
bucket = interfaceTypeValue;
|
||||
break;
|
||||
case "host":
|
||||
host = interfaceTypeValue;
|
||||
break;
|
||||
case "accessKey":
|
||||
accessKey = interfaceTypeValue;
|
||||
break;
|
||||
case "secretKey":
|
||||
secretKey = interfaceTypeValue;
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
// 压缩代码
|
||||
InputStream inputStream = null;
|
||||
try {
|
||||
//初始化minio
|
||||
initMinio();
|
||||
// bucket 不存在,创建
|
||||
if (!minioClient.bucketExists(bucket)) {
|
||||
minioClient.makeBucket(bucket);
|
||||
}
|
||||
String OriginalFilename = multipartFile.getOriginalFilename();
|
||||
inputStream = multipartFile.getInputStream();
|
||||
SimpleDateFormat sdf = new SimpleDateFormat("yyyy-MM-dd HH:mm:ss");
|
||||
//水印内容
|
||||
String waterMarkContent = sdf.format(new Date());
|
||||
//以下两种方法加水印
|
||||
//方法1
|
||||
if (OriginalFilename.indexOf(".pdf") < 0) {
|
||||
ByteArrayOutputStream byteArrayOutputStreamut = new ByteArrayOutputStream();
|
||||
Thumbnails.of(inputStream).width(1024).keepAspectRatio(true).outputQuality(0.9).toOutputStream(byteArrayOutputStreamut);
|
||||
inputStream = new ByteArrayInputStream(byteArrayOutputStreamut.toByteArray());
|
||||
//添加水印
|
||||
inputStream = OssBootUtil.buildWatermarkOfText(inputStream, waterMarkDTO, OssBootUtil.WaterMarkLocation.SOUTH_WEST, null, 0.5f);
|
||||
}
|
||||
//方法2
|
||||
/*if (ImageUtil.isImage(multipartFile.getOriginalFilename())) {
|
||||
inputStream = ImageUtil.getInputStream(
|
||||
ImageUtil.setWatermark(
|
||||
ImageUtil.compress(
|
||||
ImageIO.read(inputStream)),waterMarkContent),
|
||||
ImageUtil.getFileExtention(multipartFile.getOriginalFilename()));
|
||||
}*/
|
||||
StringBuilder fileUrl = new StringBuilder();
|
||||
String suffix = multipartFile.getOriginalFilename().substring(multipartFile.getOriginalFilename().lastIndexOf('.'));
|
||||
// 上传文件的名称
|
||||
String fileName = multipartFile.getOriginalFilename();
|
||||
long timestamp = Calendar.getInstance().getTimeInMillis();
|
||||
// PutObjectOptions,上传配置(文件大小,内存中文件分片大小)
|
||||
// PutObjectOptions putObjectOptions = new PutObjectOptions(multipartFile.getSize(), PutObjectOptions.MIN_MULTIPART_SIZE);
|
||||
// // 文件的ContentType
|
||||
// putObjectOptions.setContentType(multipartFile.getContentType());
|
||||
|
||||
SimpleDateFormat sdYear = new SimpleDateFormat("yyyy");
|
||||
SimpleDateFormat sdMonth = new SimpleDateFormat("MM");
|
||||
SimpleDateFormat sdDay = new SimpleDateFormat("dd");
|
||||
String year = sdYear.format(new Date());
|
||||
String month = sdMonth.format(new Date());
|
||||
String day = sdDay.format(new Date());
|
||||
String filrDir = "wlhy/" + year + "/" + month + "/" + day + "/";
|
||||
|
||||
// minioClient.putObject(bucket, filrDir+timestamp+fileName, inputStream, putObjectOptions);
|
||||
minioClient.putObject(bucket, filrDir+timestamp+fileName, inputStream, multipartFile.getContentType());
|
||||
// 返回访问路径
|
||||
String fileurl = host+ "/"+bucket + "/"+filrDir+timestamp+ UriUtils.encode(fileName, StandardCharsets.UTF_8);
|
||||
System.out.println("fileurl===="+fileurl);
|
||||
FILE_URL = fileurl;
|
||||
return fileurl;
|
||||
} catch (IOException e) {
|
||||
log.error(e.getMessage());
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage());
|
||||
}
|
||||
return FILE_URL;
|
||||
}
|
||||
|
||||
}
|
||||
+1
@@ -129,6 +129,7 @@ public class TokenService
|
||||
if (StringUtils.isNotEmpty(token))
|
||||
{
|
||||
String userkey = JwtUtils.getUserKey(token);
|
||||
redisService.deleteObject(userkey);
|
||||
redisService.deleteObject(getTokenKey(userkey));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,21 +13,17 @@ spring:
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
# server-addr: 10.102.192.5:6848
|
||||
server-addr: 10.33.0.129:6010
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
config:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
# server-addr: 10.102.192.5:6848
|
||||
server-addr: 10.33.0.129:6010
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
group: DEFAULT_GROUP # 默认分组就是DEFAULT_GROUP,如果使用默认分组可以不配置
|
||||
file-extension: yml #默认properties
|
||||
# 共享配置
|
||||
shared-configs:
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
@@ -14,10 +14,14 @@ spring:
|
||||
nacos:
|
||||
discovery:
|
||||
server-addr: 127.0.0.1:8848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
#server-addr: mhd-nacos:8848
|
||||
config:
|
||||
server-addr: 127.0.0.1:8848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
#server-addr: mhd-nacos:8848
|
||||
group: DEFAULT_GROUP # 默认分组就是DEFAULT_GROUP,如果使用默认分组可以不配置
|
||||
|
||||
@@ -6,6 +6,7 @@ import com.mhd.common.security.annotation.EnableCustomConfig;
|
||||
import com.mhd.common.security.annotation.EnableRyFeignClients;
|
||||
import com.mhd.common.swagger.annotation.EnableCustomSwagger2;
|
||||
import org.springframework.scheduling.annotation.EnableAsync;
|
||||
import org.springframework.scheduling.annotation.EnableScheduling;
|
||||
|
||||
/**
|
||||
* 系统模块
|
||||
@@ -17,6 +18,7 @@ import org.springframework.scheduling.annotation.EnableAsync;
|
||||
@EnableRyFeignClients
|
||||
@SpringBootApplication
|
||||
@EnableAsync
|
||||
@EnableScheduling
|
||||
public class MhdSystemApplication
|
||||
{
|
||||
public static void main(String[] args)
|
||||
|
||||
+318
@@ -0,0 +1,318 @@
|
||||
package com.mhd.basic.application.service.Lease;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.mhd.basic.application.service.storageSection.StorageSectionApplicationService;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.facade.ILeaseService;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.lease.service.LeaseDomainService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.WarehouseOccupancyRate;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.facade.IShipperLeaseDetailsService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.basic.domain.storageSection.repository.po.StorageSectionPO;
|
||||
import com.mhd.basic.domain.storageSection.repository.todo.StorageSectionDO;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.basic.interfaces.dto.shipperLeaseDetailsApi.ShipperLeaseDetailsDTO;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.domain.WarehouseFeignPO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.system.service.ISysDictTypeService;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.scheduling.annotation.Scheduled;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.*;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 租赁管理ApplicationService
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class LeaseApplicationService {
|
||||
|
||||
@Autowired
|
||||
private LeaseDomainService leaseDomainService;
|
||||
|
||||
@Autowired
|
||||
private ILeaseService leaseService;
|
||||
|
||||
@Autowired
|
||||
private ISysDictTypeService dictTypeService;
|
||||
|
||||
@Autowired
|
||||
private WmsServiceFeign wmsServiceFeign;
|
||||
|
||||
@Autowired
|
||||
private StorageSectionApplicationService storageSectionApplicationService;
|
||||
|
||||
@Autowired
|
||||
private IShipperLeaseDetailsService shipperLeaseDetailsService;
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
|
||||
public List<LeasePO> queryList(LeaseDO leaseDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null){
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
|
||||
// 数据权限:根据organizationId来设置查询权限
|
||||
// organizationId等于2827时查询全部,其他仅查询各自组织的信息
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId,使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (leaseDO.getOrganizationId() == null) {
|
||||
leaseDO.setOrganizationId(null);
|
||||
leaseDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
leaseDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
// 如果前端传递了organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (leaseDO.getOrganizationId() != null && !leaseDO.getOrganizationId().equals(loginUserOrganizationId)) {
|
||||
// 前端传递了其他组织的organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
leaseDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
return leaseDomainService.queryList(leaseDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增租赁管理
|
||||
*/
|
||||
public Boolean insert(LeaseDO leaseDO) {
|
||||
// 设置当前登录用户的组织信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
leaseDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
leaseDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
leaseDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
List<Lease> timeOverlapSimple = isTimeOverlapSimple(leaseDO.getCargoOwnerName(), leaseDO.getStartDate(), leaseDO.getEndDate(), null);
|
||||
if (ObjectUtil.isNotEmpty(timeOverlapSimple)) {
|
||||
throw new ServiceException("同一货主租赁信息时间不能重叠");
|
||||
}
|
||||
setWarehouseInfo(leaseDO);
|
||||
return leaseDomainService.insert(leaseDO);
|
||||
}
|
||||
|
||||
@Autowired
|
||||
private SystemServiceFeign systemServiceFeign;
|
||||
|
||||
private void setWarehouseInfo(LeaseDO leaseDO) {
|
||||
AjaxResult ajaxResult = systemServiceFeign.getWarehouseInfoByWarehouseId(leaseDO.getWarehouseId());
|
||||
if(!"200".equals(String.valueOf(ajaxResult.get("code")))){
|
||||
throw new ServiceException("获取仓库信息失败");
|
||||
}
|
||||
WarehouseFeignPO warehouseFeignPO = com.alibaba.fastjson.JSON.parseObject(com.alibaba.fastjson2.JSONObject.toJSONString(ajaxResult.get("data")), WarehouseFeignPO.class);
|
||||
leaseDO.setWarehouseName(warehouseFeignPO.getWarehouseName());
|
||||
}
|
||||
|
||||
private List<Lease> isTimeOverlapSimple(String cargoOwnerName, Date startDate, Date endDate, Long excludeId) {
|
||||
LambdaQueryWrapper<Lease> wrapper = new LambdaQueryWrapper<>();
|
||||
wrapper.eq(Lease::getCargoOwnerName, cargoOwnerName)
|
||||
.eq(Lease::getDelFlag, 1) // 只查询正常状态
|
||||
.le(Lease::getStartDate, endDate)
|
||||
.ge(Lease::getEndDate, startDate);
|
||||
if (excludeId != null) {
|
||||
wrapper.ne(Lease::getId, excludeId);
|
||||
}
|
||||
return leaseService.list(wrapper);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改租赁管理
|
||||
*/
|
||||
public Boolean update(LeaseDO leaseDO) {
|
||||
List<Lease> timeOverlapSimple = isTimeOverlapSimple(leaseDO.getCargoOwnerName(), leaseDO.getStartDate(), leaseDO.getEndDate(), leaseDO.getId());
|
||||
if (ObjectUtil.isNotEmpty(timeOverlapSimple)) {
|
||||
throw new ServiceException("同一货主租赁信息时间不能重叠");
|
||||
}
|
||||
return leaseDomainService.update(leaseDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除租赁管理
|
||||
*/
|
||||
public boolean delete(Long[] leaseIds) {
|
||||
return leaseDomainService.delete(leaseIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租赁管理详细信息
|
||||
*/
|
||||
public LeasePO getInfo(Long leaseId)
|
||||
{
|
||||
return leaseDomainService.getInfo(leaseId);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 批量作废租赁
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/13 9:46
|
||||
* @param leaseIds
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean nullifyByIds(List<Long> leaseIds){
|
||||
return leaseDomainService.nullifyByIds(leaseIds);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 货主租赁明细
|
||||
*/
|
||||
@Scheduled(cron = "0 0 1 * * ?")
|
||||
public void shipperLeaseDetails() {
|
||||
LeaseDO leaseDO = new LeaseDO();
|
||||
leaseDO.setTime(new Date());
|
||||
//查询租赁
|
||||
List<LeasePO> leasePOS = queryList(leaseDO);
|
||||
// List<LeasePO> leasePOS = leaseDomainService.queryList(leaseDO);
|
||||
List<LeasePO> entireUnit = leasePOS.stream()
|
||||
.filter(lease -> lease.getLeaseType().equals("整租"))
|
||||
.collect(Collectors.toList());
|
||||
List<LeasePO> casualRental = leasePOS.stream()
|
||||
.filter(lease -> lease.getLeaseType().equals("散租"))
|
||||
.collect(Collectors.toList());
|
||||
List<ShipperLeaseDetails> shipperLeaseDetailsList = new ArrayList<>(); //建表后保存
|
||||
for (LeasePO en : entireUnit) {//整租
|
||||
ShipperLeaseDetails shipperLeaseDetails = new ShipperLeaseDetails();
|
||||
BeanUtils.copyProperties(en, shipperLeaseDetails);
|
||||
shipperLeaseDetails.setBusinessDate(new Date());
|
||||
shipperLeaseDetailsList.add(shipperLeaseDetails);
|
||||
}
|
||||
//当前货主当前仓库,库存查询页面所有面积加起来就是散租面积
|
||||
for (LeasePO ca : casualRental) {//散租
|
||||
ShipperLeaseDetails shipperLeaseDetails = new ShipperLeaseDetails();
|
||||
BeanUtils.copyProperties(ca, shipperLeaseDetails);
|
||||
shipperLeaseDetails.setBusinessDate(new Date());
|
||||
//物料库存
|
||||
MaterialInventoryDTO materialInventoryDTO = new MaterialInventoryDTO();
|
||||
materialInventoryDTO.setShipperId(ca.getShipperId());
|
||||
materialInventoryDTO.setWarehouseId(ca.getWarehouseId());
|
||||
AjaxResult ajaxResult = wmsServiceFeign.materialInventoryApiListAll(materialInventoryDTO);
|
||||
BigDecimal area = BigDecimal.ZERO;
|
||||
if(String.valueOf(ajaxResult.get("code")).equals("200")) {
|
||||
JSONArray data = JSONObject.parseArray(JSON.toJSONString(ajaxResult.get("data")));
|
||||
for (Object datum : data) {
|
||||
JSONObject json = (JSONObject) datum;
|
||||
BigDecimal area1 = json.getBigDecimal("area");
|
||||
if (area1 == null) {
|
||||
area1 = BigDecimal.ZERO;
|
||||
}
|
||||
area = area.add(area1);
|
||||
}
|
||||
}
|
||||
shipperLeaseDetails.setLeaseArea(area);
|
||||
shipperLeaseDetailsList.add(shipperLeaseDetails);
|
||||
}
|
||||
// 保存货主租赁明细(新建表)
|
||||
if (shipperLeaseDetailsList.size() > 0) {
|
||||
shipperLeaseDetailsService.saveBatch(shipperLeaseDetailsList);
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 计算仓库出租率
|
||||
* warehouseId 仓库id
|
||||
* businessDateStart 业务开始时间
|
||||
* businessDateEnd 业务结束时间
|
||||
*/
|
||||
public List<WarehouseOccupancyRate> warehouseOccupancyRate(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
//仓库id 和 开始结束时间作为查询条件 查数据库 差出来当前仓库所有的
|
||||
List<ShipperLeaseDetailsPO> shipperLeaseDetailsList = shipperLeaseDetailsService.queryList(shipperLeaseDetailsDO);
|
||||
ShipperLeaseDetailsPO shipperLeaseDetailsPO = shipperLeaseDetailsList.get(0);
|
||||
//按业务日期分组,并按日期排序
|
||||
TreeMap<Date, List<ShipperLeaseDetailsPO>> groupedByDate = shipperLeaseDetailsList.stream().collect(
|
||||
Collectors.groupingBy(
|
||||
ShipperLeaseDetailsPO::getBusinessDate,
|
||||
TreeMap::new,
|
||||
Collectors.toList()
|
||||
)
|
||||
);
|
||||
//获取总面积
|
||||
BigDecimal totalArea = BigDecimal.ZERO;
|
||||
StorageSectionDO storageSectionDO = new StorageSectionDO();
|
||||
storageSectionDO.setWarehouseId(shipperLeaseDetailsDO.getWarehouseId());
|
||||
storageSectionDO.setOpeningUp(1);
|
||||
List<StorageSectionPO> storageSectionPOS = storageSectionApplicationService.queryList(storageSectionDO);
|
||||
for (StorageSectionPO storageSectionPO : storageSectionPOS) {
|
||||
totalArea = totalArea.add(storageSectionPO.getStorageRegion());
|
||||
}
|
||||
|
||||
List<WarehouseOccupancyRate> warehouseOccupancyRatesList = new ArrayList<>();
|
||||
//组装仓库返回数据
|
||||
BigDecimal finalTotalArea = totalArea;
|
||||
groupedByDate.forEach((date, shipperLeaseDetails) -> {
|
||||
WarehouseOccupancyRate warehouseOccupancyRate = new WarehouseOccupancyRate();
|
||||
warehouseOccupancyRate.setBusinessDate(date);
|
||||
BigDecimal entireLeaseArea = BigDecimal.ZERO;
|
||||
BigDecimal fractionalLeaseArea = BigDecimal.ZERO;
|
||||
//计算整租和散租
|
||||
for (ShipperLeaseDetailsPO shipperLeaseDetail : shipperLeaseDetails) {
|
||||
if (shipperLeaseDetail.getLeaseType().equals("整租")){
|
||||
entireLeaseArea = entireLeaseArea.add(shipperLeaseDetail.getLeaseArea());
|
||||
}else {
|
||||
fractionalLeaseArea = fractionalLeaseArea.add(shipperLeaseDetail.getLeaseArea());
|
||||
}
|
||||
warehouseOccupancyRate.setWarehouseName(shipperLeaseDetail.getWarehouseName());
|
||||
warehouseOccupancyRate.setBusinessDate(date);
|
||||
warehouseOccupancyRate.setWarehouseId(shipperLeaseDetail.getWarehouseId());
|
||||
}
|
||||
warehouseOccupancyRate.setEntireLeaseArea(entireLeaseArea);
|
||||
warehouseOccupancyRate.setFractionalLeaseArea(fractionalLeaseArea);
|
||||
warehouseOccupancyRate.setTotalArea(finalTotalArea);
|
||||
BigDecimal dailyRentalRate = entireLeaseArea.add(fractionalLeaseArea).divide(finalTotalArea, 2, BigDecimal.ROUND_HALF_UP);
|
||||
warehouseOccupancyRate.setDailyRentalRate(dailyRentalRate);
|
||||
warehouseOccupancyRatesList.add(warehouseOccupancyRate);
|
||||
});
|
||||
return warehouseOccupancyRatesList;
|
||||
}
|
||||
|
||||
// /**
|
||||
// * @description 设置数据字典键值
|
||||
// * @author ZhouGY
|
||||
// * @date 2024/4/7 14:33
|
||||
// * @param containerDO
|
||||
// */
|
||||
// private void setDataDict(LeaseDO leaseDO){
|
||||
// //翻译租赁类型
|
||||
// List<SysDictData> storageTypeDictDataList = dictTypeService.selectDictDataByType(DictCode.CONTAINER_TYPE.getCode());
|
||||
// if (null == storageTypeDictDataList) {
|
||||
// throw new ServiceException("租赁类型数据字典不存在 请联系管理员");
|
||||
// }
|
||||
// SysDictData storageTypeDictData = storageTypeDictDataList.stream().filter(info -> ObjectUtil.equal(info.getDictValue(), containerDO.getContainerType())).findAny().orElse(null);
|
||||
// if (null == storageTypeDictData) {
|
||||
// throw new ServiceException("租赁类型【" + leaseDO.getContainerType() + "】数据字典不存在 请联系管理员");
|
||||
// }
|
||||
// leaseDO.setContainerTypeName(storageTypeDictData.getDictLabel());
|
||||
// }
|
||||
}
|
||||
+56
-1
@@ -69,9 +69,37 @@ public class AddressBookApplicationService
|
||||
// 获取登录人id
|
||||
Long userId = SecurityUtils.getLoginUser().getUserid();
|
||||
addressBookPo.setUserId(userId);
|
||||
|
||||
// 添加组织数据权限过滤
|
||||
applyOrganizationDataPermissionForAddressBook(addressBookPo);
|
||||
|
||||
return addressBookDomainService.selectAddressBookList(addressBookPo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 应用组织数据权限过滤(地址簿)
|
||||
* 通过用户表关联来过滤组织数据
|
||||
*/
|
||||
private void applyOrganizationDataPermissionForAddressBook(AddressBookPo addressBookPo) {
|
||||
try {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
|
||||
// 如果当前登录用户的organizationId为2827(南光组织),可以查询全部组织数据
|
||||
// 其他组织只能查询自己组织的数据
|
||||
if (loginUserOrganizationId != null && !loginUserOrganizationId.equals(2827L)) {
|
||||
// 其他组织:需要通过用户表关联来过滤,只查询同一组织下用户创建的地址簿
|
||||
// 由于AddressBook表只有userId字段,需要在XML中通过用户表关联来过滤
|
||||
addressBookPo.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
// 如果是2827组织,不设置organizationId,可以查询全部
|
||||
}
|
||||
} catch (Exception e) {
|
||||
// 如果获取登录用户信息失败,不添加过滤条件,避免影响正常查询
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增地址簿
|
||||
*
|
||||
@@ -156,12 +184,39 @@ public class AddressBookApplicationService
|
||||
*/
|
||||
public List<CommonRoutePo> selectCommonRouteList(CommonRouteDo commonRouteDo){
|
||||
// 获取登录人id
|
||||
// Long userId = SecurityUtils.getUserId()==0 ? 4L:SecurityUtils.getLoginUser().getUserid();
|
||||
Long userId = SecurityUtils.getLoginUser().getUserid();
|
||||
commonRouteDo.setCreateBy(userId);
|
||||
|
||||
// 添加组织数据权限过滤
|
||||
applyOrganizationDataPermissionForCommonRoute(commonRouteDo);
|
||||
|
||||
return commonRouteDomainService.selectCommonRouteList(commonRouteDo);
|
||||
}
|
||||
|
||||
/**
|
||||
* 应用组织数据权限过滤(常用路线)
|
||||
* 通过用户表关联来过滤组织数据
|
||||
*/
|
||||
private void applyOrganizationDataPermissionForCommonRoute(CommonRouteDo commonRouteDo) {
|
||||
try {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
|
||||
// 如果当前登录用户的organizationId为2827(南光组织),可以查询全部组织数据
|
||||
// 其他组织只能查询自己组织的数据
|
||||
if (loginUserOrganizationId != null && !loginUserOrganizationId.equals(2827L)) {
|
||||
// 其他组织:需要通过用户表关联来过滤,只查询同一组织下用户创建的常用路线
|
||||
// 由于CommonRoute表只有userId字段,需要在XML中通过用户表关联来过滤
|
||||
commonRouteDo.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
// 如果是2827组织,不设置organizationId,可以查询全部
|
||||
}
|
||||
} catch (Exception e) {
|
||||
// 如果获取登录用户信息失败,不添加过滤条件,避免影响正常查询
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增常用路线
|
||||
*
|
||||
|
||||
+24
-1
@@ -1,15 +1,22 @@
|
||||
package com.mhd.basic.application.service.batch;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.mhd.basic.domain.batch.repository.po.BatchPO;
|
||||
import com.mhd.basic.domain.batch.repository.todo.BatchDO;
|
||||
import com.mhd.basic.domain.batch.service.BatchDomainService;
|
||||
import com.mhd.basic.domain.batchDetail.entity.BatchDetail;
|
||||
import com.mhd.basic.domain.batchDetail.repository.facade.IBatchDetailService;
|
||||
import com.mhd.basic.domain.batchDetail.repository.po.BatchDetailPO;
|
||||
import com.mhd.basic.domain.pack.repository.todo.PackDO;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
/**
|
||||
* 批次管理ApplicationService
|
||||
@@ -22,6 +29,8 @@ import java.util.List;
|
||||
public class BatchApplicationService {
|
||||
@Autowired
|
||||
private BatchDomainService batchDomainService;
|
||||
@Autowired
|
||||
private IBatchDetailService batchDetailService;
|
||||
|
||||
|
||||
/**
|
||||
@@ -36,7 +45,21 @@ public class BatchApplicationService {
|
||||
batchDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
}
|
||||
return batchDomainService.queryList(batchDO);
|
||||
List<BatchPO> batchPOS = batchDomainService.queryList(batchDO);
|
||||
for (BatchPO batchPO : batchPOS) {
|
||||
List<BatchDetail> batchDetailList = batchDetailService.list(new LambdaQueryWrapper<BatchDetail>()
|
||||
.eq(BatchDetail::getBatchId, batchPO.getBatchId())
|
||||
.eq(BatchDetail::getDelFlag, "1"));
|
||||
List<BatchDetailPO> batchDetailPOS = new ArrayList<>();
|
||||
// 逐个对象拷贝
|
||||
for (BatchDetail detail : batchDetailList) {
|
||||
BatchDetailPO detailPO = new BatchDetailPO();
|
||||
BeanUtils.copyProperties(detail, detailPO);
|
||||
batchDetailPOS.add(detailPO);
|
||||
}
|
||||
batchPO.setBatchDetailList(batchDetailPOS);
|
||||
}
|
||||
return batchPOS;
|
||||
}
|
||||
|
||||
|
||||
|
||||
+4
@@ -45,6 +45,10 @@ public class BatchDetailApplicationService {
|
||||
batchDetailDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
}
|
||||
// 如果未指定isDisplay,默认只查询显示的数据(isDisplay=1)
|
||||
if (batchDetailDO.getIsDisplay() == null) {
|
||||
batchDetailDO.setIsDisplay(1);
|
||||
}
|
||||
return batchDetailDomainService.queryList(batchDetailDO);
|
||||
}
|
||||
|
||||
|
||||
+30
-23
@@ -38,10 +38,30 @@ public class ContainerApplicationService {
|
||||
|
||||
public List<ContainerPO> queryList(ContainerDO containerDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null){
|
||||
if (loginUser != null && loginUser.getUserPo() != null){
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
containerDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
|
||||
// 数据权限:根据organizationId来设置查询权限
|
||||
// organizationId等于2827时查询全部,其他仅查询各自组织的信息
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId,使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (containerDO.getOrganizationId() == null) {
|
||||
containerDO.setOrganizationId(null);
|
||||
containerDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
containerDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
// 如果前端传递了organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (containerDO.getOrganizationId() != null && !containerDO.getOrganizationId().equals(loginUserOrganizationId)) {
|
||||
// 前端传递了其他组织的organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
containerDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
return containerDomainService.queryList(containerDO);
|
||||
@@ -52,8 +72,13 @@ public class ContainerApplicationService {
|
||||
* 新增容器管理
|
||||
*/
|
||||
public Boolean insert(ContainerDO containerDO) {
|
||||
//翻译库区类型
|
||||
setDataDict(containerDO);
|
||||
// 设置当前登录用户的组织信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
containerDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
containerDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
containerDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
return containerDomainService.insert(containerDO);
|
||||
}
|
||||
|
||||
@@ -90,22 +115,4 @@ public class ContainerApplicationService {
|
||||
return containerDomainService.nullifyByIds(containerIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 设置数据字典键值
|
||||
* @author ZhouGY
|
||||
* @date 2024/4/7 14:33
|
||||
* @param containerDO
|
||||
*/
|
||||
private void setDataDict(ContainerDO containerDO){
|
||||
//翻译容器类型
|
||||
List<SysDictData> storageTypeDictDataList = dictTypeService.selectDictDataByType(DictCode.CONTAINER_TYPE.getCode());
|
||||
if (null == storageTypeDictDataList) {
|
||||
throw new ServiceException("容器类型数据字典不存在 请联系管理员");
|
||||
}
|
||||
SysDictData storageTypeDictData = storageTypeDictDataList.stream().filter(info -> ObjectUtil.equal(info.getDictValue(), containerDO.getContainerType())).findAny().orElse(null);
|
||||
if (null == storageTypeDictData) {
|
||||
throw new ServiceException("容器类型【" + containerDO.getContainerType() + "】数据字典不存在 请联系管理员");
|
||||
}
|
||||
containerDO.setContainerTypeName(storageTypeDictData.getDictLabel());
|
||||
}
|
||||
}
|
||||
|
||||
+174
-11
@@ -22,6 +22,7 @@ import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.common.core.domain.po.UserPo;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -50,29 +51,131 @@ public class ExpenseAccountApplicationService {
|
||||
/**
|
||||
* 分页查询费用科目列表
|
||||
*/
|
||||
|
||||
public List<ExpenseAccountPO> queryList(ExpenseAccountDO expenseAccountDO) {
|
||||
setTopOrganizationIdLogin(expenseAccountDO);
|
||||
return expenseAccountDomainService.queryList(expenseAccountDO);
|
||||
try {
|
||||
log.info("开始查询费用科目列表,参数:organizationId={}, topOrganizationId={}, expenseAccountDO={}",
|
||||
expenseAccountDO.getOrganizationId(), expenseAccountDO.getTopOrganizationId(), expenseAccountDO);
|
||||
setDataPermission(expenseAccountDO);
|
||||
|
||||
// 处理 createByName 和 updateByName 字段:
|
||||
// 问题:ExpenseAccountAssembler 在查询场景下可能会自动设置 createByName 和 updateByName 为当前登录用户名
|
||||
// 这会导致 SQL 中添加 create_by_name LIKE '%nanguang%' 和 update_by_name LIKE '%nanguang%' 条件
|
||||
// 解决方案:
|
||||
// 1. 如果查询所有组织(organizationId 和 topOrganizationId 都为 null),清空这些字段(除非前端明确传递了这些字段作为查询条件)
|
||||
// 2. 如果查询指定组织(organizationId 不为 null),且是南光组织查询,如果 createByName 或 updateByName 等于当前登录用户名,清空它们
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
String currentUserName = loginUser.getUsername();
|
||||
|
||||
// 先保存前端传递的 createByName 和 updateByName(用于判断是否是前端传递的查询条件)
|
||||
String frontendCreateByName = expenseAccountDO.getCreateByName();
|
||||
String frontendUpdateByName = expenseAccountDO.getUpdateByName();
|
||||
|
||||
if (expenseAccountDO.getOrganizationId() == null && expenseAccountDO.getTopOrganizationId() == null) {
|
||||
// 查询所有组织的数据时,不应该通过创建者或更新者来过滤,清空这些字段
|
||||
// 除非前端明确传递了这些字段作为查询条件
|
||||
if (frontendCreateByName == null || frontendCreateByName.isEmpty() ||
|
||||
(currentUserName != null && frontendCreateByName.equals(currentUserName))) {
|
||||
// 前端未传递,或者等于当前登录用户名(可能是 Assembler 自动设置的),清空
|
||||
log.info("查询所有组织数据,清空 createByName 过滤条件(前端未传递或由 Assembler 自动设置)");
|
||||
expenseAccountDO.setCreateByName(null);
|
||||
}
|
||||
if (frontendUpdateByName == null || frontendUpdateByName.isEmpty() ||
|
||||
(currentUserName != null && frontendUpdateByName.equals(currentUserName))) {
|
||||
// 前端未传递,或者等于当前登录用户名(可能是 Assembler 自动设置的),清空
|
||||
log.info("查询所有组织数据,清空 updateByName 过滤条件(前端未传递或由 Assembler 自动设置)");
|
||||
expenseAccountDO.setUpdateByName(null);
|
||||
}
|
||||
} else if (expenseAccountDO.getOrganizationId() != null && loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织查询指定组织时,如果 createByName 或 updateByName 等于当前登录用户名,说明可能是 Assembler 自动设置的
|
||||
// 清空这些字段,避免限制查询结果(因为其他组织的数据可能不是当前登录用户创建的)
|
||||
if (currentUserName != null) {
|
||||
if (expenseAccountDO.getCreateByName() != null && expenseAccountDO.getCreateByName().equals(currentUserName)) {
|
||||
log.info("南光组织查询指定组织数据(organizationId={}),清空 createByName 过滤条件(可能由 Assembler 自动设置)",
|
||||
expenseAccountDO.getOrganizationId());
|
||||
expenseAccountDO.setCreateByName(null);
|
||||
}
|
||||
if (expenseAccountDO.getUpdateByName() != null && expenseAccountDO.getUpdateByName().equals(currentUserName)) {
|
||||
log.info("南光组织查询指定组织数据(organizationId={}),清空 updateByName 过滤条件(可能由 Assembler 自动设置)",
|
||||
expenseAccountDO.getOrganizationId());
|
||||
expenseAccountDO.setUpdateByName(null);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
log.info("设置组织ID后,查询参数:organizationId={}, topOrganizationId={}, createByName={}, updateByName={}",
|
||||
expenseAccountDO.getOrganizationId(), expenseAccountDO.getTopOrganizationId(),
|
||||
expenseAccountDO.getCreateByName(), expenseAccountDO.getUpdateByName());
|
||||
List<ExpenseAccountPO> result = expenseAccountDomainService.queryList(expenseAccountDO);
|
||||
log.info("查询费用科目列表成功,返回数据条数:{}", result != null ? result.size() : 0);
|
||||
return result;
|
||||
} catch (Exception e) {
|
||||
log.error("查询费用科目列表异常", e);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
public List<ExpenseAccountPO> treeCostSubject(ExpenseAccountDO expenseAccountDO){
|
||||
setTopOrganizationIdLogin(expenseAccountDO);
|
||||
setDataPermission(expenseAccountDO);
|
||||
return expenseAccountDomainService.treeCostSubject(expenseAccountDO);
|
||||
}
|
||||
|
||||
public List<ExpenseAccountPO> subjectTreeCost(ExpenseAccountDO expenseAccountDO){
|
||||
setTopOrganizationIdLogin(expenseAccountDO);
|
||||
setDataPermission(expenseAccountDO);
|
||||
return expenseAccountDomainService.treeCostSubject(expenseAccountDO);
|
||||
}
|
||||
|
||||
|
||||
private void setTopOrganizationIdLogin(ExpenseAccountDO expenseAccountDO){
|
||||
/**
|
||||
* 根据当前登录用户的组织信息实现数据隔离
|
||||
* 当前登录用户为组织ID字段organization_id为2827时可查全部组织数据,其他组织只能查自己
|
||||
*/
|
||||
private void setDataPermission(ExpenseAccountDO expenseAccountDO){
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null){
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
expenseAccountDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
if (loginUser == null || loginUser.getUserPo() == null) {
|
||||
log.warn("费用科目查询 - 未获取到登录用户信息,跳过数据权限过滤");
|
||||
return;
|
||||
}
|
||||
|
||||
UserPo userPo = loginUser.getUserPo();
|
||||
Long loginUserOrganizationId = userPo.getOrganizationId();
|
||||
Long topOrganizationId = userPo.getTopOrganizationId();
|
||||
|
||||
// 先保存前端传递的 organizationId(如果存在)
|
||||
Long frontendOrganizationId = expenseAccountDO.getOrganizationId();
|
||||
|
||||
// 数据权限:根据 organizationId 来设置查询权限
|
||||
// 当前登录用户的 organizationId 为 2827 时,可查全部组织数据;其他组织只能查自己
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId,使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
expenseAccountDO.setOrganizationId(frontendOrganizationId);
|
||||
expenseAccountDO.setTopOrganizationId(null);
|
||||
} else {
|
||||
expenseAccountDO.setOrganizationId(null);
|
||||
expenseAccountDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置 organizationId,只查询当前组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (!frontendOrganizationId.equals(loginUserOrganizationId)) {
|
||||
log.warn("费用科目查询 - 前端传递的组织ID {} 与当前登录用户的组织ID {} 不一致,使用当前登录用户的组织ID进行过滤",
|
||||
frontendOrganizationId, loginUserOrganizationId);
|
||||
expenseAccountDO.setOrganizationId(loginUserOrganizationId);
|
||||
} else {
|
||||
expenseAccountDO.setOrganizationId(frontendOrganizationId);
|
||||
}
|
||||
expenseAccountDO.setTopOrganizationId(topOrganizationId);
|
||||
} else {
|
||||
// 前端没有传递 organizationId,使用当前登录用户的组织ID
|
||||
if (loginUserOrganizationId != null) {
|
||||
expenseAccountDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
expenseAccountDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -276,6 +379,35 @@ public class ExpenseAccountApplicationService {
|
||||
expenseAccountDO.setUpdateByName(loginUser.getUsername());
|
||||
return expenseAccountDomainService.update(expenseAccountDO);
|
||||
}
|
||||
/**
|
||||
* 修改创建订单是否固定显示 0-否 1-是
|
||||
* @param expenseAccountDTO
|
||||
* @return
|
||||
*/
|
||||
public boolean changeFixedOrderDisplay(ExpenseAccountDTO expenseAccountDTO) {
|
||||
//获取登录用户信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
}
|
||||
//根据id修改启用状态停用状态
|
||||
if(expenseAccountDTO.getExpenseAccountId() == null){
|
||||
throw new ServiceException("费用科目id不能为空");
|
||||
}
|
||||
if(expenseAccountDTO.getFixedOrderDisplay() == null){
|
||||
throw new ServiceException("状态不能为空");
|
||||
}
|
||||
if(expenseAccountDTO.getFixedOrderDisplay() != 0 && expenseAccountDTO.getFixedOrderDisplay()!=1){
|
||||
throw new ServiceException("状态错误");
|
||||
}
|
||||
ExpenseAccountDO expenseAccountDO = new ExpenseAccountDO();
|
||||
expenseAccountDO.setExpenseAccountId(expenseAccountDTO.getExpenseAccountId());
|
||||
expenseAccountDO.setFixedOrderDisplay(expenseAccountDTO.getFixedOrderDisplay());
|
||||
expenseAccountDO.setUpdateBy(loginUser.getUserid());
|
||||
expenseAccountDO.setUpdateTime(new Date());
|
||||
expenseAccountDO.setUpdateByName(loginUser.getUsername());
|
||||
return expenseAccountDomainService.update(expenseAccountDO);
|
||||
}
|
||||
/**
|
||||
* 根据编码查询费用科目信息
|
||||
*/
|
||||
@@ -287,13 +419,44 @@ public class ExpenseAccountApplicationService {
|
||||
}
|
||||
|
||||
public List<QueryExpenseAccountPO> selectExpenseAccount(SearchExpenseAccountDO searchExpenseAccountDO){
|
||||
setDataPermissionForSearch(searchExpenseAccountDO);
|
||||
return expenseAccountDomainService.selectExpenseAccount(searchExpenseAccountDO);
|
||||
}
|
||||
|
||||
public List<QueryExpenseAccountPO> selectOtherExpenseAccount(SearchExpenseAccountDO searchExpenseAccountDO){
|
||||
setDataPermissionForSearch(searchExpenseAccountDO);
|
||||
return expenseAccountDomainService.selectOtherExpenseAccount(searchExpenseAccountDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 为 SearchExpenseAccountDO 设置数据权限
|
||||
*/
|
||||
private void setDataPermissionForSearch(SearchExpenseAccountDO searchExpenseAccountDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser == null || loginUser.getUserPo() == null) {
|
||||
log.warn("费用科目查询 - 未获取到登录用户信息,跳过数据权限过滤");
|
||||
return;
|
||||
}
|
||||
|
||||
UserPo userPo = loginUser.getUserPo();
|
||||
Long loginUserOrganizationId = userPo.getOrganizationId();
|
||||
Long topOrganizationId = userPo.getTopOrganizationId();
|
||||
|
||||
// 数据权限:根据 organizationId 来设置查询权限
|
||||
// 当前登录用户的 organizationId 为 2827 时,可查全部组织数据;其他组织只能查自己
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据,不设置组织过滤条件
|
||||
searchExpenseAccountDO.setOrganizationId(null);
|
||||
searchExpenseAccountDO.setTopOrganizationId(null);
|
||||
} else {
|
||||
// 其他组织:只查询当前组织的数据
|
||||
if (loginUserOrganizationId != null) {
|
||||
searchExpenseAccountDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
searchExpenseAccountDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
}
|
||||
|
||||
public List<QueryExpenseAccountPO> selectSocialVehicleExpenseAccount(){
|
||||
return expenseAccountDomainService.selectSocialVehicleExpenseAccount();
|
||||
}
|
||||
|
||||
+5
-1
@@ -120,7 +120,11 @@ public class MaterialBaseInfoApplicationService {
|
||||
throw new ServiceException("获取货主信息失败");
|
||||
}
|
||||
UserPo userPo = JSON.parseObject(JSONObject.toJSONString(ajaxResult.get("data")), UserPo.class);
|
||||
materialBaseInfoDO.setShipperName(userPo.getUserName());
|
||||
// 如果原始shipperName不为空,保留原始值(导入或手动输入时应该保留完整名称)
|
||||
// 只有在原始shipperName为空时,才使用查询到的userName
|
||||
if (materialBaseInfoDO.getShipperName() == null || materialBaseInfoDO.getShipperName().trim().isEmpty()) {
|
||||
materialBaseInfoDO.setShipperName(userPo.getUserName());
|
||||
}
|
||||
}
|
||||
|
||||
public List<MaterialStockInfoVo> getMaterialStockList(String shipperName, String materialName,
|
||||
|
||||
+179
-13
@@ -35,24 +35,190 @@ public class ServiceItemsManageApplicationService {
|
||||
/**
|
||||
* 分页查询服务项管理列表
|
||||
*/
|
||||
|
||||
public List<ServiceItemsManagePO> queryList(ServiceItemsManageDO serviceItemsManageDO) {
|
||||
setTopOrganizationIdLogin(serviceItemsManageDO);
|
||||
return serviceItemsManageDomainService.queryList(serviceItemsManageDO);
|
||||
try {
|
||||
log.info("开始查询服务项管理列表,参数:organizationId={}, topOrganizationId={}, serviceItemsManageDO={}",
|
||||
serviceItemsManageDO.getOrganizationId(), serviceItemsManageDO.getTopOrganizationId(), serviceItemsManageDO);
|
||||
|
||||
// 先保存前端传递的 organizationId 和 topOrganizationId(如果存在)
|
||||
// 注意:这里需要在设置权限逻辑之前保存,因为 Assembler 可能已经设置了这些值
|
||||
Long frontendOrganizationId = serviceItemsManageDO.getOrganizationId();
|
||||
Long frontendTopOrganizationId = serviceItemsManageDO.getTopOrganizationId();
|
||||
|
||||
// 获取登录用户信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
Long loginUserOrganizationId = null;
|
||||
Long loginUserTopOrganizationId = null;
|
||||
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
loginUserTopOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
}
|
||||
|
||||
log.info("登录用户信息:loginUserOrganizationId={}, loginUserTopOrganizationId={}, 前端传递:frontendOrganizationId={}, frontendTopOrganizationId={}",
|
||||
loginUserOrganizationId, loginUserTopOrganizationId, frontendOrganizationId, frontendTopOrganizationId);
|
||||
|
||||
// 数据权限:根据 organizationId 来设置查询权限
|
||||
// 当前登录用户的 organizationId 为 2827 时,可查全部组织数据;其他组织只能查自己
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId(包括2827或其他组织),使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId(包括2827或其他组织),使用前端传递的值进行过滤
|
||||
serviceItemsManageDO.setOrganizationId(frontendOrganizationId);
|
||||
serviceItemsManageDO.setTopOrganizationId(null); // 明确设置为 null,避免使用 topOrganizationId 条件
|
||||
log.info("南光组织查询指定组织:organizationId={}", frontendOrganizationId);
|
||||
} else {
|
||||
// 前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
serviceItemsManageDO.setOrganizationId(null);
|
||||
serviceItemsManageDO.setTopOrganizationId(null);
|
||||
log.info("南光组织查询所有组织:不设置组织过滤条件");
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
// 其他组织只能查询自己组织的数据,不能查询其他组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (!frontendOrganizationId.equals(loginUserOrganizationId)) {
|
||||
// 前端传递了其他组织的 organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
log.warn("服务项管理查询 - 前端传递的组织ID {} 与当前登录用户的组织ID {} 不一致,使用当前登录用户的组织ID进行过滤",
|
||||
frontendOrganizationId, loginUserOrganizationId);
|
||||
serviceItemsManageDO.setOrganizationId(loginUserOrganizationId);
|
||||
} else {
|
||||
// 前端传递的 organizationId 与当前登录用户的组织ID一致,使用前端传递的值
|
||||
serviceItemsManageDO.setOrganizationId(frontendOrganizationId);
|
||||
}
|
||||
if (loginUserTopOrganizationId != null) {
|
||||
serviceItemsManageDO.setTopOrganizationId(loginUserTopOrganizationId);
|
||||
}
|
||||
} else {
|
||||
// 前端没有传递 organizationId,使用当前登录用户的组织ID
|
||||
if (loginUserOrganizationId != null) {
|
||||
serviceItemsManageDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
if (loginUserTopOrganizationId != null) {
|
||||
serviceItemsManageDO.setTopOrganizationId(loginUserTopOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
// 处理 createByName 和 updateByName 字段:
|
||||
// 问题:Assembler 在查询场景下(serviceItemsManageId == null)会自动设置 createByName 和 updateByName 为当前登录用户名
|
||||
// 这会导致 SQL 中添加 create_by_name LIKE '%nanguang%' 和 update_by_name LIKE '%nanguang%' 条件
|
||||
// 解决方案:
|
||||
// 1. 如果查询所有组织(organizationId 和 topOrganizationId 都为 null),清空这些字段
|
||||
// 2. 如果查询指定组织(organizationId 不为 null),且是南光组织查询,如果 createByName 或 updateByName 等于当前登录用户名,清空它们
|
||||
// 因为查询其他组织的数据时,不应该通过当前登录用户的名称来过滤
|
||||
// 注意:这种方法可能会误判(如果前端确实传递了当前登录用户名作为查询条件),但这种情况很少见,且影响较小
|
||||
|
||||
String currentUserName = null;
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
currentUserName = loginUser.getUsername();
|
||||
}
|
||||
|
||||
if (serviceItemsManageDO.getOrganizationId() == null && serviceItemsManageDO.getTopOrganizationId() == null) {
|
||||
// 查询所有组织的数据时,不应该通过创建者或更新者来过滤,清空这些字段
|
||||
log.info("查询所有组织数据,清空 createByName 和 updateByName 过滤条件,避免限制查询结果");
|
||||
serviceItemsManageDO.setCreateByName(null);
|
||||
serviceItemsManageDO.setUpdateByName(null);
|
||||
} else if (serviceItemsManageDO.getOrganizationId() != null && loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织查询指定组织时,如果 createByName 或 updateByName 等于当前登录用户名,说明可能是 Assembler 自动设置的
|
||||
// 清空这些字段,避免限制查询结果(因为其他组织的数据可能不是当前登录用户创建的)
|
||||
if (currentUserName != null) {
|
||||
if (serviceItemsManageDO.getCreateByName() != null && serviceItemsManageDO.getCreateByName().equals(currentUserName)) {
|
||||
log.info("南光组织查询指定组织数据(organizationId={}),清空 createByName 过滤条件(可能由 Assembler 自动设置)",
|
||||
serviceItemsManageDO.getOrganizationId());
|
||||
serviceItemsManageDO.setCreateByName(null);
|
||||
}
|
||||
if (serviceItemsManageDO.getUpdateByName() != null && serviceItemsManageDO.getUpdateByName().equals(currentUserName)) {
|
||||
log.info("南光组织查询指定组织数据(organizationId={}),清空 updateByName 过滤条件(可能由 Assembler 自动设置)",
|
||||
serviceItemsManageDO.getOrganizationId());
|
||||
serviceItemsManageDO.setUpdateByName(null);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
log.info("设置组织ID后,查询参数:organizationId={}, topOrganizationId={}, createByName={}, updateByName={}",
|
||||
serviceItemsManageDO.getOrganizationId(), serviceItemsManageDO.getTopOrganizationId(),
|
||||
serviceItemsManageDO.getCreateByName(), serviceItemsManageDO.getUpdateByName());
|
||||
List<ServiceItemsManagePO> result = serviceItemsManageDomainService.queryList(serviceItemsManageDO);
|
||||
log.info("查询服务项管理列表成功,返回数据条数:{}", result != null ? result.size() : 0);
|
||||
return result;
|
||||
} catch (Exception e) {
|
||||
log.error("查询服务项管理列表异常", e);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
public List<ServiceItemsManagePO> getCostTypeList(ServiceItemsManageDO serviceItemsManageDO){
|
||||
setTopOrganizationIdLogin(serviceItemsManageDO);
|
||||
return serviceItemsManageDomainService.getCostsType(serviceItemsManageDO);
|
||||
}
|
||||
|
||||
private void setTopOrganizationIdLogin(ServiceItemsManageDO serviceItemsManageDO){
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null){
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
serviceItemsManageDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
try {
|
||||
log.info("开始查询费用类别列表,参数:{}", serviceItemsManageDO);
|
||||
|
||||
// 先保存前端传递的 organizationId(如果存在)
|
||||
Long frontendOrganizationId = serviceItemsManageDO.getOrganizationId();
|
||||
|
||||
// 获取登录用户信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
Long loginUserOrganizationId = null;
|
||||
Long topOrganizationId = null;
|
||||
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
}
|
||||
|
||||
// 数据权限:根据 organizationId 来设置查询权限
|
||||
// 当前登录用户的 organizationId 为 2827 时,可查全部组织数据;其他组织只能查自己
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId(包括2827),使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId(包括2827或其他组织),使用前端传递的值进行过滤
|
||||
serviceItemsManageDO.setOrganizationId(frontendOrganizationId);
|
||||
serviceItemsManageDO.setTopOrganizationId(null);
|
||||
} else {
|
||||
// 前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
serviceItemsManageDO.setOrganizationId(null);
|
||||
serviceItemsManageDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
// 其他组织只能查询自己组织的数据,不能查询其他组织的数据
|
||||
if (frontendOrganizationId != null) {
|
||||
// 前端传递了 organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (!frontendOrganizationId.equals(loginUserOrganizationId)) {
|
||||
// 前端传递了其他组织的 organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
log.warn("费用类别查询 - 前端传递的组织ID {} 与当前登录用户的组织ID {} 不一致,使用当前登录用户的组织ID进行过滤",
|
||||
frontendOrganizationId, loginUserOrganizationId);
|
||||
serviceItemsManageDO.setOrganizationId(loginUserOrganizationId);
|
||||
} else {
|
||||
// 前端传递的 organizationId 与当前登录用户的组织ID一致,使用前端传递的值
|
||||
serviceItemsManageDO.setOrganizationId(frontendOrganizationId);
|
||||
}
|
||||
if (topOrganizationId != null) {
|
||||
serviceItemsManageDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
} else {
|
||||
// 前端没有传递 organizationId,使用当前登录用户的组织ID
|
||||
if (loginUserOrganizationId != null) {
|
||||
serviceItemsManageDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
if (topOrganizationId != null) {
|
||||
serviceItemsManageDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
log.info("设置组织ID后,费用类别查询参数:organizationId={}, topOrganizationId={}",
|
||||
serviceItemsManageDO.getOrganizationId(), serviceItemsManageDO.getTopOrganizationId());
|
||||
List<ServiceItemsManagePO> result = serviceItemsManageDomainService.getCostsType(serviceItemsManageDO);
|
||||
log.info("查询费用类别列表成功,返回数据条数:{}", result != null ? result.size() : 0);
|
||||
return result;
|
||||
} catch (Exception e) {
|
||||
log.error("查询费用类别列表异常", e);
|
||||
throw e;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
+160
@@ -0,0 +1,160 @@
|
||||
package com.mhd.basic.application.service.shipperLeaseDetails;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.alibaba.fastjson.JSONArray;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.mhd.basic.application.service.storageSection.StorageSectionApplicationService;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.facade.ILeaseService;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.lease.service.LeaseDomainService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.WarehouseOccupancyRate;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.facade.IShipperLeaseDetailsService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.service.ShipperLeaseDetailsDomainService;
|
||||
import com.mhd.basic.domain.storageSection.repository.po.StorageSectionPO;
|
||||
import com.mhd.basic.domain.storageSection.repository.todo.StorageSectionDO;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.WmsServiceFeign;
|
||||
import com.mhd.system.api.domain.MaterialInventoryDTO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import com.mhd.system.service.ISysDictTypeService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.scheduling.annotation.Scheduled;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.TreeMap;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 货主租赁明细ApplicationService
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ShipperLeaseDetailsApplicationService {
|
||||
|
||||
@Autowired
|
||||
private ShipperLeaseDetailsDomainService shipperLeaseDetailsDomainService;
|
||||
|
||||
@Autowired
|
||||
private ISysDictTypeService dictTypeService;
|
||||
|
||||
/**
|
||||
* 分页查询货主租赁明细列表
|
||||
*/
|
||||
|
||||
public List<ShipperLeaseDetailsPO> queryList(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null){
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
|
||||
// 数据权限:根据organizationId来设置查询权限
|
||||
// organizationId等于2827时查询全部,其他仅查询各自组织的信息
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据
|
||||
// 如果前端传递了 organizationId,使用前端传递的值进行过滤
|
||||
// 如果前端没有传递 organizationId,清空组织过滤条件,查询所有组织的数据
|
||||
if (shipperLeaseDetailsDO.getOrganizationId() == null) {
|
||||
shipperLeaseDetailsDO.setOrganizationId(null);
|
||||
shipperLeaseDetailsDO.setTopOrganizationId(null);
|
||||
}
|
||||
} else {
|
||||
// 其他组织:设置organizationId,只查询当前组织的数据
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
shipperLeaseDetailsDO.setTopOrganizationId(topOrganizationId);
|
||||
}
|
||||
// 如果前端传递了organizationId,验证是否与当前登录用户的组织ID一致
|
||||
if (shipperLeaseDetailsDO.getOrganizationId() != null && !shipperLeaseDetailsDO.getOrganizationId().equals(loginUserOrganizationId)) {
|
||||
// 前端传递了其他组织的organizationId,强制使用当前登录用户的组织ID,防止越权查询
|
||||
shipperLeaseDetailsDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
}
|
||||
}
|
||||
return shipperLeaseDetailsDomainService.queryList(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增货主租赁明细
|
||||
*/
|
||||
public Boolean insert(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
// 设置当前登录用户的组织信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
shipperLeaseDetailsDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
shipperLeaseDetailsDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
shipperLeaseDetailsDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
return shipperLeaseDetailsDomainService.insert(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 修改货主租赁明细
|
||||
*/
|
||||
public Boolean update(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
return shipperLeaseDetailsDomainService.update(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除货主租赁明细
|
||||
*/
|
||||
public boolean delete(Long[] shipperLeaseDetailsIds) {
|
||||
return shipperLeaseDetailsDomainService.delete(shipperLeaseDetailsIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取货主租赁明细详细信息
|
||||
*/
|
||||
public ShipperLeaseDetailsPO getInfo(Long shipperLeaseDetailsId)
|
||||
{
|
||||
return shipperLeaseDetailsDomainService.getInfo(shipperLeaseDetailsId);
|
||||
}
|
||||
|
||||
/**
|
||||
* @description 批量作废租赁
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/13 9:46
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean nullifyByIds(List<Long> shipperLeaseDetailsIds){
|
||||
return shipperLeaseDetailsDomainService.nullifyByIds(shipperLeaseDetailsIds);
|
||||
}
|
||||
|
||||
|
||||
// /**
|
||||
// * @description 设置数据字典键值
|
||||
// * @author ZhouGY
|
||||
// * @date 2024/4/7 14:33
|
||||
// * @param containerDO
|
||||
// */
|
||||
// private void setDataDict(LeaseDO leaseDO){
|
||||
// //翻译租赁类型
|
||||
// List<SysDictData> storageTypeDictDataList = dictTypeService.selectDictDataByType(DictCode.CONTAINER_TYPE.getCode());
|
||||
// if (null == storageTypeDictDataList) {
|
||||
// throw new ServiceException("租赁类型数据字典不存在 请联系管理员");
|
||||
// }
|
||||
// SysDictData storageTypeDictData = storageTypeDictDataList.stream().filter(info -> ObjectUtil.equal(info.getDictValue(), containerDO.getContainerType())).findAny().orElse(null);
|
||||
// if (null == storageTypeDictData) {
|
||||
// throw new ServiceException("租赁类型【" + leaseDO.getContainerType() + "】数据字典不存在 请联系管理员");
|
||||
// }
|
||||
// leaseDO.setContainerTypeName(storageTypeDictData.getDictLabel());
|
||||
// }
|
||||
}
|
||||
+24
-2
@@ -49,8 +49,30 @@ public class StorageLocationApplicationService {
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
storageLocationDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
AssociationWarehouseCacheDO associationWarehouseCacheDO = SystemServiceCacheUtil.getAssociationWarehouseCache(loginUser.getUserid());
|
||||
storageLocationDO.setWarehouseId(associationWarehouseCacheDO.getWarehouseId());
|
||||
// 只有当前端没有明确传仓库条件时,才使用用户关联仓库缓存进行过滤;
|
||||
// 避免出现“单据仓库=常温仓,但库位列表仍显示保税仓”的错配问题。
|
||||
boolean hasWarehouseFilter = storageLocationDO.getWarehouseId() != null
|
||||
|| (storageLocationDO.getWarehouseCode() != null && !storageLocationDO.getWarehouseCode().trim().isEmpty())
|
||||
|| (storageLocationDO.getWarehouseName() != null && !storageLocationDO.getWarehouseName().trim().isEmpty());
|
||||
if (!hasWarehouseFilter) {
|
||||
try {
|
||||
AssociationWarehouseCacheDO associationWarehouseCacheDO = SystemServiceCacheUtil.getAssociationWarehouseCache(loginUser.getUserid());
|
||||
if (associationWarehouseCacheDO != null) {
|
||||
if (associationWarehouseCacheDO.getWarehouseId() != null) {
|
||||
storageLocationDO.setWarehouseId(associationWarehouseCacheDO.getWarehouseId());
|
||||
}
|
||||
if (associationWarehouseCacheDO.getWarehouseCode() != null && !associationWarehouseCacheDO.getWarehouseCode().trim().isEmpty()) {
|
||||
storageLocationDO.setWarehouseCode(associationWarehouseCacheDO.getWarehouseCode());
|
||||
}
|
||||
if (associationWarehouseCacheDO.getWarehouseName() != null && !associationWarehouseCacheDO.getWarehouseName().trim().isEmpty()) {
|
||||
storageLocationDO.setWarehouseName(associationWarehouseCacheDO.getWarehouseName());
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
// 获取失败不影响查询(允许查询所有仓库,或由前端传参控制)
|
||||
log.warn("获取用户关联仓库信息失败,将按前端条件查询库位数据,用户ID:{},错误:{}", loginUser.getUserid(), e.getMessage());
|
||||
}
|
||||
}
|
||||
}
|
||||
return storageLocationDomainService.queryList(storageLocationDO);
|
||||
}
|
||||
|
||||
+10
-3
@@ -43,9 +43,9 @@ public class WarehouseApplicationService {
|
||||
public List<WarehousePO> queryList(WarehouseDO warehouseDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null){
|
||||
Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
if (topOrganizationId != null && topOrganizationId != 1){
|
||||
warehouseDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
Long organizationId = loginUser.getUserPo().getOrganizationId();
|
||||
if (organizationId != null && organizationId != 1){
|
||||
warehouseDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
}
|
||||
}
|
||||
return warehouseDomainService.queryList(warehouseDO);
|
||||
@@ -56,6 +56,13 @@ public class WarehouseApplicationService {
|
||||
* 新增仓库
|
||||
*/
|
||||
public Boolean insert(WarehouseDO warehouseDO) {
|
||||
// 设置当前登录用户的组织信息
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getUserPo() != null) {
|
||||
warehouseDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
warehouseDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
warehouseDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
}
|
||||
//设置数据字典键值
|
||||
setDataDict(warehouseDO);
|
||||
return warehouseDomainService.insert(warehouseDO);
|
||||
|
||||
+3
@@ -126,4 +126,7 @@ public class CommonRouteDo extends BaseVOEntity
|
||||
|
||||
@ApiModelProperty(name = "运费单价")
|
||||
private BigDecimal freightUnitPrice;
|
||||
|
||||
@ApiModelProperty(name = "组织ID(用于数据权限过滤,内部使用)", hidden = true)
|
||||
private Long organizationId;
|
||||
}
|
||||
|
||||
+8
@@ -46,6 +46,10 @@ public class BatchDetail extends BaseVOEntity{
|
||||
@Excel(name = "批次标签")
|
||||
private String batchLabels;
|
||||
|
||||
@ApiModelProperty("字段名称")
|
||||
@Excel(name = "字段名称")
|
||||
private String fieldName;
|
||||
|
||||
@ApiModelProperty("输入控制: 1-必填 2-可选")
|
||||
@Excel(name = "输入控制: 1-必填 2-可选")
|
||||
private String inputControl;
|
||||
@@ -58,6 +62,10 @@ public class BatchDetail extends BaseVOEntity{
|
||||
@Excel(name = "属性选项")
|
||||
private String attributeOption;
|
||||
|
||||
@ApiModelProperty("是否显示: 0-不显示 1-显示")
|
||||
@Excel(name = "是否显示: 0-不显示 1-显示")
|
||||
private Integer isDisplay;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
+35
-3
@@ -62,24 +62,40 @@ public class BatchDetailImpl extends ServiceImpl<BatchDetailMapper, BatchDetail>
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
UserPo userPo = loginUser.getUserPo();
|
||||
List<BatchDetailDO> batchDetailDOList = batchDO.getBatchDetailList();
|
||||
//验证提交的数据是否存在重复
|
||||
// 验证本次提交的数据是否存在重复(同一批次内不允许重复标签)
|
||||
long count = batchDetailDOList.stream().map(BatchDetailDO::getBatchLabels).distinct().count();
|
||||
if (batchDetailDOList.size() != count){
|
||||
throw new ServiceException("批次标签不允许重复,请检查提交的数据");
|
||||
}
|
||||
|
||||
// 查询当前批次原有的标签明细
|
||||
List<BatchDetail> batchDetailDbList = batchDetailMapper.selectList(new QueryWrapper<BatchDetail>().lambda()
|
||||
.eq(BatchDetail::getBatchId, batchDO.getBatchId()));
|
||||
|
||||
// 如果数据库里已经有明细,并且这次前端传过来的所有明细都没有明细ID,
|
||||
// 说明前端没有带回原来的主键,这种情况我们视为“完全替换”:
|
||||
// 先物理删除当前批次下所有旧的明细,再按本次数据重新插入,避免命中数据库唯一索引冲突。
|
||||
boolean allNewWithoutId = CollectionUtil.isNotEmpty(batchDetailDOList)
|
||||
&& batchDetailDOList.stream().allMatch(detail -> detail.getBatchDetailId() == null);
|
||||
if (CollectionUtil.isNotEmpty(batchDetailDbList) && allNewWithoutId) {
|
||||
batchDetailMapper.delete(new QueryWrapper<BatchDetail>().lambda()
|
||||
.eq(BatchDetail::getBatchId, batchDO.getBatchId()));
|
||||
batchDetailDbList = new ArrayList<>();
|
||||
}
|
||||
List<BatchDetail> batchDetailListSave = new ArrayList<>();
|
||||
List<BatchDetail> batchDetailListSave2 = new ArrayList<>();
|
||||
List<BatchDetail> batchDetailListUpdates = new ArrayList<>();
|
||||
if (CollectionUtil.isNotEmpty(batchDetailDbList)){
|
||||
Map<String, BatchDetail> batchDetailMap = batchDetailDbList.stream().collect(Collectors.toMap(BatchDetail::getBatchLabels, Function.identity()));
|
||||
Map<Long, BatchDetail> batchDetailMap = batchDetailDbList.stream().collect(Collectors.toMap(BatchDetail::getBatchDetailId, Function.identity()));
|
||||
for (BatchDetailDO batchDetailDO : batchDetailDOList){
|
||||
BatchDetail batchDetailDb = batchDetailMap.get(batchDetailDO.getBatchLabels());
|
||||
BatchDetail batchDetailDb = batchDetailMap.get(batchDetailDO.getBatchDetailId());
|
||||
if (batchDetailDb != null){
|
||||
batchDetailDb.setBatchLabels(batchDetailDO.getBatchLabels());
|
||||
batchDetailDb.setFieldName(batchDetailDO.getFieldName());
|
||||
batchDetailDb.setInputControl(batchDetailDO.getInputControl());
|
||||
batchDetailDb.setAttributeFormat(batchDetailDO.getAttributeFormat());
|
||||
batchDetailDb.setAttributeOption(batchDetailDO.getAttributeOption());
|
||||
batchDetailDb.setIsDisplay(batchDetailDO.getIsDisplay());
|
||||
batchDetailDb.setRemark(batchDetailDO.getRemark());
|
||||
batchDetailDb.setDelFlag(1);
|
||||
batchDetailListUpdates.add(batchDetailDb);
|
||||
@@ -96,6 +112,20 @@ public class BatchDetailImpl extends ServiceImpl<BatchDetailMapper, BatchDetail>
|
||||
batchDetailListSave.add(batchDetail);
|
||||
}
|
||||
}
|
||||
}else {
|
||||
//是空没有详情 新增
|
||||
for (BatchDetailDO batchDetailDO : batchDetailDOList) {
|
||||
BatchDetail batchDetail = new BatchDetail();
|
||||
BeanUtils.copyProperties(batchDetailDO, batchDetail);
|
||||
batchDetail.setBatchId(batchDO.getBatchId());
|
||||
batchDetail.setOrganizationId(batchDO.getOrganizationId());
|
||||
batchDetail.setOrganizationName(batchDO.getOrganizationName());
|
||||
batchDetail.setTopOrganizationId(batchDO.getTopOrganizationId());
|
||||
batchDetail.setCreateBy(userPo.getUserId());
|
||||
batchDetail.setCreateByName(userPo.getUserName());
|
||||
batchDetail.setCreateTime(new Date());
|
||||
batchDetailListSave2.add(batchDetail);
|
||||
}
|
||||
}
|
||||
//删除 之前存在 现在没有的
|
||||
List<Long> batchDetailIds = batchDetailDbList.stream().map(BatchDetail::getBatchDetailId).collect(Collectors.toList());
|
||||
@@ -113,6 +143,8 @@ public class BatchDetailImpl extends ServiceImpl<BatchDetailMapper, BatchDetail>
|
||||
//新增
|
||||
if (CollectionUtil.isNotEmpty(batchDetailListSave)){
|
||||
saveBatch(batchDetailListSave);
|
||||
}else if (CollectionUtil.isNotEmpty(batchDetailListSave2)){
|
||||
saveBatch(batchDetailListSave2);
|
||||
}
|
||||
//修改
|
||||
if (CollectionUtil.isNotEmpty(batchDetailListUpdates)){
|
||||
|
||||
+8
@@ -45,6 +45,10 @@ public class BatchDetailPO extends BaseVOEntity{
|
||||
@Excel(name = "批次标签")
|
||||
private String batchLabels;
|
||||
|
||||
@ApiModelProperty("字段名称")
|
||||
@Excel(name = "字段名称")
|
||||
private String fieldName;
|
||||
|
||||
@ApiModelProperty("输入控制: 1-必填 2-可选")
|
||||
@Excel(name = "输入控制: 1-必填 2-可选")
|
||||
private String inputControl;
|
||||
@@ -57,6 +61,10 @@ public class BatchDetailPO extends BaseVOEntity{
|
||||
@Excel(name = "属性选项")
|
||||
private String attributeOption;
|
||||
|
||||
@ApiModelProperty("是否显示: 0-不显示 1-显示")
|
||||
@Excel(name = "是否显示: 0-不显示 1-显示")
|
||||
private Integer isDisplay;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
+13
@@ -1,5 +1,7 @@
|
||||
package com.mhd.basic.domain.batchDetail.repository.todo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import lombok.Data;
|
||||
import java.util.Date;
|
||||
@@ -23,6 +25,7 @@ public class BatchDetailDO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("批次管理详情id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long batchDetailId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@@ -45,6 +48,14 @@ public class BatchDetailDO extends BaseVOEntity{
|
||||
@Excel(name = "批次标签")
|
||||
private String batchLabels;
|
||||
|
||||
@ApiModelProperty("字段名称")
|
||||
@Excel(name = "字段名称")
|
||||
private String fieldName;
|
||||
|
||||
@ApiModelProperty("是否显示: 0-不显示 1-显示")
|
||||
@Excel(name = "是否显示: 0-不显示 1-显示")
|
||||
private Integer isDisplay;
|
||||
|
||||
@ApiModelProperty("输入控制: 1-必填 2-可选")
|
||||
@Excel(name = "输入控制: 1-必填 2-可选")
|
||||
private String inputControl;
|
||||
@@ -57,6 +68,8 @@ public class BatchDetailDO extends BaseVOEntity{
|
||||
@Excel(name = "属性选项")
|
||||
private String attributeOption;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
+6
@@ -101,4 +101,10 @@ public class ExpenseAccount extends BaseVOEntity{
|
||||
@ApiModelProperty(name = "收支类型")
|
||||
private Integer accountExpenseType;
|
||||
|
||||
@ApiModelProperty(name = "创建订单是否固定显示 0-否 1-是")
|
||||
private Integer fixedOrderDisplay;
|
||||
|
||||
@ApiModelProperty("费率")
|
||||
private BigDecimal rate;
|
||||
|
||||
}
|
||||
|
||||
+11
-1
@@ -10,6 +10,7 @@ import com.mhd.basic.domain.expenseAccount.repository.todo.ExpenseAccountDO;
|
||||
import com.mhd.basic.domain.expenseAccount.repository.todo.ExpenseAccountDoMap;
|
||||
import com.mhd.basic.domain.expenseAccount.repository.todo.SearchExpenseAccountDO;
|
||||
import com.mhd.basic.interfaces.dto.expenseAccount.SearchExpenseAccountDTO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -24,6 +25,7 @@ import java.util.List;
|
||||
* @author gen
|
||||
* @date 2024-06-04
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class ExpenseAccountImpl extends ServiceImpl<ExpenseAccountMapper, ExpenseAccount> implements IExpenseAccountService{
|
||||
@Autowired
|
||||
@@ -35,7 +37,15 @@ public class ExpenseAccountImpl extends ServiceImpl<ExpenseAccountMapper, Expens
|
||||
@Override
|
||||
public List<ExpenseAccountPO> queryList(ExpenseAccountDO expenseAccountDO)
|
||||
{
|
||||
return expenseAccountMapper.queryList(expenseAccountDO);
|
||||
// 添加日志,记录查询参数
|
||||
log.info("ExpenseAccountImpl.queryList 查询参数:topOrganizationId={}, subjectName={}, subjectCode={}, status={}",
|
||||
expenseAccountDO.getTopOrganizationId(),
|
||||
expenseAccountDO.getSubjectName(),
|
||||
expenseAccountDO.getSubjectCode(),
|
||||
expenseAccountDO.getStatus());
|
||||
List<ExpenseAccountPO> result = expenseAccountMapper.queryList(expenseAccountDO);
|
||||
log.info("ExpenseAccountImpl.queryList 查询结果:{} 条", result != null ? result.size() : 0);
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
|
||||
+7
@@ -122,4 +122,11 @@ public class ExpenseAccountPO extends BaseVOEntity{
|
||||
@Excel(name = "服务项税率")
|
||||
private BigDecimal taxRate;
|
||||
|
||||
|
||||
|
||||
@ApiModelProperty("费率")
|
||||
private BigDecimal rate;
|
||||
|
||||
@ApiModelProperty(name = "创建订单是否固定显示 0-否 1-是")
|
||||
private Integer fixedOrderDisplay;
|
||||
}
|
||||
|
||||
+11
@@ -39,5 +39,16 @@ public class QueryExpenseAccountPO {
|
||||
@Excel(name = "上级科目名称")
|
||||
private String upperSubject;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
}
|
||||
|
||||
+21
@@ -7,6 +7,7 @@ import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import java.math.BigDecimal;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
@@ -125,4 +126,24 @@ public class ExpenseAccountDO extends BaseVOEntity{
|
||||
|
||||
@ApiModelProperty("服务项名称")
|
||||
private String serviceItemsName;
|
||||
|
||||
@ApiModelProperty("费率")
|
||||
private BigDecimal rate;
|
||||
|
||||
@ApiModelProperty(name = "创建订单是否固定显示 0-否 1-是")
|
||||
private Integer fixedOrderDisplay;
|
||||
|
||||
@ApiModelProperty(name = "创建者姓名")
|
||||
private String createByName;
|
||||
|
||||
@ApiModelProperty(value = "创建时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd HH:mm:ss")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd HH:mm:ss")
|
||||
private Date createTime;
|
||||
|
||||
@ApiModelProperty(value = "更新者")
|
||||
private Long updateBy;
|
||||
|
||||
@ApiModelProperty(name = "创建者姓名")
|
||||
private String updateByName;
|
||||
}
|
||||
|
||||
+6
@@ -25,4 +25,10 @@ public class SearchExpenseAccountDO{
|
||||
|
||||
@ApiModelProperty("社会车辆固定显示(1-是,2-否)")
|
||||
private Integer societyStatus;
|
||||
|
||||
@ApiModelProperty("组织ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("上级组织ID")
|
||||
private Long topOrganizationId;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,64 @@
|
||||
package com.mhd.basic.domain.lease.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 租赁管理对象 container
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class Lease extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("开始日期")
|
||||
private Date startDate;
|
||||
|
||||
@ApiModelProperty("结束日期")
|
||||
private Date endDate;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
}
|
||||
+43
@@ -0,0 +1,43 @@
|
||||
package com.mhd.basic.domain.lease.repository.facade;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理Service接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
public interface ILeaseService extends IService<Lease>
|
||||
{
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
public List<LeasePO> queryList(LeaseDO leaseDO);
|
||||
|
||||
/**
|
||||
* 新增租赁管理
|
||||
*/
|
||||
public Boolean insert(LeaseDO leaseDO);
|
||||
|
||||
/**
|
||||
* 修改租赁管理
|
||||
*/
|
||||
public Boolean update(LeaseDO leaseDO);
|
||||
|
||||
/**
|
||||
* 批量删除租赁管理
|
||||
*/
|
||||
public Boolean delete(Long[] leaseIds);
|
||||
|
||||
|
||||
/**
|
||||
* 查询租赁管理
|
||||
*/
|
||||
public LeasePO getInfo(Long leaseId);
|
||||
}
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
package com.mhd.basic.domain.lease.repository.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理Mapper接口
|
||||
*
|
||||
*/
|
||||
public interface LeaseMapper extends BaseMapper<Lease>
|
||||
{
|
||||
/**
|
||||
* 查询租赁管理列表
|
||||
*/
|
||||
public List<LeasePO> queryList(LeaseDO leaseDO);
|
||||
|
||||
}
|
||||
+114
@@ -0,0 +1,114 @@
|
||||
package com.mhd.basic.domain.lease.repository.persistence;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.facade.ILeaseService;
|
||||
import com.mhd.basic.domain.lease.repository.mapper.LeaseMapper;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 容器管理Service业务层处理
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
@Service
|
||||
public class LeaseImpl extends ServiceImpl<LeaseMapper, Lease> implements ILeaseService {
|
||||
@Autowired
|
||||
private LeaseMapper leaseMapper;
|
||||
|
||||
/**
|
||||
* 查询容器管理列表
|
||||
*/
|
||||
@Override
|
||||
public List<LeasePO> queryList(LeaseDO leaseDO)
|
||||
{
|
||||
return leaseMapper.queryList(leaseDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增容器管理
|
||||
*/
|
||||
@Override
|
||||
public Boolean insert(LeaseDO leaseDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
Lease lease = new Lease();
|
||||
BeanUtils.copyProperties(leaseDO,lease);
|
||||
return this.save(lease);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改容器管理
|
||||
*/
|
||||
@Override
|
||||
public Boolean update(LeaseDO leaseDO) {
|
||||
Lease lease = new Lease();
|
||||
BeanUtils.copyProperties(leaseDO,lease);
|
||||
return this.updateById(lease);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除容器管理
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean delete(Long[] leaseIds ) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
List<Lease> list = new ArrayList<>();
|
||||
for (Long id : leaseIds) {
|
||||
Lease lease = new Lease();
|
||||
lease.setId(id);
|
||||
lease.setDelFlag(2);
|
||||
lease.setUpdateBy(loginUser.getUserid());
|
||||
lease.setUpdateByName(loginUser.getUsername());
|
||||
lease.setUpdateTime(new Date());
|
||||
list.add(lease);
|
||||
}
|
||||
return this.updateBatchById(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改容器管理
|
||||
*/
|
||||
@Override
|
||||
public LeasePO getInfo(Long leaseId) {
|
||||
Lease lease = this.getById(leaseId);
|
||||
LeasePO leasePO = new LeasePO();
|
||||
BeanUtils.copyProperties(lease,leasePO);
|
||||
return leasePO;
|
||||
}
|
||||
|
||||
// /**
|
||||
// * @description 校验唯一
|
||||
// * @author ZhouGY
|
||||
// * @date 2024/5/9 21:10
|
||||
// * @param containerDO
|
||||
// */
|
||||
// private void verifyUniqueness(ContainerDO containerDO){
|
||||
// LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
// if (topOrganizationId == null || topOrganizationId == 0 ){
|
||||
// throw new ServiceException("获取当前登陆人组织失败!");
|
||||
// }
|
||||
// int count = leaseMapper.selectCount(new QueryWrapper<Container>().lambda()
|
||||
// .eq(Container::getTopOrganizationId, topOrganizationId)
|
||||
// .eq(Container::getContainerCode,containerDO.getContainerCode())
|
||||
// .eq(Container::getOrganizationId, containerDO.getOrganizationId())
|
||||
// .ne(containerDO.getContainerId() != null, Container::getContainerId, containerDO.getContainerId() )
|
||||
// .eq(Container::getDelFlag,1));
|
||||
// if (count > 0){
|
||||
// throw new ServiceException("容器编码【" + containerDO.getContainerCode() + "】已存在");
|
||||
// }
|
||||
// }
|
||||
}
|
||||
+67
@@ -0,0 +1,67 @@
|
||||
package com.mhd.basic.domain.lease.repository.po;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 租赁管理对象 container
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class LeasePO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("开始日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date startDate;
|
||||
|
||||
@ApiModelProperty("结束日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date endDate;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
}
|
||||
+82
@@ -0,0 +1,82 @@
|
||||
package com.mhd.basic.domain.lease.repository.todo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 租赁管理对象 container
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class LeaseDO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("开始日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date startDate;
|
||||
|
||||
@ApiModelProperty("结束日期")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date endDate;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty("当前时间")
|
||||
@JsonFormat(pattern = "yyyy-MM-dd")
|
||||
private Date time;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件开始日期")
|
||||
private String createTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件结束日期")
|
||||
private String createTimeEnd;
|
||||
|
||||
@ApiModelProperty(name = "修改时间查询条件开始日期")
|
||||
private String updateTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "修改时间查询条件结束日期")
|
||||
private String updateTimeEnd;
|
||||
}
|
||||
+87
@@ -0,0 +1,87 @@
|
||||
package com.mhd.basic.domain.lease.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import com.mhd.basic.domain.container.entity.Container;
|
||||
import com.mhd.basic.domain.container.repository.facade.IContainerService;
|
||||
import com.mhd.basic.domain.container.repository.po.ContainerPO;
|
||||
import com.mhd.basic.domain.container.repository.todo.ContainerDO;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.facade.ILeaseService;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class LeaseDomainService {
|
||||
|
||||
@Autowired
|
||||
private ILeaseService leaseService;
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
public List<LeasePO> queryList(LeaseDO leaseDO) {
|
||||
return leaseService.queryList(leaseDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增租赁管理
|
||||
*/
|
||||
public Boolean insert(LeaseDO leaseDO) {
|
||||
|
||||
return leaseService.insert(leaseDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改租赁管理
|
||||
*/
|
||||
public Boolean update(LeaseDO leaseDO) {
|
||||
return leaseService.update(leaseDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除租赁管理
|
||||
*/
|
||||
public Boolean delete(Long[] leaseIds) {
|
||||
return leaseService.delete(leaseIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租赁管理详细信息
|
||||
*/
|
||||
public LeasePO getInfo(Long leaseId)
|
||||
{
|
||||
return leaseService.getInfo(leaseId);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @description 批量作废租赁
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/13 9:46
|
||||
* @param leaseIds
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean nullifyByIds(List<Long> leaseIds) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
return leaseService.update(new UpdateWrapper<Lease>().lambda()
|
||||
.set(Lease::getUpdateBy, loginUser.getUserid())
|
||||
.set(Lease::getUpdateTime, new Date())
|
||||
.in(Lease::getId, leaseIds)
|
||||
.eq(Lease::getDelFlag, 1));
|
||||
}
|
||||
}
|
||||
+202
-1
@@ -158,6 +158,7 @@ public class MaterialBaseInfo extends BaseVOEntity{
|
||||
|
||||
@ApiModelProperty("单位数量")
|
||||
@Excel(name = "单位数量")
|
||||
@TableField(exist = false)
|
||||
private BigDecimal unitNumber;
|
||||
|
||||
@ApiModelProperty("是否公用: 1-是 2-否")
|
||||
@@ -184,4 +185,204 @@ public class MaterialBaseInfo extends BaseVOEntity{
|
||||
@ApiModelProperty("整机编码")
|
||||
@Excel(name = "整机编号")
|
||||
private String machineCode;
|
||||
}
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
@TableField(exist = false)
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
@TableField(exist = false)
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
@TableField(exist = false)
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
@TableField(exist = false)
|
||||
private String specificationModel;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
@TableField(exist = false)
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
@TableField(exist = false)
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
@TableField(exist = false)
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
@TableField(exist = false)
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO's
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO's")
|
||||
@Excel(name = "Batch Ref NO's")
|
||||
@TableField(exist = false)
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO's
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO's")
|
||||
@Excel(name = "Sheet Ref NO's")
|
||||
@TableField(exist = false)
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
@TableField(exist = false)
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
@TableField(exist = false)
|
||||
private String casePalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
@TableField(exist = false)
|
||||
private Double declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
@TableField(exist = false)
|
||||
private Double caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
@TableField(exist = false)
|
||||
private Double pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
@TableField(exist = false)
|
||||
private Double outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
@TableField(exist = false)
|
||||
private Double totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
@TableField(exist = false)
|
||||
private Double totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
@TableField(exist = false)
|
||||
private Double totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
@TableField(exist = false)
|
||||
private Double totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
@TableField(exist = false)
|
||||
private Double totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
@TableField(exist = false)
|
||||
private String unit;
|
||||
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("单价")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("HS码")
|
||||
private String hsCode;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("法定单位")
|
||||
private String statutoryUnit;
|
||||
|
||||
@ApiModelProperty("法定第二单位")
|
||||
private String statutorySecondUnit;
|
||||
}
|
||||
+195
-1
@@ -5,6 +5,7 @@ import com.mhd.basic.domain.batch.repository.po.BatchPO;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.handler.ListTypeHandler;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import com.mhd.system.api.domain.*;
|
||||
import io.swagger.annotations.ApiModel;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
@@ -182,4 +183,197 @@ public class MaterialBaseInfoPO extends BaseVOEntity{
|
||||
@Excel(name = "整机编号")
|
||||
private String machineCode;
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String casePalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private Double declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private Double caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private Double pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private Double outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private Double totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private Double totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private Double totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private Double totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private Double totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("单价")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("HS码")
|
||||
private String hsCode;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("法定单位")
|
||||
private String statutoryUnit;
|
||||
|
||||
@ApiModelProperty("法定第二单位")
|
||||
private String statutorySecondUnit;
|
||||
|
||||
@ApiModelProperty("商品规则")
|
||||
private MaterialGoodsRuleFeign materialGoodsRule;
|
||||
|
||||
@ApiModelProperty("公共信息")
|
||||
private MaterialCommonFeign materialCommon;
|
||||
|
||||
@ApiModelProperty("仓库控制信息")
|
||||
private MaterialWarehouseControlFeign materialWarehouseControl;
|
||||
|
||||
@ApiModelProperty("库存预警信息")
|
||||
private List<MaterialInventoryWarningFeign> materialInventoryWarningList;
|
||||
|
||||
@ApiModelProperty("条码信息")
|
||||
private List<MaterialBarCodeFeign> materialBarCodeList;
|
||||
|
||||
}
|
||||
+179
-1
@@ -203,4 +203,182 @@ public class MaterialBaseInfoDO extends BaseVOEntity{
|
||||
@ApiModelProperty("整机编码")
|
||||
@Excel(name = "整机编号")
|
||||
private String machineCode;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String casePalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private Double declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private Double caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private Double pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private Double outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private Double totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private Double totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private Double totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private Double totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private Double totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("单价")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("HS码")
|
||||
private String hsCode;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("法定单位")
|
||||
private String statutoryUnit;
|
||||
|
||||
@ApiModelProperty("法定第二单位")
|
||||
private String statutorySecondUnit;
|
||||
}
|
||||
+4
@@ -68,6 +68,10 @@ public class PackPO extends BaseVOEntity{
|
||||
@Excel(name = "是否作废: 1-否 2-是")
|
||||
private Integer nullify;
|
||||
|
||||
@ApiModelProperty("包装单位(取第一条包装详情的单位名称)")
|
||||
@Excel(name = "包装单位")
|
||||
private String unitName;
|
||||
|
||||
@ApiModelProperty("包装明细")
|
||||
private List<PackDetailPO> packDetailList;
|
||||
|
||||
|
||||
+1
-1
@@ -22,7 +22,7 @@ public interface IServiceItemsManageService extends IService<ServiceItemsManage>
|
||||
/**
|
||||
* 查询费用类别
|
||||
*/
|
||||
public List<ServiceItemsManagePO> getCostType();
|
||||
public List<ServiceItemsManagePO> getCostType(ServiceItemsManageDO serviceItemsManageDO);
|
||||
/**
|
||||
* 新增服务项管理
|
||||
*/
|
||||
|
||||
+1
-1
@@ -21,6 +21,6 @@ public interface ServiceItemsManageMapper extends BaseMapper<ServiceItemsManage>
|
||||
/**
|
||||
* 查询费用类别
|
||||
*/
|
||||
public List<ServiceItemsManagePO> selectServiceTypes();
|
||||
public List<ServiceItemsManagePO> selectServiceTypes(ServiceItemsManageDO serviceItemsManageDO);
|
||||
|
||||
}
|
||||
|
||||
+73
-3
@@ -6,6 +6,7 @@ import com.mhd.basic.domain.serviceItemsManage.entity.ServiceItemsManage;
|
||||
import com.mhd.basic.domain.serviceItemsManage.repository.facade.IServiceItemsManageService;
|
||||
import com.mhd.basic.domain.serviceItemsManage.repository.po.ServiceItemsManagePO;
|
||||
import com.mhd.basic.domain.serviceItemsManage.repository.todo.ServiceItemsManageDO;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -19,6 +20,7 @@ import java.util.List;
|
||||
* @author gen
|
||||
* @date 2024-06-03
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class ServiceItemsManageImpl extends ServiceImpl<ServiceItemsManageMapper, ServiceItemsManage> implements IServiceItemsManageService{
|
||||
@Autowired
|
||||
@@ -30,12 +32,80 @@ public class ServiceItemsManageImpl extends ServiceImpl<ServiceItemsManageMapper
|
||||
@Override
|
||||
public List<ServiceItemsManagePO> queryList(ServiceItemsManageDO serviceItemsManageDO)
|
||||
{
|
||||
return serviceItemsManageMapper.queryList(serviceItemsManageDO);
|
||||
// 添加日志,记录查询参数
|
||||
log.info("ServiceItemsManageImpl.queryList 查询参数:topOrganizationId={}, organizationId={}, serviceItemsName={}, serviceItemsCode={}",
|
||||
serviceItemsManageDO.getTopOrganizationId(),
|
||||
serviceItemsManageDO.getOrganizationId(),
|
||||
serviceItemsManageDO.getServiceItemsName(),
|
||||
serviceItemsManageDO.getServiceItemsCode());
|
||||
|
||||
// 构建SQL查询条件说明(用于日志,必须与 MyBatis XML 中的条件保持一致)
|
||||
StringBuilder sqlCondition = new StringBuilder("WHERE del_flag = 1");
|
||||
|
||||
// 组织过滤条件(与 XML 中的 <if test="organizationId != null"> 和 <if test="topOrganizationId != null and organizationId == null"> 对应)
|
||||
if (serviceItemsManageDO.getOrganizationId() != null) {
|
||||
// 如果设置了 organizationId,添加 organization_id 条件
|
||||
sqlCondition.append(" AND organization_id = ").append(serviceItemsManageDO.getOrganizationId());
|
||||
sqlCondition.append(" AND organization_name IS NOT NULL");
|
||||
sqlCondition.append(" AND organization_name != ''");
|
||||
sqlCondition.append(" AND LENGTH(TRIM(organization_name)) > 0");
|
||||
} else if (serviceItemsManageDO.getTopOrganizationId() != null) {
|
||||
// 如果设置了 topOrganizationId 但没有设置 organizationId,添加 top_organization_id 条件
|
||||
sqlCondition.append(" AND top_organization_id = ").append(serviceItemsManageDO.getTopOrganizationId());
|
||||
sqlCondition.append(" AND organization_name IS NOT NULL");
|
||||
sqlCondition.append(" AND organization_name != ''");
|
||||
sqlCondition.append(" AND LENGTH(TRIM(organization_name)) > 0");
|
||||
} else {
|
||||
// 如果 organizationId 和 topOrganizationId 都为 null,不添加组织过滤条件(查询所有组织的数据)
|
||||
sqlCondition.append(" (无组织过滤条件,查询所有组织的数据)");
|
||||
}
|
||||
|
||||
// 其他查询条件
|
||||
if (serviceItemsManageDO.getCreateByName() != null && !serviceItemsManageDO.getCreateByName().isEmpty()) {
|
||||
sqlCondition.append(" AND create_by_name LIKE '%").append(serviceItemsManageDO.getCreateByName()).append("%'");
|
||||
}
|
||||
if (serviceItemsManageDO.getUpdateByName() != null && !serviceItemsManageDO.getUpdateByName().isEmpty()) {
|
||||
sqlCondition.append(" AND update_by_name LIKE '%").append(serviceItemsManageDO.getUpdateByName()).append("%'");
|
||||
}
|
||||
if (serviceItemsManageDO.getOrganizationName() != null && !serviceItemsManageDO.getOrganizationName().isEmpty()) {
|
||||
sqlCondition.append(" AND organization_name LIKE '%").append(serviceItemsManageDO.getOrganizationName()).append("%'");
|
||||
}
|
||||
if (serviceItemsManageDO.getServiceItemsName() != null && !serviceItemsManageDO.getServiceItemsName().isEmpty()) {
|
||||
sqlCondition.append(" AND service_items_name LIKE '%").append(serviceItemsManageDO.getServiceItemsName()).append("%'");
|
||||
}
|
||||
if (serviceItemsManageDO.getServiceItemsCode() != null && !serviceItemsManageDO.getServiceItemsCode().isEmpty()) {
|
||||
sqlCondition.append(" AND service_items_code = '").append(serviceItemsManageDO.getServiceItemsCode()).append("'");
|
||||
}
|
||||
if (serviceItemsManageDO.getTaxRate() != null) {
|
||||
sqlCondition.append(" AND tax_rate = ").append(serviceItemsManageDO.getTaxRate());
|
||||
}
|
||||
if (serviceItemsManageDO.getRemark() != null && !serviceItemsManageDO.getRemark().isEmpty()) {
|
||||
sqlCondition.append(" AND remark LIKE '%").append(serviceItemsManageDO.getRemark()).append("%'");
|
||||
}
|
||||
|
||||
log.info("ServiceItemsManageImpl.queryList 生成的SQL条件(预估):SELECT * FROM service_items_manage {}", sqlCondition.toString());
|
||||
log.info("ServiceItemsManageImpl.queryList 实际执行的SQL请查看 MyBatis 日志,参数:organizationId={}, topOrganizationId={}, delFlag={}",
|
||||
serviceItemsManageDO.getOrganizationId(), serviceItemsManageDO.getTopOrganizationId(), serviceItemsManageDO.getDelFlag());
|
||||
|
||||
List<ServiceItemsManagePO> result = serviceItemsManageMapper.queryList(serviceItemsManageDO);
|
||||
log.info("ServiceItemsManageImpl.queryList 查询结果:{} 条", result != null ? result.size() : 0);
|
||||
// 记录查询结果中的组织ID分布
|
||||
if (result != null && !result.isEmpty()) {
|
||||
StringBuilder orgIds = new StringBuilder();
|
||||
for (ServiceItemsManagePO po : result) {
|
||||
if (orgIds.length() > 0) {
|
||||
orgIds.append(", ");
|
||||
}
|
||||
orgIds.append(po.getOrganizationId());
|
||||
}
|
||||
log.info("查询结果中的组织ID分布:{}", orgIds.toString());
|
||||
}
|
||||
return result;
|
||||
}
|
||||
|
||||
@Override
|
||||
public List<ServiceItemsManagePO> getCostType() {
|
||||
return serviceItemsManageMapper.selectServiceTypes();
|
||||
public List<ServiceItemsManagePO> getCostType(ServiceItemsManageDO serviceItemsManageDO) {
|
||||
return serviceItemsManageMapper.selectServiceTypes(serviceItemsManageDO);
|
||||
}
|
||||
/**
|
||||
* 新增服务项管理
|
||||
|
||||
+1
-1
@@ -37,7 +37,7 @@ public class ServiceItemsManageDomainService {
|
||||
* 查询费用类型
|
||||
*/
|
||||
public List<ServiceItemsManagePO> getCostsType(ServiceItemsManageDO serviceItemsManageDO){
|
||||
return serviceItemsManageService.getCostType();
|
||||
return serviceItemsManageService.getCostType(serviceItemsManageDO);
|
||||
}
|
||||
|
||||
|
||||
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.entity;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 货主租赁明细
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ShipperLeaseDetails extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("业务日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDate;
|
||||
|
||||
|
||||
|
||||
}
|
||||
+58
@@ -0,0 +1,58 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.entity;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 仓库出租率返回类 没有表
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class WarehouseOccupancyRate extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("业务日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDate;
|
||||
|
||||
@ApiModelProperty("整租面积(m²)")
|
||||
private BigDecimal entireLeaseArea;
|
||||
|
||||
@ApiModelProperty("散租面积(m²)")
|
||||
private BigDecimal fractionalLeaseArea;
|
||||
|
||||
@ApiModelProperty("总面积(m²)")
|
||||
private BigDecimal totalArea;
|
||||
|
||||
@ApiModelProperty("日租率(%)")
|
||||
private BigDecimal dailyRentalRate;
|
||||
|
||||
}
|
||||
+43
@@ -0,0 +1,43 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.repository.facade;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.IService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 货主租赁明细Service接口
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
public interface IShipperLeaseDetailsService extends IService<ShipperLeaseDetails>
|
||||
{
|
||||
/**
|
||||
* 分页查询货主租赁明细列表
|
||||
*/
|
||||
public List<ShipperLeaseDetailsPO> queryList(ShipperLeaseDetailsDO shipperLeaseDetailsDO);
|
||||
|
||||
/**
|
||||
* 新增货主租赁明细
|
||||
*/
|
||||
public Boolean insert(ShipperLeaseDetailsDO shipperLeaseDetailsDO);
|
||||
|
||||
/**
|
||||
* 修改货主租赁明细
|
||||
*/
|
||||
public Boolean update(ShipperLeaseDetailsDO shipperLeaseDetailsDO);
|
||||
|
||||
/**
|
||||
* 批量删除货主租赁明细
|
||||
*/
|
||||
public Boolean delete(Long[] leaseIds);
|
||||
|
||||
|
||||
/**
|
||||
* 查询货主租赁明细
|
||||
*/
|
||||
public ShipperLeaseDetailsPO getInfo(Long leaseId);
|
||||
}
|
||||
+21
@@ -0,0 +1,21 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.repository.mapper;
|
||||
|
||||
import com.baomidou.mybatisplus.core.mapper.BaseMapper;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 货主租赁明细Mapper接口
|
||||
*
|
||||
*/
|
||||
public interface ShipperLeaseDetailsMapper extends BaseMapper<ShipperLeaseDetails>
|
||||
{
|
||||
/**
|
||||
* 查询货主租赁明细列表
|
||||
*/
|
||||
public List<ShipperLeaseDetailsPO> queryList(ShipperLeaseDetailsDO shipperLeaseDetailsDO);
|
||||
|
||||
}
|
||||
+114
@@ -0,0 +1,114 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.repository.persistence;
|
||||
|
||||
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.facade.IShipperLeaseDetailsService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.mapper.ShipperLeaseDetailsMapper;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 货主租赁明细Service业务层处理
|
||||
*
|
||||
* @author gen
|
||||
* @date 2024-05-07
|
||||
*/
|
||||
@Service
|
||||
public class ShipperLeaseDetailsImpl extends ServiceImpl<ShipperLeaseDetailsMapper, ShipperLeaseDetails> implements IShipperLeaseDetailsService {
|
||||
@Autowired
|
||||
private ShipperLeaseDetailsMapper shipperLeaseDetailsMapper;
|
||||
|
||||
/**
|
||||
* 查询货主租赁明细列表
|
||||
*/
|
||||
@Override
|
||||
public List<ShipperLeaseDetailsPO> queryList(ShipperLeaseDetailsDO shipperLeaseDetailsDO)
|
||||
{
|
||||
return shipperLeaseDetailsMapper.queryList(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增货主租赁明细
|
||||
*/
|
||||
@Override
|
||||
public Boolean insert(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
ShipperLeaseDetails shipperLeaseDetails = new ShipperLeaseDetails();
|
||||
BeanUtils.copyProperties(shipperLeaseDetailsDO,shipperLeaseDetails);
|
||||
return this.save(shipperLeaseDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改货主租赁明细
|
||||
*/
|
||||
@Override
|
||||
public Boolean update(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
ShipperLeaseDetails shipperLeaseDetails = new ShipperLeaseDetails();
|
||||
BeanUtils.copyProperties(shipperLeaseDetailsDO,shipperLeaseDetails);
|
||||
return this.updateById(shipperLeaseDetails);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除货主租赁明细
|
||||
*/
|
||||
@Override
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public Boolean delete(Long[] leaseIds ) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
List<ShipperLeaseDetails> list = new ArrayList<>();
|
||||
for (Long id : leaseIds) {
|
||||
ShipperLeaseDetails shipperLeaseDetails = new ShipperLeaseDetails();
|
||||
shipperLeaseDetails.setId(id);
|
||||
shipperLeaseDetails.setDelFlag(2);
|
||||
shipperLeaseDetails.setUpdateBy(loginUser.getUserid());
|
||||
shipperLeaseDetails.setUpdateByName(loginUser.getUsername());
|
||||
shipperLeaseDetails.setUpdateTime(new Date());
|
||||
list.add(shipperLeaseDetails);
|
||||
}
|
||||
return this.updateBatchById(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改货主租赁明细
|
||||
*/
|
||||
@Override
|
||||
public ShipperLeaseDetailsPO getInfo(Long ShipperLeaseDetailsId) {
|
||||
ShipperLeaseDetails shipperLeaseDetails = this.getById(ShipperLeaseDetailsId);
|
||||
ShipperLeaseDetailsPO shipperLeaseDetailsPO = new ShipperLeaseDetailsPO();
|
||||
BeanUtils.copyProperties(shipperLeaseDetails,shipperLeaseDetailsPO);
|
||||
return shipperLeaseDetailsPO;
|
||||
}
|
||||
|
||||
// /**
|
||||
// * @description 校验唯一
|
||||
// * @author ZhouGY
|
||||
// * @date 2024/5/9 21:10
|
||||
// * @param containerDO
|
||||
// */
|
||||
// private void verifyUniqueness(ContainerDO containerDO){
|
||||
// LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
// Long topOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
// if (topOrganizationId == null || topOrganizationId == 0 ){
|
||||
// throw new ServiceException("获取当前登陆人组织失败!");
|
||||
// }
|
||||
// int count = leaseMapper.selectCount(new QueryWrapper<Container>().lambda()
|
||||
// .eq(Container::getTopOrganizationId, topOrganizationId)
|
||||
// .eq(Container::getContainerCode,containerDO.getContainerCode())
|
||||
// .eq(Container::getOrganizationId, containerDO.getOrganizationId())
|
||||
// .ne(containerDO.getContainerId() != null, Container::getContainerId, containerDO.getContainerId() )
|
||||
// .eq(Container::getDelFlag,1));
|
||||
// if (count > 0){
|
||||
// throw new ServiceException("容器编码【" + containerDO.getContainerCode() + "】已存在");
|
||||
// }
|
||||
// }
|
||||
}
|
||||
+65
@@ -0,0 +1,65 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.repository.po;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 货主租赁明细
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ShipperLeaseDetailsPO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("业务日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDate;
|
||||
|
||||
|
||||
|
||||
}
|
||||
+73
@@ -0,0 +1,73 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.repository.todo;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 货主租赁明细
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ShipperLeaseDetailsDO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("业务日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDate;
|
||||
|
||||
@ApiModelProperty("业务日期开始时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDateStart;
|
||||
|
||||
@ApiModelProperty("业务日期结束时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDateEnd;
|
||||
|
||||
}
|
||||
+87
@@ -0,0 +1,87 @@
|
||||
package com.mhd.basic.domain.shipperLeaseDetails.service;
|
||||
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import com.mhd.basic.domain.lease.entity.Lease;
|
||||
import com.mhd.basic.domain.lease.repository.facade.ILeaseService;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.facade.IShipperLeaseDetailsService;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理
|
||||
*
|
||||
*/
|
||||
@Service
|
||||
@Slf4j
|
||||
public class ShipperLeaseDetailsDomainService {
|
||||
|
||||
@Autowired
|
||||
private IShipperLeaseDetailsService shipperLeaseDetailsService;
|
||||
|
||||
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
public List<ShipperLeaseDetailsPO> queryList(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
return shipperLeaseDetailsService.queryList(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 新增租赁管理
|
||||
*/
|
||||
public Boolean insert(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
|
||||
return shipperLeaseDetailsService.insert(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改租赁管理
|
||||
*/
|
||||
public Boolean update(ShipperLeaseDetailsDO shipperLeaseDetailsDO) {
|
||||
return shipperLeaseDetailsService.update(shipperLeaseDetailsDO);
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除租赁管理
|
||||
*/
|
||||
public Boolean delete(Long[] shipperLeaseDetailsIds) {
|
||||
return shipperLeaseDetailsService.delete(shipperLeaseDetailsIds);
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租赁管理详细信息
|
||||
*/
|
||||
public ShipperLeaseDetailsPO getInfo(Long shipperLeaseDetailsId)
|
||||
{
|
||||
return shipperLeaseDetailsService.getInfo(shipperLeaseDetailsId);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @description 批量作废租赁
|
||||
* @author ZhouGY
|
||||
* @date 2024/5/13 9:46
|
||||
* @param leaseIds
|
||||
* @return Boolean
|
||||
*/
|
||||
public Boolean nullifyByIds(List<Long> leaseIds) {
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
return shipperLeaseDetailsService.update(new UpdateWrapper<ShipperLeaseDetails>().lambda()
|
||||
.set(ShipperLeaseDetails::getUpdateBy, loginUser.getUserid())
|
||||
.set(ShipperLeaseDetails::getUpdateTime, new Date())
|
||||
.in(ShipperLeaseDetails::getId, leaseIds)
|
||||
.eq(ShipperLeaseDetails::getDelFlag, 1));
|
||||
}
|
||||
}
|
||||
+36
-17
@@ -27,8 +27,10 @@ public class ExpenseAccountAssembler {
|
||||
*/
|
||||
public ExpenseAccountDO toDO(ExpenseAccountDTO expenseAccountDTO) {
|
||||
ExpenseAccountDO expenseAccountDO = new ExpenseAccountDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(expenseAccountDTO, expenseAccountDO, IgnoreNullUtil.getNullPropertyNames(expenseAccountDTO));
|
||||
// 如果 expenseAccountDTO 不为 null,才进行拷贝
|
||||
if (expenseAccountDTO != null) {
|
||||
BeanUtils.copyProperties(expenseAccountDTO, expenseAccountDO, IgnoreNullUtil.getNullPropertyNames(expenseAccountDTO));
|
||||
}
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
@@ -36,28 +38,45 @@ public class ExpenseAccountAssembler {
|
||||
String userName = loginUser.getUsername();
|
||||
// 获取登录人id
|
||||
Long userId = loginUser.getUserid();
|
||||
if(expenseAccountDTO.getExpenseAccountId() != null){
|
||||
|
||||
// 只有在新增或编辑操作时才设置 createByName 和 updateByName
|
||||
// 查询列表时不应该自动设置这些字段,否则会导致 SQL 中添加过滤条件,影响查询结果
|
||||
if(expenseAccountDTO != null && expenseAccountDTO.getExpenseAccountId() != null){
|
||||
// 编辑操作:只设置更新相关字段
|
||||
if(userId != null){
|
||||
expenseAccountDO.setUpdateBy(userId);
|
||||
}else {
|
||||
expenseAccountDO.setUpdateBy(new Long("0"));
|
||||
}
|
||||
expenseAccountDO.setUpdateByName(userName);
|
||||
expenseAccountDO.setUpdateTime(new Date());
|
||||
|
||||
}else {
|
||||
if(userId != null){
|
||||
expenseAccountDO.setCreateBy(userId);
|
||||
expenseAccountDO.setUpdateBy(userId);
|
||||
}else {
|
||||
expenseAccountDO.setCreateBy(new Long("0"));
|
||||
expenseAccountDO.setUpdateBy(new Long("0"));
|
||||
// 只有在 DTO 中没有传递 updateByName 时才设置(避免覆盖前端传递的值)
|
||||
if(expenseAccountDO.getUpdateByName() == null || expenseAccountDO.getUpdateByName().isEmpty()){
|
||||
expenseAccountDO.setUpdateByName(userName);
|
||||
}
|
||||
expenseAccountDO.setCreateByName(userName);
|
||||
expenseAccountDO.setUpdateByName(userName);
|
||||
expenseAccountDO.setCreateTime(new Date());
|
||||
expenseAccountDO.setUpdateTime(new Date());
|
||||
expenseAccountDO.setDelFlag(1);
|
||||
} else if(expenseAccountDTO != null && expenseAccountDTO.getExpenseAccountId() == null) {
|
||||
// expenseAccountId == null,可能是查询操作或新增操作
|
||||
// 如果前端传递了 createByName 或 updateByName,说明是查询条件,不应该设置(已经在 BeanUtils.copyProperties 中拷贝了)
|
||||
// 如果前端没有传递 createByName 和 updateByName,可能是新增操作,需要设置默认值
|
||||
boolean hasQueryCondition = (expenseAccountDTO.getCreateByName() != null && !expenseAccountDTO.getCreateByName().isEmpty())
|
||||
|| (expenseAccountDTO.getUpdateByName() != null && !expenseAccountDTO.getUpdateByName().isEmpty());
|
||||
|
||||
if(!hasQueryCondition) {
|
||||
// 没有查询条件,可能是新增操作,设置默认值
|
||||
if(userId != null){
|
||||
expenseAccountDO.setCreateBy(userId);
|
||||
expenseAccountDO.setUpdateBy(userId);
|
||||
}else {
|
||||
expenseAccountDO.setCreateBy(new Long("0"));
|
||||
expenseAccountDO.setUpdateBy(new Long("0"));
|
||||
}
|
||||
expenseAccountDO.setCreateByName(userName);
|
||||
expenseAccountDO.setUpdateByName(userName);
|
||||
expenseAccountDO.setCreateTime(new Date());
|
||||
expenseAccountDO.setUpdateTime(new Date());
|
||||
expenseAccountDO.setDelFlag(1);
|
||||
}
|
||||
// 如果有查询条件(createByName 或 updateByName),说明是查询操作,不应该设置这些字段
|
||||
// 字段值已经在 BeanUtils.copyProperties 中从 DTO 拷贝过来了
|
||||
}
|
||||
return expenseAccountDO;
|
||||
}
|
||||
|
||||
+116
@@ -0,0 +1,116 @@
|
||||
package com.mhd.basic.interfaces.assember.lease;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.alibaba.fastjson.JSONObject;
|
||||
import com.alibaba.fastjson2.JSON;
|
||||
import com.mhd.basic.domain.container.repository.todo.ContainerDO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.interfaces.dto.container.ContainerDTO;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.common.core.exception.ServiceException;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.DigitalLogisticsException;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.UserError;
|
||||
import com.mhd.common.core.utils.IgnoreNullUtil;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.SystemServiceFeign;
|
||||
import com.mhd.system.api.domain.WarehouseFeignPO;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 容器管理Assembler
|
||||
*
|
||||
*/
|
||||
@Component
|
||||
public class LeaseAssembler {
|
||||
|
||||
@Autowired
|
||||
private SystemServiceFeign systemServiceFeign;
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public LeaseDO toDO(LeaseDTO leaseDTO) {
|
||||
LeaseDO leaseDO = new LeaseDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(leaseDTO, leaseDO, IgnoreNullUtil.getNullPropertyNames(leaseDTO));
|
||||
// 确保查询条件字段被正确传递(查询条件字段需要明确传递,避免被IgnoreNullUtil忽略)
|
||||
leaseDO.setCreateTimeStart(leaseDTO.getCreateTimeStart());
|
||||
leaseDO.setCreateTimeEnd(leaseDTO.getCreateTimeEnd());
|
||||
leaseDO.setUpdateTimeStart(leaseDTO.getUpdateTimeStart());
|
||||
leaseDO.setUpdateTimeEnd(leaseDTO.getUpdateTimeEnd());
|
||||
return leaseDO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public LeaseDO toDOByEdit(LeaseDTO leaseDTO) {
|
||||
LeaseDO leaseDO = new LeaseDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(leaseDTO, leaseDO, IgnoreNullUtil.getNullPropertyNames(leaseDTO));
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
}
|
||||
if(leaseDTO.getId() != null){
|
||||
leaseDO.setUpdateBy(loginUser.getUserid());
|
||||
leaseDO.setUpdateByName(loginUser.getUsername());
|
||||
leaseDO.setUpdateTime(new Date());
|
||||
}else {
|
||||
leaseDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
leaseDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
leaseDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
leaseDO.setCreateBy(loginUser.getUserid());
|
||||
leaseDO.setCreateByName(loginUser.getUsername());
|
||||
leaseDO.setCreateTime(new Date());
|
||||
// 新增时根据仓库ID查询仓库名字
|
||||
if (leaseDO.getWarehouseId() != null) {
|
||||
setWarehouseInfo(leaseDO);
|
||||
}
|
||||
}
|
||||
return leaseDO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 设置仓库信息
|
||||
*/
|
||||
private void setWarehouseInfo(LeaseDO leaseDO) {
|
||||
if (leaseDO.getWarehouseId() == null) {
|
||||
return;
|
||||
}
|
||||
AjaxResult ajaxResult = systemServiceFeign.getWarehouseInfoByWarehouseId(leaseDO.getWarehouseId());
|
||||
if (ajaxResult == null) {
|
||||
throw new ServiceException("获取仓库信息失败:返回结果为空,仓库ID:" + leaseDO.getWarehouseId());
|
||||
}
|
||||
Object codeObj = ajaxResult.get("code");
|
||||
if (codeObj == null || !"200".equals(String.valueOf(codeObj))) {
|
||||
String errorMsg = ajaxResult.get("msg") != null ? String.valueOf(ajaxResult.get("msg")) : "未知错误";
|
||||
throw new ServiceException("获取仓库信息失败,仓库ID:" + leaseDO.getWarehouseId() + ",错误信息:" + errorMsg);
|
||||
}
|
||||
Object dataObj = ajaxResult.get("data");
|
||||
if (dataObj == null) {
|
||||
throw new ServiceException("获取仓库信息失败:返回数据为空,仓库ID:" + leaseDO.getWarehouseId());
|
||||
}
|
||||
String dataJsonString = JSONObject.toJSONString(dataObj);
|
||||
if (dataJsonString == null || dataJsonString.isEmpty() || "null".equals(dataJsonString)) {
|
||||
throw new ServiceException("获取仓库信息失败:返回数据为空或格式不正确,仓库ID:" + leaseDO.getWarehouseId());
|
||||
}
|
||||
WarehouseFeignPO warehouseFeignPO;
|
||||
try {
|
||||
warehouseFeignPO = JSON.parseObject(dataJsonString, WarehouseFeignPO.class);
|
||||
} catch (Exception e) {
|
||||
throw new ServiceException("获取仓库信息失败:数据解析异常,仓库ID:" + leaseDO.getWarehouseId() + ",错误信息:" + e.getMessage());
|
||||
}
|
||||
if (warehouseFeignPO == null) {
|
||||
throw new ServiceException("获取仓库信息失败:数据解析失败,仓库ID:" + leaseDO.getWarehouseId());
|
||||
}
|
||||
leaseDO.setWarehouseName(warehouseFeignPO.getWarehouseName());
|
||||
}
|
||||
|
||||
}
|
||||
+40
-17
@@ -27,8 +27,10 @@ public class ServiceItemsManageAssembler {
|
||||
*/
|
||||
public ServiceItemsManageDO toDO(ServiceItemsManageDTO serviceItemsManageDTO) {
|
||||
ServiceItemsManageDO serviceItemsManageDO = new ServiceItemsManageDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(serviceItemsManageDTO, serviceItemsManageDO, IgnoreNullUtil.getNullPropertyNames(serviceItemsManageDTO));
|
||||
// 如果 serviceItemsManageDTO 不为 null,才进行拷贝
|
||||
if (serviceItemsManageDTO != null) {
|
||||
BeanUtils.copyProperties(serviceItemsManageDTO, serviceItemsManageDO, IgnoreNullUtil.getNullPropertyNames(serviceItemsManageDTO));
|
||||
}
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
@@ -36,28 +38,49 @@ public class ServiceItemsManageAssembler {
|
||||
String userName = loginUser.getUsername();
|
||||
// 获取登录人id
|
||||
Long userId = loginUser.getUserid();
|
||||
if(serviceItemsManageDTO.getServiceItemsManageId() != null){
|
||||
|
||||
// 只有在新增或编辑操作时才设置 createByName 和 updateByName
|
||||
// 查询列表时不应该自动设置这些字段,否则会导致 SQL 中添加过滤条件,影响查询结果
|
||||
// 判断规则:
|
||||
// 1. 如果 serviceItemsManageId != null,说明是编辑操作,只设置更新相关字段
|
||||
// 2. 如果 serviceItemsManageId == null 且前端传递了 createByName 或 updateByName,说明是查询条件,不应该覆盖
|
||||
// 3. 如果 serviceItemsManageId == null 且前端没有传递 createByName 和 updateByName,可能是新增操作,设置默认值
|
||||
if(serviceItemsManageDTO != null && serviceItemsManageDTO.getServiceItemsManageId() != null){
|
||||
// 编辑操作:只设置更新相关字段
|
||||
if(userId != null){
|
||||
serviceItemsManageDO.setUpdateBy(userId);
|
||||
}else {
|
||||
serviceItemsManageDO.setUpdateBy(new Long("0"));
|
||||
}
|
||||
serviceItemsManageDO.setUpdateByName(userName);
|
||||
serviceItemsManageDO.setUpdateTime(new Date());
|
||||
|
||||
}else {
|
||||
if(userId != null){
|
||||
serviceItemsManageDO.setCreateBy(userId);
|
||||
serviceItemsManageDO.setUpdateBy(userId);
|
||||
}else {
|
||||
serviceItemsManageDO.setCreateBy(new Long("0"));
|
||||
serviceItemsManageDO.setUpdateBy(new Long("0"));
|
||||
// 只有在 DTO 中没有传递 updateByName 时才设置(避免覆盖前端传递的值)
|
||||
if(serviceItemsManageDO.getUpdateByName() == null || serviceItemsManageDO.getUpdateByName().isEmpty()){
|
||||
serviceItemsManageDO.setUpdateByName(userName);
|
||||
}
|
||||
serviceItemsManageDO.setCreateByName(userName);
|
||||
serviceItemsManageDO.setUpdateByName(userName);
|
||||
serviceItemsManageDO.setCreateTime(new Date());
|
||||
serviceItemsManageDO.setUpdateTime(new Date());
|
||||
serviceItemsManageDO.setDelFlag(1);
|
||||
} else if(serviceItemsManageDTO != null && serviceItemsManageDTO.getServiceItemsManageId() == null) {
|
||||
// serviceItemsManageId == null,可能是查询操作或新增操作
|
||||
// 如果前端传递了 createByName 或 updateByName,说明是查询条件,不应该设置(已经在 BeanUtils.copyProperties 中拷贝了)
|
||||
// 如果前端没有传递 createByName 和 updateByName,可能是新增操作,需要设置默认值
|
||||
boolean hasQueryCondition = (serviceItemsManageDTO.getCreateByName() != null && !serviceItemsManageDTO.getCreateByName().isEmpty())
|
||||
|| (serviceItemsManageDTO.getUpdateByName() != null && !serviceItemsManageDTO.getUpdateByName().isEmpty());
|
||||
|
||||
if(!hasQueryCondition) {
|
||||
// 没有查询条件,可能是新增操作,设置默认值
|
||||
if(userId != null){
|
||||
serviceItemsManageDO.setCreateBy(userId);
|
||||
serviceItemsManageDO.setUpdateBy(userId);
|
||||
}else {
|
||||
serviceItemsManageDO.setCreateBy(new Long("0"));
|
||||
serviceItemsManageDO.setUpdateBy(new Long("0"));
|
||||
}
|
||||
serviceItemsManageDO.setCreateByName(userName);
|
||||
serviceItemsManageDO.setUpdateByName(userName);
|
||||
serviceItemsManageDO.setCreateTime(new Date());
|
||||
serviceItemsManageDO.setUpdateTime(new Date());
|
||||
serviceItemsManageDO.setDelFlag(1);
|
||||
}
|
||||
// 如果有查询条件(createByName 或 updateByName),说明是查询操作,不应该设置这些字段
|
||||
// 字段值已经在 BeanUtils.copyProperties 中从 DTO 拷贝过来了
|
||||
}
|
||||
return serviceItemsManageDO;
|
||||
}
|
||||
|
||||
+61
@@ -0,0 +1,61 @@
|
||||
package com.mhd.basic.interfaces.assember.shipperLeaseDetails;
|
||||
|
||||
import cn.hutool.core.util.ObjectUtil;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.basic.interfaces.dto.shipperLeaseDetailsApi.ShipperLeaseDetailsDTO;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.DigitalLogisticsException;
|
||||
import com.mhd.common.core.exception.digitalLogisticsException.UserError;
|
||||
import com.mhd.common.core.utils.IgnoreNullUtil;
|
||||
import com.mhd.common.core.utils.bean.BeanUtils;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 货主租赁明细Assembler
|
||||
*
|
||||
*/
|
||||
@Component
|
||||
public class ShipperLeaseDetailsAssembler {
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public ShipperLeaseDetailsDO toDO(ShipperLeaseDetailsDTO shipperLeaseDetailsDTO) {
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = new ShipperLeaseDetailsDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(shipperLeaseDetailsDTO, shipperLeaseDetailsDO, IgnoreNullUtil.getNullPropertyNames(shipperLeaseDetailsDTO));
|
||||
return shipperLeaseDetailsDO;
|
||||
}
|
||||
|
||||
/**
|
||||
* 转换实体
|
||||
*/
|
||||
public ShipperLeaseDetailsDO toDOByEdit(ShipperLeaseDetailsDTO shipperLeaseDetailsDTO) {
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = new ShipperLeaseDetailsDO();
|
||||
// 拷贝
|
||||
BeanUtils.copyProperties(shipperLeaseDetailsDTO, shipperLeaseDetailsDO, IgnoreNullUtil.getNullPropertyNames(shipperLeaseDetailsDTO));
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
}
|
||||
if(shipperLeaseDetailsDTO.getId() != null){
|
||||
shipperLeaseDetailsDO.setUpdateBy(loginUser.getUserid());
|
||||
shipperLeaseDetailsDO.setUpdateByName(loginUser.getUsername());
|
||||
shipperLeaseDetailsDO.setUpdateTime(new Date());
|
||||
}else {
|
||||
shipperLeaseDetailsDO.setOrganizationId(loginUser.getUserPo().getOrganizationId());
|
||||
shipperLeaseDetailsDO.setOrganizationName(loginUser.getUserPo().getOrganizationName());
|
||||
shipperLeaseDetailsDO.setTopOrganizationId(loginUser.getUserPo().getTopOrganizationId());
|
||||
shipperLeaseDetailsDO.setCreateBy(loginUser.getUserid());
|
||||
shipperLeaseDetailsDO.setCreateByName(loginUser.getUsername());
|
||||
shipperLeaseDetailsDO.setCreateTime(new Date());
|
||||
}
|
||||
return shipperLeaseDetailsDO;
|
||||
}
|
||||
|
||||
}
|
||||
+8
@@ -44,6 +44,10 @@ public class BatchDetailDTO extends BaseVOEntity{
|
||||
@Excel(name = "批次标签")
|
||||
private String batchLabels;
|
||||
|
||||
@ApiModelProperty("字段名称")
|
||||
@Excel(name = "字段名称")
|
||||
private String fieldName;
|
||||
|
||||
@ApiModelProperty("输入控制: 1-必填 2-可选")
|
||||
@Excel(name = "输入控制: 1-必填 2-可选")
|
||||
private String inputControl;
|
||||
@@ -56,6 +60,10 @@ public class BatchDetailDTO extends BaseVOEntity{
|
||||
@Excel(name = "属性选项")
|
||||
private String attributeOption;
|
||||
|
||||
@ApiModelProperty("是否显示: 0-不显示 1-显示")
|
||||
@Excel(name = "是否显示: 0-不显示 1-显示")
|
||||
private Integer isDisplay;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
@Excel(name = "备注")
|
||||
private String remark;
|
||||
|
||||
+6
@@ -126,4 +126,10 @@ public class ExpenseAccountDTO extends BaseVOEntity{
|
||||
|
||||
@ApiModelProperty("服务项名称")
|
||||
private String serviceItemsName;
|
||||
|
||||
@ApiModelProperty("费率")
|
||||
private BigDecimal rate;
|
||||
|
||||
@ApiModelProperty(name = "创建订单是否固定显示 0-否 1-是")
|
||||
private Integer fixedOrderDisplay;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,80 @@
|
||||
package com.mhd.basic.interfaces.dto.lease;
|
||||
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理对象 container
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class LeaseDTO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("开始日期")
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private Date startDate;
|
||||
|
||||
@ApiModelProperty("结束日期")
|
||||
@JsonFormat(timezone = "GMT+8", pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern = "yyyy-MM-dd")
|
||||
private Date endDate;
|
||||
|
||||
@ApiModelProperty("备注")
|
||||
private String remark;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件开始日期")
|
||||
private String createTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "创建时间查询条件结束日期")
|
||||
private String createTimeEnd;
|
||||
|
||||
@ApiModelProperty(name = "修改时间查询条件开始日期")
|
||||
private String updateTimeStart;
|
||||
|
||||
@ApiModelProperty(name = "修改时间查询条件结束日期")
|
||||
private String updateTimeEnd;
|
||||
}
|
||||
+180
-1
@@ -181,4 +181,183 @@ public class MaterialBaseInfoDTO extends BaseVOEntity{
|
||||
@ApiModelProperty("是否公用: 1-是 2-否")
|
||||
@Excel(name = "是否公用: 1-是 2-否")
|
||||
private Integer common;
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 商品名称
|
||||
*/
|
||||
@ApiModelProperty("商品名称")
|
||||
@Excel(name = "商品名称")
|
||||
private String commodityName;
|
||||
/**
|
||||
* 商品编码
|
||||
*/
|
||||
@ApiModelProperty("商品编码")
|
||||
@Excel(name = "商品编码")
|
||||
private String commodityNo;
|
||||
/**
|
||||
* 料号
|
||||
*/
|
||||
@ApiModelProperty("料号")
|
||||
@Excel(name = "料号")
|
||||
private String materialNo;
|
||||
/**
|
||||
* 规格型号
|
||||
*/
|
||||
@ApiModelProperty("规格型号")
|
||||
@Excel(name = "规格型号")
|
||||
private String specificationModel;
|
||||
|
||||
/**
|
||||
* Invoice No
|
||||
*/
|
||||
@ApiModelProperty("Invoice No")
|
||||
@Excel(name = "Invoice No")
|
||||
private String invoiceNo;
|
||||
/**
|
||||
* 升
|
||||
*/
|
||||
@ApiModelProperty("升")
|
||||
@Excel(name = "升")
|
||||
private String liter;
|
||||
|
||||
/**
|
||||
* 尺寸
|
||||
*/
|
||||
@ApiModelProperty("尺寸")
|
||||
@Excel(name = "尺寸")
|
||||
private String size;
|
||||
|
||||
/**
|
||||
* 申报单位
|
||||
*/
|
||||
@ApiModelProperty("申报单位")
|
||||
@Excel(name = "申报单位")
|
||||
private String declareUnit;
|
||||
|
||||
/**
|
||||
* Batch Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Batch Ref NO’s")
|
||||
@Excel(name = "Batch Ref NO’s")
|
||||
private String batchRefNo;
|
||||
|
||||
/**
|
||||
* Sheet Ref NO’s
|
||||
*/
|
||||
@ApiModelProperty("Sheet Ref NO’s")
|
||||
@Excel(name = "Sheet Ref NO’s")
|
||||
private String sheetRefNo;
|
||||
|
||||
/**
|
||||
* 原产国
|
||||
*/
|
||||
@ApiModelProperty("原产国")
|
||||
@Excel(name = "原产国")
|
||||
private String countryOfOrigin;
|
||||
|
||||
/**
|
||||
* 箱号/卡板号
|
||||
*/
|
||||
@ApiModelProperty("箱号/卡板号")
|
||||
@Excel(name = "箱号/卡板号")
|
||||
private String casePalletNo;
|
||||
|
||||
/**
|
||||
* 币制
|
||||
*/
|
||||
@ApiModelProperty("币制")
|
||||
@Excel(name = "币制")
|
||||
private String currency;
|
||||
|
||||
/**
|
||||
* 申报数量
|
||||
*/
|
||||
@ApiModelProperty("申报数量")
|
||||
@Excel(name = "申报数量")
|
||||
private Double declareQuantity;
|
||||
|
||||
/**
|
||||
* 箱数
|
||||
*/
|
||||
@ApiModelProperty("箱数")
|
||||
@Excel(name = "箱数")
|
||||
private Double caseCount;
|
||||
|
||||
/**
|
||||
* 件数
|
||||
*/
|
||||
@ApiModelProperty("件数")
|
||||
@Excel(name = "件数")
|
||||
private Double pieceCount;
|
||||
|
||||
/**
|
||||
* 出库数量
|
||||
*/
|
||||
@ApiModelProperty("出库数量")
|
||||
@Excel(name = "出库数量")
|
||||
private Double outboundQuantity;
|
||||
|
||||
/**
|
||||
* 总净重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总净重(KG)")
|
||||
@Excel(name = "总净重(KG)")
|
||||
private Double totalNetWeight;
|
||||
|
||||
/**
|
||||
* 总毛重(KG)
|
||||
*/
|
||||
@ApiModelProperty("总毛重(KG)")
|
||||
@Excel(name = "总毛重(KG)")
|
||||
private Double totalGrossWeight;
|
||||
|
||||
/**
|
||||
* 总体积(CBM)
|
||||
*/
|
||||
@ApiModelProperty("总体积(CBM)")
|
||||
@Excel(name = "总体积(CBM)")
|
||||
private Double totalVolume;
|
||||
|
||||
/**
|
||||
* 总面积(SQM)
|
||||
*/
|
||||
@ApiModelProperty("总面积(SQM)")
|
||||
@Excel(name = "总面积(SQM)")
|
||||
private Double totalArea;
|
||||
/**
|
||||
* 总价
|
||||
*/
|
||||
@ApiModelProperty("总价")
|
||||
@Excel(name = "总价")
|
||||
private Double totalAmount;
|
||||
|
||||
/**
|
||||
* 单位
|
||||
*/
|
||||
@ApiModelProperty("单位")
|
||||
@Excel(name = "单位")
|
||||
private String unit;
|
||||
|
||||
|
||||
@ApiModelProperty("SKU码")
|
||||
private String skuCode;
|
||||
|
||||
@ApiModelProperty("单价")
|
||||
private BigDecimal unitPrice;
|
||||
|
||||
@ApiModelProperty("原产国")
|
||||
private String originCountry;
|
||||
|
||||
@ApiModelProperty("HS码")
|
||||
private String hsCode;
|
||||
|
||||
@ApiModelProperty("申报单位")
|
||||
private String declarationUnit;
|
||||
|
||||
@ApiModelProperty("法定单位")
|
||||
private String statutoryUnit;
|
||||
|
||||
@ApiModelProperty("法定第二单位")
|
||||
private String statutorySecondUnit;
|
||||
}
|
||||
+74
@@ -0,0 +1,74 @@
|
||||
package com.mhd.basic.interfaces.dto.shipperLeaseDetailsApi;
|
||||
|
||||
import com.baomidou.mybatisplus.annotation.IdType;
|
||||
import com.baomidou.mybatisplus.annotation.TableId;
|
||||
import com.fasterxml.jackson.annotation.JsonFormat;
|
||||
import com.mhd.common.core.annotation.Excel;
|
||||
import com.mhd.common.core.web.domain.BaseVOEntity;
|
||||
import io.swagger.annotations.ApiModelProperty;
|
||||
import lombok.Data;
|
||||
import org.springframework.format.annotation.DateTimeFormat;
|
||||
|
||||
import java.math.BigDecimal;
|
||||
import java.util.Date;
|
||||
|
||||
/**
|
||||
* 货主租赁明细
|
||||
*
|
||||
*/
|
||||
|
||||
@Data
|
||||
public class ShipperLeaseDetailsDTO extends BaseVOEntity{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
@ApiModelProperty("id")
|
||||
@TableId(type = IdType.AUTO)
|
||||
private Long id;
|
||||
|
||||
@ApiModelProperty("组织表ID")
|
||||
@Excel(name = "组织表ID")
|
||||
private Long organizationId;
|
||||
|
||||
@ApiModelProperty("组织名称")
|
||||
@Excel(name = "组织名称")
|
||||
private String organizationName;
|
||||
|
||||
@ApiModelProperty("一级组织表ID")
|
||||
@Excel(name = "一级组织表ID")
|
||||
private Long topOrganizationId;
|
||||
|
||||
@ApiModelProperty("仓库ID")
|
||||
private Long warehouseId;
|
||||
|
||||
@ApiModelProperty("仓库名字")
|
||||
private String warehouseName;
|
||||
|
||||
@ApiModelProperty("货主id")
|
||||
private Long shipperId;
|
||||
|
||||
@ApiModelProperty("货主名称")
|
||||
private String cargoOwnerName;
|
||||
|
||||
@ApiModelProperty(value = "租赁方式(整租/散租)")
|
||||
private String leaseType;
|
||||
|
||||
@ApiModelProperty("租赁面积(m²)")
|
||||
private BigDecimal leaseArea;
|
||||
|
||||
@ApiModelProperty("业务日期")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDate;
|
||||
|
||||
@ApiModelProperty("业务日期开始时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDateStart;
|
||||
|
||||
@ApiModelProperty("业务日期结束时间")
|
||||
@JsonFormat(timezone = "GMT+8",pattern = "yyyy-MM-dd")
|
||||
@DateTimeFormat(pattern="yyyy-MM-dd")
|
||||
private Date businessDateEnd;
|
||||
|
||||
|
||||
}
|
||||
+83
-6
@@ -18,6 +18,7 @@ import com.mhd.common.core.constant.HttpStatus;
|
||||
import com.mhd.common.core.domain.entity.R;
|
||||
import com.sun.org.apache.bcel.internal.generic.NEW;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.apache.ibatis.annotations.Param;
|
||||
import org.springframework.beans.BeanUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
@@ -28,6 +29,8 @@ import javax.annotation.Resource;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import com.mhd.common.security.utils.SecurityUtils;
|
||||
import com.mhd.system.api.model.LoginUser;
|
||||
import org.springframework.web.client.RestTemplate;
|
||||
|
||||
/**
|
||||
@@ -52,11 +55,35 @@ public class ExpenseAccountApi extends BaseController{
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(ExpenseAccountDTO expenseAccountDTO)
|
||||
{
|
||||
//转换实体
|
||||
ExpenseAccountDO expenseAccountDO = expenseAccountAssembler.toDO(expenseAccountDTO);
|
||||
startPage();
|
||||
List<ExpenseAccountPO> list = expenseAccountApplicationService.queryList(expenseAccountDO);
|
||||
return getDataTable(list);
|
||||
logger.info("收到查询费用科目列表请求,参数:{}", expenseAccountDTO);
|
||||
try {
|
||||
//转换实体,如果 expenseAccountDTO 为 null,创建一个新的对象
|
||||
if (expenseAccountDTO == null) {
|
||||
expenseAccountDTO = new ExpenseAccountDTO();
|
||||
logger.info("expenseAccountDTO 为 null,创建新对象");
|
||||
}
|
||||
ExpenseAccountDO expenseAccountDO = expenseAccountAssembler.toDO(expenseAccountDTO);
|
||||
if(StringUtils.isBlank(expenseAccountDTO.getCreateByName())){
|
||||
expenseAccountDO.setCreateByName(null);
|
||||
}
|
||||
if(StringUtils.isBlank(expenseAccountDTO.getUpdateByName())){
|
||||
expenseAccountDO.setUpdateByName(null);
|
||||
}
|
||||
logger.info("转换后的 ExpenseAccountDO:{}", expenseAccountDO);
|
||||
startPage();
|
||||
logger.info("分页参数已设置");
|
||||
List<ExpenseAccountPO> list = expenseAccountApplicationService.queryList(expenseAccountDO);
|
||||
logger.info("查询完成,返回数据条数:{}", list != null ? list.size() : 0);
|
||||
if (list != null && list.isEmpty()) {
|
||||
logger.warn("查询结果为空,可能的原因:1.数据库中没有符合条件的数据 2.数据权限过滤 3.SQL查询条件问题");
|
||||
logger.warn("查询条件:topOrganizationId={}, del_flag=1", expenseAccountDO.getTopOrganizationId());
|
||||
}
|
||||
return getDataTable(list);
|
||||
} catch (Exception e) {
|
||||
logger.error("查询费用科目列表失败", e);
|
||||
e.printStackTrace();
|
||||
return getDataTable(new ArrayList<>());
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation("查询费用科目树型列表")
|
||||
@@ -81,9 +108,50 @@ public class ExpenseAccountApi extends BaseController{
|
||||
public AjaxResult selectOtherExpenseAccount(SearchExpenseAccountDTO searchExpenseAccountDTO){
|
||||
SearchExpenseAccountDO searchExpenseAccountDO = new SearchExpenseAccountDO();
|
||||
BeanUtils.copyProperties(searchExpenseAccountDTO,searchExpenseAccountDO);
|
||||
|
||||
// 数据权限:根据组织ID实现数据隔离
|
||||
// organizationId=2827(南光)时,查询所有组织的数据;其他组织只查询自己的数据
|
||||
LoginUser loginUser = SecurityUtils.getLoginUser();
|
||||
if (loginUser != null && loginUser.getOrganizationPo() != null) {
|
||||
Long loginUserOrganizationId = loginUser.getOrganizationPo().getOrganizationId();
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织(organizationId=2827):可以查询所有组织的数据,不设置 organizationId 过滤条件
|
||||
searchExpenseAccountDO.setOrganizationId(null);
|
||||
} else {
|
||||
// 其他组织:只查询自己组织的数据
|
||||
searchExpenseAccountDO.setOrganizationId(loginUserOrganizationId);
|
||||
}
|
||||
}
|
||||
|
||||
return AjaxResult.success(expenseAccountApplicationService.selectOtherExpenseAccount(searchExpenseAccountDO));
|
||||
|
||||
}
|
||||
/**
|
||||
* 测试查询 - 不设置组织ID,查看是否有数据
|
||||
*/
|
||||
@ApiOperation("测试查询费用科目列表(不设置组织ID)")
|
||||
@GetMapping("/testList")
|
||||
public AjaxResult testList(ExpenseAccountDTO expenseAccountDTO)
|
||||
{
|
||||
logger.info("测试查询费用科目列表,不设置组织ID");
|
||||
try {
|
||||
if (expenseAccountDTO == null) {
|
||||
expenseAccountDTO = new ExpenseAccountDTO();
|
||||
}
|
||||
ExpenseAccountDO expenseAccountDO = expenseAccountAssembler.toDO(expenseAccountDTO);
|
||||
// 不设置组织ID,测试是否能查询到数据
|
||||
expenseAccountDO.setTopOrganizationId(null);
|
||||
logger.info("测试查询参数:{}", expenseAccountDO);
|
||||
startPage();
|
||||
List<ExpenseAccountPO> list = expenseAccountApplicationService.queryList(expenseAccountDO);
|
||||
logger.info("测试查询结果:{} 条", list != null ? list.size() : 0);
|
||||
return AjaxResult.success(list);
|
||||
} catch (Exception e) {
|
||||
logger.error("测试查询失败", e);
|
||||
return AjaxResult.error("测试查询失败:" + e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation("查询费用科目-所有现金明细")
|
||||
@GetMapping("/selectAllCashExpenseAccount")
|
||||
public AjaxResult selectAllCashExpenseAccount(){
|
||||
@@ -197,7 +265,16 @@ public class ExpenseAccountApi extends BaseController{
|
||||
return AjaxResult.error(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation("修改创建订单默认显示设置")
|
||||
@PostMapping("/changeFixedOrderDisplay")
|
||||
public AjaxResult changeFixedOrderDisplay(@RequestBody ExpenseAccountDTO expenseAccountDTO)
|
||||
{
|
||||
try {
|
||||
return toAjax(expenseAccountApplicationService.changeFixedOrderDisplay(expenseAccountDTO));
|
||||
}catch (Exception e){
|
||||
return AjaxResult.error(e.getMessage());
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation("根据code获取费用科目")
|
||||
@GetMapping(value = "/getInfoByCode")
|
||||
|
||||
+7
@@ -8,6 +8,7 @@ import com.mhd.basic.domain.serviceItemsManage.repository.todo.ServiceItemsManag
|
||||
import com.mhd.basic.interfaces.assember.serviceItemsManage.ServiceItemsManageAssembler;
|
||||
import com.mhd.basic.interfaces.dto.serviceItemsManage.ServiceItemsManageDTO;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.commons.lang.StringUtils;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@@ -40,6 +41,12 @@ public class ServiceItemsManageApi extends BaseController{
|
||||
{
|
||||
//转换实体
|
||||
ServiceItemsManageDO serviceItemsManageDO = serviceItemsManageAssembler.toDO(serviceItemsManageDTO);
|
||||
if(StringUtils.isBlank(serviceItemsManageDTO.getCreateByName())){
|
||||
serviceItemsManageDO.setCreateByName(null);
|
||||
}
|
||||
if(StringUtils.isBlank(serviceItemsManageDTO.getUpdateByName())){
|
||||
serviceItemsManageDO.setUpdateByName(null);
|
||||
}
|
||||
startPage();
|
||||
List<ServiceItemsManagePO> list = serviceItemsManageApplicationService.queryList(serviceItemsManageDO);
|
||||
return getDataTable(list);
|
||||
|
||||
+112
@@ -0,0 +1,112 @@
|
||||
package com.mhd.basic.interfaces.facadeApi.lease;
|
||||
|
||||
import com.mhd.basic.application.service.Lease.LeaseApplicationService;
|
||||
import com.mhd.basic.application.service.container.ContainerApplicationService;
|
||||
import com.mhd.basic.domain.container.repository.po.ContainerPO;
|
||||
import com.mhd.basic.domain.container.repository.todo.ContainerDO;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.WarehouseOccupancyRate;
|
||||
import com.mhd.basic.interfaces.assember.container.ContainerAssembler;
|
||||
import com.mhd.basic.interfaces.assember.lease.LeaseAssembler;
|
||||
import com.mhd.basic.interfaces.dto.container.ContainerDTO;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 租赁管理Api
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/LeaseApi")
|
||||
public class LeaseApi extends BaseController{
|
||||
|
||||
@Autowired
|
||||
private LeaseApplicationService leaseApplicationService;
|
||||
|
||||
@Resource
|
||||
private LeaseAssembler leaseAssembler;
|
||||
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
@ApiOperation("查询租赁管理列表")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(LeaseDTO leaseDTO)
|
||||
{
|
||||
//转换实体
|
||||
LeaseDO leaseDO = leaseAssembler.toDO(leaseDTO);
|
||||
startPage();
|
||||
List<LeasePO> list = leaseApplicationService.queryList(leaseDO);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询租赁管理列表
|
||||
*/
|
||||
@ApiOperation("查询租赁管理列表")
|
||||
@GetMapping("/listByApp")
|
||||
public AjaxResult listByApp(LeaseDTO leaseDTO)
|
||||
{
|
||||
//转换实体
|
||||
LeaseDO leaseDO = leaseAssembler.toDO(leaseDTO);
|
||||
List<LeasePO> list = leaseApplicationService.queryList(leaseDO);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑租赁管理
|
||||
*/
|
||||
@ApiOperation("编辑租赁管理")
|
||||
@PostMapping("/edit")
|
||||
public AjaxResult edit(@RequestBody LeaseDTO leaseDTO)
|
||||
{
|
||||
//转换实体
|
||||
LeaseDO leaseDO = leaseAssembler.toDOByEdit(leaseDTO);
|
||||
if(leaseDTO.getId() != null){
|
||||
return toAjax(leaseApplicationService.update(leaseDO));
|
||||
}else {
|
||||
return toAjax(leaseApplicationService.insert(leaseDO));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除租赁管理
|
||||
*/
|
||||
@ApiOperation("批量删除租赁管理")
|
||||
@DeleteMapping("/deleteByIds/{leaseIds}")
|
||||
public AjaxResult delete(@PathVariable Long[] leaseIds)
|
||||
{
|
||||
return toAjax(leaseApplicationService.delete(leaseIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取租赁管理详细信息
|
||||
*/
|
||||
@ApiOperation("获取租赁管理")
|
||||
@GetMapping(value = "/getInfo/{leaseId}")
|
||||
public AjaxResult getInfo(@PathVariable("leaseId") Long leaseId)
|
||||
{
|
||||
return AjaxResult.success(leaseApplicationService.getInfo(leaseId));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 批量作废租赁
|
||||
*/
|
||||
@ApiOperation("批量作废租赁")
|
||||
@GetMapping("/nullifyByIds/{leaseIds}")
|
||||
public AjaxResult nullifyByIds(@PathVariable("leaseIds") List<Long> leaseIds)
|
||||
{
|
||||
return toAjax(leaseApplicationService.nullifyByIds(leaseIds));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
+161
@@ -0,0 +1,161 @@
|
||||
package com.mhd.basic.interfaces.facadeApi.shipperLeaseDetails;
|
||||
|
||||
import com.mhd.basic.application.service.Lease.LeaseApplicationService;
|
||||
import com.mhd.basic.application.service.shipperLeaseDetails.ShipperLeaseDetailsApplicationService;
|
||||
import com.mhd.basic.domain.lease.repository.po.LeasePO;
|
||||
import com.mhd.basic.domain.lease.repository.todo.LeaseDO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.ShipperLeaseDetails;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.entity.WarehouseOccupancyRate;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.po.ShipperLeaseDetailsPO;
|
||||
import com.mhd.basic.domain.shipperLeaseDetails.repository.todo.ShipperLeaseDetailsDO;
|
||||
import com.mhd.basic.interfaces.assember.lease.LeaseAssembler;
|
||||
import com.mhd.basic.interfaces.assember.shipperLeaseDetails.ShipperLeaseDetailsAssembler;
|
||||
import com.mhd.basic.interfaces.dto.lease.LeaseDTO;
|
||||
import com.mhd.basic.interfaces.dto.shipperLeaseDetailsApi.ShipperLeaseDetailsDTO;
|
||||
import com.mhd.common.core.web.controller.BaseController;
|
||||
import com.mhd.common.core.web.domain.AjaxResult;
|
||||
import com.mhd.common.core.web.page.TableDataInfo;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.Comparator;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
* 货主租赁明细Api
|
||||
*/
|
||||
@RestController
|
||||
@RequestMapping("/ShipperLeaseDetailsApi")
|
||||
public class ShipperLeaseDetailsApi extends BaseController{
|
||||
|
||||
@Autowired
|
||||
private LeaseApplicationService leaseApplicationService;
|
||||
|
||||
@Autowired
|
||||
private ShipperLeaseDetailsApplicationService shipperLeaseDetailsApplicationService;
|
||||
|
||||
@Resource
|
||||
private ShipperLeaseDetailsAssembler shipperLeaseDetailsAssembler;
|
||||
|
||||
/**
|
||||
* 分页查询货主租赁明细列表
|
||||
*/
|
||||
@ApiOperation("查询货主租赁明细列表")
|
||||
@GetMapping("/list")
|
||||
public TableDataInfo list(ShipperLeaseDetailsDTO shipperLeaseDetailsDTO)
|
||||
{
|
||||
//转换实体
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = shipperLeaseDetailsAssembler.toDO(shipperLeaseDetailsDTO);
|
||||
startPage();
|
||||
List<ShipperLeaseDetailsPO> list = shipperLeaseDetailsApplicationService.queryList(shipperLeaseDetailsDO);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 分页查询货主租赁明细列表
|
||||
*/
|
||||
@ApiOperation("查询货主租赁明细列表")
|
||||
@GetMapping("/listByApp")
|
||||
public AjaxResult listByApp(ShipperLeaseDetailsDTO shipperLeaseDetailsDTO)
|
||||
{
|
||||
//转换实体
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = shipperLeaseDetailsAssembler.toDO(shipperLeaseDetailsDTO);
|
||||
List<ShipperLeaseDetailsPO> list = shipperLeaseDetailsApplicationService.queryList(shipperLeaseDetailsDO);
|
||||
return AjaxResult.success(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑货主租赁明细
|
||||
*/
|
||||
@ApiOperation("编辑货主租赁明细")
|
||||
@PostMapping("/edit")
|
||||
public AjaxResult edit(@RequestBody ShipperLeaseDetailsDTO shipperLeaseDetailsDTO)
|
||||
{
|
||||
//转换实体
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = shipperLeaseDetailsAssembler.toDOByEdit(shipperLeaseDetailsDTO);
|
||||
if(shipperLeaseDetailsDTO.getId() != null){
|
||||
return toAjax(shipperLeaseDetailsApplicationService.update(shipperLeaseDetailsDO));
|
||||
}else {
|
||||
return toAjax(shipperLeaseDetailsApplicationService.insert(shipperLeaseDetailsDO));
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 编辑货主租赁明细
|
||||
*/
|
||||
@ApiOperation("编辑货主租赁明细")
|
||||
@PostMapping("/editList")
|
||||
public AjaxResult edit(@RequestBody List<ShipperLeaseDetailsDTO> shipperLeaseDetailsDTO)
|
||||
{
|
||||
for (ShipperLeaseDetailsDTO leaseDetailsDTO : shipperLeaseDetailsDTO) {
|
||||
//转换实体
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = shipperLeaseDetailsAssembler.toDOByEdit(leaseDetailsDTO);
|
||||
shipperLeaseDetailsApplicationService.update(shipperLeaseDetailsDO);
|
||||
}
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
/**
|
||||
* 批量删除货主租赁明细
|
||||
*/
|
||||
@ApiOperation("批量删除货主租赁明细")
|
||||
@DeleteMapping("/deleteByIds/{shipperLeaseDetailsIds}")
|
||||
public AjaxResult delete(@PathVariable Long[] shipperLeaseDetailsIds)
|
||||
{
|
||||
return toAjax(shipperLeaseDetailsApplicationService.delete(shipperLeaseDetailsIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 获取货主租赁明细详细信息
|
||||
*/
|
||||
@ApiOperation("获取货主租赁明细")
|
||||
@GetMapping(value = "/getInfo/{shipperLeaseDetailsId}")
|
||||
public AjaxResult getInfo(@PathVariable("shipperLeaseDetailsId") Long shipperLeaseDetailsId)
|
||||
{
|
||||
return AjaxResult.success(shipperLeaseDetailsApplicationService.getInfo(shipperLeaseDetailsId));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 批量作废租赁
|
||||
*/
|
||||
@ApiOperation("批量作废租赁")
|
||||
@GetMapping("/nullifyByIds/{shipperLeaseDetailsIds}")
|
||||
public AjaxResult nullifyByIds(@PathVariable("shipperLeaseDetailsIds") List<Long> shipperLeaseDetailsIds)
|
||||
{
|
||||
return toAjax(shipperLeaseDetailsApplicationService.nullifyByIds(shipperLeaseDetailsIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 计算货主租赁明细
|
||||
*/
|
||||
@ApiOperation("货主租赁明细")
|
||||
@PostMapping("/shipperLeaseDetails")
|
||||
public AjaxResult shipperLeaseDetails()
|
||||
{
|
||||
leaseApplicationService.shipperLeaseDetails();
|
||||
return AjaxResult.success();
|
||||
}
|
||||
|
||||
/**
|
||||
* 计算仓库出租率
|
||||
* warehouseId 仓库id
|
||||
*/
|
||||
@ApiOperation("仓库出租率")
|
||||
@PostMapping("/warehouseOccupancyRate")
|
||||
public TableDataInfo warehouseOccupancyRate(@RequestBody ShipperLeaseDetailsDTO shipperLeaseDetailsDTO)
|
||||
{
|
||||
ShipperLeaseDetailsDO shipperLeaseDetailsDO = shipperLeaseDetailsAssembler.toDO(shipperLeaseDetailsDTO);
|
||||
List<WarehouseOccupancyRate> warehouseOccupancyRates = leaseApplicationService.warehouseOccupancyRate(shipperLeaseDetailsDO);
|
||||
// 按照businessDate倒序排序
|
||||
warehouseOccupancyRates = warehouseOccupancyRates.stream()
|
||||
.sorted(Comparator.comparing(WarehouseOccupancyRate::getBusinessDate, Comparator.nullsLast(Comparator.reverseOrder())))
|
||||
.collect(Collectors.toList());
|
||||
return getDataTable(warehouseOccupancyRates);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
+34
-7
@@ -85,12 +85,25 @@ public class SysDictDataServiceImpl extends ServiceImpl<SysDictDataMapper, SysDi
|
||||
if (ObjectUtil.isNull(loginUser)) {
|
||||
throw new DigitalLogisticsException(UserError.TIMEOUT);
|
||||
}
|
||||
// 数据权限验证:南光组织(organizationId=2827)可以删除所有组织的数据,其他组织只能删除自己组织的数据
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long loginUserTopOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
|
||||
for (Long dictCode : dictCodes)
|
||||
{
|
||||
SysDictData data = selectDictDataById(dictCode);
|
||||
if (ObjectUtil.notEqual(data.getTopOrganizationId(), loginUser.getUserPo().getTopOrganizationId())) {
|
||||
throw new ServiceException("修改失败");
|
||||
|
||||
// 南光组织(organizationId=2827)可以删除所有组织的数据
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织可以删除,不需要验证 topOrganizationId
|
||||
} else {
|
||||
// 其他组织:只能删除自己组织的数据
|
||||
// 使用 Objects.equals 安全比较,处理 null 值的情况
|
||||
if (!java.util.Objects.equals(data.getTopOrganizationId(), loginUserTopOrganizationId)) {
|
||||
throw new ServiceException("删除失败:无权删除其他组织的字典数据");
|
||||
}
|
||||
}
|
||||
|
||||
dictDataMapper.deleteDictDataById(dictCode);
|
||||
SysDictData dictData = new SysDictData();
|
||||
dictData.setDictType(data.getDictType());
|
||||
@@ -146,11 +159,25 @@ public class SysDictDataServiceImpl extends ServiceImpl<SysDictDataMapper, SysDi
|
||||
if (ObjectUtil.isNull(sysDictData)) {
|
||||
throw new ServiceException("字典数据未找到");
|
||||
}
|
||||
if ("Y".equals(sysDictData.getIsDefault())) {
|
||||
throw new ServiceException("默认数据不允许修改");
|
||||
}
|
||||
if (ObjectUtil.notEqual(sysDictData.getTopOrganizationId(), loginUser.getUserPo().getTopOrganizationId())) {
|
||||
throw new ServiceException("修改失败");
|
||||
|
||||
// 数据权限验证:南光组织(organizationId=2827)可以修改所有组织的数据(包括默认数据),其他组织只能修改自己组织的数据(包括默认数据)
|
||||
Long loginUserOrganizationId = loginUser.getUserPo().getOrganizationId();
|
||||
Long loginUserTopOrganizationId = loginUser.getUserPo().getTopOrganizationId();
|
||||
Long dictDataTopOrganizationId = sysDictData.getTopOrganizationId();
|
||||
Long dictDataOrganizationId = sysDictData.getOrganizationId();
|
||||
|
||||
// 南光组织(organizationId=2827)可以修改所有组织的数据(包括默认数据)
|
||||
if (loginUserOrganizationId != null && loginUserOrganizationId.equals(2827L)) {
|
||||
// 南光组织可以修改,不需要验证 topOrganizationId
|
||||
} else {
|
||||
// 其他组织:只能修改自己组织的数据(包括默认数据)
|
||||
// 使用 Objects.equals 安全比较,处理 null 值的情况
|
||||
boolean isSameTopOrg = java.util.Objects.equals(dictDataTopOrganizationId, loginUserTopOrganizationId);
|
||||
boolean isSameOrg = java.util.Objects.equals(dictDataOrganizationId, loginUserOrganizationId);
|
||||
|
||||
if (!isSameTopOrg || !isSameOrg) {
|
||||
throw new ServiceException("修改失败:无权修改其他组织的字典数据");
|
||||
}
|
||||
}
|
||||
data.setUpdateBy(loginUser.getUserPo().getUserName());
|
||||
int row = dictDataMapper.updateDictData(data);
|
||||
|
||||
@@ -13,19 +13,17 @@ spring:
|
||||
cloud:
|
||||
nacos:
|
||||
discovery:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
server-addr: 10.33.0.129:6010
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
config:
|
||||
# server-addr: 127.0.0.1:8848
|
||||
# 线上测试环境配置 容器名+端口号
|
||||
server-addr: 10.33.0.129:6010
|
||||
#线上正式环境
|
||||
# server-addr: 10.102.192.105:6848
|
||||
server-addr: 10.102.192.5:6848
|
||||
username: nacos
|
||||
password: manhuoda@2023
|
||||
group: DEFAULT_GROUP # 默认分组就是DEFAULT_GROUP,如果使用默认分组可以不配置
|
||||
file-extension: yml #默认properties
|
||||
# 共享配置
|
||||
shared-configs:
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
- application-${spring.profiles.active}.${spring.cloud.nacos.config.file-extension}
|
||||
@@ -102,7 +102,7 @@
|
||||
WHERE
|
||||
a.del_flag = 1
|
||||
<include refid="common_where"/>
|
||||
order by account_type,service_items_code,upper_subject_code,show_seq
|
||||
order by a.update_time DESC
|
||||
</select>
|
||||
<select id="selectCostSubject" parameterType="com.mhd.basic.domain.expenseAccount.repository.todo.ExpenseAccountDO"
|
||||
resultType="com.mhd.basic.domain.expenseAccount.repository.po.ExpenseAccountPO">
|
||||
@@ -191,12 +191,31 @@
|
||||
<if test="expenseAccountDO.updateTimeEnd != null and expenseAccountDO.updateTimeEnd != ''">
|
||||
AND date_format(a.update_time,'%Y-%m-%d') <![CDATA[<=]]> #{expenseAccountDO.updateTimeEnd}
|
||||
</if>
|
||||
<if test="expenseAccountDO.topOrganizationId != null ">
|
||||
<!-- 数据权限:南光组织(organizationId=2827)查全部,其他组织查自己 -->
|
||||
<!-- 如果 organizationId 和 topOrganizationId 都为 null,表示查询所有组织的数据(不添加组织过滤条件) -->
|
||||
<if test="expenseAccountDO.organizationId != null">
|
||||
<!-- 如果设置了 organizationId,添加 organization_id 条件 -->
|
||||
and a.organization_id = #{expenseAccountDO.organizationId}
|
||||
-- and a.organization_name IS NOT NULL
|
||||
-- and a.organization_name != ''
|
||||
-- and LENGTH(TRIM(a.organization_name)) > 0
|
||||
</if>
|
||||
<if test="expenseAccountDO.topOrganizationId != null and expenseAccountDO.organizationId == null">
|
||||
<!-- 如果设置了 topOrganizationId 但没有设置 organizationId,添加 top_organization_id 条件 -->
|
||||
and a.top_organization_id = #{expenseAccountDO.topOrganizationId}
|
||||
-- and a.organization_name IS NOT NULL
|
||||
-- and a.organization_name != ''
|
||||
-- and LENGTH(TRIM(a.organization_name)) > 0
|
||||
</if>
|
||||
<if test="expenseAccountDO.organizationName != null and expenseAccountDO.organizationName != ''">
|
||||
and a.organization_name like concat('%', #{expenseAccountDO.organizationName}, '%')
|
||||
</if>
|
||||
<if test="expenseAccountDO.serviceItemsCode != null and expenseAccountDO.serviceItemsCode != ''">
|
||||
and b.service_items_code = #{expenseAccountDO.serviceItemsCode}
|
||||
</if>
|
||||
<if test="expenseAccountDO.fixedOrderDisplay != null ">
|
||||
and a.fixed_order_display = #{expenseAccountDO.fixedOrderDisplay}
|
||||
</if>
|
||||
</sql>
|
||||
<select id="selectExpenseAccount" parameterType="com.mhd.basic.domain.expenseAccount.repository.todo.SearchExpenseAccountDO" resultType="com.mhd.basic.domain.expenseAccount.repository.po.QueryExpenseAccountPO">
|
||||
select
|
||||
@@ -238,6 +257,15 @@
|
||||
<if test="searchExpenseAccountDO.societyStatus != null ">
|
||||
and a.society_status = #{searchExpenseAccountDO.societyStatus}
|
||||
</if>
|
||||
<!-- 数据权限:南光组织(organizationId=2827)查全部,其他组织查自己 -->
|
||||
<!-- 如果 organizationId 为 null,表示查询所有组织的数据(不添加组织过滤条件) -->
|
||||
<if test="searchExpenseAccountDO.organizationId != null">
|
||||
<!-- 如果设置了 organizationId,添加 organization_id 条件 -->
|
||||
and a.organization_id = #{searchExpenseAccountDO.organizationId}
|
||||
and a.organization_name IS NOT NULL
|
||||
and a.organization_name != ''
|
||||
and LENGTH(TRIM(a.organization_name)) > 0
|
||||
</if>
|
||||
and a.del_flag=1
|
||||
order by show_seq
|
||||
</select>
|
||||
|
||||
+31
-19
@@ -8,18 +8,36 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
|
||||
<sql id="selectServiceItemsManagePo1">
|
||||
<where>
|
||||
del_flag = 1
|
||||
<if test="createByName != null and createByName != ''">
|
||||
and create_by_name like concat('%', #{createByName}, '%')
|
||||
</if>
|
||||
<if test="updateByName != null and updateByName != ''">
|
||||
and update_by_name like concat('%', #{updateByName}, '%')
|
||||
</if>
|
||||
<if test="topOrganizationId != null ">
|
||||
and top_organization_id = #{topOrganizationId}
|
||||
</if>
|
||||
<if test="organizationId != null ">
|
||||
<!-- <!– 删除标记:0-无状态,1-正常,2-已删除,查询时只查询正常的数据 –>-->
|
||||
<!-- <choose>-->
|
||||
<!-- <when test="delFlag != null">-->
|
||||
<!-- and del_flag = #{delFlag}-->
|
||||
<!-- </when>-->
|
||||
<!-- <otherwise>-->
|
||||
<!-- and del_flag = 1-->
|
||||
<!-- </otherwise>-->
|
||||
<!-- </choose>-->
|
||||
<!-- <if test="createByName != null and createByName != ''">-->
|
||||
<!-- and create_by_name like concat('%', #{createByName}, '%')-->
|
||||
<!-- </if>-->
|
||||
<!-- <if test="updateByName != null and updateByName != ''">-->
|
||||
<!-- and update_by_name like concat('%', #{updateByName}, '%')-->
|
||||
<!-- </if>-->
|
||||
<!-- 数据权限:南光组织(organizationId=2827)查全部,其他组织查自己 -->
|
||||
<!-- 如果 organizationId 和 topOrganizationId 都为 null,表示查询所有组织的数据(不添加组织过滤条件) -->
|
||||
<if test="organizationId != null">
|
||||
<!-- 如果设置了 organizationId,添加 organization_id 条件 -->
|
||||
and organization_id = #{organizationId}
|
||||
-- and organization_name IS NOT NULL
|
||||
-- and organization_name != ''
|
||||
-- and LENGTH(TRIM(organization_name)) > 0
|
||||
</if>
|
||||
<if test="topOrganizationId != null and organizationId == null">
|
||||
<!-- 如果设置了 topOrganizationId 但没有设置 organizationId,添加 top_organization_id 条件 -->
|
||||
and top_organization_id = #{topOrganizationId}
|
||||
-- and organization_name IS NOT NULL
|
||||
-- and organization_name != ''
|
||||
-- and LENGTH(TRIM(organization_name)) > 0
|
||||
</if>
|
||||
<if test="organizationName != null and organizationName != ''">
|
||||
and organization_name like concat('%', #{organizationName}, '%')
|
||||
@@ -42,12 +60,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="createTimeEnd != null and createTimeEnd != ''">
|
||||
AND date_format(create_time,'%Y-%m-%d') <![CDATA[<=]]> #{createTimeEnd}
|
||||
</if>
|
||||
<if test="createByName != null and createByName != ''">
|
||||
and create_by_name like concat('%', #{createByName}, '%')
|
||||
</if>
|
||||
<if test="updateByName != null and updateByName != ''">
|
||||
and update_by_name like concat('%', #{updateByName}, '%')
|
||||
</if>
|
||||
<if test="updateTimeStart != null and updateTimeStart != ''">
|
||||
AND date_format(update_time,'%Y-%m-%d') <![CDATA[>=]]> #{updateTimeStart}
|
||||
</if>
|
||||
@@ -63,10 +75,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<include refid="selectServiceItemsManagePo1"/>
|
||||
</select>
|
||||
|
||||
<select id="selectServiceTypes"
|
||||
<select id="selectServiceTypes" parameterType="com.mhd.basic.domain.serviceItemsManage.repository.todo.ServiceItemsManageDO"
|
||||
resultType="com.mhd.basic.domain.serviceItemsManage.repository.po.ServiceItemsManagePO">
|
||||
select organization_name,service_items_code,service_items_name,tax_rate,CONCAT(service_items_name,service_items_code) cost_type
|
||||
from service_items_manage
|
||||
where del_flag = 1
|
||||
<include refid="selectServiceItemsManagePo1"/>
|
||||
</select>
|
||||
</mapper>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user