@kmkf-fe-packages/services-components 2.10.13 → 2.10.14
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/esm/Hooks/useColumnsConfig.d.ts +1 -1
- package/dist/esm/commonComponents/GlobalContext/hook/dist/useGetHasErpData.js +49 -0
- package/dist/esm/commonComponents/GlobalContext/orderQuery/dist/useGetErpAddressData.js +180 -0
- package/dist/esm/commonComponents/GlobalContext/orderQuery/dist/useGetErpLogisticsCompany.js +186 -0
- package/dist/esm/components/BS/BsGoods/dist/index.js +110 -0
- package/dist/esm/components/Common/dist/index.js +1017 -0
- package/dist/esm/components/CommonHeaderGood/index.js +38 -34
- package/dist/esm/components/PostIng/index.d.ts +1 -1
- package/dist/esm/factory.d.ts +1 -1
- package/package.json +4 -4
|
@@ -20,6 +20,10 @@ import { BsHeaderPic, BsHeaderChild } from "../BS/common";
|
|
|
20
20
|
import ReissueGift from "../BsE3/ReissueGift";
|
|
21
21
|
import { erpColumnsMap } from "@kmkf-fe-packages/basic-components";
|
|
22
22
|
import { getJstColumns, getKmColumns } from "@kmkf-fe-packages/basic-components";
|
|
23
|
+
var isNullNotFalse = function isNullNotFalse(val) {
|
|
24
|
+
if (val === false) return false;
|
|
25
|
+
return isNull(val);
|
|
26
|
+
};
|
|
23
27
|
var orderGoodsHeaderComponentMap = {
|
|
24
28
|
pic: BsHeaderPic
|
|
25
29
|
};
|
|
@@ -1188,19 +1192,19 @@ var GoodHeaderMap = {
|
|
|
1188
1192
|
saleBasePrice: {
|
|
1189
1193
|
name: "原价",
|
|
1190
1194
|
transformValue: function transformValue(price) {
|
|
1191
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1195
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1192
1196
|
},
|
|
1193
1197
|
renderExport: function renderExport(price) {
|
|
1194
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1198
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1195
1199
|
}
|
|
1196
1200
|
},
|
|
1197
1201
|
salePrice: {
|
|
1198
1202
|
name: "单价",
|
|
1199
1203
|
transformValue: function transformValue(price) {
|
|
1200
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1204
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1201
1205
|
},
|
|
1202
1206
|
renderExport: function renderExport(price) {
|
|
1203
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1207
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1204
1208
|
}
|
|
1205
1209
|
},
|
|
1206
1210
|
qty: "数量",
|
|
@@ -1209,12 +1213,12 @@ var GoodHeaderMap = {
|
|
|
1209
1213
|
transformValue: function transformValue(val, record, parentName) {
|
|
1210
1214
|
if (!record) return "--";
|
|
1211
1215
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1212
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1216
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1213
1217
|
},
|
|
1214
1218
|
renderExport: function renderExport(val, record, parentName) {
|
|
1215
1219
|
if (!record) return "--";
|
|
1216
1220
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1217
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1221
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1218
1222
|
}
|
|
1219
1223
|
},
|
|
1220
1224
|
batchId: "批次号",
|
|
@@ -1260,19 +1264,19 @@ var GoodHeaderMap = {
|
|
|
1260
1264
|
saleBasePrice: {
|
|
1261
1265
|
name: "原价",
|
|
1262
1266
|
transformValue: function transformValue(price) {
|
|
1263
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1267
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1264
1268
|
},
|
|
1265
1269
|
renderExport: function renderExport(price) {
|
|
1266
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1270
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1267
1271
|
}
|
|
1268
1272
|
},
|
|
1269
1273
|
salePrice: {
|
|
1270
1274
|
name: "单价",
|
|
1271
1275
|
transformValue: function transformValue(price) {
|
|
1272
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1276
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1273
1277
|
},
|
|
1274
1278
|
renderExport: function renderExport(price) {
|
|
1275
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1279
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1276
1280
|
}
|
|
1277
1281
|
},
|
|
1278
1282
|
qty: "数量",
|
|
@@ -1302,19 +1306,19 @@ var GoodHeaderMap = {
|
|
|
1302
1306
|
saleBasePrice: {
|
|
1303
1307
|
name: "原价",
|
|
1304
1308
|
transformValue: function transformValue(price) {
|
|
1305
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1309
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1306
1310
|
},
|
|
1307
1311
|
renderExport: function renderExport(price) {
|
|
1308
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1312
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1309
1313
|
}
|
|
1310
1314
|
},
|
|
1311
1315
|
salePrice: {
|
|
1312
1316
|
name: "单价",
|
|
1313
1317
|
transformValue: function transformValue(price) {
|
|
1314
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1318
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1315
1319
|
},
|
|
1316
1320
|
renderExport: function renderExport(price) {
|
|
1317
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1321
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1318
1322
|
}
|
|
1319
1323
|
},
|
|
1320
1324
|
qty: "数量",
|
|
@@ -1323,12 +1327,12 @@ var GoodHeaderMap = {
|
|
|
1323
1327
|
transformValue: function transformValue(val, record, parentName) {
|
|
1324
1328
|
if (!record) return "--";
|
|
1325
1329
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1326
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1330
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1327
1331
|
},
|
|
1328
1332
|
renderExport: function renderExport(val, record, parentName) {
|
|
1329
1333
|
if (!record) return "--";
|
|
1330
1334
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1331
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1335
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1332
1336
|
}
|
|
1333
1337
|
},
|
|
1334
1338
|
batchId: "批次号",
|
|
@@ -1359,19 +1363,19 @@ var GoodHeaderMap = {
|
|
|
1359
1363
|
saleBasePrice: {
|
|
1360
1364
|
name: "原价",
|
|
1361
1365
|
transformValue: function transformValue(price) {
|
|
1362
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1366
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1363
1367
|
},
|
|
1364
1368
|
renderExport: function renderExport(price) {
|
|
1365
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1369
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1366
1370
|
}
|
|
1367
1371
|
},
|
|
1368
1372
|
salePrice: {
|
|
1369
1373
|
name: "单价",
|
|
1370
1374
|
transformValue: function transformValue(price) {
|
|
1371
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1375
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1372
1376
|
},
|
|
1373
1377
|
renderExport: function renderExport(price) {
|
|
1374
|
-
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/,
|
|
1378
|
+
return price || price === 0 ? Number(price).toFixed(4).replace(/\.?0+$/, "") : "";
|
|
1375
1379
|
}
|
|
1376
1380
|
},
|
|
1377
1381
|
qty: "数量",
|
|
@@ -1380,12 +1384,12 @@ var GoodHeaderMap = {
|
|
|
1380
1384
|
transformValue: function transformValue(val, record, parentName) {
|
|
1381
1385
|
if (!record) return "--";
|
|
1382
1386
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1383
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1387
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1384
1388
|
},
|
|
1385
1389
|
renderExport: function renderExport(val, record, parentName) {
|
|
1386
1390
|
if (!record) return "--";
|
|
1387
1391
|
var amount = (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
|
|
1388
|
-
return Number(amount).toFixed(4).replace(/\.?0+$/,
|
|
1392
|
+
return Number(amount).toFixed(4).replace(/\.?0+$/, "");
|
|
1389
1393
|
}
|
|
1390
1394
|
},
|
|
1391
1395
|
isGift: {
|
|
@@ -1473,11 +1477,11 @@ var GoodHeaderMap = {
|
|
|
1473
1477
|
name: "赠品类型",
|
|
1474
1478
|
width: 100,
|
|
1475
1479
|
transformValue: function transformValue(val) {
|
|
1476
|
-
if (
|
|
1480
|
+
if (isNullNotFalse(val)) return "--";
|
|
1477
1481
|
return val ? "赠品" : "非赠品";
|
|
1478
1482
|
},
|
|
1479
1483
|
renderExport: function renderExport(val) {
|
|
1480
|
-
if (
|
|
1484
|
+
if (isNullNotFalse(val)) return "--";
|
|
1481
1485
|
return val ? "赠品" : "非赠品";
|
|
1482
1486
|
}
|
|
1483
1487
|
},
|
|
@@ -1485,11 +1489,11 @@ var GoodHeaderMap = {
|
|
|
1485
1489
|
width: 200,
|
|
1486
1490
|
name: "是否组合商品",
|
|
1487
1491
|
transformValue: function transformValue(val) {
|
|
1488
|
-
if (
|
|
1492
|
+
if (isNullNotFalse(val)) return "--";
|
|
1489
1493
|
return val ? "是" : "否";
|
|
1490
1494
|
},
|
|
1491
1495
|
renderExport: function renderExport(val) {
|
|
1492
|
-
if (
|
|
1496
|
+
if (isNullNotFalse(val)) return "--";
|
|
1493
1497
|
return val ? "是" : "否";
|
|
1494
1498
|
}
|
|
1495
1499
|
},
|
|
@@ -1497,11 +1501,11 @@ var GoodHeaderMap = {
|
|
|
1497
1501
|
width: 100,
|
|
1498
1502
|
name: "是否退款",
|
|
1499
1503
|
transformValue: function transformValue(val) {
|
|
1500
|
-
if (
|
|
1504
|
+
if (isNullNotFalse(val)) return "--";
|
|
1501
1505
|
return val ? "是" : "否";
|
|
1502
1506
|
},
|
|
1503
1507
|
renderExport: function renderExport(val) {
|
|
1504
|
-
if (
|
|
1508
|
+
if (isNullNotFalse(val)) return "--";
|
|
1505
1509
|
return val ? "是" : "否";
|
|
1506
1510
|
}
|
|
1507
1511
|
},
|
|
@@ -1587,11 +1591,11 @@ var GoodHeaderMap = {
|
|
|
1587
1591
|
name: "赠品类型",
|
|
1588
1592
|
width: 100,
|
|
1589
1593
|
transformValue: function transformValue(val) {
|
|
1590
|
-
if (
|
|
1594
|
+
if (isNullNotFalse(val)) return "--";
|
|
1591
1595
|
return val ? "赠品" : "非赠品";
|
|
1592
1596
|
},
|
|
1593
1597
|
renderExport: function renderExport(val) {
|
|
1594
|
-
if (
|
|
1598
|
+
if (isNullNotFalse(val)) return "--";
|
|
1595
1599
|
return val ? "赠品" : "非赠品";
|
|
1596
1600
|
}
|
|
1597
1601
|
},
|
|
@@ -1599,11 +1603,11 @@ var GoodHeaderMap = {
|
|
|
1599
1603
|
width: 200,
|
|
1600
1604
|
name: "是否组合商品",
|
|
1601
1605
|
transformValue: function transformValue(val) {
|
|
1602
|
-
if (
|
|
1606
|
+
if (isNullNotFalse(val)) return "--";
|
|
1603
1607
|
return val ? "是" : "否";
|
|
1604
1608
|
},
|
|
1605
1609
|
renderExport: function renderExport(val) {
|
|
1606
|
-
if (
|
|
1610
|
+
if (isNullNotFalse(val)) return "--";
|
|
1607
1611
|
return val ? "是" : "否";
|
|
1608
1612
|
}
|
|
1609
1613
|
},
|
|
@@ -1611,11 +1615,11 @@ var GoodHeaderMap = {
|
|
|
1611
1615
|
width: 100,
|
|
1612
1616
|
name: "是否退款",
|
|
1613
1617
|
transformValue: function transformValue(val) {
|
|
1614
|
-
if (
|
|
1618
|
+
if (isNullNotFalse(val)) return "--";
|
|
1615
1619
|
return val ? "是" : "否";
|
|
1616
1620
|
},
|
|
1617
1621
|
renderExport: function renderExport(val) {
|
|
1618
|
-
if (
|
|
1622
|
+
if (isNullNotFalse(val)) return "--";
|
|
1619
1623
|
return val ? "是" : "否";
|
|
1620
1624
|
}
|
|
1621
1625
|
},
|
|
@@ -31,7 +31,7 @@ declare class BasicPosting implements ComponentInterface {
|
|
|
31
31
|
sortColumns: SortColumnsField;
|
|
32
32
|
headerProvince: boolean;
|
|
33
33
|
constructor(options: PickOption);
|
|
34
|
-
getChildren: () => (
|
|
34
|
+
getChildren: () => (Province | City | District | Detail | ReceiverName | ReceiverMobile | undefined)[];
|
|
35
35
|
getSortColumns: (sortColumns: string | undefined) => SortColumnsField;
|
|
36
36
|
renderPc: (value: any, record: Record) => React.JSX.Element | null;
|
|
37
37
|
renderLog: (r: Record) => React.JSX.Element | null;
|
package/dist/esm/factory.d.ts
CHANGED
|
@@ -1,3 +1,3 @@
|
|
|
1
1
|
import { ReissueLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, BasicPicturePro, BasicMultSelect, BasicGrade, BasicRate, BasicFile, BasicPosting, SubForm, CommonDataTime, TradeId, ShopName, BuyerNick, ReceiverName, ReceiverMobile, ReceiverAddress, TradeDateTime, Logistics, ReturnLogistics, ActualPayment, ERemark, AliPay, ItemSelect, ItemId, ItemEnCode, SystemOrderNo, Ordinary, ThirdItemSelect, FlowStatusSelect, FlowMarkSelect, FlowTag, Payment, TemplateSelect, WorkOrderId, PlatForm, ShopInput, Submitter, PrevSubmitter, FlowCreator, Handler, CompletedUser, LogisticsInterception, LogisticsMoreInterception, LogisticsTrajectory, LogisticsMoreTrajectory, FlowWorkOrderId, BsGoods, BsExchange, BsReissue, BsReturn, BsSystemOrder, BsLogistics, StatusSelect, CommonSystemOrder, CommonMultiStatus, Calculation, NodeDeadLine, HandlerDeadLine, NodeStayDuration, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, GyReissue, AfterSalesOrderId, BsE3Goods, PublicGoods, PublicReissueGoods, PublicExchange, GyGoods, BsE3Reissue, MemberLevel, GyReturn, AsyncSelect, WdtShopSelect, KmVideo, BasicTypeInput, SkxIdInputSelect, SkxGoods, BasicSelectOption, OrderSubForm, FlowOverallStatusSelect, ReturnWarehouse, KmExchange } from "./index";
|
|
2
2
|
import { PickOption } from "./type";
|
|
3
|
-
export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | CommonMultiStatus |
|
|
3
|
+
export declare const factory: (type: string, options: PickOption) => BsLogistics | BsSystemOrder | CommonMultiStatus | JstSendGood | JstSupply | PublicGoods | ReturnWarehouse | ReissueLogistics | BasicInput | BasicTypeInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicSelect | BasicSelectOption | BasicRadio | BasicTextArea | BasicPicture | BasicPicturePro | BasicMultSelect | BasicGrade | BasicRate | BasicFile | BasicPosting | SubForm | CommonDataTime | TradeId | ShopName | BuyerNick | ReceiverName | ReceiverMobile | ReceiverAddress | TradeDateTime | Logistics | ReturnLogistics | ActualPayment | ERemark | AliPay | ItemSelect | ItemId | ItemEnCode | SystemOrderNo | Ordinary | ThirdItemSelect | Payment | JstItemSelect | BsGoods | BsE3Goods | PublicReissueGoods | PublicExchange | BsE3Reissue | BsExchange | BsReissue | BsReturn | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | NodeDeadLine | HandlerDeadLine | NodeStayDuration | BsPosting | NodeInput | FlowWorkOrderStatus | MsgStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | WdtShopSelect | KmVideo | CommonInput | PaymentVoucherCode | Label | MemberLevel | AfterSalesOrderId | GyGoods | KmExchange | GyReissue | GyReturn | AsyncSelect | SkxIdInputSelect | SkxGoods | OrderSubForm | FlowOverallStatusSelect;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@kmkf-fe-packages/services-components",
|
|
3
|
-
"version": "2.10.
|
|
3
|
+
"version": "2.10.14",
|
|
4
4
|
"module": "dist/esm/index.js",
|
|
5
5
|
"typings": "dist/esm/index.d.ts",
|
|
6
6
|
"files": [
|
|
@@ -21,8 +21,8 @@
|
|
|
21
21
|
]
|
|
22
22
|
},
|
|
23
23
|
"dependencies": {
|
|
24
|
-
"@kmkf-fe-packages/basic-components": "2.10.
|
|
25
|
-
"@kmkf-fe-packages/kmkf-utils": "2.10.
|
|
24
|
+
"@kmkf-fe-packages/basic-components": "2.10.14",
|
|
25
|
+
"@kmkf-fe-packages/kmkf-utils": "2.10.14",
|
|
26
26
|
"b64-to-blob": "^1.2.19",
|
|
27
27
|
"html2canvas": "^1.4.1",
|
|
28
28
|
"react-pdf-js": "^5.1.0"
|
|
@@ -41,7 +41,7 @@
|
|
|
41
41
|
"publishConfig": {
|
|
42
42
|
"access": "public"
|
|
43
43
|
},
|
|
44
|
-
"gitHead": "
|
|
44
|
+
"gitHead": "f39208196a64c8def6860f31bf3895b1f96ee765",
|
|
45
45
|
"gitHooks": {
|
|
46
46
|
"pre-commit": "lint-staged"
|
|
47
47
|
}
|