@kmkf-fe-packages/basic-components 0.7.15-alpha.49 → 0.7.15-alpha.50

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
@@ -7183,6 +7183,9 @@ var Province = function Province(props) {
7183
7183
  }, []);
7184
7184
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement(Cascader, _objectSpread2(_objectSpread2({}, props), {}, {
7185
7185
  options: option,
7186
+ style: {
7187
+ minWidth: '100px'
7188
+ },
7186
7189
  placeholder: "\u8BF7\u9009\u62E9\u7701\u5E02\u533A"
7187
7190
  })));
7188
7191
  };
@@ -9624,26 +9627,43 @@ var ItemList = function ItemList(props) {
9624
9627
  };
9625
9628
 
9626
9629
  var columns = [{
9627
- dataIndex: '',
9630
+ dataIndex: 'index',
9628
9631
  title: '序号',
9632
+ // with: 70,
9633
+ ellipsis: true,
9629
9634
  render: function render(val, record, index) {
9630
9635
  return /*#__PURE__*/React.createElement("span", null, index + 1);
9631
9636
  }
9632
9637
  }, {
9633
9638
  dataIndex: 'name',
9634
- title: '商品名称'
9639
+ title: '商品名称',
9640
+ with: 200,
9641
+ ellipsis: true
9635
9642
  }, {
9636
9643
  dataIndex: 'goodsId',
9637
- title: '商品id'
9644
+ title: '商品id',
9645
+ with: 200,
9646
+ ellipsis: true
9638
9647
  }, {
9639
9648
  dataIndex: 'skuName',
9640
- title: '商品sku名称'
9649
+ title: '商品sku名称',
9650
+ with: 200,
9651
+ ellipsis: true
9641
9652
  }, {
9642
9653
  dataIndex: 'code',
9643
- title: '商品编码'
9654
+ title: '商品编码',
9655
+ with: 200,
9656
+ ellipsis: true
9644
9657
  }, {
9645
9658
  dataIndex: 'skuCode',
9646
- title: '商品sku编码'
9659
+ title: '商品sku编码',
9660
+ with: 200,
9661
+ ellipsis: true
9662
+ }, {
9663
+ dataIndex: 'marketPrice',
9664
+ title: '市场价',
9665
+ with: 200,
9666
+ ellipsis: true
9647
9667
  }];
9648
9668
  var GoodsModal$1 = function GoodsModal(props, ref) {
9649
9669
  useImperativeHandle(ref, function () {
@@ -9729,7 +9749,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9729
9749
  _context.prev = 0;
9730
9750
  setLoading(true);
9731
9751
  params = {
9732
- shopCode: shopCode || 'DP015'
9752
+ shopCode: shopCode
9733
9753
  };
9734
9754
  _context.next = 5;
9735
9755
  return extendRequest('/qy/gdfw/product/bsListProduct', {
@@ -9766,6 +9786,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9766
9786
  }, [shopId]);
9767
9787
  var rowSelection = {
9768
9788
  selectedRowKeys: selectIds,
9789
+ fixed: true,
9769
9790
  onChange: function onChange(selectedRowKeys, selectedRows, info) {
9770
9791
  console.log(selectedRowKeys, selectedRows, info);
9771
9792
  setSelectIds(selectedRowKeys);
@@ -9840,7 +9861,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9840
9861
  rowKey: 'skuCode',
9841
9862
  dataSource: goodList,
9842
9863
  scroll: {
9843
- x: '100%',
9864
+ x: true,
9844
9865
  y: 300
9845
9866
  },
9846
9867
  pagination: {
@@ -10014,14 +10035,15 @@ var GoodItem = function GoodItem(props) {
10014
10035
  var goodsId = item.goodsId,
10015
10036
  name = item.name,
10016
10037
  code = item.code,
10017
- skuCode = item.skuCode;
10038
+ skuCode = item.skuCode,
10039
+ marketPrice = item.marketPrice;
10018
10040
  return {
10019
10041
  id: goodsId,
10020
10042
  pic: '',
10021
10043
  name: name,
10022
10044
  code: code,
10023
10045
  sku: skuCode,
10024
- money: '',
10046
+ money: marketPrice || 0,
10025
10047
  share: '',
10026
10048
  number: 1,
10027
10049
  type: '',
@@ -10279,6 +10301,12 @@ var BsExchange = function BsExchange(props) {
10279
10301
  };
10280
10302
  var changeHandle = function changeHandle(val, key) {
10281
10303
  var newValue = _objectSpread2({}, value);
10304
+ if (key === 'bsExchangeGiftGoods') {
10305
+ val = cloneDeep(val).map(function (t) {
10306
+ t.money = 0;
10307
+ return t;
10308
+ });
10309
+ }
10282
10310
  newValue[key] = val;
10283
10311
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
10284
10312
  if (key === 'bsExchangeType') {
@@ -10343,7 +10371,7 @@ var BsExchange = function BsExchange(props) {
10343
10371
  })) : /*#__PURE__*/React.createElement(React.Fragment, null, ((value === null || value === void 0 ? void 0 : value.bsExchangeReturnGoods) || []).map(function (item, index) {
10344
10372
  return /*#__PURE__*/React.createElement("div", {
10345
10373
  style: {
10346
- border: '1px dashed #eee',
10374
+ border: '1px dashed',
10347
10375
  marginBottom: '8px'
10348
10376
  }
10349
10377
  }, /*#__PURE__*/React.createElement("div", null, "\u9000\u56DE\u5546\u54C1"), /*#__PURE__*/React.createElement(GoodItem, _objectSpread2(_objectSpread2({
@@ -10371,7 +10399,8 @@ var BsExchange = function BsExchange(props) {
10371
10399
  })), ['3', '4'].includes(value === null || value === void 0 ? void 0 : (_value$bsExchangeType6 = value.bsExchangeType) === null || _value$bsExchangeType6 === void 0 ? void 0 : _value$bsExchangeType6[0]) ? /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", null, "\u8D60\u54C1\u4FE1\u606F"), /*#__PURE__*/React.createElement(GoodItem, _objectSpread2(_objectSpread2({
10372
10400
  headerText: "\u8D60\u54C1",
10373
10401
  key: 'bsGiftGoods',
10374
- disabled: disabled
10402
+ disabled: disabled,
10403
+ shopCode: value === null || value === void 0 ? void 0 : value.shopCode
10375
10404
  }, other), {}, {
10376
10405
  value: value === null || value === void 0 ? void 0 : value.bsExchangeGiftGoods,
10377
10406
  onChange: function onChange(val) {
@@ -10411,8 +10440,8 @@ var BsReissue = function BsReissue(props) {
10411
10440
  newValue[key] = val;
10412
10441
  if (key === 'bsReissueType') {
10413
10442
  newValue.bsReissueGoods = [];
10414
- onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, newValue));
10415
10443
  }
10444
+ onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, newValue));
10416
10445
  if (key === 'bsReissueType') {
10417
10446
  pubsub.publish('reissueType', val[0]);
10418
10447
  pubsub.subscribe('reissueSelectList', function (_, data) {
package/dist/index.js CHANGED
@@ -7194,6 +7194,9 @@ var Province = function Province(props) {
7194
7194
  }, []);
7195
7195
  return /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement(antd.Cascader, _objectSpread2(_objectSpread2({}, props), {}, {
7196
7196
  options: option,
7197
+ style: {
7198
+ minWidth: '100px'
7199
+ },
7197
7200
  placeholder: "\u8BF7\u9009\u62E9\u7701\u5E02\u533A"
7198
7201
  })));
7199
7202
  };
@@ -9635,26 +9638,43 @@ var ItemList = function ItemList(props) {
9635
9638
  };
9636
9639
 
9637
9640
  var columns = [{
9638
- dataIndex: '',
9641
+ dataIndex: 'index',
9639
9642
  title: '序号',
9643
+ // with: 70,
9644
+ ellipsis: true,
9640
9645
  render: function render(val, record, index) {
9641
9646
  return /*#__PURE__*/React__default['default'].createElement("span", null, index + 1);
9642
9647
  }
9643
9648
  }, {
9644
9649
  dataIndex: 'name',
9645
- title: '商品名称'
9650
+ title: '商品名称',
9651
+ with: 200,
9652
+ ellipsis: true
9646
9653
  }, {
9647
9654
  dataIndex: 'goodsId',
9648
- title: '商品id'
9655
+ title: '商品id',
9656
+ with: 200,
9657
+ ellipsis: true
9649
9658
  }, {
9650
9659
  dataIndex: 'skuName',
9651
- title: '商品sku名称'
9660
+ title: '商品sku名称',
9661
+ with: 200,
9662
+ ellipsis: true
9652
9663
  }, {
9653
9664
  dataIndex: 'code',
9654
- title: '商品编码'
9665
+ title: '商品编码',
9666
+ with: 200,
9667
+ ellipsis: true
9655
9668
  }, {
9656
9669
  dataIndex: 'skuCode',
9657
- title: '商品sku编码'
9670
+ title: '商品sku编码',
9671
+ with: 200,
9672
+ ellipsis: true
9673
+ }, {
9674
+ dataIndex: 'marketPrice',
9675
+ title: '市场价',
9676
+ with: 200,
9677
+ ellipsis: true
9658
9678
  }];
9659
9679
  var GoodsModal$1 = function GoodsModal(props, ref) {
9660
9680
  React.useImperativeHandle(ref, function () {
@@ -9740,7 +9760,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9740
9760
  _context.prev = 0;
9741
9761
  setLoading(true);
9742
9762
  params = {
9743
- shopCode: shopCode || 'DP015'
9763
+ shopCode: shopCode
9744
9764
  };
9745
9765
  _context.next = 5;
9746
9766
  return extendRequest('/qy/gdfw/product/bsListProduct', {
@@ -9777,6 +9797,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9777
9797
  }, [shopId]);
9778
9798
  var rowSelection = {
9779
9799
  selectedRowKeys: selectIds,
9800
+ fixed: true,
9780
9801
  onChange: function onChange(selectedRowKeys, selectedRows, info) {
9781
9802
  console.log(selectedRowKeys, selectedRows, info);
9782
9803
  setSelectIds(selectedRowKeys);
@@ -9851,7 +9872,7 @@ var GoodsModal$1 = function GoodsModal(props, ref) {
9851
9872
  rowKey: 'skuCode',
9852
9873
  dataSource: goodList,
9853
9874
  scroll: {
9854
- x: '100%',
9875
+ x: true,
9855
9876
  y: 300
9856
9877
  },
9857
9878
  pagination: {
@@ -10025,14 +10046,15 @@ var GoodItem = function GoodItem(props) {
10025
10046
  var goodsId = item.goodsId,
10026
10047
  name = item.name,
10027
10048
  code = item.code,
10028
- skuCode = item.skuCode;
10049
+ skuCode = item.skuCode,
10050
+ marketPrice = item.marketPrice;
10029
10051
  return {
10030
10052
  id: goodsId,
10031
10053
  pic: '',
10032
10054
  name: name,
10033
10055
  code: code,
10034
10056
  sku: skuCode,
10035
- money: '',
10057
+ money: marketPrice || 0,
10036
10058
  share: '',
10037
10059
  number: 1,
10038
10060
  type: '',
@@ -10290,6 +10312,12 @@ var BsExchange = function BsExchange(props) {
10290
10312
  };
10291
10313
  var changeHandle = function changeHandle(val, key) {
10292
10314
  var newValue = _objectSpread2({}, value);
10315
+ if (key === 'bsExchangeGiftGoods') {
10316
+ val = lodash.cloneDeep(val).map(function (t) {
10317
+ t.money = 0;
10318
+ return t;
10319
+ });
10320
+ }
10293
10321
  newValue[key] = val;
10294
10322
  onChange === null || onChange === void 0 ? void 0 : onChange(newValue);
10295
10323
  if (key === 'bsExchangeType') {
@@ -10354,7 +10382,7 @@ var BsExchange = function BsExchange(props) {
10354
10382
  })) : /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, ((value === null || value === void 0 ? void 0 : value.bsExchangeReturnGoods) || []).map(function (item, index) {
10355
10383
  return /*#__PURE__*/React__default['default'].createElement("div", {
10356
10384
  style: {
10357
- border: '1px dashed #eee',
10385
+ border: '1px dashed',
10358
10386
  marginBottom: '8px'
10359
10387
  }
10360
10388
  }, /*#__PURE__*/React__default['default'].createElement("div", null, "\u9000\u56DE\u5546\u54C1"), /*#__PURE__*/React__default['default'].createElement(GoodItem, _objectSpread2(_objectSpread2({
@@ -10382,7 +10410,8 @@ var BsExchange = function BsExchange(props) {
10382
10410
  })), ['3', '4'].includes(value === null || value === void 0 ? void 0 : (_value$bsExchangeType6 = value.bsExchangeType) === null || _value$bsExchangeType6 === void 0 ? void 0 : _value$bsExchangeType6[0]) ? /*#__PURE__*/React__default['default'].createElement(React__default['default'].Fragment, null, /*#__PURE__*/React__default['default'].createElement("div", null, "\u8D60\u54C1\u4FE1\u606F"), /*#__PURE__*/React__default['default'].createElement(GoodItem, _objectSpread2(_objectSpread2({
10383
10411
  headerText: "\u8D60\u54C1",
10384
10412
  key: 'bsGiftGoods',
10385
- disabled: disabled
10413
+ disabled: disabled,
10414
+ shopCode: value === null || value === void 0 ? void 0 : value.shopCode
10386
10415
  }, other), {}, {
10387
10416
  value: value === null || value === void 0 ? void 0 : value.bsExchangeGiftGoods,
10388
10417
  onChange: function onChange(val) {
@@ -10422,8 +10451,8 @@ var BsReissue = function BsReissue(props) {
10422
10451
  newValue[key] = val;
10423
10452
  if (key === 'bsReissueType') {
10424
10453
  newValue.bsReissueGoods = [];
10425
- onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, newValue));
10426
10454
  }
10455
+ onChange === null || onChange === void 0 ? void 0 : onChange(_objectSpread2({}, newValue));
10427
10456
  if (key === 'bsReissueType') {
10428
10457
  pubsub__default['default'].publish('reissueType', val[0]);
10429
10458
  pubsub__default['default'].subscribe('reissueSelectList', function (_, data) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/basic-components",
3
- "version": "0.7.15-alpha.49",
3
+ "version": "0.7.15-alpha.50",
4
4
  "description": "> TODO: description",
5
5
  "homepage": "",
6
6
  "license": "ISC",
@@ -20,7 +20,7 @@
20
20
  "watch": "nodemon --ignore dist/ --ignore node_modules/ --watch src/ -C -e ts,tsx,less --debug -x 'yarn async'"
21
21
  },
22
22
  "dependencies": {
23
- "@kmkf-fe-packages/kmkf-utils": "^0.7.15-alpha.49",
23
+ "@kmkf-fe-packages/kmkf-utils": "^0.7.15-alpha.50",
24
24
  "lodash": "^4.17.21",
25
25
  "pubsub-js": "^1.9.4",
26
26
  "umi-request": "^1.4.0"
@@ -58,5 +58,5 @@
58
58
  "publishConfig": {
59
59
  "access": "public"
60
60
  },
61
- "gitHead": "83a1112fe9ef93e93431e2c4ae163b9b4e5bc0c8"
61
+ "gitHead": "e2bde9f9f75f470cdeeebb9731976a09360fbeef"
62
62
  }