@undp/carbon-library 1.0.133 → 1.0.134-CARBON-326.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/index.js +14 -2
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +14 -2
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
package/dist/esm/index.js
CHANGED
@@ -18698,12 +18698,18 @@ var NdcActionViewComponent = function (props) {
|
|
18698
18698
|
});
|
18699
18699
|
}); };
|
18700
18700
|
var getProjectReportActions = function (reportData) {
|
18701
|
+
var versionfull = (reportData === null || reportData === void 0 ? void 0 : reportData.url).split("_")[(reportData === null || reportData === void 0 ? void 0 : reportData.url).split("_").length - 1];
|
18702
|
+
var version = versionfull ? versionfull.split(".")[0] : "1";
|
18703
|
+
var Docversion = version.startsWith("V") ? version : "V1";
|
18701
18704
|
return (React.createElement(Row, null,
|
18702
18705
|
React.createElement("div", { className: "icon" },
|
18703
18706
|
(reportData === null || reportData === void 0 ? void 0 : reportData.status) === DocumentStatus.ACCEPTED && (React.createElement(CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })),
|
18704
18707
|
(reportData === null || reportData === void 0 ? void 0 : reportData.status) === DocumentStatus.REJECTED && (React.createElement(ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } }))),
|
18705
18708
|
React.createElement("div", { className: "link mg-left-1" }, (reportData === null || reportData === void 0 ? void 0 : reportData.url) && linkDocVisible(reportData === null || reportData === void 0 ? void 0 : reportData.status) && (React.createElement("a", { href: reportData === null || reportData === void 0 ? void 0 : reportData.url, target: "_blank", rel: "noopener noreferrer", download: true },
|
18706
|
-
React.createElement(LinkOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } }))))
|
18709
|
+
React.createElement(LinkOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } })))),
|
18710
|
+
(reportData === null || reportData === void 0 ? void 0 : reportData.url) !== "" && (React.createElement("div", { className: "time" },
|
18711
|
+
moment(parseInt(reportData === null || reportData === void 0 ? void 0 : reportData.txTime)).format("DD MMMM YYYY @ HH:mm"),
|
18712
|
+
" ~ " + Docversion))));
|
18707
18713
|
};
|
18708
18714
|
var getProjectReports = function () { return __awaiter(void 0, void 0, void 0, function () {
|
18709
18715
|
var reportDetails, response, exception_1;
|
@@ -19216,6 +19222,11 @@ var CreditTransferComponent = function (props) {
|
|
19216
19222
|
}); };
|
19217
19223
|
Form.useForm()[0];
|
19218
19224
|
var Search = Input.Search;
|
19225
|
+
var ministryLevelPermission = function (sectoralScope) {
|
19226
|
+
return ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.MINISTRY &&
|
19227
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) !== Role.ViewOnly &&
|
19228
|
+
ministrySectoralScope.includes(sectoralScope));
|
19229
|
+
};
|
19219
19230
|
var onCheckAllChange = function (e) {
|
19220
19231
|
var nw = e.target.checked ? statusOptions.map(function (el) { return el.value; }) : [];
|
19221
19232
|
setSelectedStatus(nw);
|
@@ -19476,7 +19487,8 @@ var CreditTransferComponent = function (props) {
|
|
19476
19487
|
], renderItem: function (item) { return (React.createElement(List.Item, { onClick: item.click },
|
19477
19488
|
React.createElement(Typography.Text, { className: "action-icon ".concat(item.style) }, item.icon),
|
19478
19489
|
React.createElement("span", null, item.text))); } })) : record.isRetirement &&
|
19479
|
-
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.GOVERNMENT
|
19490
|
+
((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.GOVERNMENT ||
|
19491
|
+
ministryLevelPermission(record.programmeSectoralScope)) ? (React.createElement(List, { className: "action-menu", size: "small", dataSource: [
|
19480
19492
|
{
|
19481
19493
|
text: t("creditTransfer:recognise"),
|
19482
19494
|
icon: React.createElement(Icon.Save, null),
|