@kmkf-fe-packages/services-components 0.13.0-alpha.2 → 0.13.0-alpha.20

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.
Files changed (56) hide show
  1. package/dist/esm/commonComponents/OperationLog/index.js +6 -1
  2. package/dist/esm/components/Address/index.d.ts +6 -6
  3. package/dist/esm/components/Address/index.js +32 -26
  4. package/dist/esm/components/BS/BsExchange/index.js +5 -5
  5. package/dist/esm/components/BS/BsPosting/components/City/index.d.ts +29 -0
  6. package/dist/esm/components/BS/BsPosting/components/City/index.js +76 -0
  7. package/dist/esm/components/BS/BsPosting/components/Detail/index.d.ts +27 -0
  8. package/dist/esm/components/BS/BsPosting/components/Detail/index.js +70 -0
  9. package/dist/esm/components/BS/BsPosting/components/District/index.d.ts +29 -0
  10. package/dist/esm/components/BS/BsPosting/components/District/index.js +76 -0
  11. package/dist/esm/components/BS/BsPosting/components/Province/index.d.ts +29 -0
  12. package/dist/esm/components/BS/BsPosting/components/Province/index.js +76 -0
  13. package/dist/esm/components/BS/BsPosting/components/ReceiverMobile/index.d.ts +27 -0
  14. package/dist/esm/components/BS/BsPosting/components/ReceiverMobile/index.js +70 -0
  15. package/dist/esm/components/BS/BsPosting/components/ReceiverName/index.d.ts +27 -0
  16. package/dist/esm/components/BS/BsPosting/components/ReceiverName/index.js +70 -0
  17. package/dist/esm/components/BS/BsPosting/index.d.ts +43 -0
  18. package/dist/esm/components/BS/BsPosting/index.js +106 -0
  19. package/dist/esm/components/BS/BsReissue/index.js +3 -3
  20. package/dist/esm/components/BS/BsReturn/index.js +3 -3
  21. package/dist/esm/components/BS/BsSystemOrder/index.js +6 -3
  22. package/dist/esm/components/Cascader/index.d.ts +1 -1
  23. package/dist/esm/components/Cascader/index.js +2 -2
  24. package/dist/esm/components/Checkbox/index.d.ts +1 -1
  25. package/dist/esm/components/Checkbox/index.js +2 -2
  26. package/dist/esm/components/Common/img/reject.png +0 -0
  27. package/dist/esm/components/Common/img/reminder.png +0 -0
  28. package/dist/esm/components/Common/index.js +6 -1
  29. package/dist/esm/components/CommonDataTime/index.d.ts +1 -1
  30. package/dist/esm/components/CommonDataTime/index.js +2 -2
  31. package/dist/esm/components/DataTime/index.d.ts +1 -1
  32. package/dist/esm/components/DataTime/index.js +2 -2
  33. package/dist/esm/components/FlowCreator/index.d.ts +39 -0
  34. package/dist/esm/components/FlowCreator/index.js +87 -0
  35. package/dist/esm/components/FlowTag/index.js +18 -6
  36. package/dist/esm/components/GetFormItem/index.d.ts +1 -1
  37. package/dist/esm/components/GetFormItem/index.js +4 -2
  38. package/dist/esm/components/Input/index.d.ts +6 -4
  39. package/dist/esm/components/Input/index.js +66 -9
  40. package/dist/esm/components/PrevSubmitter/index.d.ts +39 -0
  41. package/dist/esm/components/PrevSubmitter/index.js +87 -0
  42. package/dist/esm/components/Radio/index.d.ts +5 -5
  43. package/dist/esm/components/Radio/index.js +13 -13
  44. package/dist/esm/components/ReceiverAddress/index.d.ts +5 -5
  45. package/dist/esm/components/ReceiverAddress/index.js +27 -19
  46. package/dist/esm/components/Submitter/index.js +1 -1
  47. package/dist/esm/factory.d.ts +2 -2
  48. package/dist/esm/factory.js +6 -2
  49. package/dist/esm/index.d.ts +3 -0
  50. package/dist/esm/index.js +3 -0
  51. package/dist/esm/service/api.d.ts +1 -0
  52. package/dist/esm/service/api.js +9 -0
  53. package/dist/esm/service/request.d.ts +17 -0
  54. package/dist/esm/service/request.js +56 -0
  55. package/dist/esm/type.d.ts +16 -14
  56. package/package.json +4 -4
@@ -0,0 +1,87 @@
1
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
+ function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
3
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
4
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
7
+ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
8
+ import React from "react";
9
+ import { filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
10
+ import { SYMBOL } from "../../constant";
11
+ var FlowCreator = /*#__PURE__*/_createClass(function FlowCreator(options) {
12
+ var _this = this,
13
+ _this$effects3;
14
+ _classCallCheck(this, FlowCreator);
15
+ _defineProperty(this, "name", void 0);
16
+ _defineProperty(this, "id", void 0);
17
+ _defineProperty(this, "sortField", void 0);
18
+ _defineProperty(this, "type", void 0);
19
+ _defineProperty(this, "componentConfig", void 0);
20
+ _defineProperty(this, "effects", void 0);
21
+ _defineProperty(this, "isCombinationComponent", void 0);
22
+ _defineProperty(this, "formField", void 0);
23
+ _defineProperty(this, "canSort", void 0);
24
+ _defineProperty(this, "children", void 0);
25
+ _defineProperty(this, "dataType", void 0);
26
+ _defineProperty(this, "options", void 0);
27
+ _defineProperty(this, "renderPc", function (value, record) {
28
+ var _record;
29
+ return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) !== null && _record !== void 0 ? _record : "--");
30
+ });
31
+ _defineProperty(this, "renderLog", function () {
32
+ return null;
33
+ });
34
+ _defineProperty(this, "getComponentValue", function (r) {
35
+ return r === null || r === void 0 ? void 0 : r[_this.id];
36
+ });
37
+ _defineProperty(this, "renderExport", function (value, record) {
38
+ var _record2;
39
+ return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) !== null && _record2 !== void 0 ? _record2 : "--";
40
+ });
41
+ _defineProperty(this, "renderClient", function () {
42
+ return null;
43
+ });
44
+ _defineProperty(this, "editRender", function () {
45
+ return null;
46
+ });
47
+ _defineProperty(this, "filterConfig", function (item) {
48
+ var _this$effects;
49
+ return {
50
+ searchDefaultConditions: SYMBOL.in,
51
+ type: item.type,
52
+ id: item.id,
53
+ // 过滤组件id
54
+ name: item.name,
55
+ // 过滤组件名称
56
+ filterComponentType: "MultipleSelect",
57
+ props: {
58
+ options: (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.userList
59
+ },
60
+ formatFilterValue: function formatFilterValue(val) {
61
+ return val === null || val === void 0 ? void 0 : val.map(function (v) {
62
+ var _this$effects2, _this$effects2$userLi, _this$effects2$userLi2;
63
+ return (_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : (_this$effects2$userLi = _this$effects2.userList) === null || _this$effects2$userLi === void 0 ? void 0 : (_this$effects2$userLi2 = _this$effects2$userLi.find(function (u) {
64
+ return u.value === v;
65
+ })) === null || _this$effects2$userLi2 === void 0 ? void 0 : _this$effects2$userLi2.label;
66
+ });
67
+ },
68
+ filterFn: function filterFn(value) {
69
+ return function (i) {
70
+ return value === null || value === void 0 ? void 0 : value.includes(_filterFn.filterTableListItemColumnValue(i, item.id, ""));
71
+ };
72
+ }
73
+ };
74
+ });
75
+ this.name = options.name || "流程创建人";
76
+ this.id = (options === null || options === void 0 ? void 0 : options.id) || "flowCreator";
77
+ this.type = "FLOW_CREATOR_INPUT";
78
+ this.sortField = "flowCreator";
79
+ this.formField = "flowCreator";
80
+ this.effects = options === null || options === void 0 ? void 0 : options.effects;
81
+ this.isCombinationComponent = false;
82
+ this.canSort = true;
83
+ this.children = [];
84
+ this.dataType = "string";
85
+ this.options = ((_this$effects3 = this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.userList) || [];
86
+ });
87
+ export default FlowCreator;
@@ -14,13 +14,25 @@ import { ApaasSelect } from "@kmkf-fe-packages/basic-components";
14
14
  import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
15
15
  import GetFormItem from "../GetFormItem";
16
16
  import { SYMBOL } from "../../constant";
17
+ import reject from "../Common/img/reject.png";
18
+ import reminder from "../Common/img/reminder.png";
17
19
  var TAG_MAP = {
18
20
  REMINDER: "催单",
19
21
  REJECT: "驳回"
20
22
  };
21
23
  var TAG_ICON_MAP = {
22
- REMINDER: "催单",
23
- REJECT: "驳回"
24
+ REMINDER: /*#__PURE__*/React.createElement("img", {
25
+ src: reminder,
26
+ style: {
27
+ width: "16px"
28
+ }
29
+ }),
30
+ REJECT: /*#__PURE__*/React.createElement("img", {
31
+ src: reject,
32
+ style: {
33
+ width: "16px"
34
+ }
35
+ })
24
36
  };
25
37
  var FlowTag = /*#__PURE__*/_createClass(function FlowTag(options) {
26
38
  var _this = this;
@@ -99,7 +111,7 @@ var FlowTag = /*#__PURE__*/_createClass(function FlowTag(options) {
99
111
  label: "催单",
100
112
  value: "REMINDER"
101
113
  }, {
102
- label: "暂存",
114
+ label: "驳回",
103
115
  value: "REJECT"
104
116
  }]
105
117
  },
@@ -111,9 +123,9 @@ var FlowTag = /*#__PURE__*/_createClass(function FlowTag(options) {
111
123
  };
112
124
  });
113
125
  this.name = "标签";
114
- this.id = (options === null || options === void 0 ? void 0 : options.id) || "markFlag";
115
- this.sortField = "markFlag";
116
- this.formField = "markFlag";
126
+ this.id = (options === null || options === void 0 ? void 0 : options.id) || "flowTags";
127
+ this.sortField = "flowTags";
128
+ this.formField = "flowTags";
117
129
  this.type = "FLOW_TAG";
118
130
  this.effects = options.effects;
119
131
  this.rules = [];
@@ -9,5 +9,5 @@ declare type GetFormItemProps = {
9
9
  style?: CSSProperties | undefined;
10
10
  [prop: string]: any;
11
11
  };
12
- declare const GetFormItem: ({ rules, required, title, component, name, hidden, style, }: GetFormItemProps) => React.JSX.Element | null;
12
+ declare const GetFormItem: ({ rules, required, title, component, name, hidden, style, validateTrigger }: GetFormItemProps) => React.JSX.Element | null;
13
13
  export default GetFormItem;
@@ -14,7 +14,8 @@ var GetFormItem = function GetFormItem(_ref) {
14
14
  name = _ref.name,
15
15
  _ref$hidden = _ref.hidden,
16
16
  hidden = _ref$hidden === void 0 ? false : _ref$hidden,
17
- style = _ref.style;
17
+ style = _ref.style,
18
+ validateTrigger = _ref.validateTrigger;
18
19
  var newRules = rules;
19
20
  if (required) {
20
21
  newRules = rules.concat({
@@ -33,7 +34,8 @@ var GetFormItem = function GetFormItem(_ref) {
33
34
  name: name,
34
35
  label: title,
35
36
  rules: newRules,
36
- className: "form-item-label--index"
37
+ className: "form-item-label--index",
38
+ validateTrigger: validateTrigger
37
39
  // hidden={hidden}
38
40
  }, component));
39
41
  };
@@ -1,17 +1,19 @@
1
- import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../type";
2
- import React from "react";
1
+ import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../type';
2
+ import React from 'react';
3
3
  declare class BasicInput implements ComponentInterface {
4
4
  name: string;
5
5
  id: string;
6
6
  sortField: string;
7
7
  type: string;
8
8
  rules: any[];
9
- componentConfig: ComponentInterface["componentConfig"];
9
+ componentConfig: ComponentInterface['componentConfig'];
10
10
  isCombinationComponent: boolean;
11
11
  formField: string;
12
12
  canSort: boolean;
13
13
  children: ComponentInterface[];
14
- dataType: ComponentInterface["dataType"];
14
+ dataType: ComponentInterface['dataType'];
15
+ templateId?: string;
16
+ workOrderUniqueKey?: string;
15
17
  constructor(options: PickOption);
16
18
  renderPc: (value: any, record: Record) => React.JSX.Element;
17
19
  renderLog: (r: Record) => React.JSX.Element | null;
@@ -1,4 +1,7 @@
1
1
  function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
+ function _regeneratorRuntime() { "use strict"; /*! regenerator-runtime -- Copyright (c) 2014-present, Facebook, Inc. -- license (MIT): https://github.com/facebook/regenerator/blob/main/LICENSE */ _regeneratorRuntime = function _regeneratorRuntime() { return exports; }; var exports = {}, Op = Object.prototype, hasOwn = Op.hasOwnProperty, defineProperty = Object.defineProperty || function (obj, key, desc) { obj[key] = desc.value; }, $Symbol = "function" == typeof Symbol ? Symbol : {}, iteratorSymbol = $Symbol.iterator || "@@iterator", asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator", toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag"; function define(obj, key, value) { return Object.defineProperty(obj, key, { value: value, enumerable: !0, configurable: !0, writable: !0 }), obj[key]; } try { define({}, ""); } catch (err) { define = function define(obj, key, value) { return obj[key] = value; }; } function wrap(innerFn, outerFn, self, tryLocsList) { var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator, generator = Object.create(protoGenerator.prototype), context = new Context(tryLocsList || []); return defineProperty(generator, "_invoke", { value: makeInvokeMethod(innerFn, self, context) }), generator; } function tryCatch(fn, obj, arg) { try { return { type: "normal", arg: fn.call(obj, arg) }; } catch (err) { return { type: "throw", arg: err }; } } exports.wrap = wrap; var ContinueSentinel = {}; function Generator() {} function GeneratorFunction() {} function GeneratorFunctionPrototype() {} var IteratorPrototype = {}; define(IteratorPrototype, iteratorSymbol, function () { return this; }); var getProto = Object.getPrototypeOf, NativeIteratorPrototype = getProto && getProto(getProto(values([]))); NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype); var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype); function defineIteratorMethods(prototype) { ["next", "throw", "return"].forEach(function (method) { define(prototype, method, function (arg) { return this._invoke(method, arg); }); }); } function AsyncIterator(generator, PromiseImpl) { function invoke(method, arg, resolve, reject) { var record = tryCatch(generator[method], generator, arg); if ("throw" !== record.type) { var result = record.arg, value = result.value; return value && "object" == _typeof(value) && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) { invoke("next", value, resolve, reject); }, function (err) { invoke("throw", err, resolve, reject); }) : PromiseImpl.resolve(value).then(function (unwrapped) { result.value = unwrapped, resolve(result); }, function (error) { return invoke("throw", error, resolve, reject); }); } reject(record.arg); } var previousPromise; defineProperty(this, "_invoke", { value: function value(method, arg) { function callInvokeWithMethodAndArg() { return new PromiseImpl(function (resolve, reject) { invoke(method, arg, resolve, reject); }); } return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg(); } }); } function makeInvokeMethod(innerFn, self, context) { var state = "suspendedStart"; return function (method, arg) { if ("executing" === state) throw new Error("Generator is already running"); if ("completed" === state) { if ("throw" === method) throw arg; return doneResult(); } for (context.method = method, context.arg = arg;;) { var delegate = context.delegate; if (delegate) { var delegateResult = maybeInvokeDelegate(delegate, context); if (delegateResult) { if (delegateResult === ContinueSentinel) continue; return delegateResult; } } if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) { if ("suspendedStart" === state) throw state = "completed", context.arg; context.dispatchException(context.arg); } else "return" === context.method && context.abrupt("return", context.arg); state = "executing"; var record = tryCatch(innerFn, self, context); if ("normal" === record.type) { if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue; return { value: record.arg, done: context.done }; } "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg); } }; } function maybeInvokeDelegate(delegate, context) { var methodName = context.method, method = delegate.iterator[methodName]; if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel; var record = tryCatch(method, delegate.iterator, context.arg); if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel; var info = record.arg; return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel); } function pushTryEntry(locs) { var entry = { tryLoc: locs[0] }; 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry); } function resetTryEntry(entry) { var record = entry.completion || {}; record.type = "normal", delete record.arg, entry.completion = record; } function Context(tryLocsList) { this.tryEntries = [{ tryLoc: "root" }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0); } function values(iterable) { if (iterable) { var iteratorMethod = iterable[iteratorSymbol]; if (iteratorMethod) return iteratorMethod.call(iterable); if ("function" == typeof iterable.next) return iterable; if (!isNaN(iterable.length)) { var i = -1, next = function next() { for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next; return next.value = undefined, next.done = !0, next; }; return next.next = next; } } return { next: doneResult }; } function doneResult() { return { value: undefined, done: !0 }; } return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", { value: GeneratorFunctionPrototype, configurable: !0 }), defineProperty(GeneratorFunctionPrototype, "constructor", { value: GeneratorFunction, configurable: !0 }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) { var ctor = "function" == typeof genFun && genFun.constructor; return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name)); }, exports.mark = function (genFun) { return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun; }, exports.awrap = function (arg) { return { __await: arg }; }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () { return this; }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) { void 0 === PromiseImpl && (PromiseImpl = Promise); var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl); return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) { return result.done ? result.value : iter.next(); }); }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () { return this; }), define(Gp, "toString", function () { return "[object Generator]"; }), exports.keys = function (val) { var object = Object(val), keys = []; for (var key in object) keys.push(key); return keys.reverse(), function next() { for (; keys.length;) { var key = keys.pop(); if (key in object) return next.value = key, next.done = !1, next; } return next.done = !0, next; }; }, exports.values = values, Context.prototype = { constructor: Context, reset: function reset(skipTempReset) { if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined); }, stop: function stop() { this.done = !0; var rootRecord = this.tryEntries[0].completion; if ("throw" === rootRecord.type) throw rootRecord.arg; return this.rval; }, dispatchException: function dispatchException(exception) { if (this.done) throw exception; var context = this; function handle(loc, caught) { return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught; } for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i], record = entry.completion; if ("root" === entry.tryLoc) return handle("end"); if (entry.tryLoc <= this.prev) { var hasCatch = hasOwn.call(entry, "catchLoc"), hasFinally = hasOwn.call(entry, "finallyLoc"); if (hasCatch && hasFinally) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } else if (hasCatch) { if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0); } else { if (!hasFinally) throw new Error("try statement without catch or finally"); if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc); } } } }, abrupt: function abrupt(type, arg) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) { var finallyEntry = entry; break; } } finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null); var record = finallyEntry ? finallyEntry.completion : {}; return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record); }, complete: function complete(record, afterLoc) { if ("throw" === record.type) throw record.arg; return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel; }, finish: function finish(finallyLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel; } }, catch: function _catch(tryLoc) { for (var i = this.tryEntries.length - 1; i >= 0; --i) { var entry = this.tryEntries[i]; if (entry.tryLoc === tryLoc) { var record = entry.completion; if ("throw" === record.type) { var thrown = record.arg; resetTryEntry(entry); } return thrown; } } throw new Error("illegal catch attempt"); }, delegateYield: function delegateYield(iterable, resultName, nextLoc) { return this.delegate = { iterator: values(iterable), resultName: resultName, nextLoc: nextLoc }, "next" === this.method && (this.arg = undefined), ContinueSentinel; } }, exports; }
3
+ function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) { try { var info = gen[key](arg); var value = info.value; } catch (error) { reject(error); return; } if (info.done) { resolve(value); } else { Promise.resolve(value).then(_next, _throw); } }
4
+ function _asyncToGenerator(fn) { return function () { var self = this, args = arguments; return new Promise(function (resolve, reject) { var gen = fn.apply(self, args); function _next(value) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "next", value); } function _throw(err) { asyncGeneratorStep(gen, resolve, reject, _next, _throw, "throw", err); } _next(undefined); }); }; }
2
5
  function _extends() { _extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return _extends.apply(this, arguments); }
3
6
  function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
4
7
  function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
@@ -6,12 +9,13 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
6
9
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
7
10
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
8
11
  function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
9
- import React from "react";
10
- import { ApaasInput } from "@kmkf-fe-packages/basic-components";
12
+ import React from 'react';
13
+ import { ApaasInput } from '@kmkf-fe-packages/basic-components';
11
14
  import GetFormItem from "../GetFormItem";
12
15
  import ItemView from "../../commonComponents/ItemView";
13
- import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
16
+ import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
14
17
  import { SYMBOL } from "../../constant";
18
+ import { replaceCheck } from "../../service/api";
15
19
  var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
16
20
  var _this = this,
17
21
  _options$componentCon;
@@ -27,9 +31,11 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
27
31
  _defineProperty(this, "canSort", void 0);
28
32
  _defineProperty(this, "children", void 0);
29
33
  _defineProperty(this, "dataType", void 0);
34
+ _defineProperty(this, "templateId", void 0);
35
+ _defineProperty(this, "workOrderUniqueKey", void 0);
30
36
  _defineProperty(this, "renderPc", function (value, record) {
31
37
  var _record;
32
- return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record !== void 0 ? _record : "--");
38
+ return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record !== void 0 ? _record : '--');
33
39
  });
34
40
  _defineProperty(this, "renderLog", function (r) {
35
41
  if (isNull(r === null || r === void 0 ? void 0 : r["".concat(_this.id, "_input")])) return null;
@@ -40,7 +46,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
40
46
  });
41
47
  _defineProperty(this, "renderExport", function (value, record) {
42
48
  var _record2;
43
- return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record2 !== void 0 ? _record2 : "--";
49
+ return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_input")]) !== null && _record2 !== void 0 ? _record2 : '--';
44
50
  });
45
51
  _defineProperty(this, "renderClient", function (record) {
46
52
  return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
@@ -56,6 +62,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
56
62
  name: _this.id,
57
63
  rules: _this.rules,
58
64
  hidden: p === null || p === void 0 ? void 0 : p.hidden,
65
+ validateTrigger: ['onBlur', 'onChange'],
59
66
  required: (_this$componentConfig = (_this$componentConfig2 = _this.componentConfig) === null || _this$componentConfig2 === void 0 ? void 0 : _this$componentConfig2.required) !== null && _this$componentConfig !== void 0 ? _this$componentConfig : false,
60
67
  component: /*#__PURE__*/React.createElement(ApaasInput, _extends({}, _this.componentConfig, {
61
68
  placeholder: "\u8BF7\u8F93\u5165".concat(_this.name)
@@ -70,10 +77,10 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
70
77
  // 过滤组件id
71
78
  name: item.name,
72
79
  // 过滤组件名称
73
- filterComponentType: "Input",
80
+ filterComponentType: 'Input',
74
81
  filterFn: function filterFn(value) {
75
82
  return function (i) {
76
- return "".concat(_filterFn.filterTableListItemColumnValue(i, item.id, "input")).includes(value);
83
+ return "".concat(_filterFn.filterTableListItemColumnValue(i, item.id, 'input')).includes(value);
77
84
  };
78
85
  }
79
86
  };
@@ -83,7 +90,9 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
83
90
  this.sortField = "".concat(options.id, "_input");
84
91
  this.formField = "".concat(options.id, "_input");
85
92
  this.type = options.type;
93
+ this.templateId = options.templateId;
86
94
  this.componentConfig = options.componentConfig;
95
+ this.workOrderUniqueKey = options === null || options === void 0 ? void 0 : options.workOrderUniqueKey;
87
96
  this.rules = [{
88
97
  validator: function validator(_, value) {
89
98
  var _this$componentConfig3, _this$componentConfig4, _this$componentConfig5, _this$componentConfig6, _this$componentConfig7;
@@ -101,7 +110,7 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
101
110
  return item.test(value);
102
111
  });
103
112
  if (testList.length && !isTest) {
104
- return Promise.reject(new Error("请填写正确的格式"));
113
+ return Promise.reject(new Error('请填写正确的格式'));
105
114
  }
106
115
  if ((_this$componentConfig6 = _this.componentConfig) !== null && _this$componentConfig6 !== void 0 && (_this$componentConfig7 = _this$componentConfig6.rulesOptions) !== null && _this$componentConfig7 !== void 0 && _this$componentConfig7.length) {
107
116
  var _this$componentConfig8;
@@ -126,10 +135,58 @@ var BasicInput = /*#__PURE__*/_createClass(function BasicInput(options) {
126
135
  }
127
136
  return Promise.resolve();
128
137
  }
138
+ }, {
139
+ validateTrigger: 'onBlur',
140
+ validator: function () {
141
+ var _validator = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(_, value) {
142
+ var _this$componentConfig10;
143
+ var _resultList$, params, _yield$replaceCheck, resultList;
144
+ return _regeneratorRuntime().wrap(function _callee$(_context) {
145
+ while (1) switch (_context.prev = _context.next) {
146
+ case 0:
147
+ if (value) {
148
+ _context.next = 2;
149
+ break;
150
+ }
151
+ return _context.abrupt("return", Promise.resolve());
152
+ case 2:
153
+ if (!((_this$componentConfig10 = _this.componentConfig) !== null && _this$componentConfig10 !== void 0 && _this$componentConfig10.replaceWarn)) {
154
+ _context.next = 10;
155
+ break;
156
+ }
157
+ params = {
158
+ templateId: _this.templateId,
159
+ workOrderUniqueKey: _this.workOrderUniqueKey,
160
+ needCheckComponentList: [{
161
+ componentKey: _this.formField,
162
+ componentValue: String(value)
163
+ }]
164
+ };
165
+ _context.next = 6;
166
+ return replaceCheck(params);
167
+ case 6:
168
+ _yield$replaceCheck = _context.sent;
169
+ resultList = _yield$replaceCheck.data.resultList;
170
+ if (!((resultList === null || resultList === void 0 ? void 0 : (_resultList$ = resultList[0]) === null || _resultList$ === void 0 ? void 0 : _resultList$.repeatCount) > 0)) {
171
+ _context.next = 10;
172
+ break;
173
+ }
174
+ return _context.abrupt("return", Promise.reject(new Error('内容已存在,不能重复提交')));
175
+ case 10:
176
+ case "end":
177
+ return _context.stop();
178
+ }
179
+ }, _callee);
180
+ }));
181
+ function validator(_x, _x2) {
182
+ return _validator.apply(this, arguments);
183
+ }
184
+ return validator;
185
+ }()
129
186
  }];
130
187
  this.isCombinationComponent = false;
131
188
  this.canSort = true;
132
189
  this.children = [];
133
- this.dataType = options !== null && options !== void 0 && (_options$componentCon = options.componentConfig) !== null && _options$componentCon !== void 0 && _options$componentCon.isNumber ? "number" : "string";
190
+ this.dataType = options !== null && options !== void 0 && (_options$componentCon = options.componentConfig) !== null && _options$componentCon !== void 0 && _options$componentCon.isNumber ? 'number' : 'string';
134
191
  });
135
192
  export default BasicInput;
@@ -0,0 +1,39 @@
1
+ import React from "react";
2
+ import { ComponentInterface, ColumnConfig, Record, PickOption } from "../../type";
3
+ declare class PrevSubmitter implements ComponentInterface {
4
+ name: string;
5
+ id: string;
6
+ sortField: string;
7
+ type: string;
8
+ componentConfig: ComponentInterface["componentConfig"];
9
+ effects: ComponentInterface["effects"];
10
+ isCombinationComponent: boolean;
11
+ formField: string;
12
+ canSort: boolean;
13
+ children: ComponentInterface[];
14
+ dataType: ComponentInterface["dataType"];
15
+ options: ComponentInterface["options"];
16
+ constructor(options: PickOption);
17
+ renderPc: (value: unknown, record: Record) => React.JSX.Element;
18
+ renderLog: () => null;
19
+ getComponentValue: (r: Record) => any;
20
+ renderExport: (value: any, record: Record) => any;
21
+ renderClient: () => null;
22
+ editRender: () => null;
23
+ filterConfig: (item: ColumnConfig) => {
24
+ searchDefaultConditions: "in";
25
+ type: string;
26
+ id: string;
27
+ name: string;
28
+ filterComponentType: "MultipleSelect";
29
+ props: {
30
+ options: {
31
+ label: string;
32
+ value: string;
33
+ }[] | undefined;
34
+ };
35
+ formatFilterValue: (val: Array<string>) => (string | undefined)[];
36
+ filterFn: (value: string) => (i: Record) => boolean;
37
+ };
38
+ }
39
+ export default PrevSubmitter;
@@ -0,0 +1,87 @@
1
+ function _typeof(obj) { "@babel/helpers - typeof"; return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function (obj) { return typeof obj; } : function (obj) { return obj && "function" == typeof Symbol && obj.constructor === Symbol && obj !== Symbol.prototype ? "symbol" : typeof obj; }, _typeof(obj); }
2
+ function _defineProperties(target, props) { for (var i = 0; i < props.length; i++) { var descriptor = props[i]; descriptor.enumerable = descriptor.enumerable || false; descriptor.configurable = true; if ("value" in descriptor) descriptor.writable = true; Object.defineProperty(target, _toPropertyKey(descriptor.key), descriptor); } }
3
+ function _createClass(Constructor, protoProps, staticProps) { if (protoProps) _defineProperties(Constructor.prototype, protoProps); if (staticProps) _defineProperties(Constructor, staticProps); Object.defineProperty(Constructor, "prototype", { writable: false }); return Constructor; }
4
+ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Constructor)) { throw new TypeError("Cannot call a class as a function"); } }
5
+ function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
6
+ function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
7
+ function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
8
+ import React from "react";
9
+ import { filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
10
+ import { SYMBOL } from "../../constant";
11
+ var PrevSubmitter = /*#__PURE__*/_createClass(function PrevSubmitter(options) {
12
+ var _this = this,
13
+ _this$effects3;
14
+ _classCallCheck(this, PrevSubmitter);
15
+ _defineProperty(this, "name", void 0);
16
+ _defineProperty(this, "id", void 0);
17
+ _defineProperty(this, "sortField", void 0);
18
+ _defineProperty(this, "type", void 0);
19
+ _defineProperty(this, "componentConfig", void 0);
20
+ _defineProperty(this, "effects", void 0);
21
+ _defineProperty(this, "isCombinationComponent", void 0);
22
+ _defineProperty(this, "formField", void 0);
23
+ _defineProperty(this, "canSort", void 0);
24
+ _defineProperty(this, "children", void 0);
25
+ _defineProperty(this, "dataType", void 0);
26
+ _defineProperty(this, "options", void 0);
27
+ _defineProperty(this, "renderPc", function (value, record) {
28
+ var _record;
29
+ return /*#__PURE__*/React.createElement("span", null, (_record = record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) !== null && _record !== void 0 ? _record : "--");
30
+ });
31
+ _defineProperty(this, "renderLog", function () {
32
+ return null;
33
+ });
34
+ _defineProperty(this, "getComponentValue", function (r) {
35
+ return r === null || r === void 0 ? void 0 : r[_this.id];
36
+ });
37
+ _defineProperty(this, "renderExport", function (value, record) {
38
+ var _record2;
39
+ return (_record2 = record === null || record === void 0 ? void 0 : record["".concat(_this.id)]) !== null && _record2 !== void 0 ? _record2 : "--";
40
+ });
41
+ _defineProperty(this, "renderClient", function () {
42
+ return null;
43
+ });
44
+ _defineProperty(this, "editRender", function () {
45
+ return null;
46
+ });
47
+ _defineProperty(this, "filterConfig", function (item) {
48
+ var _this$effects;
49
+ return {
50
+ searchDefaultConditions: SYMBOL.in,
51
+ type: item.type,
52
+ id: item.id,
53
+ // 过滤组件id
54
+ name: item.name,
55
+ // 过滤组件名称
56
+ filterComponentType: "MultipleSelect",
57
+ props: {
58
+ options: (_this$effects = _this.effects) === null || _this$effects === void 0 ? void 0 : _this$effects.userList
59
+ },
60
+ formatFilterValue: function formatFilterValue(val) {
61
+ return val === null || val === void 0 ? void 0 : val.map(function (v) {
62
+ var _this$effects2, _this$effects2$userLi, _this$effects2$userLi2;
63
+ return (_this$effects2 = _this.effects) === null || _this$effects2 === void 0 ? void 0 : (_this$effects2$userLi = _this$effects2.userList) === null || _this$effects2$userLi === void 0 ? void 0 : (_this$effects2$userLi2 = _this$effects2$userLi.find(function (u) {
64
+ return u.value === v;
65
+ })) === null || _this$effects2$userLi2 === void 0 ? void 0 : _this$effects2$userLi2.label;
66
+ });
67
+ },
68
+ filterFn: function filterFn(value) {
69
+ return function (i) {
70
+ return value === null || value === void 0 ? void 0 : value.includes(_filterFn.filterTableListItemColumnValue(i, item.id, ""));
71
+ };
72
+ }
73
+ };
74
+ });
75
+ this.name = options.name || "流程创建人";
76
+ this.id = (options === null || options === void 0 ? void 0 : options.id) || "prevSubmitter";
77
+ this.type = "PREV_SUBMITTER_INPUT";
78
+ this.sortField = "prevSubmitter";
79
+ this.formField = "prevSubmitter";
80
+ this.effects = options === null || options === void 0 ? void 0 : options.effects;
81
+ this.isCombinationComponent = false;
82
+ this.canSort = true;
83
+ this.children = [];
84
+ this.dataType = "string";
85
+ this.options = ((_this$effects3 = this.effects) === null || _this$effects3 === void 0 ? void 0 : _this$effects3.userList) || [];
86
+ });
87
+ export default PrevSubmitter;
@@ -1,5 +1,5 @@
1
- import { ComponentInterface, PickOption, ColumnConfig, Record } from '../../type';
2
- import React from 'react';
1
+ import { ComponentInterface, PickOption, ColumnConfig, Record } from "../../type";
2
+ import React from "react";
3
3
  declare type Value = {
4
4
  value?: string;
5
5
  other?: string;
@@ -10,13 +10,13 @@ declare class BasicRadio implements ComponentInterface {
10
10
  sortField: string;
11
11
  type: string;
12
12
  rules: any[];
13
- componentConfig: ComponentInterface['componentConfig'];
13
+ componentConfig: ComponentInterface["componentConfig"];
14
14
  isCombinationComponent: boolean;
15
15
  formField: string;
16
16
  canSort: boolean;
17
17
  children: ComponentInterface[];
18
- dataType: ComponentInterface['dataType'];
19
- options: ComponentInterface['options'];
18
+ dataType: ComponentInterface["dataType"];
19
+ options: ComponentInterface["options"];
20
20
  constructor(options: PickOption);
21
21
  render: (value: Value) => React.JSX.Element;
22
22
  renderPc: (value: any, record: Record) => React.JSX.Element;
@@ -6,15 +6,15 @@ function _classCallCheck(instance, Constructor) { if (!(instance instanceof Cons
6
6
  function _defineProperty(obj, key, value) { key = _toPropertyKey(key); if (key in obj) { Object.defineProperty(obj, key, { value: value, enumerable: true, configurable: true, writable: true }); } else { obj[key] = value; } return obj; }
7
7
  function _toPropertyKey(arg) { var key = _toPrimitive(arg, "string"); return _typeof(key) === "symbol" ? key : String(key); }
8
8
  function _toPrimitive(input, hint) { if (_typeof(input) !== "object" || input === null) return input; var prim = input[Symbol.toPrimitive]; if (prim !== undefined) { var res = prim.call(input, hint || "default"); if (_typeof(res) !== "object") return res; throw new TypeError("@@toPrimitive must return a primitive value."); } return (hint === "string" ? String : Number)(input); }
9
- import React from 'react';
10
- import { ApaasRadio } from '@kmkf-fe-packages/basic-components';
9
+ import React from "react";
10
+ import { ApaasRadio } from "@kmkf-fe-packages/basic-components";
11
11
  import GetFormItem from "../GetFormItem";
12
12
  import ItemView from "../../commonComponents/ItemView";
13
- import { isNull, filterFn as _filterFn } from '@kmkf-fe-packages/kmkf-utils';
14
- import get from 'lodash/get';
13
+ import { isNull, filterFn as _filterFn } from "@kmkf-fe-packages/kmkf-utils";
14
+ import get from "lodash/get";
15
15
  import { SYMBOL } from "../../constant";
16
16
  var typeMap = {
17
- RADIO: 'radio'
17
+ RADIO: "radio"
18
18
  };
19
19
  var BasicRadio = /*#__PURE__*/_createClass(function BasicRadio(options) {
20
20
  var _this = this,
@@ -35,7 +35,7 @@ var BasicRadio = /*#__PURE__*/_createClass(function BasicRadio(options) {
35
35
  _defineProperty(this, "options", void 0);
36
36
  _defineProperty(this, "render", function (value) {
37
37
  var _value$value;
38
- return /*#__PURE__*/React.createElement("span", null, value === null || value === void 0 ? void 0 : value.value, (value === null || value === void 0 ? void 0 : value.value) && typeof value.value === 'string' && (value === null || value === void 0 ? void 0 : (_value$value = value.value) === null || _value$value === void 0 ? void 0 : _value$value.indexOf('其他')) > -1 && (value === null || value === void 0 ? void 0 : value.other) && "(".concat(value === null || value === void 0 ? void 0 : value.other, ")"));
38
+ return /*#__PURE__*/React.createElement("span", null, value === null || value === void 0 ? void 0 : value.value, (value === null || value === void 0 ? void 0 : value.value) && typeof value.value === "string" && (value === null || value === void 0 ? void 0 : (_value$value = value.value) === null || _value$value === void 0 ? void 0 : _value$value.indexOf("其他")) > -1 && (value === null || value === void 0 ? void 0 : value.other) && "(".concat(value === null || value === void 0 ? void 0 : value.other, ")"));
39
39
  });
40
40
  _defineProperty(this, "renderPc", function (value, record) {
41
41
  var type = _this.type;
@@ -59,12 +59,12 @@ var BasicRadio = /*#__PURE__*/_createClass(function BasicRadio(options) {
59
59
  _defineProperty(this, "renderExport", function (value, record) {
60
60
  var type = _this.type;
61
61
  if ((record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type])]) === undefined) {
62
- return '--';
62
+ return "--";
63
63
  }
64
- return "".concat(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type])], " ").concat(get(record, "".concat(_this.id, "_").concat(typeMap[type], "Other"), ''));
64
+ return "".concat(record === null || record === void 0 ? void 0 : record["".concat(_this.id, "_").concat(typeMap[type])], " ").concat(get(record, "".concat(_this.id, "_").concat(typeMap[type], "Other"), ""));
65
65
  });
66
66
  _defineProperty(this, "getKeyByComponentType", function (type) {
67
- return typeMap[type] || '';
67
+ return typeMap[type] || "";
68
68
  });
69
69
  _defineProperty(this, "renderClient", function (record) {
70
70
  return !isNull(record === null || record === void 0 ? void 0 : record[_this.id]) ? /*#__PURE__*/React.createElement(ItemView, {
@@ -96,11 +96,11 @@ var BasicRadio = /*#__PURE__*/_createClass(function BasicRadio(options) {
96
96
  // 过滤组件id
97
97
  name: item.name,
98
98
  // 过滤组件名称
99
- filterComponentType: 'MultipleSelect',
99
+ filterComponentType: "MultipleSelect",
100
100
  props: {
101
101
  options: item !== null && item !== void 0 && (_item$config = item.config) !== null && _item$config !== void 0 && _item$config.showOther ? item === null || item === void 0 ? void 0 : (_item$config2 = item.config) === null || _item$config2 === void 0 ? void 0 : (_item$config2$options = _item$config2.options) === null || _item$config2$options === void 0 ? void 0 : _item$config2$options.concat({
102
- label: '其他',
103
- value: '其他'
102
+ label: "其他",
103
+ value: "其他"
104
104
  }) : (item === null || item === void 0 ? void 0 : (_item$config3 = item.config) === null || _item$config3 === void 0 ? void 0 : _item$config3.options) || []
105
105
  },
106
106
  filterFn: function filterFn(value) {
@@ -130,7 +130,7 @@ var BasicRadio = /*#__PURE__*/_createClass(function BasicRadio(options) {
130
130
  return Promise.resolve();
131
131
  }
132
132
  }] : [];
133
- this.dataType = 'string';
133
+ this.dataType = "string";
134
134
  this.options = ((_this$componentConfig4 = this.componentConfig) === null || _this$componentConfig4 === void 0 ? void 0 : _this$componentConfig4.options) || [];
135
135
  });
136
136
  export default BasicRadio;
@@ -1,6 +1,6 @@
1
- import { ComponentInterface, PickOption, Record } from '../../type';
2
- import React from 'react';
3
- import { AddressData } from '@kmkf-fe-packages/kmkf-utils';
1
+ import { ComponentInterface, PickOption, Record } from "../../type";
2
+ import React from "react";
3
+ import { AddressData } from "@kmkf-fe-packages/kmkf-utils";
4
4
  declare type Value = {
5
5
  address?: (string | number)[];
6
6
  detail?: string;
@@ -18,12 +18,12 @@ declare class BasicInput implements ComponentInterface {
18
18
  canSort: boolean;
19
19
  children: ComponentInterface[];
20
20
  addressDateInstance: InstanceType<typeof AddressData>;
21
- dataType: ComponentInterface['dataType'];
21
+ dataType: ComponentInterface["dataType"];
22
22
  constructor(options: PickOption);
23
23
  render: (value: Value) => React.JSX.Element;
24
24
  transTextToNumber: (value?: string) => string | number | undefined;
25
25
  renderPc: (value: any, record: Record) => React.JSX.Element;
26
- renderLog: (r: Record) => React.JSX.Element | null;
26
+ renderLog: (r: Record) => string;
27
27
  getComponentValue: (r: Record) => {
28
28
  address: any[];
29
29
  detail: any;