ztxkui 4.2.23-342-beta → 4.2.23-343-beta
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/components/WorkflowPrintContainer/component/Header.d.ts +1 -1
- package/dist/components/WorkflowPrintContainer/component/Header.js +5 -6
- package/dist/components/WorkflowPrintContainer/workflow-print-container.d.ts +3 -0
- package/dist/components/WorkflowPrintContainer/workflow-print-container.js +2 -2
- package/dist/components/electron-signatures/fileComponents/file-operation.js +1 -1
- package/dist/components/electron-signatures/hooks/useMergeRecords.d.ts +1 -0
- package/dist/components/electron-signatures/hooks/useMergeRecords.js +5 -2
- package/dist/components/electron-signatures/index.js +3 -0
- package/package.json +1 -1
|
@@ -88,13 +88,12 @@ var Header = function (_a) {
|
|
|
88
88
|
React.createElement("div", { className: "title" }, ((data === null || data === void 0 ? void 0 : data.taskName) ? data === null || data === void 0 ? void 0 : data.taskName : '') + "\u8BE6\u60C5"),
|
|
89
89
|
showStatus ? (React.createElement("div", { className: getDealType(data.status)[0] }, getDealType(data.status)[1])) : null,
|
|
90
90
|
showProcessStatus ? (React.createElement("div", { className: getProcessType(data.processInstState)[0] }, getProcessType(data.processInstState)[1])) : null,
|
|
91
|
-
priority ? (React.createElement("div", { className: getPriorityStatus(priority)[0] }, getPriorityStatus(priority)[1])) : null
|
|
91
|
+
priority ? (React.createElement("div", { className: getPriorityStatus(priority)[0] }, getPriorityStatus(priority)[1])) : null,
|
|
92
|
+
(data === null || data === void 0 ? void 0 : data.processInstId) ? (React.createElement("div", { className: "process-inst-id" }, data === null || data === void 0 ? void 0 : data.processInstId)) : null),
|
|
92
93
|
React.createElement("div", null, (data === null || data === void 0 ? void 0 : data.processTypeName) ? data === null || data === void 0 ? void 0 : data.processTypeName : '')),
|
|
93
|
-
React.createElement("div", { className: "wf-task-process-status" },
|
|
94
|
-
React.createElement("div", { className: "lbpm-process-status", style: { backgroundImage: "url(" + lbpmProcessStatus + ")" } }),
|
|
95
|
-
|
|
96
|
-
React.createElement("div", { className: "lbpm-process-status", style: { backgroundImage: "url(" + lbpmProcessStatus + ")" } }))) : 8 === (data === null || data === void 0 ? void 0 : data.processInstState) ? (React.createElement("div", { className: "lbpm-flow-info" },
|
|
97
|
-
React.createElement("div", { className: "lbpm-discard-status", style: { backgroundImage: "url(" + lbpmDiscardStatus + ")" } }))) : null),
|
|
94
|
+
React.createElement("div", { className: "wf-task-process-status" }, 7 === (data === null || data === void 0 ? void 0 : data.processInstState) ? (React.createElement("div", { className: "lbpm-flow-info" },
|
|
95
|
+
React.createElement("div", { className: "lbpm-process-status", style: { backgroundImage: "url(" + lbpmProcessStatus + ")" } }))) : 8 === (data === null || data === void 0 ? void 0 : data.processInstState) ? (React.createElement("div", { className: "lbpm-flow-info" },
|
|
96
|
+
React.createElement("div", { className: "lbpm-discard-status", style: { backgroundImage: "url(" + lbpmDiscardStatus + ")" } }))) : null),
|
|
98
97
|
showPrintDate ? (React.createElement("div", { className: "print-date", style: { top: offsetHeight - 16 } },
|
|
99
98
|
"\u6253\u5370\u65E5\u671F:",
|
|
100
99
|
dayjs().format('YYYY-MM-DD'))) : null),
|
|
@@ -1,4 +1,5 @@
|
|
|
1
1
|
import React from 'react';
|
|
2
|
+
import { IProps as HeaderProps } from './component/Header';
|
|
2
3
|
/**
|
|
3
4
|
* 任务状态:待办
|
|
4
5
|
*/
|
|
@@ -95,6 +96,8 @@ export interface IProps {
|
|
|
95
96
|
getComponet?: (any: any) => any;
|
|
96
97
|
/** 获得流程的一些信息 */
|
|
97
98
|
getProcessInfo?: (data: any) => any;
|
|
99
|
+
/** 标题入参 */
|
|
100
|
+
headerProp?: HeaderProps;
|
|
98
101
|
}
|
|
99
102
|
declare const WorkflowPrintContainer: React.FC<IProps>;
|
|
100
103
|
export default WorkflowPrintContainer;
|
|
@@ -116,7 +116,7 @@ export var PROCESS_REJECTED = 9;
|
|
|
116
116
|
*/
|
|
117
117
|
export var PROCESS_DRAWBACK = 10;
|
|
118
118
|
var WorkflowPrintContainer = function (_a) {
|
|
119
|
-
var request = _a.request, taskId = _a.taskId, processInstId = _a.processInstId, _b = _a.isNotice, isNotice = _b === void 0 ? false : _b, _c = _a.titleCheckable, titleCheckable = _c === void 0 ? true : _c, _d = _a.showTitle, showTitle = _d === void 0 ? true : _d, _e = _a.detailCheckable, detailCheckable = _e === void 0 ? true : _e, _f = _a.showDetail, showDetail = _f === void 0 ? true : _f, _g = _a.approvalRecordsCheckable, approvalRecordsCheckable = _g === void 0 ? true : _g, _h = _a.showApprovalRecords, showApprovalRecords = _h === void 0 ? true : _h, _j = _a.attachCheckable, attachCheckable = _j === void 0 ? true : _j, _k = _a.showAttach, showAttach = _k === void 0 ? true : _k, _l = _a.relatedProcessesCheckable, relatedProcessesCheckable = _l === void 0 ? true : _l, _m = _a.showRelatedProcesses, showRelatedProcesses = _m === void 0 ? true : _m, _o = _a.circulationRecordsCheckable, circulationRecordsCheckable = _o === void 0 ? true : _o, _p = _a.showCirculationRecords, showCirculationRecords = _p === void 0 ? true : _p, getComponet = _a.getComponet, getProcessInfo = _a.getProcessInfo;
|
|
119
|
+
var request = _a.request, taskId = _a.taskId, processInstId = _a.processInstId, _b = _a.isNotice, isNotice = _b === void 0 ? false : _b, _c = _a.titleCheckable, titleCheckable = _c === void 0 ? true : _c, _d = _a.showTitle, showTitle = _d === void 0 ? true : _d, _e = _a.detailCheckable, detailCheckable = _e === void 0 ? true : _e, _f = _a.showDetail, showDetail = _f === void 0 ? true : _f, _g = _a.approvalRecordsCheckable, approvalRecordsCheckable = _g === void 0 ? true : _g, _h = _a.showApprovalRecords, showApprovalRecords = _h === void 0 ? true : _h, _j = _a.attachCheckable, attachCheckable = _j === void 0 ? true : _j, _k = _a.showAttach, showAttach = _k === void 0 ? true : _k, _l = _a.relatedProcessesCheckable, relatedProcessesCheckable = _l === void 0 ? true : _l, _m = _a.showRelatedProcesses, showRelatedProcesses = _m === void 0 ? true : _m, _o = _a.circulationRecordsCheckable, circulationRecordsCheckable = _o === void 0 ? true : _o, _p = _a.showCirculationRecords, showCirculationRecords = _p === void 0 ? true : _p, getComponet = _a.getComponet, getProcessInfo = _a.getProcessInfo, headerProp = _a.headerProp;
|
|
120
120
|
var _q = useState(isNotice), noticeInfoShown = _q[0], setNoticeInfoShown = _q[1];
|
|
121
121
|
// 标题
|
|
122
122
|
var _r = useState(showTitle), titleShown = _r[0], setTitleShown = _r[1];
|
|
@@ -244,7 +244,7 @@ var WorkflowPrintContainer = function (_a) {
|
|
|
244
244
|
React.createElement(Paragraph, { style: needHighlight ? { color: 'red' } : undefined },
|
|
245
245
|
"\u5185\u5BB9\uFF1A", data === null || data === void 0 ? void 0 :
|
|
246
246
|
data.noticeContent))),
|
|
247
|
-
titleShown && (React.createElement(Header, { data: __assign(__assign({}, data), { taskName: data === null || data === void 0 ? void 0 : data.processInstName }) })),
|
|
247
|
+
titleShown && (React.createElement(Header, __assign({ data: __assign(__assign({}, data), { taskName: data === null || data === void 0 ? void 0 : data.processInstName }) }, headerProp))),
|
|
248
248
|
React.createElement(ProcessDetail, { request: request, type: 'notice', data: data, showBizForm: true, toEdit: false, OuterComponent: createLazyComponent(data), showCfg: {
|
|
249
249
|
detailShown: detailShown,
|
|
250
250
|
approvalRecordsShown: approvalRecordsShown,
|
|
@@ -39,7 +39,7 @@ var FileOperation = function (props) {
|
|
|
39
39
|
onWatermarkChange && onWatermarkChange(e.target.checked);
|
|
40
40
|
} }, "\u6DFB\u52A0\u6C34\u5370"))),
|
|
41
41
|
React.createElement("div", { className: "file-operation--list" },
|
|
42
|
-
isReplaceFile && (React.createElement(FileUpload, { fileList: fileList, apiBaseUrl: apiBaseUrl, onFileChange: onFileChange, type: "link" }, "\u66FF\u6362")),
|
|
42
|
+
isEdit && isReplaceFile && (React.createElement(FileUpload, { fileList: fileList, apiBaseUrl: apiBaseUrl, onFileChange: onFileChange, type: "link" }, "\u66FF\u6362")),
|
|
43
43
|
isDownload && fileId ? (React.createElement(Button, { type: "link", onClick: function () {
|
|
44
44
|
downloadFileCallBack(apiBaseUrl, fileId, dangerouslySetXss(fileName) || '附件', {
|
|
45
45
|
addWaterMark: false,
|
|
@@ -4,16 +4,19 @@ import { currentRecordIsOnlyQunj } from '../utils';
|
|
|
4
4
|
* 将各级获取到的附件数据拉平成一个整体
|
|
5
5
|
*/
|
|
6
6
|
export default function useMergeRecords(options) {
|
|
7
|
-
var allData = options.allData, dataTypeSort = options.dataTypeSort, isDeleteAllFileWhenJustUseQj = options.isDeleteAllFileWhenJustUseQj;
|
|
7
|
+
var allData = options.allData, dataTypeSort = options.dataTypeSort, isDeleteAllFileWhenJustUseQj = options.isDeleteAllFileWhenJustUseQj, isDeletePlaceholderFileData = options.isDeletePlaceholderFileData;
|
|
8
8
|
var mergeRecords = useMemo(function () {
|
|
9
9
|
var allRecords = [];
|
|
10
10
|
dataTypeSort.forEach(function (dataType) {
|
|
11
11
|
var _a;
|
|
12
12
|
var records = ((_a = allData === null || allData === void 0 ? void 0 : allData[dataType]) === null || _a === void 0 ? void 0 : _a.records) || [];
|
|
13
|
+
if (isDeletePlaceholderFileData) {
|
|
14
|
+
records = records.filter(function (record) { return !currentRecordIsOnlyQunj(record); });
|
|
15
|
+
}
|
|
13
16
|
allRecords = allRecords.concat(records);
|
|
14
17
|
});
|
|
15
18
|
return allRecords;
|
|
16
|
-
}, [allData, dataTypeSort]);
|
|
19
|
+
}, [allData, dataTypeSort, isDeletePlaceholderFileData]);
|
|
17
20
|
// 是否仅选中群杰印章
|
|
18
21
|
var isQunjOnlyChecked = useMemo(function () {
|
|
19
22
|
return mergeRecords.some(function (record) { return currentRecordIsOnlyQunj(record); });
|
|
@@ -86,6 +86,7 @@ import { countIsValidate } from './hooks/useParseQunjListData';
|
|
|
86
86
|
import FileUpload from './fileComponents/file-upload';
|
|
87
87
|
import { DATA_TYPE_KEY } from './hooks/useParseRecords';
|
|
88
88
|
import useGetDeptInfo from './electronComponents/useGetDeptInfo';
|
|
89
|
+
import dayjs from 'dayjs';
|
|
89
90
|
/**
|
|
90
91
|
* 一开始这个组件想设计成 可以传入多中类型的数据 但是发现这种做法会有很多问题
|
|
91
92
|
* 不同的数据类型 共享一个表头 那么其实这样就做不到隐藏某些表头的效果
|
|
@@ -244,6 +245,7 @@ var ElectronSignatures = function (props) {
|
|
|
244
245
|
allData: allData,
|
|
245
246
|
dataTypeSort: dataTypeSort,
|
|
246
247
|
isDeleteAllFileWhenJustUseQj: isDeleteAllFileWhenJustUseQj,
|
|
248
|
+
isDeletePlaceholderFileData: isDeletePlaceholderFileData,
|
|
247
249
|
}), mergeRecords = _u.mergeRecords, isHiddenColumns = _u.isHiddenColumns;
|
|
248
250
|
// 附件归属
|
|
249
251
|
var fileTypeColumns = useFileTypeColumns({
|
|
@@ -750,6 +752,7 @@ var ElectronSignatures = function (props) {
|
|
|
750
752
|
copyRecords = copyRecords.filter(function (record) { return !currentRecordIsOnlyQunj(record); });
|
|
751
753
|
// 插入一个给开发操作附件的机会
|
|
752
754
|
var newFile = callback(file);
|
|
755
|
+
newFile.createTime = dayjs().format('YYYY-MM-DD HH:mm:ss');
|
|
753
756
|
// 每个附件都可以添加群杰时控制
|
|
754
757
|
if (isSingleQj) {
|
|
755
758
|
newFile[isQunjKey_1] = 1;
|