flowcore-fn 9.4.2 → 9.4.4
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/pkg-index.js +35 -5
- package/dist/pkg-index.mjs +79 -49
- package/package.json +1 -1
package/dist/pkg-index.js
CHANGED
|
@@ -3874,6 +3874,30 @@ function AddUserHierarchyNodeMappingModal({
|
|
|
3874
3874
|
}) {
|
|
3875
3875
|
const [formData, setFormData] = (0, import_react22.useState)({ mappingId: "", externalUserId: "", hierarchyNodeId: "", roleCode: "", isPrimary: "", effectiveFrom: "", effectiveTo: "" });
|
|
3876
3876
|
const [isSubmitting, setIsSubmitting] = (0, import_react22.useState)(false);
|
|
3877
|
+
const [hierarchyNodes, setHierarchyNodes] = (0, import_react22.useState)([]);
|
|
3878
|
+
const [isLoadingHierarchyNodes, setIsLoadingHierarchyNodes] = (0, import_react22.useState)(false);
|
|
3879
|
+
const [hierarchyNodesError, setHierarchyNodesError] = (0, import_react22.useState)("");
|
|
3880
|
+
(0, import_react22.useEffect)(() => {
|
|
3881
|
+
if (!isOpen) return;
|
|
3882
|
+
const loadHierarchyNodes = async () => {
|
|
3883
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
3884
|
+
setIsLoadingHierarchyNodes(true);
|
|
3885
|
+
setHierarchyNodesError("");
|
|
3886
|
+
try {
|
|
3887
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.hierarchyNode) == null ? void 0 : _c.getList;
|
|
3888
|
+
if (!endpoint) throw new Error("Hierarchy node list endpoint is not configured.");
|
|
3889
|
+
const result = await getApiService().get(endpoint);
|
|
3890
|
+
const value = ((_d = result == null ? void 0 : result.data) == null ? void 0 : _d.data) || ((_e = result == null ? void 0 : result.data) == null ? void 0 : _e.result) || (result == null ? void 0 : result.data) || result;
|
|
3891
|
+
setHierarchyNodes(Array.isArray(value) ? value : (value == null ? void 0 : value.items) || (value == null ? void 0 : value.records) || []);
|
|
3892
|
+
} catch (error) {
|
|
3893
|
+
setHierarchyNodes([]);
|
|
3894
|
+
setHierarchyNodesError(((_g = (_f = error == null ? void 0 : error.response) == null ? void 0 : _f.data) == null ? void 0 : _g.message) || (error == null ? void 0 : error.message) || "Unable to load hierarchy nodes.");
|
|
3895
|
+
} finally {
|
|
3896
|
+
setIsLoadingHierarchyNodes(false);
|
|
3897
|
+
}
|
|
3898
|
+
};
|
|
3899
|
+
loadHierarchyNodes();
|
|
3900
|
+
}, [isOpen]);
|
|
3877
3901
|
const handleChange = (event) => setFormData((previous) => __spreadProps(__spreadValues({}, previous), { [event.target.name]: event.target.value }));
|
|
3878
3902
|
const handleSave = async () => {
|
|
3879
3903
|
if (!onSave) return;
|
|
@@ -3925,8 +3949,14 @@ function AddUserHierarchyNodeMappingModal({
|
|
|
3925
3949
|
"Hierarchy Node ID ",
|
|
3926
3950
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("span", { className: "fc:text-red-500", children: "*" })
|
|
3927
3951
|
] }),
|
|
3928
|
-
/* @__PURE__ */ (0, import_jsx_runtime22.
|
|
3929
|
-
|
|
3952
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("select", { name: "hierarchyNodeId", value: formData.hierarchyNodeId, onChange: handleChange, disabled: isLoadingHierarchyNodes, className: "fc:w-full fc:p-2.5 fc:border fc:border-slate-200 fc:rounded-xl fc:text-xs fc:bg-white fc:text-slate-700 disabled:fc:fc:bg-slate-100 disabled:fc:fc:cursor-not-allowed focus:fc:fc:outline-none focus:fc:fc:ring-2 focus:fc:fc:ring-indigo-500/10 focus:fc:fc:border-indigo-500", children: [
|
|
3953
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("option", { value: "", children: isLoadingHierarchyNodes ? "Loading hierarchy nodes..." : "Select hierarchy node" }),
|
|
3954
|
+
hierarchyNodes.map((node) => /* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("option", { value: node.hierarchyNodeId, children: [
|
|
3955
|
+
node.hierarchyNodeId,
|
|
3956
|
+
node.nodeName ? ` - ${node.nodeName}` : ""
|
|
3957
|
+
] }, node.hierarchyNodeId))
|
|
3958
|
+
] }),
|
|
3959
|
+
/* @__PURE__ */ (0, import_jsx_runtime22.jsx)("p", { className: `fc:text-[10px] fc:mt-1 ${hierarchyNodesError ? "fc:text-red-500" : "fc:text-slate-400"}`, children: hierarchyNodesError || "Select the hierarchy node assigned to the user" })
|
|
3930
3960
|
] }),
|
|
3931
3961
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { className: "fc:grid fc:grid-cols-2 fc:gap-5", children: [
|
|
3932
3962
|
/* @__PURE__ */ (0, import_jsx_runtime22.jsxs)("div", { children: [
|
|
@@ -4426,7 +4456,7 @@ function User_hierarchy_mapping_main() {
|
|
|
4426
4456
|
(async () => {
|
|
4427
4457
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
4428
4458
|
try {
|
|
4429
|
-
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.
|
|
4459
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.WorkflowStepUserMapping) == null ? void 0 : _c.getList;
|
|
4430
4460
|
if (!endpoint) throw new Error("User hierarchy node mapping list endpoint is not configured.");
|
|
4431
4461
|
const result = await getApiService().post(endpoint, {});
|
|
4432
4462
|
const value = ((_d = result == null ? void 0 : result.data) == null ? void 0 : _d.data) || ((_e = result == null ? void 0 : result.data) == null ? void 0 : _e.result) || (result == null ? void 0 : result.data) || result;
|
|
@@ -4452,7 +4482,7 @@ function User_hierarchy_mapping_main() {
|
|
|
4452
4482
|
const saveMapping = async (payload, isEdit = false) => {
|
|
4453
4483
|
var _a, _b, _c, _d, _e;
|
|
4454
4484
|
try {
|
|
4455
|
-
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.
|
|
4485
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.WorkflowStepUserMapping) == null ? void 0 : _c[isEdit ? "update" : "create"];
|
|
4456
4486
|
if (!endpoint) throw new Error(`User hierarchy node mapping ${isEdit ? "update" : "create"} endpoint is not configured.`);
|
|
4457
4487
|
await getApiService()[isEdit ? "put" : "post"](endpoint, payload);
|
|
4458
4488
|
await import_sweetalert29.default.fire("Success", `User hierarchy node mapping ${isEdit ? "updated" : "created"} successfully.`, "success");
|
|
@@ -12694,7 +12724,7 @@ function Sidebar({
|
|
|
12694
12724
|
const Icon = item.icon;
|
|
12695
12725
|
const handleClick = () => {
|
|
12696
12726
|
if (item.component) {
|
|
12697
|
-
router.push("/
|
|
12727
|
+
router.push("/", void 0, {
|
|
12698
12728
|
shallow: true
|
|
12699
12729
|
});
|
|
12700
12730
|
setActiveComponent(item.component);
|
package/dist/pkg-index.mjs
CHANGED
|
@@ -3825,11 +3825,11 @@ function WorkFlowTransition() {
|
|
|
3825
3825
|
}
|
|
3826
3826
|
|
|
3827
3827
|
// src/components/user-hierarchy-node-mapping/user_hierarachy_node_main.jsx
|
|
3828
|
-
import React27, { useState as useState19, useRef as useRef6, useEffect as
|
|
3828
|
+
import React27, { useState as useState19, useRef as useRef6, useEffect as useEffect15 } from "react";
|
|
3829
3829
|
import Swal9 from "sweetalert2";
|
|
3830
3830
|
|
|
3831
3831
|
// src/components/user-hierarchy-node-mapping/adduserhierarchynode.jsx
|
|
3832
|
-
import React22, { useState as useState16 } from "react";
|
|
3832
|
+
import React22, { useEffect as useEffect12, useState as useState16 } from "react";
|
|
3833
3833
|
import { jsx as jsx22, jsxs as jsxs21 } from "react/jsx-runtime";
|
|
3834
3834
|
function AddUserHierarchyNodeMappingModal({
|
|
3835
3835
|
isOpen,
|
|
@@ -3838,6 +3838,30 @@ function AddUserHierarchyNodeMappingModal({
|
|
|
3838
3838
|
}) {
|
|
3839
3839
|
const [formData, setFormData] = useState16({ mappingId: "", externalUserId: "", hierarchyNodeId: "", roleCode: "", isPrimary: "", effectiveFrom: "", effectiveTo: "" });
|
|
3840
3840
|
const [isSubmitting, setIsSubmitting] = useState16(false);
|
|
3841
|
+
const [hierarchyNodes, setHierarchyNodes] = useState16([]);
|
|
3842
|
+
const [isLoadingHierarchyNodes, setIsLoadingHierarchyNodes] = useState16(false);
|
|
3843
|
+
const [hierarchyNodesError, setHierarchyNodesError] = useState16("");
|
|
3844
|
+
useEffect12(() => {
|
|
3845
|
+
if (!isOpen) return;
|
|
3846
|
+
const loadHierarchyNodes = async () => {
|
|
3847
|
+
var _a, _b, _c, _d, _e, _f, _g;
|
|
3848
|
+
setIsLoadingHierarchyNodes(true);
|
|
3849
|
+
setHierarchyNodesError("");
|
|
3850
|
+
try {
|
|
3851
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.hierarchyNode) == null ? void 0 : _c.getList;
|
|
3852
|
+
if (!endpoint) throw new Error("Hierarchy node list endpoint is not configured.");
|
|
3853
|
+
const result = await getApiService().get(endpoint);
|
|
3854
|
+
const value = ((_d = result == null ? void 0 : result.data) == null ? void 0 : _d.data) || ((_e = result == null ? void 0 : result.data) == null ? void 0 : _e.result) || (result == null ? void 0 : result.data) || result;
|
|
3855
|
+
setHierarchyNodes(Array.isArray(value) ? value : (value == null ? void 0 : value.items) || (value == null ? void 0 : value.records) || []);
|
|
3856
|
+
} catch (error) {
|
|
3857
|
+
setHierarchyNodes([]);
|
|
3858
|
+
setHierarchyNodesError(((_g = (_f = error == null ? void 0 : error.response) == null ? void 0 : _f.data) == null ? void 0 : _g.message) || (error == null ? void 0 : error.message) || "Unable to load hierarchy nodes.");
|
|
3859
|
+
} finally {
|
|
3860
|
+
setIsLoadingHierarchyNodes(false);
|
|
3861
|
+
}
|
|
3862
|
+
};
|
|
3863
|
+
loadHierarchyNodes();
|
|
3864
|
+
}, [isOpen]);
|
|
3841
3865
|
const handleChange = (event) => setFormData((previous) => __spreadProps(__spreadValues({}, previous), { [event.target.name]: event.target.value }));
|
|
3842
3866
|
const handleSave = async () => {
|
|
3843
3867
|
if (!onSave) return;
|
|
@@ -3889,8 +3913,14 @@ function AddUserHierarchyNodeMappingModal({
|
|
|
3889
3913
|
"Hierarchy Node ID ",
|
|
3890
3914
|
/* @__PURE__ */ jsx22("span", { className: "fc:text-red-500", children: "*" })
|
|
3891
3915
|
] }),
|
|
3892
|
-
/* @__PURE__ */
|
|
3893
|
-
|
|
3916
|
+
/* @__PURE__ */ jsxs21("select", { name: "hierarchyNodeId", value: formData.hierarchyNodeId, onChange: handleChange, disabled: isLoadingHierarchyNodes, className: "fc:w-full fc:p-2.5 fc:border fc:border-slate-200 fc:rounded-xl fc:text-xs fc:bg-white fc:text-slate-700 disabled:fc:fc:bg-slate-100 disabled:fc:fc:cursor-not-allowed focus:fc:fc:outline-none focus:fc:fc:ring-2 focus:fc:fc:ring-indigo-500/10 focus:fc:fc:border-indigo-500", children: [
|
|
3917
|
+
/* @__PURE__ */ jsx22("option", { value: "", children: isLoadingHierarchyNodes ? "Loading hierarchy nodes..." : "Select hierarchy node" }),
|
|
3918
|
+
hierarchyNodes.map((node) => /* @__PURE__ */ jsxs21("option", { value: node.hierarchyNodeId, children: [
|
|
3919
|
+
node.hierarchyNodeId,
|
|
3920
|
+
node.nodeName ? ` - ${node.nodeName}` : ""
|
|
3921
|
+
] }, node.hierarchyNodeId))
|
|
3922
|
+
] }),
|
|
3923
|
+
/* @__PURE__ */ jsx22("p", { className: `fc:text-[10px] fc:mt-1 ${hierarchyNodesError ? "fc:text-red-500" : "fc:text-slate-400"}`, children: hierarchyNodesError || "Select the hierarchy node assigned to the user" })
|
|
3894
3924
|
] }),
|
|
3895
3925
|
/* @__PURE__ */ jsxs21("div", { className: "fc:grid fc:grid-cols-2 fc:gap-5", children: [
|
|
3896
3926
|
/* @__PURE__ */ jsxs21("div", { children: [
|
|
@@ -3970,10 +4000,10 @@ function MappingSearchBar({
|
|
|
3970
4000
|
}
|
|
3971
4001
|
|
|
3972
4002
|
// src/components/user-hierarchy-node-mapping/userhierarchynodetable.jsx
|
|
3973
|
-
import React26, { useState as useState18, useEffect as
|
|
4003
|
+
import React26, { useState as useState18, useEffect as useEffect14 } from "react";
|
|
3974
4004
|
|
|
3975
4005
|
// src/components/user-hierarchy-node-mapping/edit-mapping.jsx
|
|
3976
|
-
import React24, { useEffect as
|
|
4006
|
+
import React24, { useEffect as useEffect13, useState as useState17 } from "react";
|
|
3977
4007
|
import { jsx as jsx24, jsxs as jsxs23 } from "react/jsx-runtime";
|
|
3978
4008
|
function EditUserHierarchyNodeMappingModal({
|
|
3979
4009
|
isOpen,
|
|
@@ -3988,7 +4018,7 @@ function EditUserHierarchyNodeMappingModal({
|
|
|
3988
4018
|
effectiveFrom: "",
|
|
3989
4019
|
effectiveTo: ""
|
|
3990
4020
|
});
|
|
3991
|
-
|
|
4021
|
+
useEffect13(() => {
|
|
3992
4022
|
if (selectedMapping) {
|
|
3993
4023
|
setFormData({
|
|
3994
4024
|
hierarchyNodeId: selectedMapping.hierarchyNodeId || "",
|
|
@@ -4236,7 +4266,7 @@ function UserHierarchyNodeMappingTable({
|
|
|
4236
4266
|
onDelete
|
|
4237
4267
|
}) {
|
|
4238
4268
|
const [data, setData] = useState18(apiData || []);
|
|
4239
|
-
|
|
4269
|
+
useEffect14(() => {
|
|
4240
4270
|
setData(apiData || []);
|
|
4241
4271
|
}, [apiData]);
|
|
4242
4272
|
const [sortOrder, setSortOrder] = useState18("asc");
|
|
@@ -4256,7 +4286,7 @@ function UserHierarchyNodeMappingTable({
|
|
|
4256
4286
|
const query = (searchQuery || "").toLowerCase();
|
|
4257
4287
|
return String(item.mappingId).toLowerCase().includes(query) || String(item.externalUserId).toLowerCase().includes(query) || String(item.hierarchyNodeId).toLowerCase().includes(query) || item.roleCode.toLowerCase().includes(query);
|
|
4258
4288
|
});
|
|
4259
|
-
|
|
4289
|
+
useEffect14(() => {
|
|
4260
4290
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
4261
4291
|
}, [filteredData.length, setTotalEntries]);
|
|
4262
4292
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -4386,11 +4416,11 @@ import { jsx as jsx27, jsxs as jsxs26 } from "react/jsx-runtime";
|
|
|
4386
4416
|
function User_hierarchy_mapping_main() {
|
|
4387
4417
|
const [refreshkey, setRefreshKey] = useState19(0);
|
|
4388
4418
|
const [apiData, setApiData] = useState19([]);
|
|
4389
|
-
|
|
4419
|
+
useEffect15(() => {
|
|
4390
4420
|
(async () => {
|
|
4391
4421
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
4392
4422
|
try {
|
|
4393
|
-
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.
|
|
4423
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.WorkflowStepUserMapping) == null ? void 0 : _c.getList;
|
|
4394
4424
|
if (!endpoint) throw new Error("User hierarchy node mapping list endpoint is not configured.");
|
|
4395
4425
|
const result = await getApiService().post(endpoint, {});
|
|
4396
4426
|
const value = ((_d = result == null ? void 0 : result.data) == null ? void 0 : _d.data) || ((_e = result == null ? void 0 : result.data) == null ? void 0 : _e.result) || (result == null ? void 0 : result.data) || result;
|
|
@@ -4416,7 +4446,7 @@ function User_hierarchy_mapping_main() {
|
|
|
4416
4446
|
const saveMapping = async (payload, isEdit = false) => {
|
|
4417
4447
|
var _a, _b, _c, _d, _e;
|
|
4418
4448
|
try {
|
|
4419
|
-
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.
|
|
4449
|
+
const endpoint = (_c = (_b = (_a = getApiEndpoints()) == null ? void 0 : _a.flowCore) == null ? void 0 : _b.WorkflowStepUserMapping) == null ? void 0 : _c[isEdit ? "update" : "create"];
|
|
4420
4450
|
if (!endpoint) throw new Error(`User hierarchy node mapping ${isEdit ? "update" : "create"} endpoint is not configured.`);
|
|
4421
4451
|
await getApiService()[isEdit ? "put" : "post"](endpoint, payload);
|
|
4422
4452
|
await Swal9.fire("Success", `User hierarchy node mapping ${isEdit ? "updated" : "created"} successfully.`, "success");
|
|
@@ -4484,10 +4514,10 @@ function SearchBar3({
|
|
|
4484
4514
|
}
|
|
4485
4515
|
|
|
4486
4516
|
// src/components/document-configuration/DocumentConfigurationTable.jsx
|
|
4487
|
-
import React31, { useState as useState21, useEffect as
|
|
4517
|
+
import React31, { useState as useState21, useEffect as useEffect17 } from "react";
|
|
4488
4518
|
|
|
4489
4519
|
// src/components/document-configuration/Edit.jsx
|
|
4490
|
-
import React29, { useState as useState20, useEffect as
|
|
4520
|
+
import React29, { useState as useState20, useEffect as useEffect16 } from "react";
|
|
4491
4521
|
import { jsx as jsx29, jsxs as jsxs28 } from "react/jsx-runtime";
|
|
4492
4522
|
function EditDocumentConfiguration({
|
|
4493
4523
|
isOpen,
|
|
@@ -4505,7 +4535,7 @@ function EditDocumentConfiguration({
|
|
|
4505
4535
|
status: "Active"
|
|
4506
4536
|
});
|
|
4507
4537
|
const [errors, setErrors] = useState20({});
|
|
4508
|
-
|
|
4538
|
+
useEffect16(() => {
|
|
4509
4539
|
if (initialData) {
|
|
4510
4540
|
const sizeParts = (initialData.maxSize || "10 MB").split(" ");
|
|
4511
4541
|
setFormData({
|
|
@@ -4935,7 +4965,7 @@ function DocumentConfigTable({
|
|
|
4935
4965
|
const query = (searchQuery || "").toLowerCase();
|
|
4936
4966
|
return item.docName.toLowerCase().includes(query) || item.extensions.toLowerCase().includes(query) || item.stepId.toLowerCase().includes(query);
|
|
4937
4967
|
});
|
|
4938
|
-
|
|
4968
|
+
useEffect17(() => {
|
|
4939
4969
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
4940
4970
|
}, [filteredData.length, setTotalEntries]);
|
|
4941
4971
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -5356,7 +5386,7 @@ function SearchBar4({
|
|
|
5356
5386
|
}
|
|
5357
5387
|
|
|
5358
5388
|
// src/components/audit-log/AuditLogTable.jsx
|
|
5359
|
-
import React35, { useState as useState24, useEffect as
|
|
5389
|
+
import React35, { useState as useState24, useEffect as useEffect18 } from "react";
|
|
5360
5390
|
import { jsx as jsx35, jsxs as jsxs34 } from "react/jsx-runtime";
|
|
5361
5391
|
function AuditLogTable({
|
|
5362
5392
|
pageSize,
|
|
@@ -5584,7 +5614,7 @@ function AuditLogTable({
|
|
|
5584
5614
|
const query = (searchQuery || "").toLowerCase();
|
|
5585
5615
|
return item.logId.toLowerCase().includes(query) || item.user.toLowerCase().includes(query) || item.section.toLowerCase().includes(query) || item.action.toLowerCase().includes(query);
|
|
5586
5616
|
});
|
|
5587
|
-
|
|
5617
|
+
useEffect18(() => {
|
|
5588
5618
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
5589
5619
|
}, [filteredData.length, setTotalEntries]);
|
|
5590
5620
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -5872,7 +5902,7 @@ function SearchBar5({
|
|
|
5872
5902
|
}
|
|
5873
5903
|
|
|
5874
5904
|
// src/components/movement-history/MovementHistoryTable.jsx
|
|
5875
|
-
import React39, { useState as useState27, useEffect as
|
|
5905
|
+
import React39, { useState as useState27, useEffect as useEffect19 } from "react";
|
|
5876
5906
|
import { jsx as jsx39, jsxs as jsxs38 } from "react/jsx-runtime";
|
|
5877
5907
|
function MovementHistoryTable({
|
|
5878
5908
|
pageSize,
|
|
@@ -6100,7 +6130,7 @@ function MovementHistoryTable({
|
|
|
6100
6130
|
const query = (searchQuery || "").toLowerCase();
|
|
6101
6131
|
return item.movementHistoryId.toLowerCase().includes(query) || item.name.toLowerCase().includes(query) || item.toStepId.toLowerCase().includes(query);
|
|
6102
6132
|
});
|
|
6103
|
-
|
|
6133
|
+
useEffect19(() => {
|
|
6104
6134
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
6105
6135
|
}, [filteredData.length, setTotalEntries]);
|
|
6106
6136
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -6383,7 +6413,7 @@ function SearchBar6({
|
|
|
6383
6413
|
}
|
|
6384
6414
|
|
|
6385
6415
|
// src/components/task-permission/Table.js
|
|
6386
|
-
import React43, { useState as useState30, useEffect as
|
|
6416
|
+
import React43, { useState as useState30, useEffect as useEffect20 } from "react";
|
|
6387
6417
|
import { jsx as jsx43, jsxs as jsxs42 } from "react/jsx-runtime";
|
|
6388
6418
|
function Table({
|
|
6389
6419
|
pageSize,
|
|
@@ -6411,7 +6441,7 @@ function Table({
|
|
|
6411
6441
|
});
|
|
6412
6442
|
return map;
|
|
6413
6443
|
}, [workflowSteps]);
|
|
6414
|
-
|
|
6444
|
+
useEffect20(() => {
|
|
6415
6445
|
(async () => {
|
|
6416
6446
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t;
|
|
6417
6447
|
try {
|
|
@@ -6462,7 +6492,7 @@ function Table({
|
|
|
6462
6492
|
const totalPages = Math.max(Math.ceil(sorted.length / pageSize), 1);
|
|
6463
6493
|
const startIndex = (currentPage - 1) * pageSize;
|
|
6464
6494
|
const visibleData = sorted.slice(startIndex, startIndex + pageSize);
|
|
6465
|
-
|
|
6495
|
+
useEffect20(() => {
|
|
6466
6496
|
if (setTotalEntries) setTotalEntries(filtered.length);
|
|
6467
6497
|
}, [filtered.length]);
|
|
6468
6498
|
const pageNumbers = Array.from({ length: totalPages }, (_, i) => i + 1);
|
|
@@ -6620,7 +6650,7 @@ function Table({
|
|
|
6620
6650
|
}
|
|
6621
6651
|
|
|
6622
6652
|
// src/components/task-permission/Popup.js
|
|
6623
|
-
import React44, { useState as useState31, useEffect as
|
|
6653
|
+
import React44, { useState as useState31, useEffect as useEffect21 } from "react";
|
|
6624
6654
|
import Swal10 from "sweetalert2";
|
|
6625
6655
|
import { jsx as jsx44, jsxs as jsxs43 } from "react/jsx-runtime";
|
|
6626
6656
|
function Popup({ isOpen, onClose, onSave }) {
|
|
@@ -6635,7 +6665,7 @@ function Popup({ isOpen, onClose, onSave }) {
|
|
|
6635
6665
|
const [isSubmitting, setIsSubmitting] = useState31(false);
|
|
6636
6666
|
const [workflowSteps, setWorkflowSteps] = useState31([]);
|
|
6637
6667
|
const [loadingSteps, setLoadingSteps] = useState31(false);
|
|
6638
|
-
|
|
6668
|
+
useEffect21(() => {
|
|
6639
6669
|
if (!isOpen) return;
|
|
6640
6670
|
(async () => {
|
|
6641
6671
|
var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
@@ -6653,7 +6683,7 @@ function Popup({ isOpen, onClose, onSave }) {
|
|
|
6653
6683
|
}
|
|
6654
6684
|
})();
|
|
6655
6685
|
}, [isOpen]);
|
|
6656
|
-
|
|
6686
|
+
useEffect21(() => {
|
|
6657
6687
|
if (!isOpen) {
|
|
6658
6688
|
setFormData({ workflowStepId: "", canView: false, canEdit: false, canApprove: false, canReject: false });
|
|
6659
6689
|
setErrors({});
|
|
@@ -6813,7 +6843,7 @@ function Popup({ isOpen, onClose, onSave }) {
|
|
|
6813
6843
|
}
|
|
6814
6844
|
|
|
6815
6845
|
// src/components/task-permission/EditTaskPermissionModal.js
|
|
6816
|
-
import React45, { useState as useState32, useEffect as
|
|
6846
|
+
import React45, { useState as useState32, useEffect as useEffect22 } from "react";
|
|
6817
6847
|
import { jsx as jsx45, jsxs as jsxs44 } from "react/jsx-runtime";
|
|
6818
6848
|
function EditTaskPermissionModal({ isOpen, onClose, onSave, selectedData, onUpdate }) {
|
|
6819
6849
|
var _a;
|
|
@@ -6830,7 +6860,7 @@ function EditTaskPermissionModal({ isOpen, onClose, onSave, selectedData, onUpda
|
|
|
6830
6860
|
const [isSubmitting, setIsSubmitting] = useState32(false);
|
|
6831
6861
|
const [workflowSteps, setWorkflowSteps] = useState32([]);
|
|
6832
6862
|
const [loadingSteps, setLoadingSteps] = useState32(false);
|
|
6833
|
-
|
|
6863
|
+
useEffect22(() => {
|
|
6834
6864
|
if (!isOpen) return;
|
|
6835
6865
|
(async () => {
|
|
6836
6866
|
var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j;
|
|
@@ -6848,7 +6878,7 @@ function EditTaskPermissionModal({ isOpen, onClose, onSave, selectedData, onUpda
|
|
|
6848
6878
|
}
|
|
6849
6879
|
})();
|
|
6850
6880
|
}, [isOpen]);
|
|
6851
|
-
|
|
6881
|
+
useEffect22(() => {
|
|
6852
6882
|
var _a2, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n;
|
|
6853
6883
|
if (selectedData) {
|
|
6854
6884
|
setFormData({
|
|
@@ -7212,7 +7242,7 @@ function SearchBar7({
|
|
|
7212
7242
|
}
|
|
7213
7243
|
|
|
7214
7244
|
// src/components/Workflow-Setting/Table.js
|
|
7215
|
-
import React48, { useState as useState34, useEffect as
|
|
7245
|
+
import React48, { useState as useState34, useEffect as useEffect23 } from "react";
|
|
7216
7246
|
import { jsx as jsx48, jsxs as jsxs47 } from "react/jsx-runtime";
|
|
7217
7247
|
function Table2({
|
|
7218
7248
|
pageSize,
|
|
@@ -7459,7 +7489,7 @@ function Table2({
|
|
|
7459
7489
|
}
|
|
7460
7490
|
return item.settingId && item.settingId.toString().toLowerCase().includes(query) || item.moduleName && item.moduleName.toLowerCase().includes(query) || item.executionOrder && item.executionOrder.toString().toLowerCase().includes(query) || item.SLA && item.SLA.toLowerCase().includes(query);
|
|
7461
7491
|
});
|
|
7462
|
-
|
|
7492
|
+
useEffect23(() => {
|
|
7463
7493
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
7464
7494
|
}, [filteredData.length, setTotalEntries]);
|
|
7465
7495
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -7735,7 +7765,7 @@ function SearchBar8({
|
|
|
7735
7765
|
}
|
|
7736
7766
|
|
|
7737
7767
|
// src/components/notification/Table.js
|
|
7738
|
-
import React52, { useState as useState37, useEffect as
|
|
7768
|
+
import React52, { useState as useState37, useEffect as useEffect24 } from "react";
|
|
7739
7769
|
import { jsx as jsx52, jsxs as jsxs51 } from "react/jsx-runtime";
|
|
7740
7770
|
function Table3({
|
|
7741
7771
|
pageSize,
|
|
@@ -7982,7 +8012,7 @@ function Table3({
|
|
|
7982
8012
|
}
|
|
7983
8013
|
return item.notificationId && item.notificationId.toString().toLowerCase().includes(query) || item.eventTrigger && item.eventTrigger.toLowerCase().includes(query) || item.channelType && item.channelType.toLowerCase().includes(query) || item.recipientGroup && item.recipientGroup.toLowerCase().includes(query);
|
|
7984
8014
|
});
|
|
7985
|
-
|
|
8015
|
+
useEffect24(() => {
|
|
7986
8016
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
7987
8017
|
}, [filteredData.length, setTotalEntries]);
|
|
7988
8018
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -8268,10 +8298,10 @@ function TaskInstanceSearchBar({
|
|
|
8268
8298
|
}
|
|
8269
8299
|
|
|
8270
8300
|
// src/components/task-instance/taskinstancetable.jsx
|
|
8271
|
-
import React58, { useState as useState41, useEffect as
|
|
8301
|
+
import React58, { useState as useState41, useEffect as useEffect26 } from "react";
|
|
8272
8302
|
|
|
8273
8303
|
// src/components/task-instance/edit-instance.jsx
|
|
8274
|
-
import React56, { useEffect as
|
|
8304
|
+
import React56, { useEffect as useEffect25, useState as useState40 } from "react";
|
|
8275
8305
|
import { jsx as jsx56, jsxs as jsxs55 } from "react/jsx-runtime";
|
|
8276
8306
|
function EditTaskInstanceModal({
|
|
8277
8307
|
isOpen,
|
|
@@ -8287,7 +8317,7 @@ function EditTaskInstanceModal({
|
|
|
8287
8317
|
escalatedOn: "",
|
|
8288
8318
|
slaStatus: ""
|
|
8289
8319
|
});
|
|
8290
|
-
|
|
8320
|
+
useEffect25(() => {
|
|
8291
8321
|
if (selectedTask) {
|
|
8292
8322
|
setFormData({
|
|
8293
8323
|
assignedUserId: selectedTask.assignedUserId || selectedTask.assigned_user_id || "",
|
|
@@ -8808,7 +8838,7 @@ function TaskInstanceTable({
|
|
|
8808
8838
|
const query = (searchQuery || "").toLowerCase();
|
|
8809
8839
|
return String(item.taskInstanceId).includes(query) || String(item.fileInstanceId).includes(query) || String(item.workflowStepId).includes(query) || String(item.assignedUserId).includes(query) || item.status.toLowerCase().includes(query);
|
|
8810
8840
|
});
|
|
8811
|
-
|
|
8841
|
+
useEffect26(() => {
|
|
8812
8842
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
8813
8843
|
}, [filteredData.length, setTotalEntries]);
|
|
8814
8844
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -9177,7 +9207,7 @@ function CommentSearchBar({
|
|
|
9177
9207
|
}
|
|
9178
9208
|
|
|
9179
9209
|
// src/components/comment/commenttable.jsx
|
|
9180
|
-
import React62, { useState as useState43, useEffect as
|
|
9210
|
+
import React62, { useState as useState43, useEffect as useEffect27 } from "react";
|
|
9181
9211
|
import { jsx as jsx62, jsxs as jsxs61 } from "react/jsx-runtime";
|
|
9182
9212
|
function CommentTable({
|
|
9183
9213
|
pageSize,
|
|
@@ -9405,7 +9435,7 @@ function CommentTable({
|
|
|
9405
9435
|
const query = (searchQuery || "").toLowerCase();
|
|
9406
9436
|
return String(item.commentId).toLowerCase().includes(query) || String(item.taskInstanceId).toLowerCase().includes(query) || item.comment.toLowerCase().includes(query) || String(item.commentedBy).toLowerCase().includes(query);
|
|
9407
9437
|
});
|
|
9408
|
-
|
|
9438
|
+
useEffect27(() => {
|
|
9409
9439
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
9410
9440
|
}, [filteredData.length, setTotalEntries]);
|
|
9411
9441
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -9740,7 +9770,7 @@ function Comment_main() {
|
|
|
9740
9770
|
}
|
|
9741
9771
|
|
|
9742
9772
|
// src/components/hierarchy-node/HierarchyNodeMain.jsx
|
|
9743
|
-
import React70, { useState as useState49, useRef as useRef15, useEffect as
|
|
9773
|
+
import React70, { useState as useState49, useRef as useRef15, useEffect as useEffect30 } from "react";
|
|
9744
9774
|
import Swal12 from "sweetalert2";
|
|
9745
9775
|
|
|
9746
9776
|
// src/components/hierarchy-node/SearchBar.jsx
|
|
@@ -9780,10 +9810,10 @@ function SearchBar9({ searchQuery, setSearchQuery }) {
|
|
|
9780
9810
|
}
|
|
9781
9811
|
|
|
9782
9812
|
// src/components/hierarchy-node/HierarchyTable.jsx
|
|
9783
|
-
import React68, { useState as useState47, useEffect as
|
|
9813
|
+
import React68, { useState as useState47, useEffect as useEffect29 } from "react";
|
|
9784
9814
|
|
|
9785
9815
|
// src/components/hierarchy-node/AddEditModal.jsx
|
|
9786
|
-
import React66, { useEffect as
|
|
9816
|
+
import React66, { useEffect as useEffect28, useState as useState46 } from "react";
|
|
9787
9817
|
import { jsx as jsx66, jsxs as jsxs65 } from "react/jsx-runtime";
|
|
9788
9818
|
function AddEditModal({
|
|
9789
9819
|
isOpen,
|
|
@@ -9801,7 +9831,7 @@ function AddEditModal({
|
|
|
9801
9831
|
externalEntityId: "",
|
|
9802
9832
|
isActive: true
|
|
9803
9833
|
});
|
|
9804
|
-
|
|
9834
|
+
useEffect28(() => {
|
|
9805
9835
|
if (editData) {
|
|
9806
9836
|
setFormData(editData);
|
|
9807
9837
|
}
|
|
@@ -10024,7 +10054,7 @@ function HierarchyTable({
|
|
|
10024
10054
|
const [currentPage, setCurrentPage] = useState47(1);
|
|
10025
10055
|
;
|
|
10026
10056
|
const [data, setData] = useState47(apiData || []);
|
|
10027
|
-
|
|
10057
|
+
useEffect29(() => {
|
|
10028
10058
|
setData(apiData || []);
|
|
10029
10059
|
}, [apiData]);
|
|
10030
10060
|
const filteredData = data.filter(
|
|
@@ -10041,7 +10071,7 @@ function HierarchyTable({
|
|
|
10041
10071
|
const [editOpen, setEditOpen] = useState47(false);
|
|
10042
10072
|
const [deleteOpen, setDeleteOpen] = useState47(false);
|
|
10043
10073
|
const [selectedNode, setSelectedNode] = useState47(null);
|
|
10044
|
-
|
|
10074
|
+
useEffect29(() => {
|
|
10045
10075
|
setCurrentPage(1);
|
|
10046
10076
|
}, [searchQuery, pageSize]);
|
|
10047
10077
|
const handleSort = (column) => {
|
|
@@ -10335,7 +10365,7 @@ function HierarchyNodeMain() {
|
|
|
10335
10365
|
const [searchQuery, setSearchQuery] = useState49("");
|
|
10336
10366
|
const [apiData, setApiData] = useState49([]);
|
|
10337
10367
|
const [refreshKey, setRefreshKey] = useState49(0);
|
|
10338
|
-
|
|
10368
|
+
useEffect30(() => {
|
|
10339
10369
|
(async () => {
|
|
10340
10370
|
var _a, _b, _c, _d, _e, _f, _g;
|
|
10341
10371
|
try {
|
|
@@ -12105,7 +12135,7 @@ function SearchBar12({
|
|
|
12105
12135
|
}
|
|
12106
12136
|
|
|
12107
12137
|
// src/components/assignment-rule/Table.js
|
|
12108
|
-
import React84, { useState as useState58, useEffect as
|
|
12138
|
+
import React84, { useState as useState58, useEffect as useEffect31 } from "react";
|
|
12109
12139
|
import { jsx as jsx84, jsxs as jsxs83 } from "react/jsx-runtime";
|
|
12110
12140
|
function Table4({
|
|
12111
12141
|
pageSize,
|
|
@@ -12271,7 +12301,7 @@ function Table4({
|
|
|
12271
12301
|
const query = searchQuery.toLowerCase().trim();
|
|
12272
12302
|
return item.workflowStepId && item.workflowStepId.toString().toLowerCase().includes(query) || item.assignmentType && item.assignmentType.toLowerCase().includes(query) || item.hierarchyNodeType && item.hierarchyNodeType.toLowerCase().includes(query) || item.dynamicFunctionId && item.dynamicFunctionId.toString().toLowerCase().includes(query);
|
|
12273
12303
|
});
|
|
12274
|
-
|
|
12304
|
+
useEffect31(() => {
|
|
12275
12305
|
if (setTotalEntries) setTotalEntries(filteredData.length);
|
|
12276
12306
|
}, [filteredData.length, setTotalEntries]);
|
|
12277
12307
|
const totalPages = Math.ceil(filteredData.length / pageSize) || 1;
|
|
@@ -12658,7 +12688,7 @@ function Sidebar({
|
|
|
12658
12688
|
const Icon = item.icon;
|
|
12659
12689
|
const handleClick = () => {
|
|
12660
12690
|
if (item.component) {
|
|
12661
|
-
router.push("/
|
|
12691
|
+
router.push("/", void 0, {
|
|
12662
12692
|
shallow: true
|
|
12663
12693
|
});
|
|
12664
12694
|
setActiveComponent(item.component);
|