@undp/carbon-library 1.0.298-CARBON-300.0 → 1.0.298-CARBON-428-hotfix.0
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/index.js +18 -34
- package/dist/cjs/index.js.map +1 -1
- package/dist/esm/index.js +18 -34
- package/dist/esm/index.js.map +1 -1
- package/package.json +1 -1
package/dist/cjs/index.js
CHANGED
@@ -16266,7 +16266,7 @@ var InvestmentCreationComponent = function (props) {
|
|
16266
16266
|
payload.nationalInvestmentId = investmentData.requestId;
|
16267
16267
|
}
|
16268
16268
|
else {
|
16269
|
-
payload.instrument =
|
16269
|
+
payload.instrument = payload.instrument;
|
16270
16270
|
}
|
16271
16271
|
payload.programmeId = projectData === null || projectData === void 0 ? void 0 : projectData.programmeId;
|
16272
16272
|
payload.fromCompanyIds = projectData === null || projectData === void 0 ? void 0 : projectData.companyId.map(function (e) { return Number(e); });
|
@@ -16276,7 +16276,7 @@ var InvestmentCreationComponent = function (props) {
|
|
16276
16276
|
response = _a.sent();
|
16277
16277
|
return [3 /*break*/, 5];
|
16278
16278
|
case 3:
|
16279
|
-
payload.instrument =
|
16279
|
+
payload.instrument = payload.instrument;
|
16280
16280
|
return [4 /*yield*/, post("national/organisation/addInvestment", payload)];
|
16281
16281
|
case 4:
|
16282
16282
|
response = _a.sent();
|
@@ -20081,11 +20081,23 @@ var Assessment = function (props) {
|
|
20081
20081
|
changedValues = {};
|
20082
20082
|
if (info.changedFields && info.changedFields.length > 0) {
|
20083
20083
|
info.changedFields.map(function (changedField) { return __awaiter(void 0, void 0, void 0, function () {
|
20084
|
+
var base64Value, values_1;
|
20084
20085
|
return __generator(this, function (_a) {
|
20085
|
-
|
20086
|
-
|
20086
|
+
switch (_a.label) {
|
20087
|
+
case 0:
|
20088
|
+
if (!(changedField.name[0] === "document")) return [3 /*break*/, 2];
|
20089
|
+
return [4 /*yield*/, getBase64(changedField.value[0].originFileObj)];
|
20090
|
+
case 1:
|
20091
|
+
base64Value = _a.sent();
|
20092
|
+
console.log("FEAsibility document : ", base64Value);
|
20093
|
+
values_1 = base64Value;
|
20094
|
+
setCobenefitsAssessmentDetails(function (pre) { return (__assign(__assign({}, pre), { document: values_1 })); });
|
20095
|
+
return [3 /*break*/, 3];
|
20096
|
+
case 2:
|
20097
|
+
changedValues[changedField.name[0]] = changedField.value;
|
20098
|
+
_a.label = 3;
|
20099
|
+
case 3: return [2 /*return*/];
|
20087
20100
|
}
|
20088
|
-
return [2 /*return*/];
|
20089
20101
|
});
|
20090
20102
|
}); });
|
20091
20103
|
setCobenefitsAssessmentDetails(function (pre) { return (__assign(__assign({}, pre), changedValues)); });
|
@@ -20120,34 +20132,6 @@ var Assessment = function (props) {
|
|
20120
20132
|
setIsPersonListedDetailsVisible(false);
|
20121
20133
|
}
|
20122
20134
|
};
|
20123
|
-
var onAssesmentDocument = function (e) { return __awaiter(void 0, void 0, void 0, function () {
|
20124
|
-
var base64Value, values_1;
|
20125
|
-
var _a;
|
20126
|
-
return __generator(this, function (_b) {
|
20127
|
-
switch (_b.label) {
|
20128
|
-
case 0:
|
20129
|
-
if (!((e === null || e === void 0 ? void 0 : e.fileList.length) > 0 && ((_a = e === null || e === void 0 ? void 0 : e.fileList[0]) === null || _a === void 0 ? void 0 : _a.name))) return [3 /*break*/, 2];
|
20130
|
-
return [4 /*yield*/, getBase64(e.fileList[0].originFileObj)];
|
20131
|
-
case 1:
|
20132
|
-
base64Value = _b.sent();
|
20133
|
-
values_1 = base64Value;
|
20134
|
-
setCobenefitsAssessmentDetails(function (pre) { return (__assign(__assign({}, pre), { document: values_1 })); });
|
20135
|
-
return [3 /*break*/, 3];
|
20136
|
-
case 2:
|
20137
|
-
setCobenefitsAssessmentDetails(function (pre) {
|
20138
|
-
pre.document; var rest = __rest(pre, ["document"]);
|
20139
|
-
if (Object.keys(rest).length === 0) {
|
20140
|
-
return undefined;
|
20141
|
-
}
|
20142
|
-
else {
|
20143
|
-
return __assign({}, rest);
|
20144
|
-
}
|
20145
|
-
});
|
20146
|
-
_b.label = 3;
|
20147
|
-
case 3: return [2 /*return*/];
|
20148
|
-
}
|
20149
|
-
});
|
20150
|
-
}); };
|
20151
20135
|
var normFile = function (e) {
|
20152
20136
|
if (Array.isArray(e)) {
|
20153
20137
|
return e;
|
@@ -20362,7 +20346,7 @@ var Assessment = function (props) {
|
|
20362
20346
|
] },
|
20363
20347
|
React.createElement(antd.Upload, { accept: ".xls, .xlsx, .ppt, .pptx, .csv, .doc, .docx, .pdf, .png, .jpg", beforeUpload: function (file) {
|
20364
20348
|
return false;
|
20365
|
-
}, className: "design-upload-section", name: "document", listType: "picture", multiple: false, maxCount: 1
|
20349
|
+
}, className: "design-upload-section", name: "document", listType: "picture", multiple: false, maxCount: 1 },
|
20366
20350
|
React.createElement(antd.Button, { className: "upload-doc", size: "large", icon: React.createElement(icons.UploadOutlined, null) }, "Upload")))),
|
20367
20351
|
viewOnly && assessmentViewData.document && (React.createElement(antd.Form.Item, { label: t("assessmentDocuments"), name: "assessmentDocuments" },
|
20368
20352
|
React.createElement("a", { href: assessmentViewData.document, target: "_blank", rel: "noopener noreferrer", download: true }, assessmentViewData.document))))))))));
|