@mseva/upyog-ui-module-asset 1.1.44 → 1.1.45

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.
@@ -15038,6 +15038,7 @@ const getTimelineAcknowledgementData = (workflowDetails, tenantInfo, pdfFiles =
15038
15038
  const formats = (downloadLink === null || downloadLink === void 0 ? void 0 : (_downloadLink$split = downloadLink.split(",")) === null || _downloadLink$split === void 0 ? void 0 : _downloadLink$split.filter(Boolean)) || [];
15039
15039
  return (formats === null || formats === void 0 ? void 0 : formats.find(link => !(link !== null && link !== void 0 && link.includes("large")) && !(link !== null && link !== void 0 && link.includes("medium")) && !(link !== null && link !== void 0 && link.includes("small")))) || (formats === null || formats === void 0 ? void 0 : formats[0]) || "";
15040
15040
  };
15041
+ const pattern = /\[#\?.*?\*\*\]/;
15041
15042
  const timelineRows = timeline.map((item, index) => {
15042
15043
  var _item$auditDetails, _item$auditDetails2, _item$assigner, _item$assigner2, _item$assigner3, _item$wfComment;
15043
15044
  const createdDate = (item === null || item === void 0 ? void 0 : (_item$auditDetails = item.auditDetails) === null || _item$auditDetails === void 0 ? void 0 : _item$auditDetails.created) || "N/A";
@@ -15047,7 +15048,8 @@ const getTimelineAcknowledgementData = (workflowDetails, tenantInfo, pdfFiles =
15047
15048
  const mobileNumber = (item === null || item === void 0 ? void 0 : (_item$assigner3 = item.assigner) === null || _item$assigner3 === void 0 ? void 0 : _item$assigner3.mobileNumber) || "N/A";
15048
15049
  const action = (item === null || item === void 0 ? void 0 : item.performedAction) || "N/A";
15049
15050
  const status = (item === null || item === void 0 ? void 0 : item.status) || (item === null || item === void 0 ? void 0 : item.state) || "N/A";
15050
- const comment = (item === null || item === void 0 ? void 0 : (_item$wfComment = item.wfComment) === null || _item$wfComment === void 0 ? void 0 : _item$wfComment[0]) || "-";
15051
+ const rawComment = (item === null || item === void 0 ? void 0 : (_item$wfComment = item.wfComment) === null || _item$wfComment === void 0 ? void 0 : _item$wfComment[0]) || "-";
15052
+ const comment = typeof rawComment === "string" ? rawComment.split(pattern)[0] : rawComment;
15051
15053
  const documents = (item === null || item === void 0 ? void 0 : item.wfDocuments) || [];
15052
15054
  const sla = (item === null || item === void 0 ? void 0 : item.sla) || "N/A";
15053
15055
  const assignedTo = Array.isArray(item === null || item === void 0 ? void 0 : item.assignes) ? item.assignes.map(a => a === null || a === void 0 ? void 0 : a.name).filter(Boolean).join(", ") : "";
@@ -15268,7 +15270,9 @@ function NewApplicationTimeline({
15268
15270
  workflowDetails,
15269
15271
  t,
15270
15272
  tenantId = Digit.ULBService.getCurrentTenantId(),
15271
- timeObj
15273
+ timeObj,
15274
+ empUserName = null,
15275
+ handleSetEmpDesignation = () => {}
15272
15276
  }) {
15273
15277
  var _workflowDetails$data, _workflowDetails$data2, _workflowDetails$data3, _workflowDetails$data4, _employeeData$data, _employeeData$data$Em;
15274
15278
  const {
@@ -15343,6 +15347,9 @@ function NewApplicationTimeline({
15343
15347
  const translationKey = `COMMON_MASTERS_DESIGNATION_${assignment === null || assignment === void 0 ? void 0 : assignment.designation}`;
15344
15348
  deptMap[emp === null || emp === void 0 ? void 0 : emp.code] = translationKey;
15345
15349
  });
15350
+ if (employeeData && empUserName) {
15351
+ handleSetEmpDesignation(t(deptMap[empUserName]));
15352
+ }
15346
15353
  if (isLoading) return /*#__PURE__*/React.createElement(Loader, null);
15347
15354
  return /*#__PURE__*/React.createElement(React.Fragment, null, /*#__PURE__*/React.createElement("div", {
15348
15355
  className: "custom-timeline-container"