@kmkf-fe-packages/basic-components 0.8.21-alpha.1 → 0.8.21-alpha.3

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/index.esm.js CHANGED
@@ -6854,6 +6854,7 @@ hooks.HTML5_FMT = {
6854
6854
  };
6855
6855
 
6856
6856
  var _excluded$7 = ["maxCount", "maxSize", "onChange", "value", "accept", "disabled", "uniqueKey", "hostUrl", "actionUrl"];
6857
+ // import { getInfo } from 'react-mediainfo';
6857
6858
  var Dragger = Upload.Dragger;
6858
6859
  var fn$2 = function fn() {
6859
6860
  return void 0;
@@ -6986,6 +6987,9 @@ var ApaasUploadAsync$1 = function ApaasUploadAsync(_ref) {
6986
6987
  // 手动上传模式, 一直返回false
6987
6988
  var beforeUpload = function beforeUpload(file) {
6988
6989
  console.log('beforeUpload', file);
6990
+ // getInfo(file).then((res: any) => {
6991
+ // console.log(res);
6992
+ // });
6989
6993
  var size = file.size / 1024 / 1024 < maxSize;
6990
6994
  if (value.length >= maxCount) {
6991
6995
  message.error("\u6700\u591A\u6DFB\u52A0".concat(maxCount, "\u4E2A\u6587\u4EF6\uFF01"));
@@ -7445,7 +7449,7 @@ var IdentifyAddress = function IdentifyAddress(props) {
7445
7449
  receiverMobile: val === null || val === void 0 ? void 0 : val.phone,
7446
7450
  address: []
7447
7451
  };
7448
- if (val === null || val === void 0 ? void 0 : val.province) {
7452
+ if ((val === null || val === void 0 ? void 0 : val.province) && AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
7449
7453
  params.address = [AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.province), AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.city), AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.district)];
7450
7454
  }
7451
7455
  onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, params));
@@ -9415,7 +9419,8 @@ var LogisticsInterception = function LogisticsInterception(props) {
9415
9419
  interceptReceiverName: undefined,
9416
9420
  interceptReceiverMobile: undefined,
9417
9421
  interceptLogisticsStatus: undefined,
9418
- interceptLogisticsStatusOther: undefined
9422
+ interceptLogisticsStatusOther: undefined,
9423
+ interceptLogisticsSnapshot: undefined
9419
9424
  });
9420
9425
  }
9421
9426
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
@@ -10710,12 +10715,14 @@ var BsExchange = function BsExchange(props) {
10710
10715
  }, []);
10711
10716
  var getListHandle = function getListHandle(list, val) {
10712
10717
  var _val$bsExchangeType, _val$bsExchangeType2;
10718
+ //固定的sku
10719
+ var FIXED_FIELD = ['Q0000002', '600123001', '10103003', 'Q0000003', 'Q0000004'];
10713
10720
  //如果是原单换
10714
10721
  if (['1', '3'].includes(val === null || val === void 0 ? void 0 : (_val$bsExchangeType = val.bsExchangeType) === null || _val$bsExchangeType === void 0 ? void 0 : _val$bsExchangeType[0])) {
10715
10722
  return list.reduce(function (prv, next) {
10716
10723
  next.canDelete = false;
10717
10724
  //数量大于1 拆开
10718
- if (next.number > 1) {
10725
+ if (next.number > 1 && !FIXED_FIELD.includes(next.sku)) {
10719
10726
  var newList = Array(next.number).fill({}).map(function () {
10720
10727
  var newNext = _objectSpread2({}, next);
10721
10728
  newNext.money = newNext.share;
@@ -10735,7 +10742,7 @@ var BsExchange = function BsExchange(props) {
10735
10742
  next.canDelete = true;
10736
10743
  next.index = index;
10737
10744
  //数量大于1 拆开
10738
- if (next.number > 1) {
10745
+ if (next.number > 1 && !FIXED_FIELD.includes(next.sku)) {
10739
10746
  var newList = Array(next.number).fill({}).map(function () {
10740
10747
  var newNext = _objectSpread2({}, next);
10741
10748
  newNext.money = newNext.share;
package/dist/index.js CHANGED
@@ -6865,6 +6865,7 @@ hooks.HTML5_FMT = {
6865
6865
  };
6866
6866
 
6867
6867
  var _excluded$7 = ["maxCount", "maxSize", "onChange", "value", "accept", "disabled", "uniqueKey", "hostUrl", "actionUrl"];
6868
+ // import { getInfo } from 'react-mediainfo';
6868
6869
  var Dragger = antd.Upload.Dragger;
6869
6870
  var fn$2 = function fn() {
6870
6871
  return void 0;
@@ -6997,6 +6998,9 @@ var ApaasUploadAsync$1 = function ApaasUploadAsync(_ref) {
6997
6998
  // 手动上传模式, 一直返回false
6998
6999
  var beforeUpload = function beforeUpload(file) {
6999
7000
  console.log('beforeUpload', file);
7001
+ // getInfo(file).then((res: any) => {
7002
+ // console.log(res);
7003
+ // });
7000
7004
  var size = file.size / 1024 / 1024 < maxSize;
7001
7005
  if (value.length >= maxCount) {
7002
7006
  antd.message.error("\u6700\u591A\u6DFB\u52A0".concat(maxCount, "\u4E2A\u6587\u4EF6\uFF01"));
@@ -7456,7 +7460,7 @@ var IdentifyAddress = function IdentifyAddress(props) {
7456
7460
  receiverMobile: val === null || val === void 0 ? void 0 : val.phone,
7457
7461
  address: []
7458
7462
  };
7459
- if (val === null || val === void 0 ? void 0 : val.province) {
7463
+ if ((val === null || val === void 0 ? void 0 : val.province) && kmkfUtils.AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.province)) {
7460
7464
  params.address = [kmkfUtils.AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.province), kmkfUtils.AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.city), kmkfUtils.AddressData.getInstance().getProCodeByName(val === null || val === void 0 ? void 0 : val.district)];
7461
7465
  }
7462
7466
  onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, params));
@@ -9426,7 +9430,8 @@ var LogisticsInterception = function LogisticsInterception(props) {
9426
9430
  interceptReceiverName: undefined,
9427
9431
  interceptReceiverMobile: undefined,
9428
9432
  interceptLogisticsStatus: undefined,
9429
- interceptLogisticsStatusOther: undefined
9433
+ interceptLogisticsStatusOther: undefined,
9434
+ interceptLogisticsSnapshot: undefined
9430
9435
  });
9431
9436
  }
9432
9437
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
@@ -10721,12 +10726,14 @@ var BsExchange = function BsExchange(props) {
10721
10726
  }, []);
10722
10727
  var getListHandle = function getListHandle(list, val) {
10723
10728
  var _val$bsExchangeType, _val$bsExchangeType2;
10729
+ //固定的sku
10730
+ var FIXED_FIELD = ['Q0000002', '600123001', '10103003', 'Q0000003', 'Q0000004'];
10724
10731
  //如果是原单换
10725
10732
  if (['1', '3'].includes(val === null || val === void 0 ? void 0 : (_val$bsExchangeType = val.bsExchangeType) === null || _val$bsExchangeType === void 0 ? void 0 : _val$bsExchangeType[0])) {
10726
10733
  return list.reduce(function (prv, next) {
10727
10734
  next.canDelete = false;
10728
10735
  //数量大于1 拆开
10729
- if (next.number > 1) {
10736
+ if (next.number > 1 && !FIXED_FIELD.includes(next.sku)) {
10730
10737
  var newList = Array(next.number).fill({}).map(function () {
10731
10738
  var newNext = _objectSpread2({}, next);
10732
10739
  newNext.money = newNext.share;
@@ -10746,7 +10753,7 @@ var BsExchange = function BsExchange(props) {
10746
10753
  next.canDelete = true;
10747
10754
  next.index = index;
10748
10755
  //数量大于1 拆开
10749
- if (next.number > 1) {
10756
+ if (next.number > 1 && !FIXED_FIELD.includes(next.sku)) {
10750
10757
  var newList = Array(next.number).fill({}).map(function () {
10751
10758
  var newNext = _objectSpread2({}, next);
10752
10759
  newNext.money = newNext.share;
@@ -10,6 +10,7 @@ interface LogisticsInterceptionValueType {
10
10
  interceptReceiverMobile: string;
11
11
  interceptLogisticsStatus: string | number;
12
12
  interceptLogisticsStatusOther: string;
13
+ interceptLogisticsSnapshot: string;
13
14
  }
14
15
  interface LogisticsInterceptionProps {
15
16
  value: Partial<LogisticsInterceptionValueType>;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/basic-components",
3
- "version": "0.8.21-alpha.1",
3
+ "version": "0.8.21-alpha.3",
4
4
  "description": "> TODO: description",
5
5
  "homepage": "",
6
6
  "license": "ISC",
@@ -24,6 +24,7 @@
24
24
  "lodash": "^4.17.21",
25
25
  "pubsub-js": "^1.9.4",
26
26
  "react-copy-to-clipboard": "^5.1.0",
27
+ "react-mediainfo": "^0.0.42",
27
28
  "umi-request": "^1.4.0"
28
29
  },
29
30
  "devDependencies": {
@@ -60,5 +61,5 @@
60
61
  "publishConfig": {
61
62
  "access": "public"
62
63
  },
63
- "gitHead": "1f85f4ce9472dc2958c5b43d45ac9a0cf219e83e"
64
+ "gitHead": "eac22eddf099294739d285729a552e44daf58558"
64
65
  }