Compare commits
1084 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
c813ed0062 | ||
|
|
f658d43a5a | ||
|
|
fe0b9c37a4 | ||
|
|
28cc0617c3 | ||
|
|
f2cb6b56ea | ||
|
|
81b7da07f4 | ||
|
|
db3f775c50 | ||
|
|
93a45319ac | ||
|
|
7627614284 | ||
|
|
ca5887028a | ||
|
|
1a3736fd29 | ||
|
|
09d00260f6 | ||
|
|
2e019ef933 | ||
|
|
6acc99c7cf | ||
|
|
b57e7813d6 | ||
|
|
09e6f4a1a1 | ||
|
|
872bb220dc | ||
|
|
2498e57600 | ||
|
|
cfbb673387 | ||
|
|
05db6501f7 | ||
|
|
a5aa090f4a | ||
|
|
09aae17a02 | ||
|
|
7f5739f89b | ||
|
|
131d4eb156 | ||
|
|
ffa0b0db30 | ||
|
|
7bd0084802 | ||
|
|
d88762f3ab | ||
|
|
ebdbed6d08 | ||
|
|
efdf505e63 | ||
|
|
98f25179d3 | ||
|
|
9a0c7dd73d | ||
|
|
0cf464e549 | ||
|
|
2e6ddeafdd | ||
|
|
633b94c375 | ||
|
|
6441018d95 | ||
|
|
e706431df5 | ||
|
|
db1a3566ae | ||
|
|
9225b4ff10 | ||
|
|
586a507bb1 | ||
|
|
034f29c734 | ||
|
|
478dd1d201 | ||
|
|
554aed024c | ||
|
|
b2e0fe1de4 | ||
|
|
b69a558df0 | ||
|
|
2f180a73ed | ||
|
|
82f3223a03 | ||
|
|
cfe48d539b | ||
|
|
8ef00ae285 | ||
|
|
ed032653ee | ||
|
|
9108a1585c | ||
|
|
d4855b702b | ||
|
|
40822ca05b | ||
|
|
4dac80f084 | ||
|
|
8609216ef5 | ||
|
|
9678c7f506 | ||
|
|
63cdebdf1f | ||
|
|
e89be8eb8c | ||
|
|
3559971a8d | ||
|
|
dc1d1a7e7e | ||
|
|
10ecce1e0d | ||
|
|
2520c27f77 | ||
|
|
63d684c972 | ||
|
|
35739b64a3 | ||
|
|
ddcda57a08 | ||
|
|
16ae69ed06 | ||
|
|
fd067d8abf | ||
|
|
42b3c72977 | ||
|
|
e34b4172b8 | ||
|
|
30d6ab64f8 | ||
|
|
2e8c40bcf3 | ||
|
|
f2385c3ace | ||
|
|
a45355b125 | ||
|
|
b3bb771066 | ||
|
|
068c6b986e | ||
|
|
18e2c89891 | ||
|
|
7b485753a6 | ||
|
|
8556d27173 | ||
|
|
d677aabbf4 | ||
|
|
aaa0748409 | ||
|
|
57ee156798 | ||
|
|
5ae4d8b4fa | ||
|
|
681327274c | ||
|
|
6ab2888fd0 | ||
|
|
80a0e0e8c7 | ||
|
|
80773e2d58 | ||
|
|
065bcc8a55 | ||
|
|
9398413999 | ||
|
|
cf623f6756 | ||
|
|
1b316baac6 | ||
|
|
4fc1d0e346 | ||
|
|
159fe37120 | ||
|
|
6f9486f065 | ||
|
|
94da71336a | ||
|
|
8c5ce396b2 | ||
|
|
0063820fdf | ||
|
|
fe80edebbd | ||
|
|
6b59c1e643 | ||
|
|
1b52381c71 | ||
|
|
763519876e | ||
|
|
cede181bc0 | ||
|
|
cb776eb4c0 | ||
|
|
8ed4f6eb3c | ||
|
|
9cf97f3203 | ||
|
|
2a984b8c56 | ||
|
|
22ecf48168 | ||
|
|
89422b2736 | ||
|
|
bcd4bf4ff1 | ||
|
|
a263bc6301 | ||
|
|
27ae773e20 | ||
|
|
085b61c2ab | ||
|
|
c7682680ee | ||
|
|
a301432a87 | ||
|
|
526de18a42 | ||
|
|
c940bf6cb2 | ||
|
|
a7643a6b93 | ||
|
|
24f6b9e80f | ||
|
|
d349616957 | ||
|
|
f7c9ba820d | ||
|
|
f99f59963a | ||
|
|
caaf9c74f3 | ||
|
|
076f47f5c4 | ||
|
|
f0e4e4c2bc | ||
|
|
c87fe45dfa | ||
|
|
49fd03df7f | ||
|
|
6deed61311 | ||
|
|
6311767320 | ||
|
|
2463d1b5bb | ||
|
|
9d41ae3cae | ||
|
|
2be8bf27bf | ||
|
|
2d052ffb1a | ||
|
|
88ab071ac7 | ||
|
|
bda72da679 | ||
|
|
95e5ef2d33 | ||
|
|
48a294e7c6 | ||
|
|
794fa63302 | ||
|
|
cdb8e851a8 | ||
|
|
f8ee3a8d15 | ||
|
|
76ab997922 | ||
|
|
97e7a130f1 | ||
|
|
2a96ad4af7 | ||
|
|
e1aee4a744 | ||
|
|
ecfe1524d4 | ||
|
|
42ea2dc986 | ||
|
|
230e2e7407 | ||
|
|
92639ba309 | ||
|
|
19b3225312 | ||
|
|
e56c20469d | ||
|
|
a28eceaf61 | ||
|
|
1925c6d33c | ||
|
|
fcac4002b1 | ||
|
|
ed3a2ae9fc | ||
|
|
4955d2135b | ||
|
|
9f1dacc1d4 | ||
|
|
f0765a6627 | ||
|
|
a31a9fdfbd | ||
|
|
fd2d0724a7 | ||
|
|
82d7389092 | ||
|
|
a53eb3cfde | ||
|
|
bd048d725c | ||
|
|
8e275613e1 | ||
|
|
fc869a34e0 | ||
|
|
48c84acb7c | ||
|
|
40d40a344e | ||
|
|
d31257ba76 | ||
|
|
f0a80338da | ||
|
|
6b5ca5b337 | ||
|
|
61f9d7812d | ||
|
|
d5eeafc554 | ||
|
|
2175433444 | ||
|
|
cfbb1a1519 | ||
|
|
1302ca6de4 | ||
|
|
239b520939 | ||
|
|
56d9dbee5b | ||
|
|
41decf1fa1 | ||
|
|
1d2cb5737d | ||
|
|
a2496b267a | ||
|
|
178544fe2d | ||
|
|
9e3b9c8f38 | ||
|
|
b439d8283f | ||
|
|
fb48bce38d | ||
|
|
b189fbe238 | ||
|
|
26c1c97442 | ||
|
|
ee8f5b6e1e | ||
|
|
6755515b1f | ||
|
|
074036c0b5 | ||
|
|
c7d0820eed | ||
|
|
97c0fdbf1d | ||
|
|
a962939db8 | ||
|
|
a9802710ef | ||
|
|
aaaa0b1ebf | ||
|
|
f34d10146a | ||
|
|
b875cbdda4 | ||
|
|
d80a3f7f48 | ||
|
|
259946e78f | ||
|
|
9c24adf77d | ||
|
|
4c47d4aba2 | ||
|
|
7f9061cfc5 | ||
|
|
085dad2107 | ||
|
|
055a7fffdb | ||
|
|
6cea6af59b | ||
|
|
6f0f8106e0 | ||
|
|
c9a0ce7985 | ||
|
|
b40533c553 | ||
|
|
e2fff23080 | ||
|
|
72482ee395 | ||
|
|
5366034556 | ||
|
|
484e2a2318 | ||
|
|
0873fba7df | ||
|
|
4aa6f864f0 | ||
|
|
183b2ba30c | ||
|
|
071f15347e | ||
|
|
71ed58e665 | ||
|
|
50c7e20ba6 | ||
|
|
876b801fa1 | ||
|
|
bd42b88b71 | ||
|
|
b2dfb3abe2 | ||
|
|
164f726222 | ||
|
|
24cdf5cf00 | ||
|
|
93cb9da558 | ||
|
|
66c6bfa0fb | ||
|
|
edd93a6ad4 | ||
|
|
ea1626a2ef | ||
|
|
1f3b7f21bb | ||
|
|
e6fe055cd5 | ||
|
|
1422b6fdbc | ||
|
|
cfb70eff8a | ||
|
|
dfe6085432 | ||
|
|
b8e8db0e36 | ||
|
|
fb2e41422b | ||
|
|
f3db8f2e45 | ||
|
|
6bc2c0adf1 | ||
|
|
df75e08d22 | ||
|
|
b2ccdad483 | ||
|
|
3d6eb7b4fa | ||
|
|
96cfb8a8ce | ||
|
|
4a4672c80a | ||
|
|
a0c1cd1019 | ||
|
|
ed20d1abbb | ||
|
|
0ebb9c01f8 | ||
|
|
dd3176f841 | ||
|
|
a910a97719 | ||
|
|
cdf8ab3a3c | ||
|
|
074e4ed5b7 | ||
|
|
9e43d186d7 | ||
|
|
8b61d40ff8 | ||
|
|
f9b3001eb3 | ||
|
|
f1ec44869d | ||
|
|
72341acb57 | ||
|
|
fa696e6c11 | ||
|
|
b30909942a | ||
|
|
7c64e1f11d | ||
|
|
d1c6988d0f | ||
|
|
efe0bd4bad | ||
|
|
7523481be0 | ||
|
|
23182106b9 | ||
|
|
515ffbcf0a | ||
|
|
8f52a1e2a2 | ||
|
|
bdd9045fc1 | ||
|
|
518616483b | ||
|
|
817f662cb7 | ||
|
|
01419cde15 | ||
|
|
118efe0833 | ||
|
|
46911004db | ||
|
|
b87190d135 | ||
|
|
39e22f5561 | ||
|
|
02dd37c87f | ||
|
|
7db7afad4a | ||
|
|
25582e2958 | ||
|
|
3c5609545b | ||
|
|
061d924d46 | ||
|
|
49af6777ee | ||
|
|
e9d9a95cb4 | ||
|
|
7e70e7d6cd | ||
|
|
ebb48c7d0f | ||
|
|
e0d464906e | ||
|
|
9189a6d433 | ||
|
|
b3f6bad6f8 | ||
|
|
105162aa89 | ||
|
|
51c4161f68 | ||
|
|
488d9352f3 | ||
|
|
56b800e4ff | ||
|
|
03864ca1a9 | ||
|
|
94c87f5645 | ||
|
|
dadf48ac25 | ||
|
|
a47bfcc5fd | ||
|
|
1798916bf9 | ||
|
|
5af1238e02 | ||
|
|
a62db61221 | ||
|
|
8104947aec | ||
|
|
d5f9fbf99d | ||
|
|
d3910bb931 | ||
|
|
7cac57bd79 | ||
|
|
07874ca210 | ||
|
|
0267597b20 | ||
|
|
1cc939f457 | ||
|
|
b12245bb94 | ||
|
|
006ec15000 | ||
|
|
4f4593e5f7 | ||
|
|
58ff71a863 | ||
|
|
7d8a31c55a | ||
|
|
29e6637399 | ||
|
|
d61fc41465 | ||
|
|
1cc692a3c9 | ||
|
|
a2a1bed3e0 | ||
|
|
557366a3ec | ||
|
|
80c8b4b4d4 | ||
|
|
9dd6bc2d6f | ||
|
|
9c1db92824 | ||
|
|
e3172c28b7 | ||
|
|
b0b3747760 | ||
|
|
e8af34995b | ||
|
|
9f17dcafbb | ||
|
|
347877cdad | ||
|
|
8f1541c338 | ||
|
|
89f3e8f980 | ||
|
|
e945f93032 | ||
|
|
4f9841d443 | ||
|
|
c73204a828 | ||
|
|
b2681d443d | ||
|
|
05a1d880c5 | ||
|
|
7b13ae13ad | ||
|
|
ecb330cc57 | ||
|
|
af5e866853 | ||
|
|
007b145c2e | ||
|
|
201943994b | ||
|
|
b17f3c08b7 | ||
|
|
c46c59e4a1 | ||
|
|
0bdb39797d | ||
|
|
71061ad861 | ||
|
|
f14875e679 | ||
|
|
e8a1f6a02f | ||
|
|
036035f51b | ||
|
|
104b6c2f5d | ||
|
|
7dffd7dcb9 | ||
|
|
63f1f0df21 | ||
|
|
dda955219a | ||
|
|
5d6e99dc8a | ||
|
|
b61a5e8f7b | ||
|
|
d9018ef317 | ||
|
|
9993b9bbf6 | ||
|
|
03fd9b222a | ||
|
|
3d7cfb1c63 | ||
|
|
ca6e45fb92 | ||
|
|
e9950652a6 | ||
|
|
cddc6571f7 | ||
|
|
708ba929f0 | ||
|
|
6e820d745c | ||
|
|
ae9e0e27ff | ||
|
|
3485c5a5dd | ||
|
|
62ac16b705 | ||
|
|
048ca0e64a | ||
|
|
d413de75d3 | ||
|
|
4f8d4f7a74 | ||
|
|
a0619abfc4 | ||
|
|
5e950b9766 | ||
|
|
1f02818692 | ||
|
|
c0a370ad47 | ||
|
|
a502420c5f | ||
|
|
b4aef1461c | ||
|
|
54b40c35f4 | ||
|
|
a33e053bc7 | ||
|
|
ae93661763 | ||
|
|
349bee7405 | ||
|
|
c286d05ad8 | ||
|
|
49b2c2f7a3 | ||
|
|
b469fcfee3 | ||
|
|
5e6fde594b | ||
|
|
5d598d9034 | ||
|
|
8181f2602a | ||
|
|
3e74697215 | ||
|
|
fac10debd5 | ||
|
|
74941f7243 | ||
|
|
621b2e322c | ||
|
|
948b67558a | ||
|
|
dcf48db2ac | ||
|
|
072d31e8df | ||
|
|
25240f445d | ||
|
|
279b473793 | ||
|
|
959e24f51b | ||
|
|
c720d53389 | ||
|
|
335d3f7ff1 | ||
|
|
16608d4950 | ||
|
|
7b6a150bd2 | ||
|
|
1f21d80dc0 | ||
|
|
76c8a23721 | ||
|
|
08933ad92f | ||
|
|
06d0fb5b86 | ||
|
|
05c3c8a80c | ||
|
|
41796774dc | ||
|
|
4594752470 | ||
|
|
d818b396c4 | ||
|
|
cf7b333662 | ||
|
|
7cc0a90acf | ||
|
|
f9eed2f2ab | ||
|
|
f8ff163aee | ||
|
|
38ad5bb394 | ||
|
|
b2fb415ab5 | ||
|
|
4c03676a3e | ||
|
|
efce977bd6 | ||
|
|
071974c74b | ||
|
|
7f202506b5 | ||
|
|
a9c9886210 | ||
|
|
e18b62da6e | ||
|
|
59c6dedd35 | ||
|
|
a673db222e | ||
|
|
1cb72a5bdd | ||
|
|
c1e45242a7 | ||
|
|
efe9a1a6e4 | ||
|
|
e91f0e7ee4 | ||
|
|
3716691366 | ||
|
|
675830045d | ||
|
|
9294f77163 | ||
|
|
864701adfb | ||
|
|
81f47a7fb6 | ||
|
|
a56ceca3c5 | ||
|
|
bc670d263d | ||
|
|
36068d7197 | ||
|
|
4ebe0d4f43 | ||
|
|
9f01078fe0 | ||
|
|
b07fc790e5 | ||
|
|
ab2bb11eee | ||
|
|
919367162b | ||
|
|
ec4d91b37f | ||
|
|
799aa8f90c | ||
|
|
cfbd1d68ee | ||
|
|
4cf8c4e81f | ||
|
|
87bde2c53f | ||
|
|
2aaf677605 | ||
|
|
fad7c4a39d | ||
|
|
fc464c0564 | ||
|
|
53c28359bb | ||
|
|
4737cc5ae8 | ||
|
|
97845bbaf5 | ||
|
|
8f516f7be7 | ||
|
|
5c164f89cc | ||
|
|
da28859398 | ||
|
|
25f8b103bf | ||
|
|
8b0513aece | ||
|
|
b95712aef3 | ||
|
|
917d9437b6 | ||
|
|
123388d059 | ||
|
|
226d66c22e | ||
|
|
d8f09b6039 | ||
|
|
fae4dcaae2 | ||
|
|
b957df648b | ||
|
|
a21f4800ab | ||
|
|
4abf2205c1 | ||
|
|
0c652eac63 | ||
|
|
3fef330707 | ||
|
|
c2abc4e2e4 | ||
|
|
d48e5a05a6 | ||
|
|
72471168d7 | ||
|
|
08a2f7dfcd | ||
|
|
ceb61318f0 | ||
|
|
11778a632a | ||
|
|
f3e11fd368 | ||
|
|
69fdd4b756 | ||
|
|
507a6e6525 | ||
|
|
82a9c6dbf7 | ||
|
|
21d66f719d | ||
|
|
c793c47d45 | ||
|
|
a81faf4ba4 | ||
|
|
e60d47163e | ||
|
|
e7215cec9e | ||
|
|
f7e6789e23 | ||
|
|
4af58aea4a | ||
|
|
4d379d6006 | ||
|
|
519ccb7ddd | ||
|
|
79ccab6869 | ||
|
|
ccac5226d5 | ||
|
|
674e585eff | ||
|
|
7e1b7f2725 | ||
|
|
256f2ba480 | ||
|
|
72f63e7e31 | ||
|
|
606f9d2ccf | ||
|
|
0261b7e9ab | ||
|
|
71abf32d82 | ||
|
|
f6030cc918 | ||
|
|
f7ba021799 | ||
|
|
f506fa86cc | ||
|
|
1a0130dd1a | ||
|
|
6f746e3aff | ||
|
|
36a3a0a0e1 | ||
|
|
323e1cd6eb | ||
|
|
06fb54c65c | ||
|
|
07d4a2cda9 | ||
|
|
53e753c3ef | ||
|
|
8d8cffca71 | ||
|
|
352a19b91c | ||
|
|
74972eaa37 | ||
|
|
5ee07ec34d | ||
|
|
61104b9cd3 | ||
|
|
032ecc4a3e | ||
|
|
7337cf6fa5 | ||
|
|
967852f84d | ||
|
|
17734e7a3d | ||
|
|
b8398ac1d1 | ||
|
|
0a3696ac56 | ||
|
|
8e0b77c232 | ||
|
|
88efc2da38 | ||
|
|
48f9398e72 | ||
|
|
b147bbef3d | ||
|
|
013e8f8f70 | ||
|
|
98907b33aa | ||
|
|
49003f4d9a | ||
|
|
46c869ca8a | ||
|
|
f92756c103 | ||
|
|
57c3fa04db | ||
|
|
30d8d34976 | ||
|
|
c49f968d82 | ||
|
|
894a75beb3 | ||
|
|
cb7e1cc03e | ||
|
|
9e1837e89c | ||
|
|
475f96d00a | ||
|
|
96854ca00c | ||
|
|
0bf6aab43b | ||
|
|
856aee6c18 | ||
|
|
0f2ed23b02 | ||
|
|
10b4d0b16b | ||
|
|
7f44b29fbc | ||
|
|
a66c6e5504 | ||
|
|
255d5a4550 | ||
|
|
6df2b92bc6 | ||
|
|
8c38c9e145 | ||
|
|
501b9777b5 | ||
|
|
8fc18458c2 | ||
|
|
457793b4d2 | ||
|
|
4bb00bc006 | ||
|
|
1a0515361e | ||
|
|
2df8df1a0d | ||
|
|
96a9a32079 | ||
|
|
5d6b475e09 | ||
|
|
cb3eca29d8 | ||
|
|
bdb62de868 | ||
|
|
b416e56b98 | ||
|
|
1728be9c36 | ||
|
|
ea85710c05 | ||
|
|
e1af67beb3 | ||
|
|
d9de601e8a | ||
|
|
3c568a7d42 | ||
|
|
5080cf65c7 | ||
|
|
eefca656c6 | ||
|
|
3a63f87807 | ||
|
|
d71628adfe | ||
|
|
585fc96bca | ||
|
|
28b1820bfa | ||
|
|
85e74014b1 | ||
|
|
cc12cecc2a | ||
|
|
197a7bcc43 | ||
|
|
613f397c33 | ||
|
|
a3bd0f2c0b | ||
|
|
bda297b90d | ||
|
|
8ddba831f0 | ||
|
|
5218702005 | ||
|
|
fbabd2f340 | ||
|
|
a38bc6b534 | ||
|
|
73aa36fc69 | ||
|
|
d627fca7d6 | ||
|
|
06325a7ce1 | ||
|
|
903b779ebe | ||
|
|
0e3d582d13 | ||
|
|
cd17f3d755 | ||
|
|
8543a228fd | ||
|
|
b97c8e7fda | ||
|
|
1346614a30 | ||
|
|
0eec40673f | ||
|
|
602678e2b9 | ||
|
|
d6393e39f7 | ||
|
|
b3f22866b5 | ||
|
|
51d2880392 | ||
|
|
ede7a37e37 | ||
|
|
8373303651 | ||
|
|
f3ccabe253 | ||
|
|
ba6bb56e81 | ||
|
|
73124f016d | ||
|
|
32ca2e4298 | ||
|
|
1cc7486b0a | ||
|
|
26b58442c5 | ||
|
|
20de17bef1 | ||
|
|
54e04be768 | ||
|
|
49b517f1ab | ||
|
|
fc71d2d1ca | ||
|
|
340b5b7248 | ||
|
|
cfd292ef18 | ||
|
|
f7ea17a9cf | ||
|
|
096ab34ae8 | ||
|
|
e72b35c7eb | ||
|
|
9141f21cf8 | ||
|
|
65d9efef94 | ||
|
|
c5b19db662 | ||
|
|
f6a50cc43a | ||
|
|
a13260b8c6 | ||
|
|
66c0200457 | ||
|
|
e244883165 | ||
|
|
92367c9020 | ||
|
|
e78ea60644 | ||
|
|
29f73eaaa1 | ||
|
|
22c004a892 | ||
|
|
ef0507cf1d | ||
|
|
9df9e33ce1 | ||
|
|
52a2caaa6d | ||
|
|
0b6aa9e857 | ||
|
|
3b078cfd6b | ||
|
|
67b746998f | ||
|
|
52f62f0c1d | ||
|
|
ca23b5ab33 | ||
|
|
5a14790ec2 | ||
|
|
67542eebfb | ||
|
|
88c62bc238 | ||
|
|
0c4ed91335 | ||
|
|
74dbb611ab | ||
|
|
07e72c7e72 | ||
|
|
2c0700c10e | ||
|
|
191cee25a4 | ||
|
|
1b4fad72ed | ||
|
|
3fce0dba48 | ||
|
|
706346338b | ||
|
|
aee846764b | ||
|
|
391b35ef1f | ||
|
|
9364841cf4 | ||
|
|
0d7b44fe51 | ||
|
|
47734cfca6 | ||
|
|
a272e53519 | ||
|
|
710fe1998b | ||
|
|
31c76c08b8 | ||
|
|
e8e2e8e315 | ||
|
|
5a1c6b9e7f | ||
|
|
1d98d8eecb | ||
|
|
7d5e609f7b | ||
|
|
4d2cb2d1dc | ||
|
|
fa2806e3aa | ||
|
|
761d9f45da | ||
|
|
07d9cfe5bc | ||
|
|
b9d7e0787c | ||
|
|
4ea6660402 | ||
|
|
8391596e2a | ||
|
|
0f1cfc129c | ||
|
|
3e33f9b363 | ||
|
|
a76cc4693f | ||
|
|
d75bb7b7cf | ||
|
|
6c87de7a97 | ||
|
|
0ba493d71d | ||
|
|
bd0f1f0b23 | ||
|
|
d45a96a919 | ||
|
|
55e02dde5e | ||
|
|
cb7814cbd6 | ||
|
|
2b1abc8aeb | ||
|
|
3376ce54cc | ||
|
|
d35b4d1ad6 | ||
|
|
7a2c45ddb5 | ||
|
|
d3648a7e89 | ||
|
|
c794bb6a26 | ||
|
|
3f8b2f7a30 | ||
|
|
2bc6d1bc9a | ||
|
|
ee53ddd097 | ||
|
|
1705817128 | ||
|
|
0f8936e9a9 | ||
|
|
e3792cde12 | ||
|
|
4792d83119 | ||
|
|
27888f503a | ||
|
|
8b0823f504 | ||
|
|
12476fc173 | ||
|
|
56cc0a92f6 | ||
|
|
88db57c64b | ||
|
|
cd1f465a81 | ||
|
|
a80b5ed961 | ||
|
|
7f54cb0de8 | ||
|
|
3549b216b0 | ||
|
|
3786c53cad | ||
|
|
178e0d18cd | ||
|
|
cbdcb6f1ce | ||
|
|
74cc5af5c9 | ||
|
|
392d90db57 | ||
|
|
c87081f673 | ||
|
|
f375432e7d | ||
|
|
3011645c44 | ||
|
|
322256cc5a | ||
|
|
02d017eb9e | ||
|
|
2f13bce20d | ||
|
|
e2bf90e340 | ||
|
|
9bc1247544 | ||
|
|
90a2ec9719 | ||
|
|
b61cfe8b6b | ||
|
|
28d57dff72 | ||
|
|
55270548c7 | ||
|
|
a45f9e7843 | ||
|
|
37cfcde476 | ||
|
|
9517f0eedf | ||
|
|
a9da0cdcc8 | ||
|
|
b3c537d034 | ||
|
|
2d4cf29da8 | ||
|
|
eea47aea55 | ||
|
|
2648a0b57e | ||
|
|
46dfe4650e | ||
|
|
7eca11d51b | ||
|
|
43022a9838 | ||
|
|
b873ec2095 | ||
|
|
18f8718de2 | ||
|
|
c6c0801d14 | ||
|
|
196d27b7c5 | ||
|
|
daed961a99 | ||
|
|
8387e03254 | ||
|
|
b6d43a069f | ||
|
|
558eea94e2 | ||
|
|
f5f99efff6 | ||
|
|
cc95fa92e7 | ||
|
|
9eba3287b2 | ||
|
|
46845dd4b9 | ||
|
|
c3be2cdfe5 | ||
|
|
443cf1829e | ||
|
|
ae833b245e | ||
|
|
88338877b0 | ||
|
|
0d74a4aecc | ||
|
|
1cf0496cd1 | ||
|
|
050b026166 | ||
|
|
8d95319e39 | ||
|
|
fe12b0a665 | ||
|
|
93dd2e06d8 | ||
|
|
05f29a264e | ||
|
|
26dd8ed13a | ||
|
|
72c58059bd | ||
|
|
7e596d47a6 | ||
|
|
c38a8c0475 | ||
|
|
15adbf489e | ||
|
|
98b863be6f | ||
|
|
ecd40523d4 | ||
|
|
7f6de6e64e | ||
|
|
002163fbdc | ||
|
|
da9ea504fb | ||
|
|
bb171f6e23 | ||
|
|
b860c2eed0 | ||
|
|
fdf81d1b39 | ||
|
|
40bf6d3010 | ||
|
|
2d63d36f51 | ||
|
|
ed976e90dc | ||
|
|
6f4994b5da | ||
|
|
a2a923809e | ||
|
|
8d06ccace9 | ||
|
|
99479e722a | ||
|
|
70890cdc19 | ||
|
|
0eebc544a6 | ||
|
|
12280e5769 | ||
|
|
4ec2c1b943 | ||
|
|
d6edb93403 | ||
|
|
3236a05ae9 | ||
|
|
5576ae7305 | ||
|
|
d5aadf6926 | ||
|
|
2eb469b228 | ||
|
|
088c6faae1 | ||
|
|
04f7d22e3f | ||
|
|
950274f6be | ||
|
|
c6596fff1a | ||
|
|
7cbbc57514 | ||
|
|
8041a4a4fc | ||
|
|
1fa247aa35 | ||
|
|
7de49dcfb8 | ||
|
|
b21e307640 | ||
|
|
aae7eedd49 | ||
|
|
bce60310c5 | ||
|
|
d17cb4ce96 | ||
|
|
4b25a03b1d | ||
|
|
682433efe4 | ||
|
|
a6f28d67eb | ||
|
|
c663aa2799 | ||
|
|
2c02b816b5 | ||
|
|
d14b87729a | ||
|
|
70b41ab8a8 | ||
|
|
d185b548f7 | ||
|
|
4b5dcec08b | ||
|
|
13a7a875a4 | ||
|
|
8743bf4b93 | ||
|
|
d8792e9e27 | ||
|
|
82a0cd0336 | ||
|
|
60ae5b8965 | ||
|
|
4d4b54ec36 | ||
|
|
53f6910a34 | ||
|
|
826c3a8f8f | ||
|
|
727ddd3198 | ||
|
|
7b535434ae | ||
|
|
da8ed53c60 | ||
|
|
40e9d6f392 | ||
|
|
d189f55de1 | ||
|
|
893f4a0388 | ||
|
|
a28547c581 | ||
|
|
a8079e0d35 | ||
|
|
60a210a45f | ||
|
|
170aa01946 | ||
|
|
f4c8e5d493 | ||
|
|
b3a0a402d7 | ||
|
|
b6c70d1530 | ||
|
|
8fbc7b9f5c | ||
|
|
3c2e73b5f5 | ||
|
|
1a221eefe3 | ||
|
|
5912428c00 | ||
|
|
f01236cc96 | ||
|
|
ad1f5a297e | ||
|
|
96697e11fd | ||
|
|
25e8b9b578 | ||
|
|
49603e29bd | ||
|
|
6a18489c15 | ||
|
|
cb52fca2a4 | ||
|
|
00964e6bbf | ||
|
|
ea1b91af2a | ||
|
|
8894e5482f | ||
|
|
e17e3474ca | ||
|
|
6d09bd4987 | ||
|
|
84f3907140 | ||
|
|
d704e2eb55 | ||
|
|
2e4c6f4284 | ||
|
|
61c77e0047 | ||
|
|
cf1e6fc283 | ||
|
|
b361e46fb7 | ||
|
|
7bb06e7fdc | ||
|
|
9f83b40be4 | ||
|
|
1edd3441bc | ||
|
|
079a4a2cf6 | ||
|
|
049a759cda | ||
|
|
a6ff38159f | ||
|
|
056f040317 | ||
|
|
c161206832 | ||
|
|
e9a0c293f8 | ||
|
|
24de62f5f4 | ||
|
|
b7b278f296 | ||
|
|
712941038b | ||
|
|
4316fa8953 | ||
|
|
d14763d52c | ||
|
|
79e1f34890 | ||
|
|
3cb8e066b3 | ||
|
|
5e6a56e193 | ||
|
|
478ba2048a | ||
|
|
8426294a0f | ||
|
|
178954c8b2 | ||
|
|
6ce2b65d89 | ||
|
|
fb45fee426 | ||
|
|
ffca49f469 | ||
|
|
f32c7a7253 | ||
|
|
a64ccdba78 | ||
|
|
5f6bae6fa9 | ||
|
|
fd503b4071 | ||
|
|
9ece357e39 | ||
|
|
d53c8362a2 | ||
|
|
8f3ca8c28d | ||
|
|
7f5675ae3c | ||
|
|
7b9f4be98c | ||
|
|
ca352ca341 | ||
|
|
a22ccbdda5 | ||
|
|
e6b50248de | ||
|
|
ee3f8a9261 | ||
|
|
922d7222cd | ||
|
|
4a8900105b | ||
|
|
65a4bb7778 | ||
|
|
3944551c06 | ||
|
|
66d7ffbb17 | ||
|
|
c4d879a0ad | ||
|
|
b97f77c740 | ||
|
|
27ad9b0599 | ||
|
|
234b8ab31c | ||
|
|
519a608316 | ||
|
|
d4a13c8a82 | ||
|
|
ccb57411a2 | ||
|
|
486bebe6d2 | ||
|
|
5b3129bf01 | ||
|
|
23c742c4c6 | ||
|
|
90d3bbd79e | ||
|
|
400a06d2ac | ||
|
|
594d2f620c | ||
|
|
1a6ec578de | ||
|
|
e009604595 | ||
|
|
8b23c623d1 | ||
|
|
a3c4e72902 | ||
|
|
7e54412fc3 | ||
|
|
564970a324 | ||
|
|
1ecd32027e | ||
|
|
ceb5727337 | ||
|
|
17c7552f7f | ||
|
|
8fbcad8856 | ||
|
|
a61fd454b4 | ||
|
|
c0337afbaa | ||
|
|
acb9e78a36 | ||
|
|
431ff04644 | ||
|
|
201fb0a136 | ||
|
|
90671729ea | ||
|
|
8596175f8e | ||
|
|
e9fdec6bb0 | ||
|
|
026b6aca07 | ||
|
|
fafe3c0c55 | ||
|
|
f2b327c811 | ||
|
|
7fccbc2aa2 | ||
|
|
7c40f5988b | ||
|
|
b19e4043cd | ||
|
|
db75aa1cab | ||
|
|
f5718b4062 | ||
|
|
d25f17782b | ||
|
|
e3626a094d | ||
|
|
fc7b17fe40 | ||
|
|
87e13b3677 | ||
|
|
a540e42460 | ||
|
|
c4e24fb0a3 | ||
|
|
31fb55635e | ||
|
|
3dcff0b682 | ||
|
|
81f48d9c92 | ||
|
|
6331b0d587 | ||
|
|
57cf3b94e0 | ||
|
|
b683eac996 | ||
|
|
ccdcb1d0f6 | ||
|
|
4f5f02f030 | ||
|
|
0629ce51af | ||
|
|
46f1fcc269 | ||
|
|
b49b0290f8 | ||
|
|
7ca351f7cd | ||
|
|
850b124da3 | ||
|
|
49a2d3cab3 | ||
|
|
038eda1562 | ||
|
|
b91c8e34c2 | ||
|
|
0a631a7c93 | ||
|
|
4705c2595a | ||
|
|
0ff6809d63 | ||
|
|
a375feabfc | ||
|
|
5b9fd139a3 | ||
|
|
fd92d93289 | ||
|
|
840637c0d0 | ||
|
|
f41f5386cc | ||
|
|
f4a7d8ea92 | ||
|
|
26c9160c75 | ||
|
|
4c1955da75 | ||
|
|
66e6272571 | ||
|
|
e9d5e705ed | ||
|
|
16fdb28141 | ||
|
|
e289cf29fe | ||
|
|
1cd74cc26a | ||
|
|
27112e35b3 | ||
|
|
b2a8578f43 | ||
|
|
0e0a8b039d | ||
|
|
cbd201c43b | ||
|
|
a6d734bacf | ||
|
|
8dc86e0482 | ||
|
|
d0226611d7 | ||
|
|
2b21c3cd09 | ||
|
|
b1bdd9b8a5 | ||
|
|
bb50510ecb | ||
|
|
aa185c8bd2 | ||
|
|
99e3b234c9 | ||
|
|
5168d8d08d | ||
|
|
230a8810ef | ||
|
|
e8e8c1abcc | ||
|
|
0354d6dc3e | ||
|
|
47ad388f7d | ||
|
|
2d57483805 | ||
|
|
363dbd3a7f | ||
|
|
5b5863c899 | ||
|
|
4c1ae8c3cc | ||
|
|
29ed211519 | ||
|
|
9f965c4e56 | ||
|
|
0148868129 | ||
|
|
d46863b5b5 | ||
|
|
1917aa13d5 | ||
|
|
2994131048 | ||
|
|
f0d6938127 | ||
|
|
0203630d6a | ||
|
|
89c5c2dd83 | ||
|
|
ce1954e7d3 | ||
|
|
947a82eac5 | ||
|
|
9dc01f6057 | ||
|
|
37c5ce541b | ||
|
|
726eb06714 | ||
|
|
df505e0e17 | ||
|
|
06fffac835 | ||
|
|
264a423444 | ||
|
|
6ae9692358 | ||
|
|
7270564b10 | ||
|
|
a485a29868 | ||
|
|
ec04c3221f | ||
|
|
761982474c | ||
|
|
d13b0404fb | ||
|
|
6966376f91 | ||
|
|
2720f5c0bb | ||
|
|
881f039e44 | ||
|
|
81c7a72b9c | ||
|
|
c0391e3fc1 | ||
|
|
7e542750f6 | ||
|
|
7cbf638822 | ||
|
|
4cdb461c22 | ||
|
|
ba57f19ee7 | ||
|
|
9ba2693698 | ||
|
|
3439b7aee5 | ||
|
|
63b23fbe76 | ||
|
|
63fff2398e | ||
|
|
db8796df99 | ||
|
|
4095481411 | ||
|
|
8e30defa0e | ||
|
|
06ee6d6359 | ||
|
|
a988dedfbf | ||
|
|
f90c6fb27d | ||
|
|
5292d6ef90 | ||
|
|
e760af7216 | ||
|
|
e4889d82f2 | ||
|
|
9d170ecc30 | ||
|
|
cf01011504 | ||
|
|
b1291d3c43 | ||
|
|
82546eed06 | ||
|
|
bf667e2aa6 | ||
|
|
5b6f208f53 | ||
|
|
210d56447c | ||
|
|
c093261369 | ||
|
|
ee4f87d12d | ||
|
|
74b0a5b081 | ||
|
|
f51774c077 | ||
|
|
bd9f7b8b9f | ||
|
|
dc55bd63f5 | ||
|
|
07ce947f78 | ||
|
|
0f6cc70f66 | ||
|
|
6d014a01bc | ||
|
|
de5e97ac3a | ||
|
|
40e866aadd | ||
|
|
36ce7593a9 | ||
|
|
a2a28af41d | ||
|
|
203a30a236 | ||
|
|
b7d418b5b7 | ||
|
|
1625f7ca76 | ||
|
|
8a67b905fc | ||
|
|
9ee76b5328 | ||
|
|
df9dd7f435 | ||
|
|
9d0d318d66 | ||
|
|
ee1723a76b | ||
|
|
c715422814 | ||
|
|
72e7941230 | ||
|
|
ac475ca456 | ||
|
|
ee5355668d | ||
|
|
1b30f0ad31 | ||
|
|
348f362b30 | ||
|
|
6bef12b91b | ||
|
|
5b4113be4d | ||
|
|
a82d3fe57c | ||
|
|
4d551366ed | ||
|
|
441cb6ddcb | ||
|
|
f14efa2612 | ||
|
|
f4d7c07f57 | ||
|
|
66b2f1f55d | ||
|
|
b9b2c10ca0 | ||
|
|
0d5f871da7 | ||
|
|
1688a7ba15 | ||
|
|
3506e1c738 | ||
|
|
ae0c4aea12 | ||
|
|
a52b672e9b | ||
|
|
c4307aa821 | ||
|
|
a2c32009f5 | ||
|
|
e27185d424 | ||
|
|
0714480e01 | ||
|
|
504ee766f8 | ||
|
|
7358fd0c23 | ||
|
|
25be7094a2 | ||
|
|
627a1d7d5a | ||
|
|
63b84ee69d | ||
|
|
5eb76176ab | ||
|
|
6115ecf673 | ||
|
|
d1a112d3a3 | ||
|
|
7d67e6a007 | ||
|
|
b824ee625e | ||
|
|
961ac20213 | ||
|
|
f213b6f53f | ||
|
|
631600ab3f | ||
|
|
d95fce2efb | ||
|
|
1c6c009f14 | ||
|
|
f555f6423a | ||
|
|
cd374f2d98 | ||
|
|
c62f31c387 | ||
|
|
87ccad6ec7 | ||
|
|
1600f7cdab | ||
|
|
dc3256566b | ||
|
|
b0858429fb | ||
|
|
2f3e2a5ae8 | ||
|
|
f280ab88ec | ||
|
|
5b1b75cbbe | ||
|
|
b5e709f5e5 | ||
|
|
65bd2ff35f | ||
|
|
4468657030 | ||
|
|
4ad95a65cf | ||
|
|
31f6c19e87 | ||
|
|
612d1d1646 | ||
|
|
eddf3ecdeb | ||
|
|
bf8f8d9382 | ||
|
|
d5091bf659 | ||
|
|
fd003eff8b | ||
|
|
4d1dfebacd |
30
.cursor/rules/01-project-overview.mdc
Normal file
30
.cursor/rules/01-project-overview.mdc
Normal file
@@ -0,0 +1,30 @@
|
||||
---
|
||||
description:
|
||||
globs:
|
||||
alwaysApply: false
|
||||
---
|
||||
# Lilishop Project Overview
|
||||
|
||||
This is a comprehensive B2B2C e-commerce system built with Spring Boot (backend) and Vue/uniapp (frontend). The project supports multi-tenant merchant access and distributed deployment.
|
||||
|
||||
## Key Project Components
|
||||
|
||||
### Backend APIs
|
||||
- [buyer-api/](mdc:buyer-api) - Buyer-facing APIs for shopping functionality
|
||||
- [seller-api/](mdc:seller-api) - Merchant-facing APIs for store management
|
||||
- [manager-api/](mdc:manager-api) - Platform admin APIs
|
||||
- [common-api/](mdc:common-api) - Shared API components
|
||||
- [im-api/](mdc:im-api) - Instant messaging APIs
|
||||
|
||||
### Core Components
|
||||
- [framework/](mdc:framework) - Core framework and shared utilities
|
||||
- [consumer/](mdc:consumer) - Message queue consumers
|
||||
- [config/](mdc:config) - System configuration files
|
||||
|
||||
### Documentation
|
||||
- [docs/](mdc:docs) - Project documentation
|
||||
- [README.md](mdc:README.md) - Project overview and setup instructions
|
||||
|
||||
### Build & Deployment
|
||||
- [pom.xml](mdc:pom.xml) - Maven project configuration
|
||||
- [deploy-api.yml](mdc:deploy-api.yml) - Deployment configuration
|
||||
38
.cursor/rules/02-technical-architecture.mdc
Normal file
38
.cursor/rules/02-technical-architecture.mdc
Normal file
@@ -0,0 +1,38 @@
|
||||
---
|
||||
description:
|
||||
globs:
|
||||
alwaysApply: false
|
||||
---
|
||||
# Technical Architecture
|
||||
|
||||
## Backend Stack
|
||||
- Spring Boot - Core framework
|
||||
- Spring MVC - Web framework
|
||||
- Mybatis-Plus - ORM framework
|
||||
- Spring Security - Security framework
|
||||
- JWT - Authentication
|
||||
- RocketMQ - Message queue
|
||||
- Redis & MongoDB - Caching
|
||||
- Elasticsearch - Search engine
|
||||
- MySQL - Primary database
|
||||
- Sharding - Database sharding
|
||||
- XXL-Job - Distributed scheduling
|
||||
|
||||
## Frontend Stack
|
||||
### Admin & Seller Portals ([admin/](mdc:admin))
|
||||
- Vue.js - Frontend framework
|
||||
- iView - UI components
|
||||
- Vuex - State management
|
||||
- Vue Router - Routing
|
||||
- Axios - HTTP client
|
||||
|
||||
### Mobile Applications
|
||||
- Uni-app - Cross-platform framework
|
||||
- uViewui - UI components
|
||||
- SCSS - Styling
|
||||
|
||||
## Infrastructure
|
||||
- Nginx - Load balancing & reverse proxy
|
||||
- Aliyun OSS - Object storage
|
||||
- Docker - Containerization
|
||||
- Docker Compose - Container orchestration
|
||||
43
.cursor/rules/03-development-guidelines.mdc
Normal file
43
.cursor/rules/03-development-guidelines.mdc
Normal file
@@ -0,0 +1,43 @@
|
||||
---
|
||||
description:
|
||||
globs:
|
||||
alwaysApply: false
|
||||
---
|
||||
# Development Guidelines
|
||||
|
||||
## Project Setup
|
||||
1. Ensure you have the following prerequisites:
|
||||
- JDK 1.8+
|
||||
- Maven 3.x
|
||||
- MySQL 5.7+
|
||||
- Redis
|
||||
- RocketMQ
|
||||
- Elasticsearch
|
||||
- Node.js 12+
|
||||
|
||||
## Database Setup
|
||||
- Initial database scripts can be found in [DB/](mdc:DB)
|
||||
- For Docker deployment, refer to docker-compose configuration
|
||||
|
||||
## API Development Guidelines
|
||||
1. All new APIs should be placed in appropriate modules:
|
||||
- Customer-facing APIs in [buyer-api/](mdc:buyer-api)
|
||||
- Merchant APIs in [seller-api/](mdc:seller-api)
|
||||
- Admin APIs in [manager-api/](mdc:manager-api)
|
||||
- Shared components in [common-api/](mdc:common-api)
|
||||
|
||||
2. Follow RESTful API conventions:
|
||||
- Use appropriate HTTP methods (GET, POST, PUT, DELETE)
|
||||
- Use consistent URL patterns
|
||||
- Implement proper error handling
|
||||
|
||||
## Security Guidelines
|
||||
1. All sensitive operations must be authenticated
|
||||
2. Use Spring Security for access control
|
||||
3. Store sensitive configuration in environment variables
|
||||
4. Never commit sensitive credentials to version control
|
||||
|
||||
## Testing
|
||||
1. Write unit tests for critical business logic
|
||||
2. Ensure API endpoints are properly documented
|
||||
3. Test both success and error scenarios
|
||||
37
.cursor/rules/04-deployment-guide.mdc
Normal file
37
.cursor/rules/04-deployment-guide.mdc
Normal file
@@ -0,0 +1,37 @@
|
||||
---
|
||||
description:
|
||||
globs:
|
||||
alwaysApply: false
|
||||
---
|
||||
# Deployment Guide
|
||||
|
||||
## Local Development Setup
|
||||
1. Clone the repository
|
||||
2. Import as Maven project
|
||||
3. Configure environment variables in [config/](mdc:config)
|
||||
4. Start required services (MySQL, Redis, RocketMQ, Elasticsearch)
|
||||
5. Run individual API modules
|
||||
|
||||
## Docker Deployment
|
||||
- Use [deploy-api.yml](mdc:deploy-api.yml) for container configuration
|
||||
- Execute [docker-image.sh](mdc:docker-image.sh) to build images
|
||||
|
||||
## Production Deployment
|
||||
1. Configure load balancer (Nginx recommended)
|
||||
2. Set up database replication/clustering
|
||||
3. Configure message queue clusters
|
||||
4. Set up monitoring and logging
|
||||
5. Configure CDN for static assets
|
||||
|
||||
## Configuration Files
|
||||
- Database: [DB/](mdc:DB)
|
||||
- API deployment: [deploy-api.yml](mdc:deploy-api.yml)
|
||||
- Docker scripts: [docker-image.sh](mdc:docker-image.sh)
|
||||
|
||||
## Deployment Checklist
|
||||
1. Database migration and backup
|
||||
2. Environment variable configuration
|
||||
3. Service dependencies verification
|
||||
4. SSL certificate setup
|
||||
5. Monitoring and alerting setup
|
||||
6. Backup and recovery procedures
|
||||
14
DB/index.sql
Normal file
14
DB/index.sql
Normal file
@@ -0,0 +1,14 @@
|
||||
-- 针对WHERE条件、排序和分组的组合索引
|
||||
CREATE INDEX idx_order_delete_flag_create_time_id_sn ON li_order (delete_flag, create_time DESC, id DESC, sn);
|
||||
|
||||
-- 针对WHERE条件和连接条件的组合索引
|
||||
CREATE INDEX idx_order_status_delete_flag_sn ON li_order (order_status, delete_flag, sn);
|
||||
|
||||
-- 针对连接条件的索引
|
||||
CREATE INDEX idx_order_item_order_sn ON li_order_item (order_sn);
|
||||
|
||||
-- 针对过滤条件、排序字段的组合索引
|
||||
CREATE INDEX idx_li_member_disabled_create_time ON li_member (disabled, create_time DESC);
|
||||
|
||||
-- 针对过滤条件、排序字段的组合索引
|
||||
CREATE INDEX idx_li_goods_delete_flag_create_time ON li_goods (delete_flag, create_time DESC);
|
||||
@@ -7,6 +7,7 @@
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : lilishop
|
||||
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80023
|
||||
File Encoding : 65001
|
||||
|
||||
@@ -6,7 +6,7 @@ ALTER TABLE li_distribution ADD settlement_bank_branch_name varchar ( 200 );
|
||||
/** 文章分类添加默认值**/
|
||||
ALTER TABLE li_article_category alter column sort set default 0;
|
||||
/** 添加分销提现菜单**/
|
||||
INSERT INTO `lilishop`.`li_menu`(`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1410862675914764290, 'admin', '2021-07-02 15:27:29', b'0', 'admin', '2021-07-02 15:27:45', 'null', 'distribution/distributionCash', '', 2, 'distributionCash', '1374173575405109248', 'distributionCash', 5.00, '分销提现', 'null');
|
||||
INSERT INTO `rxshop`.`li_menu`(`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1410862675914764290, 'admin', '2021-07-02 15:27:29', b'0', 'admin', '2021-07-02 15:27:45', 'null', 'distribution/distributionCash', '', 2, 'distributionCash', '1374173575405109248', 'distributionCash', 5.00, '分销提现', 'null');
|
||||
|
||||
/** 促销商品添加商品类型**/
|
||||
ALTER TABLE li_promotion_goods ADD goods_type varchar (200);
|
||||
@@ -16,7 +16,7 @@ update li_member_points_history set point_type = 'INCREASE' where point_type=1;
|
||||
update li_member_points_history set point_type = 'REDUCE' where point_type=0;
|
||||
|
||||
/** 添加分词管理菜单*/
|
||||
INSERT INTO `lilishop`.`li_menu` (`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1349247640584085511, 'admin', '2021-01-13 14:51:20', b'0', 'admin', '2021-02-25 09:02:59', 'null', 'customWords/index', 'ios-american-football', 2, 'customWords', '1349237129847005184', 'customWords', 8.00, '分词管理', 'null');
|
||||
INSERT INTO `rxshop`.`li_menu` (`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1349247640584085511, 'admin', '2021-01-13 14:51:20', b'0', 'admin', '2021-02-25 09:02:59', 'null', 'customWords/index', 'ios-american-football', 2, 'customWords', '1349237129847005184', 'customWords', 8.00, '分词管理', 'null');
|
||||
|
||||
/** 修改会员评价店铺图片字段类型 **/
|
||||
alter table li_member_evaluation modify column reply_image text;
|
||||
@@ -25,4 +25,4 @@ alter table li_member_evaluation modify column reply_image text;
|
||||
alter table li_after_sale modify column after_sale_image text;
|
||||
|
||||
/** 提现申请审核sql **/
|
||||
INSERT INTO `lilishop`.`li_menu`(`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1367042804944994305, 'admin', '2021-03-03 09:22:58', b'0', NULL, NULL, NULL, 'member/advance/withdrawApply', 'ios-alert', 2, 'withdrawApply', '1367042490443497472', 'withdrawApply', 1.00, '提现申请', NULL);
|
||||
INSERT INTO `rxshop`.`li_menu`(`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `front_component`) VALUES (1367042804944994305, 'admin', '2021-03-03 09:22:58', b'0', NULL, NULL, NULL, 'member/advance/withdrawApply', 'ios-alert', 2, 'withdrawApply', '1367042490443497472', 'withdrawApply', 1.00, '提现申请', NULL);
|
||||
|
||||
@@ -1,2 +1,64 @@
|
||||
/** 新增已退货数量 **/
|
||||
ALTER TABLE li_order_item ADD return_goods_number int DEFAULT 0 COMMENT '退货数量 ';
|
||||
ALTER TABLE li_order_item ADD return_goods_number int DEFAULT 0 COMMENT '退货数量 ';
|
||||
|
||||
|
||||
-- 促销重构sql
|
||||
ALTER TABLE li_coupon DROP COLUMN promotion_status;
|
||||
|
||||
ALTER TABLE li_coupon_activity DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_coupon_activity ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_coupon_activity ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_full_discount DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_full_discount ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_full_discount ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_kanjia_activity_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL;
|
||||
|
||||
ALTER TABLE li_pintuan DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_pintuan ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_pintuan ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_points_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_points_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_points_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_points_goods ADD `original_price` double(10,2) DEFAULT NULL COMMENT '原价';
|
||||
ALTER TABLE li_points_goods ADD `thumbnail` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '缩略图';
|
||||
ALTER TABLE li_points_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '商品编号';
|
||||
ALTER TABLE li_points_goods ADD `goods_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '货品名称';
|
||||
|
||||
ALTER TABLE li_promotion_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_promotion_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_promotion_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_promotion_goods ADD `original_price` double(10,2) DEFAULT NULL COMMENT '原价';
|
||||
ALTER TABLE li_promotion_goods ADD `points` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '兑换积分';
|
||||
ALTER TABLE li_promotion_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '商品编号';
|
||||
|
||||
ALTER TABLE li_seckill DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_seckill ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_seckill ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_coupon TO coupon_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_free_freight TO free_freight_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_full_minus TO full_minus_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_full_rate TO full_rate_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_gift TO gift_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_point TO point_flag;
|
||||
|
||||
ALTER TABLE li_member_coupon RENAME COLUMN is_platform TO platform_flag;
|
||||
|
||||
ALTER TABLE li_goods RENAME COLUMN is_auth TO auth_flag;
|
||||
|
||||
ALTER TABLE li_goods_sku RENAME COLUMN is_promotion TO promotion_flag;
|
||||
ALTER TABLE li_goods_sku RENAME COLUMN is_auth TO auth_flag;
|
||||
|
||||
|
||||
-- 增加会员表索引
|
||||
ALTER TABLE li_member ADD INDEX query_mobile (`mobile`) COMMENT 'query_member';
|
||||
-- 会员签到唯一索引 惠券查询索引
|
||||
ALTER TABLE li_member_sign ADD INDEX query_create_time (`create_time`) COMMENT 'query_create_time';
|
||||
ALTER TABLE li_member_sign ADD INDEX query_member_id (`member_id`) COMMENT 'query_member_id';
|
||||
ALTER TABLE li_member_sign add unique uk_member_day (member_id, create_time) COMMENT 'uk_member_day';
|
||||
@@ -1,64 +0,0 @@
|
||||
/** 新增已退货数量 **/
|
||||
ALTER TABLE li_order_item ADD return_goods_number int DEFAULT 0 COMMENT '退货数量 ';
|
||||
|
||||
|
||||
-- 促销重构sql
|
||||
ALTER TABLE li_coupon DROP COLUMN promotion_status;
|
||||
|
||||
ALTER TABLE li_coupon_activity DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_coupon_activity ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_coupon_activity ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_full_discount DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_full_discount ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_full_discount ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_kanjia_activity_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_kanjia_activity_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL;
|
||||
|
||||
ALTER TABLE li_pintuan DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_pintuan ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_pintuan ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_points_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_points_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_points_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_points_goods ADD `original_price` double(10,2) DEFAULT NULL COMMENT '原价';
|
||||
ALTER TABLE li_points_goods ADD `thumbnail` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '缩略图';
|
||||
ALTER TABLE li_points_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '商品编号';
|
||||
ALTER TABLE li_points_goods ADD `goods_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '货品名称';
|
||||
|
||||
ALTER TABLE li_promotion_goods DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_promotion_goods ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_promotion_goods ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
ALTER TABLE li_promotion_goods ADD `original_price` double(10,2) DEFAULT NULL COMMENT '原价';
|
||||
ALTER TABLE li_promotion_goods ADD `points` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '兑换积分';
|
||||
ALTER TABLE li_promotion_goods ADD `goods_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT NULL COMMENT '商品编号';
|
||||
|
||||
ALTER TABLE li_seckill DROP COLUMN promotion_status;
|
||||
ALTER TABLE li_seckill ADD `scope_id` mediumtext CHARACTER SET utf8mb4 COLLATE utf8mb4_bin COMMENT '范围关联的ID';
|
||||
ALTER TABLE li_seckill ADD `scope_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin DEFAULT 'PORTION_GOODS' COMMENT '关联范围类型';
|
||||
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_coupon TO coupon_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_free_freight TO free_freight_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_full_minus TO full_minus_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_full_rate TO full_rate_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_gift TO gift_flag;
|
||||
ALTER TABLE li_full_discount RENAME COLUMN is_point TO point_flag;
|
||||
|
||||
ALTER TABLE li_member_coupon RENAME COLUMN is_platform TO platform_flag;
|
||||
|
||||
ALTER TABLE li_goods RENAME COLUMN is_auth TO auth_flag;
|
||||
|
||||
ALTER TABLE li_goods_sku RENAME COLUMN is_promotion TO promotion_flag;
|
||||
ALTER TABLE li_goods_sku RENAME COLUMN is_auth TO auth_flag;
|
||||
|
||||
|
||||
-- 增加会员表索引
|
||||
ALTER TABLE li_member ADD INDEX query_mobile (`mobile`) COMMENT 'query_member';
|
||||
-- 会员签到唯一索引 惠券查询索引
|
||||
ALTER TABLE li_member_sign ADD INDEX query_create_time (`create_time`) COMMENT 'query_create_time';
|
||||
ALTER TABLE li_member_sign ADD INDEX query_member_id (`member_id`) COMMENT 'query_member_id';
|
||||
ALTER TABLE li_member_sign add unique uk_member_day (member_id, create_time) COMMENT 'uk_member_day';
|
||||
521
DB/version4.2.4to4.2.5.sql
Normal file
521
DB/version4.2.4to4.2.5.sql
Normal file
@@ -0,0 +1,521 @@
|
||||
/**增加店铺发货信息**/
|
||||
ALTER TABLE li_store_detail ADD `sales_consignor_address_id` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '发货地址id';
|
||||
ALTER TABLE li_store_detail ADD `sales_consignor_address_path` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '发货地址名称';
|
||||
ALTER TABLE li_store_detail ADD `sales_consignor_detail` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '发货详细地址';
|
||||
ALTER TABLE li_store_detail ADD `sales_consignor_mobile` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '发货人手机';
|
||||
ALTER TABLE li_store_detail ADD `sales_consignor_name` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '发货人姓名';
|
||||
|
||||
/**增加电子面单店铺信息**/
|
||||
ALTER TABLE `li_store_logistics` ADD `customer_name` varchar(255) DEFAULT NULL COMMENT '客户代码';
|
||||
ALTER TABLE `li_store_logistics` ADD `customer_pwd` varchar(255) DEFAULT NULL COMMENT '客户密码';
|
||||
ALTER TABLE `li_store_logistics` ADD `month_code` varchar(255) DEFAULT NULL COMMENT '月结号/密钥';
|
||||
ALTER TABLE `li_store_logistics` ADD `send_site` varchar(255) DEFAULT NULL COMMENT '归属网点';
|
||||
ALTER TABLE `li_store_logistics` ADD `send_staff` varchar(255) DEFAULT NULL COMMENT '收件快递员';
|
||||
ALTER TABLE `li_store_logistics` ADD `face_sheet_flag` bit(1) DEFAULT NULL COMMENT '是否使用电子面单';
|
||||
ALTER TABLE `li_store_logistics` ADD `pay_type` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '支付方式';
|
||||
ALTER TABLE `li_store_logistics` ADD `exp_type` varchar(255) COLLATE utf8mb4_bin DEFAULT NULL COMMENT '快递类型';
|
||||
|
||||
/** 店铺--默认页面是否开启**/
|
||||
ALTER TABLE li_store ADD page_show bit(1) DEFAULT NULL COMMENT '默认页面是否开启';
|
||||
|
||||
/** 创建店员表 **/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:30:20
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_clerk
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_clerk`;
|
||||
CREATE TABLE `li_clerk` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime(6) NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`clerk_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店员名称',
|
||||
`member_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '会员id',
|
||||
`store_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店铺id',
|
||||
`department_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '部门id',
|
||||
`role_ids` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '角色',
|
||||
`shopkeeper` bit(1) NULL DEFAULT NULL COMMENT '是否是店主',
|
||||
`is_super` bit(1) NULL DEFAULT NULL COMMENT '是否是超级管理员 超级管理员/普通管理员',
|
||||
`status` bit(1) NULL DEFAULT NULL COMMENT '状态',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
/** 店员角色**/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:30:39
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_clerk_role
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_clerk_role`;
|
||||
CREATE TABLE `li_clerk_role` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`clerk_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店员唯一id',
|
||||
`role_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '角色唯一id',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
/** 店铺部门 **/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:31:39
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_store_department
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_store_department`;
|
||||
CREATE TABLE `li_store_department` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime(6) NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '部门名称',
|
||||
`store_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店铺id',
|
||||
`parent_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '父id',
|
||||
`sort_order` decimal(20, 2) NULL DEFAULT NULL COMMENT '排序值',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
/** 部门角色关联 **/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:32:01
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_store_department_role
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_store_department_role`;
|
||||
CREATE TABLE `li_store_department_role` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime(6) NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`role_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '角色id',
|
||||
`department_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '部门id',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
/**店铺角色菜单**/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:34:42
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_store_menu_role
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_store_menu_role`;
|
||||
CREATE TABLE `li_store_menu_role` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime(6) NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`role_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '角色id',
|
||||
`menu_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '菜单',
|
||||
`store_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店铺id',
|
||||
`is_super` bit(1) NULL DEFAULT NULL COMMENT '是否拥有操作数据权限,为否则只有查看权限',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = Dynamic;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
/**店铺角色**/
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 03/03/2022 19:32:59
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_store_role
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_store_role`;
|
||||
CREATE TABLE `li_store_role` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime(6) NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '角色名称',
|
||||
`store_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '店铺id',
|
||||
`default_role` bit(1) NULL DEFAULT NULL COMMENT '是否为注册默认角色',
|
||||
`description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '备注',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 02/03/2022 09:57:49
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_menu
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_menu`;
|
||||
CREATE TABLE `li_menu` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`description` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '说明备注',
|
||||
`front_route` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '前端路由',
|
||||
`icon` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '图标',
|
||||
`level` int NULL DEFAULT NULL COMMENT '层级',
|
||||
`name` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '菜单/权限名称',
|
||||
`parent_id` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '父id',
|
||||
`path` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '赋权API地址,正则表达式',
|
||||
`sort_order` decimal(10, 2) NULL DEFAULT NULL COMMENT '排序值',
|
||||
`title` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '菜单标题',
|
||||
`front_component` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '文件地址',
|
||||
`permission` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci NULL DEFAULT NULL COMMENT '权限url',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8 COLLATE = utf8_general_ci ROW_FORMAT = Dynamic;
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of li_menu
|
||||
-- ----------------------------
|
||||
INSERT INTO `li_menu` VALUES (1348810750596767744, 'admin', '2021-01-12 09:55:17', b'0', 'admin', '2021-01-15 09:42:50', 'null', '1', 'ios-american-football', 0, 'settings', '0', '1', 2.00, '设置', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1348810864748945408, 'admin', '2021-01-12 09:55:45', b'0', 'admin', '2021-03-15 20:57:12', 'null', 'null', 'ios-american-football', 0, 'log', '0', 'null', 3.00, '日志', 'null', '/manager/setting/log*');
|
||||
INSERT INTO `li_menu` VALUES (1349237129847005184, 'admin', '2021-01-13 14:09:34', b'0', 'admin', '2021-01-15 09:43:16', 'null', 'Main', 'ios-american-football', 1, 'sys', '1348810750596767744', '/sys', 1.00, '系统设置', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1349237207378714624, 'admin', '2021-01-13 14:09:53', b'0', 'admin', '2021-07-27 16:07:49', 'null', 'Main', 'ios-american-football', 1, 'member', '1348810750596767744', '/member', 0.00, '用户管理', 'null', '/manager/permission/department*,/manager/passport/user*,/manager/permission/role*,/manager/permission/menu*,/manager/passport/user/admin/edit*');
|
||||
INSERT INTO `li_menu` VALUES (1349237928434098176, 'admin', '2021-01-13 14:13:03', b'0', 'admin', '2021-07-27 16:09:11', 'null', 'Main', 'ios-american-football', 1, 'log', '1348810864748945408', '/log', 1.00, '系统监控', 'null', '/manager/log*');
|
||||
INSERT INTO `li_menu` VALUES (1349246048900243456, 'admin', '2021-01-13 14:45:00', b'0', 'admin', '2021-07-27 16:07:57', 'null', 'sys/setting-manage/settingManage', 'ios-american-football', 2, 'setting', '1349237129847005184', 'setting', 1.00, '系统设置', 'null', '/manager/system/setting/get*,/manager/system/setting/put*,/manager/setting/setting*');
|
||||
INSERT INTO `li_menu` VALUES (1349246347597602816, 'admin', '2021-01-13 14:46:12', b'0', 'admin', '2021-07-27 16:08:03', 'null', 'sys/oss-manage/ossManage', 'ios-american-football', 2, 'oss-manage', '1349237129847005184', 'oss-manage', 3.00, 'OSS资源', '', '/manager/common/file*');
|
||||
INSERT INTO `li_menu` VALUES (1349246468775239680, 'admin', '2021-01-13 14:46:41', b'0', 'admin', '2021-07-27 16:08:14', 'null', 'region/index', 'ios-american-football', 2, 'region', '1349237129847005184', 'region', 4.00, '行政地区', 'null', '/manager/region*');
|
||||
INSERT INTO `li_menu` VALUES (1349246671158796288, 'admin', '2021-01-13 14:47:29', b'0', 'admin', '2021-07-27 16:08:09', 'null', 'logistics/index', 'ios-american-football', 2, 'logistics', '1349237129847005184', 'logistics', 5.00, '物流公司', 'null', '/manager/other/logistics*');
|
||||
INSERT INTO `li_menu` VALUES (1349246896661356544, 'admin', '2021-01-13 14:48:23', b'0', 'admin', '2021-07-27 16:08:23', 'null', 'sys/setting-manage/settingManage', 'ios-american-football', 2, 'authLogin', '1349237129847005184', 'authLogin', 6.00, '信任登录', 'null', '/manager/system/setting/get*,/manager/system/setting/put*,/manager/setting/setting*\r\n');
|
||||
INSERT INTO `li_menu` VALUES (1349247081504333824, 'admin', '2021-01-13 14:49:07', b'0', 'admin', '2021-07-27 16:08:45', 'null', 'sys/setting-manage/settingManage', 'ios-american-football', 2, 'pay', '1349237129847005184', 'pay', 7.00, '支付设置', 'null', '/manager/system/setting/get*,/manager/system/setting/put*,/manager/system/setting*');
|
||||
INSERT INTO `li_menu` VALUES (1349247640584085504, 'admin', '2021-01-13 14:51:20', b'0', 'admin', '2021-07-27 16:08:56', 'null', 'sensitiveWords/index', 'ios-american-football', 2, 'sensitiveWords', '1349237129847005184', 'sensitiveWords', 8.00, '敏感词', 'null', '/manager/other/sensitiveWords*');
|
||||
INSERT INTO `li_menu` VALUES (1349254815809298432, 'admin', '2021-01-13 15:19:51', b'0', 'admin', '2021-01-15 11:15:40', 'null', 'sys/user-manage/userManage', 'ios-american-football', 2, 'user-manage', '1349237207378714624', 'user-manage', 1.00, '用户管理', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1349255214977015808, 'admin', '2021-01-13 15:21:26', b'0', 'admin', '2021-01-15 11:16:21', 'null', 'sys/department-manage/departmentManage', 'ios-american-football', 2, 'department-manage', '1349237207378714624', 'department-manage', 3.00, '部门管理', 'null', '/manager/permission/department*,/manager/permission/departmentRole*,');
|
||||
INSERT INTO `li_menu` VALUES (1349255404425338880, 'admin', '2021-01-13 15:22:11', b'0', 'admin', '2021-02-24 09:22:21', 'null', 'sys/role-manage/roleManage', 'ios-american-football', 2, 'role-manage', '1349237207378714624', 'role-manage', 4.00, '角色权限', 'null', '/manager/permission/role*,/manager/permission/roleMenu*');
|
||||
INSERT INTO `li_menu` VALUES (1349256082979840000, 'admin', '2021-01-13 15:24:53', b'0', 'admin', '2021-01-15 11:18:14', 'null', 'sys/log-manage/logManage', 'ios-american-football', 2, 'log-manage', '1349237928434098176', 'log-manage', 2.00, '日志管理', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1357584224760102912, 'admin', '2021-02-05 06:57:57', b'0', 'admin', '2021-07-27 16:09:02', 'null', 'sys/app-version/appVersion', 'ios-american-football', 2, 'appVersion', '1349237129847005184', 'appVersion', 9.00, 'APP版本', 'null', '/manager/other/appVersion*');
|
||||
INSERT INTO `li_menu` VALUES (1357873097859923969, 'admin', '2021-02-24 09:53:02', b'0', 'admin', '2021-02-24 09:53:12', NULL, 'sys/menu-manage/menuManage', 'ios-american-football', 2, 'menuManage', '1349237207378714624', 'menu-manage', 2.00, '菜单管理', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367038467288072192, 'admin', '2021-03-03 09:05:44', b'0', 'admin', '2021-03-03 09:09:27', 'null', 'null', 'ios-person-add', 0, 'member', '0', 'null', 0.00, '会员', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367039534616805376, 'admin', '2021-03-03 09:09:58', b'0', 'admin', '2021-05-18 10:51:12', 'null', 'null', 'md-reorder', 0, 'order', '0', 'null', 0.00, '订单', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367039950368800768, 'admin', '2021-03-03 09:11:37', b'0', NULL, NULL, NULL, NULL, 'ios-share', 0, 'goods', '0', NULL, 0.20, '商品', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367040067201138688, 'admin', '2021-03-03 09:12:05', b'0', 'admin', '2021-12-02 19:45:22', NULL, 'null', 'ios-hammer', 0, 'promotions', '0', 'null', 0.30, '促销', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1367040599596728320, 'admin', '2021-03-03 09:14:12', b'0', 'admin', '2021-03-03 09:52:13', 'null', 'null', 'ios-color-palette', 0, 'operate', '0', 'null', 0.50, '运营', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367040819248234496, 'admin', '2021-03-03 09:15:04', b'0', 'lili_ftyy', '2022-03-01 15:13:04', NULL, 'null', 'ios-stats', 0, 'statistics', '0', 'null', 0.70, '统计', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1367041332861730816, 'admin', '2021-03-03 09:17:07', b'0', NULL, NULL, NULL, 'Main', 'ios-aperture', 1, '/', '1367038467288072192', '/', 0.00, '会员管理', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367041461194850304, 'admin', '2021-03-03 09:17:37', b'0', 'admin', '2021-07-27 16:02:17', NULL, 'member/list/index', 'ios-aperture', 2, 'memberList', '1367041332861730816', 'memberList', 0.00, '会员列表', NULL, '/manager/common/file*,/manager/passport/member*');
|
||||
INSERT INTO `li_menu` VALUES (1367041575619657728, 'admin', '2021-03-03 09:18:05', b'0', 'admin', '2021-07-27 15:59:50', NULL, 'member/list/memberRecycle', 'ios-aperture', 2, 'memberRecycle', '1367041332861730816', 'memberRecycle', 1.00, '回收站', NULL, '/manager/member*');
|
||||
INSERT INTO `li_menu` VALUES (1367042490443497472, 'admin', '2021-03-03 09:21:43', b'0', NULL, NULL, NULL, 'Main', 'ios-aperture', 1, '/', '1367038467288072192', '/', 1.00, '预存款', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367042664410644480, 'admin', '2021-03-03 09:22:24', b'0', 'admin', '2021-07-27 16:02:44', 'null', 'member/advance/walletLog', 'ios-aperture', 2, 'walletLog', '1367042490443497472', 'walletLog', 0.00, '会员资金', 'null', '/manager/wallet/log*');
|
||||
INSERT INTO `li_menu` VALUES (1367042804944994304, 'admin', '2021-03-03 09:22:58', b'0', 'admin', '2021-07-27 16:02:48', NULL, 'member/advance/recharge', 'ios-alert', 2, 'recharge', '1367042490443497472', 'recharge', 1.00, '充值记录', NULL, '/manager/wallet/recharge*');
|
||||
INSERT INTO `li_menu` VALUES (1367042804944994305, 'admin', '2021-03-03 09:22:58', b'0', 'admin', '2021-07-27 16:02:52', NULL, 'member/advance/withdrawApply', 'ios-alert', 2, 'withdrawApply', '1367042490443497472', 'withdrawApply', 1.00, '提现申请', NULL, '/manager/wallet/withdrawApply*');
|
||||
INSERT INTO `li_menu` VALUES (1367042917113266176, 'admin', '2021-03-03 09:23:25', b'0', NULL, NULL, NULL, 'Main', 'ios-aperture', 1, 'commont', '1367038467288072192', '/', 0.00, '评价', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367043020976816128, 'admin', '2021-03-03 09:23:49', b'0', 'admin', '2021-07-27 16:02:35', NULL, 'goods/goods-review/index', 'md-aperture', 2, 'goodsReview', '1367042917113266176', 'goodsReview', 0.00, '会员评价', NULL, '/manager/memberEvaluation*');
|
||||
INSERT INTO `li_menu` VALUES (1367043443917848576, 'admin', '2021-03-03 09:25:30', b'0', 'admin', '2021-07-27 16:03:00', NULL, 'Main', 'md-aperture', 1, 'order', '1367039534616805376', '/', 0.00, '订单', NULL, '/manager/orders*');
|
||||
INSERT INTO `li_menu` VALUES (1367043505771249664, 'admin', '2021-03-03 09:25:45', b'0', NULL, NULL, NULL, 'Main', 'md-aperture', 1, 'aftersale', '1367039534616805376', '/', 0.00, '售后', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367043642379730944, 'admin', '2021-03-03 09:26:17', b'0', NULL, NULL, NULL, 'order/order/orderList', 'ios-aperture', 2, 'orderList', '1367043443917848576', 'orderList', 0.00, '商品订单', NULL, '/manager/order/order*');
|
||||
INSERT INTO `li_menu` VALUES (1367043791105556480, 'admin', '2021-03-03 09:26:53', b'0', NULL, NULL, NULL, 'order/order/fictitiousOrderList', 'ios-aperture', 2, 'fictitiousOrderList', '1367043443917848576', 'fictitiousOrderList', 1.00, '虚拟订单', NULL, '/manager/order/order*');
|
||||
INSERT INTO `li_menu` VALUES (1367043980407078912, 'admin', '2021-03-03 09:27:38', b'0', 'admin', '2021-07-27 16:03:43', NULL, 'order/after-order/afterSaleOrder', 'md-alert', 2, 'afterSaleOrder', '1367043505771249664', 'afterSaleOrder', 0.00, '售后管理', NULL, '/manager/order/afterSale*');
|
||||
INSERT INTO `li_menu` VALUES (1367044121163726848, 'admin', '2021-03-03 09:28:12', b'0', 'admin', '2021-07-27 16:03:48', NULL, 'order/after-order/orderComplaint', 'md-alert', 2, 'orderComplaint', '1367043505771249664', 'orderComplaint', 2.00, '交易投诉', NULL, '/manager/order/complain*');
|
||||
INSERT INTO `li_menu` VALUES (1367044247978508288, 'admin', '2021-03-03 09:28:42', b'0', 'admin', '2021-07-27 16:03:52', NULL, 'order/after-order/afterSale', 'md-aperture', 2, 'afterSaleReason', '1367043505771249664', 'afterSaleReason', 3.00, '售后原因', NULL, '/manager/order/afterSaleReason*');
|
||||
INSERT INTO `li_menu` VALUES (1367044376391319552, 'admin', '2021-03-03 09:29:12', b'0', 'admin', '2021-07-27 16:04:08', NULL, 'Main', 'md-aperture', 1, 'goodsManager', '1367039950368800768', '/', 0.00, '商品管理', NULL, '/manager/goods*');
|
||||
INSERT INTO `li_menu` VALUES (1367044657296441344, 'admin', '2021-03-03 09:30:19', b'0', NULL, NULL, NULL, 'Main', 'ios-aperture', 1, 'association', '1367039950368800768', '/', 1.00, '关联管理', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367045529720061952, 'admin', '2021-03-03 09:33:47', b'0', 'admin', '2021-07-27 15:38:46', NULL, 'goods/goods-info/goods', 'md-aperture', 2, 'managerGoods', '1367044376391319552', 'managerGoods', 0.00, '平台商品', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1367045630710513664, 'admin', '2021-03-03 09:34:11', b'0', 'admin', '2021-07-27 15:38:56', NULL, 'goods/goods-info/goodsApply', 'ios-alert', 2, 'applyGoods', '1367044376391319552', 'applyGoods', 1.00, '商品审核', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1367045794284175360, 'admin', '2021-03-03 09:34:50', b'0', 'admin', '2021-07-27 16:04:18', NULL, 'goods/goods-manage/category', 'md-alert', 2, 'goodsCategory', '1367044657296441344', 'goodsCategory', 0.00, '商品分类', NULL, '/manager/goods/category*,/manager/goods/brand*,/manager/goods/spec*,/manager/goods/parameters*');
|
||||
INSERT INTO `li_menu` VALUES (1367045921434501120, 'admin', '2021-03-03 09:35:21', b'0', 'admin', '2021-07-27 16:04:23', NULL, 'goods/goods-manage/brand', 'md-alert', 2, 'goodsBrand', '1367044657296441344', 'goodsBrand', 1.00, '品牌列表', NULL, '/manager/goods/brand*');
|
||||
INSERT INTO `li_menu` VALUES (1367046068369358848, 'admin', '2021-03-03 09:35:56', b'0', 'admin', '2021-07-27 16:04:27', NULL, 'goods/goods-manage/spec', 'md-aperture', 2, 'goodsSpec', '1367044657296441344', 'goodsSpec', 2.00, '规格列表', NULL, '/manager/goods/spec*');
|
||||
INSERT INTO `li_menu` VALUES (1367046266214678528, 'admin', '2021-03-03 09:36:43', b'0', 'admin', '2021-07-27 16:04:32', NULL, 'goods-unit/index', 'md-alert', 2, 'goodsUnit', '1367044657296441344', 'goodsUnit', 4.00, '计量单位', NULL, '/manager/goods/goodsUnit*');
|
||||
INSERT INTO `li_menu` VALUES (1367048084701315072, 'admin', '2021-03-03 09:43:57', b'0', 'admin', '2021-03-03 09:52:17', 'null', 'null', 'ios-pricetags', 0, 'shop', '0', 'null', 0.40, '店铺', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367048684339986432, 'admin', '2021-03-03 09:46:20', b'0', NULL, NULL, NULL, 'Main', 'md-aperture', 1, 'shopManager', '1367048084701315072', '/', 0.00, '店铺管理', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367048754229673984, 'admin', '2021-03-03 09:46:36', b'0', NULL, NULL, NULL, 'Main', 'md-aperture', 1, 'bill', '1367048084701315072', '/', 0.00, ' 店铺结算', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367048832210173952, 'admin', '2021-03-03 09:46:55', b'0', 'admin', '2021-07-27 16:05:30', NULL, 'seller/shop/shopList', 'md-aperture', 2, 'shopList', '1367048684339986432', 'shopList', 0.00, '店铺列表', NULL, '/manager/order/order*,/manager/store*');
|
||||
INSERT INTO `li_menu` VALUES (1367048967635861504, 'admin', '2021-03-03 09:47:27', b'0', 'admin', '2021-07-27 16:05:32', NULL, 'seller/shop/shopAuditList', 'md-alert', 2, 'shopAuth', '1367048684339986432', 'shopAuth', 1.00, '店铺审核', NULL, '/manager/store*');
|
||||
INSERT INTO `li_menu` VALUES (1367049068122996736, 'admin', '2021-03-03 09:47:51', b'0', 'admin', '2021-07-27 16:05:36', NULL, 'seller/bill/bill', 'md-alert', 2, 'billList', '1367048754229673984', 'billList', 0.00, '店铺结算', NULL, '/manager/order/bill*');
|
||||
INSERT INTO `li_menu` VALUES (1367049214198022144, 'admin', '2021-03-03 09:48:26', b'0', 'admin', '2021-12-02 19:45:28', NULL, 'Main', 'md-aperture', 1, 'promotionsManager', '1367040067201138688', '/', 0.00, '促销管理', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1367049384792948736, 'admin', '2021-03-03 09:49:07', b'0', 'admin', '2021-12-02 19:54:12', NULL, 'promotions/coupon/coupon', 'md-alert', 2, 'promotions/coupon', '1367049214198022144', 'promotions/coupon', 0.00, '优惠券', NULL, '/manager/promotion/coupon*');
|
||||
INSERT INTO `li_menu` VALUES (1367049500782231552, 'admin', '2021-03-03 09:49:34', b'0', 'admin', '2021-12-02 19:41:37', 'null', 'promotions/full-discount/full-discount', 'md-alert', 2, 'promotions/full-discount', '1367049214198022144', 'promotions/full-discount', 1.00, '满额活动', 'null', '/manager/promotion/fullDiscount*');
|
||||
INSERT INTO `li_menu` VALUES (1367049611578966016, 'admin', '2021-03-03 09:50:01', b'0', 'admin', '2021-12-02 20:16:10', 'null', 'promotions/seckill/seckill', 'md-alert', 2, 'promotions/seckill', '1367049214198022144', 'promotions/seckill', 2.00, '秒杀活动', 'null', '/manager/promotion/seckill*');
|
||||
INSERT INTO `li_menu` VALUES (1367049712657498112, 'admin', '2021-03-03 09:50:25', b'0', 'admin', '2021-12-02 20:22:04', 'null', 'promotions/pintuan/pintuan', 'md-alert', 2, 'promotions/pintuan', '1367049214198022144', 'promotions/pintuan', 3.00, '拼团活动', 'null', '/manager/promotion/pintuan*');
|
||||
INSERT INTO `li_menu` VALUES (1367050250249830400, 'admin', '2021-03-03 09:52:33', b'0', 'admin', '2021-03-22 20:38:14', 'null', 'Main', 'md-aperture', 1, 'document', '1367040599596728320', '/', 2.00, '文章管理', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367050320584114176, 'admin', '2021-03-03 09:52:50', b'0', 'admin', '2021-07-27 16:05:49', NULL, 'Main', 'md-aperture', 1, 'floor', '1367040599596728320', '/', 0.00, '楼层装修', NULL, '/manager/pageData*,/manager/file*,/manager/article-category*,/manager/article*,/manager/promotion*,/manager/goods*,/manager/store*');
|
||||
INSERT INTO `li_menu` VALUES (1367050530030878720, 'admin', '2021-03-03 09:53:40', b'0', 'admin', '2021-03-04 01:05:57', 'null', 'page-decoration/floorList', 'md-alert', 2, 'pcFloor', '1367050320584114176', 'pcFloor', 0.00, 'PC端', 'null', '/manager/other/pageData*');
|
||||
INSERT INTO `li_menu` VALUES (1367050673312497664, 'admin', '2021-03-03 09:54:14', b'0', 'admin', '2021-03-04 01:06:04', 'null', 'page-decoration/wap/wapList', 'md-aperture', 2, 'wapList', '1367050320584114176', 'wapList', 1.00, '移动端', 'null', '/manager/other/pageData*');
|
||||
INSERT INTO `li_menu` VALUES (1367050829697122304, 'admin', '2021-03-03 09:54:51', b'0', 'admin', '2021-07-27 16:06:32', 'null', 'page/article-manage/hotWords', 'md-aperture', 2, 'hotKeyWord', '1367050250249830400', 'hotKeyWord', 0.00, '搜索热词', 'null', '/manager/hotwords*');
|
||||
INSERT INTO `li_menu` VALUES (1367050939084570624, 'admin', '2021-03-03 09:55:17', b'0', 'admin', '2021-07-27 16:06:38', NULL, 'page/article-manage/ArticleCategory', 'md-aperture', 2, 'article-category', '1367050250249830400', 'article-category', 1.00, '文章分类', NULL, '/manager/other/articleCategory*');
|
||||
INSERT INTO `li_menu` VALUES (1367051048232943616, 'admin', '2021-03-03 09:55:43', b'0', 'admin', '2021-07-27 16:06:42', NULL, 'page/article-manage/articleList', 'md-alert', 2, 'articleList', '1367050250249830400', 'articleList', 3.00, '文章管理', NULL, '/manager/other/article*,/manager/other/articleCategory*');
|
||||
INSERT INTO `li_menu` VALUES (1367052616634204160, 'admin', '2021-03-03 10:01:57', b'0', 'admin', '2021-07-27 16:07:38', NULL, 'Main', 'md-aperture', 1, 'statistics', '1367040819248234496', '/', 0.00, '统计', NULL, '/manager/store*,/manager/member*');
|
||||
INSERT INTO `li_menu` VALUES (1367052705725415424, 'admin', '2021-03-03 10:02:18', b'0', 'admin', '2021-03-11 22:11:05', 'null', 'statistics/member', 'md-alert', 2, 'memberStatistics', '1367052616634204160', 'memberStatistics', 0.00, '会员统计', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367052805503713280, 'admin', '2021-03-03 10:02:42', b'0', 'admin', '2021-03-11 22:11:14', 'null', 'statistics/order', 'md-alert', 2, 'orderStatistics', '1367052616634204160', 'orderStatistics', 1.00, '订单统计', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367052915314786304, 'admin', '2021-03-03 10:03:08', b'0', 'admin', '2021-03-11 22:11:23', 'null', 'statistics/goods', 'md-alert', 2, 'goodsStatistics', '1367052616634204160', 'goodsStatistics', 2.00, '商品统计', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1367053087121866752, 'admin', '2021-03-03 10:03:49', b'0', 'admin', '2021-03-11 22:11:34', 'null', 'statistics/traffic', 'md-alert', 2, 'trafficStatistics', '1367052616634204160', 'trafficStatistics', 4.00, '流量统计', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1372807928452481024, 'admin', '2021-03-19 02:11:30', b'0', NULL, NULL, NULL, 'Main', 'ios-aperture', 1, 'flow', '1367039534616805376', '/', 3.00, '流水', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1372808148565360640, 'admin', '2021-03-19 02:12:23', b'0', 'admin', '2021-07-27 16:03:57', NULL, 'order/flow/paymentLog', 'md-alert', 2, 'paymentLog', '1372807928452481024', 'paymentLog', 1.00, '收款记录', NULL, '/manager/order/paymentLog*');
|
||||
INSERT INTO `li_menu` VALUES (1372808352295288832, 'admin', '2021-03-19 02:13:11', b'0', 'admin', '2021-07-27 16:04:01', NULL, 'order/flow/refundLog', 'ios-aperture', 2, 'refundLog', '1372807928452481024', 'refundLog', 2.00, '退款流水', NULL, '/manager/order/refundLog*');
|
||||
INSERT INTO `li_menu` VALUES (1373166892465782784, 'admin', '2021-03-20 01:57:54', b'0', 'admin', '2021-03-22 20:13:48', 'null', 'Main', 'ios-aperture', 1, '/', '1367038467288072192', '/', 0.00, '积分', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1373167227385151488, 'admin', '2021-03-20 01:59:14', b'0', 'admin', '2021-07-27 16:02:40', 'null', 'member/point/point', 'ios-aperture', 2, 'point', '1373166892465782784', 'point', 0.00, '积分历史', 'null', '/manager/member/memberPointsHistory*');
|
||||
INSERT INTO `li_menu` VALUES (1373791578371391488, 'admin', '2021-03-21 19:20:11', b'0', 'admin', '2021-07-27 16:05:38', NULL, 'seller/bill/accountStatementBill', 'md-alert', 2, 'accountStatementBill', '1367048754229673984', 'accountStatementBill', 0.00, '商家对账', NULL, '/manager/order/bill*');
|
||||
INSERT INTO `li_menu` VALUES (1374154349697040384, 'admin', '2021-03-22 19:21:42', b'0', 'admin', '2021-07-27 16:06:55', 'null', 'Main', 'md-aperture', 1, 'feedback', '1367040599596728320', '/', 3.00, '意见反馈', 'null', '/manager/other/feedback*');
|
||||
INSERT INTO `li_menu` VALUES (1374155741123837952, 'admin', '2021-03-22 19:27:14', b'0', 'admin', '2021-07-27 15:41:40', 'null', 'page/feedback/feedback', 'md-aperture', 2, 'feedback', '1374154349697040384', 'feedback', 0.00, '意见反馈', 'null', 'null');
|
||||
INSERT INTO `li_menu` VALUES (1374173575405109248, 'admin', '2021-03-22 20:38:06', b'0', 'admin', '2021-03-22 20:52:58', 'null', 'Main', 'ios-analytics', 1, 'distributionManager', '1367040599596728320', '/', 1.00, '分销管理', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1374177618072436736, 'admin', '2021-03-22 20:54:10', b'0', 'admin', '2021-07-27 16:05:58', 'null', 'distribution/distributionSetting', 'ios-basketball', 2, 'distributionSetting', '1374173575405109248', 'distributionSetting', 0.00, '分销设置', 'null', '/manager/system/setting/put/DISTRIBUTION_SETTING*,/manager/system/setting/get/DISTRIBUTION_SETTING*');
|
||||
INSERT INTO `li_menu` VALUES (1374177789581721600, 'admin', '2021-03-22 20:54:51', b'0', 'admin', '2021-07-27 16:06:15', 'null', 'distribution/distributionGoods', 'ios-chatbubbles', 2, 'distributionGoods', '1374173575405109248', 'distributionGoods', 3.00, '分销商品', 'null', '/manager/distribution/goods*');
|
||||
INSERT INTO `li_menu` VALUES (1374177910411231232, 'admin', '2021-03-22 20:55:19', b'0', 'admin', '2021-07-27 16:06:20', 'null', 'distribution/distributionOrder', 'ios-cloudy', 2, 'distributionOrder', '1374173575405109248', 'distributionOrder', 4.00, '分销订单', 'null', '/manager/distribution/order*,/manager/store*');
|
||||
INSERT INTO `li_menu` VALUES (1374178079181635584, 'admin', '2021-03-22 20:56:00', b'0', 'admin', '2021-07-27 16:06:05', 'null', 'distribution/distributionApply', 'md-egg', 2, 'distributionApply', '1374173575405109248', 'distributionApply', 1.00, '分销申请', 'null', '/manager/distribution*');
|
||||
INSERT INTO `li_menu` VALUES (1374178303975358464, 'admin', '2021-03-22 20:56:53', b'0', 'admin', '2021-07-27 16:06:08', 'null', 'distribution/distribution', 'md-person', 2, 'distribution', '1374173575405109248', 'distribution', 2.00, '分销员', 'null', '/manager/distribution*');
|
||||
INSERT INTO `li_menu` VALUES (1374916594269945856, 'admin', '2021-03-24 21:50:35', b'0', 'admin', '2021-07-27 16:08:51', NULL, 'sys/slider/slider', 'ios-aperture', 2, 'slider', '1349237129847005184', 'slider', 7.00, '验证码', NULL, '/manager/other/verificationSource*');
|
||||
INSERT INTO `li_menu` VALUES (1376450531517530112, 'admin', '2021-03-29 03:25:55', b'0', NULL, NULL, NULL, 'Main', 'md-basketball', 1, 'notice', '1367040599596728320', '/', 5.00, '站内信', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1376450662098796544, 'admin', '2021-03-29 03:26:26', b'0', 'admin', '2021-07-27 16:07:23', NULL, 'sys/message/noticeMessageTemplate', 'ios-american-football', 2, 'noticeMessageTemplate', '1376450531517530112', 'noticeMessageTemplate', 1.00, '站内信', NULL, '/manager/other/message*');
|
||||
INSERT INTO `li_menu` VALUES (1376450766817984512, 'admin', '2021-03-29 03:26:51', b'0', 'admin', '2021-03-29 03:27:25', 'null', 'Main', 'md-checkmark', 1, 'sms', '1367040599596728320', '/', 6.00, '短信管理', 'null', NULL);
|
||||
INSERT INTO `li_menu` VALUES (1376450876423536640, 'admin', '2021-03-29 03:27:17', b'0', 'admin', '2021-07-27 16:07:29', NULL, 'sys/message/sms', 'ios-timer', 2, 'sms', '1376450766817984512', 'sms', 1.00, '短信', NULL, '/manager/sms/sms*,/manager/passport/member*');
|
||||
INSERT INTO `li_menu` VALUES (1384035281702748160, 'admin', '2021-04-19 14:45:00', b'0', 'admin', '2021-07-27 16:08:18', 'null', 'member/message-manage/weChatMessageManager', 'md-aperture', 2, 'message-manage', '1349237129847005184', 'message-manage', 5.00, '微信消息', 'null', '/manager/wechat/wechatMessage*');
|
||||
INSERT INTO `li_menu` VALUES (1403988156444962818, 'admin', '2021-06-13 16:10:36', b'0', 'admin', '2021-12-02 19:54:37', 'null', 'promotions/coupon-activity/coupon', '', 2, 'promotions/coupon-activity', '1367049214198022144', 'promotions/coupon-activity', 0.00, '券活动', 'null', '/manager/promotion/couponActivity*');
|
||||
INSERT INTO `li_menu` VALUES (1407601962899230721, 'admin', '2021-06-23 15:30:35', b'0', 'admin', '2021-07-27 16:05:08', NULL, 'Main', '', 1, 'liveManage', '1367040067201138688', '/', 2.00, '直播管理', NULL, '/manager/broadcast*');
|
||||
INSERT INTO `li_menu` VALUES (1407602049759072258, 'admin', '2021-06-23 15:30:55', b'0', 'admin', '2021-12-07 10:54:54', NULL, 'promotions/live/live', '', 2, 'promotions/live', '1407601962899230721', 'promotions/live', 1.00, '直播管理', NULL, 'null');
|
||||
INSERT INTO `li_menu` VALUES (1407602441964244994, 'admin', '2021-06-23 15:32:29', b'0', NULL, NULL, NULL, 'Main', '', 1, 'pointManage', '1367040067201138688', '/', 3.00, '积分活动', NULL, NULL);
|
||||
INSERT INTO `li_menu` VALUES (1407602516912263170, 'admin', '2021-06-23 15:32:47', b'0', 'admin', '2021-12-03 19:18:30', NULL, 'promotions/points-goods/points-goods', '', 2, 'promotions/points-goods', '1407602441964244994', 'promotions/points-goods', 1.00, '积分商品', NULL, '/manager/promotion/pointsGoods*,/manager/goods*');
|
||||
INSERT INTO `li_menu` VALUES (1407602673334636546, 'admin', '2021-06-23 15:33:24', b'0', 'admin', '2021-12-03 19:19:23', NULL, 'promotions/points-goods-category/points-goods-category', '', 2, 'promotions/points-goods-category', '1407602441964244994', 'promotions/points-goods-category', 2.00, '积分分类', NULL, '/manager/promotion/pointsGoodsCategory*');
|
||||
INSERT INTO `li_menu` VALUES (1410862675914764290, 'admin', '2021-07-02 15:27:29', b'0', 'admin', '2021-07-27 16:06:26', 'null', 'distribution/distributionCash', '', 2, 'distributionCash', '1374173575405109248', 'distributionCash', 5.00, '分销提现', 'null', '/manager/distribution/cash*');
|
||||
INSERT INTO `li_menu` VALUES (1419926569920536578, 'admin', '2021-07-27 15:44:10', b'0', 'admin', '2021-07-27 16:07:10', NULL, 'customWords/index', NULL, 2, 'customWords', '1367050250249830400', 'customWords', 4.00, 'ES分词', NULL, '/manager/other/customWords*');
|
||||
INSERT INTO `li_menu` VALUES (1430799171593535490, 'admin', '2021-08-26 15:48:00', b'0', 'admin', '2021-12-02 20:21:34', NULL, 'promotions/kanjia/kanjia-activity-goods', NULL, 2, 'promotions/kanjia', '1367049214198022144', 'promotions/kanjia', 6.00, '砍价活动', NULL, '/manager/promotion/kanJiaGoods*');
|
||||
INSERT INTO `li_menu` VALUES (1495665663207432193, 'admin', '2022-02-21 15:44:17', b'0', 'admin', '2022-02-21 15:45:44', NULL, 'distribution/distrbutionGrade', NULL, 2, 'distrbutionGrade', '1374173575405109248', 'distrbutionGrade', 0.00, '分销等级', NULL, '/manager/distrbutionGrade*');
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
|
||||
/*
|
||||
Navicat Premium Data Transfer
|
||||
|
||||
Source Server : lilishop
|
||||
Source Server Type : MySQL
|
||||
Source Server Version : 80025
|
||||
Source Host : 192.168.0.116:3306
|
||||
Source Schema : zhimai1
|
||||
|
||||
Target Server Type : MySQL
|
||||
Target Server Version : 80025
|
||||
File Encoding : 65001
|
||||
|
||||
Date: 01/03/2022 15:36:03
|
||||
*/
|
||||
|
||||
SET NAMES utf8mb4;
|
||||
SET FOREIGN_KEY_CHECKS = 0;
|
||||
|
||||
-- ----------------------------
|
||||
-- Table structure for li_store_menu
|
||||
-- ----------------------------
|
||||
DROP TABLE IF EXISTS `li_store_menu`;
|
||||
CREATE TABLE `li_store_menu` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) NULL DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) NULL DEFAULT NULL COMMENT '删除标志 true/false 删除/未删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`update_time` datetime NULL DEFAULT NULL COMMENT '更新时间',
|
||||
`description` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '说明备注',
|
||||
`front_route` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '前端路由',
|
||||
`icon` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '图标',
|
||||
`level` int NULL DEFAULT NULL COMMENT '层级',
|
||||
`name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '菜单/权限名称',
|
||||
`parent_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '父id',
|
||||
`path` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '赋权API地址,正则表达式',
|
||||
`sort_order` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '排序值',
|
||||
`title` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '菜单标题',
|
||||
`permission` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '权限url',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC;
|
||||
|
||||
-- ----------------------------
|
||||
-- Records of li_store_menu
|
||||
-- ----------------------------
|
||||
INSERT INTO `li_store_menu` VALUES (1348810750596767744, NULL, '2022-01-11 22:35:33.000000', b'0', NULL, '2022-01-11 22:36:52', NULL, 'Main', 'ios-american-football', 0, 'goods', '0', '/', '1', '商品', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1348810864748945408, NULL, '2022-01-11 22:35:37.000000', b'0', NULL, '2022-01-11 22:36:55', NULL, 'Main', 'ios-american-football', 1, 'Main', '1348810750596767744', '/', '1.1', '商品管理', '');
|
||||
INSERT INTO `li_store_menu` VALUES (1349237129847005184, NULL, '2022-01-11 22:35:40.000000', b'0', NULL, '2022-01-11 22:36:59', NULL, 'goods-operation', 'ios-american-football', 2, 'goods-operation', '1348810864748945408', '/goods-operation', '1.11', '商品发布', '/store/goods/category*,/store/goods/categorySpec*,/store/goods/categoryParameters*,/store/goods/draftGoods*,/store/goods/label*,/store/goods/goods*,/store/goods/goodsUnit*,/store/goods/spec*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349237207378714624, NULL, '2022-01-11 22:35:42.000000', b'0', NULL, '2022-01-11 22:37:02', NULL, 'goods/goods-seller/goods', 'ios-american-football', 2, 'goods', '1348810864748945408', 'goods', '1.12', '商品列表', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349237928434098176, NULL, '2022-01-11 22:35:45.000000', b'0', NULL, '2022-01-11 22:37:05', NULL, 'goods/goods-seller/draftGoods', 'ios-american-football', 2, 'template-goods', '1348810864748945408', 'template-goods', '1.13', '商品模板', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349246048900243456, NULL, '2022-01-11 22:35:48.000000', b'0', NULL, '2022-01-11 22:37:08', NULL, 'goods/goods-manage/category', 'ios-american-football', 2, 'category', '1348810864748945408', 'category', '1.14', '店铺分类', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349246347597602816, NULL, '2022-01-11 22:35:51.000000', b'0', NULL, '2022-01-11 22:37:11', NULL, 'Main', 'ios-american-football', 0, 'order', '0', '/', '2', '订单', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349246468775239680, NULL, '2022-01-11 22:38:28.000000', b'0', NULL, '2022-01-11 22:38:31', NULL, 'Main', 'ios-american-football', 1, 'Main', '1349246347597602816', '/', '2.1', '订单管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349246671158796288, NULL, '2022-01-11 22:38:42.000000', b'0', NULL, '2022-01-11 22:38:35', NULL, 'order/order/orderList', 'ios-american-football', 2, 'orderList', '1349246468775239680', 'orderList', '2.11', '商品订单', '/store/order/order*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349246896661356544, NULL, '2022-01-11 22:40:27.000000', b'0', NULL, '2022-01-11 22:40:34', NULL, 'order/order/virtualOrderList', 'ios-american-football', 2, 'virtualOrderList', '1349246468775239680', 'virtualOrderList', '2.12', '虚拟订单', '/store/order/order*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349247081504333824, NULL, '2022-01-11 22:41:47.000000', b'0', NULL, '2022-01-11 22:41:50', NULL, 'Main', 'ios-american-football', 1, 'Main', '1349246347597602816', '/', '2.2', '评价管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349247640584085504, NULL, '2022-01-11 22:43:29.000000', b'0', NULL, '2022-01-11 22:45:47', NULL, 'member/memberComment', 'ios-american-football', 2, 'memberComment', '1349247081504333824', 'memberComment', '2.21', '评价管理', '/store/member/evaluation*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349254815809298432, NULL, '2022-01-11 22:45:35.000000', b'0', NULL, '2022-01-11 22:45:50', NULL, 'Main', 'ios-american-football', 1, 'Main', '1349246347597602816', '/', '2.3', '售后管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1349255214977015808, NULL, '2022-01-11 22:49:22.000000', b'0', NULL, '2022-01-11 22:49:27', NULL, 'order/after-order/returnGoodsOrder', 'ios-american-football', 2, 'returnGoodsOrder', '1349254815809298432', 'returnGoodsOrder', '2.31', '退货管理', '/store/order/afterSale*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349255404425338880, NULL, '2022-01-11 22:51:20.000000', b'0', NULL, '2022-01-11 22:51:22', NULL, 'order/after-order/returnMoneyOrder', 'ios-american-football', 2, 'returnMoneyOrder', '1349254815809298432', 'returnMoneyOrder', '2.32', '退款管理', '/store/order/afterSale*');
|
||||
INSERT INTO `li_store_menu` VALUES (1349256082979840000, NULL, '2022-01-11 22:52:50.000000', b'0', NULL, '2022-01-11 22:52:55', NULL, 'order/after-order/orderComplaint', 'ios-american-football', 2, 'orderComplaint', '1349254815809298432', 'orderComplaint', '2.33', '投诉管理', '/store/order/complain*');
|
||||
INSERT INTO `li_store_menu` VALUES (1357584224760102912, NULL, '2022-01-11 23:02:20.000000', b'0', NULL, '2022-01-11 23:02:25', NULL, 'Main', 'ios-american-football', 0, 'bill', '0', '/', '3', '财务', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1357873097859923969, NULL, '2022-01-11 23:04:13.000000', b'0', NULL, '2022-01-11 23:04:17', NULL, 'Main', 'ios-american-football', 1, 'Main', '1357584224760102912', '/', '3.1', '财务管理', '');
|
||||
INSERT INTO `li_store_menu` VALUES (1367038467288072192, NULL, '2022-01-11 23:06:11.000000', b'0', NULL, '2022-01-11 23:06:16', NULL, 'shop/bill/accountStatementBill', 'ios-american-football', 2, 'accountStatementBill', '1357873097859923969', 'accountStatementBill', '3.11', '财务对账', '/store/order/bill*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367039534616805376, NULL, '2022-01-11 23:07:54.000000', b'0', NULL, '2022-01-11 23:07:57', NULL, 'shop/bill/storeBill', 'ios-american-football', 2, 'storeBill', '1357873097859923969', 'storeBill', '3.12', '店铺结算', '/store/order/bill*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367039950368800768, NULL, '2022-01-11 23:09:26.000000', b'0', NULL, '2022-01-11 23:09:29', NULL, 'Main', 'ios-american-football', 1, 'Main', '1357584224760102912', '/', '3.2', '发票管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367040067201138688, NULL, '2022-01-11 23:11:14.000000', b'0', NULL, '2022-01-11 23:11:18', NULL, 'order/receiptManager/receipt', 'ios-american-football', 2, 'receipt', '1367039950368800768', 'receipt', '3.21', '发票管理', '/store/trade/receipt*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367040599596728320, NULL, '2022-01-11 23:12:49.000000', b'0', NULL, '2022-01-11 23:12:52', NULL, 'Main', 'ios-american-football', 0, 'promotion', '0', '/', '4', '营销', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367040819248234496, NULL, '2022-01-11 23:14:35.000000', b'0', NULL, '2022-01-11 23:14:38', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367040599596728320', '/', '4.1', '平台活动', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367041332861730816, NULL, '2022-01-11 23:15:42.000000', b'0', NULL, '2022-01-11 23:15:48', NULL, 'promotion/pintuan/pintuan', 'ios-american-football', 2, 'pintuan', '1367040819248234496', 'pintuan', '4.11', '拼团活动', '/store/promotion/pintuan*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367041461194850304, NULL, '2022-01-11 23:17:32.000000', b'0', NULL, '2022-01-11 23:17:44', NULL, 'promotion/seckill/seckill', 'ios-american-football', 2, 'seckill', '1367040819248234496', 'seckill', '4.12', '秒杀活动', '/store/promotion/seckill*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367041575619657728, NULL, '2022-01-11 23:20:19.000000', b'0', NULL, '2022-01-11 23:20:24', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367040599596728320', '/', '4.2', '直播活动', '');
|
||||
INSERT INTO `li_store_menu` VALUES (1367042490443497472, NULL, '2022-01-11 23:21:13.000000', b'0', NULL, '2022-01-11 23:21:22', NULL, 'promotion/live/live', 'ios-american-football', 2, 'live', '1367041575619657728', 'live', '4.21', '直播管理', '/store/broadcast/studio*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367042664410644480, NULL, '2022-01-11 23:22:42.000000', b'0', NULL, '2022-01-11 23:22:59', NULL, 'promotion/live/liveGoods', 'ios-american-football', 2, 'liveGoods', '1367041575619657728', 'liveGoods', '4.22', '直播商品', '/store/broadcast/commodity*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367042804944994304, NULL, '2022-01-11 23:24:24.000000', b'0', NULL, '2022-01-11 23:24:38', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367040599596728320', '/', '4.3', '商家活动', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367042804944994305, NULL, '2022-01-11 23:24:29.000000', b'0', NULL, '2022-01-11 23:24:42', NULL, 'promotion/full-discount/full-discount', 'ios-american-football', 2, 'full-cut', '1367042804944994304', 'full-discount', '4.31', '满额活动', '/store/promotion/fullDiscount*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367042917113266176, NULL, '2022-01-11 23:26:45.000000', b'0', NULL, '2022-01-11 23:26:50', NULL, 'promotion/coupon/coupon', 'ios-american-football', 2, 'coupon', '1367042804944994304', 'coupon', '4.32', '优惠券', '/store/promotion/coupon*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367043020976816128, NULL, '2022-01-11 23:28:50.000000', b'0', NULL, '2022-01-11 23:29:02', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367040599596728320', '/', '4.4', '分销管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367043443917848576, NULL, '2022-01-11 23:28:53.000000', b'0', NULL, '2022-01-11 23:29:04', NULL, 'distribution/distributionGoods', 'ios-american-football', 2, 'distributionGoods', '1367043020976816128', 'distributionGoods', '4.41', '分销商品', '/store/distribution/goods*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367043505771249664, NULL, '2022-01-11 23:28:56.000000', b'0', NULL, '2022-01-11 23:29:07', NULL, 'distribution/distributionOrder', 'ios-american-football', 2, 'distributionOrder', '1367043020976816128', 'distributionOrderdistributionOrder', '4.42', '分销订单', '/store/distribution/order*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367044121163726848, NULL, '2022-01-12 21:47:03.000000', b'0', NULL, '2022-01-12 21:47:25', NULL, 'Main', 'ios-american-football', 0, 'statistics', '0', '/', '5', '统计', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367044247978508288, NULL, '2022-01-12 21:47:19.000000', b'0', NULL, '2022-01-12 21:47:28', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367044121163726848', '/', '5.1', '统计管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367044376391319552, NULL, '2022-01-12 21:49:45.000000', b'0', NULL, '2022-01-12 21:50:01', NULL, 'statistics/goods', 'ios-american-football', 2, 'goodsStatistics', '1367044247978508288', 'goodsStatistics', '5.11', '商品统计', '/store/statistics/goods*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367044657296441344, NULL, '2022-01-12 21:49:48.000000', b'0', NULL, '2022-01-12 21:49:58', NULL, 'statistics/order', 'ios-american-football', 2, 'orderStatistics', '1367044247978508288', 'orderStatistics', '5.12', '订单统计', '/store/statistics/order*,/store/statistics/order*,/store/statistics/order*,/store/statistics/order*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367045529720061952, NULL, '2022-01-12 21:49:51.000000', b'0', NULL, '2022-01-12 21:50:03', NULL, 'statistics/traffic', 'ios-american-football', 2, 'trafficStatistics', '1367044247978508288', 'trafficStatistics', '5.13', '流量统计', '/store/statistics/view*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367045630710513664, NULL, '2022-01-12 21:52:59.000000', b'0', NULL, '2022-01-12 21:53:09', NULL, 'Main', 'ios-american-football', 0, 'settings', '0', '/', '6', '设置', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367045794284175360, NULL, '2022-01-12 21:53:03.000000', b'0', NULL, '2022-01-12 21:53:12', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367045630710513664', '/', '6.1', '配送设置', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367045921434501120, NULL, '2022-01-12 21:55:49.000000', b'0', NULL, '2022-01-12 21:55:52', NULL, 'shop/ship/shipTemplate', 'ios-american-football', 2, 'shipTemplate', '1367045794284175360', 'shipTemplate', '6.11', '配送模板', '/store/setting/freightTemplate*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367046068369358848, NULL, '2022-01-12 21:58:05.000000', b'0', NULL, '2022-01-12 21:58:13', NULL, 'shop/ship/logistics', 'ios-american-football', 2, 'logistics', '1367045794284175360', 'logistics', '6.12', '物流公司', '/store/other/logistics*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367046266214678528, NULL, '2022-01-12 21:59:07.000000', b'0', NULL, '2022-01-12 21:59:43', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367045630710513664', '/', '6.2', '店铺管理', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367048084701315072, NULL, '2022-01-12 21:59:32.000000', b'0', NULL, '2022-01-12 21:59:48', NULL, 'shop/shopSetting', 'ios-american-football', 2, 'shopSetting', '1367046266214678528', 'shopSetting', '6.21', '店铺设置', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367048684339986432, NULL, '2022-01-12 21:59:36.000000', b'0', NULL, '2022-01-12 21:59:51', NULL, 'shop/shopAddress', 'ios-american-football', 2, 'shopAddress', '1367046266214678528', 'shopAddress', '6.22', '自提管理', '/store/member/storeAddress*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048754229673984, NULL, '2022-01-12 22:02:11.000000', b'0', NULL, '2022-01-12 22:04:36', NULL, 'Main', 'ios-american-football', 0, 'Main', '0', '/', '7', '消息', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367048832210173952, NULL, '2022-01-12 22:02:49.000000', b'0', NULL, '2022-01-12 22:04:39', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367048754229673984', '/', '7.1', '系统消息', NULL);
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861503, NULL, '2022-02-18 16:08:30.000000', b'0', NULL, '2022-02-18 16:08:36', NULL, 'Main', 'ios-american-football', 1, 'Main', '1367045630710513664', '/', '6.3', '店员设置', '');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861504, NULL, '2022-01-12 22:02:51.000000', b'0', NULL, '2022-01-12 22:04:45', NULL, 'message', 'ios-american-football', 2, 'message_index', '1367048832210173952', 'message', '7.11', '系统消息', '/store/message/storeMessage*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861505, NULL, '2022-02-18 16:12:18.000000', b'0', NULL, '2022-02-18 16:12:21', NULL, 'shop/system/clerk/clerkManage', 'ios-american-football', 2, '\nclerkManage', '1367048967635861503', '\nclerkManage', '6.31', '店员管理', '/store/department*,/store/clerk*,/store/role*,/store/department*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861506, NULL, '2022-02-18 16:25:27.000000', NULL, NULL, '2022-02-18 16:25:31', NULL, 'shop/system/department/storeDepartmentManage', 'ios-american-football', 2, 'storeDepartmentManage', '1367048967635861503', 'storeDepartmentManage', '6.32', '部门管理', '/store/department*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861507, NULL, '2022-02-18 16:27:28.000000', NULL, NULL, '2022-02-18 16:27:30', NULL, 'shop/system/role/storeRoleManage', 'ios-american-football', 2, 'storeRoleManage', '1367048967635861503', 'storeRoleManage', '6.33', '角色权限', '/store/role*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861510, NULL, '2022-03-07 14:45:10.000000', b'0', NULL, '2022-03-07 14:45:13', NULL, 'shop/floorList', 'ios-american-football', 2, 'floorList', '1367046266214678528', 'floorList', '6.23', 'PC端', '/store/other/pageData*');
|
||||
INSERT INTO `li_store_menu` VALUES (1367048967635861511, NULL, '2022-03-07 15:13:52.000000', b'0', NULL, '2022-03-07 15:13:55', NULL, 'shop/wap/wapList', 'ios-american-football', 2, 'wapList', '1367046266214678528', 'wapList', '6.24', '移动端', '/store/other/pageData*');
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
|
||||
insert li_clerk(id,create_by,create_time,store_id,clerk_name,member_id,shopkeeper,is_super,`status`) select id,member_name,current_date(),id,member_name,member_id ,TRUE,TRUE,TRUE from li_store
|
||||
|
||||
|
||||
91
DB/version4.2.5to4.3.sql
Normal file
91
DB/version4.2.5to4.3.sql
Normal file
@@ -0,0 +1,91 @@
|
||||
|
||||
/** 优惠券活动增加领取周期字段 **/
|
||||
ALTER TABLE li_coupon_activity ADD coupon_frequency_enum varchar(255) COMMENT '领取周期';
|
||||
-- 会员优惠券标识
|
||||
CREATE TABLE `li_member_coupon_sign` (
|
||||
`id` bigint NOT NULL,
|
||||
`coupon_activity_Id` bigint NULL DEFAULT NULL COMMENT '优惠券活动id',
|
||||
`member_id` bigint NULL DEFAULT NULL COMMENT '会员id',
|
||||
`invalid_time` datetime NULL DEFAULT NULL COMMENT '过期时间',
|
||||
`create_time` datetime NULL DEFAULT NULL COMMENT '创建时间',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB CHARACTER SET = utf8mb4 COLLATE = utf8mb4_bin ROW_FORMAT = DYNAMIC;
|
||||
|
||||
/**
|
||||
IM聊天
|
||||
*/
|
||||
CREATE TABLE `li_im_talk` (
|
||||
`id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) DEFAULT NULL COMMENT '删除标志',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '修改者',
|
||||
`update_time` datetime(6) DEFAULT NULL COMMENT '修改时间',
|
||||
`user_id1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户1Id',
|
||||
`user_id2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户2Id',
|
||||
`name1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户1名称',
|
||||
`name2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户2名称',
|
||||
`face1` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户1头像',
|
||||
`face2` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '用户2头像',
|
||||
`top1` bit(1) DEFAULT NULL COMMENT '用户1置顶标识',
|
||||
`top2` bit(1) DEFAULT NULL COMMENT '用户2置顶标识',
|
||||
`disable1` bit(1) DEFAULT NULL COMMENT '用户1禁用标识',
|
||||
`disable2` bit(1) DEFAULT NULL COMMENT '用户2禁用标识',
|
||||
`store_flag1` bit(1) DEFAULT NULL COMMENT '用户1店铺标识',
|
||||
`store_flag2` bit(1) DEFAULT NULL COMMENT '用户2店铺标识',
|
||||
`last_talk_time` datetime DEFAULT NULL COMMENT '最后聊天时间',
|
||||
`last_talk_message` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci COMMENT '最后的消息',
|
||||
`last_message_type` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '最后消息类型',
|
||||
`talk_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '聊天Id',
|
||||
`tenant_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '坐席Id',
|
||||
`tenant_name` varchar(255) COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '坐席名称',
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
|
||||
/**
|
||||
IM消息
|
||||
*/
|
||||
CREATE TABLE `li_im_message` (
|
||||
`id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci NOT NULL,
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) DEFAULT NULL COMMENT '删除标识',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '修改者',
|
||||
`update_time` datetime(6) DEFAULT NULL COMMENT '修改标识',
|
||||
`from_user` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '发送用户Id',
|
||||
`to_user` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '接收用户Id',
|
||||
`is_read` bit(1) DEFAULT NULL COMMENT '已读标识',
|
||||
`message_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '聊天类型',
|
||||
`text` text CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci COMMENT '聊天内容',
|
||||
`talk_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_unicode_ci DEFAULT NULL COMMENT '聊天Id',
|
||||
PRIMARY KEY (`id`)
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb4 COLLATE=utf8mb4_unicode_ci;
|
||||
|
||||
|
||||
|
||||
|
||||
/**
|
||||
订单增加自提信息
|
||||
*/
|
||||
ALTER TABLE li_order ADD `store_address_path` varchar(255) DEFAULT NULL;
|
||||
ALTER TABLE li_order ADD `store_address_center` varchar(255) DEFAULT NULL;
|
||||
ALTER TABLE li_order ADD `store_address_mobile` varchar(255) CHARACTER SET utf8 COLLATE utf8_general_ci DEFAULT NULL;
|
||||
|
||||
/**
|
||||
店铺是否开启自提
|
||||
*/
|
||||
ALTER TABLE li_store ADD `self_pick_flag` bit(1) DEFAULT NULL;
|
||||
/**
|
||||
历史足迹增加店铺Id
|
||||
*/
|
||||
ALTER TABLE li_foot_print ADD `store_id` varchar(255) DEFAULT NULL COMMENT '店铺ID';
|
||||
|
||||
|
||||
|
||||
/**
|
||||
用户提现申请增加字段
|
||||
*/
|
||||
ALTER TABLE li_member_withdraw_apply ADD `real_name` varchar(255) DEFAULT NULL;
|
||||
ALTER TABLE li_member_withdraw_apply ADD `connect_number` varchar(255) DEFAULT NULL;
|
||||
ALTER TABLE li_member_withdraw_apply ADD `error_message` text DEFAULT NULL;
|
||||
173
DB/version4.3to4.4.sql
Normal file
173
DB/version4.3to4.4.sql
Normal file
@@ -0,0 +1,173 @@
|
||||
CREATE TABLE `li_file_directory`
|
||||
(
|
||||
`id` bigint NOT NULL AUTO_INCREMENT COMMENT '主键ID',
|
||||
`create_time` datetime NULL DEFAULT CURRENT_TIMESTAMP COMMENT '创建时间',
|
||||
`create_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '创建者',
|
||||
`update_time` datetime NULL DEFAULT CURRENT_TIMESTAMP ON UPDATE CURRENT_TIMESTAMP COMMENT '更新时间',
|
||||
`update_by` varchar(64) CHARACTER SET utf8mb4 COLLATE utf8mb4_bin NULL DEFAULT NULL COMMENT '更新者',
|
||||
`delete_flag` tinyint(1) NULL DEFAULT 0 COMMENT '删除标志 true/false 删除/未删除',
|
||||
`directory_type` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '文件目录类型',
|
||||
`directory_name` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '拥有者名称',
|
||||
`owner_id` varchar(255) CHARACTER SET utf8mb4 COLLATE utf8mb4_0900_ai_ci NULL DEFAULT NULL COMMENT '拥有者id',
|
||||
`parent_id` bigint NULL DEFAULT NULL COMMENT '父分类ID',
|
||||
`level` int NULL DEFAULT NULL COMMENT '层级',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE = InnoDB
|
||||
AUTO_INCREMENT = 1698937596963311619
|
||||
CHARACTER SET = utf8mb4
|
||||
COLLATE = utf8mb4_0900_ai_ci COMMENT = '文件夹'
|
||||
ROW_FORMAT = DYNAMIC;
|
||||
|
||||
SET FOREIGN_KEY_CHECKS = 1;
|
||||
|
||||
ALTER TABLE li_file
|
||||
ADD file_directory_id varchar(255) COMMENT '文件夹ID';
|
||||
|
||||
/**
|
||||
订单包裹
|
||||
*/
|
||||
CREATE TABLE `li_order_package` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) DEFAULT NULL COMMENT '是否删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '修改者',
|
||||
`update_time` datetime(6) DEFAULT NULL COMMENT '修改时间',
|
||||
`package_no` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '包裹单号',
|
||||
`order_sn` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '订单编号',
|
||||
`logistics_no` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '发货单号',
|
||||
`logistics_code` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '物流公司CODE',
|
||||
`logistics_name` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '物流公司名称',
|
||||
`consignee_mobile` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '收件人手机',
|
||||
`status` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '状态',
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_bin ROW_FORMAT=DYNAMIC;
|
||||
|
||||
/**
|
||||
分包货物
|
||||
*/
|
||||
CREATE TABLE `li_order_package_item` (
|
||||
`id` bigint NOT NULL COMMENT 'ID',
|
||||
`create_by` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '创建者',
|
||||
`create_time` datetime(6) DEFAULT NULL COMMENT '创建时间',
|
||||
`delete_flag` bit(1) DEFAULT NULL COMMENT '是否删除',
|
||||
`update_by` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '修改者',
|
||||
`update_time` datetime(6) DEFAULT NULL COMMENT '修改时间',
|
||||
`package_no` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '包裹单号',
|
||||
`order_sn` varchar(255) CHARACTER SET utf8mb3 COLLATE utf8mb3_bin DEFAULT NULL COMMENT '订单编号',
|
||||
`order_item_sn` varchar(255) COLLATE utf8mb3_bin DEFAULT NULL COMMENT '子订单编号',
|
||||
`deliver_number` int DEFAULT NULL COMMENT '发货数量',
|
||||
`logistics_time` datetime(6) DEFAULT NULL COMMENT '发货时间',
|
||||
`goods_name` varchar(255) COLLATE utf8mb3_bin DEFAULT NULL,
|
||||
`thumbnail` varchar(255) COLLATE utf8mb3_bin DEFAULT NULL,
|
||||
PRIMARY KEY (`id`) USING BTREE
|
||||
) ENGINE=InnoDB DEFAULT CHARSET=utf8mb3 COLLATE=utf8mb3_bin ROW_FORMAT=DYNAMIC;
|
||||
|
||||
/*
|
||||
订单货物增加发货数量
|
||||
*/
|
||||
ALTER TABLE li_order_item ADD `deliver_number` int DEFAULT NULL COMMENT '发货数量';
|
||||
|
||||
/*
|
||||
sku增加预警库存
|
||||
*/
|
||||
ALTER TABLE li_goods_sku ADD `alert_quantity` int DEFAULT NULL COMMENT '预警库存';
|
||||
/*
|
||||
增加库存预警菜单
|
||||
*/
|
||||
INSERT INTO `lilishop`.`li_store_menu`(`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `description`, `front_route`, `icon`, `level`, `name`, `parent_id`, `path`, `sort_order`, `title`, `permission`) VALUES (1349237928434098177, NULL, '2022-01-11 22:35:45.000000', b'0', NULL, '2022-01-11 22:37:05', NULL, 'goods/goods-seller/alertQuantity', 'ios-american-football', 2, 'alert-goods-quantity', '1348810864748945408', 'alert-goods-quantity', '1.14', '库存预警', NULL);
|
||||
|
||||
/**
|
||||
交易唤醒表,增加交易流水详情
|
||||
*/
|
||||
ALTER TABLE li_order_item ADD `is_refund` varchar(255) DEFAULT NULL COMMENT '是否退款';
|
||||
|
||||
/**
|
||||
交易表增加订单状态字段
|
||||
*/
|
||||
ALTER TABLE li_order_item ADD `refund_price` decimal(10,2) DEFAULT NULL COMMENT '退款金额';
|
||||
|
||||
/**
|
||||
结算单表,增加砍价/积分退款金额字段
|
||||
*/
|
||||
ALTER TABLE li_bill ADD `point_refund_settlement_price` decimal(10,2) DEFAULT NULL COMMENT '退货积分补贴返还';
|
||||
ALTER TABLE li_bill ADD `kanjia_refund_settlement_price` decimal(10,2) DEFAULT NULL COMMENT '退货砍价补贴返还';
|
||||
|
||||
UPDATE li_bill b
|
||||
SET b.point_refund_settlement_price =IFNULL((
|
||||
SELECT
|
||||
SUM( point_settlement_price )
|
||||
FROM
|
||||
li_store_flow sf
|
||||
WHERE
|
||||
sf.flow_type = 'REFUND'
|
||||
AND sf.store_id=b.store_id
|
||||
AND sf.create_time BETWEEN b.start_time
|
||||
AND b.end_time),0);
|
||||
|
||||
UPDATE li_bill b
|
||||
SET b.kanjia_refund_settlement_price =IFNULL((
|
||||
SELECT
|
||||
SUM( kanjia_settlement_price )
|
||||
FROM
|
||||
li_store_flow sf
|
||||
WHERE
|
||||
sf.flow_type = 'REFUND'
|
||||
AND sf.store_id=b.store_id
|
||||
AND sf.create_time BETWEEN b.start_time
|
||||
AND b.end_time),0);
|
||||
|
||||
/**
|
||||
文件表增加拥有者名称
|
||||
*/
|
||||
ALTER TABLE li_file ADD `owner_name` varchar(255) DEFAULT NULL COMMENT '拥有者名称';
|
||||
|
||||
/**
|
||||
初始化文件拥有者名称
|
||||
*/
|
||||
UPDATE li_file f JOIN li_store s ON f.owner_id = s.id
|
||||
SET f.owner_name = s.store_name
|
||||
WHERE user_enums = 'STORE';
|
||||
|
||||
UPDATE li_file f JOIN li_admin_user a ON f.owner_id = a.id
|
||||
SET f.owner_name = a.nick_name
|
||||
WHERE user_enums = 'MANAGER';
|
||||
|
||||
UPDATE li_file f JOIN li_member m ON f.owner_id = m.id
|
||||
SET f.owner_name = m.nick_name
|
||||
WHERE user_enums = 'MEMBER';
|
||||
|
||||
ALTER TABLE `li_order`
|
||||
ADD COLUMN `seller_remark` varchar(255) NULL COMMENT '商家订单备注' AFTER `remark`;
|
||||
|
||||
|
||||
ALTER TABLE `li_distribution_cash`
|
||||
ADD COLUMN `name` varchar(255) NULL COMMENT '会员姓名';
|
||||
ALTER TABLE `li_distribution_cash`
|
||||
ADD COLUMN `id_number` varchar(255) NULL COMMENT '身份证号' ;
|
||||
ALTER TABLE `li_distribution_cash`
|
||||
ADD COLUMN `settlement_bank_account_name` varchar(255) NULL COMMENT '结算银行开户行名称' ;
|
||||
ALTER TABLE `li_distribution_cash`
|
||||
ADD COLUMN `settlement_bank_account_num` varchar(255) NULL COMMENT '结算银行开户账号' ;
|
||||
ALTER TABLE `li_distribution_cash`
|
||||
ADD COLUMN `settlement_bank_branch_name` varchar(255) NULL COMMENT '结算银行开户支行名称' ;
|
||||
|
||||
ALTER TABLE `li_distribution` ADD `distribution_order_price` decimal(10,2) DEFAULT NULL COMMENT '分销订单金额';
|
||||
|
||||
ALTER TABLE `li_distribution_order` ADD `refund_num` int DEFAULT NULL COMMENT '退款商品数量';
|
||||
|
||||
ALTER TABLE `li_store_flow` ADD `bill_time` datetime(6) DEFAULT NULL COMMENT '结算时间';
|
||||
ALTER TABLE `li_store_flow` ADD `full_refund` bit(1) DEFAULT NULL COMMENT '是否全部退款';
|
||||
ALTER TABLE `li_store_flow` ADD `profit_sharing_status` varchar(255) NULL COMMENT '分账状态';
|
||||
ALTER TABLE `li_store_flow` ADD `profit_sharing` varchar(255) NULL COMMENT '分账详情';
|
||||
|
||||
|
||||
|
||||
INSERT INTO `lilishop`.`li_setting` (`id`, `create_by`, `create_time`, `delete_flag`, `update_by`, `update_time`, `setting_value`) VALUES ('CONNECT_SETTING', 'admin', '2024-07-07 13:55:38.686000', b'0', NULL, NULL, '{\"callbackUrl\":\"https://buyer-api.pickmall.cn\",\"pc\":\"https://pc-b2b2c.pickmall.cn\",\"wap\":\"https://m-b2b2c.pickmall.cn\"}');
|
||||
UPDATE `lilishop`.`li_setting` SET `create_by` = 'admin', `create_time` = '2021-01-23 02:18:03.299000', `delete_flag` = b'0', `update_by` = 'admin', `update_time` = '2024-07-07 13:53:44.732000', `setting_value` = '{\"accessKeyId\":\"test\",\"tencentSdkAppId\":\"null\",\"registerTemplateCode\":\"SMS_205755298\",\"huaweiSender\":\"null\",\"signName\":\"lili\",\"tencentSecretId\":\"null\",\"huaweiAppKey\":\"null\",\"isTestModel\":\"true\",\"tencentSecretKey\":\"null\",\"type\":\"ALI\",\"accessSecret\":\"test\",\"tencentSignName\":\"null\",\"huaweiSignature\":\"null\",\"payPasswordTemplateCode\":\"SMS_205755301\",\"walletPasswordTemplateCode\":\"SMS_205755297\",\"findPasswordTemplateCode\":\"SMS_205755301\",\"huaweiAppSecret\":\"null\",\"loginTemplateCode\":\"SMS_205755300\"}' WHERE `id` = 'SMS_SETTING';
|
||||
|
||||
|
||||
|
||||
ALTER TABLE li_store_logistics ADD `partner_name` varchar(255) DEFAULT NULL COMMENT '电子面单客户账户名称';
|
||||
|
||||
|
||||
233
README.md
233
README.md
@@ -1,161 +1,166 @@
|
||||
## Lilishop B2B2C商城系统
|
||||
# Lilishop B2B2C 商城系统
|
||||
|
||||
##### 开源不易,如有帮助请点Star
|
||||
[](https://github.com/hongyehuicheng/lilishop)
|
||||
[](https://gitee.com/beijing_hongye_huicheng/lilishop)
|
||||
[](https://www.gnu.org/licenses/agpl-3.0.html)
|
||||
[](https://spring.io/projects/spring-boot)
|
||||
[](https://vuejs.org/)
|
||||
[](https://uniapp.dcloud.io/)
|
||||
|
||||
---
|
||||
|
||||
### 1. 项目简介
|
||||
|
||||
#### 欢迎交流需求,交流业务,交流技术(基础问题自行解决,进群先看文档后提问)
|
||||
**Lilishop** 是一款功能完善的B2B2C多商户商城系统,采用前后端分离架构,全端代码开源。后端基于 **SpringBoot** 构建,具备高内聚、低耦合的特性,支持分布式部署。前端覆盖PC、H5、小程序和APP,基于 **Vue** 和 **uni-app** 开发。
|
||||
|
||||
- **官方网站**: <https://pickmall.cn>
|
||||
- **官方文档**: <https://docs.pickmall.cn>
|
||||
- **Gitee 仓库**: <https://gitee.com/beijing_hongye_huicheng/lilishop>
|
||||
- **GitHub 仓库**: <https://github.com/lilishop/lilishop>
|
||||
|
||||
##### 交流 qq 1群 961316482(已满)
|
||||
<a target="_blank" href="https://qm.qq.com/cgi-bin/qm/qr?k=BAhURE3DG2YWhQk6kRxVapbLykqMoPS8&jump_from=webapi"><img border="0" src="https://pub.idqqimg.com/wpa/images/group.png" alt="Lilishop交流群" title="Lilishop交流群">点击快捷加群</a>
|
||||
> **聚合版**: 为简化部署,我们提供了API聚合版,仅需启动单个JAR包即可运行。详情请访问:[lilishop-simplify](https://gitee.com/beijing_hongye_huicheng/lilishop-simplify)
|
||||
|
||||
##### 交流 qq 2群 875294241
|
||||
---
|
||||
|
||||
<a target="_blank" href="https://qm.qq.com/cgi-bin/qm/qr?k=_lrekOvr5k2p5uTn5GRidI-chKEmpCX3&jump_from=webapi"><img border="0" src="https://pub.idqqimg.com/wpa/images/group.png" alt="Lilishop交流群2群" title="Lilishop交流群2群">点击快捷加群</a>
|
||||
### 2. 核心特性
|
||||
|
||||
- **全端覆盖**: 一套代码库支持PC、H5、小程序、APP,降低开发和维护成本。
|
||||
- **商家入驻**: 支持多商家入驻,构建平台化电商生态。
|
||||
- **分布式架构**: 后端API服务化,支持独立部署和弹性伸缩。
|
||||
- **前后端分离**: 清晰的职责划分,便于团队协作和独立开发。
|
||||
- **容器化支持**: 提供Docker镜像和docker-compose配置,实现一键部署。
|
||||
- **功能完善**: 涵盖会员、订单、商品、促销、店铺、运营、统计等完整电商业务模块。
|
||||
|
||||
##### 体验 公众号/小程序/APP 体验,扫描二维码
|
||||
---
|
||||
|
||||

|
||||
### 3. 在线演示
|
||||
|
||||
[](https://gitee.com/beijing_hongye_huicheng/lilishop/stargazers)
|
||||

|
||||
**注意**: 演示站手机验证码统一为 `111111`。演示环境部署于 `master` 分支。
|
||||
|
||||
- **平台管理端**: <https://admin-b2b2c.pickmall.cn>
|
||||
- 账号: `admin`
|
||||
- 密码: `123456`
|
||||
- **店铺管理端**: <https://store-b2b2c.pickmall.cn>
|
||||
- 账号: `13011111111`
|
||||
- 密码: `111111`
|
||||
- **商城PC端**: <https://pc-b2b2c.pickmall.cn>
|
||||
- **移动端 (H5/小程序/APP)**:
|
||||

|
||||
|
||||
### 商城介绍
|
||||
**官网**:https://pickmall.cn
|
||||
---
|
||||
|
||||
Lilishop商城系统支持商家入驻,后端基于SpringBoot 研发,前端使用 Vue、uniapp开发, **系统全端全部代码开源**
|
||||
### 4. 快速开始
|
||||
|
||||
商城前后端分离,支持分布式部署,支持Docker,各个API独立,并且有独立的消费者。
|
||||
#### 环境准备与部署
|
||||
详细的本地部署指南,请参考官方文档:
|
||||
[**部署文档 -> 环境准备**](https://docs.pickmall.cn/deploy/%E8%BF%90%E8%A1%8C%E7%8E%AF%E5%A2%83%E5%87%86%E5%A4%87.html)
|
||||
|
||||
### 商城 API/消费者 聚合版
|
||||
api不需要单独部署,只需启动一个jar包就可以正常运转 如有需要,可以点击跳转
|
||||
https://gitee.com/beijing_hongye_huicheng/lilishop-simplify
|
||||
#### 数据库初始化
|
||||
- **推荐方式**: 使用项目提供的 `docker-compose` 配置,可自动完成数据库(MySQL, Redis, Elasticsearch等)的部署与初始化。
|
||||
- **手动方式**: 如果您选择手动部署,SQL脚本位于以下地址。请确保获取与您代码版本一致的SQL文件。
|
||||
[**数据库脚本 (Gitee)**](https://gitee.com/beijing_hongye_huicheng/docker/tree/master/init/mysql)
|
||||
|
||||
### 商城 开发/使用/常见问题 帮助文档
|
||||
---
|
||||
|
||||
https://docs.pickmall.cn
|
||||
### 5. 技术架构
|
||||
|
||||
### 项目地址
|
||||
#### 5.1 架构图
|
||||

|
||||
|
||||
gitee : https://gitee.com/beijing_hongye_huicheng
|
||||
#### 5.2 后端技术栈
|
||||
|
||||
github 镜像: https://github.com/lilishop?tab=repositories
|
||||
| 技术 | 选型 | 备注/用途 |
|
||||
| :-------------- | :-------------- | :--------- |
|
||||
| 核心框架 | Spring Boot | 简化应用开发 |
|
||||
| ORM框架 | Mybatis-Plus | 数据持久化 |
|
||||
| 数据库 | MySQL | 关系型数据存储 |
|
||||
| 消息队列 | RocketMQ | 异步任务与解耦 |
|
||||
| 缓存 | Redis, MongoDB | 数据缓存与存储 |
|
||||
| 搜索引擎 | Elasticsearch | 商品搜索 |
|
||||
| 安全框架 | Spring Security | 认证与授权 |
|
||||
| 分库分表 | ShardingSphere | 数据水平扩展 |
|
||||
| 定时任务 | XXL-Job | 分布式任务调度 |
|
||||
| 认证方案 | JWT | Token |
|
||||
|
||||
商城UI 项目下3个文件夹
|
||||
buyer:买家PC端,seller:商家端,manager:后台管理端
|
||||
#### 5.3 前端技术栈
|
||||
|
||||
**管理端 (平台/商家)**
|
||||
|
||||
### 演示地址
|
||||
PS:手机验证码为 ‘111111’
|
||||
|
||||
**平台管理端**:https://admin-b2b2c.pickmall.cn 账号:admin/123456
|
||||
|
||||
**店铺管理端**:https://store-b2b2c.pickmall.cn 账号:13011111111/111111
|
||||
|
||||
**商城PC页面**:https://pc-b2b2c.pickmall.cn
|
||||
|
||||
**商城 小程序/公众号/APP**:扫描二维码
|
||||
|
||||

|
||||
|
||||
### 快速部署本地商城
|
||||
|
||||
[点击跳转](https://docs.pickmall.cn/deploy/%E8%BF%90%E8%A1%8C%E7%8E%AF%E5%A2%83%E5%87%86%E5%A4%87.html)
|
||||
|
||||
**商城数据库**
|
||||
使用docker-compose部署数据库,自动初始化数据库,不需要手动下载等操作
|
||||
|
||||
如果手动部署,才需要获取sql [点击跳转](https://gitee.com/beijing_hongye_huicheng/docker/tree/master/init/mysql) (PS:这里有与tag版本一致的sql,如果是历史版本,则docker项目也切换至历史版本获取sql即可,历史版本升级则根据java相聚的根目录DB目录下的升级sql,按需执行)。
|
||||
| 技术 | 选型 | 备注/用途 |
|
||||
| :--------- | :--------- | :--------- |
|
||||
| JS框架 | Vue.js | 核心框架 |
|
||||
| UI库 | iView | 界面组件 |
|
||||
| 状态管理 | Vuex | 全局状态管理 |
|
||||
| 路由 | Vue Router | 页面路由 |
|
||||
| HTTP客户端 | axios | API请求 |
|
||||
|
||||
**移动端 (H5/小程序/APP)**
|
||||
|
||||
| 技术 | 选型 | 备注/用途 |
|
||||
| :-------- | :------ | :------------- |
|
||||
| 核心框架 | uni-app | 跨平台开发框架 |
|
||||
| UI库 | uViewUI | 丰富的组件库 |
|
||||
| CSS预处理 | SCSS | 样式开发 |
|
||||
|
||||
### 功能列表
|
||||
|
||||
### 6. 功能清单
|
||||
|
||||
#### 6.1 平台管理端
|
||||
|
||||
#### 平台管理端功能
|
||||
| 模块 | 主要功能 |
|
||||
| :--- | :--------------------------------------------------------------------- |
|
||||
| 首页 | 数据看板、待办事项 |
|
||||
| 会员 | 会员管理、会员评价、积分管理、资金流水、充值管理 |
|
||||
| 订单 | 商品订单、虚拟订单、售后处理、订单投诉、收款与退款流水 |
|
||||
| 商品 | 商品管理、商品审核、分类、品牌、规格、计量单位管理 |
|
||||
| 促销 | 优惠券、秒杀、砍价、拼团、积分商品等营销活动 |
|
||||
| 店铺 | 店铺管理、入驻审核、结算管理、店铺对账 |
|
||||
| 运营 | 页面装修、分销管理、文章管理、意见反馈、站内信、短信配置 |
|
||||
| 统计 | 会员、订单、流量、商品销量等多维度统计 |
|
||||
| 设置 | 权限、角色、部门、管理员、系统参数、OSS、支付、物流、敏感词等基础配置 |
|
||||
|
||||

|
||||
#### 6.2 商家端
|
||||
|
||||
| 模块 | 主要功能 |
|
||||
| :--- | :----------------------------------------------------------- |
|
||||
| 首页 | 店铺看板、待办事项、公告 |
|
||||
| 商品 | 商品发布、商品管理、运费模板、店铺内分类 |
|
||||
| 订单 | 订单处理、评价管理、投诉处理、退款/退货申请 |
|
||||
| 财务 | 店铺对账、结算管理、发票管理 |
|
||||
| 促销 | 优惠券、满减、秒杀、拼团、分销商品管理 |
|
||||
| 统计 | 订单统计、流量分析、商品销量排行 |
|
||||
| 设置 | 物流配送、自提点、店铺信息、PC/移动端装修、店员与权限管理 |
|
||||
|
||||
---
|
||||
|
||||
#### 卖家功能
|
||||
### 7. 界面展示
|
||||
|
||||

|
||||
|
||||
|
||||
### 商城前端功能展示
|
||||
|
||||
#### 商城移动端
|
||||
|
||||
<img src="https://pickmall.cn/assets/imgs/other/app.gif" alt="移动端功能展示" style="zoom:50%;" />
|
||||
#### 移动端
|
||||
<img src="https://static.pickmall.cn/images/other/app.gif" alt="移动端功能展示" width="300"/>
|
||||
|
||||
#### 平台管理端
|
||||

|
||||
|
||||

|
||||
---
|
||||
|
||||
### 8. 开源与授权
|
||||
|
||||
### 技术选型
|
||||
1. **开源协议**: 本项目遵循 `AGPL-3.0` 开源协议。
|
||||
2. **使用范围**: 仅允许用于个人学习、研究和非商业用途。
|
||||
3. **禁止行为**: 禁止将本项目的代码和资源用于任何形式的商业销售。
|
||||
4. **商业授权**: 如需商业使用,必须获得官方授权。授权为一次性永久授权,并提供持续的版本升级服务。详情请联系官网客服。
|
||||
5. **软件著作权**: 本软件受国家计算机软件著作权保护(登记号:2021SR0805085)。
|
||||
|
||||
#### 架构图
|
||||
---
|
||||
|
||||

|
||||
### 9. 社区与支持
|
||||
|
||||
##### 后台技术选型
|
||||
我们欢迎任何形式的交流与贡献。在提问前,请先查阅 [官方文档](https://docs.pickmall.cn/) 和 [常见问题](https://docs.pickmall.cn/faq/常见问题.html),并参考 [《提问的智慧》](https://github.com/ryanhanwu/How-To-Ask-Questions-The-Smart-Way/blob/master/README-zh_CN.md) 以便高效沟通。
|
||||
|
||||
| 说明 | 框架 | 说明 | |
|
||||
| -------------- | --------------- | -------------- | ------------- |
|
||||
| 基础框架 | Spring Boot | MVC框架 | Spring MVC |
|
||||
| 持久框架 | Mybatis-Plus | 程序构建 | Maven |
|
||||
| 关系型数据库 | MySQL | 消息中间件AMQP | RocketMQ |
|
||||
| 缓存 | Redis +MongoDB | 搜索引擎 | Elasticsearch |
|
||||
| 安全框架 | Spring Security | 数据库连接池 | Druid |
|
||||
| 数据库分库分表 | sharding | 定时任务 | xxl-job |
|
||||
| 负载均衡 | Nginx | 静态资源 | 阿里云OSS |
|
||||
| 短信 | 阿里云短信 | 认证 | JWT |
|
||||
| 日志处理 | Log4j | 接口规范 | RESTful |
|
||||
|
||||
##### 前端-运营后台、店铺后台
|
||||
|
||||
| 说明 | 框架 | 说明 | 框架 |
|
||||
| ---------- | ---------- | ---------- | ------- |
|
||||
| 构建工具 | webpack | JS版本 | ES6 |
|
||||
| 基础JS框架 | Vue.js | 视频播放器 | Dplayer |
|
||||
| 路由管理 | Vue Router | 状态管理 | Vuex |
|
||||
| 基础UI库 | iView | UI界面基于 | iView |
|
||||
| 网络请求 | axios | | |
|
||||
|
||||
##### 前端-移动端
|
||||
|
||||
| 说明 | 架构 | 说明 | 架构 |
|
||||
| --------- | ------- | -------- | ------- |
|
||||
| 基础UI库 | uViewui | 基础框架 | uni-app |
|
||||
| CSS预处理 | scss | 地图引擎 | amap |
|
||||
|
||||
### 版本升级
|
||||
|
||||
```
|
||||
商城后续会持续版本升级,修复bug,完善功能,覆盖更多业务场景 o2o/b2b/s2b2b2c/跨境电商
|
||||
|
||||
后续会考虑推出微服务商城系统/商城中台等
|
||||
```
|
||||
|
||||
|
||||
### 开源须知
|
||||
1.仅允许用于个人学习研究使用.
|
||||
|
||||
2.禁止将本开源的代码和资源进行任何形式任何名义的出售.
|
||||
|
||||
3.软件受国家计算机软件著作权保护(登记号:2021SR0805085)。
|
||||
|
||||
4.限制商用,如果需要商业使用请联系我们。QQ3409056806.
|
||||
|
||||
|
||||
### 交流群
|
||||
|
||||
##### 官方qq 1群 961316482(已满)
|
||||
##### 官方qq 2群 875294241
|
||||
- **微信交流群**:
|
||||

|
||||
|
||||
- **社区贡献内容**:
|
||||
- 清晨敲代码的分析: <https://blog.csdn.net/vaevaevae233/category_12103567.html>
|
||||
- DeepWiki: <https://deepwiki.com/lilishop/lilishop>
|
||||
@@ -32,10 +32,10 @@
|
||||
<artifactId>logstash-logback-encoder</artifactId>
|
||||
<version>${logstash-logback-encoder}</version>
|
||||
</dependency>
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>org.springframework.boot</groupId>-->
|
||||
<!-- <artifactId>spring-boot-starter-mail</artifactId>-->
|
||||
<!-- </dependency> -->
|
||||
<!-- <dependency>-->
|
||||
<!-- <groupId>org.springframework.boot</groupId>-->
|
||||
<!-- <artifactId>spring-boot-starter-mail</artifactId>-->
|
||||
<!-- </dependency> -->
|
||||
</dependencies>
|
||||
|
||||
<build>
|
||||
|
||||
@@ -16,5 +16,6 @@ spring.mail.username=1814994716@qq.com
|
||||
spring.mail.password=abcdefg123456!@#$%^
|
||||
# 日志文件路径
|
||||
logging.file.path=lili-logs/admin
|
||||
lili.data.logstash.server=106.124.130.167:4560
|
||||
# 文件格式
|
||||
logging.pattern.file=%clr(%d{yyyy-MM-dd HH:mm:ss.SSS}){faint} %clr(%5p) %clr(${PID}){magenta} %clr(---){faint} %clr([%15.15t]){faint} %clr(%-40.40logger{39}){cyan} %clr(:){faint} %m%n%wEx
|
||||
|
||||
@@ -29,6 +29,7 @@ public class BuyerApiApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
System.setProperty("es.set.netty.runtime.available.processors", "false");
|
||||
System.setProperty("rocketmq.client.logUseSlf4j","true");
|
||||
SpringApplication.run(BuyerApiApplication.class, args);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -54,22 +54,22 @@ public class DistributionGoodsBuyerController {
|
||||
@PreventDuplicateSubmissions
|
||||
@ApiOperation(value = "选择分销商品")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "distributionGoodsId", value = "分销ID", required = true, dataType = "String", paramType = "path"),
|
||||
@ApiImplicitParam(name = "distributionGoodsId", value = "分销ID", required = true, dataType = "String", paramType = "path"),
|
||||
@ApiImplicitParam(name = "checked", value = "是否选择", required = true, dataType = "boolean", paramType = "query")
|
||||
})
|
||||
@GetMapping(value = "/checked/{distributionGoodsId}")
|
||||
public ResultMessage<Object> distributionCheckGoods(
|
||||
@NotNull(message = "分销商品不能为空") @PathVariable("distributionGoodsId") String distributionGoodsId,Boolean checked) {
|
||||
Boolean result=false;
|
||||
if(checked){
|
||||
result=distributionSelectedGoodsService.add(distributionGoodsId);
|
||||
}else {
|
||||
result=distributionSelectedGoodsService.delete(distributionGoodsId);
|
||||
@NotNull(message = "分销商品不能为空") @PathVariable("distributionGoodsId") String distributionGoodsId, Boolean checked) {
|
||||
Boolean result = false;
|
||||
if (checked) {
|
||||
result = distributionSelectedGoodsService.add(distributionGoodsId);
|
||||
} else {
|
||||
result = distributionSelectedGoodsService.delete(distributionGoodsId);
|
||||
}
|
||||
//判断操作结果
|
||||
if(result){
|
||||
if (result) {
|
||||
return ResultUtil.success(ResultCode.SUCCESS);
|
||||
}else{
|
||||
} else {
|
||||
throw new ServiceException(ResultCode.ERROR);
|
||||
}
|
||||
|
||||
|
||||
@@ -6,6 +6,7 @@ import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.goods.entity.dos.Goods;
|
||||
import cn.lili.modules.goods.entity.dos.GoodsSku;
|
||||
import cn.lili.modules.goods.entity.dto.GoodsSearchParams;
|
||||
import cn.lili.modules.goods.entity.vos.GoodsVO;
|
||||
import cn.lili.modules.goods.service.GoodsService;
|
||||
@@ -14,17 +15,17 @@ import cn.lili.modules.search.entity.dos.EsGoodsIndex;
|
||||
import cn.lili.modules.search.entity.dos.EsGoodsRelatedInfo;
|
||||
import cn.lili.modules.search.entity.dto.EsGoodsSearchDTO;
|
||||
import cn.lili.modules.search.service.EsGoodsSearchService;
|
||||
import cn.lili.modules.search.service.HotWordsService;
|
||||
import cn.lili.modules.statistics.aop.PageViewPoint;
|
||||
import cn.lili.modules.statistics.aop.enums.PageViewEnum;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.domain.Page;
|
||||
import org.springframework.data.elasticsearch.core.SearchPage;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
@@ -62,6 +63,9 @@ public class GoodsBuyerController {
|
||||
@Autowired
|
||||
private EsGoodsSearchService goodsSearchService;
|
||||
|
||||
@Autowired
|
||||
private HotWordsService hotWordsService;
|
||||
|
||||
@ApiOperation(value = "通过id获取商品信息")
|
||||
@ApiImplicitParam(name = "goodsId", value = "商品ID", required = true, paramType = "path", dataType = "Long")
|
||||
@GetMapping(value = "/get/{goodsId}")
|
||||
@@ -98,12 +102,17 @@ public class GoodsBuyerController {
|
||||
return ResultUtil.data(goodsService.queryByParams(goodsSearchParams));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取商品sku列表")
|
||||
@GetMapping("/sku")
|
||||
public ResultMessage<List<GoodsSku>> getSkuByPage(GoodsSearchParams goodsSearchParams) {
|
||||
return ResultUtil.data(goodsSkuService.getGoodsSkuByList(goodsSearchParams));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "从ES中获取商品信息")
|
||||
@GetMapping("/es")
|
||||
public ResultMessage<SearchPage<EsGoodsIndex>> getGoodsByPageFromEs(EsGoodsSearchDTO goodsSearchParams, PageVO pageVO) {
|
||||
public ResultMessage<Page<EsGoodsIndex>> getGoodsByPageFromEs(EsGoodsSearchDTO goodsSearchParams, PageVO pageVO) {
|
||||
pageVO.setNotConvert(true);
|
||||
SearchPage<EsGoodsIndex> esGoodsIndices = goodsSearchService.searchGoods(goodsSearchParams, pageVO);
|
||||
return ResultUtil.data(esGoodsIndices);
|
||||
return ResultUtil.data(goodsSearchService.searchGoodsByPage(goodsSearchParams, pageVO));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "从ES中获取相关商品品牌名称,分类名称及属性")
|
||||
@@ -117,7 +126,7 @@ public class GoodsBuyerController {
|
||||
@ApiOperation(value = "获取搜索热词")
|
||||
@GetMapping("/hot-words")
|
||||
public ResultMessage<List<String>> getGoodsHotWords(Integer count) {
|
||||
List<String> hotWords = goodsSearchService.getHotWords(count);
|
||||
List<String> hotWords = hotWordsService.getHotWords(count);
|
||||
return ResultUtil.data(hotWords);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,13 +1,17 @@
|
||||
package cn.lili.controller.member;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.entity.dto.FootPrintQueryParams;
|
||||
import cn.lili.modules.member.service.FootprintService;
|
||||
import cn.lili.modules.search.entity.dos.EsGoodsIndex;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.apache.catalina.User;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
@@ -34,8 +38,9 @@ public class FootprintController {
|
||||
|
||||
@ApiOperation(value = "分页获取")
|
||||
@GetMapping
|
||||
public ResultMessage<List<EsGoodsIndex>> getByPage(PageVO page) {
|
||||
return ResultUtil.data(footprintService.footPrintPage(page));
|
||||
public ResultMessage<IPage<EsGoodsIndex>> getByPage(FootPrintQueryParams params) {
|
||||
params.setMemberId(UserContext.getCurrentUser().getId());
|
||||
return ResultUtil.data(footprintService.footPrintPage(params));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "根据id删除")
|
||||
@@ -60,4 +65,10 @@ public class FootprintController {
|
||||
return ResultUtil.data(footprintService.getFootprintNum());
|
||||
}
|
||||
|
||||
|
||||
@GetMapping("/history")
|
||||
@ApiOperation(value = "获取会员的历史足迹")
|
||||
public ResultMessage<IPage<EsGoodsIndex>> getMemberHistory(FootPrintQueryParams params) {
|
||||
return ResultUtil.data(footprintService.footPrintPage(params));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -59,7 +59,7 @@ public class MemberAddressBuyerController {
|
||||
public ResultMessage<MemberAddress> addShippingAddress(@Valid MemberAddress shippingAddress) {
|
||||
//添加会员地址
|
||||
shippingAddress.setMemberId(Objects.requireNonNull(UserContext.getCurrentUser()).getId());
|
||||
if(shippingAddress.getIsDefault()==null){
|
||||
if(Objects.isNull(shippingAddress.getIsDefault())){
|
||||
shippingAddress.setIsDefault(false);
|
||||
}
|
||||
return ResultUtil.data(memberAddressService.saveMemberAddress(shippingAddress));
|
||||
@@ -68,6 +68,8 @@ public class MemberAddressBuyerController {
|
||||
@ApiOperation(value = "修改会员收件地址")
|
||||
@PutMapping
|
||||
public ResultMessage<MemberAddress> editShippingAddress(@Valid MemberAddress shippingAddress) {
|
||||
OperationalJudgment.judgment(memberAddressService.getById(shippingAddress.getId()));
|
||||
shippingAddress.setMemberId(Objects.requireNonNull(UserContext.getCurrentUser()).getId());
|
||||
return ResultUtil.data(memberAddressService.updateMemberAddress(shippingAddress));
|
||||
}
|
||||
|
||||
|
||||
@@ -1,96 +0,0 @@
|
||||
package cn.lili.controller.member;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.service.GoodsCollectionService;
|
||||
import cn.lili.modules.member.service.StoreCollectionService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 买家端,会员收藏接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/17 2:32 下午
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "买家端,会员收藏接口")
|
||||
@RequestMapping("/buyer/member/collection")
|
||||
public class MemberCollectionController {
|
||||
|
||||
/**
|
||||
* 会员商品收藏
|
||||
*/
|
||||
@Autowired
|
||||
private GoodsCollectionService goodsCollectionService;
|
||||
/**
|
||||
* 会员店铺
|
||||
*/
|
||||
@Autowired
|
||||
private StoreCollectionService storeCollectionService;
|
||||
|
||||
/**
|
||||
* 商品收藏关键字
|
||||
*/
|
||||
private String goods="GOODS";
|
||||
|
||||
@ApiOperation(value = "查询会员收藏列表")
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺")
|
||||
@GetMapping("/{type}")
|
||||
public ResultMessage<Object> goodsList(@PathVariable String type, PageVO page) {
|
||||
if (goods.equals(type)) {
|
||||
return ResultUtil.data(goodsCollectionService.goodsCollection(page));
|
||||
}
|
||||
return ResultUtil.data(storeCollectionService.storeCollection(page));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "添加会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺"),
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@PostMapping("/add/{type}/{id}")
|
||||
public ResultMessage<Object> addGoodsCollection(@PathVariable String type,
|
||||
@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
if (goods.equals(type)) {
|
||||
return ResultUtil.data(goodsCollectionService.addGoodsCollection(id));
|
||||
}
|
||||
return ResultUtil.data(storeCollectionService.addStoreCollection(id));
|
||||
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺"),
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@DeleteMapping(value = "/delete/{type}/{id}")
|
||||
public ResultMessage<Object> deleteGoodsCollection(@PathVariable String type,
|
||||
@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
if (goods.equals(type)) {
|
||||
return ResultUtil.data(goodsCollectionService.deleteGoodsCollection(id));
|
||||
}
|
||||
return ResultUtil.data(storeCollectionService.deleteStoreCollection(id));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询会员是否收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺"),
|
||||
@ApiImplicitParam(name = "id", value = "值", dataType = "String", paramType = "path")
|
||||
})
|
||||
@GetMapping(value = "/isCollection/{type}/{id}")
|
||||
public ResultMessage<Boolean> isCollection(@PathVariable String type,
|
||||
@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
if (goods.equals(type)) {
|
||||
return ResultUtil.data(this.goodsCollectionService.isCollection(id));
|
||||
}
|
||||
return ResultUtil.data(this.storeCollectionService.isCollection(id));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,68 @@
|
||||
package cn.lili.controller.member;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.service.GoodsCollectionService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 买家端,会员收藏接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/17 2:32 下午
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "买家端,会员商品收藏接口")
|
||||
@RequestMapping("/buyer/member/collection")
|
||||
public class MemberCollectionGoodsController {
|
||||
|
||||
/**
|
||||
* 会员商品收藏
|
||||
*/
|
||||
@Autowired
|
||||
private GoodsCollectionService goodsCollectionService;
|
||||
|
||||
@ApiOperation(value = "查询会员收藏列表")
|
||||
@GetMapping("/GOODS")
|
||||
public ResultMessage<Object> goodsList(PageVO page) {
|
||||
return ResultUtil.data(goodsCollectionService.goodsCollection(page));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "添加会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@PostMapping("/add/GOODS/{id}")
|
||||
public ResultMessage<Object> addGoodsCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(goodsCollectionService.addGoodsCollection(id));
|
||||
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺"),
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@DeleteMapping(value = "/delete/GOODS/{id}")
|
||||
public ResultMessage<Object> deleteGoodsCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(goodsCollectionService.deleteGoodsCollection(id));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询会员是否收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "类型", dataType = "String", paramType = "path", example = "GOODS:商品,STORE:店铺"),
|
||||
@ApiImplicitParam(name = "id", value = "值", dataType = "String", paramType = "path")
|
||||
})
|
||||
@GetMapping(value = "/isCollection/GOODS/{id}")
|
||||
public ResultMessage<Boolean> isCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(this.goodsCollectionService.isCollection(id));
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,66 @@
|
||||
package cn.lili.controller.member;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.service.StoreCollectionService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
|
||||
/**
|
||||
* 买家端,会员收藏接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/17 2:32 下午
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "买家端,会员店铺收藏接口")
|
||||
@RequestMapping("/buyer/member/storeCollection")
|
||||
public class MemberCollectionStoreController {
|
||||
|
||||
/**
|
||||
* 会员店铺
|
||||
*/
|
||||
@Autowired
|
||||
private StoreCollectionService storeCollectionService;
|
||||
|
||||
@ApiOperation(value = "查询会员收藏列表")
|
||||
@GetMapping("/STORE")
|
||||
public ResultMessage<Object> goodsList(PageVO page) {
|
||||
return ResultUtil.data(storeCollectionService.storeCollection(page));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "添加会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@PostMapping("/add/STORE/{id}")
|
||||
public ResultMessage<Object> addGoodsCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(storeCollectionService.addStoreCollection(id));
|
||||
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除会员收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "num", value = "值", dataType = "Long", paramType = "path")
|
||||
})
|
||||
@DeleteMapping(value = "/delete/STORE/{id}")
|
||||
public ResultMessage<Object> deleteGoodsCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(storeCollectionService.deleteStoreCollection(id));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询会员是否收藏")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "id", value = "值", dataType = "String", paramType = "path")
|
||||
})
|
||||
@GetMapping(value = "/isCollection/STORE/{id}")
|
||||
public ResultMessage<Boolean> isCollection(@NotNull(message = "值不能为空") @PathVariable String id) {
|
||||
return ResultUtil.data(this.storeCollectionService.isCollection(id));
|
||||
}
|
||||
}
|
||||
@@ -48,7 +48,7 @@ public class MemberEvaluationBuyerController {
|
||||
@ApiOperation(value = "查看会员评价详情")
|
||||
@ApiImplicitParam(name = "id", value = "评价ID", required = true, paramType = "path")
|
||||
@GetMapping(value = "/get/{id}")
|
||||
public ResultMessage<MemberEvaluationVO> save(@NotNull(message = "评价ID不能为空") @PathVariable("id") String id) {
|
||||
public ResultMessage<MemberEvaluationVO> get(@NotNull(message = "评价ID不能为空") @PathVariable("id") String id) {
|
||||
return ResultUtil.data(memberEvaluationService.queryById(id));
|
||||
|
||||
}
|
||||
|
||||
@@ -1,5 +1,6 @@
|
||||
package cn.lili.controller.member;
|
||||
|
||||
import cn.lili.cache.limit.annotation.LimitPoint;
|
||||
import cn.lili.common.aop.annotation.PreventDuplicateSubmissions;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
|
||||
@@ -189,20 +189,38 @@ public class CartController {
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "选择自提地址")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "storeAddressId", value = "自提地址id ", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "way", value = "购物车类型 ", paramType = "query")
|
||||
})
|
||||
@GetMapping("/storeAddress")
|
||||
public ResultMessage<Object> shippingSelfPickAddress(@NotNull(message = "自提地址ID不能为空") String storeAddressId,
|
||||
String way) {
|
||||
try {
|
||||
cartService.shippingSelfAddress(storeAddressId, way);
|
||||
return ResultUtil.success();
|
||||
} catch (ServiceException se) {
|
||||
log.error(ResultCode.SHIPPING_NOT_APPLY.message(), se);
|
||||
throw new ServiceException(ResultCode.SHIPPING_NOT_APPLY);
|
||||
} catch (Exception e) {
|
||||
log.error(ResultCode.CART_ERROR.message(), e);
|
||||
throw new ServiceException(ResultCode.CART_ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "选择配送方式")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "shippingMethod", value = "配送方式:SELF_PICK_UP(自提)," +
|
||||
"LOCAL_TOWN_DELIVERY(同城配送)," +
|
||||
"LOGISTICS(物流) ", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "selleId", value = "店铺id", paramType = "query"),
|
||||
@ApiImplicitParam(name = "way", value = "购物车类型 ", paramType = "query")
|
||||
})
|
||||
@GetMapping("/shippingMethod")
|
||||
@PutMapping("/shippingMethod")
|
||||
public ResultMessage<Object> shippingMethod(@NotNull(message = "配送方式不能为空") String shippingMethod,
|
||||
String selleId,
|
||||
String way) {
|
||||
try {
|
||||
cartService.shippingMethod(selleId, shippingMethod, way);
|
||||
cartService.shippingMethod( shippingMethod, way);
|
||||
return ResultUtil.success();
|
||||
} catch (ServiceException se) {
|
||||
log.error(se.getMsg(), se);
|
||||
@@ -213,6 +231,21 @@ public class CartController {
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取用户可选择的物流方式")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "way", value = "购物车类型 ", paramType = "query")
|
||||
})
|
||||
@GetMapping("/shippingMethodList")
|
||||
public ResultMessage<Object> shippingMethodList(String way) {
|
||||
try {
|
||||
return ResultUtil.data(cartService.shippingMethodList(way));
|
||||
}
|
||||
catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
return ResultUtil.error(ResultCode.ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "选择发票")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "way", value = "购物车购买:CART/立即购买:BUY_NOW/拼团购买:PINTUAN / 积分购买:POINT ", required = true, paramType = "query"),
|
||||
|
||||
@@ -9,11 +9,14 @@ import cn.lili.common.security.OperationalJudgment;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dos.OrderPackage;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderSearchParams;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.vo.OrderDetailVO;
|
||||
import cn.lili.modules.order.order.entity.vo.OrderSimpleVO;
|
||||
import cn.lili.modules.order.order.service.OrderPackageService;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.system.entity.vo.Traces;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
@@ -44,6 +47,9 @@ public class OrderBuyerController {
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
|
||||
@Autowired
|
||||
private OrderPackageService orderPackageService;
|
||||
|
||||
@ApiOperation(value = "查询会员订单列表")
|
||||
@GetMapping
|
||||
public ResultMessage<IPage<OrderSimpleVO>> queryMineOrder(OrderSearchParams orderSearchParams) {
|
||||
@@ -116,6 +122,16 @@ public class OrderBuyerController {
|
||||
return ResultUtil.data(orderService.getTraces(orderSn));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询地图版物流踪迹")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "orderSn", value = "订单编号", required = true, dataType = "String", paramType = "path")
|
||||
})
|
||||
@PostMapping(value = "/getMapTraces/{orderSn}")
|
||||
public ResultMessage<Object> getMapTraces(@NotBlank(message = "订单编号不能为空") @PathVariable String orderSn) {
|
||||
OperationalJudgment.judgment(orderService.getBySn(orderSn));
|
||||
return ResultUtil.data(orderService.getMapTraces(orderSn));
|
||||
}
|
||||
|
||||
|
||||
@PreventDuplicateSubmissions
|
||||
@ApiOperation(value = "开票")
|
||||
@@ -128,5 +144,21 @@ public class OrderBuyerController {
|
||||
return ResultUtil.data(orderService.invoice(orderSn));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查询物流踪迹")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "orderSn", value = "订单编号", required = true, dataType = "String", paramType = "path")
|
||||
})
|
||||
@GetMapping(value = "/getTracesList/{orderSn}")
|
||||
public ResultMessage<Object> getTracesList(@NotBlank(message = "订单编号不能为空") @PathVariable String orderSn) {
|
||||
return ResultUtil.data(orderPackageService.getOrderPackageVOList(orderSn));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "查看包裹列表")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "orderSn", value = "订单编号", required = true, dataType = "String", paramType = "path")
|
||||
})
|
||||
@GetMapping(value = "/getPackage/{orderSn}")
|
||||
public ResultMessage<Object> getPackage(@NotBlank(message = "订单编号不能为空") @PathVariable String orderSn) {
|
||||
return ResultUtil.data(orderPackageService.getOrderPackageVOList(orderSn));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -82,7 +82,7 @@ public class OrderComplaintBuyerController {
|
||||
@PostMapping("/communication")
|
||||
public ResultMessage<OrderComplaintCommunicationVO> addCommunication(@RequestParam String complainId, @RequestParam String content) {
|
||||
AuthUser currentUser = Objects.requireNonNull(UserContext.getCurrentUser());
|
||||
OrderComplaintCommunicationVO communicationVO = new OrderComplaintCommunicationVO(complainId, content, CommunicationOwnerEnum.BUYER.name(), currentUser.getId(), currentUser.getNickName());
|
||||
OrderComplaintCommunicationVO communicationVO = new OrderComplaintCommunicationVO(complainId, content, CommunicationOwnerEnum.BUYER.name(), currentUser.getNickName(), currentUser.getId());
|
||||
orderComplaintCommunicationService.addCommunication(communicationVO);
|
||||
return ResultUtil.data(communicationVO);
|
||||
}
|
||||
|
||||
@@ -10,6 +10,7 @@ import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
@@ -26,6 +27,7 @@ import javax.validation.constraints.Min;
|
||||
@RestController
|
||||
@Api(tags = "买家端,预存款充值记录接口")
|
||||
@RequestMapping("/buyer/trade/recharge")
|
||||
@Validated
|
||||
public class RechargeTradeBuyerController {
|
||||
|
||||
@Autowired
|
||||
@@ -37,7 +39,10 @@ public class RechargeTradeBuyerController {
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "price", value = "充值金额", required = true, dataType = "double", paramType = "query")
|
||||
})
|
||||
public ResultMessage<Recharge> create(@Max(value = 10000, message = "充值金额单次最多允许充值10000元") @Min(value = 1, message = "充值金额单次最少充值金额为1元") Double price) {
|
||||
public ResultMessage<Recharge> create(
|
||||
@Max(value = 10000, message = "充值金额单次最多允许充值10000元")
|
||||
@Min(value = 1, message = "充值金额单次最少充值金额为1元")
|
||||
Double price) {
|
||||
Recharge recharge = this.rechargeService.recharge(price);
|
||||
return ResultUtil.data(recharge);
|
||||
}
|
||||
|
||||
@@ -2,17 +2,17 @@ package cn.lili.controller.other;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.page.entity.dos.PageData;
|
||||
import cn.lili.modules.page.entity.dto.PageDataDTO;
|
||||
import cn.lili.modules.page.entity.enums.PageEnum;
|
||||
import cn.lili.modules.page.entity.vos.PageDataVO;
|
||||
import cn.lili.modules.page.service.PageDataService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RequestParam;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 买家端,页面接口
|
||||
@@ -36,12 +36,63 @@ public class PageBuyerController {
|
||||
public ResultMessage<PageDataVO> getIndex(@RequestParam String clientType) {
|
||||
PageDataDTO pageDataDTO = new PageDataDTO(PageEnum.INDEX.name());
|
||||
pageDataDTO.setPageClientType(clientType);
|
||||
return ResultUtil.data(pageService.getPageData(pageDataDTO));
|
||||
PageDataVO pageDataVO=pageService.getPageData(pageDataDTO);
|
||||
return ResultUtil.data(pageDataVO);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取页面数据")
|
||||
@GetMapping
|
||||
public ResultMessage<PageDataVO> get(PageDataDTO pageDataDTO) {
|
||||
return ResultUtil.data(pageService.getPageData(pageDataDTO));
|
||||
PageDataVO pageDataVO=pageService.getPageData(pageDataDTO);
|
||||
return ResultUtil.data(pageDataVO);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取店铺首页")
|
||||
@GetMapping("/getStore")
|
||||
public ResultMessage<PageDataVO> getShopPage(@RequestParam String clientType,String storeId) {
|
||||
PageDataDTO pageDataDTO = new PageDataDTO(PageEnum.STORE.name());
|
||||
pageDataDTO.setPageClientType(clientType);
|
||||
pageDataDTO.setNum(storeId);
|
||||
PageDataVO pageDataVO=pageService.getPageData(pageDataDTO);
|
||||
return ResultUtil.data(pageDataVO);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取页面数据")
|
||||
@ApiImplicitParam(name = "id", value = "id", required = true, dataType = "String", paramType = "path")
|
||||
@GetMapping("/get/{id}")
|
||||
public ResultMessage<PageData> getPage(@PathVariable("id") String id) {
|
||||
return ResultUtil.data(pageService.getSpecial(id));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取专题页面数据(根据消息内容得知)")
|
||||
@GetMapping("/getSpecial")
|
||||
public ResultMessage<PageData> getSpecial(@RequestParam String body) {
|
||||
String name = "";
|
||||
if (body.indexOf("』") >= 0 && body.indexOf("『") >= 0) {
|
||||
name = body.substring(body.indexOf("『") + 1, body.lastIndexOf("』"));
|
||||
} else if (body.indexOf("〉") >= 0 && body.indexOf("〈") >= 0) {
|
||||
name = body.substring(body.indexOf("〈") + 1, body.lastIndexOf("〉"));
|
||||
} else if (body.indexOf("」") >= 0 && body.indexOf("「") >= 0) {
|
||||
name = body.substring(body.indexOf("「") + 1, body.lastIndexOf("」"));
|
||||
} else if (body.indexOf("》") >= 0 && body.indexOf("《") >= 0) {
|
||||
name = body.substring(body.indexOf("《") + 1, body.lastIndexOf("》"));
|
||||
} else if (body.indexOf(")") >= 0 && body.indexOf("(") >= 0) {
|
||||
name = body.substring(body.indexOf("(") + 1, body.lastIndexOf(")"));
|
||||
} else if (body.indexOf("】") >= 0 && body.indexOf("【") >= 0) {
|
||||
name = body.substring(body.indexOf("【") + 1, body.lastIndexOf("】"));
|
||||
} else if (body.indexOf("}") >= 0 && body.indexOf("{") >= 0) {
|
||||
name = body.substring(body.indexOf("{") + 1, body.lastIndexOf("}"));
|
||||
} else if (body.indexOf("!") >= 0) {
|
||||
name = body.substring(body.indexOf("!") + 1, body.lastIndexOf("!"));
|
||||
} else if (body.indexOf("|") >= 0) {
|
||||
name = body.substring(body.indexOf("|") + 1, body.lastIndexOf("|"));
|
||||
}
|
||||
|
||||
PageData pageData = pageService.getOne(
|
||||
new LambdaQueryWrapper<PageData>()
|
||||
.eq(PageData::getPageType, PageEnum.SPECIAL.name())
|
||||
.eq(PageData::getName, name));
|
||||
return ResultUtil.data(pageData);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -3,7 +3,7 @@ package cn.lili.controller.other.broadcast;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.goods.entity.dos.Studio;
|
||||
import cn.lili.modules.goods.entity.vos.StudioVO;
|
||||
import cn.lili.modules.goods.service.StudioService;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import io.swagger.annotations.Api;
|
||||
@@ -35,7 +35,7 @@ public class StudioController {
|
||||
@ApiImplicitParam(name = "status", value = "直播间状态", paramType = "query", dataType = "String")
|
||||
})
|
||||
@GetMapping
|
||||
public ResultMessage<IPage<Studio>> page(PageVO pageVO, Integer recommend, String status) {
|
||||
public ResultMessage<IPage<StudioVO>> page(PageVO pageVO, Integer recommend, String status) {
|
||||
return ResultUtil.data(studioService.studioList(pageVO, recommend, status));
|
||||
}
|
||||
|
||||
|
||||
@@ -3,10 +3,14 @@ package cn.lili.controller.passport;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.common.security.AuthUser;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.security.enums.UserEnums;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.member.entity.dto.MemberEditDTO;
|
||||
import cn.lili.modules.member.entity.enums.QRCodeLoginSessionStatusEnum;
|
||||
import cn.lili.modules.member.entity.vo.QRLoginResultVo;
|
||||
import cn.lili.modules.member.service.MemberService;
|
||||
import cn.lili.modules.sms.SmsUtil;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
@@ -15,10 +19,17 @@ import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.http.HttpStatus;
|
||||
import org.springframework.http.ResponseEntity;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.context.request.async.DeferredResult;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.concurrent.CompletableFuture;
|
||||
import java.util.concurrent.TimeUnit;
|
||||
import java.util.concurrent.atomic.AtomicInteger;
|
||||
|
||||
/**
|
||||
* 买家端,会员接口
|
||||
@@ -26,6 +37,7 @@ import javax.validation.constraints.NotNull;
|
||||
* @author Chopper
|
||||
* @since 2020/11/16 10:07 下午
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@Api(tags = "买家端,会员接口")
|
||||
@RequestMapping("/buyer/passport/member")
|
||||
@@ -39,6 +51,84 @@ public class MemberBuyerController {
|
||||
private VerificationService verificationService;
|
||||
|
||||
|
||||
@ApiOperation(value = "web-获取登录二维码")
|
||||
@PostMapping(value = "/pc_session", produces = "application/json;charset=UTF-8")
|
||||
public ResultMessage<Object> createPcSession() {
|
||||
return ResultUtil.data(memberService.createPcSession());
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 长轮询:参考nacos
|
||||
*
|
||||
* @param token
|
||||
* @param beforeSessionStatus 上次记录的session状态
|
||||
* @return
|
||||
*/
|
||||
@ApiOperation(value = "web-二维码登录")
|
||||
@PostMapping(value = "/session_login/{token}", produces = "application/json;charset=UTF-8")
|
||||
public Object loginWithSession(@PathVariable("token") String token, Integer beforeSessionStatus) {
|
||||
log.info("receive login with session key {}", token);
|
||||
ResponseEntity<ResultMessage<Object>> timeoutResponseEntity =
|
||||
new ResponseEntity<>(ResultUtil.error(ResultCode.ERROR), HttpStatus.OK);
|
||||
int timeoutSecond = 20;
|
||||
DeferredResult<ResponseEntity<Object>> deferredResult = new DeferredResult<>(timeoutSecond * 1000L, timeoutResponseEntity);
|
||||
// 用于记录重试次数
|
||||
AtomicInteger retryCount = new AtomicInteger(0);
|
||||
CompletableFuture.runAsync(() -> {
|
||||
try {
|
||||
int i = 0;
|
||||
while (i < timeoutSecond) {
|
||||
QRLoginResultVo queryResult = memberService.loginWithSession(token);
|
||||
int status = queryResult.getStatus();
|
||||
if (status == beforeSessionStatus
|
||||
&& (QRCodeLoginSessionStatusEnum.WAIT_SCANNING.getCode() == status
|
||||
|| QRCodeLoginSessionStatusEnum.SCANNING.getCode() == status)) {
|
||||
//睡眠一秒种,继续等待结果
|
||||
//TimeUnit.SECONDS.sleep(1);
|
||||
|
||||
// 应用指数退避策略
|
||||
int baseSleepTime = 1000; // 基础退避时间(毫秒)
|
||||
int maxSleepTime = 10000; // 最大退避时间(毫秒)
|
||||
|
||||
int sleepTime = Math.min(maxSleepTime, baseSleepTime * (1 + retryCount.getAndIncrement()));
|
||||
int randomFactor = (int) (Math.random() * (sleepTime / 2)); // 随机化因子
|
||||
|
||||
TimeUnit.MILLISECONDS.sleep(sleepTime + randomFactor);
|
||||
} else {
|
||||
deferredResult.setResult(new ResponseEntity<>(ResultUtil.data(queryResult), HttpStatus.OK));
|
||||
break;
|
||||
}
|
||||
i++;
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error("获取登录状态异常,", e);
|
||||
deferredResult.setResult(new ResponseEntity<>(ResultUtil.error(ResultCode.ERROR), HttpStatus.OK));
|
||||
Thread.currentThread().interrupt();
|
||||
}
|
||||
});
|
||||
return deferredResult;
|
||||
}
|
||||
|
||||
@ApiOperation(value = "app扫码")
|
||||
@PostMapping(value = "/app_scanner", produces = "application/json;charset=UTF-8")
|
||||
public ResultMessage<Object> appScanner(String token) {
|
||||
return ResultUtil.data(memberService.appScanner(token));
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation(value = "app扫码-登录确认:同意/拒绝")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "token", value = "sessionToken", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "code", value = "操作:0拒绝登录,1同意登录", required = true, paramType = "query")
|
||||
})
|
||||
@PostMapping(value = "/app_confirm", produces = "application/json;charset=UTF-8")
|
||||
public ResultMessage<Object> appSConfirm(String token, Integer code) {
|
||||
boolean flag = memberService.appSConfirm(token, code);
|
||||
return flag ? ResultUtil.success() : ResultUtil.error(ResultCode.ERROR);
|
||||
}
|
||||
|
||||
|
||||
@ApiOperation(value = "登录接口")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "username", value = "用户名", required = true, paramType = "query"),
|
||||
@@ -75,6 +165,32 @@ public class MemberBuyerController {
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "绑定手机号")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "username", value = "用户名", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "mobile", value = "手机号", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "code", value = "验证码", required = true, paramType = "query"),
|
||||
})
|
||||
@PostMapping("/bindMobile")
|
||||
public ResultMessage<Object> bindMobile(@NotNull(message = "用户名不能为空") @RequestParam String username,
|
||||
@NotNull(message = "手机号为空") @RequestParam String mobile,
|
||||
@NotNull(message = "验证码为空") @RequestParam String code,
|
||||
@RequestHeader String uuid) {
|
||||
if (smsUtil.verifyCode(mobile, VerificationEnums.BIND_MOBILE, uuid, code)) {
|
||||
Member member = memberService.findByUsername(username);
|
||||
Member memberByMobile = memberService.findByMobile(mobile);
|
||||
if (member == null) {
|
||||
throw new ServiceException(ResultCode.USER_NOT_EXIST);
|
||||
}
|
||||
if(memberByMobile != null){
|
||||
throw new ServiceException(ResultCode.USER_MOBILE_REPEATABLE_ERROR);
|
||||
}
|
||||
return ResultUtil.data(memberService.changeMobile(member.getId(), mobile));
|
||||
} else {
|
||||
throw new ServiceException(ResultCode.VERIFICATION_SMS_CHECKED_ERROR);
|
||||
}
|
||||
}
|
||||
|
||||
@ApiOperation(value = "注册用户")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "username", value = "用户名", required = true, paramType = "query"),
|
||||
@@ -125,7 +241,6 @@ public class MemberBuyerController {
|
||||
|
||||
@ApiOperation(value = "修改密码")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "mobile", value = "手机号", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "password", value = "是否保存登录", required = true, paramType = "query")
|
||||
})
|
||||
@PostMapping("/resetPassword")
|
||||
@@ -152,6 +267,31 @@ public class MemberBuyerController {
|
||||
return ResultUtil.data(memberService.modifyPass(password, newPassword));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "初始设置密码")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "newPassword", value = "新密码", required = true, paramType = "query")
|
||||
})
|
||||
@PutMapping("/canInitPassword")
|
||||
public ResultMessage<Object> canInitPassword() {
|
||||
return ResultUtil.data(memberService.canInitPass());
|
||||
}
|
||||
|
||||
@ApiOperation(value = "初始设置密码")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "newPassword", value = "新密码", required = true, paramType = "query")
|
||||
})
|
||||
@PutMapping("/initPassword")
|
||||
public ResultMessage<Object> initPassword(@NotNull(message = "密码不能为空") @RequestParam String password) {
|
||||
memberService.initPass(password);
|
||||
return ResultUtil.success();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "注销账号")
|
||||
@PutMapping("/cancellation")
|
||||
public ResultMessage<Member> cancellation() {
|
||||
memberService.cancellation();
|
||||
return ResultUtil.success();
|
||||
}
|
||||
|
||||
@ApiOperation(value = "刷新token")
|
||||
@GetMapping("/refresh/{refreshToken}")
|
||||
@@ -159,4 +299,18 @@ public class MemberBuyerController {
|
||||
return ResultUtil.data(this.memberService.refreshToken(refreshToken));
|
||||
}
|
||||
|
||||
@GetMapping("/getImUser")
|
||||
@ApiOperation(value = "获取用户信息")
|
||||
public ResultMessage<Member> getImUser() {
|
||||
AuthUser authUser = UserContext.getCurrentUser();
|
||||
return ResultUtil.data(memberService.getById(authUser.getId()));
|
||||
}
|
||||
|
||||
@GetMapping("/getImUserDetail/{memberId}")
|
||||
@ApiImplicitParam(name = "memberId", value = "店铺Id", required = true, dataType = "String", paramType = "path")
|
||||
@ApiOperation(value = "获取用户信息")
|
||||
public ResultMessage<Member> getImUserDetail(@PathVariable String memberId) {
|
||||
return ResultUtil.data(memberService.getById(memberId));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -47,7 +47,7 @@ public class ConnectBuyerWebController {
|
||||
|
||||
|
||||
@GetMapping("/login/web/{type}")
|
||||
@ApiOperation(value = "WEB信任登录授权")
|
||||
@ApiOperation(value = "WEB信任登录授权,包含PC、WAP")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "type", value = "登录方式:QQ,微信,微信_PC",
|
||||
allowableValues = "QQ,WECHAT,WECHAT_PC", paramType = "path")
|
||||
@@ -75,25 +75,13 @@ public class ConnectBuyerWebController {
|
||||
return connectUtil.getResult(state);
|
||||
}
|
||||
|
||||
@GetMapping("/register/auto")
|
||||
@ApiOperation(value = "WEB信任登录授权")
|
||||
public ResultMessage<Token> webAuthorize() {
|
||||
Token token = memberService.autoRegister();
|
||||
return ResultUtil.data(token);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "unionID登录")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "openId", value = "openid", required = true, paramType = "query"),
|
||||
@ApiImplicitParam(name = "type", value = "联合类型", required = true,
|
||||
allowableValues = "WECHAT,QQ,ALIPAY,WEIBO,APPLE", paramType = "query"),
|
||||
@ApiImplicitParam(name = "uniAccessToken", value = "联合登陆返回的accessToken", required = true, paramType = "query")
|
||||
})
|
||||
@GetMapping("/app/login")
|
||||
public ResultMessage<Token> unionLogin(ConnectAuthUser authUser, @RequestHeader("uuid") String uuid) {
|
||||
@ApiOperation(value = "APP-unionID登录")
|
||||
@PostMapping("/app/login")
|
||||
public ResultMessage<Token> unionLogin(@RequestBody ConnectAuthUser authUser, @RequestHeader("uuid") String uuid) {
|
||||
try {
|
||||
return ResultUtil.data(connectService.appLoginCallback(authUser, uuid));
|
||||
return ResultUtil.data(connectService.unionLoginCallback(authUser, uuid));
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
log.error("unionID登录错误", e);
|
||||
}
|
||||
return null;
|
||||
|
||||
@@ -7,11 +7,14 @@ import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.promotion.entity.dos.MemberCoupon;
|
||||
import cn.lili.modules.promotion.entity.dto.CouponActivityTrigger;
|
||||
import cn.lili.modules.promotion.entity.dto.search.CouponSearchParams;
|
||||
import cn.lili.modules.promotion.entity.dto.search.MemberCouponSearchParams;
|
||||
import cn.lili.modules.promotion.entity.enums.CouponActivityTypeEnum;
|
||||
import cn.lili.modules.promotion.entity.enums.CouponGetEnum;
|
||||
import cn.lili.modules.promotion.entity.enums.PromotionsStatusEnum;
|
||||
import cn.lili.modules.promotion.entity.vos.CouponVO;
|
||||
import cn.lili.modules.promotion.service.CouponActivityService;
|
||||
import cn.lili.modules.promotion.service.CouponService;
|
||||
import cn.lili.modules.promotion.service.MemberCouponService;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
@@ -26,6 +29,7 @@ import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import javax.validation.constraints.NotNull;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
@@ -45,12 +49,39 @@ public class CouponBuyerController {
|
||||
@Autowired
|
||||
private CouponService couponService;
|
||||
|
||||
/**
|
||||
* 优惠券活动
|
||||
*/
|
||||
@Autowired
|
||||
private CouponActivityService couponActivityService;
|
||||
|
||||
/**
|
||||
* 会员优惠券
|
||||
*/
|
||||
@Autowired
|
||||
private MemberCouponService memberCouponService;
|
||||
|
||||
@GetMapping("/activity")
|
||||
@ApiOperation(value = "自动领取优惠券")
|
||||
public ResultMessage<List<MemberCoupon>> activity() {
|
||||
if (UserContext.getCurrentUser() == null) {
|
||||
return ResultUtil.success();
|
||||
}
|
||||
List<MemberCoupon> memberCouponList = couponActivityService.trigger(
|
||||
CouponActivityTrigger.builder()
|
||||
.couponActivityTypeEnum(CouponActivityTypeEnum.AUTO_COUPON)
|
||||
.nickName(UserContext.getCurrentUser().getNickName())
|
||||
.userId(UserContext.getCurrentUser().getId())
|
||||
.build());
|
||||
memberCouponList.addAll(couponActivityService.trigger(
|
||||
CouponActivityTrigger.builder()
|
||||
.couponActivityTypeEnum(CouponActivityTypeEnum.SPECIFY)
|
||||
.nickName(UserContext.getCurrentUser().getNickName())
|
||||
.userId(UserContext.getCurrentUser().getId())
|
||||
.build()));
|
||||
return ResultUtil.data(memberCouponList);
|
||||
}
|
||||
|
||||
@GetMapping
|
||||
@ApiOperation(value = "获取可领取优惠券列表")
|
||||
public ResultMessage<IPage<CouponVO>> getCouponList(CouponSearchParams queryParam, PageVO page) {
|
||||
|
||||
@@ -0,0 +1,53 @@
|
||||
package cn.lili.controller.store;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.security.OperationalJudgment;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.store.entity.dos.StoreAddress;
|
||||
import cn.lili.modules.store.service.StoreAddressService;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.PathVariable;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 买家端,商家地址(自提点)接口
|
||||
*
|
||||
* @author chc
|
||||
* @since 2022/6/2114:46
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "买家端,商家地址(自提点)接口")
|
||||
@RequestMapping("/buyer/store/address")
|
||||
public class StoreAddressBuyerController {
|
||||
|
||||
/**
|
||||
* 店铺自提点
|
||||
*/
|
||||
@Autowired
|
||||
private StoreAddressService storeAddressService;
|
||||
|
||||
@ApiOperation(value = "获取商家自提点分页")
|
||||
@ApiImplicitParam(name = "storeId", value = "店铺Id", required = true, dataType = "String", paramType = "path")
|
||||
@GetMapping("/page/{storeId}")
|
||||
public ResultMessage<IPage<StoreAddress>> get(PageVO pageVo,@PathVariable String storeId) {
|
||||
return ResultUtil.data(storeAddressService.getStoreAddress(storeId, pageVo));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "获取商家自提点信息")
|
||||
@ApiImplicitParam(name = "id", value = "自提点ID", required = true, paramType = "path")
|
||||
@GetMapping("/{id}")
|
||||
public ResultMessage<StoreAddress> get(@PathVariable String id) {
|
||||
StoreAddress address = OperationalJudgment.judgment(storeAddressService.getById(id));
|
||||
return ResultUtil.data(address);
|
||||
}
|
||||
}
|
||||
@@ -1,11 +1,13 @@
|
||||
package cn.lili.controller.store;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.security.AuthUser;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.goods.entity.vos.StoreGoodsLabelVO;
|
||||
import cn.lili.modules.goods.service.StoreGoodsLabelService;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import cn.lili.modules.store.entity.dto.StoreBankDTO;
|
||||
import cn.lili.modules.store.entity.dto.StoreCompanyDTO;
|
||||
import cn.lili.modules.store.entity.dto.StoreOtherInfoDTO;
|
||||
@@ -57,6 +59,20 @@ public class StoreBuyerController {
|
||||
return ResultUtil.data(storeService.findByConditionPage(entity, page));
|
||||
}
|
||||
|
||||
@GetMapping("/store")
|
||||
@ApiOperation(value = "im-获取店铺信息")
|
||||
public ResultMessage<Store> getStoreUser() {
|
||||
AuthUser authUser = UserContext.getCurrentUser();
|
||||
return ResultUtil.data(storeService.getById(authUser.getStoreId()));
|
||||
}
|
||||
|
||||
@GetMapping("/store/{storeId}")
|
||||
@ApiImplicitParam(name = "storeId", value = "店铺Id", required = true, dataType = "String", paramType = "path")
|
||||
@ApiOperation(value = "im-店铺ID获取店铺信息")
|
||||
public ResultMessage<Store> getStoreUserDetail(@PathVariable String storeId) {
|
||||
return ResultUtil.data(storeService.getById(storeId));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "通过id获取店铺信息")
|
||||
@ApiImplicitParam(name = "id", value = "店铺ID", required = true, paramType = "path")
|
||||
@GetMapping(value = "/get/detail/{id}")
|
||||
|
||||
@@ -9,22 +9,28 @@ import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.member.service.MemberService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.WithdrawalSetting;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.entity.vo.WithdrawalSettingVO;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
import cn.lili.modules.verification.service.VerificationService;
|
||||
import cn.lili.modules.wallet.entity.dos.MemberWallet;
|
||||
import cn.lili.modules.wallet.entity.vo.MemberWalletVO;
|
||||
import cn.lili.modules.wallet.service.MemberWalletService;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.google.gson.Gson;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.security.crypto.bcrypt.BCryptPasswordEncoder;
|
||||
import org.springframework.validation.annotation.Validated;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.validation.constraints.Max;
|
||||
import javax.validation.constraints.Min;
|
||||
import javax.validation.constraints.Pattern;
|
||||
|
||||
/**
|
||||
@@ -36,6 +42,7 @@ import javax.validation.constraints.Pattern;
|
||||
@RestController
|
||||
@Api(tags = "买家端,会员余额接口")
|
||||
@RequestMapping("/buyer/wallet/wallet")
|
||||
@Validated
|
||||
public class MemberWalletBuyerController {
|
||||
|
||||
/**
|
||||
@@ -54,6 +61,9 @@ public class MemberWalletBuyerController {
|
||||
@Autowired
|
||||
private VerificationService verificationService;
|
||||
|
||||
@Autowired
|
||||
private SettingService settingService;
|
||||
|
||||
@GetMapping
|
||||
@ApiOperation(value = "查询会员预存款余额")
|
||||
public ResultMessage<MemberWalletVO> get() {
|
||||
@@ -64,6 +74,31 @@ public class MemberWalletBuyerController {
|
||||
throw new ServiceException(ResultCode.USER_NOT_LOGIN);
|
||||
}
|
||||
|
||||
@GetMapping(value = "/withdrawalSettingVO")
|
||||
@ApiOperation(value = "获取提现设置VO")
|
||||
public ResultMessage<Object> minPrice() {
|
||||
Setting setting = settingService.get(SettingEnum.WITHDRAWAL_SETTING.name());
|
||||
WithdrawalSetting withdrawalSetting = new Gson().fromJson(setting.getSettingValue(), WithdrawalSetting.class);
|
||||
|
||||
WithdrawalSettingVO withdrawalSettingVO = new WithdrawalSettingVO();
|
||||
withdrawalSettingVO.setMinPrice(withdrawalSetting.getMinPrice());
|
||||
withdrawalSettingVO.setFee(withdrawalSetting.getFee());
|
||||
withdrawalSettingVO.setType(withdrawalSetting.getType());
|
||||
return ResultUtil.data(withdrawalSettingVO);
|
||||
}
|
||||
|
||||
@PreventDuplicateSubmissions
|
||||
@PostMapping(value = "/withdrawal")
|
||||
@ApiOperation(value = "会员中心余额提现")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "price", value = "提现金额", required = true, dataType = "double", paramType = "query"),
|
||||
@ApiImplicitParam(name = "realName", value = "真实姓名", required = true, dataType = "String", paramType = "query"),
|
||||
@ApiImplicitParam(name = "connectNumber", value = "第三方登录账号", required = true, dataType = "String", paramType = "query")
|
||||
})
|
||||
public ResultMessage<Boolean> withdrawal(@Max(value = 9999, message = "充值金额单次最多允许提现9999元") Double price, @RequestParam String realName, @RequestParam String connectNumber) {
|
||||
return ResultUtil.data(memberWalletService.applyWithdrawal(price, realName, connectNumber));
|
||||
}
|
||||
|
||||
@PostMapping(value = "/set-password")
|
||||
@ApiOperation(value = "设置支付密码")
|
||||
@ApiImplicitParams({
|
||||
@@ -120,15 +155,4 @@ public class MemberWalletBuyerController {
|
||||
return memberWalletService.checkPassword();
|
||||
}
|
||||
|
||||
|
||||
@PreventDuplicateSubmissions
|
||||
@PostMapping(value = "/withdrawal")
|
||||
@ApiOperation(value = "会员中心余额提现")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(name = "price", value = "提现金额", required = true, dataType = "double", paramType = "query")
|
||||
})
|
||||
public ResultMessage<Boolean> withdrawal(@Max(value = 9999, message = "充值金额单次最多允许提现9999元") @Min(value = 1, message = "充值金额单次最少提现金额为1元") Double price) {
|
||||
return ResultUtil.data(memberWalletService.applyWithdrawal(price));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,30 @@
|
||||
package cn.lili.init;
|
||||
|
||||
import cn.lili.modules.search.service.EsGoodsIndexService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.ApplicationArguments;
|
||||
import org.springframework.boot.ApplicationRunner;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* @author paulG
|
||||
* @since 2022/6/9
|
||||
**/
|
||||
@Component
|
||||
@Slf4j
|
||||
public class EsGoodsIndexInitRunner implements ApplicationRunner {
|
||||
|
||||
@Autowired
|
||||
private EsGoodsIndexService esGoodsIndexService;
|
||||
|
||||
|
||||
@Override
|
||||
public void run(ApplicationArguments args) {
|
||||
try {
|
||||
esGoodsIndexService.initIndex();
|
||||
} catch (Exception e) {
|
||||
log.error("检测ES商品索引失败", e);
|
||||
}
|
||||
}
|
||||
}
|
||||
2
buyer-api/src/main/java/cn/lili/security/BuyerAuthenticationFilter.java
Executable file → Normal file
2
buyer-api/src/main/java/cn/lili/security/BuyerAuthenticationFilter.java
Executable file → Normal file
@@ -99,7 +99,7 @@ public class BuyerAuthenticationFilter extends BasicAuthenticationFilter {
|
||||
AuthUser authUser = new Gson().fromJson(json, AuthUser.class);
|
||||
|
||||
//校验redis中是否有权限
|
||||
if (cache.hasKey(CachePrefix.ACCESS_TOKEN.getPrefix(UserEnums.MEMBER) + jwt)) {
|
||||
if (cache.hasKey(CachePrefix.ACCESS_TOKEN.getPrefix(UserEnums.MEMBER,authUser.getId()) + jwt)) {
|
||||
//构造返回信息
|
||||
List<GrantedAuthority> auths = new ArrayList<>();
|
||||
auths.add(new SimpleGrantedAuthority("ROLE_" + authUser.getRole().name()));
|
||||
|
||||
@@ -213,18 +213,6 @@ lili:
|
||||
lbs:
|
||||
key: 4BYBZ-7MT6S-PUAOA-6BNWL-FJUD7-UUFXT
|
||||
sk: zhNKVrJK6UPOhqIjn8AQvG37b9sz6
|
||||
#域名
|
||||
domain:
|
||||
pc: https://pc-b2b2c.pickmall.cn
|
||||
wap: https://m-b2b2c.pickmall.cn
|
||||
store: https://store-b2b2c.pickmall.cn
|
||||
admin: https://admin-b2b2c.pickmall.cn
|
||||
#api地址
|
||||
api:
|
||||
buyer: https://buyer-api.pickmall.cn
|
||||
common: https://common-api.pickmall.cn
|
||||
manager: https://admin-api.pickmall.cn
|
||||
store: https://store-api.pickmall.cn
|
||||
|
||||
# jwt 细节设定
|
||||
jwt-setting:
|
||||
@@ -265,6 +253,8 @@ lili:
|
||||
order-group: lili_order_group
|
||||
member-topic: lili_member_topic
|
||||
member-group: lili_member_group
|
||||
store-topic: lili_store_topic
|
||||
store-group: lili_store_group
|
||||
other-topic: lili_other_topic
|
||||
other-group: lili_other_group
|
||||
notice-topic: lili_notice_topic
|
||||
|
||||
@@ -20,6 +20,23 @@
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<appender name="RocketmqClientAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${LOG_FILE_PATH}/rocketmq.log</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_PATH}/rocketmq/rocketmq-%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<maxHistory>30</maxHistory>
|
||||
<totalSizeCap>30MB</totalSizeCap>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>%d{yy-MM-dd.HH:mm:ss.SSS} [%-16t] %-5p %-22c{0} %X{ServiceId} - %m%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
<logger name="RocketmqClient" additivity="false">
|
||||
<level value="info" />
|
||||
<appender-ref ref="RocketmqClientAppender"/>
|
||||
</logger>
|
||||
|
||||
|
||||
<!--输出到elk的LOGSTASH-->
|
||||
<appender name="LOGSTASH" class="net.logstash.logback.appender.LogstashTcpSocketAppender">
|
||||
<!-- 配置elk日志收集 配饰的是 LOGSTASH 的地址-->
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
package cn.lili.buyer.test.cart;
|
||||
|
||||
|
||||
import cn.lili.modules.file.plugin.FileManagerPlugin;
|
||||
import cn.lili.modules.file.plugin.FilePlugin;
|
||||
import cn.lili.modules.goods.entity.dos.Brand;
|
||||
import cn.lili.modules.goods.service.BrandService;
|
||||
import com.xkcoding.http.util.StringUtil;
|
||||
@@ -27,7 +27,7 @@ class FileTest {
|
||||
|
||||
|
||||
@Autowired
|
||||
private FileManagerPlugin fileManagerPlugin;
|
||||
private FilePlugin fileManagerPlugin;
|
||||
|
||||
@Autowired
|
||||
private BrandService brandService;
|
||||
|
||||
@@ -15,6 +15,7 @@ import org.springframework.cache.annotation.EnableCaching;
|
||||
public class CommonApiApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
System.setProperty("rocketmq.client.logUseSlf4j","true");
|
||||
SpringApplication.run(CommonApiApplication.class, args);
|
||||
}
|
||||
|
||||
|
||||
@@ -1,15 +1,15 @@
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.common.context.ThreadContextHolder;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.common.security.AuthUser;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.security.enums.UserEnums;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.common.utils.ResponseUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.common.vo.SearchVO;
|
||||
import cn.lili.modules.file.entity.File;
|
||||
import cn.lili.modules.file.entity.dto.FileOwnerDTO;
|
||||
import cn.lili.modules.file.service.FileService;
|
||||
@@ -43,10 +43,14 @@ public class FileController {
|
||||
@ApiOperation(value = "获取自己的图片资源")
|
||||
@GetMapping
|
||||
@ApiImplicitParam(name = "title", value = "名称模糊匹配")
|
||||
public ResultMessage<IPage<File>> getFileList(@RequestHeader String accessToken, File file, SearchVO searchVO, PageVO pageVo) {
|
||||
public ResultMessage<IPage<File>> getFileList(@RequestHeader String accessToken, FileOwnerDTO fileOwnerDTO) {
|
||||
|
||||
AuthUser authUser = UserContext.getAuthUser(cache, accessToken);
|
||||
FileOwnerDTO fileOwnerDTO = new FileOwnerDTO();
|
||||
if (authUser == null) {
|
||||
ResponseUtil.output(ThreadContextHolder.getHttpResponse(), 403, ResponseUtil.resultMap(false,
|
||||
403, "登录已失效,请重新登录"));
|
||||
return null;
|
||||
}
|
||||
//只有买家才写入自己id
|
||||
if (authUser.getRole().equals(UserEnums.MEMBER)) {
|
||||
fileOwnerDTO.setOwnerId(authUser.getId());
|
||||
@@ -55,7 +59,7 @@ public class FileController {
|
||||
fileOwnerDTO.setOwnerId(authUser.getStoreId());
|
||||
}
|
||||
fileOwnerDTO.setUserEnums(authUser.getRole().name());
|
||||
return ResultUtil.data(fileService.customerPageOwner(fileOwnerDTO, file, searchVO, pageVo));
|
||||
return ResultUtil.data(fileService.customerPageOwner(fileOwnerDTO));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "文件重命名")
|
||||
|
||||
@@ -0,0 +1,70 @@
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.security.context.UserContext;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.file.entity.FileDirectory;
|
||||
import cn.lili.modules.file.entity.dto.FileDirectoryDTO;
|
||||
import cn.lili.modules.file.service.FileDirectoryService;
|
||||
import cn.lili.modules.file.service.FileService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.RequiredArgsConstructor;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
import javax.validation.Valid;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 文件目录管理接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "文件目录管理接口")
|
||||
@RequestMapping("/common/resource/fileDirectory")
|
||||
@RequiredArgsConstructor
|
||||
public class FileDirectoryController {
|
||||
|
||||
private final FileDirectoryService fileDirectoryService;
|
||||
private final FileService fileService;
|
||||
|
||||
@ApiOperation(value = "获取文件目录列表")
|
||||
@GetMapping
|
||||
public ResultMessage<List<FileDirectoryDTO>> getSceneFileList() {
|
||||
return ResultUtil.data(fileDirectoryService.getFileDirectoryList(UserContext.getCurrentUser().getId()));
|
||||
}
|
||||
|
||||
@ApiOperation(value = "添加文件目录")
|
||||
@PostMapping
|
||||
public ResultMessage<FileDirectory> addSceneFileList(@RequestBody @Valid FileDirectory fileDirectory) {
|
||||
fileDirectory.setDirectoryType(UserContext.getCurrentUser().getRole().name());
|
||||
fileDirectory.setOwnerId(UserContext.getCurrentUser().getId());
|
||||
fileDirectoryService.save(fileDirectory);
|
||||
return ResultUtil.data(fileDirectory);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "修改文件目录")
|
||||
@PutMapping
|
||||
public ResultMessage<FileDirectory> editSceneFileList(@RequestBody @Valid FileDirectory fileDirectory) {
|
||||
fileDirectory.setDirectoryType(UserContext.getCurrentUser().getRole().name());
|
||||
fileDirectory.setOwnerId(UserContext.getCurrentUser().getId());
|
||||
fileDirectoryService.updateById(fileDirectory);
|
||||
return ResultUtil.data(fileDirectory);
|
||||
}
|
||||
|
||||
@ApiOperation(value = "删除文件目录")
|
||||
@DeleteMapping("/{id}")
|
||||
public ResultMessage<Object> deleteSceneFileList(@PathVariable String id) {
|
||||
//检测文件夹下是否包含图片
|
||||
if(fileService.countByDirectory(id)){
|
||||
return ResultUtil.error(ResultCode.FILE_DIRECTORY_NOT_EMPTY);
|
||||
}
|
||||
//删除目录
|
||||
fileDirectoryService.removeById(id);
|
||||
return ResultUtil.success();
|
||||
}
|
||||
|
||||
}
|
||||
@@ -39,7 +39,7 @@ public class IMController {
|
||||
try {
|
||||
Setting imSettingVal = settingService.get(SettingEnum.IM_SETTING.name());
|
||||
ImSetting imSetting = JSONUtil.toBean(imSettingVal.getSettingValue(), ImSetting.class);
|
||||
imUrl = imSetting.getHttpUrl() + "?tenant_id=" + imSetting.getTenantId()+"&merchant_euid=";
|
||||
imUrl = imSetting.getHttpUrl();
|
||||
} catch (Exception e) {
|
||||
throw new ServiceException(ResultCode.PLATFORM_NOT_SUPPORTED_IM);
|
||||
}
|
||||
|
||||
@@ -2,9 +2,9 @@ package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.system.service.RegionService;
|
||||
import cn.lili.modules.system.entity.dos.Region;
|
||||
import cn.lili.modules.system.entity.vo.RegionVO;
|
||||
import cn.lili.modules.system.service.RegionService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
@@ -38,6 +38,11 @@ public class RegionController {
|
||||
return ResultUtil.data(regionService.getRegion(cityCode,townName));
|
||||
}
|
||||
|
||||
@GetMapping(value = "/name")
|
||||
@ApiOperation(value = "根据名字获取地区地址id")
|
||||
public ResultMessage<String> getItemByLastName(String lastName) {
|
||||
return ResultUtil.data(regionService.getItemByLastName(lastName));
|
||||
}
|
||||
|
||||
@GetMapping(value = "/item/{id}")
|
||||
@ApiImplicitParam(name = "id", value = "地区ID", required = true, dataType = "String", paramType = "path")
|
||||
|
||||
@@ -6,31 +6,30 @@ import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.GetMapping;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 文件管理管理接口
|
||||
* 站点基础配置获取
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
* @author liushuai(liushuai711 @ gmail.com)
|
||||
* @version v4.0
|
||||
* @Description:
|
||||
* @since 2022/9/22 17:49
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@Api(tags = "文件管理接口")
|
||||
@RequestMapping("/common/common/logo")
|
||||
public class LogoController {
|
||||
@RequestMapping("/common/common/site")
|
||||
@Api(tags = "站点基础接口")
|
||||
public class SiteController {
|
||||
|
||||
@Autowired
|
||||
private SettingService settingService;
|
||||
|
||||
@ApiOperation(value = "获取logo")
|
||||
@ApiOperation(value = "获取站点基础信息")
|
||||
@GetMapping
|
||||
public ResultMessage<Object> getFileList() {
|
||||
public ResultMessage<Object> baseSetting() {
|
||||
return ResultUtil.data(settingService.get(SettingEnum.BASE_SETTING.name()));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -1,43 +1,43 @@
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.cache.limit.annotation.LimitPoint;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
import cn.lili.modules.verification.service.VerificationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 滑块验证码接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequestMapping("/common/common/slider")
|
||||
@Api(tags = "滑块验证码接口")
|
||||
public class SliderImageController {
|
||||
|
||||
@Autowired
|
||||
private VerificationService verificationService;
|
||||
|
||||
@LimitPoint(name = "slider_image", key = "verification")
|
||||
@GetMapping("/{verificationEnums}")
|
||||
@ApiOperation(value = "获取校验接口,一分钟同一个ip请求10次")
|
||||
public ResultMessage getSliderImage(@RequestHeader String uuid, @PathVariable VerificationEnums verificationEnums) {
|
||||
return ResultUtil.data(verificationService.createVerification(verificationEnums, uuid));
|
||||
|
||||
}
|
||||
|
||||
@LimitPoint(name = "slider_image", key = "verification_pre_check", limit = 600)
|
||||
@PostMapping("/{verificationEnums}")
|
||||
@ApiOperation(value = "验证码预校验")
|
||||
public ResultMessage verificationImage(Integer xPos, @RequestHeader String uuid, @PathVariable VerificationEnums verificationEnums) {
|
||||
return ResultUtil.data(verificationService.preCheck(xPos, uuid, verificationEnums));
|
||||
}
|
||||
}
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.cache.limit.annotation.LimitPoint;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
import cn.lili.modules.verification.service.VerificationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 滑块验证码接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
*/
|
||||
@Slf4j
|
||||
@RestController
|
||||
@RequestMapping("/common/common/slider")
|
||||
@Api(tags = "滑块验证码接口")
|
||||
public class SliderImageController {
|
||||
|
||||
@Autowired
|
||||
private VerificationService verificationService;
|
||||
|
||||
@LimitPoint(name = "slider_image", key = "verification")
|
||||
@GetMapping("/{verificationEnums}")
|
||||
@ApiOperation(value = "获取校验接口,一分钟同一个ip请求10次")
|
||||
public ResultMessage getSliderImage(@RequestHeader String uuid, @PathVariable VerificationEnums verificationEnums) {
|
||||
return ResultUtil.data(verificationService.createVerification(verificationEnums, uuid));
|
||||
|
||||
}
|
||||
|
||||
@LimitPoint(name = "slider_image", key = "verification_pre_check", limit = 600)
|
||||
@PostMapping("/{verificationEnums}")
|
||||
@ApiOperation(value = "验证码预校验")
|
||||
public ResultMessage verificationImage(Integer xPos, @RequestHeader String uuid, @PathVariable VerificationEnums verificationEnums) {
|
||||
return ResultUtil.data(verificationService.preCheck(xPos, uuid, verificationEnums));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,48 +1,48 @@
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.cache.limit.annotation.LimitPoint;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.sms.SmsUtil;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
import cn.lili.modules.verification.service.VerificationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 短信验证码接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "短信验证码接口")
|
||||
@RequestMapping("/common/common/sms")
|
||||
public class SmsController {
|
||||
|
||||
@Autowired
|
||||
private SmsUtil smsUtil;
|
||||
@Autowired
|
||||
private VerificationService verificationService;
|
||||
|
||||
@LimitPoint(name = "sms_send", key = "sms")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "path", dataType = "String", name = "mobile", value = "手机号"),
|
||||
@ApiImplicitParam(paramType = "header", dataType = "String", name = "uuid", value = "uuid"),
|
||||
})
|
||||
@GetMapping("/{verificationEnums}/{mobile}")
|
||||
@ApiOperation(value = "发送短信验证码,一分钟同一个ip请求1次")
|
||||
public ResultMessage getSmsCode(
|
||||
@RequestHeader String uuid,
|
||||
@PathVariable String mobile,
|
||||
@PathVariable VerificationEnums verificationEnums) {
|
||||
verificationService.check(uuid, verificationEnums);
|
||||
smsUtil.sendSmsCode(mobile, verificationEnums, uuid);
|
||||
return ResultUtil.success(ResultCode.VERIFICATION_SEND_SUCCESS);
|
||||
}
|
||||
}
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.lili.cache.limit.annotation.LimitPoint;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.sms.SmsUtil;
|
||||
import cn.lili.modules.verification.entity.enums.VerificationEnums;
|
||||
import cn.lili.modules.verification.service.VerificationService;
|
||||
import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiImplicitParam;
|
||||
import io.swagger.annotations.ApiImplicitParams;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
|
||||
/**
|
||||
* 短信验证码接口
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/26 15:41
|
||||
*/
|
||||
@RestController
|
||||
@Api(tags = "短信验证码接口")
|
||||
@RequestMapping("/common/common/sms")
|
||||
public class SmsController {
|
||||
|
||||
@Autowired
|
||||
private SmsUtil smsUtil;
|
||||
@Autowired
|
||||
private VerificationService verificationService;
|
||||
|
||||
@LimitPoint(name = "sms_send", key = "sms")
|
||||
@ApiImplicitParams({
|
||||
@ApiImplicitParam(paramType = "path", dataType = "String", name = "mobile", value = "手机号"),
|
||||
@ApiImplicitParam(paramType = "header", dataType = "String", name = "uuid", value = "uuid"),
|
||||
})
|
||||
@GetMapping("/{verificationEnums}/{mobile}")
|
||||
@ApiOperation(value = "发送短信验证码,一分钟同一个ip请求1次")
|
||||
public ResultMessage getSmsCode(
|
||||
@RequestHeader String uuid,
|
||||
@PathVariable String mobile,
|
||||
@PathVariable VerificationEnums verificationEnums) {
|
||||
verificationService.check(uuid, verificationEnums);
|
||||
smsUtil.sendSmsCode(mobile, verificationEnums, uuid);
|
||||
return ResultUtil.success(ResultCode.VERIFICATION_SEND_SUCCESS);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,6 +1,7 @@
|
||||
package cn.lili.controller.common;
|
||||
|
||||
import cn.hutool.core.text.CharSequenceUtil;
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.enums.ResultUtil;
|
||||
@@ -12,7 +13,7 @@ import cn.lili.common.utils.Base64DecodeMultipartFile;
|
||||
import cn.lili.common.utils.CommonUtil;
|
||||
import cn.lili.common.vo.ResultMessage;
|
||||
import cn.lili.modules.file.entity.File;
|
||||
import cn.lili.modules.file.plugin.FileManagerPlugin;
|
||||
import cn.lili.modules.file.plugin.FilePluginFactory;
|
||||
import cn.lili.modules.file.service.FileService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
@@ -21,10 +22,7 @@ import io.swagger.annotations.Api;
|
||||
import io.swagger.annotations.ApiOperation;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.web.bind.annotation.PostMapping;
|
||||
import org.springframework.web.bind.annotation.RequestHeader;
|
||||
import org.springframework.web.bind.annotation.RequestMapping;
|
||||
import org.springframework.web.bind.annotation.RestController;
|
||||
import org.springframework.web.bind.annotation.*;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
import java.io.InputStream;
|
||||
@@ -47,7 +45,7 @@ public class UploadController {
|
||||
@Autowired
|
||||
private SettingService settingService;
|
||||
@Autowired
|
||||
private FileManagerPlugin fileManagerPlugin;
|
||||
private FilePluginFactory filePluginFactory;
|
||||
@Autowired
|
||||
private Cache cache;
|
||||
|
||||
@@ -55,24 +53,30 @@ public class UploadController {
|
||||
@PostMapping(value = "/file")
|
||||
public ResultMessage<Object> upload(MultipartFile file,
|
||||
String base64,
|
||||
@RequestHeader String accessToken) {
|
||||
@RequestHeader String accessToken, @RequestParam String directoryPath) {
|
||||
|
||||
if(StrUtil.isBlank(directoryPath)){
|
||||
directoryPath = "default";
|
||||
}
|
||||
|
||||
AuthUser authUser = UserContext.getAuthUser(cache, accessToken);
|
||||
//如果用户未登录,则无法上传图片
|
||||
if (authUser == null) {
|
||||
throw new ServiceException(ResultCode.USER_AUTHORITY_ERROR);
|
||||
}
|
||||
if (file == null) {
|
||||
throw new ServiceException(ResultCode.FILE_NOT_EXIST_ERROR);
|
||||
}
|
||||
Setting setting = settingService.get(SettingEnum.OSS_SETTING.name());
|
||||
if (setting == null || CharSequenceUtil.isBlank(setting.getSettingValue())) {
|
||||
throw new ServiceException(ResultCode.OSS_NOT_EXIST);
|
||||
}
|
||||
if (file == null || CharSequenceUtil.isEmpty(file.getContentType())) {
|
||||
if (CharSequenceUtil.isEmpty(file.getContentType())) {
|
||||
throw new ServiceException(ResultCode.IMAGE_FILE_EXT_ERROR);
|
||||
}
|
||||
|
||||
|
||||
if (!CharSequenceUtil.containsAny(file.getContentType().toLowerCase(), "image")) {
|
||||
if (!CharSequenceUtil.containsAny(Objects.requireNonNull(file.getContentType()).toLowerCase(), "image", "video")) {
|
||||
throw new ServiceException(ResultCode.FILE_TYPE_NOT_SUPPORT);
|
||||
}
|
||||
|
||||
@@ -86,7 +90,13 @@ public class UploadController {
|
||||
try {
|
||||
InputStream inputStream = file.getInputStream();
|
||||
//上传至第三方云服务或服务器
|
||||
result = fileManagerPlugin.inputStreamUpload(inputStream, fileKey);
|
||||
String scene = UserContext.getCurrentUser().getRole().name();
|
||||
if (StrUtil.equalsAny(UserContext.getCurrentUser().getRole().name(), UserEnums.MEMBER.name(), UserEnums.STORE.name(), UserEnums.SEAT.name())) {
|
||||
scene = scene + "/" + authUser.getId();
|
||||
}
|
||||
fileKey = scene + "/" + directoryPath + "/" + fileKey;
|
||||
//上传至第三方云服务或服务器
|
||||
result = filePluginFactory.filePlugin().inputStreamUpload(inputStream, fileKey);
|
||||
//保存数据信息至数据库
|
||||
newFile.setName(file.getOriginalFilename());
|
||||
newFile.setFileSize(file.getSize());
|
||||
@@ -98,8 +108,19 @@ public class UploadController {
|
||||
//如果是店铺,则记录店铺id
|
||||
if (authUser.getRole().equals(UserEnums.STORE)) {
|
||||
newFile.setOwnerId(authUser.getStoreId());
|
||||
newFile.setOwnerName(authUser.getStoreName());
|
||||
} else {
|
||||
newFile.setOwnerId(authUser.getId());
|
||||
newFile.setOwnerName(authUser.getNickName());
|
||||
}
|
||||
|
||||
//存储文件目录
|
||||
if (StrUtil.isNotEmpty(directoryPath)) {
|
||||
if (directoryPath.indexOf("/") > 0) {
|
||||
newFile.setFileDirectoryId(directoryPath.substring(directoryPath.lastIndexOf("/") + 1));
|
||||
} else {
|
||||
newFile.setFileDirectoryId(directoryPath);
|
||||
}
|
||||
}
|
||||
fileService.save(newFile);
|
||||
} catch (Exception e) {
|
||||
|
||||
@@ -1,8 +1,5 @@
|
||||
package cn.lili.controller.security;
|
||||
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.common.security.CustomAccessDeniedHandler;
|
||||
import cn.lili.common.properties.IgnoredUrlsProperties;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.context.annotation.Configuration;
|
||||
@@ -25,19 +22,10 @@ import org.springframework.web.cors.CorsConfigurationSource;
|
||||
public class CommonSecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
|
||||
|
||||
/**
|
||||
* 忽略验权配置
|
||||
*/
|
||||
@Autowired
|
||||
private IgnoredUrlsProperties ignoredUrlsProperties;
|
||||
/**
|
||||
* spring security -》 权限不足处理
|
||||
*/
|
||||
@Autowired
|
||||
private CustomAccessDeniedHandler accessDeniedHandler;
|
||||
@Autowired
|
||||
private Cache<String> cache;
|
||||
@Autowired
|
||||
private CorsConfigurationSource corsConfigurationSource;
|
||||
|
||||
@Override
|
||||
|
||||
@@ -121,6 +121,8 @@ ignored:
|
||||
- /source/**
|
||||
- /common/common/slider/**
|
||||
- /common/common/sms/**
|
||||
- /common/common/logo
|
||||
- /common/common/site
|
||||
- /druid/**
|
||||
- /swagger-ui.html
|
||||
- /doc.html
|
||||
@@ -188,18 +190,6 @@ lili:
|
||||
interfereNum: 0
|
||||
#允许误差像素
|
||||
faultTolerant: 3
|
||||
#短信模版配置
|
||||
sms:
|
||||
#登录
|
||||
LOGIN: SMS_205755300
|
||||
#注册
|
||||
REGISTER: SMS_205755298
|
||||
#找回密码
|
||||
FIND_USER: SMS_205755301
|
||||
#设置密码
|
||||
UPDATE_PASSWORD: SMS_205755297
|
||||
#支付密码
|
||||
WALLET_PASSWORD: SMS_205755301
|
||||
system:
|
||||
isTestModel: true
|
||||
statistics:
|
||||
|
||||
@@ -20,6 +20,22 @@
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<appender name="RocketmqClientAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${LOG_FILE_PATH}/rocketmq.log</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_PATH}/rocketmq/rocketmq-%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<maxHistory>30</maxHistory>
|
||||
<totalSizeCap>30MB</totalSizeCap>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>%d{yy-MM-dd.HH:mm:ss.SSS} [%-16t] %-5p %-22c{0} %X{ServiceId} - %m%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
<logger name="RocketmqClient" additivity="false">
|
||||
<level value="info" />
|
||||
<appender-ref ref="RocketmqClientAppender"/>
|
||||
</logger>
|
||||
|
||||
<!--输出到elk的LOGSTASH-->
|
||||
<appender name="LOGSTASH" class="net.logstash.logback.appender.LogstashTcpSocketAppender">
|
||||
<!-- 配置elk日志收集 配饰的是 LOGSTASH 的地址-->
|
||||
|
||||
@@ -20,25 +20,29 @@ management:
|
||||
exposure:
|
||||
include: '*'
|
||||
spring:
|
||||
mail:
|
||||
host: smtp.qq.com
|
||||
port: 465
|
||||
username: lifenlong@foxmail.com
|
||||
password: dirpxpqgfvysbefh
|
||||
protocol: smtps
|
||||
properties:
|
||||
mail:
|
||||
smtp:
|
||||
auth: true
|
||||
starttls:
|
||||
enable: true
|
||||
|
||||
# 要在其中注册的Spring Boot Admin Server的URL。
|
||||
boot:
|
||||
admin:
|
||||
client:
|
||||
url: http://192.168.0.116:8000
|
||||
# mongodb
|
||||
data:
|
||||
mongodb:
|
||||
uri: 192.168.0.116:27017
|
||||
database: lilishop
|
||||
username: root
|
||||
password: lilishop
|
||||
authentication-database: admin
|
||||
# replica-set-name: mongoreplset
|
||||
url: http://127.0.0.1:8000
|
||||
cache:
|
||||
type: redis
|
||||
# Redis
|
||||
redis:
|
||||
host: 192.168.0.116
|
||||
host: 127.0.0.1
|
||||
port: 6379
|
||||
password: lilishop
|
||||
lettuce:
|
||||
@@ -69,7 +73,7 @@ spring:
|
||||
default-datasource:
|
||||
type: com.alibaba.druid.pool.DruidDataSource
|
||||
driverClassName: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://192.168.0.116:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
url: jdbc:mysql://127.0.0.1:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
username: root
|
||||
password: lilishop
|
||||
maxActive: 50
|
||||
@@ -128,6 +132,7 @@ ignored:
|
||||
- /store/passport/login/refresh/**
|
||||
- /common/common/slider/**
|
||||
- /common/common/sms/**
|
||||
- /common/common/site
|
||||
- /buyer/payment/cashier/**
|
||||
- /buyer/other/pageData/**
|
||||
- /buyer/other/article/**
|
||||
@@ -191,7 +196,6 @@ logging:
|
||||
cn.lili: info
|
||||
# org.hibernate: debug
|
||||
# org.springframework: debug
|
||||
# org.springframework.data.mongodb.core: debug
|
||||
file:
|
||||
# 指定路径
|
||||
path: logs
|
||||
@@ -218,25 +222,12 @@ lili:
|
||||
interfereNum: 1
|
||||
#允许误差像素
|
||||
faultTolerant: 3
|
||||
#短信模版配置
|
||||
sms:
|
||||
#登录
|
||||
LOGIN: SMS_205755300
|
||||
#注册
|
||||
REGISTER: SMS_205755298
|
||||
#找回密码
|
||||
FIND_USER: SMS_205755301
|
||||
#设置密码
|
||||
UPDATE_PASSWORD: SMS_205755297
|
||||
#支付密码
|
||||
WALLET_PASSWORD: SMS_205755301
|
||||
system:
|
||||
isDemoSite: false
|
||||
isTestModel: true
|
||||
# 脱敏级别:
|
||||
# 0:不做脱敏处理
|
||||
# 1:管理端用户手机号等信息脱敏
|
||||
# 2:商家端信息脱敏(为2时,表示管理端,商家端同时脱敏)
|
||||
# 脱敏级别:
|
||||
# 0:不做脱敏处理
|
||||
# 1:管理端用户手机号等信息脱敏
|
||||
# 2:商家端信息脱敏(为2时,表示管理端,商家端同时脱敏)
|
||||
sensitiveLevel: 1
|
||||
|
||||
statistics:
|
||||
@@ -250,16 +241,16 @@ lili:
|
||||
sk: zhNKVrJK6UPOhqIjn8AQvG37b9sz6
|
||||
#域名
|
||||
domain:
|
||||
pc: http://192.168.0.116:8888
|
||||
wap: http://192.168.0.116:8888
|
||||
seller: http://192.168.0.116:8888
|
||||
admin: http://192.168.0.116:8888
|
||||
pc: http://127.0.0.1:8888
|
||||
wap: http://127.0.0.1:8888
|
||||
seller: http://127.0.0.1:8888
|
||||
admin: http://127.0.0.1:8888
|
||||
#api地址
|
||||
api:
|
||||
buyer: https://z171l91606.51mypc.cn
|
||||
base: http://192.168.0.116:8888
|
||||
manager: http://192.168.0.116:8888
|
||||
seller: http://192.168.0.116:8888
|
||||
base: http://127.0.0.1:8888
|
||||
manager: http://127.0.0.1:8888
|
||||
seller: http://127.0.0.1:8888
|
||||
|
||||
# jwt 细节设定
|
||||
jwt-setting:
|
||||
@@ -278,7 +269,7 @@ lili:
|
||||
data:
|
||||
elasticsearch:
|
||||
cluster-name: elasticsearch
|
||||
cluster-nodes: 192.168.0.116:9200
|
||||
cluster-nodes: 127.0.0.1:9200
|
||||
index:
|
||||
number-of-replicas: 0
|
||||
number-of-shards: 3
|
||||
@@ -289,26 +280,28 @@ lili:
|
||||
# password: LiLiShopES
|
||||
|
||||
logstash:
|
||||
server: 192.168.0.116:4560
|
||||
server: 127.0.0.1:4560
|
||||
rocketmq:
|
||||
promotion-topic: lili_promotion_topic
|
||||
promotion-group: lili_promotion_group
|
||||
msg-ext-topic: lili_msg_topic
|
||||
msg-ext-group: lili_msg_group
|
||||
goods-topic: lili_goods_topic
|
||||
goods-group: lili_goods_group
|
||||
order-topic: lili_order_topic
|
||||
order-group: lili_order_group
|
||||
member-topic: lili_member_topic
|
||||
member-group: lili_member_group
|
||||
other-topic: lili_other_topic
|
||||
other-group: lili_other_group
|
||||
notice-topic: lili_notice_topic
|
||||
notice-group: lili_notice_group
|
||||
notice-send-topic: lili_send_notice_topic
|
||||
notice-send-group: lili_send_notice_group
|
||||
promotion-topic: shop_lili_promotion_topic
|
||||
promotion-group: shop_lili_promotion_group
|
||||
msg-ext-topic: shop_lili_msg_topic
|
||||
msg-ext-group: shop_lili_msg_group
|
||||
goods-topic: shop_lili_goods_topic
|
||||
goods-group: shop_lili_goods_group
|
||||
order-topic: shop_lili_order_topic
|
||||
order-group: shop_lili_order_group
|
||||
member-topic: shop_lili_member_topic
|
||||
member-group: shop_lili_member_group
|
||||
other-topic: shop_lili_other_topic
|
||||
other-group: shop_lili_other_group
|
||||
notice-topic: shop_lili_notice_topic
|
||||
notice-group: shop_lili_notice_group
|
||||
notice-send-topic: shop_lili_send_notice_topic
|
||||
notice-send-group: shop_lili_send_notice_group
|
||||
after-sale-topic: shop_lili_after_sale_topic
|
||||
after-sale-group: shop_lili_after_sale_group
|
||||
rocketmq:
|
||||
name-server: 192.168.0.116:9876
|
||||
name-server: 127.0.0.1:9876
|
||||
isVIPChannel: false
|
||||
producer:
|
||||
group: lili_group
|
||||
@@ -317,7 +310,7 @@ rocketmq:
|
||||
xxl:
|
||||
job:
|
||||
admin:
|
||||
addresses: http://192.168.0.116:9001/xxl-job-admin
|
||||
addresses: http://127.0.0.1:9001/xxl-job-admin
|
||||
executor:
|
||||
appname: xxl-job-executor-lilishop
|
||||
address:
|
||||
|
||||
@@ -14,6 +14,7 @@ public class ConsumerApplication {
|
||||
|
||||
public static void main(String[] args) {
|
||||
System.setProperty("es.set.netty.runtime.available.processors", "false");
|
||||
System.setProperty("rocketmq.client.logUseSlf4j","true");
|
||||
SpringApplication.run(ConsumerApplication.class, args);
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,21 @@
|
||||
package cn.lili.event;
|
||||
|
||||
import cn.lili.modules.connect.entity.dto.ConnectAuthUser;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
|
||||
/**
|
||||
* 会员联合登录消息
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2020/11/17 7:13 下午
|
||||
*/
|
||||
public interface MemberConnectLoginEvent {
|
||||
|
||||
/**
|
||||
* 会员联合登录
|
||||
*
|
||||
* @param member 会员
|
||||
* @param authUser 第三方登录
|
||||
*/
|
||||
void memberConnectLogin(Member member, ConnectAuthUser authUser);
|
||||
}
|
||||
@@ -0,0 +1,17 @@
|
||||
package cn.lili.event;
|
||||
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
|
||||
/**
|
||||
* @author chc
|
||||
* @since 2022/6/2114:46
|
||||
*/
|
||||
public interface MemberInfoChangeEvent {
|
||||
|
||||
/**
|
||||
* 会员信息更改消息
|
||||
*
|
||||
* @param member 会员信息
|
||||
*/
|
||||
void memberInfoChange(Member member);
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package cn.lili.event;
|
||||
|
||||
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
|
||||
/**
|
||||
* @author chc
|
||||
* @since 2022/6/2114:46
|
||||
*/
|
||||
public interface StoreSettingChangeEvent {
|
||||
|
||||
/**
|
||||
* 店铺信息更改消息
|
||||
*
|
||||
* @param store 店铺信息
|
||||
*/
|
||||
void storeSettingChange(Store store);
|
||||
}
|
||||
@@ -1,23 +1,24 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.hutool.core.date.DateField;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.event.AfterSaleStatusChangeEvent;
|
||||
import cn.lili.event.OrderStatusChangeEvent;
|
||||
import cn.lili.modules.distribution.entity.dos.DistributionOrder;
|
||||
import cn.lili.modules.distribution.entity.enums.DistributionOrderStatusEnum;
|
||||
import cn.lili.modules.distribution.mapper.DistributionOrderMapper;
|
||||
import cn.lili.modules.distribution.service.DistributionOrderService;
|
||||
import cn.lili.modules.order.aftersale.entity.dos.AfterSale;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleStatusEnum;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.DistributionSetting;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
|
||||
/**
|
||||
* 分销订单入库
|
||||
*
|
||||
@@ -26,26 +27,21 @@ import javax.annotation.Resource;
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class DistributionOrderExecute implements OrderStatusChangeEvent, EveryDayExecute, AfterSaleStatusChangeEvent {
|
||||
public class DistributionOrderExecute implements OrderStatusChangeEvent, AfterSaleStatusChangeEvent {
|
||||
|
||||
/**
|
||||
* 分销订单
|
||||
*/
|
||||
@Autowired
|
||||
private DistributionOrderService distributionOrderService;
|
||||
/**
|
||||
* 分销订单持久层
|
||||
*/
|
||||
@Resource
|
||||
private DistributionOrderMapper distributionOrderMapper;
|
||||
|
||||
|
||||
@Override
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
|
||||
switch (orderMessage.getNewStatus()) {
|
||||
//订单带校验/订单代发货,则记录分销信息
|
||||
//订单带校验/订单代发货/待自提,则记录分销信息
|
||||
case TAKE:
|
||||
case STAY_PICKED_UP:
|
||||
case UNDELIVERED: {
|
||||
//记录分销订单
|
||||
distributionOrderService.calculationDistribution(orderMessage.getOrderSn());
|
||||
@@ -62,23 +58,10 @@ public class DistributionOrderExecute implements OrderStatusChangeEvent, EveryDa
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void execute() {
|
||||
//计算分销提佣
|
||||
distributionOrderMapper.rebate(DistributionOrderStatusEnum.WAIT_BILL.name(), new DateTime());
|
||||
|
||||
//修改分销订单状态
|
||||
distributionOrderService.update(new LambdaUpdateWrapper<DistributionOrder>()
|
||||
.eq(DistributionOrder::getDistributionOrderStatus, DistributionOrderStatusEnum.WAIT_BILL.name())
|
||||
.le(DistributionOrder::getSettleCycle, new DateTime())
|
||||
.set(DistributionOrder::getDistributionOrderStatus, DistributionOrderStatusEnum.WAIT_CASH.name()));
|
||||
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterSaleStatusChange(AfterSale afterSale) {
|
||||
if (afterSale.getServiceStatus().equals(AfterSaleStatusEnum.COMPLETE.name())) {
|
||||
distributionOrderService.refundOrder(afterSale.getSn());
|
||||
distributionOrderService.refundOrder(afterSale);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -19,6 +19,7 @@ import cn.lili.modules.order.cart.entity.vo.CartVO;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dos.OrderItem;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderSearchParams;
|
||||
import cn.lili.modules.order.order.entity.dto.PriceDetailDTO;
|
||||
import cn.lili.modules.order.order.entity.enums.*;
|
||||
import cn.lili.modules.order.order.service.OrderItemService;
|
||||
@@ -96,6 +97,15 @@ public class FullDiscountExecute implements TradeEvent, OrderStatusChangeEvent {
|
||||
if (orderMessage.getNewStatus().equals(OrderStatusEnum.PAID)) {
|
||||
log.debug("满减活动,订单状态操作 {}", CachePrefix.ORDER.getPrefix() + orderMessage.getOrderSn());
|
||||
renderGift(JSONUtil.toBean(cache.getString(CachePrefix.ORDER.getPrefix() + orderMessage.getOrderSn()), CartVO.class), orderMessage);
|
||||
} else if (orderMessage.getNewStatus().equals(OrderStatusEnum.CANCELLED)) {
|
||||
log.debug("满减活动,取消订单状态操作 {}", CachePrefix.ORDER.getPrefix() + orderMessage.getOrderSn());
|
||||
OrderSearchParams searchParams = new OrderSearchParams();
|
||||
searchParams.setParentOrderSn(orderMessage.getOrderSn());
|
||||
searchParams.setOrderPromotionType(OrderPromotionTypeEnum.GIFT.name());
|
||||
List<Order> orders = orderService.queryListByParams(searchParams);
|
||||
if (orders != null && !orders.isEmpty()) {
|
||||
orderService.systemCancel(orders.get(0).getSn(),"主订单取消,赠送订单字段自动取消",true);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -190,6 +200,7 @@ public class FullDiscountExecute implements TradeEvent, OrderStatusChangeEvent {
|
||||
BeanUtil.copyProperties(priceDetailDTO, order, "id");
|
||||
//生成订单参数
|
||||
order.setSn(SnowFlake.createStr("G"));
|
||||
order.setParentOrderSn(originOrder.getSn());
|
||||
order.setOrderPromotionType(OrderPromotionTypeEnum.GIFT.name());
|
||||
order.setOrderStatus(OrderStatusEnum.UNPAID.name());
|
||||
order.setPayStatus(PayStatusEnum.PAID.name());
|
||||
|
||||
@@ -1,12 +1,22 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.cache.CachePrefix;
|
||||
import cn.lili.event.GoodsCommentCompleteEvent;
|
||||
import cn.lili.event.StoreSettingChangeEvent;
|
||||
import cn.lili.modules.goods.entity.dos.GoodsSku;
|
||||
import cn.lili.modules.goods.entity.dto.GoodsSearchParams;
|
||||
import cn.lili.modules.goods.service.GoodsService;
|
||||
import cn.lili.modules.goods.service.GoodsSkuService;
|
||||
import cn.lili.modules.member.entity.dos.MemberEvaluation;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 商品SKU变化
|
||||
*
|
||||
@@ -14,7 +24,7 @@ import org.springframework.stereotype.Service;
|
||||
* @since 2020-07-03 11:20
|
||||
*/
|
||||
@Service
|
||||
public class GoodsSkuExecute implements GoodsCommentCompleteEvent {
|
||||
public class GoodsSkuExecute implements GoodsCommentCompleteEvent, StoreSettingChangeEvent {
|
||||
|
||||
/**
|
||||
* 商品
|
||||
@@ -22,9 +32,26 @@ public class GoodsSkuExecute implements GoodsCommentCompleteEvent {
|
||||
@Autowired
|
||||
private GoodsSkuService goodsSkuService;
|
||||
|
||||
@Autowired
|
||||
private GoodsService goodsService;
|
||||
|
||||
@Autowired
|
||||
private Cache cache;
|
||||
|
||||
@Override
|
||||
public void goodsComment(MemberEvaluation memberEvaluation) {
|
||||
goodsSkuService.updateGoodsSkuCommentNum(memberEvaluation.getSkuId());
|
||||
goodsService.updateGoodsCommentNum(memberEvaluation.getGoodsId(), memberEvaluation.getSkuId());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void storeSettingChange(Store store) {
|
||||
//修改数据后,清除商品索引
|
||||
GoodsSearchParams goodsSearchParams = new GoodsSearchParams();
|
||||
goodsSearchParams.setStoreId(store.getId());
|
||||
List<String> goodsSkuKeys = new ArrayList<>();
|
||||
for (GoodsSku goodsSku : goodsSkuService.getGoodsSkuByList(goodsSearchParams)) {
|
||||
goodsSkuKeys.add(CachePrefix.GOODS_SKU.getPrefix()+goodsSku.getId());
|
||||
}
|
||||
cache.multiDel(goodsSkuKeys);
|
||||
}
|
||||
}
|
||||
|
||||
60
consumer/src/main/java/cn/lili/event/impl/ImTalkExecute.java
Normal file
60
consumer/src/main/java/cn/lili/event/impl/ImTalkExecute.java
Normal file
@@ -0,0 +1,60 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.lili.event.MemberInfoChangeEvent;
|
||||
import cn.lili.event.StoreSettingChangeEvent;
|
||||
import cn.lili.modules.im.entity.dos.ImTalk;
|
||||
import cn.lili.modules.im.service.ImTalkService;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* Im对话消息
|
||||
*
|
||||
* @author chc
|
||||
* @since 2022/6/2114:46
|
||||
*/
|
||||
@Service
|
||||
public class ImTalkExecute implements MemberInfoChangeEvent, StoreSettingChangeEvent {
|
||||
|
||||
@Autowired
|
||||
private ImTalkService imTalkService;
|
||||
|
||||
@Override
|
||||
public void memberInfoChange(Member member) {
|
||||
//当与UserId1相等时
|
||||
List<ImTalk> imTalkList1 = imTalkService.list(new LambdaQueryWrapper<ImTalk>().eq(ImTalk::getUserId1, member.getId()));
|
||||
for (ImTalk imTalk : imTalkList1) {
|
||||
imTalk.setName1(member.getNickName());
|
||||
imTalk.setFace1(member.getFace());
|
||||
}
|
||||
imTalkService.updateBatchById(imTalkList1);
|
||||
List<ImTalk> imTalkList2 = imTalkService.list(new LambdaQueryWrapper<ImTalk>().eq(ImTalk::getUserId2, member.getId()));
|
||||
for (ImTalk imTalk : imTalkList2) {
|
||||
imTalk.setName2(member.getNickName());
|
||||
imTalk.setFace2(member.getFace());
|
||||
}
|
||||
imTalkService.updateBatchById(imTalkList2);
|
||||
}
|
||||
|
||||
@Override
|
||||
public void storeSettingChange(Store store) {
|
||||
//当与UserId1相等时
|
||||
List<ImTalk> imTalkList1 = imTalkService.list(new LambdaQueryWrapper<ImTalk>().eq(ImTalk::getUserId1, store.getId()));
|
||||
for (ImTalk imTalk : imTalkList1) {
|
||||
imTalk.setName1(store.getStoreName());
|
||||
imTalk.setFace1(store.getStoreLogo());
|
||||
}
|
||||
imTalkService.updateBatchById(imTalkList1);
|
||||
List<ImTalk> imTalkList2 = imTalkService.list(new LambdaQueryWrapper<ImTalk>().eq(ImTalk::getUserId2, store.getId()));
|
||||
for (ImTalk imTalk : imTalkList2) {
|
||||
imTalk.setName2(store.getStoreName());
|
||||
imTalk.setFace2(store.getStoreLogo());
|
||||
}
|
||||
imTalkService.updateBatchById(imTalkList2);
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,65 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.hutool.core.collection.ListUtil;
|
||||
import cn.hutool.core.text.CharSequenceUtil;
|
||||
import cn.lili.event.AfterSaleStatusChangeEvent;
|
||||
import cn.lili.event.OrderStatusChangeEvent;
|
||||
import cn.lili.modules.order.aftersale.entity.dos.AfterSale;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderStatusEnum;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleStatusEnum;
|
||||
import cn.lili.modules.promotion.service.MemberCouponService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 会员优惠券执行类
|
||||
*
|
||||
* @author paulG
|
||||
* @since 2022/8/12
|
||||
**/
|
||||
@Service
|
||||
public class MemberCouponExecute implements OrderStatusChangeEvent, AfterSaleStatusChangeEvent {
|
||||
|
||||
/**
|
||||
* 订单
|
||||
*/
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
|
||||
@Autowired
|
||||
private MemberCouponService memberCouponService;
|
||||
|
||||
@Override
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
// 订单取消返还优惠券
|
||||
if (orderMessage.getNewStatus() == OrderStatusEnum.CANCELLED) {
|
||||
this.refundCoupon(orderMessage.getOrderSn());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@Override
|
||||
public void afterSaleStatusChange(AfterSale afterSale) {
|
||||
// 售后完成返还优惠券
|
||||
if (afterSale.getServiceStatus().equals(AfterSaleStatusEnum.COMPLETE.name())) {
|
||||
this.refundCoupon(afterSale.getOrderSn());
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 退款返还优惠券
|
||||
* @param orderSn 订单编号
|
||||
*/
|
||||
private void refundCoupon(String orderSn) {
|
||||
Order order = orderService.getBySn(orderSn);
|
||||
if (CharSequenceUtil.isNotEmpty(order.getUseStoreMemberCouponIds())) {
|
||||
memberCouponService.recoveryMemberCoupon(ListUtil.toList(order.getUseStoreMemberCouponIds().split(",")));
|
||||
}
|
||||
if (CharSequenceUtil.isNotEmpty(order.getUsePlatformMemberCouponId())) {
|
||||
memberCouponService.recoveryMemberCoupon(ListUtil.toList(order.getUsePlatformMemberCouponId().split(",")));
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -1,25 +1,58 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.hutool.core.util.StrUtil;
|
||||
import cn.lili.common.enums.ClientTypeEnum;
|
||||
import cn.lili.event.MemberConnectLoginEvent;
|
||||
import cn.lili.event.MemberLoginEvent;
|
||||
import cn.lili.modules.connect.entity.dto.ConnectAuthUser;
|
||||
import cn.lili.modules.connect.entity.enums.ConnectEnum;
|
||||
import cn.lili.modules.connect.entity.enums.SourceEnum;
|
||||
import cn.lili.modules.connect.service.ConnectService;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.member.service.MemberService;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* 会员自身业务
|
||||
* 会员登录,会员第三方登录
|
||||
*
|
||||
* @author Chopper
|
||||
* @version v1.0
|
||||
* 2022-01-11 11:08
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class MemberExecute implements MemberLoginEvent {
|
||||
public class MemberExecute implements MemberLoginEvent, MemberConnectLoginEvent {
|
||||
@Autowired
|
||||
private MemberService memberService;
|
||||
@Autowired
|
||||
private ConnectService connectService;
|
||||
@Autowired
|
||||
private SettingService settingService;
|
||||
|
||||
@Override
|
||||
public void memberLogin(Member member) {
|
||||
memberService.updateMemberLoginTime(member.getId());
|
||||
}
|
||||
|
||||
@Override
|
||||
public void memberConnectLogin(Member member, ConnectAuthUser authUser) {
|
||||
//保存UnionID
|
||||
if (StrUtil.isNotBlank(authUser.getToken().getUnionId())) {
|
||||
connectService.loginBindUser(member.getId(), authUser.getToken().getUnionId(), authUser.getSource().name());
|
||||
}
|
||||
//保存OpenID
|
||||
if (StrUtil.isNotBlank(authUser.getUuid())) {
|
||||
SourceEnum sourceEnum = SourceEnum.getSourceEnum(authUser.getSource(), authUser.getType());
|
||||
connectService.loginBindUser(member.getId(), authUser.getUuid(), sourceEnum.name());
|
||||
}
|
||||
//保存手机号,判断用户是否存手机号,如果不存在则保存手机号
|
||||
if (StrUtil.isNotBlank(authUser.getPhone())&&StrUtil.isBlank(member.getMobile())) {
|
||||
memberService.changeMobile(member.getId(),member.getMobile());
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,8 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
|
||||
import cn.hutool.core.text.CharSequenceUtil;
|
||||
import cn.lili.common.utils.CurrencyUtil;
|
||||
import cn.lili.common.utils.StringUtils;
|
||||
import cn.lili.event.AfterSaleStatusChangeEvent;
|
||||
import cn.lili.event.GoodsCommentCompleteEvent;
|
||||
import cn.lili.event.MemberRegisterEvent;
|
||||
@@ -15,6 +15,7 @@ import cn.lili.modules.order.aftersale.entity.dos.AfterSale;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderPromotionTypeEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.PayStatusEnum;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleStatusEnum;
|
||||
@@ -104,7 +105,7 @@ public class MemberPointExecute implements MemberRegisterEvent, GoodsCommentComp
|
||||
case COMPLETED: {
|
||||
Order order = orderService.getBySn(orderMessage.getOrderSn());
|
||||
//如果是积分订单 则直接返回
|
||||
if (StringUtils.isNotEmpty(order.getOrderPromotionType())
|
||||
if (CharSequenceUtil.isNotEmpty(order.getOrderPromotionType())
|
||||
&& order.getOrderPromotionType().equals(OrderPromotionTypeEnum.POINTS.name())) {
|
||||
return;
|
||||
}
|
||||
@@ -134,12 +135,16 @@ public class MemberPointExecute implements MemberRegisterEvent, GoodsCommentComp
|
||||
@Override
|
||||
public void afterSaleStatusChange(AfterSale afterSale) {
|
||||
if (afterSale.getServiceStatus().equals(AfterSaleStatusEnum.COMPLETE.name())) {
|
||||
Order order = orderService.getBySn(afterSale.getOrderSn());
|
||||
//获取积分设置
|
||||
PointSetting pointSetting = getPointSetting();
|
||||
if (pointSetting.getConsumer() == 0 || !OrderStatusEnum.COMPLETED.name().equals(order.getOrderStatus())) {
|
||||
return;
|
||||
}
|
||||
//计算扣除积分数量
|
||||
Double point = CurrencyUtil.mul(pointSetting.getMoney(), afterSale.getActualRefundPrice(), 0);
|
||||
Double point = CurrencyUtil.mul(pointSetting.getConsumer(), afterSale.getActualRefundPrice(), 0);
|
||||
//扣除会员积分
|
||||
memberService.updateMemberPoint(point.longValue(), PointTypeEnum.REDUCE.name(), afterSale.getMemberId(), "会员退款,回退积分" + point + "分");
|
||||
memberService.updateMemberPoint(point.longValue(), PointTypeEnum.REDUCE.name(), afterSale.getMemberId(), "会员退款,回退消费赠送积分" + point + "分");
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,8 +1,11 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
|
||||
import cn.lili.event.MemberRegisterEvent;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.event.MemberWithdrawalEvent;
|
||||
import cn.lili.modules.wallet.entity.dto.MemberWalletUpdateDTO;
|
||||
import cn.lili.modules.wallet.entity.dto.MemberWithdrawalMessage;
|
||||
import cn.lili.modules.wallet.entity.enums.DepositServiceTypeEnum;
|
||||
import cn.lili.modules.wallet.entity.enums.WithdrawStatusEnum;
|
||||
import cn.lili.modules.wallet.service.MemberWalletService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -14,14 +17,35 @@ import org.springframework.stereotype.Service;
|
||||
* @since 2020-07-03 11:20
|
||||
*/
|
||||
@Service
|
||||
public class MemberWalletExecute implements MemberRegisterEvent {
|
||||
public class MemberWalletExecute implements MemberWithdrawalEvent {
|
||||
|
||||
@Autowired
|
||||
private MemberWalletService memberWalletService;
|
||||
|
||||
@Override
|
||||
public void memberRegister(Member member) {
|
||||
// 有些情况下,会同时创建一个member_id的两条数据
|
||||
// memberWalletService.save(member.getId(),member.getUsername());
|
||||
public void memberWithdrawal(MemberWithdrawalMessage memberWithdrawalMessage) {
|
||||
switch (WithdrawStatusEnum.valueOf(memberWithdrawalMessage.getStatus())) {
|
||||
case VIA_AUDITING:
|
||||
memberWalletService.withdrawal(memberWithdrawalMessage.getMemberWithdrawApplyId());
|
||||
break;
|
||||
case SUCCESS:
|
||||
//提现成功扣减冻结金额
|
||||
memberWalletService.reduceFrozen(
|
||||
new MemberWalletUpdateDTO(memberWithdrawalMessage.getPrice(), memberWithdrawalMessage.getMemberId(), "提现成功,余额提现",
|
||||
DepositServiceTypeEnum.WALLET_WITHDRAWAL.name()));
|
||||
break;
|
||||
case ERROR:
|
||||
//需要从冻结金额扣减到余额
|
||||
memberWalletService.increaseWithdrawal(new MemberWalletUpdateDTO(memberWithdrawalMessage.getPrice(),
|
||||
memberWithdrawalMessage.getMemberId(), "第三方提现失败,提现金额解冻到余额", DepositServiceTypeEnum.WALLET_WITHDRAWAL.name()));
|
||||
break;
|
||||
case FAIL_AUDITING:
|
||||
//需要从冻结金额扣减到余额
|
||||
memberWalletService.increaseWithdrawal(new MemberWalletUpdateDTO(memberWithdrawalMessage.getPrice(),
|
||||
memberWithdrawalMessage.getMemberId(), "审核拒绝,提现金额解冻到余额", DepositServiceTypeEnum.WALLET_WITHDRAWAL.name()));
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -16,7 +16,6 @@ import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleStatusEnum;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleTypeEnum;
|
||||
import cn.lili.modules.wallet.entity.dto.MemberWithdrawalMessage;
|
||||
import cn.lili.modules.wallet.entity.enums.MemberWithdrawalDestinationEnum;
|
||||
import cn.lili.modules.wallet.entity.enums.WithdrawStatusEnum;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
@@ -59,7 +58,7 @@ public class NoticeMessageExecute implements TradeEvent, OrderStatusChangeEvent,
|
||||
OrderDetailVO orderDetailVO = orderService.queryDetail(orderMessage.getOrderSn());
|
||||
NoticeMessageDTO noticeMessageDTO = new NoticeMessageDTO();
|
||||
//如果订单状态不为空
|
||||
if (orderDetailVO != null) {
|
||||
if (orderDetailVO != null && orderDetailVO.getOrderItems() != null && !orderDetailVO.getOrderItems().isEmpty()) {
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
switch (orderMessage.getNewStatus()) {
|
||||
//如果订单新的状态为已取消 则发送取消订单站内信
|
||||
@@ -179,60 +178,30 @@ public class NoticeMessageExecute implements TradeEvent, OrderStatusChangeEvent,
|
||||
public void memberWithdrawal(MemberWithdrawalMessage memberWithdrawalMessage) {
|
||||
NoticeMessageDTO noticeMessageDTO = new NoticeMessageDTO();
|
||||
noticeMessageDTO.setMemberId(memberWithdrawalMessage.getMemberId());
|
||||
//如果提现状态为申请则发送申请提现站内消息
|
||||
if (memberWithdrawalMessage.getStatus().equals(WithdrawStatusEnum.APPLY.name())) {
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_CREATE);
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
params.put("price", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setParameter(params);
|
||||
//发送提现申请成功消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
}
|
||||
//如果提现状态为通过则发送审核通过站内消息
|
||||
if (memberWithdrawalMessage.getStatus().equals(WithdrawStatusEnum.VIA_AUDITING.name())) {
|
||||
//如果提现到余额
|
||||
if (memberWithdrawalMessage.getDestination().equals(MemberWithdrawalDestinationEnum.WALLET.name())) {
|
||||
//组织参数
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
params.put("income", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setParameter(params);
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
switch (WithdrawStatusEnum.valueOf(memberWithdrawalMessage.getStatus())) {
|
||||
case APPLY:
|
||||
//如果提现状态为申请则发送申请提现站内消息
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_CREATE);
|
||||
break;
|
||||
case FAIL_AUDITING:
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_AUDIT_ERROR);
|
||||
break;
|
||||
case SUCCESS:
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_SUCCESS);
|
||||
//发送提现成功消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
params.put("income", memberWithdrawalMessage.getPrice().toString());
|
||||
params.put("expenditure", "0");
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_CHANGE);
|
||||
noticeMessageDTO.setParameter(params);
|
||||
//发送余额变动消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
}
|
||||
//如果提现到微信
|
||||
if (memberWithdrawalMessage.getDestination().equals(MemberWithdrawalDestinationEnum.WECHAT.name())) {
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
params.put("income", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setParameter(params);
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_WEICHAT_SUCCESS);
|
||||
//发送提现成功消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
|
||||
params.put("income", "0");
|
||||
params.put("expenditure", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_CHANGE);
|
||||
noticeMessageDTO.setParameter(params);
|
||||
//发送余额变动消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
}
|
||||
}
|
||||
//如果提现状态为拒绝则发送审核拒绝站内消息
|
||||
if (memberWithdrawalMessage.getStatus().equals(WithdrawStatusEnum.FAIL_AUDITING.name())) {
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_ERROR);
|
||||
Map<String, String> params = new HashMap<>(2);
|
||||
params.put("price", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setParameter(params);
|
||||
//发送提现申请成功消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
break;
|
||||
case ERROR:
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_ERROR);
|
||||
break;
|
||||
case VIA_AUDITING:
|
||||
noticeMessageDTO.setNoticeMessageNodeEnum(NoticeMessageNodeEnum.WALLET_WITHDRAWAL_AUDIT_SUCCESS);
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
params.put("price", memberWithdrawalMessage.getPrice().toString());
|
||||
noticeMessageDTO.setParameter(params);
|
||||
//发送提现申请消息
|
||||
noticeMessageService.noticeMessage(noticeMessageDTO);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -1,12 +1,25 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.lili.common.utils.CurrencyUtil;
|
||||
import cn.lili.event.AfterSaleStatusChangeEvent;
|
||||
import cn.lili.event.TradeEvent;
|
||||
import cn.lili.modules.order.aftersale.entity.dos.AfterSale;
|
||||
import cn.lili.modules.order.aftersale.entity.vo.AfterSaleSearchParams;
|
||||
import cn.lili.modules.order.aftersale.service.AfterSaleService;
|
||||
import cn.lili.modules.order.cart.entity.dto.TradeDTO;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dos.OrderItem;
|
||||
import cn.lili.modules.order.order.entity.enums.RefundStatusEnum;
|
||||
import cn.lili.modules.order.order.service.OrderItemService;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.order.service.TradeService;
|
||||
import cn.lili.modules.order.trade.entity.enums.AfterSaleStatusEnum;
|
||||
import cn.lili.modules.payment.entity.enums.PaymentMethodEnum;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 订单状态处理类
|
||||
*
|
||||
@@ -14,11 +27,17 @@ import org.springframework.stereotype.Service;
|
||||
* @since 2020-07-03 11:20
|
||||
**/
|
||||
@Service
|
||||
public class OrderStatusHandlerExecute implements TradeEvent {
|
||||
public class OrderStatusHandlerExecute implements TradeEvent, AfterSaleStatusChangeEvent {
|
||||
|
||||
|
||||
@Autowired
|
||||
private TradeService tradeService;
|
||||
@Autowired
|
||||
private OrderItemService orderItemService;
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
@Autowired
|
||||
private AfterSaleService afterSaleService;
|
||||
|
||||
@Override
|
||||
public void orderCreate(TradeDTO tradeDTO) {
|
||||
@@ -28,4 +47,41 @@ public class OrderStatusHandlerExecute implements TradeEvent {
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
@Override
|
||||
public void afterSaleStatusChange(AfterSale afterSale) {
|
||||
Order order = orderService.getBySn(afterSale.getOrderSn());
|
||||
OrderItem orderItem = orderItemService.getBySn(afterSale.getOrderItemSn());
|
||||
|
||||
if (afterSale.getServiceStatus().equals(AfterSaleStatusEnum.COMPLETE.name())) {
|
||||
if (orderItem.getReturnGoodsNumber().equals(orderItem.getNum())) {
|
||||
orderItem.setIsRefund(RefundStatusEnum.ALL_REFUND.name());
|
||||
} else {
|
||||
orderItem.setIsRefund(RefundStatusEnum.PART_REFUND.name());
|
||||
}
|
||||
orderItem.setRefundPrice(CurrencyUtil.add(afterSale.getActualRefundPrice(), orderItem.getRefundPrice()));
|
||||
orderItemService.updateByAfterSale(orderItem);
|
||||
|
||||
//循环订单货物,判断是否已经全部售后
|
||||
List<OrderItem> orderItems = orderItemService.getByOrderSn(afterSale.getOrderSn());
|
||||
// 总退货数量
|
||||
int returnCount = 0;
|
||||
// 总购买数量
|
||||
int deliverCount = 0;
|
||||
//获取订单货物已完成售后的数量
|
||||
AfterSaleSearchParams saleSearchParams = new AfterSaleSearchParams();
|
||||
saleSearchParams.setOrderSn(afterSale.getOrderSn());
|
||||
saleSearchParams.setServiceStatus(AfterSaleStatusEnum.COMPLETE.name());
|
||||
List<AfterSale> afterSales = afterSaleService.exportAfterSaleOrder(saleSearchParams);
|
||||
for (AfterSale sale : afterSales) {
|
||||
returnCount += sale.getNum();
|
||||
}
|
||||
//订单货物购买总数
|
||||
deliverCount = order.getGoodsNum();
|
||||
if (returnCount == deliverCount) {
|
||||
orderService.systemCancel(afterSale.getOrderSn(),"订单货物全部退款",false);
|
||||
}
|
||||
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -5,8 +5,10 @@ import cn.lili.common.utils.SpringContextUtil;
|
||||
import cn.lili.event.OrderStatusChangeEvent;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.PayStatusEnum;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.order.service.StoreFlowService;
|
||||
import cn.lili.modules.payment.entity.RefundLog;
|
||||
import cn.lili.modules.payment.kit.Payment;
|
||||
import cn.lili.modules.payment.entity.enums.PaymentMethodEnum;
|
||||
@@ -29,56 +31,40 @@ public class PaymentExecute implements OrderStatusChangeEvent {
|
||||
*/
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
@Autowired
|
||||
private StoreFlowService storeFlowService;
|
||||
|
||||
@Override
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
|
||||
switch (orderMessage.getNewStatus()) {
|
||||
case CANCELLED:
|
||||
Order order = orderService.getBySn(orderMessage.getOrderSn());
|
||||
if (orderMessage.getNewStatus() == OrderStatusEnum.CANCELLED) {
|
||||
Order order = orderService.getBySn(orderMessage.getOrderSn());
|
||||
|
||||
//如果未付款,则不去要退回相关代码执行
|
||||
if (order.getPayStatus().equals(PayStatusEnum.UNPAID.name())) {
|
||||
return;
|
||||
}
|
||||
PaymentMethodEnum paymentMethodEnum = PaymentMethodEnum.valueOf(order.getPaymentMethod());
|
||||
|
||||
//获取支付方式
|
||||
Payment payment =
|
||||
(Payment) SpringContextUtil.getBean(paymentMethodEnum.getPlugin());
|
||||
|
||||
RefundLog refundLog = RefundLog.builder()
|
||||
.isRefund(false)
|
||||
.totalAmount(order.getFlowPrice())
|
||||
.payPrice(order.getFlowPrice())
|
||||
.memberId(order.getMemberId())
|
||||
.paymentName(order.getPaymentMethod())
|
||||
.afterSaleNo("订单取消")
|
||||
.orderSn(order.getSn())
|
||||
.paymentReceivableNo(order.getReceivableNo())
|
||||
.outOrderNo("AF" + SnowFlake.getIdStr())
|
||||
.refundReason("订单取消")
|
||||
.build();
|
||||
payment.refund(refundLog);
|
||||
|
||||
//如果未付款,则不去要退回相关代码执行
|
||||
if (order.getPayStatus().equals(PayStatusEnum.UNPAID.name())) {
|
||||
return;
|
||||
}
|
||||
PaymentMethodEnum paymentMethodEnum = PaymentMethodEnum.valueOf(order.getPaymentMethod());
|
||||
//进行退款操作
|
||||
switch (paymentMethodEnum) {
|
||||
case WALLET:
|
||||
case ALIPAY:
|
||||
case WECHAT:
|
||||
//获取支付方式
|
||||
Payment payment =
|
||||
(Payment) SpringContextUtil.getBean(paymentMethodEnum.getPlugin());
|
||||
|
||||
RefundLog refundLog = RefundLog.builder()
|
||||
.isRefund(false)
|
||||
.totalAmount(order.getFlowPrice())
|
||||
.payPrice(order.getFlowPrice())
|
||||
.memberId(order.getMemberId())
|
||||
.paymentName(order.getPaymentMethod())
|
||||
.afterSaleNo("订单取消")
|
||||
.orderSn(order.getSn())
|
||||
.paymentReceivableNo(order.getReceivableNo())
|
||||
.outOrderNo("AF" + SnowFlake.getIdStr())
|
||||
.outOrderNo("AF" + SnowFlake.getIdStr())
|
||||
.refundReason("订单取消")
|
||||
.build();
|
||||
payment.cancel(refundLog);
|
||||
break;
|
||||
case BANK_TRANSFER:
|
||||
break;
|
||||
default:
|
||||
log.error("订单支付执行异常,订单编号:{}", orderMessage.getOrderSn());
|
||||
break;
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
@@ -1,18 +1,17 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.hutool.core.text.CharSequenceUtil;
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.cache.CachePrefix;
|
||||
import cn.lili.event.MemberRegisterEvent;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.promotion.entity.dos.CouponActivity;
|
||||
import cn.lili.modules.member.service.MemberService;
|
||||
import cn.lili.modules.promotion.entity.dto.CouponActivityTrigger;
|
||||
import cn.lili.modules.promotion.entity.enums.CouponActivityTypeEnum;
|
||||
import cn.lili.modules.promotion.entity.enums.PromotionsStatusEnum;
|
||||
import cn.lili.modules.promotion.service.CouponActivityService;
|
||||
import cn.lili.modules.promotion.tools.PromotionTools;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 注册赠券活动
|
||||
*
|
||||
@@ -25,6 +24,12 @@ public class RegisteredCouponActivityExecute implements MemberRegisterEvent {
|
||||
@Autowired
|
||||
private CouponActivityService couponActivityService;
|
||||
|
||||
|
||||
@Autowired
|
||||
private MemberService memberService;
|
||||
@Autowired
|
||||
private Cache cache;
|
||||
|
||||
/**
|
||||
* 获取进行中的注册赠券的优惠券活动
|
||||
* 发送注册赠券
|
||||
@@ -33,9 +38,22 @@ public class RegisteredCouponActivityExecute implements MemberRegisterEvent {
|
||||
*/
|
||||
@Override
|
||||
public void memberRegister(Member member) {
|
||||
List<CouponActivity> couponActivities = couponActivityService.list(new QueryWrapper<CouponActivity>()
|
||||
.eq("coupon_activity_type", CouponActivityTypeEnum.REGISTERED.name())
|
||||
.and(PromotionTools.queryPromotionStatus(PromotionsStatusEnum.START)));
|
||||
couponActivityService.registered(couponActivities, member);
|
||||
//用户注册赠券
|
||||
couponActivityService.trigger(CouponActivityTrigger.builder()
|
||||
.nickName(member.getNickName())
|
||||
.userId(member.getId())
|
||||
.couponActivityTypeEnum(CouponActivityTypeEnum.REGISTERED)
|
||||
.build());
|
||||
//邀请人赠券
|
||||
String memberId = (String) cache.get(CachePrefix.INVITER.getPrefix() + member.getId());
|
||||
if (CharSequenceUtil.isNotEmpty(memberId)) {
|
||||
//邀请人
|
||||
Member inviter = memberService.getById(memberId);
|
||||
couponActivityService.trigger(CouponActivityTrigger.builder()
|
||||
.nickName(inviter.getNickName())
|
||||
.userId(inviter.getId())
|
||||
.couponActivityTypeEnum(CouponActivityTypeEnum.INVITE_NEW)
|
||||
.build());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -28,7 +28,9 @@ import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.ArrayList;
|
||||
import java.util.Arrays;
|
||||
import java.util.List;
|
||||
import java.util.Objects;
|
||||
|
||||
/**
|
||||
* 库存扣减,他表示了订单状态是否出库成功
|
||||
@@ -94,7 +96,7 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
keys.add(GoodsSkuService.getStockCacheKey(orderItem.getSkuId()));
|
||||
int i = -orderItem.getNum();
|
||||
values.add(Integer.toString(i));
|
||||
setPromotionStock(keys, values, orderItem);
|
||||
setPromotionStock(keys, values, orderItem, true);
|
||||
}
|
||||
|
||||
List<Integer> stocks = cache.multiGet(keys);
|
||||
@@ -132,6 +134,7 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
keys.add(GoodsSkuService.getStockCacheKey(orderItem.getSkuId()));
|
||||
int i = orderItem.getNum();
|
||||
values.add(Integer.toString(i));
|
||||
setPromotionStock(keys, values, orderItem, false);
|
||||
}
|
||||
//批量脚本执行库存回退
|
||||
Boolean skuResult = stringRedisTemplate.execute(quantityScript, keys, values.toArray());
|
||||
@@ -156,7 +159,7 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
* @param stocks
|
||||
*/
|
||||
private void checkStocks(List<Integer> stocks, OrderDetailVO order) {
|
||||
if (order.getOrderItems().size() == stocks.size()) {
|
||||
if (!stocks.isEmpty() && order.getOrderItems().size() == stocks.size() && stocks.stream().anyMatch(Objects::nonNull)) {
|
||||
return;
|
||||
}
|
||||
initSkuCache(order.getOrderItems());
|
||||
@@ -188,28 +191,33 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
//如果促销类型需要库存判定,则做对应处理
|
||||
orderItems.forEach(orderItem -> {
|
||||
if (orderItem.getPromotionType() != null) {
|
||||
//如果此促销有库存概念,则计入
|
||||
if (PromotionTypeEnum.haveStock(orderItem.getPromotionType())) {
|
||||
String[] skuPromotions = orderItem.getPromotionType().split(",");
|
||||
for (int i = 0; i < skuPromotions.length; i++) {
|
||||
int currentIndex = i;
|
||||
//如果此促销有库存概念,则计入
|
||||
Arrays.stream(PromotionTypeEnum.haveStockPromotion).filter(promotionTypeEnum -> promotionTypeEnum.name().equals(skuPromotions[currentIndex]))
|
||||
.findFirst()
|
||||
.ifPresent(promotionTypeEnum -> {
|
||||
String promotionId = orderItem.getPromotionId().split(",")[currentIndex];
|
||||
String cacheKey = PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, promotionId, orderItem.getSkuId());
|
||||
|
||||
PromotionTypeEnum promotionTypeEnum = PromotionTypeEnum.valueOf(orderItem.getPromotionType());
|
||||
|
||||
String cacheKey = PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, orderItem.getPromotionId(), orderItem.getSkuId());
|
||||
|
||||
switch (promotionTypeEnum) {
|
||||
case KANJIA:
|
||||
cache.put(cacheKey, kanjiaActivityGoodsService.getKanjiaGoodsBySkuId(orderItem.getSkuId()).getStock());
|
||||
return;
|
||||
case POINTS_GOODS:
|
||||
cache.put(cacheKey, pointsGoodsService.getPointsGoodsDetailBySkuId(orderItem.getSkuId()).getActiveStock());
|
||||
return;
|
||||
case SECKILL:
|
||||
case PINTUAN:
|
||||
cache.put(cacheKey, promotionGoodsService.getPromotionGoodsStock(promotionTypeEnum, orderItem.getPromotionId(), orderItem.getSkuId()));
|
||||
return;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
switch (promotionTypeEnum) {
|
||||
case KANJIA:
|
||||
cache.put(cacheKey, kanjiaActivityGoodsService.getKanjiaGoodsBySkuId(orderItem.getSkuId()).getStock());
|
||||
return;
|
||||
case POINTS_GOODS:
|
||||
cache.put(cacheKey, pointsGoodsService.getPointsGoodsDetailBySkuId(orderItem.getSkuId()).getActiveStock());
|
||||
return;
|
||||
case SECKILL:
|
||||
case PINTUAN:
|
||||
cache.put(cacheKey, promotionGoodsService.getPromotionGoodsStock(promotionTypeEnum, promotionId, orderItem.getSkuId()));
|
||||
return;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
});
|
||||
}
|
||||
@@ -221,7 +229,7 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
* @param orderSn 失败入库订单信息
|
||||
*/
|
||||
private void errorOrder(String orderSn) {
|
||||
orderService.systemCancel(orderSn, outOfStockMessage);
|
||||
orderService.systemCancel(orderSn, outOfStockMessage, true);
|
||||
}
|
||||
|
||||
|
||||
@@ -232,16 +240,20 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
* @param values 缓存value值
|
||||
* @param sku 购物车信息
|
||||
*/
|
||||
private void setPromotionStock(List<String> keys, List<String> values, OrderItem sku) {
|
||||
private void setPromotionStock(List<String> keys, List<String> values, OrderItem sku, boolean deduction) {
|
||||
if (sku.getPromotionType() != null) {
|
||||
//如果此促销有库存概念,则计入
|
||||
if (!PromotionTypeEnum.haveStock(sku.getPromotionType())) {
|
||||
return;
|
||||
String[] skuPromotions = sku.getPromotionType().split(",");
|
||||
for (int i = 0; i < skuPromotions.length; i++) {
|
||||
int currentIndex = i;
|
||||
Arrays.stream(PromotionTypeEnum.haveStockPromotion).filter(promotionTypeEnum -> promotionTypeEnum.name().equals(skuPromotions[currentIndex]))
|
||||
.findFirst()
|
||||
.ifPresent(promotionTypeEnum -> {
|
||||
keys.add(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, sku.getPromotionId().split(",")[currentIndex], sku.getSkuId()));
|
||||
int num = deduction ? -sku.getNum() : sku.getNum();
|
||||
values.add(Integer.toString(num));
|
||||
});
|
||||
}
|
||||
PromotionTypeEnum promotionTypeEnum = PromotionTypeEnum.valueOf(sku.getPromotionType());
|
||||
keys.add(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, sku.getPromotionId(), sku.getSkuId()));
|
||||
int i = -sku.getNum();
|
||||
values.add(Integer.toString(i));
|
||||
}
|
||||
}
|
||||
|
||||
@@ -276,41 +288,51 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
goodsSku.setId(orderItem.getSkuId());
|
||||
goodsSku.setGoodsId(orderItem.getGoodsId());
|
||||
//如果有促销信息
|
||||
if (null != orderItem.getPromotionType() && null != orderItem.getPromotionId() && PromotionTypeEnum.haveStock(orderItem.getPromotionType())) {
|
||||
if (null != orderItem.getPromotionType() && null != orderItem.getPromotionId()) {
|
||||
//如果促销有库存信息
|
||||
PromotionTypeEnum promotionTypeEnum = PromotionTypeEnum.valueOf(orderItem.getPromotionType());
|
||||
String[] skuPromotions = orderItem.getPromotionType().split(",");
|
||||
for (int i = 0; i < skuPromotions.length; i++) {
|
||||
int currentIndex = i;
|
||||
Arrays.stream(PromotionTypeEnum.haveStockPromotion).filter(promotionTypeEnum -> promotionTypeEnum.name().equals(skuPromotions[currentIndex]))
|
||||
.findFirst()
|
||||
.ifPresent(promotionTypeEnum -> {
|
||||
//修改砍价商品库存
|
||||
String promotionId = orderItem.getPromotionId().split(",")[currentIndex];
|
||||
|
||||
//修改砍价商品库存
|
||||
if (promotionTypeEnum.equals(PromotionTypeEnum.KANJIA)) {
|
||||
KanjiaActivity kanjiaActivity = kanjiaActivityService.getById(orderItem.getPromotionId());
|
||||
KanjiaActivityGoodsDTO kanjiaActivityGoodsDTO = kanjiaActivityGoodsService.getKanjiaGoodsDetail(kanjiaActivity.getKanjiaActivityGoodsId());
|
||||
//修改砍价商品库存
|
||||
if (promotionTypeEnum.equals(PromotionTypeEnum.KANJIA)) {
|
||||
KanjiaActivity kanjiaActivity = kanjiaActivityService.getById(promotionId);
|
||||
KanjiaActivityGoodsDTO kanjiaActivityGoodsDTO = kanjiaActivityGoodsService.getKanjiaGoodsDetail(kanjiaActivity.getKanjiaActivityGoodsId());
|
||||
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, orderItem.getPromotionId(), orderItem.getSkuId())).toString());
|
||||
kanjiaActivityGoodsDTO.setStock(stock);
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, promotionId, orderItem.getSkuId())).toString());
|
||||
kanjiaActivityGoodsDTO.setStock(stock);
|
||||
|
||||
kanjiaActivityGoodsService.updateById(kanjiaActivityGoodsDTO);
|
||||
//修改积分商品库存
|
||||
} else if (promotionTypeEnum.equals(PromotionTypeEnum.POINTS_GOODS)) {
|
||||
PointsGoodsVO pointsGoodsVO = pointsGoodsService.getPointsGoodsDetail(orderItem.getPromotionId());
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, orderItem.getPromotionId(), orderItem.getSkuId())).toString());
|
||||
pointsGoodsVO.setActiveStock(stock);
|
||||
pointsGoodsService.updateById(pointsGoodsVO);
|
||||
} else {
|
||||
PromotionGoodsSearchParams searchParams = new PromotionGoodsSearchParams();
|
||||
searchParams.setPromotionType(promotionTypeEnum.name());
|
||||
searchParams.setPromotionId(orderItem.getPromotionId());
|
||||
searchParams.setSkuId(orderItem.getSkuId());
|
||||
PromotionGoods pGoods = promotionGoodsService.getPromotionsGoods(searchParams);
|
||||
//记录需要更新的促销库存信息
|
||||
promotionKey.add(
|
||||
PromotionGoodsService.getPromotionGoodsStockCacheKey(
|
||||
promotionTypeEnum,
|
||||
orderItem.getPromotionId(), orderItem.getSkuId())
|
||||
);
|
||||
if (pGoods != null) {
|
||||
promotionGoods.add(pGoods);
|
||||
}
|
||||
kanjiaActivityGoodsService.updateById(kanjiaActivityGoodsDTO);
|
||||
//修改积分商品库存
|
||||
} else if (promotionTypeEnum.equals(PromotionTypeEnum.POINTS_GOODS)) {
|
||||
PointsGoodsVO pointsGoodsVO = pointsGoodsService.getPointsGoodsDetail(promotionId);
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, promotionId, orderItem.getSkuId())).toString());
|
||||
pointsGoodsVO.setActiveStock(stock);
|
||||
pointsGoodsService.updateById(pointsGoodsVO);
|
||||
} else {
|
||||
PromotionGoodsSearchParams searchParams = new PromotionGoodsSearchParams();
|
||||
searchParams.setPromotionType(promotionTypeEnum.name());
|
||||
searchParams.setPromotionId(promotionId);
|
||||
searchParams.setSkuId(orderItem.getSkuId());
|
||||
PromotionGoods pGoods = promotionGoodsService.getPromotionsGoods(searchParams);
|
||||
//记录需要更新的促销库存信息
|
||||
promotionKey.add(
|
||||
PromotionGoodsService.getPromotionGoodsStockCacheKey(
|
||||
promotionTypeEnum,
|
||||
promotionId, orderItem.getSkuId())
|
||||
);
|
||||
if (pGoods != null) {
|
||||
promotionGoods.add(pGoods);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
}
|
||||
goodsSkus.add(goodsSku);
|
||||
}
|
||||
@@ -321,8 +343,6 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
for (int i = 0; i < skuStocks.size(); i++) {
|
||||
goodsSkus.get(i).setQuantity(Convert.toInt(skuStocks.get(i).toString()));
|
||||
}
|
||||
//批量修改商品库存
|
||||
goodsSkuService.updateBatchById(goodsSkus);
|
||||
|
||||
//促销库存处理
|
||||
if (!promotionKey.isEmpty()) {
|
||||
@@ -332,10 +352,10 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
Integer num = promotionGoods.get(i).getNum();
|
||||
promotionGoods.get(i).setNum((num != null ? num : 0) + order.getOrder().getGoodsNum());
|
||||
}
|
||||
promotionGoodsService.updateBatchById(promotionGoods);
|
||||
promotionGoodsService.updatePromotionGoodsStock(promotionGoods);
|
||||
}
|
||||
//商品库存,包含sku库存集合,批量更新商品库存相关
|
||||
goodsSkuService.updateGoodsStuck(goodsSkus);
|
||||
goodsSkuService.updateGoodsStock(goodsSkus);
|
||||
|
||||
log.info("订单确认,库存同步:商品信息--{};促销信息---{}", goodsSkus, promotionGoods);
|
||||
|
||||
@@ -352,11 +372,75 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
List<GoodsSku> goodsSkus = new ArrayList<>();
|
||||
//sku库存key 集合
|
||||
List<String> skuKeys = new ArrayList<>();
|
||||
//促销商品
|
||||
List<PromotionGoods> promotionGoods = new ArrayList<>();
|
||||
//促销库存key 集合
|
||||
List<String> promotionKey = new ArrayList<>();
|
||||
|
||||
//循环订单
|
||||
for (OrderItem orderItem : order.getOrderItems()) {
|
||||
skuKeys.add(GoodsSkuService.getStockCacheKey(orderItem.getSkuId()));
|
||||
|
||||
GoodsSku goodsSku = new GoodsSku();
|
||||
goodsSku.setId(orderItem.getSkuId());
|
||||
goodsSku.setGoodsId(orderItem.getGoodsId());
|
||||
//如果有促销信息
|
||||
if (null != orderItem.getPromotionType() && null != orderItem.getPromotionId()) {
|
||||
|
||||
//如果促销有库存信息
|
||||
String[] skuPromotions = orderItem.getPromotionType().split(",");
|
||||
for (int i = 0; i < skuPromotions.length; i++) {
|
||||
int currentIndex = i;
|
||||
Arrays.stream(PromotionTypeEnum.haveStockPromotion).filter(promotionTypeEnum -> promotionTypeEnum.name().equals(skuPromotions[currentIndex]))
|
||||
.findFirst()
|
||||
.ifPresent(promotionTypeEnum -> {
|
||||
//修改砍价商品库存
|
||||
String promotionId = orderItem.getPromotionId().split(",")[currentIndex];
|
||||
//修改砍价商品库存
|
||||
if (promotionTypeEnum.equals(PromotionTypeEnum.KANJIA)) {
|
||||
KanjiaActivity kanjiaActivity = kanjiaActivityService.getById(promotionId);
|
||||
KanjiaActivityGoodsDTO kanjiaActivityGoodsDTO = kanjiaActivityGoodsService.getKanjiaGoodsDetail(kanjiaActivity.getKanjiaActivityGoodsId());
|
||||
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, promotionId, orderItem.getSkuId())).toString());
|
||||
kanjiaActivityGoodsDTO.setStock(stock);
|
||||
|
||||
kanjiaActivityGoodsService.updateById(kanjiaActivityGoodsDTO);
|
||||
//修改积分商品库存
|
||||
} else if (promotionTypeEnum.equals(PromotionTypeEnum.POINTS_GOODS)) {
|
||||
PointsGoodsVO pointsGoodsVO = pointsGoodsService.getPointsGoodsDetail(promotionId);
|
||||
Integer stock = Integer.parseInt(cache.get(PromotionGoodsService.getPromotionGoodsStockCacheKey(promotionTypeEnum, promotionId, orderItem.getSkuId())).toString());
|
||||
pointsGoodsVO.setActiveStock(stock);
|
||||
pointsGoodsService.updateById(pointsGoodsVO);
|
||||
} else {
|
||||
PromotionGoodsSearchParams searchParams = new PromotionGoodsSearchParams();
|
||||
searchParams.setPromotionType(promotionTypeEnum.name());
|
||||
searchParams.setPromotionId(promotionId);
|
||||
searchParams.setSkuId(orderItem.getSkuId());
|
||||
PromotionGoods pGoods = promotionGoodsService.getPromotionsGoods(searchParams);
|
||||
//记录需要更新的促销库存信息
|
||||
promotionKey.add(
|
||||
PromotionGoodsService.getPromotionGoodsStockCacheKey(
|
||||
promotionTypeEnum,
|
||||
promotionId, orderItem.getSkuId())
|
||||
);
|
||||
if (pGoods != null) {
|
||||
promotionGoods.add(pGoods);
|
||||
}
|
||||
}
|
||||
});
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
goodsSkus.add(goodsSku);
|
||||
}
|
||||
|
||||
//循环订单
|
||||
for (OrderItem orderItem : order.getOrderItems()) {
|
||||
skuKeys.add(GoodsSkuService.getStockCacheKey(orderItem.getSkuId()));
|
||||
GoodsSku goodsSku = new GoodsSku();
|
||||
goodsSku.setId(orderItem.getSkuId());
|
||||
goodsSku.setGoodsId(orderItem.getGoodsId());
|
||||
goodsSkus.add(goodsSku);
|
||||
}
|
||||
//批量获取商品库存
|
||||
@@ -365,10 +449,19 @@ public class StockUpdateExecute implements OrderStatusChangeEvent {
|
||||
for (int i = 0; i < skuStocks.size(); i++) {
|
||||
goodsSkus.get(i).setQuantity(Convert.toInt(skuStocks.get(i).toString()));
|
||||
}
|
||||
//促销库存处理
|
||||
if (!promotionKey.isEmpty()) {
|
||||
List promotionStocks = cache.multiGet(promotionKey);
|
||||
for (int i = 0; i < promotionKey.size(); i++) {
|
||||
promotionGoods.get(i).setQuantity(Convert.toInt(promotionStocks.get(i).toString()));
|
||||
Integer num = promotionGoods.get(i).getNum();
|
||||
promotionGoods.get(i).setNum((num != null ? num : 0) + order.getOrder().getGoodsNum());
|
||||
}
|
||||
promotionGoodsService.updatePromotionGoodsStock(promotionGoods);
|
||||
}
|
||||
log.info("订单取消,库存还原:{}", goodsSkus);
|
||||
//批量修改商品库存
|
||||
goodsSkuService.updateBatchById(goodsSkus);
|
||||
goodsSkuService.updateGoodsStuck(goodsSkus);
|
||||
goodsSkuService.updateGoodsStock(goodsSkus);
|
||||
|
||||
}
|
||||
}
|
||||
|
||||
206
consumer/src/main/java/cn/lili/event/impl/StoreChangeEvent.java
Normal file
206
consumer/src/main/java/cn/lili/event/impl/StoreChangeEvent.java
Normal file
@@ -0,0 +1,206 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.lili.event.StoreSettingChangeEvent;
|
||||
import cn.lili.modules.distribution.service.DistributionGoodsService;
|
||||
import cn.lili.modules.distribution.service.DistributionOrderService;
|
||||
import cn.lili.modules.goods.service.DraftGoodsService;
|
||||
import cn.lili.modules.member.service.MemberEvaluationService;
|
||||
import cn.lili.modules.message.service.StoreMessageService;
|
||||
import cn.lili.modules.order.aftersale.service.AfterSaleService;
|
||||
import cn.lili.modules.order.order.service.OrderComplaintService;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.order.service.ReceiptService;
|
||||
import cn.lili.modules.order.order.service.StoreFlowService;
|
||||
import cn.lili.modules.promotion.service.*;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import cn.lili.modules.store.service.BillService;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.UpdateWrapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
|
||||
/**
|
||||
* @author ftyy
|
||||
* @description: 店铺名称修改同步对应场景
|
||||
* @date 2023/4/24
|
||||
*/
|
||||
@Service
|
||||
public class StoreChangeEvent implements StoreSettingChangeEvent {
|
||||
/**
|
||||
* 优惠券活动表
|
||||
*/
|
||||
@Autowired
|
||||
private CouponActivityService couponActivityService;
|
||||
|
||||
/**
|
||||
* 砍价活动商品
|
||||
*/
|
||||
@Autowired
|
||||
private KanjiaActivityGoodsService kanjiaActivityGoodsService;
|
||||
|
||||
/**
|
||||
* 积分商品
|
||||
*/
|
||||
@Autowired
|
||||
private PointsGoodsService pointsGoodsService;
|
||||
|
||||
/**
|
||||
* 促销商品
|
||||
*/
|
||||
@Autowired
|
||||
private PromotionGoodsService promotionGoodsService;
|
||||
|
||||
/**
|
||||
* 秒杀活动活动
|
||||
*/
|
||||
@Autowired
|
||||
private SeckillService seckillService;
|
||||
|
||||
/**
|
||||
* 优惠券
|
||||
*/
|
||||
@Autowired
|
||||
private CouponService couponService;
|
||||
|
||||
/**
|
||||
* 满优惠活动
|
||||
*/
|
||||
@Autowired
|
||||
private FullDiscountService fullDiscountService;
|
||||
|
||||
/**
|
||||
* 拼团
|
||||
*/
|
||||
@Autowired
|
||||
private PintuanService pintuanService;
|
||||
|
||||
/**
|
||||
* 秒杀活动
|
||||
*/
|
||||
@Autowired
|
||||
private SeckillApplyService seckillApplyService;
|
||||
/**
|
||||
* 订单
|
||||
*/
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
|
||||
/**
|
||||
* 店铺流水
|
||||
*/
|
||||
@Autowired
|
||||
private StoreFlowService storeFlowService;
|
||||
|
||||
/**
|
||||
* 售后
|
||||
*/
|
||||
@Autowired
|
||||
private AfterSaleService afterSaleService;
|
||||
|
||||
/**
|
||||
* 订单投诉
|
||||
*/
|
||||
@Autowired
|
||||
private OrderComplaintService orderComplaintService;
|
||||
/**
|
||||
* 发票
|
||||
*/
|
||||
@Autowired
|
||||
private ReceiptService receiptService;
|
||||
|
||||
/**
|
||||
* 会员优惠券
|
||||
*/
|
||||
@Autowired
|
||||
private MemberCouponService memberCouponService;
|
||||
|
||||
/**
|
||||
* 店铺消息
|
||||
*/
|
||||
@Autowired
|
||||
private StoreMessageService storeMessageService;
|
||||
|
||||
/**
|
||||
* 会员评价
|
||||
*/
|
||||
@Autowired
|
||||
private MemberEvaluationService memberEvaluationService;
|
||||
|
||||
/**
|
||||
* 结算单
|
||||
*/
|
||||
@Autowired
|
||||
private BillService billService;
|
||||
/**
|
||||
* 分销商品
|
||||
*/
|
||||
@Autowired
|
||||
private DistributionGoodsService distributionGoodsService;
|
||||
/**
|
||||
* 分销订单
|
||||
*/
|
||||
@Autowired
|
||||
private DistributionOrderService distributionOrderService;
|
||||
|
||||
/**
|
||||
* 草稿商品
|
||||
*/
|
||||
@Autowired
|
||||
private DraftGoodsService draftGoodsService;
|
||||
|
||||
|
||||
/**
|
||||
* 店铺名称修改 同步更新相关店铺名称
|
||||
*
|
||||
* @param store 店铺信息
|
||||
*/
|
||||
@Override
|
||||
public void storeSettingChange(Store store) {
|
||||
|
||||
UpdateWrapper updateWrapper = new UpdateWrapper<>()
|
||||
.eq("store_id", store.getId())
|
||||
.set("store_name", store.getStoreName());
|
||||
|
||||
//修改会员优惠券中店铺名称
|
||||
memberCouponService.update(updateWrapper);
|
||||
//修改优惠券活动中店铺名称
|
||||
couponActivityService.update(updateWrapper);
|
||||
//修改砍价活动商品中店铺名称
|
||||
kanjiaActivityGoodsService.update(updateWrapper);
|
||||
//修改积分商品中店铺名称
|
||||
pointsGoodsService.update(updateWrapper);
|
||||
//修改促销商品中店铺名称
|
||||
promotionGoodsService.update(updateWrapper);
|
||||
//修改秒杀活动活动中店铺名称
|
||||
seckillService.update(updateWrapper);
|
||||
//修改优惠券中店铺名称
|
||||
couponService.update(updateWrapper);
|
||||
//修改满优惠活动中店铺名称
|
||||
fullDiscountService.update(updateWrapper);
|
||||
//修改拼团中店铺名称
|
||||
pintuanService.update(updateWrapper);
|
||||
//修改秒杀活动中店铺名称
|
||||
seckillApplyService.update(updateWrapper);
|
||||
//修改发票中店铺名称
|
||||
receiptService.update(updateWrapper);
|
||||
//修改订单中的店铺名称
|
||||
orderService.update(updateWrapper);
|
||||
//修改店铺流水中店铺名称
|
||||
storeFlowService.update(updateWrapper);
|
||||
//修改售后中店铺名称
|
||||
afterSaleService.update(updateWrapper);
|
||||
//修改订单投诉中店铺名称
|
||||
orderComplaintService.update(updateWrapper);
|
||||
//修改店铺消息中的店铺名称
|
||||
storeMessageService.update(updateWrapper);
|
||||
//修改会员评价中店铺名称
|
||||
memberEvaluationService.update(updateWrapper);
|
||||
//修改结算单中店铺名称
|
||||
billService.update(updateWrapper);
|
||||
//修改分销订单中店铺名称
|
||||
distributionOrderService.update(updateWrapper);
|
||||
//修改分销商品中店铺名称
|
||||
distributionGoodsService.update(updateWrapper);
|
||||
//修改草稿商品中店铺名称
|
||||
draftGoodsService.update(updateWrapper);
|
||||
}
|
||||
}
|
||||
@@ -31,7 +31,7 @@ public class VerificationOrderExecute implements OrderStatusChangeEvent {
|
||||
@Override
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
//订单状态为待核验,添加订单添加核验码
|
||||
if (orderMessage.getNewStatus().equals(OrderStatusEnum.TAKE)) {
|
||||
if (orderMessage.getNewStatus().equals(OrderStatusEnum.TAKE) || orderMessage.getNewStatus().equals(OrderStatusEnum.STAY_PICKED_UP)) {
|
||||
//获取订单信息
|
||||
Order order = orderService.getBySn(orderMessage.getOrderSn());
|
||||
//获取随机数,判定是否存在
|
||||
@@ -43,7 +43,7 @@ public class VerificationOrderExecute implements OrderStatusChangeEvent {
|
||||
//修改虚拟订单货物可以进行售后、投诉
|
||||
orderItemService.update(new LambdaUpdateWrapper<OrderItem>().eq(OrderItem::getOrderSn, orderMessage.getOrderSn())
|
||||
.set(OrderItem::getAfterSaleStatus, OrderItemAfterSaleStatusEnum.NOT_APPLIED)
|
||||
.set(OrderItem::getCommentStatus, OrderComplaintStatusEnum.NO_APPLY));
|
||||
.set(OrderItem::getComplainStatus, OrderComplaintStatusEnum.NO_APPLY));
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -0,0 +1,48 @@
|
||||
package cn.lili.event.impl;
|
||||
|
||||
import cn.lili.event.OrderStatusChangeEvent;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderMessage;
|
||||
import cn.lili.modules.wechat.service.WechatMPService;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service ;
|
||||
|
||||
/**
|
||||
* 微信小程序执行器
|
||||
*
|
||||
* @author Chopper
|
||||
* @version v1.0 2021-04-19 14:25
|
||||
*/
|
||||
@Slf4j
|
||||
@Service
|
||||
public class WechatMPExecute implements OrderStatusChangeEvent {
|
||||
|
||||
@Autowired
|
||||
private WechatMPService wechatMPService;
|
||||
|
||||
|
||||
/**
|
||||
* 订单已发货、待提货、待核验状态 如果是微信小程序的订单则进行 订单发货信息录入
|
||||
*
|
||||
* @param orderMessage 订单消息
|
||||
*/
|
||||
@Override
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
|
||||
switch (orderMessage.getNewStatus()) {
|
||||
case TAKE:
|
||||
case STAY_PICKED_UP:
|
||||
case DELIVERED:
|
||||
try {
|
||||
wechatMPService.uploadShippingInfo(orderMessage.getOrderSn());
|
||||
} catch (Exception e) {
|
||||
log.error("发货信息录入失败", e);
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
@@ -39,9 +39,9 @@ public class WechatMessageExecute implements OrderStatusChangeEvent, TradeEvent
|
||||
public void orderChange(OrderMessage orderMessage) {
|
||||
|
||||
switch (orderMessage.getNewStatus()) {
|
||||
case PAID:
|
||||
case UNDELIVERED:
|
||||
case DELIVERED:
|
||||
case STAY_PICKED_UP:
|
||||
case COMPLETED:
|
||||
try {
|
||||
wechatMessageUtil.sendWechatMessage(orderMessage.getOrderSn());
|
||||
|
||||
@@ -6,6 +6,9 @@ import cn.hutool.core.util.ArrayUtil;
|
||||
import cn.hutool.core.util.ClassLoaderUtil;
|
||||
import cn.hutool.json.JSONObject;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.common.aop.annotation.RetryOperation;
|
||||
import cn.lili.common.exception.RetryException;
|
||||
import cn.lili.common.vo.PageVO;
|
||||
import cn.lili.event.GoodsCommentCompleteEvent;
|
||||
import cn.lili.modules.distribution.entity.dos.DistributionGoods;
|
||||
import cn.lili.modules.distribution.entity.dto.DistributionGoodsSearchParams;
|
||||
@@ -30,8 +33,9 @@ import cn.lili.modules.promotion.service.PromotionGoodsService;
|
||||
import cn.lili.modules.promotion.service.PromotionService;
|
||||
import cn.lili.modules.search.entity.dos.EsGoodsIndex;
|
||||
import cn.lili.modules.search.service.EsGoodsIndexService;
|
||||
import cn.lili.modules.store.service.StoreService;
|
||||
import cn.lili.rocketmq.tags.GoodsTagsEnum;
|
||||
import com.baomidou.mybatisplus.core.metadata.IPage;
|
||||
import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.rocketmq.common.message.MessageExt;
|
||||
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
|
||||
@@ -53,16 +57,13 @@ import java.util.stream.Collectors;
|
||||
@RocketMQMessageListener(topic = "${lili.data.rocketmq.goods-topic}", consumerGroup = "${lili.data.rocketmq.goods-group}")
|
||||
public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
|
||||
private static final int BATCH_SIZE = 10;
|
||||
|
||||
/**
|
||||
* ES商品
|
||||
*/
|
||||
@Autowired
|
||||
private EsGoodsIndexService goodsIndexService;
|
||||
/**
|
||||
* 店铺
|
||||
*/
|
||||
@Autowired
|
||||
private StoreService storeService;
|
||||
/**
|
||||
* 商品
|
||||
*/
|
||||
@@ -121,6 +122,7 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
private PromotionGoodsService promotionGoodsService;
|
||||
|
||||
@Override
|
||||
@RetryOperation
|
||||
public void onMessage(MessageExt messageExt) {
|
||||
|
||||
switch (GoodsTagsEnum.valueOf(messageExt.getTags())) {
|
||||
@@ -135,20 +137,32 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
String goodsId = new String(messageExt.getBody());
|
||||
log.info("生成索引: {}", goodsId);
|
||||
Goods goods = this.goodsService.getById(goodsId);
|
||||
updateGoodsIndex(goods);
|
||||
this.updateGoodsIndex(goods);
|
||||
} catch (Exception e) {
|
||||
log.error("生成商品索引事件执行异常,商品信息 {}", new String(messageExt.getBody()));
|
||||
log.error("生成商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
case GENERATOR_STORE_GOODS_INDEX:
|
||||
try {
|
||||
String storeId = new String(messageExt.getBody());
|
||||
this.updateGoodsIndex(storeId);
|
||||
} catch (Exception e) {
|
||||
log.error("生成店铺商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
case UPDATE_GOODS_INDEX_PROMOTIONS:
|
||||
this.updateGoodsIndexPromotions(new String(messageExt.getBody()));
|
||||
break;
|
||||
case DELETE_GOODS_INDEX_PROMOTIONS:
|
||||
BasePromotions promotions = JSONUtil.toBean(new String(messageExt.getBody()), BasePromotions.class);
|
||||
if (CharSequenceUtil.isNotEmpty(promotions.getScopeId())) {
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionId(Arrays.asList(promotions.getScopeId().split(",")), promotions.getId());
|
||||
JSONObject jsonObject = JSONUtil.parseObj(new String(messageExt.getBody()));
|
||||
String promotionKey = jsonObject.getStr("promotionKey");
|
||||
if (CharSequenceUtil.isEmpty(promotionKey)) {
|
||||
break;
|
||||
}
|
||||
if (CharSequenceUtil.isNotEmpty(jsonObject.getStr("scopeId"))) {
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionKey(Arrays.asList(jsonObject.getStr("scopeId").split(",")), promotionKey);
|
||||
} else {
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionId(null, promotions.getId());
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionKey(promotionKey);
|
||||
}
|
||||
break;
|
||||
case UPDATE_GOODS_INDEX:
|
||||
@@ -159,20 +173,18 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
List<Goods> goodsList = goodsService.queryListByParams(searchParams);
|
||||
this.updateGoodsIndex(goodsList);
|
||||
} catch (Exception e) {
|
||||
log.error("更新商品索引事件执行异常,商品信息 {}", new String(messageExt.getBody()));
|
||||
log.error("更新商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
case UPDATE_GOODS_INDEX_FIELD:
|
||||
try {
|
||||
String updateIndexFieldsJsonStr = new String(messageExt.getBody());
|
||||
JSONObject updateIndexFields = JSONUtil.parseObj(updateIndexFieldsJsonStr);
|
||||
@SuppressWarnings("unchecked")
|
||||
Map<String, Object> queryFields = updateIndexFields.get("queryFields", Map.class);
|
||||
@SuppressWarnings("unchecked")
|
||||
Map<String, Object> updateFields = updateIndexFields.get("updateFields", Map.class);
|
||||
@SuppressWarnings("unchecked") Map<String, Object> queryFields = updateIndexFields.get("queryFields", Map.class);
|
||||
@SuppressWarnings("unchecked") Map<String, Object> updateFields = updateIndexFields.get("updateFields", Map.class);
|
||||
goodsIndexService.updateIndex(queryFields, updateFields);
|
||||
} catch (Exception e) {
|
||||
log.error("更新商品索引事件执行异常,商品信息 {}", new String(messageExt.getBody()));
|
||||
log.error("更新商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
case RESET_GOODS_INDEX:
|
||||
@@ -181,13 +193,12 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
List<EsGoodsIndex> goodsIndices = JSONUtil.toList(goodsIdsJsonStr, EsGoodsIndex.class);
|
||||
goodsIndexService.updateBulkIndex(goodsIndices);
|
||||
} catch (Exception e) {
|
||||
log.error("重置商品索引事件执行异常,商品信息 {}", new String(messageExt.getBody()));
|
||||
log.error("重置商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
//审核商品
|
||||
case GOODS_AUDIT:
|
||||
Goods goods = JSONUtil.toBean(new String(messageExt.getBody()), Goods.class);
|
||||
updateGoodsNum(goods);
|
||||
updateGoodsIndex(goods);
|
||||
break;
|
||||
//删除商品
|
||||
@@ -195,27 +206,40 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
try {
|
||||
String goodsIdsJsonStr = new String(messageExt.getBody());
|
||||
for (String goodsId : JSONUtil.toList(goodsIdsJsonStr, String.class)) {
|
||||
Goods goodsById = this.goodsService.getById(goodsId);
|
||||
if (goodsById != null) {
|
||||
this.deleteGoods(goodsById);
|
||||
this.updateGoodsNum(goodsById);
|
||||
List<String> skuIdsByGoodsId = this.goodsSkuService.getSkuIdsByGoodsId(goodsId);
|
||||
if (skuIdsByGoodsId != null && !skuIdsByGoodsId.isEmpty()) {
|
||||
this.goodsIndexService.deleteIndexByIds(skuIdsByGoodsId);
|
||||
}
|
||||
}
|
||||
goodsIndexService.deleteIndex(MapUtil.builder(new HashMap<String, Object>()).put("goodsId", goodsId).build());
|
||||
}
|
||||
|
||||
promotionService.removeByGoodsIds(goodsIdsJsonStr);
|
||||
} catch (Exception e) {
|
||||
log.error("删除商品索引事件执行异常,商品信息 {}", new String(messageExt.getBody()));
|
||||
log.error("删除商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
case DOWN:
|
||||
String goodsIdsJsonStr = new String(messageExt.getBody());
|
||||
promotionService.removeByGoodsIds(goodsIdsJsonStr);
|
||||
break;
|
||||
//规格删除
|
||||
case SKU_DELETE:
|
||||
String message = new String(messageExt.getBody());
|
||||
List<String> skuIds = JSONUtil.toList(message, String.class);
|
||||
goodsCollectionService.deleteSkuCollection(skuIds);
|
||||
break;
|
||||
case STORE_GOODS_DELETE:
|
||||
try {
|
||||
String storeId = new String(messageExt.getBody());
|
||||
goodsIndexService.deleteIndex(MapUtil.builder(new HashMap<String, Object>()).put("storeId", storeId).build());
|
||||
} catch (RetryException re) {
|
||||
throw re;
|
||||
} catch (Exception e) {
|
||||
log.error("删除店铺商品索引事件执行异常,商品信息: " + new String(messageExt.getBody()), e);
|
||||
}
|
||||
break;
|
||||
//同步商品分类名称
|
||||
case CATEGORY_GOODS_NAME:
|
||||
//分类ID
|
||||
String id = new String(messageExt.getBody());
|
||||
goodsService.categoryGoodsName(id);
|
||||
break;
|
||||
//商品评价
|
||||
case GOODS_COMMENT_COMPLETE:
|
||||
MemberEvaluation memberEvaluation = JSONUtil.toBean(new String(messageExt.getBody()), MemberEvaluation.class);
|
||||
@@ -223,10 +247,7 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
try {
|
||||
goodsCommentCompleteEvent.goodsComment(memberEvaluation);
|
||||
} catch (Exception e) {
|
||||
log.error("评价{},在{}业务中,状态修改事件执行异常",
|
||||
new String(messageExt.getBody()),
|
||||
goodsCommentCompleteEvent.getClass().getName(),
|
||||
e);
|
||||
log.error("评价{},在{}业务中,状态修改事件执行异常", new String(messageExt.getBody()), goodsCommentCompleteEvent.getClass().getName(), e);
|
||||
}
|
||||
}
|
||||
break;
|
||||
@@ -244,23 +265,46 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
try {
|
||||
log.info("更新商品索引促销信息: {}", promotionsJsonStr);
|
||||
JSONObject jsonObject = JSONUtil.parseObj(promotionsJsonStr);
|
||||
BasePromotions promotions = (BasePromotions) jsonObject.get("promotions",
|
||||
ClassLoaderUtil.loadClass(jsonObject.get("promotionsType").toString()));
|
||||
// 转换为详细的促销信息(注:促销信息必须继承自 BasePromotions,且必须保证派生类存在与sdk包下)
|
||||
BasePromotions promotions = (BasePromotions) jsonObject.get("promotions", ClassLoaderUtil.loadClass(jsonObject.get("promotionsType").toString()));
|
||||
// 获取促销唯一key,由 促销类型 + 促销id 组成
|
||||
String esPromotionKey = jsonObject.get("esPromotionKey").toString();
|
||||
if (PromotionsScopeTypeEnum.PORTION_GOODS.name().equals(promotions.getScopeType())) {
|
||||
PromotionGoodsSearchParams searchParams = new PromotionGoodsSearchParams();
|
||||
searchParams.setPromotionId(promotions.getId());
|
||||
List<PromotionGoods> promotionGoodsList = this.promotionGoodsService.listFindAll(searchParams);
|
||||
List<String> skuIds = promotionGoodsList.stream().map(PromotionGoods::getSkuId).collect(Collectors.toList());
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionId(skuIds, promotions.getId());
|
||||
this.goodsIndexService.updateEsGoodsIndexByList(promotionGoodsList, promotions, esPromotionKey);
|
||||
for (int i = 0; ; i++) {
|
||||
PromotionGoodsSearchParams searchParams = new PromotionGoodsSearchParams();
|
||||
searchParams.setPromotionId(promotions.getId());
|
||||
PageVO pageVO = new PageVO();
|
||||
pageVO.setPageNumber(i);
|
||||
pageVO.setPageSize(BATCH_SIZE);
|
||||
Page<PromotionGoods> promotionGoodsPage = this.promotionGoodsService.pageFindAll(searchParams, pageVO);
|
||||
if (promotionGoodsPage == null || promotionGoodsPage.getRecords().isEmpty()) {
|
||||
break;
|
||||
}
|
||||
List<String> skuIds = promotionGoodsPage.getRecords().stream().map(PromotionGoods::getSkuId).collect(Collectors.toList());
|
||||
// 更新商品索引促销信息(删除原索引中相关的促销信息,更新索引中促销信息)
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionKey(skuIds, esPromotionKey);
|
||||
this.goodsIndexService.updateEsGoodsIndexByList(promotionGoodsPage.getRecords(), promotions, esPromotionKey);
|
||||
}
|
||||
|
||||
} else if (PromotionsScopeTypeEnum.PORTION_GOODS_CATEGORY.name().equals(promotions.getScopeType())) {
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setCategoryPath(promotions.getScopeId());
|
||||
List<GoodsSku> goodsSkuByList = this.goodsSkuService.getGoodsSkuByList(searchParams);
|
||||
List<String> skuIds = goodsSkuByList.stream().map(GoodsSku::getId).collect(Collectors.toList());
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionId(skuIds, promotions.getId());
|
||||
this.goodsIndexService.updateEsGoodsIndexPromotions(skuIds, promotions, esPromotionKey);
|
||||
for (int i = 0; ; i++) {
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setCategoryPath(promotions.getScopeId());
|
||||
searchParams.setPageNumber(i);
|
||||
searchParams.setPageSize(BATCH_SIZE);
|
||||
if (CharSequenceUtil.isNotEmpty(promotions.getStoreId()) && !"0".equals(promotions.getStoreId())){
|
||||
searchParams.setStoreId(promotions.getStoreId());
|
||||
}
|
||||
IPage<GoodsSku> goodsSkuByPage = this.goodsSkuService.getGoodsSkuByPage(searchParams);
|
||||
if (goodsSkuByPage == null || goodsSkuByPage.getRecords().isEmpty()) {
|
||||
break;
|
||||
}
|
||||
List<String> skuIds = goodsSkuByPage.getRecords().stream().map(GoodsSku::getId).collect(Collectors.toList());
|
||||
// 更新商品索引促销信息(删除原索引中相关的促销信息,更新索引中促销信息)
|
||||
this.goodsIndexService.deleteEsGoodsPromotionByPromotionKey(skuIds, esPromotionKey);
|
||||
this.goodsIndexService.updateEsGoodsIndexPromotions(skuIds, promotions, esPromotionKey);
|
||||
}
|
||||
|
||||
} else if (PromotionsScopeTypeEnum.ALL.name().equals(promotions.getScopeType())) {
|
||||
this.goodsIndexService.updateEsGoodsIndexAllByList(promotions, esPromotionKey);
|
||||
}
|
||||
@@ -275,32 +319,25 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
* @param goodsList 商品列表消息
|
||||
*/
|
||||
private void updateGoodsIndex(List<Goods> goodsList) {
|
||||
List<EsGoodsIndex> goodsIndices = new ArrayList<>();
|
||||
for (Goods goods : goodsList) {
|
||||
//如果商品通过审核&&并且已上架
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setGoodsId(goods.getId());
|
||||
searchParams.setGeQuantity(0);
|
||||
List<GoodsSku> goodsSkuList = this.goodsSkuService.getGoodsSkuByList(searchParams);
|
||||
if (goods.getAuthFlag().equals(GoodsAuthEnum.PASS.name())
|
||||
&& goods.getMarketEnable().equals(GoodsStatusEnum.UPPER.name())
|
||||
&& Boolean.FALSE.equals(goods.getDeleteFlag())) {
|
||||
goodsSkuList.forEach(goodsSku -> {
|
||||
EsGoodsIndex goodsIndex = this.settingUpGoodsIndexData(goods, goodsSku);
|
||||
goodsIndices.add(goodsIndex);
|
||||
});
|
||||
}
|
||||
//如果商品状态值不支持es搜索,那么将商品信息做下架处理
|
||||
else {
|
||||
for (GoodsSku goodsSku : goodsSkuList) {
|
||||
EsGoodsIndex esGoodsOld = goodsIndexService.findById(goodsSku.getId());
|
||||
if (esGoodsOld != null) {
|
||||
goodsIndexService.deleteIndexById(goodsSku.getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
this.updateGoodsIndex(goods);
|
||||
}
|
||||
goodsIndexService.updateBulkIndex(goodsIndices);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 更新商品索引根据店铺id
|
||||
*
|
||||
* @param storeId 店铺id
|
||||
*/
|
||||
private void updateGoodsIndex(String storeId) {
|
||||
//如果商品通过审核&&并且已上架
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setStoreId(storeId);
|
||||
for (Goods goods : this.goodsService.queryListByParams(searchParams)) {
|
||||
this.updateGoodsIndex(goods);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -309,26 +346,32 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
* @param goods 商品消息
|
||||
*/
|
||||
private void updateGoodsIndex(Goods goods) {
|
||||
//如果商品通过审核&&并且已上架
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setGoodsId(goods.getId());
|
||||
List<GoodsSku> goodsSkuList = this.goodsSkuService.getGoodsSkuByList(searchParams);
|
||||
log.info("goods:{}", goods);
|
||||
log.info("goodsSkuList:{}", goodsSkuList);
|
||||
if (goods.getAuthFlag().equals(GoodsAuthEnum.PASS.name())
|
||||
&& goods.getMarketEnable().equals(GoodsStatusEnum.UPPER.name())
|
||||
&& Boolean.FALSE.equals(goods.getDeleteFlag())) {
|
||||
this.generatorGoodsIndex(goods, goodsSkuList);
|
||||
}
|
||||
//如果商品状态值不支持es搜索,那么将商品信息做下架处理
|
||||
else {
|
||||
for (GoodsSku goodsSku : goodsSkuList) {
|
||||
EsGoodsIndex esGoodsOld = goodsIndexService.findById(goodsSku.getId());
|
||||
if (esGoodsOld != null) {
|
||||
goodsIndexService.deleteIndexById(goodsSku.getId());
|
||||
for (int i = 1; ; i++) {
|
||||
//如果商品通过审核&&并且已上架
|
||||
GoodsSearchParams searchParams = new GoodsSearchParams();
|
||||
searchParams.setGoodsId(goods.getId());
|
||||
searchParams.setPageNumber(i);
|
||||
searchParams.setPageSize(BATCH_SIZE);
|
||||
searchParams.setGeQuantity(0);
|
||||
IPage<GoodsSku> goodsSkuByPage = this.goodsSkuService.getGoodsSkuByPage(searchParams);
|
||||
if (goodsSkuByPage == null || goodsSkuByPage.getRecords().isEmpty()) {
|
||||
break;
|
||||
}
|
||||
log.info("goods:{}", goods);
|
||||
log.info("goodsSkuList:{}", goodsSkuByPage.getRecords());
|
||||
if (goods.getAuthFlag().equals(GoodsAuthEnum.PASS.name()) && goods.getMarketEnable().equals(GoodsStatusEnum.UPPER.name()) && Boolean.FALSE.equals(goods.getDeleteFlag())) {
|
||||
this.generatorGoodsIndex(goods, goodsSkuByPage.getRecords());
|
||||
} else {
|
||||
//如果商品状态值不支持es搜索,那么将商品信息做下架处理
|
||||
for (GoodsSku goodsSku : goodsSkuByPage.getRecords()) {
|
||||
EsGoodsIndex esGoodsOld = goodsIndexService.findById(goodsSku.getId());
|
||||
if (esGoodsOld != null) {
|
||||
goodsIndexService.deleteIndexById(goodsSku.getId());
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -339,20 +382,20 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
*/
|
||||
private void generatorGoodsIndex(Goods goods, List<GoodsSku> goodsSkuList) {
|
||||
int skuSource = 100;
|
||||
List<EsGoodsIndex> esGoodsIndices = new ArrayList<>();
|
||||
for (GoodsSku goodsSku : goodsSkuList) {
|
||||
EsGoodsIndex esGoodsOld = goodsIndexService.findById(goodsSku.getId());
|
||||
EsGoodsIndex goodsIndex = this.settingUpGoodsIndexData(goods, goodsSku);
|
||||
goodsIndex.setSkuSource(skuSource--);
|
||||
log.info("goodsSku:{}", goodsSku);
|
||||
log.info("esGoodsOld:{}", esGoodsOld);
|
||||
//如果商品库存不为0,并且es中有数据
|
||||
if (goodsSku.getQuantity() > 0 && esGoodsOld == null) {
|
||||
log.info("生成商品索引 {}", goodsIndex);
|
||||
this.goodsIndexService.addIndex(goodsIndex);
|
||||
} else if (goodsSku.getQuantity() > 0 && esGoodsOld != null) {
|
||||
goodsIndexService.updateIndex(goodsIndex);
|
||||
skuSource--;
|
||||
if (skuSource <= 0) {
|
||||
skuSource = 1;
|
||||
}
|
||||
goodsIndex.setSkuSource(skuSource);
|
||||
log.info("goodsSku:{}", goodsSku);
|
||||
log.info("生成商品索引 {}", goodsIndex);
|
||||
esGoodsIndices.add(goodsIndex);
|
||||
}
|
||||
this.goodsIndexService.deleteIndex(MapUtil.builder(new HashMap<String, Object>()).put("goodsId", goods.getId()).build());
|
||||
this.goodsIndexService.addIndex(esGoodsIndices);
|
||||
}
|
||||
|
||||
private EsGoodsIndex settingUpGoodsIndexData(Goods goods, GoodsSku goodsSku) {
|
||||
@@ -389,7 +432,7 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
}
|
||||
|
||||
if (goodsIndex.getPromotionMap() == null || goodsIndex.getPromotionMap().isEmpty()) {
|
||||
if (goodsIndex.getOriginPromotionMap() == null || goodsIndex.getOriginPromotionMap().isEmpty()) {
|
||||
Map<String, Object> goodsCurrentPromotionMap = promotionService.getGoodsSkuPromotionMap(goodsIndex.getStoreId(), goodsIndex.getId());
|
||||
goodsIndex.setPromotionMapJson(JSONUtil.toJsonStr(goodsCurrentPromotionMap));
|
||||
}
|
||||
@@ -421,21 +464,6 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 修改商品数量
|
||||
*
|
||||
* @param goods 信息体
|
||||
*/
|
||||
private void updateGoodsNum(Goods goods) {
|
||||
try {
|
||||
//更新店铺商品数量
|
||||
assert goods != null;
|
||||
storeService.updateStoreGoodsNum(goods.getStoreId());
|
||||
} catch (Exception e) {
|
||||
log.error("修改商品数量错误");
|
||||
}
|
||||
}
|
||||
|
||||
/**
|
||||
* 商品购买完成
|
||||
* 1.更新商品购买数量
|
||||
@@ -467,11 +495,9 @@ public class GoodsMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
int buyCount = goodsSku.getBuyCount() + goodsCompleteMessage.getBuyNum();
|
||||
goodsSku.setBuyCount(buyCount);
|
||||
goodsSkuService.update(goodsSku);
|
||||
goodsSkuService.updateGoodsSkuBuyCount(goodsSku.getId(), buyCount);
|
||||
|
||||
this.goodsIndexService.updateIndex(
|
||||
MapUtil.builder(new HashMap<String, Object>()).put("id", goodsCompleteMessage.getSkuId()).build(),
|
||||
MapUtil.builder(new HashMap<String, Object>()).put("buyCount", buyCount).build());
|
||||
this.goodsIndexService.updateIndex(MapUtil.builder(new HashMap<String, Object>()).put("id", goodsCompleteMessage.getSkuId()).build(), MapUtil.builder(new HashMap<String, Object>()).put("buyCount", buyCount).build());
|
||||
|
||||
} else {
|
||||
log.error("商品SkuId为[" + goodsCompleteMessage.getGoodsId() + "的商品不存在,更新商品失败!");
|
||||
|
||||
@@ -1,10 +1,9 @@
|
||||
package cn.lili.listener;
|
||||
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.event.MemberLoginEvent;
|
||||
import cn.lili.event.MemberPointChangeEvent;
|
||||
import cn.lili.event.MemberRegisterEvent;
|
||||
import cn.lili.event.MemberWithdrawalEvent;
|
||||
import cn.lili.event.*;
|
||||
import cn.lili.event.impl.ImTalkExecute;
|
||||
import cn.lili.modules.connect.entity.dto.MemberConnectLoginMessage;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.member.entity.dos.MemberSign;
|
||||
import cn.lili.modules.member.entity.dto.MemberPointMessage;
|
||||
@@ -57,7 +56,10 @@ public class MemberMessageListener implements RocketMQListener<MessageExt> {
|
||||
*/
|
||||
@Autowired
|
||||
private List<MemberLoginEvent> memberLoginEvents;
|
||||
|
||||
@Autowired
|
||||
private List<MemberInfoChangeEvent> memberInfoChangeEvents;
|
||||
@Autowired
|
||||
private List<MemberConnectLoginEvent> memberConnectLoginEvents;
|
||||
|
||||
@Override
|
||||
public void onMessage(MessageExt messageExt) {
|
||||
@@ -76,7 +78,7 @@ public class MemberMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
}
|
||||
break;
|
||||
|
||||
//用户登录
|
||||
case MEMBER_LOGIN:
|
||||
|
||||
for (MemberLoginEvent memberLoginEvent : memberLoginEvents) {
|
||||
@@ -110,6 +112,20 @@ public class MemberMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
}
|
||||
break;
|
||||
//会员信息更改
|
||||
case MEMBER_INFO_EDIT:
|
||||
for (MemberInfoChangeEvent memberInfoChangeEvent : memberInfoChangeEvents) {
|
||||
try {
|
||||
Member member = JSONUtil.toBean(new String(messageExt.getBody()), Member.class);
|
||||
memberInfoChangeEvent.memberInfoChange(member);
|
||||
} catch (Exception e) {
|
||||
log.error("会员{},在{}业务中,提现事件执行异常",
|
||||
new String(messageExt.getBody()),
|
||||
memberInfoChangeEvent.getClass().getName(),
|
||||
e);
|
||||
}
|
||||
}
|
||||
break;
|
||||
//会员提现
|
||||
case MEMBER_WITHDRAWAL:
|
||||
for (MemberWithdrawalEvent memberWithdrawalEvent : memberWithdrawalEvents) {
|
||||
@@ -124,6 +140,20 @@ public class MemberMessageListener implements RocketMQListener<MessageExt> {
|
||||
}
|
||||
}
|
||||
break;
|
||||
//用户第三方登录
|
||||
case MEMBER_CONNECT_LOGIN:
|
||||
for (MemberConnectLoginEvent memberConnectLoginEvent : memberConnectLoginEvents) {
|
||||
try {
|
||||
MemberConnectLoginMessage memberConnectLoginMessage = JSONUtil.toBean(new String(messageExt.getBody()), MemberConnectLoginMessage.class);
|
||||
memberConnectLoginEvent.memberConnectLogin(memberConnectLoginMessage.getMember(), memberConnectLoginMessage.getConnectAuthUser());
|
||||
} catch (Exception e) {
|
||||
log.error("会员{},在{}业务中,状态修改事件执行异常",
|
||||
new String(messageExt.getBody()),
|
||||
memberConnectLoginEvent.getClass().getName(),
|
||||
e);
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
|
||||
@@ -0,0 +1,51 @@
|
||||
package cn.lili.listener;
|
||||
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.event.MemberRegisterEvent;
|
||||
import cn.lili.event.StoreSettingChangeEvent;
|
||||
import cn.lili.modules.member.entity.dos.Member;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import cn.lili.rocketmq.tags.StoreTagsEnum;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.apache.rocketmq.common.message.MessageExt;
|
||||
import org.apache.rocketmq.spring.annotation.RocketMQMessageListener;
|
||||
import org.apache.rocketmq.spring.core.RocketMQListener;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 店铺消息
|
||||
* @author chc
|
||||
* @since 2022/6/2114:46
|
||||
*/
|
||||
@Component
|
||||
@Slf4j
|
||||
@RocketMQMessageListener(topic = "${lili.data.rocketmq.store-topic}", consumerGroup = "${lili.data.rocketmq.store-group}")
|
||||
public class StoreMessageListener implements RocketMQListener<MessageExt> {
|
||||
@Autowired
|
||||
private List<StoreSettingChangeEvent> storeSettingChangeEventList;
|
||||
|
||||
@Override
|
||||
public void onMessage(MessageExt messageExt) {
|
||||
switch (StoreTagsEnum.valueOf(messageExt.getTags())){
|
||||
//修改店铺
|
||||
case EDIT_STORE_SETTING:
|
||||
for (StoreSettingChangeEvent storeSettingChangeEvent : storeSettingChangeEventList) {
|
||||
try {
|
||||
Store store = JSONUtil.toBean(new String(messageExt.getBody()), Store.class);
|
||||
storeSettingChangeEvent.storeSettingChange(store);
|
||||
} catch (Exception e) {
|
||||
log.error("会员{},在{}业务中,状态修改事件执行异常",
|
||||
new String(messageExt.getBody()),
|
||||
storeSettingChangeEvent.getClass().getName(),
|
||||
e);
|
||||
}
|
||||
}
|
||||
break;
|
||||
default:
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -0,0 +1,18 @@
|
||||
package cn.lili.sucurity;
|
||||
|
||||
import org.springframework.security.config.annotation.web.builders.HttpSecurity;
|
||||
import org.springframework.security.config.annotation.web.configuration.WebSecurityConfigurerAdapter;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* @author paulG
|
||||
* @since 2022/2/18
|
||||
**/
|
||||
@Component
|
||||
public class ConsumerSecurityConfig extends WebSecurityConfigurerAdapter {
|
||||
|
||||
@Override
|
||||
protected void configure(HttpSecurity http) throws Exception {
|
||||
http.formLogin().disable();
|
||||
}
|
||||
}
|
||||
@@ -71,7 +71,7 @@ public class TimedTaskJobHandler {
|
||||
try {
|
||||
everyHourExecutes.get(i).execute();
|
||||
} catch (Exception e) {
|
||||
log.error("每分钟任务异常", e);
|
||||
log.error("每小时任务异常", e);
|
||||
}
|
||||
}
|
||||
return ReturnT.SUCCESS;
|
||||
@@ -94,7 +94,7 @@ public class TimedTaskJobHandler {
|
||||
try {
|
||||
everyDayExecutes.get(i).execute();
|
||||
} catch (Exception e) {
|
||||
log.error("每分钟任务异常", e);
|
||||
log.error("每日任务异常", e);
|
||||
}
|
||||
}
|
||||
return ReturnT.SUCCESS;
|
||||
|
||||
@@ -1,60 +0,0 @@
|
||||
package cn.lili.timetask.handler.impl.bill;
|
||||
|
||||
import cn.hutool.core.date.DateTime;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.lili.modules.store.entity.dto.StoreSettlementDay;
|
||||
import cn.lili.modules.store.service.BillService;
|
||||
import cn.lili.modules.store.service.StoreDetailService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 店铺结算执行
|
||||
*
|
||||
* @author Bulbasaur
|
||||
* @since 2021/2/18 3:45 下午
|
||||
*/
|
||||
@Component
|
||||
public class BillExecute implements EveryDayExecute {
|
||||
|
||||
/**
|
||||
* 结算单
|
||||
*/
|
||||
@Autowired
|
||||
private BillService billService;
|
||||
/**
|
||||
* 店铺详情
|
||||
*/
|
||||
@Autowired
|
||||
private StoreDetailService storeDetailService;
|
||||
|
||||
/**
|
||||
* 1.查询今日待结算的商家
|
||||
* 2.查询商家上次结算日期,生成本次结算单
|
||||
* 3.记录商家结算日
|
||||
*/
|
||||
@Override
|
||||
public void execute() {
|
||||
|
||||
//获取当前天数
|
||||
int day = DateUtil.date().dayOfMonth();
|
||||
|
||||
//获取待结算商家列表
|
||||
List<StoreSettlementDay> storeList = storeDetailService.getSettlementStore(day);
|
||||
|
||||
//获取当前时间
|
||||
DateTime endTime = DateUtil.date();
|
||||
//批量商家结算
|
||||
for (StoreSettlementDay storeSettlementDay : storeList) {
|
||||
|
||||
//生成结算单
|
||||
billService.createBill(storeSettlementDay.getStoreId(), storeSettlementDay.getSettlementDay(), endTime);
|
||||
|
||||
//修改店铺结算时间
|
||||
storeDetailService.updateSettlementDay(storeSettlementDay.getStoreId(), endTime);
|
||||
}
|
||||
}
|
||||
}
|
||||
@@ -34,7 +34,7 @@ public class CouponExecute implements EveryDayExecute {
|
||||
*/
|
||||
@Override
|
||||
public void execute() {
|
||||
//将过期优惠券变更为过期状体
|
||||
//将过期优惠券变更为过期状态
|
||||
LambdaUpdateWrapper<MemberCoupon> updateWrapper = new LambdaUpdateWrapper<MemberCoupon>()
|
||||
.eq(MemberCoupon::getMemberCouponStatus, MemberCouponStatusEnum.NEW.name())
|
||||
.le(MemberCoupon::getEndTime, new Date())
|
||||
|
||||
@@ -3,14 +3,12 @@ package cn.lili.timetask.handler.impl.goods;
|
||||
import cn.hutool.core.convert.Convert;
|
||||
import cn.hutool.core.date.DateTime;
|
||||
import cn.hutool.core.date.DateUtil;
|
||||
import cn.lili.modules.goods.mapper.GoodsMapper;
|
||||
import cn.lili.modules.member.entity.dos.MemberEvaluation;
|
||||
import cn.lili.modules.member.mapper.MemberEvaluationMapper;
|
||||
import cn.lili.modules.goods.service.GoodsService;
|
||||
import cn.lili.modules.member.service.MemberEvaluationService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
import java.util.Map;
|
||||
|
||||
@@ -25,13 +23,13 @@ public class GoodsExecute implements EveryDayExecute {
|
||||
/**
|
||||
* 会员评价
|
||||
*/
|
||||
@Resource
|
||||
private MemberEvaluationMapper memberEvaluationMapper;
|
||||
@Autowired
|
||||
private MemberEvaluationService memberEvaluationService;
|
||||
/**
|
||||
* 商品
|
||||
*/
|
||||
@Resource
|
||||
private GoodsMapper goodsMapper;
|
||||
@Autowired
|
||||
private GoodsService goodsService;
|
||||
|
||||
/**
|
||||
* 查询已上架的商品的评价数量并赋值
|
||||
@@ -40,12 +38,10 @@ public class GoodsExecute implements EveryDayExecute {
|
||||
public void execute() {
|
||||
|
||||
//查询上次统计到本次的评价数量
|
||||
List<Map<String, Object>> list = memberEvaluationMapper.memberEvaluationNum(
|
||||
new QueryWrapper<MemberEvaluation>()
|
||||
.between("create_time", DateUtil.yesterday(), new DateTime()));
|
||||
List<Map<String, Object>> list = memberEvaluationService.memberEvaluationNum(DateUtil.yesterday(), new DateTime());
|
||||
|
||||
for (Map<String, Object> map : list) {
|
||||
goodsMapper.addGoodsCommentNum(Convert.toInt(map.get("num").toString()), map.get("goods_id").toString());
|
||||
goodsService.addGoodsCommentNum(Convert.toInt(map.get("num").toString()), map.get("goods_id").toString());
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -1,11 +1,24 @@
|
||||
package cn.lili.timetask.handler.impl.hotwords;
|
||||
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.cache.Cache;
|
||||
import cn.lili.cache.CachePrefix;
|
||||
import cn.lili.common.utils.StringUtils;
|
||||
import cn.lili.modules.search.entity.dos.HotWordsHistory;
|
||||
import cn.lili.modules.search.service.HotWordsHistoryService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.HotWordsSetting;
|
||||
import cn.lili.modules.system.entity.dto.HotWordsSettingItem;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.data.redis.core.DefaultTypedTuple;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.util.CollectionUtils;
|
||||
|
||||
import java.util.*;
|
||||
|
||||
/**
|
||||
* @author paulG
|
||||
@@ -18,13 +31,54 @@ public class HotWordsEveryDayTaskExecute implements EveryDayExecute {
|
||||
@Autowired
|
||||
private Cache cache;
|
||||
|
||||
@Autowired
|
||||
private HotWordsHistoryService hotWordsHistoryService;
|
||||
@Autowired
|
||||
private SettingService settingService;
|
||||
|
||||
/**
|
||||
* 执行每日任务
|
||||
*/
|
||||
@Override
|
||||
public void execute() {
|
||||
//获取大于0分的热词
|
||||
Set<DefaultTypedTuple> tuples = cache.zRangeByScore(CachePrefix.HOT_WORD.getPrefix(), 1, Integer.MAX_VALUE);
|
||||
//如果任务不为空
|
||||
if (!CollectionUtils.isEmpty(tuples)) {
|
||||
|
||||
//因为是第二天统计第一天的数据,所以这里获取昨天凌晨的时间
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.set(Calendar.HOUR_OF_DAY, 0);
|
||||
calendar.set(Calendar.SECOND, 0);
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
calendar.set(Calendar.MINUTE, 0);
|
||||
calendar.set(Calendar.DAY_OF_YEAR, calendar.get(Calendar.DAY_OF_YEAR) - 1);
|
||||
|
||||
//批量保存热词
|
||||
List<HotWordsHistory> hotWordsHistories = new ArrayList<>();
|
||||
for (DefaultTypedTuple tuple : tuples) {
|
||||
String keywords = (String) tuple.getValue();
|
||||
Double score = tuple.getScore();
|
||||
hotWordsHistories.add(new HotWordsHistory(keywords, score.intValue(), calendar.getTime()));
|
||||
}
|
||||
|
||||
hotWordsHistoryService.saveBatch(hotWordsHistories);
|
||||
}
|
||||
//移除昨日的热搜词
|
||||
cache.remove(CachePrefix.HOT_WORD.getPrefix());
|
||||
|
||||
//设置今日默认热词
|
||||
Setting setting = settingService.get(SettingEnum.HOT_WORDS.name());
|
||||
if (setting == null) {
|
||||
return;
|
||||
}
|
||||
HotWordsSetting hotWordsSetting = JSONUtil.toBean(setting.getSettingValue(), HotWordsSetting.class);
|
||||
List<HotWordsSettingItem> hotWordsSettingItems = hotWordsSetting.getHotWordsSettingItems();
|
||||
if (hotWordsSettingItems != null && !hotWordsSettingItems.isEmpty()) {
|
||||
for (HotWordsSettingItem hotWordsSettingItem : hotWordsSettingItems) {
|
||||
cache.zAdd(CachePrefix.HOT_WORD.getPrefix(), hotWordsSettingItem.getScore(), hotWordsSettingItem.getKeywords());
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -54,7 +54,7 @@ public class CancelOrderTaskExecute implements EveryMinuteExecute {
|
||||
List<Order> list = orderService.list(queryWrapper);
|
||||
List<String> cancelSnList = list.stream().map(Order::getSn).collect(Collectors.toList());
|
||||
for (String sn : cancelSnList) {
|
||||
orderService.systemCancel(sn, "超时未支付自动取消");
|
||||
orderService.systemCancel(sn, "超时未支付自动取消",false);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -5,32 +5,35 @@ import cn.hutool.core.date.DateUtil;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.common.enums.ResultCode;
|
||||
import cn.lili.common.exception.ServiceException;
|
||||
import cn.lili.modules.distribution.service.DistributionOrderService;
|
||||
import cn.lili.modules.member.entity.dto.MemberEvaluationDTO;
|
||||
import cn.lili.modules.member.entity.enums.EvaluationGradeEnum;
|
||||
import cn.lili.modules.member.service.MemberEvaluationService;
|
||||
import cn.lili.modules.order.aftersale.service.AfterSaleService;
|
||||
import cn.lili.modules.order.order.entity.dos.Order;
|
||||
import cn.lili.modules.order.order.entity.dos.OrderItem;
|
||||
import cn.lili.modules.order.order.entity.dto.OrderItemOperationDTO;
|
||||
import cn.lili.modules.order.order.entity.enums.CommentStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderComplaintStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderItemAfterSaleStatusEnum;
|
||||
import cn.lili.modules.order.order.entity.enums.OrderStatusEnum;
|
||||
import cn.lili.modules.order.order.mapper.OrderItemMapper;
|
||||
import cn.lili.modules.order.order.service.OrderItemService;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.order.order.service.StoreFlowService;
|
||||
import cn.lili.modules.store.entity.dto.StoreSettlementDay;
|
||||
import cn.lili.modules.store.service.BillService;
|
||||
import cn.lili.modules.store.service.StoreDetailService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.OrderSetting;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
|
||||
import com.baomidou.mybatisplus.core.conditions.update.LambdaUpdateWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
@@ -53,8 +56,6 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
*/
|
||||
@Autowired
|
||||
private OrderItemService orderItemService;
|
||||
@Resource
|
||||
private OrderItemMapper orderItemMapper;
|
||||
/**
|
||||
* 设置
|
||||
*/
|
||||
@@ -67,7 +68,21 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
private MemberEvaluationService memberEvaluationService;
|
||||
|
||||
@Autowired
|
||||
private AfterSaleService afterSaleService;
|
||||
private DistributionOrderService distributionOrderService;
|
||||
|
||||
@Autowired
|
||||
private StoreFlowService storeFlowService;
|
||||
|
||||
/**
|
||||
* 结算单
|
||||
*/
|
||||
@Autowired
|
||||
private BillService billService;
|
||||
/**
|
||||
* 店铺详情
|
||||
*/
|
||||
@Autowired
|
||||
private StoreDetailService storeDetailService;
|
||||
|
||||
/**
|
||||
* 执行每日任务
|
||||
@@ -82,14 +97,46 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
throw new ServiceException(ResultCode.ORDER_SETTING_ERROR);
|
||||
}
|
||||
|
||||
//自动确认收货
|
||||
completedOrder(orderSetting);
|
||||
//自动好评
|
||||
memberEvaluation(orderSetting);
|
||||
//关闭允许售后申请
|
||||
closeAfterSale(orderSetting);
|
||||
//关闭允许投诉
|
||||
closeComplaint(orderSetting);
|
||||
try {
|
||||
//自动确认收货
|
||||
completedOrder(orderSetting);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
try {
|
||||
//自动好评
|
||||
memberEvaluation(orderSetting);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
try {
|
||||
//关闭允许售后申请
|
||||
this.closeAfterSale(orderSetting);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
try {
|
||||
//关闭允许投诉
|
||||
closeComplaint(orderSetting);
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
|
||||
//修改分账状态
|
||||
try {
|
||||
storeFlowService.updateProfitSharingStatus();
|
||||
} catch (Exception e) {
|
||||
log.error("修改分账状态失败", e);
|
||||
}
|
||||
|
||||
//生成店铺结算单
|
||||
try {
|
||||
createBill();
|
||||
} catch (Exception e) {
|
||||
log.error("生成店铺结算单", e);
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
@@ -99,7 +146,6 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
*/
|
||||
private void completedOrder(OrderSetting orderSetting) {
|
||||
|
||||
|
||||
//订单自动收货时间 = 当前时间 - 自动收货时间天数
|
||||
DateTime receiveTime = DateUtil.offsetDay(DateUtil.date(), -orderSetting.getAutoReceive());
|
||||
LambdaQueryWrapper<Order> queryWrapper = new LambdaQueryWrapper<>();
|
||||
@@ -109,12 +155,16 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
queryWrapper.le(Order::getLogisticsTime, receiveTime);
|
||||
List<Order> list = orderService.list(queryWrapper);
|
||||
|
||||
//判断是否有符合条件的订单,进行订单完成处理
|
||||
if (!list.isEmpty()) {
|
||||
List<String> receiveSnList = list.stream().map(Order::getSn).collect(Collectors.toList());
|
||||
for (String orderSn : receiveSnList) {
|
||||
orderService.systemComplete(orderSn);
|
||||
try {
|
||||
//判断是否有符合条件的订单,进行订单完成处理
|
||||
if (!list.isEmpty()) {
|
||||
List<String> receiveSnList = list.stream().map(Order::getSn).collect(Collectors.toList());
|
||||
for (String orderSn : receiveSnList) {
|
||||
orderService.systemComplete(orderSn);
|
||||
}
|
||||
}
|
||||
} catch (Exception e) {
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
|
||||
@@ -128,10 +178,10 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
DateTime receiveTime = DateUtil.offsetDay(DateUtil.date(), -orderSetting.getAutoEvaluation());
|
||||
|
||||
//订单完成时间 <= 订单自动好评时间
|
||||
QueryWrapper queryWrapper = new QueryWrapper();
|
||||
queryWrapper.le("o.complete_time", receiveTime);
|
||||
queryWrapper.eq("oi.comment_status", CommentStatusEnum.UNFINISHED.name());
|
||||
List<OrderItem> orderItems = orderItemMapper.waitOperationOrderItem(queryWrapper);
|
||||
OrderItemOperationDTO orderItemOperationDTO =
|
||||
OrderItemOperationDTO.builder().receiveTime(receiveTime).commentStatus(CommentStatusEnum.UNFINISHED.name())
|
||||
.build();
|
||||
List<OrderItem> orderItems = orderItemService.waitOperationOrderItem(orderItemOperationDTO);
|
||||
|
||||
//判断是否有符合条件的订单,进行自动评价处理
|
||||
if (!orderItems.isEmpty()) {
|
||||
@@ -146,40 +196,32 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
memberEvaluationDTO.setDescriptionScore(5);
|
||||
memberEvaluationDTO.setServiceScore(5);
|
||||
|
||||
memberEvaluationService.addMemberEvaluation(memberEvaluationDTO, false);
|
||||
try {
|
||||
memberEvaluationService.addMemberEvaluation(memberEvaluationDTO, false);
|
||||
} catch (Exception e) {
|
||||
// 修改订单货物评价状态为已评价避免无限调用评价异常
|
||||
orderItemService.updateCommentStatus(orderItem.getSn(), CommentStatusEnum.FINISHED);
|
||||
log.error(e.getMessage(), e);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 关闭允许售后申请
|
||||
*
|
||||
* @param orderSetting 订单设置
|
||||
*/
|
||||
private void closeAfterSale(OrderSetting orderSetting) {
|
||||
|
||||
@Transactional(rollbackFor = Exception.class)
|
||||
public void closeAfterSale(OrderSetting orderSetting) {
|
||||
//订单关闭售后申请时间 = 当前时间 - 自动关闭售后申请天数
|
||||
DateTime receiveTime = DateUtil.offsetDay(DateUtil.date(), -orderSetting.getAutoEvaluation());
|
||||
DateTime receiveTime = DateUtil.offsetDay(DateUtil.date(), -orderSetting.getCloseAfterSale());
|
||||
|
||||
// OrderItemOperationDTO build = OrderItemOperationDTO.builder().receiveTime(receiveTime)
|
||||
// .afterSaleStatus(OrderItemAfterSaleStatusEnum.NOT_APPLIED.name()).build();
|
||||
// List<OrderItem> orderItems = orderItemService.waitOperationOrderItem(build);
|
||||
//关闭售后订单=未售后订单+小于订单关闭售后申请时间
|
||||
QueryWrapper queryWrapper = new QueryWrapper();
|
||||
queryWrapper.le("o.complete_time", receiveTime);
|
||||
queryWrapper.eq("oi.after_sale_status", OrderItemAfterSaleStatusEnum.NOT_APPLIED.name());
|
||||
List<OrderItem> orderItems = orderItemMapper.waitOperationOrderItem(queryWrapper);
|
||||
|
||||
//判断是否有符合条件的订单,关闭允许售后申请处理
|
||||
if (!orderItems.isEmpty()) {
|
||||
|
||||
//获取订单货物ID
|
||||
List<String> orderItemIdList = orderItems.stream().map(OrderItem::getId).collect(Collectors.toList());
|
||||
|
||||
//修改订单售后状态
|
||||
LambdaUpdateWrapper<OrderItem> lambdaUpdateWrapper = new LambdaUpdateWrapper<OrderItem>()
|
||||
.set(OrderItem::getAfterSaleStatus, OrderItemAfterSaleStatusEnum.EXPIRED.name())
|
||||
.in(OrderItem::getId, orderItemIdList);
|
||||
orderItemService.update(lambdaUpdateWrapper);
|
||||
}
|
||||
orderItemService.expiredAfterSaleStatus(receiveTime);
|
||||
|
||||
}
|
||||
|
||||
@@ -190,14 +232,17 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
*/
|
||||
private void closeComplaint(OrderSetting orderSetting) {
|
||||
|
||||
//为0则不限制
|
||||
if (orderSetting.getCloseComplaint() == null || orderSetting.getCloseComplaint() == 0) {
|
||||
return;
|
||||
}
|
||||
//订单关闭交易投诉申请时间 = 当前时间 - 自动关闭交易投诉申请天数
|
||||
DateTime receiveTime = DateUtil.offsetDay(DateUtil.date(), -orderSetting.getCloseComplaint());
|
||||
|
||||
//关闭售后订单=未售后订单+小于订单关闭售后申请时间
|
||||
QueryWrapper queryWrapper = new QueryWrapper();
|
||||
queryWrapper.le("o.complete_time", receiveTime);
|
||||
queryWrapper.eq("oi.complain_status", OrderComplaintStatusEnum.NO_APPLY.name());
|
||||
List<OrderItem> orderItems = orderItemMapper.waitOperationOrderItem(queryWrapper);
|
||||
OrderItemOperationDTO build = OrderItemOperationDTO.builder().receiveTime(receiveTime)
|
||||
.complainStatus(OrderComplaintStatusEnum.NO_APPLY.name()).build();
|
||||
List<OrderItem> orderItems = orderItemService.waitOperationOrderItem(build);
|
||||
|
||||
//判断是否有符合条件的订单,关闭允许售后申请处理
|
||||
if (!orderItems.isEmpty()) {
|
||||
@@ -206,12 +251,37 @@ public class OrderEveryDayTaskExecute implements EveryDayExecute {
|
||||
List<String> orderItemIdList = orderItems.stream().map(OrderItem::getId).collect(Collectors.toList());
|
||||
|
||||
//修改订单投诉状态
|
||||
LambdaUpdateWrapper<OrderItem> lambdaUpdateWrapper = new LambdaUpdateWrapper<OrderItem>()
|
||||
.set(OrderItem::getComplainStatus, OrderItemAfterSaleStatusEnum.EXPIRED.name())
|
||||
.in(OrderItem::getId, orderItemIdList);
|
||||
LambdaUpdateWrapper<OrderItem> lambdaUpdateWrapper =
|
||||
new LambdaUpdateWrapper<OrderItem>().set(OrderItem::getComplainStatus,
|
||||
OrderItemAfterSaleStatusEnum.EXPIRED.name()).in(OrderItem::getId, orderItemIdList);
|
||||
orderItemService.update(lambdaUpdateWrapper);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
* 1.查询今日待结算的商家
|
||||
* 2.查询商家上次结算日期,生成本次结算单
|
||||
* 3.记录商家结算日
|
||||
*/
|
||||
private void createBill() {
|
||||
//获取当前天数
|
||||
int day = DateUtil.date().dayOfMonth();
|
||||
|
||||
//获取待结算商家列表
|
||||
List<StoreSettlementDay> storeList = storeDetailService.getSettlementStore(day);
|
||||
|
||||
//获取当前时间
|
||||
DateTime endTime = DateUtil.date();
|
||||
//批量商家结算
|
||||
for (StoreSettlementDay storeSettlementDay : storeList) {
|
||||
|
||||
//生成结算单
|
||||
billService.createBill(storeSettlementDay.getStoreId(), storeSettlementDay.getSettlementDay(), endTime);
|
||||
|
||||
//修改店铺结算时间
|
||||
storeDetailService.updateSettlementDay(storeSettlementDay.getStoreId(), endTime);
|
||||
}
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
@@ -0,0 +1,45 @@
|
||||
package cn.lili.timetask.handler.impl.promotion;
|
||||
|
||||
import cn.lili.common.enums.PromotionTypeEnum;
|
||||
import cn.lili.modules.promotion.entity.dos.Seckill;
|
||||
import cn.lili.modules.promotion.service.MemberCouponSignService;
|
||||
import cn.lili.modules.promotion.service.SeckillService;
|
||||
import cn.lili.modules.promotion.tools.PromotionTools;
|
||||
import cn.lili.modules.search.service.EsGoodsIndexService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.SeckillSetting;
|
||||
import cn.lili.modules.system.entity.enums.SettingEnum;
|
||||
import cn.lili.modules.system.service.SettingService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import com.google.gson.Gson;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* 促销活动每日定时器
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2021/3/18 3:23 下午
|
||||
*/
|
||||
@Slf4j
|
||||
@Component
|
||||
public class MemberCouponSignEverydayExecute implements EveryDayExecute {
|
||||
|
||||
@Autowired
|
||||
private MemberCouponSignService memberCouponSignService;
|
||||
|
||||
/**
|
||||
* 将已过期的促销活动置为结束
|
||||
*/
|
||||
@Override
|
||||
public void execute() {
|
||||
try {
|
||||
memberCouponSignService.clean();
|
||||
} catch (Exception e) {
|
||||
log.error("清除领取优惠券标记异常", e);
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
@@ -1,7 +1,9 @@
|
||||
package cn.lili.timetask.handler.impl.promotion;
|
||||
|
||||
import cn.lili.common.enums.PromotionTypeEnum;
|
||||
import cn.lili.modules.promotion.entity.dos.Seckill;
|
||||
import cn.lili.modules.promotion.service.SeckillService;
|
||||
import cn.lili.modules.promotion.tools.PromotionTools;
|
||||
import cn.lili.modules.search.service.EsGoodsIndexService;
|
||||
import cn.lili.modules.system.entity.dos.Setting;
|
||||
import cn.lili.modules.system.entity.dto.SeckillSetting;
|
||||
@@ -62,14 +64,22 @@ public class PromotionEverydayExecute implements EveryDayExecute {
|
||||
/**
|
||||
* 添加秒杀活动
|
||||
* 从系统设置中获取秒杀活动的配置
|
||||
* 添加30天后的秒杀活动
|
||||
* 添加明天后的秒杀活动
|
||||
*/
|
||||
private void addSeckill() {
|
||||
Setting setting = settingService.get(SettingEnum.SECKILL_SETTING.name());
|
||||
SeckillSetting seckillSetting = new Gson().fromJson(setting.getSettingValue(), SeckillSetting.class);
|
||||
log.info("生成秒杀活动设置:{}", seckillSetting);
|
||||
for (int i = 1; i <= SeckillService.PRE_CREATION; i++) {
|
||||
Seckill seckill = new Seckill(i, seckillSetting.getHours(), seckillSetting.getSeckillRule());
|
||||
seckillService.savePromotions(seckill);
|
||||
seckill.setApplyEndTime(null);
|
||||
|
||||
//如果已经存在促销,则不再次保存
|
||||
if (seckillService.list(
|
||||
PromotionTools.checkActiveTime(seckill.getStartTime(), seckill.getEndTime(), PromotionTypeEnum.SECKILL, null, seckill.getId())).isEmpty()) {
|
||||
boolean result = seckillService.savePromotions(seckill);
|
||||
log.info("生成秒杀活动参数:{},结果:{}", seckill, result);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@@ -13,6 +13,7 @@ import java.util.ArrayList;
|
||||
import java.util.Calendar;
|
||||
import java.util.Date;
|
||||
import java.util.List;
|
||||
import java.util.concurrent.atomic.AtomicReference;
|
||||
import java.util.stream.Collectors;
|
||||
|
||||
/**
|
||||
@@ -54,8 +55,16 @@ public class OnlineMemberStatistics implements EveryHourExecute {
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
|
||||
Calendar finalCalendar = calendar;
|
||||
|
||||
AtomicReference<Integer> lastNum = new AtomicReference<>(0);
|
||||
onlineMemberVOS = onlineMemberVOS.stream()
|
||||
.filter(onlineMemberVO -> onlineMemberVO.getDate().after(finalCalendar.getTime()))
|
||||
.filter(onlineMemberVO -> {
|
||||
//如果为过滤参数,则记录为过期参数,则为统一时段上一周期的在线人数
|
||||
if (!onlineMemberVO.getDate().after(finalCalendar.getTime())) {
|
||||
lastNum.set(onlineMemberVO.getNum());
|
||||
}
|
||||
return onlineMemberVO.getDate().after(finalCalendar.getTime());
|
||||
})
|
||||
.collect(Collectors.toList());
|
||||
|
||||
//计入新数据
|
||||
@@ -63,7 +72,8 @@ public class OnlineMemberStatistics implements EveryHourExecute {
|
||||
calendar.set(Calendar.MINUTE, 0);
|
||||
calendar.set(Calendar.SECOND, 0);
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
onlineMemberVOS.add(new OnlineMemberVO(calendar.getTime(), cache.keys(CachePrefix.ACCESS_TOKEN.getPrefix(UserEnums.MEMBER) + "*").size()));
|
||||
onlineMemberVOS.add(new OnlineMemberVO(calendar.getTime(), cache.keys(CachePrefix.ACCESS_TOKEN.getPrefix(UserEnums.MEMBER) + "*").size(),
|
||||
lastNum.get()));
|
||||
|
||||
//写入缓存
|
||||
cache.put(CachePrefix.ONLINE_MEMBER.getPrefix(), onlineMemberVOS);
|
||||
@@ -95,7 +105,7 @@ public class OnlineMemberStatistics implements EveryHourExecute {
|
||||
onlineMemberVOS = onlineMemberVOS.stream()
|
||||
.filter(onlineMemberVO -> onlineMemberVO.getDate().after(calendar.getTime()))
|
||||
.collect(Collectors.toList());
|
||||
onlineMemberVOS.add(new OnlineMemberVO(time, num));
|
||||
onlineMemberVOS.add(new OnlineMemberVO(time, num, num));
|
||||
|
||||
//写入缓存
|
||||
cache.put(CachePrefix.ONLINE_MEMBER.getPrefix(), onlineMemberVOS);
|
||||
|
||||
@@ -0,0 +1,49 @@
|
||||
package cn.lili.timetask.handler.impl.store;
|
||||
|
||||
import cn.lili.modules.goods.service.GoodsSkuService;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import cn.lili.modules.store.entity.enums.StoreStatusEnum;
|
||||
import cn.lili.modules.store.service.StoreService;
|
||||
import cn.lili.timetask.handler.EveryDayExecute;
|
||||
import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 店铺信息更新
|
||||
*
|
||||
* @author Chopper
|
||||
* @since 2021/3/15 5:30 下午
|
||||
*/
|
||||
@Component
|
||||
@Slf4j
|
||||
public class StoreExecute implements EveryDayExecute {
|
||||
/**
|
||||
* 店铺
|
||||
*/
|
||||
@Autowired
|
||||
private StoreService storeService;
|
||||
|
||||
@Autowired
|
||||
private GoodsSkuService goodsSkuService;
|
||||
|
||||
@Override
|
||||
public void execute() {
|
||||
//获取所有开启的店铺
|
||||
List<Store> storeList = storeService.list(new LambdaQueryWrapper<Store>().eq(Store::getStoreDisable, StoreStatusEnum.OPEN.name()));
|
||||
|
||||
for (Store store : storeList) {
|
||||
try {
|
||||
Long num = goodsSkuService.countSkuNum(store.getId());
|
||||
storeService.updateStoreGoodsNum(store.getId(), num);
|
||||
} catch (Exception e) {
|
||||
log.error("店铺id为{},更新商品数量失败", store.getId(), e);
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
}
|
||||
@@ -1,9 +1,8 @@
|
||||
package cn.lili.timetask.handler.impl.storerating;
|
||||
package cn.lili.timetask.handler.impl.store;
|
||||
|
||||
import cn.lili.common.enums.SwitchEnum;
|
||||
import cn.lili.modules.member.entity.dos.MemberEvaluation;
|
||||
import cn.lili.modules.member.entity.vo.StoreRatingVO;
|
||||
import cn.lili.modules.member.mapper.MemberEvaluationMapper;
|
||||
import cn.lili.modules.member.service.MemberEvaluationService;
|
||||
import cn.lili.modules.store.entity.dos.Store;
|
||||
import cn.lili.modules.store.entity.enums.StoreStatusEnum;
|
||||
import cn.lili.modules.store.service.StoreService;
|
||||
@@ -14,7 +13,6 @@ import com.baomidou.mybatisplus.core.toolkit.Wrappers;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import javax.annotation.Resource;
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
@@ -33,8 +31,8 @@ public class StoreRatingExecute implements EveryDayExecute {
|
||||
/**
|
||||
* 会员评价
|
||||
*/
|
||||
@Resource
|
||||
private MemberEvaluationMapper memberEvaluationMapper;
|
||||
@Autowired
|
||||
private MemberEvaluationService memberEvaluationService;
|
||||
|
||||
|
||||
@Override
|
||||
@@ -43,10 +41,7 @@ public class StoreRatingExecute implements EveryDayExecute {
|
||||
List<Store> storeList = storeService.list(new LambdaQueryWrapper<Store>().eq(Store::getStoreDisable, StoreStatusEnum.OPEN.name()));
|
||||
for (Store store : storeList) {
|
||||
//店铺所有开启的评价
|
||||
LambdaQueryWrapper<MemberEvaluation> lambdaQueryWrapper = Wrappers.lambdaQuery();
|
||||
lambdaQueryWrapper.eq(MemberEvaluation::getStoreId, store.getId());
|
||||
lambdaQueryWrapper.eq(MemberEvaluation::getStatus, SwitchEnum.OPEN.name());
|
||||
StoreRatingVO storeRatingVO = memberEvaluationMapper.getStoreRatingVO(lambdaQueryWrapper);
|
||||
StoreRatingVO storeRatingVO = memberEvaluationService.getStoreRatingVO(store.getId(), SwitchEnum.OPEN.name());
|
||||
|
||||
if (storeRatingVO != null) {
|
||||
//保存评分
|
||||
@@ -0,0 +1,31 @@
|
||||
package cn.lili.trigger.executor;
|
||||
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.modules.promotion.service.CouponActivityService;
|
||||
import cn.lili.trigger.TimeTriggerExecutor;
|
||||
import cn.lili.trigger.message.CouponActivityMessage;
|
||||
import cn.lili.trigger.model.TimeExecuteConstant;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
/**
|
||||
* 优惠券活动精准发圈延时触发
|
||||
*
|
||||
* @author Bulbasaur
|
||||
* @since 2021/6/1 5:02 下午
|
||||
*/
|
||||
@Slf4j
|
||||
@Component(TimeExecuteConstant.COUPON_ACTIVITY_EXECUTOR)
|
||||
public class CouponActivityTriggerExecutor implements TimeTriggerExecutor {
|
||||
|
||||
|
||||
@Autowired
|
||||
private CouponActivityService couponActivityService;
|
||||
|
||||
@Override
|
||||
public void execute(Object object) {
|
||||
CouponActivityMessage couponActivityMessage = JSONUtil.toBean(JSONUtil.parseObj(object), CouponActivityMessage.class);
|
||||
couponActivityService.specifyCoupon(couponActivityMessage.getCouponActivityId());
|
||||
}
|
||||
}
|
||||
@@ -3,6 +3,7 @@ package cn.lili.trigger.executor;
|
||||
import cn.hutool.json.JSONUtil;
|
||||
import cn.lili.modules.order.order.service.OrderService;
|
||||
import cn.lili.modules.promotion.entity.dos.Pintuan;
|
||||
import cn.lili.modules.promotion.service.PintuanService;
|
||||
import cn.lili.trigger.TimeTriggerExecutor;
|
||||
import cn.lili.trigger.message.PintuanOrderMessage;
|
||||
import cn.lili.trigger.model.TimeExecuteConstant;
|
||||
@@ -25,6 +26,8 @@ public class PromotionTimeTriggerExecutor implements TimeTriggerExecutor {
|
||||
*/
|
||||
@Autowired
|
||||
private OrderService orderService;
|
||||
@Autowired
|
||||
private PintuanService pintuanService;
|
||||
|
||||
|
||||
@Override
|
||||
@@ -36,7 +39,7 @@ public class PromotionTimeTriggerExecutor implements TimeTriggerExecutor {
|
||||
//拼团订单自动处理
|
||||
orderService.agglomeratePintuanOrder(pintuanOrderMessage.getPintuanId(), pintuanOrderMessage.getOrderSn());
|
||||
}
|
||||
Pintuan pintuan = JSONUtil.toBean(JSONUtil.parseObj(object), Pintuan.class);
|
||||
Pintuan pintuan = pintuanService.getById(pintuanOrderMessage.getPintuanId());
|
||||
if (pintuan != null && pintuan.getId() != null) {
|
||||
this.orderService.checkFictitiousOrder(pintuan.getId(), pintuan.getRequiredNum(), pintuan.getFictitious());
|
||||
}
|
||||
|
||||
@@ -67,7 +67,7 @@ spring:
|
||||
default-datasource:
|
||||
type: com.alibaba.druid.pool.DruidDataSource
|
||||
driverClassName: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://127.0.0.1:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
url: jdbc:mysql://127.0.0.1:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&rewriteBatchedStatements=true&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
username: root
|
||||
password: lilishop
|
||||
maxActive: 20
|
||||
@@ -260,6 +260,8 @@ lili:
|
||||
order-group: lili_order_group
|
||||
member-topic: lili_member_topic
|
||||
member-group: lili_member_group
|
||||
store-topic: lili_store_topic
|
||||
store-group: lili_store_group
|
||||
other-topic: lili_other_topic
|
||||
other-group: lili_other_group
|
||||
notice-topic: lili_notice_topic
|
||||
|
||||
@@ -20,6 +20,22 @@
|
||||
</encoder>
|
||||
</appender>
|
||||
|
||||
<appender name="RocketmqClientAppender" class="ch.qos.logback.core.rolling.RollingFileAppender">
|
||||
<file>${LOG_FILE_PATH}/rocketmq.log</file>
|
||||
<rollingPolicy class="ch.qos.logback.core.rolling.TimeBasedRollingPolicy">
|
||||
<fileNamePattern>${LOG_FILE_PATH}/rocketmq/rocketmq-%d{yyyy-MM-dd}.log</fileNamePattern>
|
||||
<maxHistory>30</maxHistory>
|
||||
<totalSizeCap>30MB</totalSizeCap>
|
||||
</rollingPolicy>
|
||||
<encoder>
|
||||
<pattern>%d{yy-MM-dd.HH:mm:ss.SSS} [%-16t] %-5p %-22c{0} %X{ServiceId} - %m%n</pattern>
|
||||
</encoder>
|
||||
</appender>
|
||||
<logger name="RocketmqClient" additivity="false">
|
||||
<level value="info" />
|
||||
<appender-ref ref="RocketmqClientAppender"/>
|
||||
</logger>
|
||||
|
||||
<!--输出到elk的LOGSTASH-->
|
||||
<appender name="LOGSTASH" class="net.logstash.logback.appender.LogstashTcpSocketAppender">
|
||||
<!-- 配置elk日志收集 配饰的是 LOGSTASH 的地址-->
|
||||
|
||||
@@ -1,64 +0,0 @@
|
||||
package cn.lili.buyer.test.cart;
|
||||
|
||||
import cn.lili.common.utils.DateUtil;
|
||||
import cn.lili.timetask.handler.impl.statistics.OnlineMemberStatistics;
|
||||
import org.junit.jupiter.api.Test;
|
||||
import org.junit.jupiter.api.extension.ExtendWith;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.boot.test.context.SpringBootTest;
|
||||
import org.springframework.test.context.junit.jupiter.SpringExtension;
|
||||
|
||||
import java.util.Calendar;
|
||||
import java.util.Random;
|
||||
|
||||
/**
|
||||
* 订单库存扣减
|
||||
*/
|
||||
@ExtendWith(SpringExtension.class)
|
||||
@SpringBootTest
|
||||
class OnlineTest {
|
||||
|
||||
@Autowired
|
||||
private OnlineMemberStatistics onlineMemberStatistics;
|
||||
|
||||
//订单支付,库存扣减单元测试
|
||||
@Test
|
||||
void everyHour() {
|
||||
onlineMemberStatistics.execute();
|
||||
}
|
||||
|
||||
//订单支付,库存扣减单元测试
|
||||
@Test
|
||||
void customSetting() {
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.set(Calendar.MINUTE, 0);
|
||||
calendar.set(Calendar.SECOND, 0);
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
|
||||
calendar.set(Calendar.HOUR_OF_DAY, calendar.get(Calendar.HOUR_OF_DAY) - 48 );
|
||||
//循环填充数据
|
||||
for (int i = 0; i < 48; i++) {
|
||||
calendar.set(Calendar.HOUR_OF_DAY, calendar.get(Calendar.HOUR_OF_DAY) + 1);
|
||||
System.out.println(DateUtil.toString(calendar.getTime(),""));
|
||||
Random random = new Random();
|
||||
onlineMemberStatistics.execute(calendar.getTime(), random.nextInt(1000000));
|
||||
}
|
||||
}
|
||||
|
||||
public static void main(String[] args) {
|
||||
|
||||
Calendar calendar = Calendar.getInstance();
|
||||
calendar.set(Calendar.MINUTE, 0);
|
||||
calendar.set(Calendar.SECOND, 0);
|
||||
calendar.set(Calendar.MILLISECOND, 0);
|
||||
|
||||
calendar.set(Calendar.HOUR_OF_DAY, calendar.get(Calendar.HOUR_OF_DAY) - 48 - 1);
|
||||
//循环填充数据
|
||||
for (int i = 0; i < 48; i++) {
|
||||
calendar.set(Calendar.HOUR_OF_DAY, calendar.get(Calendar.HOUR_OF_DAY) + 1);
|
||||
System.out.println(calendar.getTime().getTime());
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
651
deploy-api.yml
Normal file
651
deploy-api.yml
Normal file
@@ -0,0 +1,651 @@
|
||||
apiVersion: v1
|
||||
kind: Namespace
|
||||
metadata:
|
||||
name: lilishop-service
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: buyer-api-service
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: buyer-api-service
|
||||
app.kubernetes.io/instance: api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
type: NodePort
|
||||
ports:
|
||||
- name: "8888"
|
||||
nodePort: 30888
|
||||
port: 8888
|
||||
targetPort: buyer8888
|
||||
selector:
|
||||
lilishop.service: buyer-api
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: common-api-service
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: common-api-service
|
||||
app.kubernetes.io/instance: api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
type: NodePort
|
||||
ports:
|
||||
- name: "8890"
|
||||
nodePort: 30890
|
||||
port: 8890
|
||||
targetPort: common8890
|
||||
selector:
|
||||
lilishop.service: common-api
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: seller-api-service
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: seller-api-service
|
||||
app.kubernetes.io/instance: api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
type: NodePort
|
||||
ports:
|
||||
- name: "8889"
|
||||
nodePort: 30889
|
||||
port: 8889
|
||||
targetPort: seller8889
|
||||
selector:
|
||||
lilishop.service: seller-api
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: Service
|
||||
metadata:
|
||||
name: manager-api-service
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: manager-api-service
|
||||
app.kubernetes.io/instance: api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
type: NodePort
|
||||
ports:
|
||||
- name: "8887"
|
||||
nodePort: 30887
|
||||
port: 8887
|
||||
targetPort: manager8887
|
||||
selector:
|
||||
lilishop.service: manager-api
|
||||
|
||||
---
|
||||
apiVersion: v1
|
||||
kind: ConfigMap
|
||||
metadata:
|
||||
name: api-config
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: mysql-db-config
|
||||
app.kubernetes.io/instance: mysql-single
|
||||
app.kubernetes.io/version: "8.0.28"
|
||||
app.kubernetes.io/component: database
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
data:
|
||||
application.yml: |
|
||||
server:
|
||||
servlet:
|
||||
context-path: /
|
||||
|
||||
tomcat:
|
||||
uri-encoding: UTF-8
|
||||
threads:
|
||||
min-spare: 50
|
||||
max: 1000
|
||||
|
||||
# 与Spring Boot 2一样,默认情况下,大多数端点都不通过http公开,我们公开了所有端点。对于生产,您应该仔细选择要公开的端点。
|
||||
management:
|
||||
# health:
|
||||
# elasticsearch:
|
||||
# enabled: false
|
||||
# datasource:
|
||||
# enabled: false
|
||||
endpoints:
|
||||
web:
|
||||
exposure:
|
||||
include: '*'
|
||||
spring:
|
||||
# 要在其中注册的Spring Boot Admin Server的URL。
|
||||
boot:
|
||||
admin:
|
||||
client:
|
||||
url: http://192.168.0.116:8000
|
||||
cache:
|
||||
type: redis
|
||||
# Redis
|
||||
redis:
|
||||
host: redis-service.lilishop-middleware
|
||||
port: 6379
|
||||
password: lilishop
|
||||
lettuce:
|
||||
pool:
|
||||
# 连接池最大连接数(使用负值表示没有限制) 默认 8
|
||||
max-active: 200
|
||||
# 连接池最大阻塞等待时间(使用负值表示没有限制) 默认 -1
|
||||
max-wait: 20
|
||||
# 连接池中的最大空闲连接 默认 8
|
||||
max-idle: 10
|
||||
# 连接池中的最小空闲连接 默认 8
|
||||
min-idle: 8
|
||||
# 文件大小上传配置
|
||||
servlet:
|
||||
multipart:
|
||||
max-file-size: 20MB
|
||||
max-request-size: 20MB
|
||||
jackson:
|
||||
time-zone: GMT+8
|
||||
serialization:
|
||||
#关闭jackson 对json做解析
|
||||
fail-on-empty-beans: false
|
||||
|
||||
shardingsphere:
|
||||
datasource:
|
||||
# 数据库名称,可自定义,可以为多个,以逗号隔开,每个在这里定义的库,都要在下面定义连接属性
|
||||
names: default-datasource
|
||||
default-datasource:
|
||||
type: com.alibaba.druid.pool.DruidDataSource
|
||||
driverClassName: com.mysql.cj.jdbc.Driver
|
||||
url: jdbc:mysql://mysql.lilishop-middleware:3306/lilishop?useUnicode=true&characterEncoding=utf-8&useSSL=false&allowPublicKeyRetrieval=true&serverTimezone=Asia/Shanghai
|
||||
username: root
|
||||
password: lilishop
|
||||
maxActive: 50
|
||||
initialSize: 20
|
||||
maxWait: 60000
|
||||
minIdle: 5
|
||||
timeBetweenEvictionRunsMillis: 60000
|
||||
minEvictableIdleTimeMillis: 300000
|
||||
validationQuery: SELECT 1 FROM DUAL
|
||||
testWhileIdle: true
|
||||
testOnBorrow: false
|
||||
testOnReturn: false
|
||||
#是否缓存preparedStatement,也就是PSCache。在mysql下建议关闭。 PSCache对支持游标的数据库性能提升巨大,比如说oracle。
|
||||
poolPreparedStatements: false
|
||||
#要启用PSCache,-1为关闭 必须配置大于0,当大于0时,poolPreparedStatements自动触发修改为true 可以把这个数值配置大一些,比如说100
|
||||
maxOpenPreparedStatements: -1
|
||||
#配置监控统计拦截的filters,去掉后监控界面sql无法统计,'wall'用于防火墙
|
||||
filters: stat,wall,log4j2
|
||||
#通过connectProperties属性来打开mergeSql功能;慢SQL记录
|
||||
connectionProperties: druid.stat.mergeSql=true;druid.stat.slowSqlMillis=5000
|
||||
#合并多个DruidDataSource的监控数据
|
||||
useGlobalDataSourceStat: true
|
||||
loginUsername: druid
|
||||
loginPassword: druid
|
||||
# sharding:
|
||||
# default-data-source-name: default-datasource
|
||||
# #需要拆分的表,可以设置多个 在 li_order 级别即可
|
||||
# tables:
|
||||
# #需要进行分表的逻辑表名
|
||||
# li_order:
|
||||
# #实际的表结点,下面代表的是li_order_为开头的所有表,如果能确定表的范围例如按月份分表,这里的写法是data2020.li_order_$->{2020..2021}_$->{01..12} 表示例如 li_order_2020_01 li_order_2020_03 li_order_2021_01
|
||||
# actual-data-nodes: data2020.li_order_$->{2019..2021}_$->{01..12}
|
||||
# table-strategy:
|
||||
# # 分表策略,根据创建日期
|
||||
# standard:
|
||||
# sharding-column: create_time
|
||||
# #分表策略
|
||||
# precise-algorithm-class-name: cn.lili.mybatis.sharding.CreateTimeShardingTableAlgorithm
|
||||
# #范围查询实现
|
||||
# range-algorithm-class-name: cn.lili.mybatis.sharding.CreateTimeShardingTableAlgorithm
|
||||
props:
|
||||
#是否打印逻辑SQL语句和实际SQL语句,建议调试时打印,在生产环境关闭
|
||||
sql:
|
||||
show: true
|
||||
|
||||
# 忽略鉴权url
|
||||
ignored:
|
||||
urls:
|
||||
- /editor-app/**
|
||||
- /actuator**
|
||||
- /actuator/**
|
||||
- /MP_verify_qSyvBPhDsPdxvOhC.txt
|
||||
- /weixin/**
|
||||
- /source/**
|
||||
- /store/passport/login/**
|
||||
- /store/passport/login/refresh/**
|
||||
- /common/common/slider/**
|
||||
- /common/common/sms/**
|
||||
- /buyer/payment/cashier/**
|
||||
- /buyer/other/pageData/**
|
||||
- /buyer/other/article/**
|
||||
- /buyer/goods/**
|
||||
- /buyer/store/**
|
||||
- /buyer/passport/connect/**
|
||||
- /buyer/members/**
|
||||
- /buyer/passport/member/**
|
||||
- /buyer/passport/member/refresh/**
|
||||
- /buyer/promotion/pintuan/**
|
||||
- /buyer/promotion/seckill/**
|
||||
- /buyer/promotion/pointsGoods/**
|
||||
- /buyer/promotion/coupon
|
||||
- /buyer/member/evaluation/**/goodsEvaluation
|
||||
- /buyer/member/evaluation/**/evaluationNumber
|
||||
- /buyer/other/appVersion/**
|
||||
- /buyer/broadcast/studio/**
|
||||
- /manager/passport/user/login
|
||||
- /manager/passport/user/refresh/**
|
||||
- /manager/other/elasticsearch
|
||||
- /manager/other/customWords
|
||||
- /druid/**
|
||||
- /swagger-ui.html
|
||||
- /doc.html
|
||||
- /swagger-resources/**
|
||||
- /swagger/**
|
||||
- /webjars/**
|
||||
- /v2/api-docs**
|
||||
- /configuration/ui
|
||||
- /boot-admin
|
||||
- /manager/promotion/seckill/init
|
||||
- /**/*.js
|
||||
- /**/*.css
|
||||
- /**/*.png
|
||||
- /**/*.ico
|
||||
|
||||
# Swagger界面内容配置
|
||||
swagger:
|
||||
title: lilishop API接口文档
|
||||
description: lilishop Api Documentation
|
||||
version: 4.2.2
|
||||
termsOfServiceUrl: https://pickmall.cn
|
||||
contact:
|
||||
name: lili
|
||||
url: https://pickmall.cn
|
||||
email: admin@pickmall.com
|
||||
|
||||
# Mybatis-plus
|
||||
mybatis-plus:
|
||||
mapper-locations: classpath*:mapper/*.xml
|
||||
configuration:
|
||||
#缓存开启
|
||||
cache-enabled: true
|
||||
#日志
|
||||
# log-impl: org.apache.ibatis.logging.stdout.StdOutImpl
|
||||
|
||||
# 日志
|
||||
logging:
|
||||
# 输出级别
|
||||
level:
|
||||
cn.lili: info
|
||||
# org.hibernate: debug
|
||||
# org.springframework: debug
|
||||
file:
|
||||
# 指定路径
|
||||
path: logs
|
||||
logback:
|
||||
rollingpolicy:
|
||||
# 最大保存天数
|
||||
max-history: 7
|
||||
# 每个文件最大大小
|
||||
max-file-size: 5MB
|
||||
#加密参数
|
||||
jasypt:
|
||||
encryptor:
|
||||
password: lili
|
||||
|
||||
|
||||
lili:
|
||||
#验证码设置
|
||||
verification-code:
|
||||
#图形验证码有效时间 秒 包含滑块验证码有效时间, 以及验证通过之后,缓存中存储的验证结果有效时间
|
||||
effectiveTime: 300
|
||||
#水印
|
||||
watermark: LILI-SHOP
|
||||
#干扰项数量 最大2 默认0
|
||||
interfereNum: 1
|
||||
#允许误差像素
|
||||
faultTolerant: 3
|
||||
#短信模版配置
|
||||
sms:
|
||||
#登录
|
||||
LOGIN: SMS_205755300
|
||||
#注册
|
||||
REGISTER: SMS_205755298
|
||||
#找回密码
|
||||
FIND_USER: SMS_205755301
|
||||
#设置密码
|
||||
UPDATE_PASSWORD: SMS_205755297
|
||||
#支付密码
|
||||
WALLET_PASSWORD: SMS_205755301
|
||||
system:
|
||||
isDemoSite: false
|
||||
isTestModel: true
|
||||
# 脱敏级别:
|
||||
# 0:不做脱敏处理
|
||||
# 1:管理端用户手机号等信息脱敏
|
||||
# 2:商家端信息脱敏(为2时,表示管理端,商家端同时脱敏)
|
||||
sensitiveLevel: 1
|
||||
|
||||
statistics:
|
||||
# 在线人数统计 X 小时。这里设置48,即统计过去48小时每小时在线人数
|
||||
onlineMember: 48
|
||||
# 当前在线人数刷新时间间隔,单位秒,设置为600,则每10分钟刷新一次
|
||||
currentOnlineUpdate: 600
|
||||
#qq lbs 申请
|
||||
lbs:
|
||||
key: 4BYBZ-7MT6S-PUAOA-6BNWL-FJUD7-UUFXT
|
||||
sk: zhNKVrJK6UPOhqIjn8AQvG37b9sz6
|
||||
#域名
|
||||
domain:
|
||||
pc: http://192.168.0.116:8888
|
||||
wap: http://192.168.0.116:8888
|
||||
seller: http://192.168.0.116:8888
|
||||
admin: http://192.168.0.116:8888
|
||||
#api地址
|
||||
api:
|
||||
buyer: http://192.168.0.116:8888
|
||||
base: http://192.168.0.116:8888
|
||||
manager: http://192.168.0.116:8888
|
||||
seller: http://192.168.0.116:8888
|
||||
|
||||
# jwt 细节设定
|
||||
jwt-setting:
|
||||
# token过期时间(分钟)
|
||||
tokenExpireTime: 30
|
||||
|
||||
# 使用Spring @Cacheable注解失效时间
|
||||
cache:
|
||||
# 过期时间 单位秒 永久不过期设为-1
|
||||
timeout: 1500
|
||||
#多线程配置
|
||||
thread:
|
||||
corePoolSize: 5
|
||||
maxPoolSize: 50
|
||||
queueCapacity: 50
|
||||
data:
|
||||
elasticsearch:
|
||||
cluster-name: elasticsearch
|
||||
cluster-nodes: elasticsearch.lilishop-middleware:9200
|
||||
index:
|
||||
number-of-replicas: 0
|
||||
number-of-shards: 3
|
||||
index-prefix: lili
|
||||
schema: http
|
||||
# account:
|
||||
# username: elastic
|
||||
# password: LiLiShopES
|
||||
|
||||
logstash:
|
||||
server: logstash-service.lilishop-middleware:4560
|
||||
rocketmq:
|
||||
promotion-topic: lili_promotion_topic
|
||||
promotion-group: lili_promotion_group
|
||||
msg-ext-topic: lili_msg_topic
|
||||
msg-ext-group: lili_msg_group
|
||||
goods-topic: lili_goods_topic
|
||||
goods-group: lili_goods_group
|
||||
order-topic: lili_order_topic
|
||||
order-group: lili_order_group
|
||||
member-topic: lili_member_topic
|
||||
member-group: lili_member_group
|
||||
other-topic: lili_other_topic
|
||||
other-group: lili_other_group
|
||||
notice-topic: lili_notice_topic
|
||||
notice-group: lili_notice_group
|
||||
notice-send-topic: lili_send_notice_topic
|
||||
notice-send-group: lili_send_notice_group
|
||||
after-sale-topic: lili_after_sale_topic
|
||||
after-sale-group: lili_after_sale_group
|
||||
rocketmq:
|
||||
name-server: rocketmq.lilishop-middleware:9876
|
||||
isVIPChannel: false
|
||||
producer:
|
||||
group: lili_group
|
||||
send-message-timeout: 30000
|
||||
|
||||
xxl:
|
||||
job:
|
||||
admin:
|
||||
addresses: http://xxl-job-service.lilishop-middleware:9001/xxl-job-admin
|
||||
executor:
|
||||
appname: xxl-job-executor-lilishop
|
||||
address:
|
||||
ip:
|
||||
port: 8891
|
||||
logpath: ./xxl-job/executor
|
||||
logretentiondays: 7
|
||||
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: buyer-api
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: buyer-api-service
|
||||
app.kubernetes.io/instance: buyer-api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
lilishop.service: buyer-api
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
lilishop.service: buyer-api
|
||||
spec:
|
||||
containers:
|
||||
- image: 192.168.0.108:31320/buyer-api:4.2.4.1
|
||||
name: buyer-api
|
||||
env:
|
||||
- name: TZ
|
||||
value: Asia/Shanghai
|
||||
- name: JAVA_OPTS
|
||||
value: -XX:MetaspaceSize=64m -XX:MaxMetaspaceSize=128m -Xms128m -Xmx256m -Xmn128m -Xss256k -XX:SurvivorRatio=8 -XX:+UseConcMarkSweepGC
|
||||
ports:
|
||||
- name: buyer8888
|
||||
containerPort: 8888
|
||||
volumeMounts:
|
||||
- mountPath: /application.yml
|
||||
name: application-yml
|
||||
subPath: application.yml
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- configMap:
|
||||
name: api-config
|
||||
name: application-yml
|
||||
|
||||
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: common-api
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: common-api-service
|
||||
app.kubernetes.io/instance: common-api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
lilishop.service: common-api
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
lilishop.service: common-api
|
||||
spec:
|
||||
containers:
|
||||
- image: 192.168.0.108:31320/common-api:4.2.4.1
|
||||
name: common-api
|
||||
env:
|
||||
- name: TZ
|
||||
value: Asia/Shanghai
|
||||
- name: JAVA_OPTS
|
||||
value: -XX:MetaspaceSize=64m -XX:MaxMetaspaceSize=128m -Xms128m -Xmx256m -Xmn128m -Xss256k -XX:SurvivorRatio=8 -XX:+UseConcMarkSweepGC
|
||||
ports:
|
||||
- name: common8890
|
||||
containerPort: 8890
|
||||
volumeMounts:
|
||||
- mountPath: /application.yml
|
||||
name: application-yml
|
||||
subPath: application.yml
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- configMap:
|
||||
name: api-config
|
||||
name: application-yml
|
||||
|
||||
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: seller-api
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: seller-api-service
|
||||
app.kubernetes.io/instance: seller-api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
lilishop.service: seller-api
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
lilishop.service: seller-api
|
||||
spec:
|
||||
containers:
|
||||
- image: 192.168.0.108:31320/seller-api:4.2.4.1
|
||||
name: seller-api
|
||||
env:
|
||||
- name: TZ
|
||||
value: Asia/Shanghai
|
||||
- name: JAVA_OPTS
|
||||
value: -XX:MetaspaceSize=64m -XX:MaxMetaspaceSize=128m -Xms128m -Xmx256m -Xmn128m -Xss256k -XX:SurvivorRatio=8 -XX:+UseConcMarkSweepGC
|
||||
ports:
|
||||
- name: seller8889
|
||||
containerPort: 8889
|
||||
volumeMounts:
|
||||
- mountPath: /application.yml
|
||||
name: application-yml
|
||||
subPath: application.yml
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- configMap:
|
||||
name: api-config
|
||||
name: application-yml
|
||||
|
||||
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: manager-api
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: manager-api-service
|
||||
app.kubernetes.io/instance: manager-api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
lilishop.service: manager-api
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
lilishop.service: manager-api
|
||||
spec:
|
||||
containers:
|
||||
- image: 192.168.0.108:31320/manager-api:4.2.4.1
|
||||
name: manager-api
|
||||
env:
|
||||
- name: TZ
|
||||
value: Asia/Shanghai
|
||||
- name: JAVA_OPTS
|
||||
value: -XX:MetaspaceSize=64m -XX:MaxMetaspaceSize=128m -Xms128m -Xmx256m -Xmn128m -Xss256k -XX:SurvivorRatio=8 -XX:+UseConcMarkSweepGC
|
||||
ports:
|
||||
- name: manager8887
|
||||
containerPort: 8887
|
||||
volumeMounts:
|
||||
- mountPath: /application.yml
|
||||
name: application-yml
|
||||
subPath: application.yml
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- configMap:
|
||||
name: api-config
|
||||
name: application-yml
|
||||
|
||||
|
||||
---
|
||||
apiVersion: apps/v1
|
||||
kind: Deployment
|
||||
metadata:
|
||||
name: consumer
|
||||
namespace: lilishop-service
|
||||
labels:
|
||||
app.kubernetes.io/name: consumer-service
|
||||
app.kubernetes.io/instance: buyer-api
|
||||
app.kubernetes.io/version: "4.2.4.1"
|
||||
app.kubernetes.io/component: api
|
||||
app.kubernetes.io/part-of: lilishop
|
||||
tier: "api-service"
|
||||
spec:
|
||||
replicas: 1
|
||||
selector:
|
||||
matchLabels:
|
||||
lilishop.service: consumer
|
||||
template:
|
||||
metadata:
|
||||
labels:
|
||||
lilishop.service: consumer
|
||||
spec:
|
||||
containers:
|
||||
- image: 192.168.0.108:31320/consumer:4.2.4.1
|
||||
name: consumer
|
||||
env:
|
||||
- name: TZ
|
||||
value: Asia/Shanghai
|
||||
- name: JAVA_OPTS
|
||||
value: -XX:MetaspaceSize=64m -XX:MaxMetaspaceSize=128m -Xms128m -Xmx256m -Xmn128m -Xss256k -XX:SurvivorRatio=8 -XX:+UseConcMarkSweepGC
|
||||
volumeMounts:
|
||||
- mountPath: /application.yml
|
||||
name: application-yml
|
||||
subPath: application.yml
|
||||
restartPolicy: Always
|
||||
volumes:
|
||||
- configMap:
|
||||
name: api-config
|
||||
name: application-yml
|
||||
50
docs/diagram/OrderComplaintBuyerController.uml
Normal file
50
docs/diagram/OrderComplaintBuyerController.uml
Normal file
@@ -0,0 +1,50 @@
|
||||
<?xml version="1.0" encoding="UTF-8"?>
|
||||
<Diagram>
|
||||
<ID>JAVA</ID>
|
||||
<OriginalElement>cn.lili.controller.order.OrderComplaintBuyerController</OriginalElement>
|
||||
<nodes>
|
||||
<node x="-377.0" y="-206.0">cn.lili.modules.order.order.service.OrderComplaintCommunicationService</node>
|
||||
<node x="-927.5" y="123.5">cn.lili.controller.order.OrderComplaintStoreController</node>
|
||||
<node x="-378.0" y="607.0">cn.lili.modules.order.order.service.OrderComplaintService</node>
|
||||
<node x="311.5" y="111.0">cn.lili.controller.order.OrderComplaintBuyerController</node>
|
||||
<node x="-308.0" y="123.5">cn.lili.controller.order.OrderComplaintManagerController</node>
|
||||
</nodes>
|
||||
<notes />
|
||||
<edges>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintStoreController" target="cn.lili.modules.order.order.service.OrderComplaintCommunicationService" relationship="TO_ONE">
|
||||
<point x="278.0" y="-84.5" />
|
||||
<point x="-330.0" y="38.5" />
|
||||
</edge>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintStoreController" target="cn.lili.modules.order.order.service.OrderComplaintService" relationship="TO_ONE">
|
||||
<point x="262.0" y="84.5" />
|
||||
<point x="-300.0" y="-119.0" />
|
||||
</edge>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintBuyerController" target="cn.lili.modules.order.order.service.OrderComplaintCommunicationService" relationship="TO_ONE">
|
||||
<point x="-286.0" y="-73.0" />
|
||||
<point x="345.0" y="38.5" />
|
||||
</edge>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintBuyerController" target="cn.lili.modules.order.order.service.OrderComplaintService" relationship="TO_ONE">
|
||||
<point x="0.0" y="73.0" />
|
||||
<point x="606.5" y="726.0" />
|
||||
<point x="307.5" y="0.0" />
|
||||
</edge>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintManagerController" target="cn.lili.modules.order.order.service.OrderComplaintCommunicationService" relationship="TO_ONE">
|
||||
<point x="-11.5" y="-84.5" />
|
||||
<point x="0.0" y="38.5" />
|
||||
</edge>
|
||||
<edge source="cn.lili.controller.order.OrderComplaintManagerController" target="cn.lili.modules.order.order.service.OrderComplaintService" relationship="TO_ONE">
|
||||
<point x="-57.5" y="84.5" />
|
||||
<point x="0.0" y="-119.0" />
|
||||
</edge>
|
||||
</edges>
|
||||
<settings layout="Hierarchic" zoom="1.0" showDependencies="true" x="-13.0" y="319.65625" />
|
||||
<SelectedNodes />
|
||||
<Categories>
|
||||
<Category>Inner Classes</Category>
|
||||
<Category>Methods</Category>
|
||||
<Category>Properties</Category>
|
||||
</Categories>
|
||||
<SCOPE>All</SCOPE>
|
||||
<VISIBILITY>private</VISIBILITY>
|
||||
</Diagram>
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user