@kmkf-fe-packages/services-components 2.0.12-beta.26 → 2.0.12-beta.28

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.
@@ -799,9 +799,11 @@ var GoodHeaderMap = {
799
799
  saleAmount: {
800
800
  name: "总金额",
801
801
  transformValue: function transformValue(val, record, parentName) {
802
+ if (!record) return '--';
802
803
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
803
804
  },
804
805
  renderExport: function renderExport(val, record, parentName) {
806
+ if (!record) return '--';
805
807
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
806
808
  }
807
809
  },
@@ -893,9 +895,11 @@ var GoodHeaderMap = {
893
895
  saleAmount: {
894
896
  name: "总金额",
895
897
  transformValue: function transformValue(val, record, parentName) {
898
+ if (!record) return '--';
896
899
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
897
900
  },
898
901
  renderExport: function renderExport(val, record, parentName) {
902
+ if (!record) return '--';
899
903
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
900
904
  }
901
905
  },
@@ -946,9 +950,11 @@ var GoodHeaderMap = {
946
950
  saleAmount: {
947
951
  name: "总金额",
948
952
  transformValue: function transformValue(val, record, parentName) {
953
+ if (!record) return '--';
949
954
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
950
955
  },
951
956
  renderExport: function renderExport(val, record, parentName) {
957
+ if (!record) return '--';
952
958
  return (record["".concat(parentName, "_qty")] || 0) * (+record["".concat(parentName, "_salePrice")] || 0);
953
959
  }
954
960
  },
@@ -1,6 +1,7 @@
1
1
  import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../../type";
2
2
  import React from "react";
3
3
  import CommonHeaderGoods from "../../CommonHeaderGood";
4
+ import { type FormInstance } from "antd";
4
5
  declare type ConfigType = {
5
6
  goodsKey: string;
6
7
  validator: any;
@@ -20,6 +21,7 @@ declare class Exchange implements ComponentInterface {
20
21
  dataType: ComponentInterface["dataType"];
21
22
  returnGoods: CommonHeaderGoods;
22
23
  config: ConfigType;
24
+ form?: FormInstance;
23
25
  constructor(options: PickOption);
24
26
  renderClient: (record: any) => React.JSX.Element | null;
25
27
  renderPc: () => null;
@@ -32,7 +32,7 @@ var CONF_MAP = {
32
32
  validator: function validator(_rule, value) {
33
33
  if (!_rule.required) return Promise.resolve();
34
34
  var goodsName = "";
35
- if (((value === null || value === void 0 ? void 0 : value.jstReissueGoods) || []).some(function (goods) {
35
+ if (((value === null || value === void 0 ? void 0 : value.jstExchangeGoods) || []).some(function (goods) {
36
36
  var qty = toNum(goods === null || goods === void 0 ? void 0 : goods.qty);
37
37
  var res = typeof qty === "number" ? qty < 1 : true;
38
38
  if (res) {
@@ -42,7 +42,7 @@ var CONF_MAP = {
42
42
  })) {
43
43
  return Promise.reject("".concat(goodsName, "\u6570\u91CF\u5FC5\u987B\u5927\u4E8E0"));
44
44
  }
45
- if (((value === null || value === void 0 ? void 0 : value.jstReissueGoods) || []).some(function (goods) {
45
+ if (((value === null || value === void 0 ? void 0 : value.jstExchangeGoods) || []).some(function (goods) {
46
46
  var v = toNum(goods === null || goods === void 0 ? void 0 : goods.salePrice);
47
47
  var res = typeof v === "number" ? v < 0 : true;
48
48
  if (res) {
@@ -58,6 +58,7 @@ var CONF_MAP = {
58
58
  };
59
59
  var Exchange = /*#__PURE__*/_createClass(function Exchange(options) {
60
60
  var _this = this,
61
+ _options$effects,
61
62
  _this$componentConfig6,
62
63
  _this$componentConfig8;
63
64
  _classCallCheck(this, Exchange);
@@ -75,6 +76,7 @@ var Exchange = /*#__PURE__*/_createClass(function Exchange(options) {
75
76
  _defineProperty(this, "dataType", void 0);
76
77
  _defineProperty(this, "returnGoods", void 0);
77
78
  _defineProperty(this, "config", void 0);
79
+ _defineProperty(this, "form", void 0);
78
80
  _defineProperty(this, "renderClient", function (record) {
79
81
  var _this$componentConfig;
80
82
  var exchangeGoods = JSON.parse((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(_this.config.goodsKey)]) || "[]");
@@ -121,7 +123,8 @@ var Exchange = /*#__PURE__*/_createClass(function Exchange(options) {
121
123
  shopList: ((_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : _this$effects2.shopList) || [],
122
124
  companyKey: (_this$effects3 = _this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.companyKey,
123
125
  width: "90%",
124
- type: _this.type
126
+ type: _this.type,
127
+ form: _this.form
125
128
  }))
126
129
  });
127
130
  });
@@ -143,6 +146,7 @@ var Exchange = /*#__PURE__*/_createClass(function Exchange(options) {
143
146
  this.effects = options === null || options === void 0 ? void 0 : options.effects;
144
147
  this.isCombinationComponent = true;
145
148
  this.canSort = false;
149
+ this.form = (_options$effects = options.effects) === null || _options$effects === void 0 ? void 0 : _options$effects.form;
146
150
  this.returnGoods = new CommonHeaderGoods(_objectSpread(_objectSpread({}, options), {}, {
147
151
  id: "".concat(options.id, "_").concat(this.config.goodsKey),
148
152
  name: "商品信息"
@@ -1,3 +1,3 @@
1
1
  import { ReissueLogistics, JstItemSelect, JstSupply, JstSendGood, BasicInput, BasicAddress, BasicCascader, BasicCheckbox, BasicDataTime, BasicSelect, BasicRadio, BasicTextArea, BasicPicture, 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, WlnGoods, BsPosting, MsgStatus, NodeInput, FlowWorkOrderStatus, WdtGoods, WdtReturn, WdtExchange, CommonInput, PaymentVoucherCode, Label, WdtReissue, GyReissue, AfterSalesOrderId, BsE3Goods, PublicGoods, PublicReissueGoods, PublicExchange, GyGoods, BsE3Reissue, MemberLevel } from "./index";
2
2
  import { PickOption } from "./type";
3
- export declare const factory: (type: string, options: PickOption) => GyReissue | JstSendGood | Label | MsgStatus | PublicExchange | PublicReissueGoods | BasicSelect | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicRadio | BasicTextArea | BasicPicture | 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 | ReissueLogistics | JstItemSelect | JstSupply | BsSystemOrder | BsGoods | BsE3Goods | PublicGoods | BsE3Reissue | BsExchange | BsReissue | BsReturn | BsLogistics | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | CommonInput | PaymentVoucherCode | MemberLevel | AfterSalesOrderId | GyGoods;
3
+ export declare const factory: (type: string, options: PickOption) => GyReissue | JstSendGood | Label | MsgStatus | BasicSelect | BasicInput | BasicAddress | BasicCascader | BasicCheckbox | BasicDataTime | BasicRadio | BasicTextArea | BasicPicture | 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 | ReissueLogistics | JstItemSelect | JstSupply | BsSystemOrder | BsGoods | BsE3Goods | PublicGoods | PublicReissueGoods | PublicExchange | BsE3Reissue | BsExchange | BsReissue | BsReturn | BsLogistics | FlowStatusSelect | FlowMarkSelect | FlowTag | TemplateSelect | WorkOrderId | LogisticsInterception | LogisticsMoreInterception | LogisticsTrajectory | LogisticsMoreTrajectory | PlatForm | ShopInput | Submitter | PrevSubmitter | FlowCreator | Handler | CompletedUser | FlowWorkOrderId | StatusSelect | Calculation | CommonSystemOrder | CommonMultiStatus | NodeDeadLine | HandlerDeadLine | NodeStayDuration | WlnGoods | BsPosting | NodeInput | FlowWorkOrderStatus | WdtGoods | WdtReissue | WdtReturn | WdtExchange | CommonInput | PaymentVoucherCode | MemberLevel | AfterSalesOrderId | GyGoods;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kmkf-fe-packages/services-components",
3
- "version": "2.0.12-beta.26",
3
+ "version": "2.0.12-beta.28",
4
4
  "module": "dist/esm/index.js",
5
5
  "typings": "dist/esm/index.d.ts",
6
6
  "files": [
@@ -21,7 +21,7 @@
21
21
  ]
22
22
  },
23
23
  "dependencies": {
24
- "@kmkf-fe-packages/basic-components": "2.0.12-beta.26",
24
+ "@kmkf-fe-packages/basic-components": "2.0.12-beta.27",
25
25
  "@kmkf-fe-packages/kmkf-utils": "2.0.12-beta.26",
26
26
  "b64-to-blob": "^1.2.19",
27
27
  "html2canvas": "^1.4.1",
@@ -41,7 +41,7 @@
41
41
  "publishConfig": {
42
42
  "access": "public"
43
43
  },
44
- "gitHead": "e0d62016bb50d3e35fccad3b6f0d74cd09e01d32",
44
+ "gitHead": "05296c3b9f995f98274dbf96bda1b9265899c62f",
45
45
  "gitHooks": {
46
46
  "pre-commit": "lint-staged"
47
47
  }