@kmkf-fe-packages/kmkf-work-order-service-component 2.2.13 → 2.2.14-beta.0
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/FlowTemplateDetailV2/common.d.ts +3 -2
- package/dist/esm/FlowTemplateDetailV2/common.js +15 -4
- package/dist/esm/FlowTemplateDetailV2/components/CurrentNode/index.js +28 -21
- package/dist/esm/FlowTemplateDetailV2/components/FormRender/index.d.ts +1 -0
- package/dist/esm/FlowTemplateDetailV2/components/FormRender/index.js +50 -4
- package/dist/esm/FlowTemplateDetailV2/components/Item/index.d.ts +1 -0
- package/dist/esm/FlowTemplateDetailV2/components/Item/index.js +61 -30
- package/dist/esm/FlowTemplateDetailV2/components/RemarkListModal/index.d.ts +1 -0
- package/dist/esm/FlowTemplateDetailV2/components/RemarkListModal/index.js +19 -11
- package/dist/esm/FlowTemplateDetailV2/components/ShareLinkModal/index.js +13 -9
- package/dist/esm/FlowTemplateDetailV2/constant.js +1 -1
- package/dist/esm/FlowTemplateDetailV2/index.js +94 -66
- package/dist/esm/FlowTemplateDetailV2/store/reducers.d.ts +6 -0
- package/dist/esm/FlowTemplateDetailV2/store/reducers.js +123 -78
- package/dist/esm/FlowTemplateDetailV2/store/selector.d.ts +3 -0
- package/dist/esm/FlowTemplateDetailV2/store/selector.js +3 -0
- package/dist/esm/Login/index.d.ts +1 -0
- package/dist/esm/Login/index.js +3 -1
- package/dist/esm/LoginNew/index.d.ts +8 -0
- package/dist/esm/{WorkOrder/components/CustomizeWorkOrderList/components/RepeatWorkOrderListModal → LoginNew}/index.js +243 -114
- package/dist/esm/LoginNew/index.module.less +45 -0
- package/dist/esm/WorkOrder/components/WorkOrderList/components/LogicFlowList/index.d.ts +3 -1
- package/dist/esm/WorkOrder/components/WorkOrderList/components/LogicFlowList/index.js +15 -4
- package/dist/esm/WorkOrder/components/WorkOrderList/components/LogicFlowList/index.less +18 -7
- package/dist/esm/WorkOrder/components/WorkOrderList/index.d.ts +1 -1
- package/dist/esm/WorkOrder/components/WorkOrderList/index.js +80 -22
- package/dist/esm/common/utils/constant.js +29 -2
- package/dist/esm/common/utils/submitDataTransOldFormat.js +113 -87
- package/dist/esm/common/utils/tools.d.ts +2 -1
- package/dist/esm/common/utils/tools.js +230 -137
- package/dist/esm/common/utils/tools_constants.js +10 -1
- package/dist/esm/common/utils/transformWorkOrderData.js +75 -4
- package/dist/esm/common/utils/xzSDK.js +3 -1
- package/dist/esm/index.d.ts +1 -0
- package/dist/esm/index.js +1 -0
- package/dist/esm/model/flowTemplateDetail/api.d.ts +3 -0
- package/dist/esm/model/flowTemplateDetail/api.js +7 -0
- package/dist/esm/model/flowTemplateDetail/types.d.ts +3 -0
- package/dist/esm/model/login.d.ts +10 -0
- package/dist/esm/model/login.js +66 -45
- package/dist/esm/model/servers/api.d.ts +4 -0
- package/dist/esm/model/servers/api.js +25 -0
- package/package.json +5 -5
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/CancelInterceptionModal/index.d.ts +0 -5
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/CancelInterceptionModal/index.js +0 -58
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/CustomizeWorkOrderCard/index.d.ts +0 -4
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/CustomizeWorkOrderCard/index.js +0 -297
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/CustomizeWorkOrderCard/index.less +0 -137
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/DealerSelectModal/index.d.ts +0 -5
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/DealerSelectModal/index.js +0 -95
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/DeleteCustomizeOrderModal/index.d.ts +0 -5
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/DeleteCustomizeOrderModal/index.js +0 -71
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.d.ts +0 -12
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.js +0 -22
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.less +0 -20
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/RecordLog/index.d.ts +0 -7
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/RecordLog/index.js +0 -96
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/RecordLog/index.less +0 -7
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/RepeatWorkOrderListModal/index.d.ts +0 -4
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/RepeatWorkOrderListModal/index.less +0 -34
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/StatusSelectModal/index.d.ts +0 -5
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/StatusSelectModal/index.js +0 -157
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.d.ts +0 -11
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.js +0 -19
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.less +0 -17
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/index.d.ts +0 -8
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/index.js +0 -454
- package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/index.less +0 -284
|
@@ -1,71 +0,0 @@
|
|
|
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); }); }; }
|
|
5
|
-
/*
|
|
6
|
-
* @Author: wangzhenggui jianjia.wzg@raycloud.com
|
|
7
|
-
* @Date: 2022-11-03 16:01:49
|
|
8
|
-
* @LastEditors: litian
|
|
9
|
-
* @LastEditTime: 2022-11-24 14:13:11
|
|
10
|
-
* @FilePath: /kmkf-work-order-service-component/src/WorkOrder/components/DeleteCustomizeOrderModal/index.tsx
|
|
11
|
-
* @Description:
|
|
12
|
-
*
|
|
13
|
-
* Copyright (c) 2022 by wangzhenggui jianjia.wzg@raycloud.com, All Rights Reserved.
|
|
14
|
-
*/
|
|
15
|
-
import React, { useCallback } from 'react';
|
|
16
|
-
import { Modal } from 'antd';
|
|
17
|
-
import { useSelector } from 'react-redux';
|
|
18
|
-
import { debounce } from 'lodash';
|
|
19
|
-
import { useAppDispatch } from "../../../../../model/hooks";
|
|
20
|
-
import { fetchDeleteWorkOrder } from "../../../../../model/workOrder";
|
|
21
|
-
import { setCurrentCustomizeRecord } from "../../../../../model/customizeWorkOrder";
|
|
22
|
-
import { selectDeleteCustomizeWorkOrderModalVisible, selectorCurrentCustomizeRecord } from "../../../../../model/customizeWorkOrder/selector";
|
|
23
|
-
var DeleteCustomizeOrderModal = function DeleteCustomizeOrderModal(_ref) {
|
|
24
|
-
var submit = _ref.submit;
|
|
25
|
-
var dispatch = useAppDispatch();
|
|
26
|
-
var deleteCustomizeWorkOrderModalVisible = useSelector(selectDeleteCustomizeWorkOrderModalVisible);
|
|
27
|
-
var record = useSelector(selectorCurrentCustomizeRecord);
|
|
28
|
-
var handleCancel = function handleCancel() {
|
|
29
|
-
dispatch({
|
|
30
|
-
type: 'customizeWorkOrder/setDeleteCustomizeWorkOrderModalVisible',
|
|
31
|
-
payload: false
|
|
32
|
-
});
|
|
33
|
-
dispatch(setCurrentCustomizeRecord({}));
|
|
34
|
-
};
|
|
35
|
-
var onDelete = useCallback( /*#__PURE__*/_asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
36
|
-
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
37
|
-
while (1) switch (_context.prev = _context.next) {
|
|
38
|
-
case 0:
|
|
39
|
-
_context.prev = 0;
|
|
40
|
-
_context.next = 3;
|
|
41
|
-
return dispatch(fetchDeleteWorkOrder({
|
|
42
|
-
uniqueKey: record === null || record === void 0 ? void 0 : record.templateId,
|
|
43
|
-
workOrderId: record === null || record === void 0 ? void 0 : record.id
|
|
44
|
-
})).unwrap();
|
|
45
|
-
case 3:
|
|
46
|
-
submit();
|
|
47
|
-
handleCancel();
|
|
48
|
-
_context.next = 10;
|
|
49
|
-
break;
|
|
50
|
-
case 7:
|
|
51
|
-
_context.prev = 7;
|
|
52
|
-
_context.t0 = _context["catch"](0);
|
|
53
|
-
console.log('e', _context.t0);
|
|
54
|
-
case 10:
|
|
55
|
-
case "end":
|
|
56
|
-
return _context.stop();
|
|
57
|
-
}
|
|
58
|
-
}, _callee, null, [[0, 7]]);
|
|
59
|
-
})), [record]);
|
|
60
|
-
return /*#__PURE__*/React.createElement(Modal, {
|
|
61
|
-
title: "\u5220\u9664\u5DE5\u5355",
|
|
62
|
-
open: deleteCustomizeWorkOrderModalVisible,
|
|
63
|
-
okText: "\u786E\u5B9A",
|
|
64
|
-
cancelText: "\u53D6\u6D88",
|
|
65
|
-
onOk: debounce(onDelete, 300),
|
|
66
|
-
onCancel: handleCancel
|
|
67
|
-
}, /*#__PURE__*/React.createElement("div", null, /*#__PURE__*/React.createElement("span", {
|
|
68
|
-
className: "red"
|
|
69
|
-
}, "\u5220\u9664\u540E\u7684\u5DE5\u5355\u65E0\u6CD5\u6062\u590D"), "\uFF0C \u786E\u8BA4\u8981\u5220\u9664\u8BE5\u6761\u6570\u636E\u5417\uFF1F"));
|
|
70
|
-
};
|
|
71
|
-
export default DeleteCustomizeOrderModal;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.d.ts
DELETED
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { LogicFlow } from '../../../../../model/logicFlow/types';
|
|
3
|
-
import './index.less';
|
|
4
|
-
declare type PropsType = {
|
|
5
|
-
logicFlowList: LogicFlow[];
|
|
6
|
-
handleCreateWorkOrderByFlowId: (p: {
|
|
7
|
-
id: string;
|
|
8
|
-
name: string;
|
|
9
|
-
}) => void;
|
|
10
|
-
};
|
|
11
|
-
declare const LogicFlowList: ({ logicFlowList, handleCreateWorkOrderByFlowId }: PropsType) => React.JSX.Element;
|
|
12
|
-
export default LogicFlowList;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.js
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Button } from 'antd';
|
|
3
|
-
import "./index.less";
|
|
4
|
-
var LogicFlowList = function LogicFlowList(_ref) {
|
|
5
|
-
var logicFlowList = _ref.logicFlowList,
|
|
6
|
-
handleCreateWorkOrderByFlowId = _ref.handleCreateWorkOrderByFlowId;
|
|
7
|
-
return /*#__PURE__*/React.createElement("div", {
|
|
8
|
-
className: "template-button-list"
|
|
9
|
-
}, logicFlowList.map(function (item) {
|
|
10
|
-
return /*#__PURE__*/React.createElement(Button, {
|
|
11
|
-
className: "template-button",
|
|
12
|
-
key: item.id,
|
|
13
|
-
onClick: function onClick() {
|
|
14
|
-
return handleCreateWorkOrderByFlowId({
|
|
15
|
-
id: item.id,
|
|
16
|
-
name: item.name
|
|
17
|
-
});
|
|
18
|
-
}
|
|
19
|
-
}, item.name);
|
|
20
|
-
}));
|
|
21
|
-
};
|
|
22
|
-
export default LogicFlowList;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/LogicFlowList/index.less
DELETED
|
@@ -1,20 +0,0 @@
|
|
|
1
|
-
.template-button-list {
|
|
2
|
-
padding:8px;
|
|
3
|
-
display: flex;
|
|
4
|
-
flex-wrap: wrap;
|
|
5
|
-
max-height: 78px;
|
|
6
|
-
margin-bottom: 8px;
|
|
7
|
-
overflow-y: auto;
|
|
8
|
-
background-color: #fff;
|
|
9
|
-
border-radius: 8px;
|
|
10
|
-
|
|
11
|
-
&:hover {
|
|
12
|
-
position: absolute;
|
|
13
|
-
z-index: 1;
|
|
14
|
-
max-height: 160px;
|
|
15
|
-
}
|
|
16
|
-
.template-button {
|
|
17
|
-
margin-right: 8px;
|
|
18
|
-
margin-bottom: 8px;
|
|
19
|
-
}
|
|
20
|
-
}
|
|
@@ -1,96 +0,0 @@
|
|
|
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); }); }; }
|
|
5
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
6
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
7
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
8
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
9
|
-
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
10
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11
|
-
import React from 'react';
|
|
12
|
-
import { useState, useEffect, memo } from 'react';
|
|
13
|
-
import { Drawer } from 'antd';
|
|
14
|
-
import { LeftOutlined } from '@ant-design/icons';
|
|
15
|
-
import moment from 'moment';
|
|
16
|
-
import { get } from 'lodash';
|
|
17
|
-
import { useSelector, useDispatch } from 'react-redux';
|
|
18
|
-
import { OperationLog } from '@kmkf-fe-packages/services-components';
|
|
19
|
-
import { reportLogs } from "../../../../../model/servers/api";
|
|
20
|
-
import { selectorLogModalVisible, selectorCurrentCustomizeRecord, selectorAllTemplateList } from "../../../../../model/customizeWorkOrder/selector";
|
|
21
|
-
import { setLogModalVisible } from "../../../../../model/customizeWorkOrder";
|
|
22
|
-
import "./index.less";
|
|
23
|
-
var custom_word = {
|
|
24
|
-
ADD: '添加',
|
|
25
|
-
UPDATE: '更新',
|
|
26
|
-
DELETE: '删除',
|
|
27
|
-
DEAL: '处理',
|
|
28
|
-
TRANSFER: '转移工单',
|
|
29
|
-
ENABLED: '启用/禁用工单',
|
|
30
|
-
'QY-CHANGE_QY_WORK_ORDER_HANDLER_LIST': '指定处理人',
|
|
31
|
-
'QY-CHANGE_QY_WORK_ORDER_FLOW_STATUS': '状态更新',
|
|
32
|
-
EXAMINE: '审核',
|
|
33
|
-
CANCEL_AUDIT: '取消审核'
|
|
34
|
-
};
|
|
35
|
-
var RecordLog = function RecordLog(props) {
|
|
36
|
-
var _useState = useState([]),
|
|
37
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
38
|
-
list = _useState2[0],
|
|
39
|
-
setLogList = _useState2[1];
|
|
40
|
-
var dispatch = useDispatch();
|
|
41
|
-
var visible = useSelector(selectorLogModalVisible);
|
|
42
|
-
var currentRecord = useSelector(selectorCurrentCustomizeRecord);
|
|
43
|
-
var componentDtoList = useSelector(selectorAllTemplateList);
|
|
44
|
-
useEffect(function () {
|
|
45
|
-
if (visible) {
|
|
46
|
-
getLog(currentRecord);
|
|
47
|
-
}
|
|
48
|
-
}, [currentRecord, visible]);
|
|
49
|
-
//获取日志
|
|
50
|
-
var getLog = /*#__PURE__*/function () {
|
|
51
|
-
var _ref = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee(record) {
|
|
52
|
-
var _yield$reportLogs, result;
|
|
53
|
-
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
54
|
-
while (1) switch (_context.prev = _context.next) {
|
|
55
|
-
case 0:
|
|
56
|
-
_context.next = 2;
|
|
57
|
-
return reportLogs({
|
|
58
|
-
pageNo: 1,
|
|
59
|
-
pageSize: 1000,
|
|
60
|
-
rowId: record.id,
|
|
61
|
-
shopId: record.shopId
|
|
62
|
-
});
|
|
63
|
-
case 2:
|
|
64
|
-
_yield$reportLogs = _context.sent;
|
|
65
|
-
result = _yield$reportLogs.data.result;
|
|
66
|
-
setLogList(result);
|
|
67
|
-
case 5:
|
|
68
|
-
case "end":
|
|
69
|
-
return _context.stop();
|
|
70
|
-
}
|
|
71
|
-
}, _callee);
|
|
72
|
-
}));
|
|
73
|
-
return function getLog(_x2) {
|
|
74
|
-
return _ref.apply(this, arguments);
|
|
75
|
-
};
|
|
76
|
-
}();
|
|
77
|
-
return /*#__PURE__*/React.createElement(Drawer, {
|
|
78
|
-
open: visible,
|
|
79
|
-
closeIcon: /*#__PURE__*/React.createElement(LeftOutlined, null),
|
|
80
|
-
width: props === null || props === void 0 ? void 0 : props.width,
|
|
81
|
-
title: "\u64CD\u4F5C\u8BB0\u5F55",
|
|
82
|
-
onClose: function onClose() {
|
|
83
|
-
return dispatch(setLogModalVisible(false));
|
|
84
|
-
}
|
|
85
|
-
}, list === null || list === void 0 ? void 0 : list.map(function (item) {
|
|
86
|
-
var splitValue = get(item.operation.split(':'), '0', '');
|
|
87
|
-
return /*#__PURE__*/React.createElement("div", {
|
|
88
|
-
className: "log_item"
|
|
89
|
-
}, /*#__PURE__*/React.createElement("div", null, "\u8D26\u53F7\uFF1A", item.operationName), /*#__PURE__*/React.createElement("div", null, "\u64CD\u4F5C\uFF1A", custom_word[splitValue]), /*#__PURE__*/React.createElement("div", null, "\u64CD\u4F5C\u65F6\u95F4:", moment(item.created).format('YYYY-MM-DD HH:mm:ss')), /*#__PURE__*/React.createElement("div", null, "\u64CD\u4F5C\u5185\u5BB9\uFF1A", /*#__PURE__*/React.createElement(OperationLog, {
|
|
90
|
-
content: item.content,
|
|
91
|
-
operation: item.operation,
|
|
92
|
-
componentDtoList: componentDtoList
|
|
93
|
-
})));
|
|
94
|
-
}));
|
|
95
|
-
};
|
|
96
|
-
export default /*#__PURE__*/memo(RecordLog);
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
.item-wrap {
|
|
2
|
-
display: flex;
|
|
3
|
-
flex-direction: column;
|
|
4
|
-
margin-bottom: 4px;
|
|
5
|
-
background: #fff;
|
|
6
|
-
.item-main-item {
|
|
7
|
-
// flex-basis: 100px;
|
|
8
|
-
font-weight: 600;
|
|
9
|
-
font-size: 14px;
|
|
10
|
-
line-height: 32px;
|
|
11
|
-
}
|
|
12
|
-
}
|
|
13
|
-
.customize-repeat-workOrder {
|
|
14
|
-
padding-left: 16px;
|
|
15
|
-
li {
|
|
16
|
-
margin-bottom: 4px;
|
|
17
|
-
list-style: decimal;
|
|
18
|
-
.workOrderIdWrap {
|
|
19
|
-
display: flex;
|
|
20
|
-
align-content: center;
|
|
21
|
-
.workOrderId {
|
|
22
|
-
display: inline-block;
|
|
23
|
-
width: 240px;
|
|
24
|
-
margin-right: 16px;
|
|
25
|
-
overflow: hidden;
|
|
26
|
-
white-space: nowrap;
|
|
27
|
-
text-overflow: ellipsis;
|
|
28
|
-
}
|
|
29
|
-
.text-repeat {
|
|
30
|
-
cursor: pointer;
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
}
|
|
34
|
-
}
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/StatusSelectModal/index.js
DELETED
|
@@ -1,157 +0,0 @@
|
|
|
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); }); }; }
|
|
5
|
-
function _slicedToArray(arr, i) { return _arrayWithHoles(arr) || _iterableToArrayLimit(arr, i) || _unsupportedIterableToArray(arr, i) || _nonIterableRest(); }
|
|
6
|
-
function _nonIterableRest() { throw new TypeError("Invalid attempt to destructure non-iterable instance.\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method."); }
|
|
7
|
-
function _unsupportedIterableToArray(o, minLen) { if (!o) return; if (typeof o === "string") return _arrayLikeToArray(o, minLen); var n = Object.prototype.toString.call(o).slice(8, -1); if (n === "Object" && o.constructor) n = o.constructor.name; if (n === "Map" || n === "Set") return Array.from(o); if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _arrayLikeToArray(o, minLen); }
|
|
8
|
-
function _arrayLikeToArray(arr, len) { if (len == null || len > arr.length) len = arr.length; for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i]; return arr2; }
|
|
9
|
-
function _iterableToArrayLimit(arr, i) { var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"]; if (null != _i) { var _s, _e, _x, _r, _arr = [], _n = !0, _d = !1; try { if (_x = (_i = _i.call(arr)).next, 0 === i) { if (Object(_i) !== _i) return; _n = !1; } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0); } catch (err) { _d = !0, _e = err; } finally { try { if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return; } finally { if (_d) throw _e; } } return _arr; } }
|
|
10
|
-
function _arrayWithHoles(arr) { if (Array.isArray(arr)) return arr; }
|
|
11
|
-
import React, { useState, useEffect } from 'react';
|
|
12
|
-
import { Modal, Select, Form, message } from 'antd';
|
|
13
|
-
import { useSelector, useDispatch } from 'react-redux';
|
|
14
|
-
import { debounce, isEmpty, isEqual } from 'lodash';
|
|
15
|
-
import { selectorModalVisible, selectorCurrentCustomizeRecord } from "../../../../../model/customizeWorkOrder/selector";
|
|
16
|
-
import { setStatusSelectModalVisible, setCurrentCustomizeRecord } from "../../../../../model/customizeWorkOrder";
|
|
17
|
-
import { WAITING, HANDLING, STOPPING, COMPLETED } from "../../../../../common/constant";
|
|
18
|
-
import every from 'lodash/every';
|
|
19
|
-
import get from 'lodash/get';
|
|
20
|
-
import { updateFlowStatus } from "../../../../../model/servers/api";
|
|
21
|
-
var options = [{
|
|
22
|
-
label: '待处理',
|
|
23
|
-
value: WAITING
|
|
24
|
-
}, {
|
|
25
|
-
label: '处理中',
|
|
26
|
-
value: HANDLING
|
|
27
|
-
}, {
|
|
28
|
-
label: '暂停中',
|
|
29
|
-
value: STOPPING
|
|
30
|
-
}, {
|
|
31
|
-
label: '已完成',
|
|
32
|
-
value: COMPLETED
|
|
33
|
-
}];
|
|
34
|
-
|
|
35
|
-
// 判断工单中是否含有【已完成】状态工单
|
|
36
|
-
var existStatusWorkOrder = function existStatusWorkOrder(workOrder, status) {
|
|
37
|
-
return (workOrder === null || workOrder === void 0 ? void 0 : workOrder.flowStatus) === status;
|
|
38
|
-
};
|
|
39
|
-
var checkPaymentStatus = function checkPaymentStatus(passStatus) {
|
|
40
|
-
return function (workOrderList, statusKeyName) {
|
|
41
|
-
// 先获取打款组件状态字段名
|
|
42
|
-
return every(workOrderList, function (item) {
|
|
43
|
-
var status = get(item, "jsonMap.".concat(statusKeyName));
|
|
44
|
-
return passStatus.includes(status);
|
|
45
|
-
});
|
|
46
|
-
};
|
|
47
|
-
};
|
|
48
|
-
|
|
49
|
-
// 打款工单状态校验
|
|
50
|
-
var checkPaymentStatusByList = function checkPaymentStatusByList(list) {
|
|
51
|
-
return every(list, function (item) {
|
|
52
|
-
// 打款金额判断是否生成打款工单
|
|
53
|
-
var enterprisePaymentRefundFee = Object.keys(item === null || item === void 0 ? void 0 : item.jsonMap).find(function (i) {
|
|
54
|
-
return i.endsWith('enterprisePaymentRefundFee');
|
|
55
|
-
});
|
|
56
|
-
var enterprisePaymentStatus = Object.keys(item === null || item === void 0 ? void 0 : item.jsonMap).find(function (i) {
|
|
57
|
-
return i.endsWith('enterprisePaymentStatus');
|
|
58
|
-
});
|
|
59
|
-
var hasEnterprisePaymentRefundFee = isEmpty(get(item === null || item === void 0 ? void 0 : item.jsonMap, enterprisePaymentRefundFee));
|
|
60
|
-
return hasEnterprisePaymentRefundFee && isEqual('未打款', get(item === null || item === void 0 ? void 0 : item.jsonMap, enterprisePaymentStatus)) || [undefined, '标记已打款', '支付宝打款失败', '支付宝打款成功', '支付宝打款关闭'].includes(get(item === null || item === void 0 ? void 0 : item.jsonMap, enterprisePaymentStatus));
|
|
61
|
-
});
|
|
62
|
-
};
|
|
63
|
-
var StatusSelectModal = function StatusSelectModal(_ref) {
|
|
64
|
-
var onSuccess = _ref.onSuccess;
|
|
65
|
-
var dispatch = useDispatch();
|
|
66
|
-
var _useState = useState(''),
|
|
67
|
-
_useState2 = _slicedToArray(_useState, 2),
|
|
68
|
-
status = _useState2[0],
|
|
69
|
-
setStatus = _useState2[1];
|
|
70
|
-
var visible = useSelector(selectorModalVisible);
|
|
71
|
-
var record = useSelector(selectorCurrentCustomizeRecord);
|
|
72
|
-
useEffect(function () {
|
|
73
|
-
var _record$jsonMap;
|
|
74
|
-
setStatus(record === null || record === void 0 ? void 0 : (_record$jsonMap = record.jsonMap) === null || _record$jsonMap === void 0 ? void 0 : _record$jsonMap.flowStatus);
|
|
75
|
-
}, [record]);
|
|
76
|
-
var handleChange = function handleChange(val) {
|
|
77
|
-
var enterprisePaymentStatus = Object.keys(record === null || record === void 0 ? void 0 : record.jsonMap).find(function (i) {
|
|
78
|
-
return i.endsWith('enterprisePaymentStatus');
|
|
79
|
-
});
|
|
80
|
-
if (val === HANDLING && existStatusWorkOrder(record === null || record === void 0 ? void 0 : record.jsonMap, COMPLETED)) {
|
|
81
|
-
return message.warn('当前工单不可以设置为处理中状态');
|
|
82
|
-
}
|
|
83
|
-
if (val === STOPPING && existStatusWorkOrder(record === null || record === void 0 ? void 0 : record.jsonMap, COMPLETED)) {
|
|
84
|
-
return message.warn('当前工单不可以设置为暂停中状态');
|
|
85
|
-
}
|
|
86
|
-
if (val === WAITING && !(existStatusWorkOrder(record === null || record === void 0 ? void 0 : record.jsonMap, HANDLING) || existStatusWorkOrder(record === null || record === void 0 ? void 0 : record.jsonMap, STOPPING) || enterprisePaymentStatus && checkPaymentStatus(['未打款'])([record], enterprisePaymentStatus))) {
|
|
87
|
-
return message.warn('当前工单不可以设置为待处理状态');
|
|
88
|
-
}
|
|
89
|
-
if (val === COMPLETED && enterprisePaymentStatus && !checkPaymentStatusByList([record])) {
|
|
90
|
-
return message.warn('只有标记已打款/支付宝打款成功/支付宝打款失败/支付宝打款关闭这4种状态才可以设置为已完成');
|
|
91
|
-
}
|
|
92
|
-
setStatus(val);
|
|
93
|
-
};
|
|
94
|
-
var handleCancel = function handleCancel() {
|
|
95
|
-
dispatch(setCurrentCustomizeRecord({}));
|
|
96
|
-
dispatch(setStatusSelectModalVisible(false));
|
|
97
|
-
};
|
|
98
|
-
var handleAppointTo = /*#__PURE__*/function () {
|
|
99
|
-
var _ref2 = _asyncToGenerator( /*#__PURE__*/_regeneratorRuntime().mark(function _callee() {
|
|
100
|
-
var params, _yield$updateFlowStat, success, errMsg;
|
|
101
|
-
return _regeneratorRuntime().wrap(function _callee$(_context) {
|
|
102
|
-
while (1) switch (_context.prev = _context.next) {
|
|
103
|
-
case 0:
|
|
104
|
-
if (status) {
|
|
105
|
-
_context.next = 2;
|
|
106
|
-
break;
|
|
107
|
-
}
|
|
108
|
-
return _context.abrupt("return", message.error('请先选择工单状态'));
|
|
109
|
-
case 2:
|
|
110
|
-
params = {
|
|
111
|
-
updatedFlowStatus: status,
|
|
112
|
-
currentFlowStatus: record === null || record === void 0 ? void 0 : record.flowStatus,
|
|
113
|
-
workOrderUniqueKeys: [record === null || record === void 0 ? void 0 : record.id]
|
|
114
|
-
};
|
|
115
|
-
_context.next = 5;
|
|
116
|
-
return updateFlowStatus(params);
|
|
117
|
-
case 5:
|
|
118
|
-
_yield$updateFlowStat = _context.sent;
|
|
119
|
-
success = _yield$updateFlowStat.success;
|
|
120
|
-
errMsg = _yield$updateFlowStat.message;
|
|
121
|
-
if (success) {
|
|
122
|
-
message.success('状态设置成功');
|
|
123
|
-
handleCancel();
|
|
124
|
-
onSuccess();
|
|
125
|
-
} else {
|
|
126
|
-
message.error(errMsg);
|
|
127
|
-
}
|
|
128
|
-
case 9:
|
|
129
|
-
case "end":
|
|
130
|
-
return _context.stop();
|
|
131
|
-
}
|
|
132
|
-
}, _callee);
|
|
133
|
-
}));
|
|
134
|
-
return function handleAppointTo() {
|
|
135
|
-
return _ref2.apply(this, arguments);
|
|
136
|
-
};
|
|
137
|
-
}();
|
|
138
|
-
return /*#__PURE__*/React.createElement(Modal, {
|
|
139
|
-
title: "\u5904\u7406\u5DE5\u5355",
|
|
140
|
-
visible: visible,
|
|
141
|
-
okText: "\u786E\u5B9A",
|
|
142
|
-
cancelText: "\u53D6\u6D88",
|
|
143
|
-
onCancel: handleCancel,
|
|
144
|
-
onOk: debounce(handleAppointTo, 300)
|
|
145
|
-
}, /*#__PURE__*/React.createElement(Form.Item, {
|
|
146
|
-
label: "\u8BF7\u8BBE\u7F6E\u5DE5\u5355\u72B6\u6001"
|
|
147
|
-
}, /*#__PURE__*/React.createElement(Select, {
|
|
148
|
-
style: {
|
|
149
|
-
width: '100%'
|
|
150
|
-
},
|
|
151
|
-
placeholder: "\u8BF7\u8BBE\u7F6E\u5DE5\u5355\u72B6\u6001",
|
|
152
|
-
value: status,
|
|
153
|
-
onChange: handleChange,
|
|
154
|
-
options: options
|
|
155
|
-
})));
|
|
156
|
-
};
|
|
157
|
-
export default StatusSelectModal;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.d.ts
DELETED
|
@@ -1,11 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import './index.less';
|
|
3
|
-
declare type PropsType = {
|
|
4
|
-
templateList: {
|
|
5
|
-
name: string;
|
|
6
|
-
uniqueKey: string;
|
|
7
|
-
}[];
|
|
8
|
-
handleCreateWorkOrder: (p: string) => void;
|
|
9
|
-
};
|
|
10
|
-
declare const TemplateList: ({ templateList, handleCreateWorkOrder }: PropsType) => React.JSX.Element;
|
|
11
|
-
export default TemplateList;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import { Button } from 'antd';
|
|
3
|
-
import "./index.less";
|
|
4
|
-
var TemplateList = function TemplateList(_ref) {
|
|
5
|
-
var templateList = _ref.templateList,
|
|
6
|
-
handleCreateWorkOrder = _ref.handleCreateWorkOrder;
|
|
7
|
-
return /*#__PURE__*/React.createElement("div", {
|
|
8
|
-
className: "template-button-list"
|
|
9
|
-
}, templateList.map(function (item) {
|
|
10
|
-
return /*#__PURE__*/React.createElement(Button, {
|
|
11
|
-
className: "template-button",
|
|
12
|
-
key: item.uniqueKey,
|
|
13
|
-
onClick: function onClick() {
|
|
14
|
-
return handleCreateWorkOrder(item.uniqueKey);
|
|
15
|
-
}
|
|
16
|
-
}, item.name);
|
|
17
|
-
}));
|
|
18
|
-
};
|
|
19
|
-
export default TemplateList;
|
package/dist/esm/WorkOrder/components/CustomizeWorkOrderList/components/TemplateList/index.less
DELETED
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
.template-button-list {
|
|
2
|
-
display: flex;
|
|
3
|
-
flex-wrap: wrap;
|
|
4
|
-
max-height: 78px;
|
|
5
|
-
margin-bottom: 4px;
|
|
6
|
-
overflow-y: auto;
|
|
7
|
-
background-color: #fff;
|
|
8
|
-
&:hover {
|
|
9
|
-
position: absolute;
|
|
10
|
-
z-index: 1;
|
|
11
|
-
max-height: 160px;
|
|
12
|
-
}
|
|
13
|
-
.template-button {
|
|
14
|
-
margin-right: 8px;
|
|
15
|
-
margin-bottom: 8px;
|
|
16
|
-
}
|
|
17
|
-
}
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import React from 'react';
|
|
2
|
-
import './index.less';
|
|
3
|
-
declare type OrderListProps = {
|
|
4
|
-
tabActive: string;
|
|
5
|
-
onOpenWangWang?: (nick: string, id: string) => void;
|
|
6
|
-
};
|
|
7
|
-
declare const CustomizeWorkOrderList: ({ tabActive, onOpenWangWang }: OrderListProps) => React.JSX.Element;
|
|
8
|
-
export default CustomizeWorkOrderList;
|