@undp/carbon-library 1.0.289-CARBON-366.0 → 1.0.289-CARBON-347.1
Sign up to get free protection for your applications and to get access to all the features.
- package/dist/cjs/index.js +1266 -526
- package/dist/cjs/index.js.map +1 -1
- package/dist/cjs/types/Components/Common/CoBenifits/coBenifits.d.ts +0 -1
- package/dist/cjs/types/Components/Common/Models/programmeRetireForm.d.ts +0 -1
- package/dist/cjs/types/Components/Common/Models/programmeTransferForm.d.ts +0 -1
- package/dist/cjs/types/Components/Common/NdcActionBody/ndcActionBody.d.ts +0 -2
- package/dist/cjs/types/Components/Common/ProgrammeDocuments/programmeDocuments.d.ts +0 -2
- package/dist/cjs/types/Context/ConnectionContext/connectionContext.d.ts +8 -0
- package/dist/cjs/types/Context/SettingsContext/settingsContext.d.ts +10 -0
- package/dist/cjs/types/Context/UserInformationContext/userInformationContext.d.ts +6 -0
- package/dist/cjs/types/Context/index.d.ts +3 -0
- package/dist/cjs/types/Definitions/Definitions/connectionContext.definitions.d.ts +3 -0
- package/dist/cjs/types/Definitions/Enums/investment.enum.d.ts +4 -0
- package/dist/cjs/types/Storybook/AddNewCompanyComponent.stories.d.ts +12 -0
- package/dist/cjs/types/Storybook/AddNewUserComponent.stories.d.ts +12 -0
- package/dist/cjs/types/Storybook/Decorators/AddNewCompanyI18nDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/Decorators/AddNewUserI18nDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/Decorators/ConnectionContextDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/Decorators/DashboardI18nDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/Decorators/InvestmentCreationI18nDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/Decorators/ProgrammeCreateI18nDecorator.d.ts +2 -0
- package/dist/cjs/types/Storybook/InvestmentCreationComponent.stories.d.ts +12 -0
- package/dist/cjs/types/Storybook/MRVDashboard.stories.d.ts +12 -0
- package/dist/cjs/types/Storybook/ProgrammeCreationComponent.stories.d.ts +12 -0
- package/dist/cjs/types/Storybook/RegistryDashboard.stories.d.ts +12 -0
- package/dist/cjs/types/index.d.ts +1 -0
- package/dist/esm/index.js +1260 -528
- package/dist/esm/index.js.map +1 -1
- package/dist/esm/types/Components/Common/CoBenifits/coBenifits.d.ts +0 -1
- package/dist/esm/types/Components/Common/Models/programmeRetireForm.d.ts +0 -1
- package/dist/esm/types/Components/Common/Models/programmeTransferForm.d.ts +0 -1
- package/dist/esm/types/Components/Common/NdcActionBody/ndcActionBody.d.ts +0 -2
- package/dist/esm/types/Components/Common/ProgrammeDocuments/programmeDocuments.d.ts +0 -2
- package/dist/esm/types/Context/ConnectionContext/connectionContext.d.ts +8 -0
- package/dist/esm/types/Context/SettingsContext/settingsContext.d.ts +10 -0
- package/dist/esm/types/Context/UserInformationContext/userInformationContext.d.ts +6 -0
- package/dist/esm/types/Context/index.d.ts +3 -0
- package/dist/esm/types/Definitions/Definitions/connectionContext.definitions.d.ts +3 -0
- package/dist/esm/types/Definitions/Enums/investment.enum.d.ts +4 -0
- package/dist/esm/types/Storybook/AddNewCompanyComponent.stories.d.ts +12 -0
- package/dist/esm/types/Storybook/AddNewUserComponent.stories.d.ts +12 -0
- package/dist/esm/types/Storybook/Decorators/AddNewCompanyI18nDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/Decorators/AddNewUserI18nDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/Decorators/ConnectionContextDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/Decorators/DashboardI18nDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/Decorators/InvestmentCreationI18nDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/Decorators/ProgrammeCreateI18nDecorator.d.ts +2 -0
- package/dist/esm/types/Storybook/InvestmentCreationComponent.stories.d.ts +12 -0
- package/dist/esm/types/Storybook/MRVDashboard.stories.d.ts +12 -0
- package/dist/esm/types/Storybook/ProgrammeCreationComponent.stories.d.ts +12 -0
- package/dist/esm/types/Storybook/RegistryDashboard.stories.d.ts +12 -0
- package/dist/esm/types/index.d.ts +1 -0
- package/dist/index.d.ts +27 -8
- package/dist/locales/i18n/programme/en.json +5 -3
- package/package.json +29 -2
package/dist/esm/index.js
CHANGED
@@ -1,8 +1,9 @@
|
|
1
1
|
import { PlusOutlined, FilterOutlined, DownloadOutlined, BankOutlined, SafetyOutlined, AuditOutlined, ExperimentOutlined, UploadOutlined, UserOutlined, MinusCircleOutlined, StarOutlined, ToolOutlined, EyeOutlined, SearchOutlined, EllipsisOutlined, EditOutlined, DeleteOutlined, FileAddOutlined, CheckCircleOutlined, ExclamationCircleOutlined, BookOutlined, CaretDownOutlined, LockOutlined, EyeInvisibleOutlined, GlobalOutlined, FlagOutlined, LineChartOutlined, LikeOutlined, DislikeOutlined, PlusCircleOutlined, LockFilled, CloseCircleOutlined } from '@ant-design/icons';
|
2
2
|
import { Input, Radio, Space, Row, Col, Button, Dropdown, Table, Empty, message, Form, Steps, Upload, InputNumber, Tooltip, Select, Modal, Alert, Card, Skeleton, Tag, Checkbox, DatePicker, Popover, List, Typography, Spin, Tabs, Progress, Collapse } from 'antd';
|
3
|
-
import React, { useState, useEffect, useRef } from 'react';
|
3
|
+
import React, { createContext, useState, useEffect, useCallback, useContext, useRef } from 'react';
|
4
4
|
import { DateTime } from 'luxon';
|
5
5
|
import { Buffer } from 'buffer';
|
6
|
+
import axios, { HttpStatusCode } from 'axios';
|
6
7
|
import PhoneInput, { formatPhoneNumberIntl, formatPhoneNumber } from 'react-phone-number-input';
|
7
8
|
import validator from 'validator';
|
8
9
|
import { plainToClass } from 'class-transformer';
|
@@ -13,7 +14,6 @@ import mapboxgl from 'mapbox-gl';
|
|
13
14
|
import 'mapbox-gl/dist/mapbox-gl.css';
|
14
15
|
import 'antd/dist/antd.css';
|
15
16
|
import * as XLSX from 'xlsx';
|
16
|
-
import { HttpStatusCode } from 'axios';
|
17
17
|
|
18
18
|
/******************************************************************************
|
19
19
|
Copyright (c) Microsoft Corporation.
|
@@ -492,9 +492,317 @@ var OrganisationStatus = function (props) {
|
|
492
492
|
return orgState;
|
493
493
|
};
|
494
494
|
|
495
|
+
function e$1(e){this.message=e;}e$1.prototype=new Error,e$1.prototype.name="InvalidCharacterError";var r="undefined"!=typeof window&&window.atob&&window.atob.bind(window)||function(r){var t=String(r).replace(/=+$/,"");if(t.length%4==1)throw new e$1("'atob' failed: The string to be decoded is not correctly encoded.");for(var n,o,a=0,i=0,c="";o=t.charAt(i++);~o&&(n=a%4?64*n+o:o,a++%4)?c+=String.fromCharCode(255&n>>(-2*a&6)):0)o="ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789+/=".indexOf(o);return c};function t$1(e){var t=e.replace(/-/g,"+").replace(/_/g,"/");switch(t.length%4){case 0:break;case 2:t+="==";break;case 3:t+="=";break;default:throw "Illegal base64url string!"}try{return function(e){return decodeURIComponent(r(e).replace(/(.)/g,(function(e,r){var t=r.charCodeAt(0).toString(16).toUpperCase();return t.length<2&&(t="0"+t),"%"+t})))}(t)}catch(e){return r(t)}}function n$1(e){this.message=e;}function o(e,r){if("string"!=typeof e)throw new n$1("Invalid token specified");var o=!0===(r=r||{}).header?0:1;try{return JSON.parse(t$1(e.split(".")[o]))}catch(e){throw new n$1("Invalid token specified: "+e.message)}}n$1.prototype=new Error,n$1.prototype.name="InvalidTokenError";
|
496
|
+
|
497
|
+
var ConnectionContext = createContext({});
|
498
|
+
var ConnectionContextProvider = function (props) {
|
499
|
+
var _a = useState(), token = _a[0], setToken = _a[1];
|
500
|
+
var serverURL = props.serverURL, t = props.t, statServerUrl = props.statServerUrl, children = props.children;
|
501
|
+
useEffect(function () {
|
502
|
+
var timer = setInterval(function () { return __awaiter(void 0, void 0, void 0, function () {
|
503
|
+
var newToken;
|
504
|
+
return __generator(this, function (_a) {
|
505
|
+
switch (_a.label) {
|
506
|
+
case 0: return [4 /*yield*/, localStorage.getItem('token')];
|
507
|
+
case 1:
|
508
|
+
newToken = _a.sent();
|
509
|
+
if (token !== newToken) {
|
510
|
+
setToken(newToken);
|
511
|
+
}
|
512
|
+
return [2 /*return*/];
|
513
|
+
}
|
514
|
+
});
|
515
|
+
}); }, 3000);
|
516
|
+
if (token) {
|
517
|
+
clearTimeout(timer);
|
518
|
+
}
|
519
|
+
return function () {
|
520
|
+
clearTimeout(timer);
|
521
|
+
};
|
522
|
+
}, [token]);
|
523
|
+
var send = useCallback(function (method, path, data, config, extraUrl) {
|
524
|
+
return new Promise(function (resolve, reject) {
|
525
|
+
var url = "".concat(extraUrl ? extraUrl : serverURL, "/").concat(path);
|
526
|
+
var headers;
|
527
|
+
if (token) {
|
528
|
+
headers = { authorization: "Bearer ".concat(token.toString()) };
|
529
|
+
}
|
530
|
+
else {
|
531
|
+
if (localStorage.getItem('token')) {
|
532
|
+
headers = {
|
533
|
+
authorization: "Bearer ".concat(localStorage.getItem('token')),
|
534
|
+
};
|
535
|
+
}
|
536
|
+
else {
|
537
|
+
headers = {
|
538
|
+
authorization: "Bearer ".concat(process.env.STORYBOOK_ACCESS_TOKEN),
|
539
|
+
};
|
540
|
+
}
|
541
|
+
}
|
542
|
+
axios(__assign({ method: method, url: url, data: data, headers: headers }, config))
|
543
|
+
.then(function (response) {
|
544
|
+
var _a, _b, _c;
|
545
|
+
if (response.status) {
|
546
|
+
if (response.status === 200 || response.status === 201) {
|
547
|
+
resolve({
|
548
|
+
status: response.status,
|
549
|
+
data: (_a = response.data.data) !== null && _a !== void 0 ? _a : response.data,
|
550
|
+
response: response,
|
551
|
+
statusText: 'SUCCESS',
|
552
|
+
message: response.data.message,
|
553
|
+
});
|
554
|
+
}
|
555
|
+
else if (response.status === 422) {
|
556
|
+
reject({
|
557
|
+
status: response.status,
|
558
|
+
data: (_b = response.data) === null || _b === void 0 ? void 0 : _b.data,
|
559
|
+
statusText: 'ERROR',
|
560
|
+
response: response,
|
561
|
+
message: response.data.message,
|
562
|
+
errors: (_c = response.data) === null || _c === void 0 ? void 0 : _c.errors,
|
563
|
+
});
|
564
|
+
}
|
565
|
+
}
|
566
|
+
else {
|
567
|
+
reject({
|
568
|
+
status: 500,
|
569
|
+
statusText: 'UNKNOWN',
|
570
|
+
message: t('common:systemError'),
|
571
|
+
});
|
572
|
+
}
|
573
|
+
})
|
574
|
+
.catch(function (e) {
|
575
|
+
var _a;
|
576
|
+
if (e.response) {
|
577
|
+
if (e.response.status) {
|
578
|
+
if (e.response.data.message === 'jwt expired') {
|
579
|
+
localStorage.removeItem('token');
|
580
|
+
window.location.reload();
|
581
|
+
}
|
582
|
+
reject({
|
583
|
+
status: e.response.status,
|
584
|
+
statusText: 'ERROR',
|
585
|
+
errors: (_a = e.response.data) === null || _a === void 0 ? void 0 : _a.errors,
|
586
|
+
message: e.response.data.message,
|
587
|
+
});
|
588
|
+
}
|
589
|
+
else {
|
590
|
+
reject({
|
591
|
+
statusText: 'ERROR',
|
592
|
+
message: t('common:systemError'),
|
593
|
+
});
|
594
|
+
}
|
595
|
+
}
|
596
|
+
else {
|
597
|
+
reject({
|
598
|
+
statusText: 'ERROR',
|
599
|
+
message: t('common:networkError'),
|
600
|
+
});
|
601
|
+
}
|
602
|
+
});
|
603
|
+
});
|
604
|
+
}, [token, serverURL]);
|
605
|
+
var post = useCallback(function (path, data, config, extraUrl) {
|
606
|
+
return send('post', path, data, config, extraUrl);
|
607
|
+
}, [send]);
|
608
|
+
var put = useCallback(function (path, data, config) {
|
609
|
+
return send('put', path, data, config);
|
610
|
+
}, [send]);
|
611
|
+
var get = useCallback(function (path, config) {
|
612
|
+
return send('get', path, undefined, config);
|
613
|
+
}, [send]);
|
614
|
+
var patch = useCallback(function (path, data, config) {
|
615
|
+
return send('patch', path, data, config);
|
616
|
+
}, [send]);
|
617
|
+
var del = useCallback(function (path, config) {
|
618
|
+
return send('delete', path, config);
|
619
|
+
}, [send]);
|
620
|
+
var updateToken = useCallback(function (newToken) { return __awaiter(void 0, void 0, void 0, function () {
|
621
|
+
return __generator(this, function (_a) {
|
622
|
+
if (newToken) {
|
623
|
+
localStorage.setItem('token', newToken);
|
624
|
+
setToken(newToken);
|
625
|
+
}
|
626
|
+
else {
|
627
|
+
localStorage.setItem('token', '');
|
628
|
+
setToken(undefined);
|
629
|
+
}
|
630
|
+
return [2 /*return*/];
|
631
|
+
});
|
632
|
+
}); }, []);
|
633
|
+
var removeToken = function (tkn) {
|
634
|
+
if (tkn) {
|
635
|
+
var exp = o(tkn).exp;
|
636
|
+
if (Date.now() > exp * 1000) {
|
637
|
+
localStorage.setItem('token', '');
|
638
|
+
localStorage.removeItem('userRole');
|
639
|
+
localStorage.removeItem('userId');
|
640
|
+
localStorage.removeItem('companyId');
|
641
|
+
localStorage.removeItem('companyRole');
|
642
|
+
}
|
643
|
+
else {
|
644
|
+
var diff = exp * 1000 - Date.now();
|
645
|
+
setTimeout(function () {
|
646
|
+
setToken(undefined);
|
647
|
+
localStorage.setItem('token', '');
|
648
|
+
localStorage.removeItem('userRole');
|
649
|
+
localStorage.removeItem('userId');
|
650
|
+
localStorage.removeItem('companyId');
|
651
|
+
localStorage.removeItem('companyRole');
|
652
|
+
}, diff);
|
653
|
+
console.log(diff, 'Remaining Token expire time');
|
654
|
+
}
|
655
|
+
}
|
656
|
+
};
|
657
|
+
useEffect(function () {
|
658
|
+
removeToken(token);
|
659
|
+
}, [token]);
|
660
|
+
return (React.createElement(ConnectionContext.Provider, { value: {
|
661
|
+
connection: { post: post, put: put, get: get, patch: patch, delete: del, updateToken: updateToken, token: token, removeToken: removeToken, statServerUrl: statServerUrl },
|
662
|
+
} }, children));
|
663
|
+
};
|
664
|
+
var useConnection = function () {
|
665
|
+
var context = useContext(ConnectionContext);
|
666
|
+
return context.connection;
|
667
|
+
};
|
668
|
+
|
669
|
+
var UserContext = createContext({
|
670
|
+
setUserInfo: function () { },
|
671
|
+
removeUserInfo: function () { },
|
672
|
+
IsAuthenticated: function (tkn) { return false; },
|
673
|
+
isTokenExpired: false,
|
674
|
+
setIsTokenExpired: function (val) { },
|
675
|
+
});
|
676
|
+
var UserInformationContextProvider = function (_a) {
|
677
|
+
var children = _a.children;
|
678
|
+
var token = useConnection().token;
|
679
|
+
var _b = useState(false), isTokenExpired = _b[0], setIsTokenExpired = _b[1];
|
680
|
+
var initialUserProps = {
|
681
|
+
id: localStorage.getItem('userId') ? localStorage.getItem('userId') : process.env.STORYBOOK_USER_ID ? process.env.STORYBOOK_USER_ID : '',
|
682
|
+
userRole: localStorage.getItem('userRole') ? localStorage.getItem('userRole') : process.env.STORYBOOK_USER_ROLE ? process.env.STORYBOOK_USER_ROLE : '',
|
683
|
+
companyRole: localStorage.getItem('companyRole')
|
684
|
+
? localStorage.getItem('companyRole')
|
685
|
+
: process.env.STORYBOOK_COMPANY_ROLE ? process.env.STORYBOOK_COMPANY_ROLE : '',
|
686
|
+
companyId: localStorage.getItem('companyId')
|
687
|
+
? parseInt(localStorage.getItem('companyId'))
|
688
|
+
: process.env.STORYBOOK_COMPANY_ID ? parseInt(process.env.STORYBOOK_COMPANY_ID) : -1,
|
689
|
+
companyLogo: localStorage.getItem('companyLogo')
|
690
|
+
? localStorage.getItem('companyLogo')
|
691
|
+
: process.env.STORYBOOK_COMPANY_LOGO ? process.env.STORYBOOK_COMPANY_LOGO : '',
|
692
|
+
companyName: localStorage.getItem('companyName')
|
693
|
+
? localStorage.getItem('companyName')
|
694
|
+
: process.env.STORYBOOK_COMPANY_NAME ? process.env.STORYBOOK_COMPANY_NAME : '',
|
695
|
+
companyState: localStorage.getItem('companyState')
|
696
|
+
? parseInt(localStorage.getItem('companyState'))
|
697
|
+
: process.env.STORYBOOK_COMPANY_STATE ? parseInt(process.env.STORYBOOK_COMPANY_STATE) : 0,
|
698
|
+
};
|
699
|
+
var _c = useState(initialUserProps), userInfoState = _c[0], setUserInfoState = _c[1];
|
700
|
+
var setUserInfo = function (value) {
|
701
|
+
var state = (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyState) === 1 ? userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyState : 0;
|
702
|
+
var id = value.id, userRole = value.userRole, companyId = value.companyId, companyRole = value.companyRole, companyLogo = value.companyLogo, companyName = value.companyName, _a = value.companyState, companyState = _a === void 0 ? state : _a;
|
703
|
+
if (id) {
|
704
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { id: id })); });
|
705
|
+
localStorage.setItem('userId', id);
|
706
|
+
}
|
707
|
+
if (userRole) {
|
708
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { userRole: userRole })); });
|
709
|
+
localStorage.setItem('userRole', userRole);
|
710
|
+
}
|
711
|
+
if (companyId) {
|
712
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyId: companyId })); });
|
713
|
+
localStorage.setItem('companyId', companyId + '');
|
714
|
+
}
|
715
|
+
if (companyLogo) {
|
716
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyLogo: companyLogo })); });
|
717
|
+
localStorage.setItem('companyLogo', companyLogo);
|
718
|
+
}
|
719
|
+
else {
|
720
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyLogo: '' })); });
|
721
|
+
localStorage.setItem('companyLogo', '');
|
722
|
+
}
|
723
|
+
if (companyName) {
|
724
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyName: companyName })); });
|
725
|
+
localStorage.setItem('companyName', companyName);
|
726
|
+
}
|
727
|
+
if (userRole) {
|
728
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyRole: companyRole })); });
|
729
|
+
localStorage.setItem('companyRole', companyRole);
|
730
|
+
}
|
731
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyState: companyState })); });
|
732
|
+
localStorage.setItem('companyState', companyState + '');
|
733
|
+
};
|
734
|
+
var IsAuthenticated = useCallback(function (tokenNew) {
|
735
|
+
var tokenVal;
|
736
|
+
if (tokenNew) {
|
737
|
+
tokenVal = tokenNew;
|
738
|
+
}
|
739
|
+
else if (token) {
|
740
|
+
tokenVal = token;
|
741
|
+
}
|
742
|
+
else {
|
743
|
+
tokenVal = localStorage.getItem('token');
|
744
|
+
if (tokenVal === '') {
|
745
|
+
if (history.length !== 1) {
|
746
|
+
setIsTokenExpired(true);
|
747
|
+
}
|
748
|
+
}
|
749
|
+
}
|
750
|
+
try {
|
751
|
+
if (tokenVal) {
|
752
|
+
var exp = o(tokenVal).exp;
|
753
|
+
return Date.now() < exp * 1000;
|
754
|
+
}
|
755
|
+
return false;
|
756
|
+
}
|
757
|
+
catch (err) {
|
758
|
+
return false;
|
759
|
+
}
|
760
|
+
}, [token]);
|
761
|
+
var removeUserInfo = function () {
|
762
|
+
localStorage.removeItem('userId');
|
763
|
+
localStorage.removeItem('userRole');
|
764
|
+
localStorage.removeItem('companyId');
|
765
|
+
localStorage.removeItem('companyRole');
|
766
|
+
localStorage.removeItem('companyName');
|
767
|
+
localStorage.removeItem('companyState');
|
768
|
+
localStorage.removeItem('companyLogo');
|
769
|
+
setUserInfoState(initialUserProps);
|
770
|
+
};
|
771
|
+
return (React.createElement(UserContext.Provider, { value: {
|
772
|
+
userInfoState: userInfoState,
|
773
|
+
setUserInfo: setUserInfo,
|
774
|
+
removeUserInfo: removeUserInfo,
|
775
|
+
IsAuthenticated: IsAuthenticated,
|
776
|
+
isTokenExpired: isTokenExpired,
|
777
|
+
setIsTokenExpired: setIsTokenExpired,
|
778
|
+
} }, children));
|
779
|
+
};
|
780
|
+
var useUserContext = function () {
|
781
|
+
return useContext(UserContext);
|
782
|
+
};
|
783
|
+
|
784
|
+
var SettingsContext = createContext({
|
785
|
+
isTransferFrozen: false,
|
786
|
+
setTransferFrozen: function (value) { },
|
787
|
+
});
|
788
|
+
var SettingsContextProvider = function (_a) {
|
789
|
+
var children = _a.children;
|
790
|
+
var _b = useState(false), isTransferFrozen = _b[0], setIsTransferFrozen = _b[1];
|
791
|
+
var setTransferFrozen = function (value) {
|
792
|
+
setIsTransferFrozen(value);
|
793
|
+
};
|
794
|
+
return (React.createElement(SettingsContext.Provider, { value: {
|
795
|
+
isTransferFrozen: isTransferFrozen,
|
796
|
+
setTransferFrozen: setTransferFrozen,
|
797
|
+
} }, children));
|
798
|
+
};
|
799
|
+
var useSettingsContext = function () {
|
800
|
+
return useContext(SettingsContext);
|
801
|
+
};
|
802
|
+
|
495
803
|
var Search$2 = Input.Search;
|
496
804
|
var CompanyManagementComponent = function (props) {
|
497
|
-
var t = props.t, useAbilityContext = props.useAbilityContext,
|
805
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, visibleColumns = props.visibleColumns, onNavigateToCompanyProfile = props.onNavigateToCompanyProfile, onClickAddCompany = props.onClickAddCompany;
|
498
806
|
var _a = useState(), totalCompany = _a[0], setTotalCompany = _a[1];
|
499
807
|
var _b = useState(false), loading = _b[0], setLoading = _b[1];
|
500
808
|
var _c = useState([]), tableData = _c[0], setTableData = _c[1];
|
@@ -509,6 +817,7 @@ var CompanyManagementComponent = function (props) {
|
|
509
817
|
var _l = useState(""), sortField = _l[0], setSortField = _l[1];
|
510
818
|
var _m = useState(), dataQuery = _m[0], setDataQuery = _m[1];
|
511
819
|
var ability = useAbilityContext();
|
820
|
+
var post = useConnection().post;
|
512
821
|
document.addEventListener("mousedown", function (event) {
|
513
822
|
var organisationFilterArea1 = document.querySelector(".filter-bar");
|
514
823
|
var organisationFilterArea2 = document.querySelector(".filter-dropdown");
|
@@ -896,7 +1205,7 @@ var CompanyManagementComponent = function (props) {
|
|
896
1205
|
var css_248z$w = ".company-details-form-container {\n width: 100%; }\n .company-details-form-container .company-details-form .steps-actions {\n display: flex;\n flex-direction: row-reverse; }\n .company-details-form-container .company-details-form .steps-actions .mg-left-1 {\n margin-left: 1rem; }\n .company-details-form-container .company-details-form .row .website .ant-input {\n margin-left: 0.3rem; }\n .company-details-form-container .company-details-form .row .website .ant-input-group-addon {\n border: 1px solid #d9d9d9; }\n .company-details-form-container .company-details-form .row .logo-upload-section {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n align-items: start;\n width: 100%; }\n .company-details-form-container .company-details-form .row .logo-upload-section .ant-upload {\n width: 20%; }\n .company-details-form-container .company-details-form .row .logo-upload-section .ant-upload-list {\n align-items: center;\n justify-content: center;\n width: 75%; }\n .company-details-form-container .company-details-form .row .logo-upload-section .ant-upload-list .ant-upload-list-item {\n margin-top: 0; }\n .company-details-form-container .company-details-form .row .details-part-one .space-container {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-one .space-container .ant-space-item {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .certifier-radio-container {\n width: 30%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .certifier-radio-container .ant-radio-button-wrapper-checked:not(\n .ant-radio-button-wrapper-disabled\n) {\n color: #519e4f !important;\n border-color: #519e4f !important;\n box-shadow: none; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .certifier-radio-container .anticon {\n background: #eeeeee;\n border-radius: 50px;\n padding: 0.2rem;\n color: #519e4f; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .dev-radio-container {\n width: 30%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .dev-radio-container .ant-radio-button-wrapper-checked:not(\n .ant-radio-button-wrapper-disabled\n) {\n color: #ffa070 !important;\n border-color: #ffa070 !important;\n box-shadow: none; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .dev-radio-container .anticon {\n background: #eeeeee;\n border-radius: 50px;\n padding: 0.2rem;\n color: #ffa070; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .minister-radio-container {\n width: 30%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .minister-radio-container .ant-radio-button-wrapper-checked:not(\n .ant-radio-button-wrapper-disabled\n) {\n color: #9155fd !important;\n border-color: #9155fd !important;\n box-shadow: none; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .minister-radio-container .anticon {\n background: #eeeeee;\n border-radius: 50px;\n padding: 0.2rem;\n color: #9155fd; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .gov-radio-container {\n width: 45%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .gov-radio-container .ant-radio-button-wrapper-checked:not(\n .ant-radio-button-wrapper-disabled\n) {\n color: #16b1ff !important;\n border-color: #16b1ff !important;\n box-shadow: none; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .gov-radio-container .anticon {\n background: #eeeeee;\n border-radius: 50px;\n padding: 0.2rem;\n color: #16b1ff; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .observer-radio-container {\n width: 25%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .observer-radio-container .ant-radio-button-wrapper-checked:not(\n .ant-radio-button-wrapper-disabled\n) {\n color: #707070 !important;\n border-color: #707070 !important;\n box-shadow: none; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .observer-radio-container .anticon {\n background: #eeeeee;\n border-radius: 50px;\n padding: 0.2rem;\n color: #707070; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .ant-radio-button-wrapper::before {\n background-color: transparent; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .ant-radio-button-wrapper {\n border: 1px solid #d9d9d9; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .anticon {\n margin-right: 0.5rem; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .certifier {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .certifier .ant-radio-button-checked {\n background: rgba(128, 255, 0, 0.12);\n color: #519e4f; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .dev {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .dev .ant-radio-button-checked {\n background: rgba(254, 241, 173, 0.5);\n color: #ffa070; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .gov {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .gov .ant-radio-button-checked {\n background: rgba(185, 226, 244, 0.56);\n color: #16b1ff; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .minister {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .minister .ant-radio-button-checked {\n background: rgba(198, 144, 251, 0.12);\n color: #9155fd; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .observer {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .observer .ant-radio-button-checked {\n background: rgba(176, 190, 197, 0.23);\n color: #707070; }\n .company-details-form-container .company-details-form .row .details-part-two .role-group .role-icons {\n margin-right: 5px; }\n .company-details-form-container .company-details-form .row .details-part-two .space-container {\n width: 100%; }\n .company-details-form-container .company-details-form .row .details-part-two .space-container .ant-space-item {\n width: 100%; }\n\n.step-title-container {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between;\n margin-bottom: 1rem; }\n .step-title-container .step-count {\n font-size: 2.2rem;\n font-weight: 800;\n margin-right: 0.4rem;\n color: rgba(58, 53, 65, 0.8); }\n .step-title-container .title {\n font-size: 1rem;\n font-weight: 600;\n color: #3a3541; }\n\n.add-company-main-container {\n display: flex;\n flex-direction: column;\n border-radius: 5px;\n padding: 0 50px; }\n .add-company-main-container .title-container {\n display: flex;\n flex-direction: column;\n border-radius: 5px; }\n .add-company-main-container .title-container .main {\n font-size: 1.25rem;\n font-weight: 500;\n color: #16b1ff; }\n .add-company-main-container .title-container .sub {\n font-size: 0.8rem;\n color: #555657; }\n .add-company-main-container .adding-section {\n display: flex;\n flex-direction: column;\n background-color: #ffffff;\n margin: 1rem 0 1rem 0;\n border-radius: 10px;\n padding: 2.5rem 1.5rem 2.5rem 1.5rem; }\n .add-company-main-container .adding-section .form-section {\n display: flex;\n margin-bottom: 2rem; }\n .add-company-main-container .adding-section .form-section .form-one {\n width: 100%; }\n .add-company-main-container .adding-section .form-section .steps {\n width: 15%; }\n .add-company-main-container .adding-section .form-section .steps-content {\n width: 85%; }\n .add-company-main-container .adding-section .steps-action {\n display: flex;\n flex-direction: row-reverse; }\n\n.ant-upload-list-picture .ant-upload-list-item-error,\n.ant-upload-list-picture-card .ant-upload-list-item-error {\n height: auto;\n max-height: 200px; }\n\n.hide {\n display: none !important; }\n";
|
897
1206
|
styleInject(css_248z$w);
|
898
1207
|
|
899
|
-
var css_248z$v = "body {\n background-color: #f4f5fa;\n font-family: \"Inter\";\n font-weight: 400; }\n\n.ant-menu {\n background-color: #f4f5fa; }\n\n.ant-layout-header {\n background-color: #f4f5fa; }\n\n.ant-layout {\n background-color: #f4f5fa; }\n\n.ant-menu-submenu .ant-menu {\n background-color: #f4f5fa; }\n\n.ant-menu-item {\n background-color: #f4f5fa; }\n\n.ant-menu-sub {\n background-color: #f4f5fa; }\n\n.ant-table-content {\n font-family: \"Inter\"; }\n\n.ant-input {\n border-radius: 5px !important; }\n\n.ant-btn {\n border-radius: 5px !important; }\n\n.ant-input-group-addon:first-child {\n border-radius: 5px !important; }\n\n.ant-input-group .ant-input {\n width: 99% !important; }\n\n.ant-radio-group {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between; }\n\n.ant-radio-group-large .ant-radio-button-wrapper {\n font-size: 0.8rem;\n width: 25%;\n border-radius: 5px !important; }\n\n.ant-upload-list-picture .ant-upload-list-item-error,\n.ant-upload-list-picture-card .ant-upload-list-item-error {\n border-color: #40a9ff;\n border-radius: 5px;\n height: 40px; }\n .ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-name,\n .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-name {\n color: #40a9ff !important; }\n\n.ant-upload-list-item-error .ant-upload-list-item-card-actions .anticon {\n color: #40a9ff; }\n\n.ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input,\n.ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:hover {\n border-color: #d9d9d9 !important; }\n\n.ant-input-group-wrapper-status-error .ant-input-group-addon {\n border-color: #d9d9d9 !important; }\n\n.ant-form-item-explain-error {\n font-size: 13px;\n color: rgba(255, 77, 79, 0.8); }\n\n.ant-table-thead\n> tr\n> th:not(:last-child):not(.ant-table-selection-column):not(.ant-table-row-expand-icon-cell):not([colspan])::before {\n background-color: transparent !important; }\n\n.ant-form-item-label > label {\n flex-direction: row-reverse !important;\n color: rgba(58, 53, 65, 0.5); }\n\n.ant-form-item-label\n> label.ant-form-item-required:not(.ant-form-item-required-mark-optional)::before {\n margin-left: 0.2rem !important;\n color: rgba(255, 77, 79, 0.8) !important; }\n\n.ant-picker {\n border-radius: 5px !important;\n height: 35px !important; }\n\n.space-container {\n width: 100%; }\n .space-container .ant-space-item {\n width: 100%; }\n\n.PhoneInput .PhoneInputCountry {\n border: 1px solid #d9d9d9 !important;\n border-radius: 5px !important;\n padding: 0 1rem 0 1rem; }\n\n.PhoneInput .PhoneInputInput {\n flex: 1 1;\n min-width: 0;\n border-radius: 5px !important;\n height: 40px;\n border: 1px solid #d9d9d9 !important;\n outline: none; }\n\n.filter-title {\n color: rgba(58, 53, 65, 0.8);\n font-family: 'Inter';\n font-style: normal;\n font-weight: 600;\n font-size: 0.875rem; }\n\n.ant-radio-wrapper {\n font-family: 'Inter';\n font-style: normal;\n font-weight: 400;\n font-size: 0.875rem;\n line-height: 22px;\n color: rgba(58, 53, 65, 0.8); }\n\n.ant-list-item {\n color: rgba(58, 53, 65, 0.8); }\n\n.PhoneInput .PhoneInputInput:focus-visible,\n.PhoneInput .PhoneInputInput:hover {\n flex: 1 1;\n min-width: 0;\n border-radius: 5px !important;\n height: 40px;\n border-right: 1px solid #40a9ff !important;\n outline: 1px solid #40a9ff; }\n\n.layout-content-container {\n padding-bottom: 100px; }\n .layout-content-container .ant-btn-primary {\n background-color: #16b1ff;\n color: #ffffff;\n border: none; }\n .layout-content-container .ant-btn {\n height: 32px;\n font-weight: 500;\n font-size: 0.8rem;\n border-radius: 0.3rem;\n box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.25);\n min-width: 80px;\n box-shadow: none; }\n .layout-content-container .ant-btn span {\n text-transform: uppercase; }\n\n.content-container {\n padding: 0px 20px; }\n .content-container .title-bar {\n padding: 0px 0px 30px 0px; }\n .content-container .body-title {\n color: #16b1ff;\n font-weight: 500;\n font-size: 1.2rem; }\n .content-container .body-sub-title {\n color: rgba(58, 53, 65, 0.6);\n font-weight: 400;\n font-size: 0.8rem; }\n\n.content-card {\n background-color: #ffffff;\n border-radius: 10px;\n width: 100%; }\n .content-card .action-bar {\n padding: 1.6rem 1.3rem 1.6rem 1.3rem; }\n .content-card .action-bar button {\n width: fit-content; }\n .content-card .filter-section {\n padding: 1.4rem 1.3rem 1.6rem 1.3rem;\n display: flex;\n width: 100%;\n flex-direction: row;\n align-items: center;\n justify-content: end; }\n .content-card .filter-section .search-bar {\n display: flex;\n flex-direction: row-reverse; }\n .content-card .filter-section .filter-bar {\n display: flex;\n flex-direction: row-reverse;\n margin-top: 0.8rem;\n width: 5%; }\n .content-card .filter-section .ant-input-affix-wrapper {\n border-radius: 0.313rem 0 0 0.313rem !important; }\n .content-card .filter-section .ant-input-search\n> .ant-input-group\n> .ant-input-group-addon:last-child\n.ant-input-search-button {\n padding-top: 0;\n padding-bottom: 0;\n border-radius: 0 0.313rem 0.313rem 0 !important; }\n\n.layout-content-container .ant-btn {\n min-width: 50px !important; }\n\n.table-actions-section {\n width: 100%;\n margin-bottom: 1rem; }\n\n.action-menu {\n min-width: 120px;\n color: rgba(58, 53, 65, 0.6); }\n .action-menu .action-icon {\n margin-right: 12px;\n display: flex; }\n .action-menu .anticon-edit {\n color: #16b1ff; }\n .action-menu .anticon-delete {\n color: #f25a29; }\n\n.ant-dropdown-menu {\n padding: 1rem 2rem 1rem 1rem !important;\n border-radius: 5px; }\n\n.ant-dropdown-menu-item-active {\n background-color: transparent !important; }\n\n.ant-popover-inner-content .action-menu {\n margin: -12px -16px; }\n .ant-popover-inner-content .action-menu .ant-list-item {\n padding: 11px 16px;\n justify-content: flex-start;\n cursor: pointer; }\n\n.ant-tag {\n border-radius: 20px; }\n\n.clickable {\n cursor: pointer; }\n\n.text-center {\n text-align: center; }\n\n.float-left {\n float: left; }\n\n.float-right {\n float: right; }\n\n.apexcharts-canvas {\n font-family: \"Inter\" !important; }\n\n.apexcharts-legend-text {\n font-family: \"Inter\" !important; }\n\n.ant-tag {\n padding: 1px 10px; }\n\n.flex-display {\n display: flex; }\n\n.ant-modal-footer {\n border-top: none;\n text-align: center; }\n .ant-modal-footer button {\n margin: 10px 20px;\n text-transform: uppercase;\n font-size: 0.8rem; }\n\n.ant-modal-header {\n border-radius: 15px;\n border: none; }\n\n.ant-modal-content {\n border-radius: 15px;\n border: none; }\n\n.ant-modal-header {\n border: none; }\n\n.ant-modal-body {\n text-align: center;\n color: rgba(58, 53, 65, 0.6);\n font-size: 0.8rem; }\n .ant-modal-body .ant-select-selector {\n text-align: left;\n border-radius: 5px !important;\n height: 32px; }\n .ant-modal-body .form-label {\n text-align: left; }\n .ant-modal-body .form-label .req-ast {\n color: rgba(255, 77, 79, 0.8);\n padding-left: 5px; }\n .ant-modal-body .ant-form .ant-input-password {\n padding: 6.5px 11px;\n font-size: 16px; }\n .ant-modal-body .ant-form .ant-form-item-explain-error {\n text-align: start; }\n\n.popup-header {\n text-align: center;\n color: rgba(58, 53, 65, 0.8);\n font-weight: 600;\n font-family: \"Inter\";\n font-size: 0.9rem;\n margin: 25px 20px -20px 20px; }\n .popup-header .icon {\n font-size: 4rem;\n margin-bottom: 15px;\n font-weight: 400; }\n .popup-header img {\n height: 100px; }\n\n.popup-success .icon {\n color: #5dc380; }\n\n.popup-success .ant-btn-primary {\n background: #16b1ff;\n border-radius: #16b1ff;\n border: none; }\n\n.popup-success .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n\n.popup-success .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n\n.popup-primary .icon {\n color: #16b1ff; }\n\n.popup-primary .ant-btn-primary {\n background: #16b1ff;\n border-radius: #16b1ff;\n border: none; }\n\n.popup-primary .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n\n.popup-primary .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n\n.popup-danger .icon {\n color: rgba(255, 77, 79, 0.8); }\n\n.popup-danger .ant-btn-primary {\n background: rgba(255, 77, 79, 0.8);\n border-radius: rgba(255, 77, 79, 0.8);\n border: none; }\n\n.popup-danger .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n\n.popup-danger .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n\n.ant-modal-footer .ant-btn {\n height: 32px;\n border-radius: 4px;\n padding: 6px 16px;\n font-weight: 500; }\n\n.ant-modal-footer .ant-btn-default {\n color: rgba(140, 140, 140, 0.7) !important;\n border-color: rgba(140, 140, 140, 0.7) !important; }\n\n.ant-tag-processing {\n color: #16b1ff;\n background: rgba(185, 226, 244, 0.4); }\n\n.filter-section input {\n font-family: 'Inter';\n font-size: 0.8rem !important; }\n\n.pull-right {\n float: right; }\n\n.disabled {\n opacity: 0.5; }\n\n.mg-left-3 {\n margin-left: 3rem; }\n\n.mg-left-2 {\n margin-left: 2rem !important; }\n\n.mg-left-1 {\n margin-left: 1rem; }\n\n.mg-top-1 {\n margin-top: 1rem; }\n\n.mg-top-2 {\n margin-top: 2rem; }\n\n.mg-bottom-1 {\n margin-bottom: 1rem !important; }\n\n.transfer-form {\n padding: 0px 15px;\n color: rgba(58, 53, 65, 0.6); }\n .transfer-form .popup-credit-input .ant-form-item-explain-error {\n width: 200px; }\n .transfer-form .info-container {\n display: flex;\n flex-direction: row;\n width: 10%;\n height: 20px;\n align-items: center;\n justify-content: start;\n margin-left: 5px; }\n .transfer-form .ant-row {\n align-items: unset; }\n .transfer-form .sub-text {\n margin-bottom: 35px;\n font-size: 0.9rem;\n font-weight: 500; }\n .transfer-form .label {\n text-align: left;\n font-size: 0.9rem;\n color: rgba(58, 53, 65, 0.6); }\n .transfer-form .seperator {\n font-size: 1.2rem;\n color: #d9d9d9; }\n .transfer-form .footer {\n margin-bottom: 0px;\n margin-top: 15px; }\n .transfer-form label {\n font-size: 0.8rem; }\n .transfer-form .ant-radio-wrapper {\n font-size: 0.9rem; }\n .transfer-form input {\n color: rgba(58, 53, 65, 0.6); }\n .transfer-form button {\n text-transform: uppercase;\n font-weight: 500; }\n\n.color-error {\n color: rgba(255, 77, 79, 0.8); }\n\n.color-primary {\n color: #16b1ff; }\n\n.ant-input-number-input {\n text-align: right; }\n\n.text-left {\n text-align: left; }\n\n.ant-form-item .ant-radio-group {\n text-align: left; }\n\n.loading-center {\n margin: auto;\n text-align: center;\n position: absolute;\n top: 50%;\n left: 50%; }\n\n.ant-tag-purple {\n color: #976ed7; }\n\n.ant-tag-orange {\n color: #ff8f56; }\n\n.ant-tag-default {\n color: rgba(58, 53, 65, 0.5); }\n\n.ant-popover-inner {\n border-radius: 4px; }\n\n.ant-input-number {\n border-radius: 5px; }\n\n.ret-icon {\n background-color: rgba(254, 241, 173, 0.5);\n color: #ff8f56; }\n\n.flag-ret-icon {\n display: flex !important;\n background-color: #f4f5fa;\n font-size: 1.1rem !important;\n padding: 7px; }\n\n.b-icon {\n vertical-align: middle; }\n\n.ant-message-notice-content {\n padding: 0px;\n border-radius: 5px; }\n .ant-message-notice-content .ant-message-custom-content {\n font-size: 0.8rem;\n border-radius: 5px;\n padding: 17px 24px; }\n .ant-message-notice-content .ant-message-error {\n color: rgba(255, 77, 79, 0.8);\n border: 1px solid rgba(255, 77, 79, 0.8); }\n .ant-message-notice-content .ant-message-success {\n color: #5bce00;\n border: 1px solid #5bce00; }\n\n.ant-select-selection-item {\n color: rgba(58, 53, 65, 0.6); }\n\n.sub-text {\n font-size: 0.9rem;\n font-weight: 500; }\n\n.search-filter {\n margin-right: 15px; }\n\n.download-data-btn {\n margin-left: 15px; }\n\n.mg-bottom-0 {\n margin-bottom: 0px; }\n\n.padding-bottom-0 {\n padding-bottom: 0px; }\n\n.ellipsis-overflow {\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical; }\n\n.nextline-overflow {\n overflow-wrap: break-word; }\n\n.ant-message {\n width: 50%;\n right: 0px;\n left: auto;\n min-width: 400px; }\n";
|
1208
|
+
var css_248z$v = "body {\n background-color: #f4f5fa;\n font-family: \"Inter\";\n font-weight: 400; }\n body .ant-menu {\n background-color: #f4f5fa; }\n body .ant-layout-header {\n background-color: #f4f5fa; }\n body .ant-layout {\n background-color: #f4f5fa; }\n body .ant-menu-submenu .ant-menu {\n background-color: #f4f5fa; }\n body .ant-menu-item {\n background-color: #f4f5fa; }\n body .ant-menu-sub {\n background-color: #f4f5fa; }\n body .ant-table-content {\n font-family: \"Inter\"; }\n body .ant-input {\n border-radius: 5px !important; }\n body .ant-btn {\n border-radius: 5px !important; }\n body .ant-input-group-addon:first-child {\n border-radius: 5px !important; }\n body .ant-input-group .ant-input {\n width: 99% !important; }\n body .ant-radio-group {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between; }\n body .ant-radio-group-large .ant-radio-button-wrapper {\n font-size: 0.8rem;\n width: 25%;\n border-radius: 5px !important; }\n body .ant-upload-list-picture .ant-upload-list-item-error,\n body .ant-upload-list-picture-card .ant-upload-list-item-error {\n border-color: #40a9ff;\n border-radius: 5px;\n height: 40px; }\n body .ant-upload-list-picture .ant-upload-list-item-error .ant-upload-list-item-name,\n body .ant-upload-list-picture-card .ant-upload-list-item-error .ant-upload-list-item-name {\n color: #40a9ff !important; }\n body .ant-upload-list-item-error .ant-upload-list-item-card-actions .anticon {\n color: #40a9ff; }\n body .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input,\n body .ant-input-status-error:not(.ant-input-disabled):not(.ant-input-borderless).ant-input:hover {\n border-color: #d9d9d9 !important; }\n body .ant-input-group-wrapper-status-error .ant-input-group-addon {\n border-color: #d9d9d9 !important; }\n body .ant-form-item-explain-error {\n font-size: 13px;\n color: rgba(255, 77, 79, 0.8); }\n body .ant-table-thead\n> tr\n> th:not(:last-child):not(.ant-table-selection-column):not(.ant-table-row-expand-icon-cell):not([colspan])::before {\n background-color: transparent !important; }\n body .ant-form-item-label > label {\n flex-direction: row-reverse !important;\n color: rgba(58, 53, 65, 0.5); }\n body .ant-form-item-label\n> label.ant-form-item-required:not(.ant-form-item-required-mark-optional)::before {\n margin-left: 0.2rem !important;\n color: rgba(255, 77, 79, 0.8) !important; }\n body .ant-picker {\n border-radius: 5px !important;\n height: 35px !important; }\n body .space-container {\n width: 100%; }\n body .space-container .ant-space-item {\n width: 100%; }\n body .PhoneInput .PhoneInputCountry {\n border: 1px solid #d9d9d9 !important;\n border-radius: 5px !important;\n padding: 0 1rem 0 1rem; }\n body .PhoneInput .PhoneInputInput {\n flex: 1 1;\n min-width: 0;\n border-radius: 5px !important;\n height: 40px;\n border: 1px solid #d9d9d9 !important;\n outline: none; }\n body .filter-title {\n color: rgba(58, 53, 65, 0.8);\n font-family: 'Inter';\n font-style: normal;\n font-weight: 600;\n font-size: 0.875rem; }\n body .ant-radio-wrapper {\n font-family: 'Inter';\n font-style: normal;\n font-weight: 400;\n font-size: 0.875rem;\n line-height: 22px;\n color: rgba(58, 53, 65, 0.8); }\n body .ant-list-item {\n color: rgba(58, 53, 65, 0.8); }\n body .PhoneInput .PhoneInputInput:focus-visible,\n body .PhoneInput .PhoneInputInput:hover {\n flex: 1 1;\n min-width: 0;\n border-radius: 5px !important;\n height: 40px;\n border-right: 1px solid #40a9ff !important;\n outline: 1px solid #40a9ff; }\n body .layout-content-container {\n padding-bottom: 100px; }\n body .layout-content-container .ant-btn-primary {\n background-color: #16b1ff;\n color: #ffffff;\n border: none; }\n body .layout-content-container .ant-btn {\n height: 32px;\n font-weight: 500;\n font-size: 0.8rem;\n border-radius: 0.3rem;\n box-shadow: 0px 8px 16px rgba(0, 0, 0, 0.25);\n min-width: 80px;\n box-shadow: none; }\n body .layout-content-container .ant-btn span {\n text-transform: uppercase; }\n body .content-container {\n padding: 0px 20px; }\n body .content-container .title-bar {\n padding: 0px 0px 30px 0px; }\n body .content-container .body-title {\n color: #16b1ff;\n font-weight: 500;\n font-size: 1.2rem; }\n body .content-container .body-sub-title {\n color: rgba(58, 53, 65, 0.6);\n font-weight: 400;\n font-size: 0.8rem; }\n body .content-card {\n background-color: #ffffff;\n border-radius: 10px;\n width: 100%; }\n body .content-card .action-bar {\n padding: 1.6rem 1.3rem 1.6rem 1.3rem; }\n body .content-card .action-bar button {\n width: fit-content; }\n body .content-card .filter-section {\n padding: 1.4rem 1.3rem 1.6rem 1.3rem;\n display: flex;\n width: 100%;\n flex-direction: row;\n align-items: center;\n justify-content: end; }\n body .content-card .filter-section .search-bar {\n display: flex;\n flex-direction: row-reverse; }\n body .content-card .filter-section .filter-bar {\n display: flex;\n flex-direction: row-reverse;\n margin-top: 0.8rem;\n width: 5%; }\n body .content-card .filter-section .ant-input-affix-wrapper {\n border-radius: 0.313rem 0 0 0.313rem !important; }\n body .content-card .filter-section .ant-input-search\n> .ant-input-group\n> .ant-input-group-addon:last-child\n.ant-input-search-button {\n padding-top: 0;\n padding-bottom: 0;\n border-radius: 0 0.313rem 0.313rem 0 !important; }\n body .layout-content-container .ant-btn {\n min-width: 50px !important; }\n body .table-actions-section {\n width: 100%;\n margin-bottom: 1rem; }\n body .action-menu {\n min-width: 120px;\n color: rgba(58, 53, 65, 0.6); }\n body .action-menu .action-icon {\n margin-right: 12px;\n display: flex; }\n body .action-menu .anticon-edit {\n color: #16b1ff; }\n body .action-menu .anticon-delete {\n color: #f25a29; }\n body .ant-dropdown-menu {\n padding: 1rem 2rem 1rem 1rem !important;\n border-radius: 5px; }\n body .ant-dropdown-menu-item-active {\n background-color: transparent !important; }\n body .ant-popover-inner-content .action-menu {\n margin: -12px -16px; }\n body .ant-popover-inner-content .action-menu .ant-list-item {\n padding: 11px 16px;\n justify-content: flex-start;\n cursor: pointer; }\n body .ant-tag {\n border-radius: 20px; }\n body .clickable {\n cursor: pointer; }\n body .text-center {\n text-align: center; }\n body .float-left {\n float: left; }\n body .float-right {\n float: right; }\n body .apexcharts-canvas {\n font-family: \"Inter\" !important; }\n body .apexcharts-legend-text {\n font-family: \"Inter\" !important; }\n body .ant-tag {\n padding: 1px 10px; }\n body .flex-display {\n display: flex; }\n body .ant-modal-footer {\n border-top: none;\n text-align: center; }\n body .ant-modal-footer button {\n margin: 10px 20px;\n text-transform: uppercase;\n font-size: 0.8rem; }\n body .ant-modal-header {\n border-radius: 15px;\n border: none; }\n body .ant-modal-content {\n border-radius: 15px;\n border: none; }\n body .ant-modal-header {\n border: none; }\n body .ant-modal-body {\n text-align: center;\n color: rgba(58, 53, 65, 0.6);\n font-size: 0.8rem; }\n body .ant-modal-body .ant-select-selector {\n text-align: left;\n border-radius: 5px !important;\n height: 32px; }\n body .ant-modal-body .form-label {\n text-align: left; }\n body .ant-modal-body .form-label .req-ast {\n color: rgba(255, 77, 79, 0.8);\n padding-left: 5px; }\n body .ant-modal-body .ant-form .ant-input-password {\n padding: 6.5px 11px;\n font-size: 16px; }\n body .ant-modal-body .ant-form .ant-form-item-explain-error {\n text-align: start; }\n body .popup-header {\n text-align: center;\n color: rgba(58, 53, 65, 0.8);\n font-weight: 600;\n font-family: \"Inter\";\n font-size: 0.9rem;\n margin: 25px 20px -20px 20px; }\n body .popup-header .icon {\n font-size: 4rem;\n margin-bottom: 15px;\n font-weight: 400; }\n body .popup-header img {\n height: 100px; }\n body .popup-success .icon {\n color: #5dc380; }\n body .popup-success .ant-btn-primary {\n background: #16b1ff;\n border-radius: #16b1ff;\n border: none; }\n body .popup-success .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n body .popup-success .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n body .popup-primary .icon {\n color: #16b1ff; }\n body .popup-primary .ant-btn-primary {\n background: #16b1ff;\n border-radius: #16b1ff;\n border: none; }\n body .popup-primary .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n body .popup-primary .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n body .popup-danger .icon {\n color: rgba(255, 77, 79, 0.8); }\n body .popup-danger .ant-btn-primary {\n background: rgba(255, 77, 79, 0.8);\n border-radius: rgba(255, 77, 79, 0.8);\n border: none; }\n body .popup-danger .ant-btn-primary[disabled] {\n border-color: #d9d9d9;\n background: #f5f5f5; }\n body .popup-danger .ant-btn-default {\n color: rgba(58, 53, 65, 0.6);\n border-color: rgba(58, 53, 65, 0.6); }\n body .ant-modal-footer .ant-btn {\n height: 32px;\n border-radius: 4px;\n padding: 6px 16px;\n font-weight: 500; }\n body .ant-modal-footer .ant-btn-default {\n color: rgba(140, 140, 140, 0.7) !important;\n border-color: rgba(140, 140, 140, 0.7) !important; }\n body .ant-tag-processing {\n color: #16b1ff;\n background: rgba(185, 226, 244, 0.4); }\n body .filter-section input {\n font-family: 'Inter';\n font-size: 0.8rem !important; }\n body .pull-right {\n float: right; }\n body .disabled {\n opacity: 0.5; }\n body .mg-left-3 {\n margin-left: 3rem; }\n body .mg-left-2 {\n margin-left: 2rem !important; }\n body .mg-left-1 {\n margin-left: 1rem; }\n body .mg-top-1 {\n margin-top: 1rem; }\n body .mg-top-2 {\n margin-top: 2rem; }\n body .mg-bottom-1 {\n margin-bottom: 1rem !important; }\n body .transfer-form {\n padding: 0px 15px;\n color: rgba(58, 53, 65, 0.6); }\n body .transfer-form .popup-credit-input .ant-form-item-explain-error {\n width: 200px; }\n body .transfer-form .info-container {\n display: flex;\n flex-direction: row;\n width: 10%;\n height: 20px;\n align-items: center;\n justify-content: start;\n margin-left: 5px; }\n body .transfer-form .ant-row {\n align-items: unset; }\n body .transfer-form .sub-text {\n margin-bottom: 35px;\n font-size: 0.9rem;\n font-weight: 500; }\n body .transfer-form .label {\n text-align: left;\n font-size: 0.9rem;\n color: rgba(58, 53, 65, 0.6); }\n body .transfer-form .seperator {\n font-size: 1.2rem;\n color: #d9d9d9; }\n body .transfer-form .footer {\n margin-bottom: 0px;\n margin-top: 15px; }\n body .transfer-form label {\n font-size: 0.8rem; }\n body .transfer-form .ant-radio-wrapper {\n font-size: 0.9rem; }\n body .transfer-form input {\n color: rgba(58, 53, 65, 0.6); }\n body .transfer-form button {\n text-transform: uppercase;\n font-weight: 500; }\n body .color-error {\n color: rgba(255, 77, 79, 0.8); }\n body .color-primary {\n color: #16b1ff; }\n body .ant-input-number-input {\n text-align: right; }\n body .text-left {\n text-align: left; }\n body .ant-form-item .ant-radio-group {\n text-align: left; }\n body .loading-center {\n margin: auto;\n text-align: center;\n position: absolute;\n top: 50%;\n left: 50%; }\n body .ant-tag-purple {\n color: #976ed7; }\n body .ant-tag-orange {\n color: #ff8f56; }\n body .ant-tag-default {\n color: rgba(58, 53, 65, 0.5); }\n body .ant-popover-inner {\n border-radius: 4px; }\n body .ant-input-number {\n border-radius: 5px; }\n body .ret-icon {\n background-color: rgba(254, 241, 173, 0.5);\n color: #ff8f56; }\n body .flag-ret-icon {\n display: flex !important;\n background-color: #f4f5fa;\n font-size: 1.1rem !important;\n padding: 7px; }\n body .b-icon {\n vertical-align: middle; }\n body .ant-message-notice-content {\n padding: 0px;\n border-radius: 5px; }\n body .ant-message-notice-content .ant-message-custom-content {\n font-size: 0.8rem;\n border-radius: 5px;\n padding: 17px 24px; }\n body .ant-message-notice-content .ant-message-error {\n color: rgba(255, 77, 79, 0.8);\n border: 1px solid rgba(255, 77, 79, 0.8); }\n body .ant-message-notice-content .ant-message-success {\n color: #5bce00;\n border: 1px solid #5bce00; }\n body .ant-select-selection-item {\n color: rgba(58, 53, 65, 0.6); }\n body .sub-text {\n font-size: 0.9rem;\n font-weight: 500; }\n body .search-filter {\n margin-right: 15px; }\n body .mg-bottom-0 {\n margin-bottom: 0px; }\n body .padding-bottom-0 {\n padding-bottom: 0px; }\n body .ellipsis-overflow {\n overflow: hidden;\n text-overflow: ellipsis;\n display: -webkit-box;\n -webkit-line-clamp: 1;\n -webkit-box-orient: vertical; }\n body .nextline-overflow {\n overflow-wrap: break-word; }\n body .ant-message {\n width: 50%;\n right: 0px;\n left: auto;\n min-width: 400px; }\n body .download-data-btn {\n margin-left: 15px; }\n";
|
900
1209
|
styleInject(css_248z$v);
|
901
1210
|
|
902
1211
|
var UserManagementColumns;
|
@@ -968,6 +1277,11 @@ var InvestmentCreationType;
|
|
968
1277
|
InvestmentCreationType["EXISTING"] = "Existing";
|
969
1278
|
InvestmentCreationType["NEW"] = "New";
|
970
1279
|
})(InvestmentCreationType || (InvestmentCreationType = {}));
|
1280
|
+
var InvestmentOwnershipType;
|
1281
|
+
(function (InvestmentOwnershipType) {
|
1282
|
+
InvestmentOwnershipType["PROJECT"] = "Project";
|
1283
|
+
InvestmentOwnershipType["NATIONAL"] = "National";
|
1284
|
+
})(InvestmentOwnershipType || (InvestmentOwnershipType = {}));
|
971
1285
|
var InvestmentStream;
|
972
1286
|
(function (InvestmentStream) {
|
973
1287
|
InvestmentStream["CLIMATE_FINANCE"] = "ClimateFinance";
|
@@ -5865,7 +6179,7 @@ var Projection = /** @class */ (function () {
|
|
5865
6179
|
|
5866
6180
|
var AddNewCompanyComponent = function (props) {
|
5867
6181
|
var _a;
|
5868
|
-
var t = props.t, onNavigateToCompanyManagement = props.onNavigateToCompanyManagement, maximumImageSize = props.maximumImageSize,
|
6182
|
+
var t = props.t, onNavigateToCompanyManagement = props.onNavigateToCompanyManagement, maximumImageSize = props.maximumImageSize, useLocation = props.useLocation, regionField = props.regionField, isGuest = props.isGuest, onNavigateToHome = props.onNavigateToHome, systemType = props.systemType;
|
5869
6183
|
var formOne = Form.useForm()[0];
|
5870
6184
|
var formTwo = Form.useForm()[0];
|
5871
6185
|
var _b = useState(), stepOneData = _b[0], setStepOneData = _b[1];
|
@@ -6751,7 +7065,7 @@ var CompanyDetailsComponent = function (props) {
|
|
6751
7065
|
};
|
6752
7066
|
|
6753
7067
|
var CompanyProfileComponent = function (props) {
|
6754
|
-
var t = props.t, useAbilityContext = props.useAbilityContext, useLocation = props.useLocation,
|
7068
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, useLocation = props.useLocation, onNavigateToCompanyManagement = props.onNavigateToCompanyManagement, onNavigateToCompanyEdit = props.onNavigateToCompanyEdit; props.regionField; var systemType = props.systemType;
|
6755
7069
|
var _a = useConnection(), get = _a.get, put = _a.put, post = _a.post;
|
6756
7070
|
var _b = useState(undefined), companyDetails = _b[0], setCompanyDetails = _b[1];
|
6757
7071
|
var _c = useState(undefined), userDetails = _c[0], setUserDetails = _c[1];
|
@@ -7095,7 +7409,7 @@ styleInject(css_248z$s);
|
|
7095
7409
|
|
7096
7410
|
var Search$1 = Input.Search;
|
7097
7411
|
var ProgrammeManagementComponent = function (props) {
|
7098
|
-
var t = props.t, visibleColumns = props.visibleColumns,
|
7412
|
+
var t = props.t, visibleColumns = props.visibleColumns, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onClickAddProgramme = props.onClickAddProgramme, enableAddProgramme = props.enableAddProgramme, useAbilityContext = props.useAbilityContext;
|
7099
7413
|
var _a = useConnection(); _a.get; _a.delete; var post = _a.post;
|
7100
7414
|
var _b = useState(), totalProgramme = _b[0], setTotalProgramme = _b[1];
|
7101
7415
|
var _c = useState(false), loading = _c[0], setLoading = _c[1];
|
@@ -7530,7 +7844,7 @@ var ProgrammeManagementComponent = function (props) {
|
|
7530
7844
|
React.createElement("div", { className: "filter-section" },
|
7531
7845
|
React.createElement("div", { className: "search-filter" },
|
7532
7846
|
React.createElement(Checkbox, { className: "label", onChange: function (v) {
|
7533
|
-
if (userInfoState.companyRole === CompanyRole.MINISTRY) {
|
7847
|
+
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.MINISTRY) {
|
7534
7848
|
if (v.target.checked) {
|
7535
7849
|
setMinistryLevelFilter(true);
|
7536
7850
|
}
|
@@ -7547,7 +7861,7 @@ var ProgrammeManagementComponent = function (props) {
|
|
7547
7861
|
}
|
7548
7862
|
: undefined);
|
7549
7863
|
}
|
7550
|
-
} }, userInfoState.companyRole === CompanyRole.MINISTRY
|
7864
|
+
} }, (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.MINISTRY
|
7551
7865
|
? t("view:ministryLevel")
|
7552
7866
|
: t("view:seeMine"))),
|
7553
7867
|
React.createElement("div", { className: "search-bar" },
|
@@ -13334,7 +13648,7 @@ var sectoralScopes = {
|
|
13334
13648
|
};
|
13335
13649
|
var ProgrammeCreationComponent = function (props) {
|
13336
13650
|
var _a, _b, _c;
|
13337
|
-
var
|
13651
|
+
var useLocation = props.useLocation, onNavigateToProgrammeView = props.onNavigateToProgrammeView, translator = props.translator;
|
13338
13652
|
var t = translator.t;
|
13339
13653
|
var state = useLocation().state;
|
13340
13654
|
var formOne = Form.useForm()[0];
|
@@ -14399,7 +14713,7 @@ var ChangePasswordModel = function (props) {
|
|
14399
14713
|
|
14400
14714
|
var AddNewUserComponent = function (props) {
|
14401
14715
|
var _a, _b, _c, _d, _e, _f;
|
14402
|
-
var t = props.t, onNavigateToUserManagement = props.onNavigateToUserManagement, onNavigateLogin = props.onNavigateLogin,
|
14716
|
+
var t = props.t, onNavigateToUserManagement = props.onNavigateToUserManagement, onNavigateLogin = props.onNavigateLogin, useLocation = props.useLocation, useAbilityContext = props.useAbilityContext, themeColor = props.themeColor;
|
14403
14717
|
var _g = useConnection(), post = _g.post, put = _g.put, del = _g.delete, get = _g.get;
|
14404
14718
|
var formOne = Form.useForm()[0];
|
14405
14719
|
var state = useLocation().state;
|
@@ -14817,7 +15131,7 @@ var LanguageSelection = function (props) {
|
|
14817
15131
|
};
|
14818
15132
|
|
14819
15133
|
var UserProfileComponent = function (props) {
|
14820
|
-
var t = props.t, i18n = props.i18n,
|
15134
|
+
var t = props.t, i18n = props.i18n, onNavigateUpdateUser = props.onNavigateUpdateUser, onNavigateLogin = props.onNavigateLogin;
|
14821
15135
|
var get = useConnection().get;
|
14822
15136
|
var _a = useState(undefined), organisationDetails = _a[0], setOrganisationDetails = _a[1];
|
14823
15137
|
var _b = useState(undefined), userDetails = _b[0], setUserDetails = _b[1];
|
@@ -14909,7 +15223,7 @@ styleInject(css_248z$n);
|
|
14909
15223
|
|
14910
15224
|
var Search = Input.Search;
|
14911
15225
|
var UserManagementComponent = function (props) {
|
14912
|
-
var t = props.t, useAbilityContext = props.useAbilityContext,
|
15226
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, visibleColumns = props.visibleColumns, onNavigateToUpdateUser = props.onNavigateToUpdateUser, onClickAddUser = props.onClickAddUser;
|
14913
15227
|
Form.useForm()[0];
|
14914
15228
|
var _a = useConnection(), post = _a.post, del = _a.delete;
|
14915
15229
|
var _b = useState(), totalUser = _b[0], setTotalUser = _b[1];
|
@@ -14932,6 +15246,7 @@ var UserManagementComponent = function (props) {
|
|
14932
15246
|
var _t = useState(false), openDeleteConfirmationModal = _t[0], setOpenDeleteConfirmationModal = _t[1];
|
14933
15247
|
var _u = useState(), dataQuery = _u[0], setDataQuery = _u[1];
|
14934
15248
|
var ability = useAbilityContext();
|
15249
|
+
var userInfoState = useUserContext().userInfoState;
|
14935
15250
|
document.addEventListener("mousedown", function (event) {
|
14936
15251
|
var userFilterArea1 = document.querySelector(".filter-bar");
|
14937
15252
|
var userFilterArea2 = document.querySelector(".filter-dropdown");
|
@@ -15499,7 +15814,7 @@ var UserManagementComponent = function (props) {
|
|
15499
15814
|
React.createElement(UserActionConfirmationModel, { t: t, actionInfo: actionInfo, onActionConfirmed: handleOk, onActionCanceled: handleCancel, openModal: openDeleteConfirmationModal, errorMsg: errorMsg, loading: loading })));
|
15500
15815
|
};
|
15501
15816
|
|
15502
|
-
var css_248z$m = ".steps-actions {\n display: flex;\n flex-direction: row-reverse;\n margin-right: 1rem;\n justify-content: flex-start; }\n\n.investment-title-bar {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n padding: 0px 0px 30px 0px; }\n .investment-title-bar .title {\n display: flex;\n flex-direction: column;\n justify-content: space-between; }\n .investment-title-bar .actions {\n display: flex;\n align-items: center;\n justify-content: flex-end; }\n .investment-title-bar .flex-display {\n margin-left: 15px; }\n\n.ownership-container {\n padding: 15px 0px; }\n .ownership-container .label {\n color: rgba(58, 53, 65, 0.5); }\n\n.separator {\n padding: 5px;\n color: #d8d8d8; }\n\n.role-group .ant-col-13 {\n max-width: 320px; }\n\n.role-group .condition-radio-container {\n width: 48%;\n text-align: center; }\n .role-group .condition-radio-container .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {\n color: #ffffff !important;\n border-color: #9155fd !important;\n box-shadow: none;\n max-width: 200px; }\n\n.role-group .ant-radio-button-wrapper::before {\n background-color: transparent; }\n\n.role-group .anticon {\n margin-right: 0.5rem; }\n\n.role-group .ant-radio-button-wrapper {\n border: 1px solid #d9d9d9;\n color: rgba(140, 140, 140, 0.7) !important;\n width: 100% !important; }\n\n.role-group .condition-radio {\n width: 100%;\n text-transform: uppercase; }\n .role-group .condition-radio .ant-radio-button-checked {\n background: #9155fd;\n color: #ffffff; }\n\n.role-group .role-icons {\n margin-right: 5px; }\n\n.investment-management .role-icon {\n padding: 0.5rem 0.6rem; }\n\n.investment-management .ant-tag {\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value
|
15817
|
+
var css_248z$m = ".steps-actions {\n display: flex;\n flex-direction: row-reverse;\n margin-right: 1rem;\n justify-content: flex-start; }\n\n.details-part-two .ant-input-number {\n width: 50%;\n margin-left: 15px; }\n\n.investment-title-bar {\n display: flex;\n flex-direction: row;\n justify-content: space-between;\n padding: 0px 0px 30px 0px; }\n .investment-title-bar .title {\n display: flex;\n flex-direction: column;\n justify-content: space-between; }\n .investment-title-bar .actions {\n display: flex;\n align-items: center;\n justify-content: flex-end; }\n .investment-title-bar .flex-display {\n margin-left: 15px; }\n\n.ownership-container {\n padding: 15px 0px; }\n .ownership-container .label {\n color: rgba(58, 53, 65, 0.5); }\n\n.separator {\n padding: 5px;\n color: #d8d8d8; }\n\n.role-group .ant-col-13 {\n max-width: 320px; }\n\n.role-group .condition-radio-container {\n width: 48%;\n text-align: center; }\n .role-group .condition-radio-container .ant-radio-button-wrapper-checked:not(.ant-radio-button-wrapper-disabled) {\n color: #ffffff !important;\n border-color: #9155fd !important;\n box-shadow: none;\n max-width: 200px; }\n\n.role-group .ant-radio-button-wrapper::before {\n background-color: transparent; }\n\n.role-group .anticon {\n margin-right: 0.5rem; }\n\n.role-group .ant-radio-button-wrapper {\n border: 1px solid #d9d9d9;\n color: rgba(140, 140, 140, 0.7) !important;\n width: 100% !important; }\n\n.role-group .condition-radio {\n width: 100%;\n text-transform: uppercase; }\n .role-group .condition-radio .ant-radio-button-checked {\n background: #9155fd;\n color: #ffffff; }\n\n.role-group .role-icons {\n margin-right: 5px; }\n\n.investment-management .role-icon {\n padding: 0.5rem 0.6rem; }\n\n.investment-management .ant-tag {\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"Rejected\"] + .ant-checkbox-inner {\n background-color: rgba(237, 77, 71, 0.6);\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"Cancelled\"] + .ant-checkbox-inner {\n background-color: rgba(58, 53, 65, 0.4);\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"Accepted\"] + .ant-checkbox-inner {\n background-color: #16b1ff;\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"Pending\"] + .ant-checkbox-inner {\n background-color: rgba(118, 195, 39, 0.6);\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"Recognised\"] + .ant-checkbox-inner {\n background-color: #976ed7;\n border: none; }\n\n.investment-management .ant-checkbox-checked .ant-checkbox-input[value=\"NotRecognised\"] + .ant-checkbox-inner {\n background-color: #ffa070;\n border: none; }\n\n.add-programme-main-container .adding-section .form-section .investment-sought-form-container .investment-sought-form .investment-radio-button .ant-radio-group {\n display: flex;\n flex-direction: row;\n align-items: flex-start;\n justify-content: space-between;\n width: fit-content; }\n\n.add-programme-main-container .adding-section .form-section .investment-sought-form-container .investment-sought-form .details-part-two .row .ant-picker-large {\n height: 40px !important;\n width: 100%; }\n";
|
15503
15818
|
styleInject(css_248z$m);
|
15504
15819
|
|
15505
15820
|
var Loading = function () {
|
@@ -15519,21 +15834,34 @@ var InsurancePayback;
|
|
15519
15834
|
|
15520
15835
|
var RangePicker$3 = DatePicker.RangePicker;
|
15521
15836
|
var InvestmentCreationComponent = function (props) {
|
15522
|
-
var t = props.t,
|
15837
|
+
var t = props.t, useLocation = props.useLocation, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onNavigateToInvestmentManagementView = props.onNavigateToInvestmentManagementView;
|
15523
15838
|
var state = useLocation().state;
|
15524
15839
|
var _a = useState(), data = _a[0], setData = _a[1];
|
15840
|
+
var _b = useState({}), companyNames = _b[0], setCompanyNames = _b[1];
|
15841
|
+
var _c = useState({}); _c[0]; var setUserOrganization = _c[1];
|
15842
|
+
var _d = useState({}), investmentNames = _d[0], setInvestmentNames = _d[1];
|
15843
|
+
var _e = useState(), projectData = _e[0], setProjectData = _e[1];
|
15844
|
+
var _f = useState(), investmentData = _f[0], setInvestmentData = _f[1];
|
15845
|
+
var _g = useState([]), allProjectData = _g[0], setAllProjectData = _g[1];
|
15525
15846
|
var formOne = Form.useForm()[0];
|
15526
15847
|
var formTwo = Form.useForm()[0];
|
15527
15848
|
var post = useConnection().post;
|
15528
|
-
var
|
15529
|
-
var
|
15530
|
-
var
|
15531
|
-
var
|
15532
|
-
var
|
15533
|
-
var
|
15534
|
-
var
|
15535
|
-
var
|
15536
|
-
var
|
15849
|
+
var _h = useState(false), loading = _h[0], setLoading = _h[1];
|
15850
|
+
var _j = useState("New"), typeCreation = _j[0], setTypeCreation = _j[1];
|
15851
|
+
var _k = useState(InvestmentOwnershipType.PROJECT), investmentOwnershipType = _k[0], setInvestmentOwnershipType = _k[1];
|
15852
|
+
var _l = useState(false), loadingList = _l[0], setLoadingList = _l[1];
|
15853
|
+
var _m = useState(false), loadingInvestment = _m[0], setLoadingInvestment = _m[1];
|
15854
|
+
var _o = useState(false), loadingProgData = _o[0], setLoadingProgData = _o[1];
|
15855
|
+
var _p = useState(0), current = _p[0], setCurrent = _p[1];
|
15856
|
+
var _q = useState(0), currentPercTotal = _q[0], setCurrentPercTotal = _q[1];
|
15857
|
+
var _r = useState([]), organisationsList = _r[0], setOrganisationList = _r[1];
|
15858
|
+
var _s = useState([]), nationalInvestmentList = _s[0], setNationalInvestmentList = _s[1];
|
15859
|
+
var _t = useState([]), instrument = _t[0], setInstrument = _t[1];
|
15860
|
+
var _u = useState(), stepOneData = _u[0], setStepOneData = _u[1];
|
15861
|
+
var _v = useState(), govData = _v[0], setGovData = _v[1];
|
15862
|
+
var userInfoState = useUserContext().userInfoState;
|
15863
|
+
var _w = useState([]), ministrySectoralScope = _w[0], setMinistrySectoralScope = _w[1];
|
15864
|
+
var _x = useState({}), prevInvestor = _x[0], setPrevInvestor = _x[1];
|
15537
15865
|
var instrumentOptions = Object.keys(Instrument).map(function (k, index) { return ({
|
15538
15866
|
label: addSpaces(Object.values(Instrument)[index]),
|
15539
15867
|
value: Object.values(Instrument)[index],
|
@@ -15585,52 +15913,225 @@ var InvestmentCreationComponent = function (props) {
|
|
15585
15913
|
}
|
15586
15914
|
});
|
15587
15915
|
}); };
|
15588
|
-
var
|
15589
|
-
var
|
15916
|
+
var getAllProjectData = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15917
|
+
var response, error_2;
|
15918
|
+
return __generator(this, function (_a) {
|
15919
|
+
switch (_a.label) {
|
15920
|
+
case 0:
|
15921
|
+
setLoadingProgData(true);
|
15922
|
+
_a.label = 1;
|
15923
|
+
case 1:
|
15924
|
+
_a.trys.push([1, 5, 6, 7]);
|
15925
|
+
if (!data) return [3 /*break*/, 4];
|
15926
|
+
if (!!(data === null || data === void 0 ? void 0 : data.programmeId)) return [3 /*break*/, 3];
|
15927
|
+
console.log("data non existing", data);
|
15928
|
+
console.log("getting all Project data");
|
15929
|
+
return [4 /*yield*/, post("national/programme/query", {
|
15930
|
+
page: 1,
|
15931
|
+
size: 100,
|
15932
|
+
filterAnd: [
|
15933
|
+
{
|
15934
|
+
key: "currentStage",
|
15935
|
+
operation: "!=",
|
15936
|
+
value: ProgrammeStageUnified.Rejected,
|
15937
|
+
},
|
15938
|
+
],
|
15939
|
+
})];
|
15940
|
+
case 2:
|
15941
|
+
response = _a.sent();
|
15942
|
+
if (response.data) {
|
15943
|
+
setAllProjectData(response === null || response === void 0 ? void 0 : response.data);
|
15944
|
+
console.log("all Project data", response === null || response === void 0 ? void 0 : response.data);
|
15945
|
+
}
|
15946
|
+
return [3 /*break*/, 4];
|
15947
|
+
case 3:
|
15948
|
+
console.log("setting current Project data");
|
15949
|
+
setAllProjectData([data]);
|
15950
|
+
_a.label = 4;
|
15951
|
+
case 4: return [3 /*break*/, 7];
|
15952
|
+
case 5:
|
15953
|
+
error_2 = _a.sent();
|
15954
|
+
console.log("Error in getting all programme data", error_2);
|
15955
|
+
return [3 /*break*/, 7];
|
15956
|
+
case 6:
|
15957
|
+
setLoadingProgData(false);
|
15958
|
+
return [7 /*endfinally*/];
|
15959
|
+
case 7: return [2 /*return*/];
|
15960
|
+
}
|
15961
|
+
});
|
15962
|
+
}); };
|
15963
|
+
var setSelectedProgramme = function (value) { return __awaiter(void 0, void 0, void 0, function () {
|
15964
|
+
var _i, allProjectData_1, obj;
|
15965
|
+
return __generator(this, function (_a) {
|
15966
|
+
console.log("setSelectedProgramme", value);
|
15967
|
+
for (_i = 0, allProjectData_1 = allProjectData; _i < allProjectData_1.length; _i++) {
|
15968
|
+
obj = allProjectData_1[_i];
|
15969
|
+
if (obj.programmeId == value) {
|
15970
|
+
setProjectData(obj);
|
15971
|
+
break;
|
15972
|
+
}
|
15973
|
+
}
|
15974
|
+
return [2 /*return*/];
|
15975
|
+
});
|
15976
|
+
}); };
|
15977
|
+
var setSelectedInvestment = function (value) { return __awaiter(void 0, void 0, void 0, function () {
|
15978
|
+
return __generator(this, function (_a) {
|
15979
|
+
console.log("setSelectedInvestment", value);
|
15980
|
+
setInvestmentData(investmentNames[value]);
|
15981
|
+
return [2 /*return*/];
|
15982
|
+
});
|
15983
|
+
}); };
|
15984
|
+
var getNationalInvestmentDetails = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15985
|
+
var optionalFilters, filterAnd, filterOr_1, response, investmentData_1, _i, _a, investment, error_3;
|
15590
15986
|
return __generator(this, function (_b) {
|
15591
15987
|
switch (_b.label) {
|
15592
15988
|
case 0:
|
15593
|
-
|
15989
|
+
setLoadingInvestment(true);
|
15594
15990
|
_b.label = 1;
|
15595
15991
|
case 1:
|
15596
15992
|
_b.trys.push([1, 3, 4, 5]);
|
15993
|
+
optionalFilters = {};
|
15597
15994
|
filterAnd = [];
|
15598
15995
|
filterAnd = [
|
15599
15996
|
{
|
15600
|
-
key: "
|
15997
|
+
key: "category",
|
15601
15998
|
operation: "=",
|
15602
|
-
value:
|
15999
|
+
value: InvestmentOwnershipType.NATIONAL.toString(),
|
16000
|
+
},
|
16001
|
+
{
|
16002
|
+
key: "amount",
|
16003
|
+
operation: ">",
|
16004
|
+
value: 0,
|
15603
16005
|
},
|
15604
16006
|
];
|
15605
16007
|
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.PROGRAMME_DEVELOPER) {
|
15606
16008
|
filterAnd.push({
|
15607
|
-
key: "
|
15608
|
-
operation: "
|
16009
|
+
key: "toCompanyId",
|
16010
|
+
operation: "=",
|
15609
16011
|
value: userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyId,
|
15610
16012
|
});
|
15611
16013
|
}
|
15612
|
-
|
15613
|
-
|
15614
|
-
|
15615
|
-
|
15616
|
-
|
15617
|
-
|
16014
|
+
else if (((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.GOVERNMENT ||
|
16015
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === CompanyRole.MINISTRY) &&
|
16016
|
+
(data === null || data === void 0 ? void 0 : data.programmeId)) {
|
16017
|
+
filterOr_1 = [];
|
16018
|
+
data.companyId.map(function (id) {
|
16019
|
+
return filterOr_1.push({
|
16020
|
+
key: "toCompanyId",
|
16021
|
+
operation: "=",
|
16022
|
+
value: id,
|
16023
|
+
});
|
15618
16024
|
});
|
16025
|
+
optionalFilters.filterOr = filterOr_1;
|
15619
16026
|
}
|
15620
|
-
return [4 /*yield*/, post("national/
|
16027
|
+
return [4 /*yield*/, post("national/programme/investmentQuery", __assign({ page: 1, size: 100, filterAnd: filterAnd }, optionalFilters))];
|
16028
|
+
case 2:
|
16029
|
+
response = _b.sent();
|
16030
|
+
if (response.data) {
|
16031
|
+
setNationalInvestmentList(response === null || response === void 0 ? void 0 : response.data);
|
16032
|
+
investmentData_1 = {};
|
16033
|
+
for (_i = 0, _a = response === null || response === void 0 ? void 0 : response.data; _i < _a.length; _i++) {
|
16034
|
+
investment = _a[_i];
|
16035
|
+
investmentData_1[investment.requestId] = investment;
|
16036
|
+
}
|
16037
|
+
setInvestmentNames(investmentData_1);
|
16038
|
+
console.log(investmentData_1);
|
16039
|
+
}
|
16040
|
+
return [3 /*break*/, 5];
|
16041
|
+
case 3:
|
16042
|
+
error_3 = _b.sent();
|
16043
|
+
console.log("Error in getting national Investments list", error_3);
|
16044
|
+
return [3 /*break*/, 5];
|
16045
|
+
case 4:
|
16046
|
+
setLoadingInvestment(false);
|
16047
|
+
return [7 /*endfinally*/];
|
16048
|
+
case 5: return [2 /*return*/];
|
16049
|
+
}
|
16050
|
+
});
|
16051
|
+
}); };
|
16052
|
+
var getUserOrganization = function () { return __awaiter(void 0, void 0, void 0, function () {
|
16053
|
+
var response, error_4;
|
16054
|
+
return __generator(this, function (_a) {
|
16055
|
+
switch (_a.label) {
|
16056
|
+
case 0:
|
16057
|
+
_a.trys.push([0, 2, , 3]);
|
16058
|
+
return [4 /*yield*/, post("national/organisation/query", {
|
15621
16059
|
page: 1,
|
15622
16060
|
size: 100,
|
15623
|
-
filterAnd:
|
16061
|
+
filterAnd: [
|
16062
|
+
{ key: "companyId", operation: "=", value: userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyId },
|
16063
|
+
],
|
15624
16064
|
})];
|
16065
|
+
case 1:
|
16066
|
+
response = _a.sent();
|
16067
|
+
console.log("getUserOrganization", response.data[0]);
|
16068
|
+
setUserOrganization(response.data[0]);
|
16069
|
+
setMinistrySectoralScope(response.data[0].sectoralScope);
|
16070
|
+
return [3 /*break*/, 3];
|
15625
16071
|
case 2:
|
15626
|
-
|
16072
|
+
error_4 = _a.sent();
|
16073
|
+
console.log("Error in getting user organization", error_4);
|
16074
|
+
return [3 /*break*/, 3];
|
16075
|
+
case 3: return [2 /*return*/];
|
16076
|
+
}
|
16077
|
+
});
|
16078
|
+
}); };
|
16079
|
+
var getOrganisationsDetails = function () { return __awaiter(void 0, void 0, void 0, function () {
|
16080
|
+
var filterAnd, filterOr, _i, _a, c, filters, response, companyName, _b, _c, company, error_5;
|
16081
|
+
return __generator(this, function (_d) {
|
16082
|
+
switch (_d.label) {
|
16083
|
+
case 0:
|
16084
|
+
setLoadingList(true);
|
16085
|
+
_d.label = 1;
|
16086
|
+
case 1:
|
16087
|
+
_d.trys.push([1, 3, 4, 5]);
|
16088
|
+
filterAnd = [];
|
16089
|
+
filterOr = [];
|
16090
|
+
filterAnd = [
|
16091
|
+
{
|
16092
|
+
key: "companyRole",
|
16093
|
+
operation: "=",
|
16094
|
+
value: CompanyRole.PROGRAMME_DEVELOPER.toString(),
|
16095
|
+
},
|
16096
|
+
];
|
16097
|
+
// if (userInfoState?.companyRole === CompanyRole.PROGRAMME_DEVELOPER) {
|
16098
|
+
// filterAnd.push({
|
16099
|
+
// key: "companyId",
|
16100
|
+
// operation: "!=",
|
16101
|
+
// value: userInfoState?.companyId,
|
16102
|
+
// });
|
16103
|
+
// }
|
16104
|
+
if (data === null || data === void 0 ? void 0 : data.companyId) {
|
16105
|
+
for (_i = 0, _a = data === null || data === void 0 ? void 0 : data.companyId; _i < _a.length; _i++) {
|
16106
|
+
c = _a[_i];
|
16107
|
+
filterOr.push({
|
16108
|
+
key: "companyId",
|
16109
|
+
operation: "=",
|
16110
|
+
value: c,
|
16111
|
+
});
|
16112
|
+
}
|
16113
|
+
}
|
16114
|
+
filters = void 0;
|
16115
|
+
if (filterOr.length) {
|
16116
|
+
filters.filterOr = filterOr;
|
16117
|
+
}
|
16118
|
+
return [4 /*yield*/, post("national/organisation/queryNames", __assign({ page: 1, size: 100, filterAnd: filterAnd }, filters))];
|
16119
|
+
case 2:
|
16120
|
+
response = _d.sent();
|
15627
16121
|
if (response.data) {
|
15628
16122
|
setOrganisationList(response === null || response === void 0 ? void 0 : response.data);
|
16123
|
+
companyName = {};
|
16124
|
+
for (_b = 0, _c = response === null || response === void 0 ? void 0 : response.data; _b < _c.length; _b++) {
|
16125
|
+
company = _c[_b];
|
16126
|
+
companyName[Number(company.companyId)] = company.name;
|
16127
|
+
}
|
16128
|
+
setCompanyNames(companyName);
|
16129
|
+
console.log(companyName);
|
15629
16130
|
}
|
15630
16131
|
return [3 /*break*/, 5];
|
15631
16132
|
case 3:
|
15632
|
-
|
15633
|
-
console.log("Error in getting organization list",
|
16133
|
+
error_5 = _d.sent();
|
16134
|
+
console.log("Error in getting organization list", error_5);
|
15634
16135
|
return [3 /*break*/, 5];
|
15635
16136
|
case 4:
|
15636
16137
|
setLoadingList(false);
|
@@ -15645,52 +16146,72 @@ var InvestmentCreationComponent = function (props) {
|
|
15645
16146
|
return;
|
15646
16147
|
}
|
15647
16148
|
if (state === null || state === void 0 ? void 0 : state.record) {
|
16149
|
+
console.log("condition 1 data", state === null || state === void 0 ? void 0 : state.record);
|
15648
16150
|
setData(state === null || state === void 0 ? void 0 : state.record);
|
15649
16151
|
}
|
15650
16152
|
else {
|
16153
|
+
console.log("condition 2 data", { ownership: true });
|
15651
16154
|
setData({ ownership: true });
|
15652
16155
|
}
|
15653
16156
|
}, []);
|
15654
16157
|
useEffect(function () {
|
15655
|
-
if (data) {
|
15656
|
-
|
15657
|
-
|
15658
|
-
|
15659
|
-
|
15660
|
-
}
|
16158
|
+
// if (data) {
|
16159
|
+
// const keys = Object.keys(data);
|
16160
|
+
// if (keys[0] !== "ownership") {
|
16161
|
+
// getOrganisationsDetails();
|
16162
|
+
// }
|
16163
|
+
// }
|
16164
|
+
getNationalInvestmentDetails();
|
16165
|
+
getOrganisationsDetails();
|
15661
16166
|
getGovernmentDetails();
|
16167
|
+
getAllProjectData();
|
16168
|
+
getUserOrganization();
|
15662
16169
|
}, [data]);
|
15663
|
-
if (!data) {
|
16170
|
+
if (!data && allProjectData.length == 0) {
|
15664
16171
|
return React.createElement(Loading, null);
|
15665
16172
|
}
|
15666
16173
|
console.log("data", data);
|
15667
|
-
|
16174
|
+
console.log("data", data);
|
15668
16175
|
if (data && Object.keys(data)[0] !== "ownership") {
|
15669
|
-
for (
|
15670
|
-
|
15671
|
-
|
15672
|
-
}
|
16176
|
+
// for (const company of data!?.company) {
|
16177
|
+
// companyName[company?.companyId] = company;
|
16178
|
+
// }
|
15673
16179
|
if (!data.proponentPercentage) {
|
15674
16180
|
data.proponentPercentage = [100];
|
15675
16181
|
}
|
15676
16182
|
}
|
15677
16183
|
var nextOne = function (val) {
|
16184
|
+
console.log("step 1 values", val);
|
16185
|
+
if (val.typeCreation == InvestmentCreationType.EXISTING) {
|
16186
|
+
val.toCompanyId = investmentData.toCompanyId;
|
16187
|
+
}
|
15678
16188
|
setCurrent(current + 1);
|
15679
16189
|
setStepOneData(val);
|
16190
|
+
if (data === null || data === void 0 ? void 0 : data.programmeId)
|
16191
|
+
setSelectedProgramme(data.programmeId);
|
16192
|
+
if (prevInvestor && prevInvestor != val.toCompanyId && !(data === null || data === void 0 ? void 0 : data.programmeId)) {
|
16193
|
+
formTwo.resetFields();
|
16194
|
+
setCurrentPercTotal(0);
|
16195
|
+
setProjectData(undefined);
|
16196
|
+
}
|
15680
16197
|
};
|
15681
16198
|
var prevOne = function () {
|
15682
16199
|
setCurrent(current - 1);
|
16200
|
+
setPrevInvestor(stepOneData.toCompanyId);
|
16201
|
+
// formTwo.resetFields();
|
16202
|
+
// setCurrentPercTotal(0);
|
16203
|
+
// setProjectData(undefined);
|
15683
16204
|
};
|
15684
16205
|
var submitInvestment = function (val) { return __awaiter(void 0, void 0, void 0, function () {
|
15685
|
-
var payload, response,
|
16206
|
+
var payload, response, error_6;
|
15686
16207
|
return __generator(this, function (_a) {
|
15687
16208
|
switch (_a.label) {
|
15688
16209
|
case 0:
|
15689
16210
|
console.log(val);
|
15690
16211
|
console.log(stepOneData);
|
16212
|
+
console.log("OwnershipType", investmentOwnershipType);
|
15691
16213
|
setLoading(true);
|
15692
16214
|
payload = stepOneData;
|
15693
|
-
payload.programmeId = data.programmeId;
|
15694
16215
|
payload.amount = parseFloat(payload.amount);
|
15695
16216
|
if (payload.interestRate) {
|
15696
16217
|
payload.interestRate = parseFloat(payload.interestRate);
|
@@ -15707,16 +16228,32 @@ var InvestmentCreationComponent = function (props) {
|
|
15707
16228
|
.startOf("day")
|
15708
16229
|
.unix();
|
15709
16230
|
}
|
15710
|
-
payload.instrument = [payload.instrument];
|
15711
|
-
payload.fromCompanyIds = data.companyId.map(function (e) { return Number(e); });
|
15712
|
-
payload.percentage = val.percentage;
|
15713
16231
|
payload.toCompanyId = Number(payload.toCompanyId);
|
15714
16232
|
_a.label = 1;
|
15715
16233
|
case 1:
|
15716
|
-
_a.trys.push([1,
|
16234
|
+
_a.trys.push([1, 6, 7, 8]);
|
16235
|
+
response = void 0;
|
16236
|
+
if (!(investmentOwnershipType == InvestmentOwnershipType.PROJECT)) return [3 /*break*/, 3];
|
16237
|
+
if (typeCreation == InvestmentCreationType.EXISTING) {
|
16238
|
+
payload.nationalInvestmentId = investmentData.requestId;
|
16239
|
+
}
|
16240
|
+
else {
|
16241
|
+
payload.instrument = [payload.instrument];
|
16242
|
+
}
|
16243
|
+
payload.programmeId = projectData === null || projectData === void 0 ? void 0 : projectData.programmeId;
|
16244
|
+
payload.fromCompanyIds = projectData === null || projectData === void 0 ? void 0 : projectData.companyId.map(function (e) { return Number(e); });
|
16245
|
+
payload.percentage = val.percentage;
|
15717
16246
|
return [4 /*yield*/, post("national/programme/addInvestment", payload)];
|
15718
16247
|
case 2:
|
15719
16248
|
response = _a.sent();
|
16249
|
+
return [3 /*break*/, 5];
|
16250
|
+
case 3:
|
16251
|
+
payload.instrument = [payload.instrument];
|
16252
|
+
return [4 /*yield*/, post("national/organisation/addInvestment", payload)];
|
16253
|
+
case 4:
|
16254
|
+
response = _a.sent();
|
16255
|
+
_a.label = 5;
|
16256
|
+
case 5:
|
15720
16257
|
console.log("investment creation -> ", response);
|
15721
16258
|
if ((response === null || response === void 0 ? void 0 : response.statusText) === "SUCCESS") {
|
15722
16259
|
message.open({
|
@@ -15726,22 +16263,24 @@ var InvestmentCreationComponent = function (props) {
|
|
15726
16263
|
style: { textAlign: "right", marginRight: 15, marginTop: 10 },
|
15727
16264
|
});
|
15728
16265
|
}
|
15729
|
-
|
15730
|
-
|
15731
|
-
|
15732
|
-
|
15733
|
-
|
16266
|
+
(data === null || data === void 0 ? void 0 : data.programmeId)
|
16267
|
+
? onNavigateToProgrammeView(data === null || data === void 0 ? void 0 : data.programmeId)
|
16268
|
+
: onNavigateToInvestmentManagementView();
|
16269
|
+
return [3 /*break*/, 8];
|
16270
|
+
case 6:
|
16271
|
+
error_6 = _a.sent();
|
16272
|
+
console.log("Error in investment creation - ", error_6);
|
15734
16273
|
message.open({
|
15735
16274
|
type: "error",
|
15736
|
-
content:
|
16275
|
+
content: error_6 === null || error_6 === void 0 ? void 0 : error_6.message,
|
15737
16276
|
duration: 4,
|
15738
16277
|
style: { textAlign: "right", marginRight: 15, marginTop: 10 },
|
15739
16278
|
});
|
15740
|
-
return [3 /*break*/,
|
15741
|
-
case
|
16279
|
+
return [3 /*break*/, 8];
|
16280
|
+
case 7:
|
15742
16281
|
setLoading(false);
|
15743
16282
|
return [7 /*endfinally*/];
|
15744
|
-
case
|
16283
|
+
case 8: return [2 /*return*/];
|
15745
16284
|
}
|
15746
16285
|
});
|
15747
16286
|
}); };
|
@@ -15755,6 +16294,14 @@ var InvestmentCreationComponent = function (props) {
|
|
15755
16294
|
var onChangeTypeCreation = function (e) {
|
15756
16295
|
console.log("radio checked", e.target.value);
|
15757
16296
|
setTypeCreation(e.target.value);
|
16297
|
+
formOne.resetFields();
|
16298
|
+
formTwo.resetFields();
|
16299
|
+
setCurrentPercTotal(0);
|
16300
|
+
setProjectData(undefined);
|
16301
|
+
};
|
16302
|
+
var onChangeInvestmentOwnershipType = function (e) {
|
16303
|
+
console.log("investment ownership type radio checked", e.target.value);
|
16304
|
+
setInvestmentOwnershipType(e.target.value);
|
15758
16305
|
};
|
15759
16306
|
return (React.createElement("div", { className: "add-programme-main-container" },
|
15760
16307
|
React.createElement("div", { className: "title-container" },
|
@@ -15779,134 +16326,60 @@ var InvestmentCreationComponent = function (props) {
|
|
15779
16326
|
] },
|
15780
16327
|
React.createElement(Radio.Group, { size: "large", defaultValue: typeCreation }, Object.values(InvestmentCreationType).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
15781
16328
|
React.createElement(Radio.Button, { className: "condition-radio", value: k, onChange: onChangeTypeCreation }, t("programme:" + k)))); }))))),
|
15782
|
-
React.createElement(
|
15783
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
15784
|
-
React.createElement("div", { className: "details-part-one" },
|
15785
|
-
React.createElement(Form.Item, { label: t("programme:investorName"), name: "toCompanyId", wrapperCol: { span: 24 }, className: "organisation", rules: [
|
15786
|
-
{
|
15787
|
-
required: true,
|
15788
|
-
message: "".concat(t("programme:investorName"), " ").concat(t("isRequired")),
|
15789
|
-
},
|
15790
|
-
] },
|
15791
|
-
React.createElement(Select, { size: "large", loading: loadingList }, organisationsList.map(function (organisation) { return (React.createElement(Select.Option, { key: organisation.companyId, value: organisation.companyId }, organisation.name)); }))))),
|
15792
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
15793
|
-
React.createElement("div", { className: "details-part-two" },
|
15794
|
-
React.createElement(Form.Item, { label: t("programme:amountInvested"), name: "amount", rules: [
|
15795
|
-
{
|
15796
|
-
required: true,
|
15797
|
-
message: "",
|
15798
|
-
},
|
15799
|
-
{
|
15800
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
15801
|
-
return __generator(this, function (_a) {
|
15802
|
-
if (String(value).trim() === "" ||
|
15803
|
-
String(value).trim() === undefined ||
|
15804
|
-
value === null ||
|
15805
|
-
value === undefined) {
|
15806
|
-
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isRequired")));
|
15807
|
-
}
|
15808
|
-
else if (!isNaN(value) &&
|
15809
|
-
Number(value) > 0) {
|
15810
|
-
return [2 /*return*/, Promise.resolve()];
|
15811
|
-
}
|
15812
|
-
else {
|
15813
|
-
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isInvalid")));
|
15814
|
-
}
|
15815
|
-
});
|
15816
|
-
}); },
|
15817
|
-
},
|
15818
|
-
] },
|
15819
|
-
React.createElement(Input, { size: "large" }))))),
|
15820
|
-
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15821
|
-
React.createElement(Col, { xl: 24, md: 24 },
|
15822
|
-
React.createElement(Form.Item, { label: t("programme:instrument"), name: "instrument",
|
15823
|
-
//wrapperCol={{ span: 24 }}
|
15824
|
-
required: true, className: "investment-radio-button", rules: [
|
15825
|
-
{
|
15826
|
-
required: true,
|
15827
|
-
message: "",
|
15828
|
-
},
|
15829
|
-
{
|
15830
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
15831
|
-
return __generator(this, function (_a) {
|
15832
|
-
if (String(value).trim() === "" ||
|
15833
|
-
String(value).trim() === undefined ||
|
15834
|
-
value === null ||
|
15835
|
-
value === undefined) {
|
15836
|
-
throw new Error("".concat(t("programme:instrument"), " ").concat(t("isRequired")));
|
15837
|
-
}
|
15838
|
-
return [2 /*return*/];
|
15839
|
-
});
|
15840
|
-
}); },
|
15841
|
-
},
|
15842
|
-
] },
|
15843
|
-
React.createElement(Radio.Group, { onChange: onInstrumentChange, value: instrument[0] }, instrumentOptions.map(function (e) {
|
15844
|
-
return (React.createElement(Radio, { value: e.value }, e.label));
|
15845
|
-
}))))),
|
15846
|
-
instrument &&
|
15847
|
-
instrument.indexOf(Instrument.LOAN) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15848
|
-
React.createElement(Col, { xl: 8, md: 12 },
|
15849
|
-
React.createElement("div", { className: "details-part-two" },
|
15850
|
-
React.createElement(Form.Item, { label: t("programme:interestRate"), name: "interestRate", rules: [
|
15851
|
-
{
|
15852
|
-
required: true,
|
15853
|
-
message: "",
|
15854
|
-
},
|
15855
|
-
{
|
15856
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
15857
|
-
return __generator(this, function (_a) {
|
15858
|
-
if (String(value).trim() === "" ||
|
15859
|
-
String(value).trim() ===
|
15860
|
-
undefined ||
|
15861
|
-
value === null ||
|
15862
|
-
value === undefined) {
|
15863
|
-
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isRequired")));
|
15864
|
-
}
|
15865
|
-
else if (!isNaN(value)) {
|
15866
|
-
return [2 /*return*/, Promise.resolve()];
|
15867
|
-
}
|
15868
|
-
else {
|
15869
|
-
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isInvalid")));
|
15870
|
-
}
|
15871
|
-
});
|
15872
|
-
}); },
|
15873
|
-
},
|
15874
|
-
] },
|
15875
|
-
React.createElement(Input, { size: "large" })))))),
|
15876
|
-
instrument &&
|
15877
|
-
(instrument.indexOf(Instrument.CONLOAN) >= 0 ||
|
15878
|
-
instrument.indexOf(Instrument.NONCONLOAN) >= 0) && (React.createElement("div", { className: "details-part-two" },
|
16329
|
+
typeCreation == InvestmentCreationType.NEW && (React.createElement("div", null,
|
15879
16330
|
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15880
|
-
React.createElement(Col, { xl:
|
15881
|
-
React.createElement(
|
15882
|
-
|
15883
|
-
|
15884
|
-
|
15885
|
-
|
15886
|
-
|
15887
|
-
|
15888
|
-
|
15889
|
-
|
15890
|
-
|
15891
|
-
|
15892
|
-
|
15893
|
-
|
15894
|
-
|
15895
|
-
|
15896
|
-
|
15897
|
-
|
15898
|
-
|
15899
|
-
|
15900
|
-
|
15901
|
-
|
15902
|
-
|
15903
|
-
|
15904
|
-
|
15905
|
-
|
15906
|
-
|
16331
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16332
|
+
React.createElement("div", { className: "details-part-one" },
|
16333
|
+
React.createElement(Form.Item, { label: t("programme:investorName"), name: "toCompanyId", wrapperCol: { span: 24 }, className: "organisation", rules: [
|
16334
|
+
{
|
16335
|
+
required: true,
|
16336
|
+
message: "".concat(t("programme:investorName"), " ").concat(t("isRequired")),
|
16337
|
+
},
|
16338
|
+
] },
|
16339
|
+
React.createElement(Select, { size: "large", loading: loadingList }, organisationsList.map(function (organisation) {
|
16340
|
+
if (data === null || data === void 0 ? void 0 : data.programmeId) {
|
16341
|
+
if (data.companyId
|
16342
|
+
.map(function (id) { return Number(id); })
|
16343
|
+
.includes(Number(organisation.companyId))) {
|
16344
|
+
return (React.createElement(Select.Option, { key: organisation.companyId, value: organisation.companyId }, organisation.name));
|
16345
|
+
}
|
16346
|
+
}
|
16347
|
+
else {
|
16348
|
+
return (React.createElement(Select.Option, { key: organisation.companyId, value: organisation.companyId }, organisation.name));
|
16349
|
+
}
|
16350
|
+
}))))),
|
16351
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16352
|
+
React.createElement("div", { className: "details-part-two" },
|
16353
|
+
React.createElement(Form.Item, { label: t("programme:amountInvested"), name: "amount", rules: [
|
16354
|
+
{
|
16355
|
+
required: true,
|
16356
|
+
message: "",
|
16357
|
+
},
|
16358
|
+
{
|
16359
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16360
|
+
return __generator(this, function (_a) {
|
16361
|
+
if (String(value).trim() === "" ||
|
16362
|
+
String(value).trim() ===
|
16363
|
+
undefined ||
|
16364
|
+
value === null ||
|
16365
|
+
value === undefined) {
|
16366
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isRequired")));
|
16367
|
+
}
|
16368
|
+
else if (!isNaN(value) &&
|
16369
|
+
Number(value) > 0) {
|
16370
|
+
return [2 /*return*/, Promise.resolve()];
|
16371
|
+
}
|
16372
|
+
else {
|
16373
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isInvalid")));
|
16374
|
+
}
|
16375
|
+
});
|
16376
|
+
}); },
|
16377
|
+
},
|
16378
|
+
] },
|
16379
|
+
React.createElement(Input, { size: "large" }))))),
|
15907
16380
|
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15908
|
-
React.createElement(Col, { xl:
|
15909
|
-
React.createElement(Form.Item, { label: t("programme:
|
16381
|
+
React.createElement(Col, { xl: 24, md: 24 },
|
16382
|
+
React.createElement(Form.Item, { label: t("programme:instrument"), name: "instrument", required: true, className: "investment-radio-button", rules: [
|
15910
16383
|
{
|
15911
16384
|
required: true,
|
15912
16385
|
message: "",
|
@@ -15915,268 +16388,422 @@ var InvestmentCreationComponent = function (props) {
|
|
15915
16388
|
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
15916
16389
|
return __generator(this, function (_a) {
|
15917
16390
|
if (String(value).trim() === "" ||
|
15918
|
-
String(value).trim() ===
|
15919
|
-
undefined ||
|
16391
|
+
String(value).trim() === undefined ||
|
15920
16392
|
value === null ||
|
15921
16393
|
value === undefined) {
|
15922
|
-
throw new Error("".concat(t("programme:
|
16394
|
+
throw new Error("".concat(t("programme:instrument"), " ").concat(t("isRequired")));
|
15923
16395
|
}
|
15924
16396
|
return [2 /*return*/];
|
15925
16397
|
});
|
15926
16398
|
}); },
|
15927
16399
|
},
|
15928
16400
|
] },
|
15929
|
-
React.createElement(
|
16401
|
+
React.createElement(Radio.Group, { onChange: onInstrumentChange, value: instrument[0] }, instrumentOptions.map(function (e) {
|
16402
|
+
return (React.createElement(Radio, { value: e.value }, e.label));
|
16403
|
+
}))))),
|
16404
|
+
instrument &&
|
16405
|
+
instrument.indexOf(Instrument.LOAN) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15930
16406
|
React.createElement(Col, { xl: 8, md: 12 },
|
15931
|
-
React.createElement(
|
15932
|
-
|
15933
|
-
|
15934
|
-
|
15935
|
-
|
15936
|
-
|
15937
|
-
|
15938
|
-
return
|
15939
|
-
|
15940
|
-
String(value).trim() ===
|
15941
|
-
|
15942
|
-
|
15943
|
-
|
15944
|
-
|
15945
|
-
|
15946
|
-
|
15947
|
-
|
15948
|
-
|
15949
|
-
|
15950
|
-
|
15951
|
-
|
15952
|
-
|
15953
|
-
|
15954
|
-
|
15955
|
-
|
15956
|
-
|
16407
|
+
React.createElement("div", { className: "details-part-two" },
|
16408
|
+
React.createElement(Form.Item, { label: t("programme:interestRate"), name: "interestRate", rules: [
|
16409
|
+
{
|
16410
|
+
required: true,
|
16411
|
+
message: "",
|
16412
|
+
},
|
16413
|
+
{
|
16414
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16415
|
+
return __generator(this, function (_a) {
|
16416
|
+
if (String(value).trim() === "" ||
|
16417
|
+
String(value).trim() ===
|
16418
|
+
undefined ||
|
16419
|
+
value === null ||
|
16420
|
+
value === undefined) {
|
16421
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isRequired")));
|
16422
|
+
}
|
16423
|
+
else if (!isNaN(value)) {
|
16424
|
+
return [2 /*return*/, Promise.resolve()];
|
16425
|
+
}
|
16426
|
+
else {
|
16427
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isInvalid")));
|
16428
|
+
}
|
16429
|
+
});
|
16430
|
+
}); },
|
16431
|
+
},
|
16432
|
+
] },
|
16433
|
+
React.createElement(Input, { size: "large" })))))),
|
16434
|
+
instrument &&
|
16435
|
+
(instrument.indexOf(Instrument.CONLOAN) >= 0 ||
|
16436
|
+
instrument.indexOf(Instrument.NONCONLOAN) >=
|
16437
|
+
0) && (React.createElement("div", { className: "details-part-two" },
|
16438
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16439
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16440
|
+
React.createElement(Form.Item, { label: t("programme:interestRate"), name: "interestRate", rules: [
|
16441
|
+
{
|
16442
|
+
required: true,
|
16443
|
+
message: "",
|
16444
|
+
},
|
16445
|
+
{
|
16446
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16447
|
+
return __generator(this, function (_a) {
|
16448
|
+
if (String(value).trim() === "" ||
|
16449
|
+
String(value).trim() ===
|
16450
|
+
undefined ||
|
16451
|
+
value === null ||
|
16452
|
+
value === undefined) {
|
16453
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isRequired")));
|
16454
|
+
}
|
16455
|
+
else if (!isNaN(value)) {
|
16456
|
+
return [2 /*return*/, Promise.resolve()];
|
16457
|
+
}
|
16458
|
+
else {
|
16459
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isInvalid")));
|
16460
|
+
}
|
16461
|
+
});
|
16462
|
+
}); },
|
16463
|
+
},
|
16464
|
+
] },
|
16465
|
+
React.createElement(Input, { size: "large" })))),
|
16466
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16467
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16468
|
+
React.createElement(Form.Item, { label: t("programme:loanPeriod"), name: "period", required: true, rules: [
|
16469
|
+
{
|
16470
|
+
required: true,
|
16471
|
+
message: "",
|
16472
|
+
},
|
16473
|
+
{
|
16474
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16475
|
+
return __generator(this, function (_a) {
|
16476
|
+
if (String(value).trim() === "" ||
|
16477
|
+
String(value).trim() ===
|
16478
|
+
undefined ||
|
16479
|
+
value === null ||
|
16480
|
+
value === undefined) {
|
16481
|
+
throw new Error("".concat(t("programme:loanPeriod"), " ").concat(t("isRequired")));
|
16482
|
+
}
|
16483
|
+
return [2 /*return*/];
|
16484
|
+
});
|
16485
|
+
}); },
|
16486
|
+
},
|
16487
|
+
] },
|
16488
|
+
React.createElement(RangePicker$3, { showTime: true, allowClear: true, format: "DD:MM:YYYY", size: "large" }))),
|
16489
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16490
|
+
React.createElement(Form.Item, { label: t("programme:startOfPayback"), name: "startOfPayback", rules: [
|
16491
|
+
{
|
16492
|
+
required: true,
|
16493
|
+
message: "",
|
16494
|
+
},
|
16495
|
+
{
|
16496
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16497
|
+
return __generator(this, function (_a) {
|
16498
|
+
if (String(value).trim() === "" ||
|
16499
|
+
String(value).trim() ===
|
16500
|
+
undefined ||
|
16501
|
+
value === null ||
|
16502
|
+
value === undefined) {
|
16503
|
+
throw new Error("".concat(t("programme:startOfPayback"), " ").concat(t("isRequired")));
|
16504
|
+
}
|
16505
|
+
return [2 /*return*/];
|
16506
|
+
});
|
16507
|
+
}); },
|
16508
|
+
},
|
16509
|
+
] },
|
16510
|
+
React.createElement(DatePicker, { size: "large", disabledDate: function (currentDate) {
|
16511
|
+
return currentDate <
|
16512
|
+
moment().startOf("day");
|
16513
|
+
} })))))),
|
16514
|
+
instrument &&
|
16515
|
+
instrument.indexOf(Instrument.GUARANTEE) >= 0 && (React.createElement("div", { className: "details-part-two" },
|
16516
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16517
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16518
|
+
React.createElement(Form.Item, { label: t("programme:interestRate"), name: "interestRate", rules: [
|
16519
|
+
{
|
16520
|
+
required: true,
|
16521
|
+
message: "",
|
16522
|
+
},
|
16523
|
+
{
|
16524
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16525
|
+
return __generator(this, function (_a) {
|
16526
|
+
if (String(value).trim() === "" ||
|
16527
|
+
String(value).trim() ===
|
16528
|
+
undefined ||
|
16529
|
+
value === null ||
|
16530
|
+
value === undefined) {
|
16531
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isRequired")));
|
16532
|
+
}
|
16533
|
+
else if (!isNaN(value)) {
|
16534
|
+
return [2 /*return*/, Promise.resolve()];
|
16535
|
+
}
|
16536
|
+
else {
|
16537
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isInvalid")));
|
16538
|
+
}
|
16539
|
+
});
|
16540
|
+
}); },
|
16541
|
+
},
|
16542
|
+
] },
|
16543
|
+
React.createElement(Input, { size: "large" })))),
|
16544
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16545
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16546
|
+
React.createElement(Form.Item, { label: t("programme:period"), name: "period", required: true, rules: [
|
16547
|
+
{
|
16548
|
+
required: true,
|
16549
|
+
message: "",
|
16550
|
+
},
|
16551
|
+
{
|
16552
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16553
|
+
return __generator(this, function (_a) {
|
16554
|
+
if (String(value).trim() === "" ||
|
16555
|
+
String(value).trim() ===
|
16556
|
+
undefined ||
|
16557
|
+
value === null ||
|
16558
|
+
value === undefined) {
|
16559
|
+
throw new Error("".concat(t("programme:period"), " ").concat(t("isRequired")));
|
16560
|
+
}
|
16561
|
+
return [2 /*return*/];
|
16562
|
+
});
|
16563
|
+
}); },
|
16564
|
+
},
|
16565
|
+
] },
|
16566
|
+
React.createElement(RangePicker$3, { showTime: true, allowClear: true, format: "DD:MM:YYYY", size: "large" }))),
|
16567
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16568
|
+
React.createElement(Form.Item, { label: t("programme:payback"), wrapperCol: { span: 13 }, className: "role-group", name: "guaranteePayback", rules: [
|
16569
|
+
{
|
16570
|
+
required: true,
|
16571
|
+
message: "",
|
16572
|
+
},
|
16573
|
+
{
|
16574
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16575
|
+
return __generator(this, function (_a) {
|
16576
|
+
if (String(value).trim() === "" ||
|
16577
|
+
String(value).trim() ===
|
16578
|
+
undefined ||
|
16579
|
+
value === null ||
|
16580
|
+
value === undefined) {
|
16581
|
+
throw new Error("".concat(t("programme:payback"), " ").concat(t("isRequired")));
|
16582
|
+
}
|
16583
|
+
return [2 /*return*/];
|
16584
|
+
});
|
16585
|
+
}); },
|
16586
|
+
},
|
16587
|
+
] },
|
16588
|
+
React.createElement(Radio.Group, { size: "large" }, Object.values(GuaranteePayback).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16589
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k }, t("programme:" + k)))); }))))))),
|
16590
|
+
instrument &&
|
16591
|
+
instrument.indexOf(Instrument.RESULT_BASED) >=
|
16592
|
+
0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16593
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16594
|
+
React.createElement("div", { className: "details-part-two" },
|
16595
|
+
React.createElement(Form.Item, { label: t("programme:resultMetric"), name: "resultMetric", rules: [
|
16596
|
+
{
|
16597
|
+
required: true,
|
16598
|
+
message: "",
|
16599
|
+
},
|
16600
|
+
{
|
16601
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16602
|
+
return __generator(this, function (_a) {
|
16603
|
+
if (String(value).trim() === "" ||
|
16604
|
+
String(value).trim() ===
|
16605
|
+
undefined ||
|
16606
|
+
value === null ||
|
16607
|
+
value === undefined) {
|
16608
|
+
throw new Error("".concat(t("programme:resultMetric"), " ").concat(t("isRequired")));
|
16609
|
+
}
|
16610
|
+
return [2 /*return*/];
|
16611
|
+
});
|
16612
|
+
}); },
|
16613
|
+
},
|
16614
|
+
] },
|
16615
|
+
React.createElement(Input, { size: "large" })))),
|
16616
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16617
|
+
React.createElement("div", { className: "details-part-two" },
|
16618
|
+
React.createElement(Form.Item, { label: t("programme:paymentPerMetric"), name: "paymentPerMetric", rules: [
|
16619
|
+
{
|
16620
|
+
required: true,
|
16621
|
+
message: "",
|
16622
|
+
},
|
16623
|
+
{
|
16624
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16625
|
+
return __generator(this, function (_a) {
|
16626
|
+
if (String(value).trim() === "" ||
|
16627
|
+
String(value).trim() ===
|
16628
|
+
undefined ||
|
16629
|
+
value === null ||
|
16630
|
+
value === undefined) {
|
16631
|
+
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isRequired")));
|
16632
|
+
}
|
16633
|
+
else if (!isNaN(value)) {
|
16634
|
+
return [2 /*return*/, Promise.resolve()];
|
16635
|
+
}
|
16636
|
+
else {
|
16637
|
+
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isInvalid")));
|
16638
|
+
}
|
16639
|
+
});
|
16640
|
+
}); },
|
16641
|
+
},
|
16642
|
+
] },
|
16643
|
+
React.createElement(Input, { size: "large" })))))),
|
16644
|
+
instrument &&
|
16645
|
+
instrument.indexOf(Instrument.INKIND) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16646
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16647
|
+
React.createElement("div", { className: "details-part-two" },
|
16648
|
+
React.createElement(Form.Item, { label: t("programme:description"), name: "description", rules: [
|
16649
|
+
{
|
16650
|
+
required: false,
|
16651
|
+
message: "",
|
16652
|
+
},
|
16653
|
+
] },
|
16654
|
+
React.createElement(Input, { size: "large" })))))),
|
16655
|
+
instrument &&
|
16656
|
+
instrument.indexOf(Instrument.INSURANCE) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15957
16657
|
React.createElement(Col, { xl: 8, md: 12 },
|
15958
|
-
React.createElement(
|
15959
|
-
|
15960
|
-
|
15961
|
-
|
15962
|
-
|
15963
|
-
|
15964
|
-
|
15965
|
-
return
|
15966
|
-
|
15967
|
-
String(value).trim() ===
|
15968
|
-
|
15969
|
-
|
15970
|
-
|
15971
|
-
|
15972
|
-
|
15973
|
-
|
15974
|
-
return [2 /*return
|
15975
|
-
}
|
15976
|
-
|
15977
|
-
|
15978
|
-
|
15979
|
-
|
15980
|
-
}); },
|
15981
|
-
|
15982
|
-
|
15983
|
-
|
16658
|
+
React.createElement("div", { className: "details-part-two" },
|
16659
|
+
React.createElement(Form.Item, { label: t("programme:payback"), wrapperCol: { span: 13 }, className: "role-group", name: "insurancePayback", rules: [
|
16660
|
+
{
|
16661
|
+
required: true,
|
16662
|
+
message: "",
|
16663
|
+
},
|
16664
|
+
{
|
16665
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16666
|
+
return __generator(this, function (_a) {
|
16667
|
+
if (String(value).trim() === "" ||
|
16668
|
+
String(value).trim() ===
|
16669
|
+
undefined ||
|
16670
|
+
value === null ||
|
16671
|
+
value === undefined) {
|
16672
|
+
throw new Error("".concat(t("programme:payback"), " ").concat(t("isRequired")));
|
16673
|
+
}
|
16674
|
+
return [2 /*return*/];
|
16675
|
+
});
|
16676
|
+
}); },
|
16677
|
+
},
|
16678
|
+
] },
|
16679
|
+
React.createElement(Radio.Group, { size: "large" }, Object.values(InsurancePayback).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16680
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k }, t("programme:" + k)))); }))))))),
|
16681
|
+
instrument &&
|
16682
|
+
instrument.indexOf(Instrument.OTHER) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16683
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16684
|
+
React.createElement("div", { className: "details-part-two" },
|
16685
|
+
React.createElement(Form.Item, { label: t("programme:comments"), name: "comments", rules: [
|
16686
|
+
{
|
16687
|
+
required: true,
|
16688
|
+
message: "",
|
16689
|
+
},
|
16690
|
+
{
|
16691
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16692
|
+
return __generator(this, function (_a) {
|
16693
|
+
if (String(value).trim() === "" ||
|
16694
|
+
String(value).trim() ===
|
16695
|
+
undefined ||
|
16696
|
+
value === null ||
|
16697
|
+
value === undefined) {
|
16698
|
+
throw new Error("".concat(t("programme:comments"), " ").concat(t("isRequired")));
|
16699
|
+
}
|
16700
|
+
return [2 /*return*/];
|
16701
|
+
});
|
16702
|
+
}); },
|
16703
|
+
},
|
16704
|
+
] },
|
16705
|
+
React.createElement(Input, { size: "large" })))))),
|
15984
16706
|
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
15985
16707
|
React.createElement(Col, { xl: 8, md: 12 },
|
15986
|
-
React.createElement(Form.Item, { label: t("programme:
|
15987
|
-
{
|
15988
|
-
required: true,
|
15989
|
-
message: "",
|
15990
|
-
},
|
16708
|
+
React.createElement(Form.Item, { label: t("programme:type"), wrapperCol: { span: 13 }, className: "role-group", name: "type", rules: [
|
15991
16709
|
{
|
15992
|
-
|
15993
|
-
return __generator(this, function (_a) {
|
15994
|
-
if (String(value).trim() === "" ||
|
15995
|
-
String(value).trim() ===
|
15996
|
-
undefined ||
|
15997
|
-
value === null ||
|
15998
|
-
value === undefined) {
|
15999
|
-
throw new Error("".concat(t("programme:period"), " ").concat(t("isRequired")));
|
16000
|
-
}
|
16001
|
-
return [2 /*return*/];
|
16002
|
-
});
|
16003
|
-
}); },
|
16710
|
+
required: false,
|
16004
16711
|
},
|
16005
16712
|
] },
|
16006
|
-
React.createElement(
|
16713
|
+
React.createElement(Radio.Group, { size: "large" }, Object.values(InvestmentType).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16714
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16715
|
+
return deselectOnClick(e, "type");
|
16716
|
+
} }, t("programme:" + k)))); })))),
|
16007
16717
|
React.createElement(Col, { xl: 8, md: 12 },
|
16008
|
-
React.createElement(Form.Item, { label: t("programme:
|
16009
|
-
{
|
16010
|
-
required: true,
|
16011
|
-
message: "",
|
16012
|
-
},
|
16013
|
-
{
|
16014
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16015
|
-
return __generator(this, function (_a) {
|
16016
|
-
if (String(value).trim() === "" ||
|
16017
|
-
String(value).trim() ===
|
16018
|
-
undefined ||
|
16019
|
-
value === null ||
|
16020
|
-
value === undefined) {
|
16021
|
-
throw new Error("".concat(t("programme:payback"), " ").concat(t("isRequired")));
|
16022
|
-
}
|
16023
|
-
return [2 /*return*/];
|
16024
|
-
});
|
16025
|
-
}); },
|
16026
|
-
},
|
16027
|
-
] },
|
16028
|
-
React.createElement(Radio.Group, { size: "large" }, Object.values(GuaranteePayback).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16029
|
-
React.createElement(Radio.Button, { className: "condition-radio", value: k }, t("programme:" + k)))); }))))))),
|
16030
|
-
instrument &&
|
16031
|
-
instrument.indexOf(Instrument.RESULT_BASED) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16032
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
16033
|
-
React.createElement("div", { className: "details-part-two" },
|
16034
|
-
React.createElement(Form.Item, { label: t("programme:resultMetric"), name: "resultMetric", rules: [
|
16035
|
-
{
|
16036
|
-
required: true,
|
16037
|
-
message: "",
|
16038
|
-
},
|
16039
|
-
{
|
16040
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16041
|
-
return __generator(this, function (_a) {
|
16042
|
-
if (String(value).trim() === "" ||
|
16043
|
-
String(value).trim() ===
|
16044
|
-
undefined ||
|
16045
|
-
value === null ||
|
16046
|
-
value === undefined) {
|
16047
|
-
throw new Error("".concat(t("programme:resultMetric"), " ").concat(t("isRequired")));
|
16048
|
-
}
|
16049
|
-
return [2 /*return*/];
|
16050
|
-
});
|
16051
|
-
}); },
|
16052
|
-
},
|
16053
|
-
] },
|
16054
|
-
React.createElement(Input, { size: "large" })))),
|
16055
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
16056
|
-
React.createElement("div", { className: "details-part-two" },
|
16057
|
-
React.createElement(Form.Item, { label: t("programme:paymentPerMetric"), name: "paymentPerMetric", rules: [
|
16058
|
-
{
|
16059
|
-
required: true,
|
16060
|
-
message: "",
|
16061
|
-
},
|
16062
|
-
{
|
16063
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16064
|
-
return __generator(this, function (_a) {
|
16065
|
-
if (String(value).trim() === "" ||
|
16066
|
-
String(value).trim() ===
|
16067
|
-
undefined ||
|
16068
|
-
value === null ||
|
16069
|
-
value === undefined) {
|
16070
|
-
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isRequired")));
|
16071
|
-
}
|
16072
|
-
else if (!isNaN(value)) {
|
16073
|
-
return [2 /*return*/, Promise.resolve()];
|
16074
|
-
}
|
16075
|
-
else {
|
16076
|
-
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isInvalid")));
|
16077
|
-
}
|
16078
|
-
});
|
16079
|
-
}); },
|
16080
|
-
},
|
16081
|
-
] },
|
16082
|
-
React.createElement(Input, { size: "large" })))))),
|
16083
|
-
instrument &&
|
16084
|
-
instrument.indexOf(Instrument.INKIND) >= 0 && (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16085
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
16086
|
-
React.createElement("div", { className: "details-part-two" },
|
16087
|
-
React.createElement(Form.Item, { label: t("programme:description"), name: "description", rules: [
|
16718
|
+
React.createElement(Form.Item, { label: t("programme:level"), wrapperCol: { span: 13 }, className: "role-group", name: "level", rules: [
|
16088
16719
|
{
|
16089
16720
|
required: false,
|
16090
|
-
message: "",
|
16091
16721
|
},
|
16092
16722
|
] },
|
16093
|
-
React.createElement(
|
16094
|
-
|
16095
|
-
|
16096
|
-
|
16097
|
-
React.createElement(
|
16098
|
-
React.createElement(Form.Item, { label: t("programme:
|
16099
|
-
{
|
16100
|
-
required: true,
|
16101
|
-
message: "",
|
16102
|
-
},
|
16723
|
+
React.createElement(Radio.Group, { size: "large" }, Object.values(InvestmentLevel).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16724
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16725
|
+
return deselectOnClick(e, "level");
|
16726
|
+
} }, t("programme:" + k)))); })))),
|
16727
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16728
|
+
React.createElement(Form.Item, { label: t("programme:stream"), wrapperCol: { span: 13 }, className: "role-group", name: "stream", rules: [
|
16103
16729
|
{
|
16104
|
-
|
16105
|
-
return __generator(this, function (_a) {
|
16106
|
-
if (String(value).trim() === "" ||
|
16107
|
-
String(value).trim() ===
|
16108
|
-
undefined ||
|
16109
|
-
value === null ||
|
16110
|
-
value === undefined) {
|
16111
|
-
throw new Error("".concat(t("programme:payback"), " ").concat(t("isRequired")));
|
16112
|
-
}
|
16113
|
-
return [2 /*return*/];
|
16114
|
-
});
|
16115
|
-
}); },
|
16730
|
+
required: false,
|
16116
16731
|
},
|
16117
16732
|
] },
|
16118
|
-
React.createElement(Radio.Group, { size: "large" }, Object.values(
|
16119
|
-
React.createElement(Radio.Button, { className: "condition-radio", value: k
|
16120
|
-
|
16121
|
-
|
16122
|
-
React.createElement(
|
16123
|
-
React.createElement(
|
16124
|
-
React.createElement(Form.Item, { label: t("programme:
|
16125
|
-
|
16126
|
-
|
16127
|
-
|
16128
|
-
|
16129
|
-
|
16130
|
-
|
16131
|
-
|
16132
|
-
|
16133
|
-
|
16134
|
-
|
16135
|
-
|
16136
|
-
|
16137
|
-
|
16138
|
-
|
16139
|
-
|
16733
|
+
React.createElement(Radio.Group, { size: "large" }, Object.values(InvestmentStream).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16734
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16735
|
+
return deselectOnClick(e, "stream");
|
16736
|
+
} }, t("programme:" + k)))); }))))),
|
16737
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16738
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16739
|
+
React.createElement(Form.Item, { label: t("programme:esgType"), name: "esgClassification" },
|
16740
|
+
React.createElement(Select, { size: "large" }, Object.values(ESGType).map(function (esg) { return (React.createElement(Select.Option, { value: esg }, esg)); }))))))),
|
16741
|
+
typeCreation == InvestmentCreationType.EXISTING && (React.createElement("div", null,
|
16742
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16743
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16744
|
+
React.createElement("div", { className: "details-part-one" },
|
16745
|
+
React.createElement(Form.Item, { label: t("programme:existingInvestmentSource"), name: "existinngInvestmentId", wrapperCol: { span: 24 }, rules: [
|
16746
|
+
{
|
16747
|
+
required: true,
|
16748
|
+
message: "".concat(t("programme:existingInvestmentSource"), " ").concat(t("isRequired")),
|
16749
|
+
},
|
16750
|
+
] },
|
16751
|
+
React.createElement(Select, { size: "large", loading: loadingInvestment, onChange: setSelectedInvestment }, nationalInvestmentList.map(function (investment) { return (React.createElement(Select.Option, { key: investment.requestId, value: investment.requestId }, investment.investmentName)); })))))),
|
16752
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16753
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16754
|
+
React.createElement("div", { className: "details-part-two" },
|
16755
|
+
React.createElement(Form.Item, { label: t("programme:amountInvested"), name: "amount", rules: [
|
16756
|
+
{
|
16757
|
+
required: true,
|
16758
|
+
message: "",
|
16759
|
+
},
|
16760
|
+
{
|
16761
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16762
|
+
return __generator(this, function (_a) {
|
16763
|
+
if (String(value).trim() === "" ||
|
16764
|
+
String(value).trim() ===
|
16765
|
+
undefined ||
|
16766
|
+
value === null ||
|
16767
|
+
value === undefined) {
|
16768
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isRequired")));
|
16769
|
+
}
|
16770
|
+
else if (!isNaN(value) &&
|
16771
|
+
Number(value) > 0) {
|
16772
|
+
return [2 /*return*/, Promise.resolve()];
|
16773
|
+
}
|
16774
|
+
else {
|
16775
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isInvalid")));
|
16776
|
+
}
|
16777
|
+
});
|
16778
|
+
}); },
|
16779
|
+
},
|
16780
|
+
function (_a) {
|
16781
|
+
var getFieldValue = _a.getFieldValue;
|
16782
|
+
return ({
|
16783
|
+
validator: function (rule, v) {
|
16784
|
+
if (getFieldValue("amount") &&
|
16785
|
+
investmentData &&
|
16786
|
+
investmentData.amount <
|
16787
|
+
parseFloat(getFieldValue("amount"))) {
|
16788
|
+
// eslint-disable-next-line prefer-promise-reject-errors
|
16789
|
+
return Promise.reject("Amount > Available");
|
16790
|
+
}
|
16791
|
+
return Promise.resolve();
|
16792
|
+
},
|
16140
16793
|
});
|
16141
|
-
}
|
16142
|
-
},
|
16143
|
-
|
16144
|
-
|
16145
|
-
|
16146
|
-
|
16147
|
-
|
16148
|
-
|
16149
|
-
|
16150
|
-
|
16151
|
-
|
16152
|
-
|
16153
|
-
|
16154
|
-
return deselectOnClick(e, "type");
|
16155
|
-
} }, t("programme:" + k)))); })))),
|
16156
|
-
React.createElement(Col, { xl: 8, md: 12 },
|
16157
|
-
React.createElement(Form.Item, { label: t("programme:level"), wrapperCol: { span: 13 }, className: "role-group", name: "level", rules: [
|
16158
|
-
{
|
16159
|
-
required: false,
|
16160
|
-
},
|
16161
|
-
] },
|
16162
|
-
React.createElement(Radio.Group, { size: "large" }, Object.values(InvestmentLevel).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16163
|
-
React.createElement(Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16164
|
-
return deselectOnClick(e, "level");
|
16165
|
-
} }, t("programme:" + k)))); })))),
|
16166
|
-
React.createElement(Col, { xl: 8, md: 12 },
|
16167
|
-
React.createElement(Form.Item, { label: t("programme:stream"), wrapperCol: { span: 13 }, className: "role-group", name: "stream", rules: [
|
16168
|
-
{
|
16169
|
-
required: false,
|
16170
|
-
},
|
16171
|
-
] },
|
16172
|
-
React.createElement(Radio.Group, { size: "large" }, Object.values(InvestmentStream).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16173
|
-
React.createElement(Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16174
|
-
return deselectOnClick(e, "stream");
|
16175
|
-
} }, t("programme:" + k)))); }))))),
|
16176
|
-
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16177
|
-
React.createElement(Col, { xl: 12, md: 24 },
|
16178
|
-
React.createElement(Form.Item, { label: t("programme:esgType"), name: "esgClassification" },
|
16179
|
-
React.createElement(Select, { size: "large" }, Object.values(ESGType).map(function (esg) { return (React.createElement(Select.Option, { value: esg }, esg)); }))))),
|
16794
|
+
},
|
16795
|
+
] },
|
16796
|
+
React.createElement(Input, { size: "large" })))),
|
16797
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16798
|
+
React.createElement("div", { className: "details-part-two" },
|
16799
|
+
React.createElement(Form.Item, { label: " ", name: "sourceAmount" },
|
16800
|
+
React.createElement("div", null,
|
16801
|
+
"/",
|
16802
|
+
React.createElement(InputNumber, { size: "large", width: "100%", formatter: function (value) {
|
16803
|
+
return "$".concat(addCommSep(value));
|
16804
|
+
}, disabled: true, value: investmentData
|
16805
|
+
? investmentData.amount
|
16806
|
+
: 0 })))))))),
|
16180
16807
|
React.createElement(Form.Item, null,
|
16181
16808
|
React.createElement("div", { className: "steps-actions" },
|
16182
16809
|
React.createElement(Button, { type: "primary", htmlType: "submit", loading: loading, onSubmit: nextOne }, t("programme:next")))))))),
|
@@ -16186,73 +16813,164 @@ var InvestmentCreationComponent = function (props) {
|
|
16186
16813
|
React.createElement("div", { className: "step-count" }, "02"),
|
16187
16814
|
React.createElement("div", { className: "title" }, t("programme:ownership")))),
|
16188
16815
|
description: current === 1 && (React.createElement("div", null,
|
16189
|
-
React.createElement("div", { className: "
|
16190
|
-
React.createElement(
|
16191
|
-
|
16192
|
-
|
16193
|
-
React.createElement(Col, { xl: 8, md:
|
16194
|
-
React.createElement("
|
16195
|
-
companyName[companyId].name,
|
16196
|
-
React.createElement("span", { className: "required-mark" }, "*"))),
|
16197
|
-
React.createElement(Col, { xl: 8, md: 9 },
|
16198
|
-
React.createElement(Form.Item, { className: "inline", name: ["percentage", index], initialValue: 0, rules: [
|
16199
|
-
{
|
16200
|
-
pattern: new RegExp(/^[+]?([.]\d+|\d+[.]?\d*)$/g),
|
16201
|
-
message: "Percentage Should be a positive number",
|
16202
|
-
},
|
16816
|
+
React.createElement("div", { className: "investment-sought-form-container" },
|
16817
|
+
React.createElement("div", { className: "investment-sought-form" },
|
16818
|
+
React.createElement(Form, { labelCol: { span: 20 }, wrapperCol: { span: 24 }, name: "investment-sought", className: "investment-sought-form", layout: "vertical", requiredMark: true },
|
16819
|
+
React.createElement(Row, { className: "row", gutter: [4, 4] },
|
16820
|
+
React.createElement(Col, { xl: 8, md: 12 },
|
16821
|
+
React.createElement(Form.Item, { label: t("programme:typeCreation"), wrapperCol: { span: 13 }, className: "role-group", name: "investmentOwnershipType", rules: [
|
16203
16822
|
{
|
16204
|
-
required:
|
16205
|
-
message: "Required field",
|
16206
|
-
},
|
16207
|
-
function (_a) {
|
16208
|
-
var getFieldValue = _a.getFieldValue;
|
16209
|
-
return ({
|
16210
|
-
validator: function (rule, v) {
|
16211
|
-
if (getFieldValue([
|
16212
|
-
"percentage",
|
16213
|
-
index,
|
16214
|
-
]) &&
|
16215
|
-
parseFloat(getFieldValue([
|
16216
|
-
"percentage",
|
16217
|
-
index,
|
16218
|
-
])) >
|
16219
|
-
data.proponentPercentage[index]) {
|
16220
|
-
// eslint-disable-next-line prefer-promise-reject-errors
|
16221
|
-
return Promise.reject("Amount > Available");
|
16222
|
-
}
|
16223
|
-
return Promise.resolve();
|
16224
|
-
},
|
16225
|
-
});
|
16823
|
+
required: false,
|
16226
16824
|
},
|
16227
16825
|
] },
|
16228
|
-
React.createElement(
|
16229
|
-
|
16230
|
-
|
16231
|
-
|
16232
|
-
|
16233
|
-
|
16234
|
-
|
16235
|
-
|
16236
|
-
|
16237
|
-
|
16238
|
-
|
16239
|
-
|
16240
|
-
|
16241
|
-
|
16242
|
-
|
16243
|
-
|
16244
|
-
|
16245
|
-
|
16246
|
-
|
16826
|
+
React.createElement(Radio.Group, { size: "large", defaultValue: typeCreation ==
|
16827
|
+
InvestmentCreationType.EXISTING
|
16828
|
+
? InvestmentOwnershipType.PROJECT
|
16829
|
+
: investmentOwnershipType }, Object.values(InvestmentOwnershipType).map(function (k, index) {
|
16830
|
+
if (!(typeCreation ==
|
16831
|
+
InvestmentCreationType.EXISTING &&
|
16832
|
+
k == InvestmentOwnershipType.NATIONAL) &&
|
16833
|
+
!(k ==
|
16834
|
+
InvestmentOwnershipType.NATIONAL &&
|
16835
|
+
(data === null || data === void 0 ? void 0 : data.programmeId))) {
|
16836
|
+
return (React.createElement("div", { className: "condition-radio-container" },
|
16837
|
+
React.createElement(Tooltip, { title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16838
|
+
CompanyRole.PROGRAMME_DEVELOPER &&
|
16839
|
+
stepOneData.toCompanyId !=
|
16840
|
+
userInfoState.companyId &&
|
16841
|
+
k ==
|
16842
|
+
InvestmentOwnershipType.NATIONAL
|
16843
|
+
? "This action is unauthorized due to the selected investor name."
|
16844
|
+
: "", color: TooltipColor, key: TooltipColor },
|
16845
|
+
React.createElement(Radio.Button, { className: "condition-radio", value: k, onChange: onChangeInvestmentOwnershipType, disabled: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16846
|
+
CompanyRole.PROGRAMME_DEVELOPER &&
|
16847
|
+
stepOneData.toCompanyId !=
|
16848
|
+
userInfoState.companyId &&
|
16849
|
+
k ==
|
16850
|
+
InvestmentOwnershipType.NATIONAL }, t("programme:" + k)))));
|
16247
16851
|
}
|
16248
|
-
}
|
16249
|
-
|
16250
|
-
|
16251
|
-
|
16252
|
-
|
16253
|
-
|
16254
|
-
|
16255
|
-
React.createElement(
|
16852
|
+
})))))))),
|
16853
|
+
React.createElement("div", { className: "programme-sought-form-container ownership-container" },
|
16854
|
+
React.createElement("div", { className: "programme-sought-form" },
|
16855
|
+
React.createElement(Form, { labelCol: { span: 20 }, wrapperCol: { span: 24 }, form: formTwo, name: "investment-sought", className: "investment-sought-form", layout: "vertical", requiredMark: true, onChange: onPercentageChange, onFinish: submitInvestment },
|
16856
|
+
allProjectData.length > 0 &&
|
16857
|
+
investmentOwnershipType ==
|
16858
|
+
InvestmentOwnershipType.PROJECT && (React.createElement("div", null,
|
16859
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16860
|
+
React.createElement(Col, { xl: 12, md: 24 },
|
16861
|
+
React.createElement("div", { className: "details-part-one" },
|
16862
|
+
React.createElement(Form.Item, { label: t("programme:title"), name: "projectId", wrapperCol: { span: 24 }, initialValue: (data === null || data === void 0 ? void 0 : data.programmeId) != undefined
|
16863
|
+
? allProjectData[0].programmeId
|
16864
|
+
: null, rules: [
|
16865
|
+
{
|
16866
|
+
required: true,
|
16867
|
+
message: "".concat(t("programme:title"), " ").concat(t("isRequired")),
|
16868
|
+
},
|
16869
|
+
] },
|
16870
|
+
React.createElement(Select, { size: "large", loading: loadingProgData,
|
16871
|
+
// defaultValue={
|
16872
|
+
// allProjectData.length == 1
|
16873
|
+
// ? allProjectData[0].programmeId
|
16874
|
+
// : null
|
16875
|
+
// }
|
16876
|
+
disabled: allProjectData.length == 1 &&
|
16877
|
+
(data === null || data === void 0 ? void 0 : data.programmeId) != undefined, onChange: setSelectedProgramme }, allProjectData.map(function (project) {
|
16878
|
+
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16879
|
+
CompanyRole.PROGRAMME_DEVELOPER &&
|
16880
|
+
Number(stepOneData.toCompanyId) !=
|
16881
|
+
userInfoState.companyId) {
|
16882
|
+
if (project.companyId
|
16883
|
+
.map(function (id) { return Number(id); })
|
16884
|
+
.includes(userInfoState.companyId)) {
|
16885
|
+
return (React.createElement(Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16886
|
+
}
|
16887
|
+
}
|
16888
|
+
else if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ===
|
16889
|
+
CompanyRole.MINISTRY) {
|
16890
|
+
if (ministrySectoralScope.includes(project.sectoralScope)) {
|
16891
|
+
return (React.createElement(Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16892
|
+
}
|
16893
|
+
}
|
16894
|
+
else {
|
16895
|
+
return (React.createElement(Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16896
|
+
}
|
16897
|
+
})))))), projectData === null || projectData === void 0 ? void 0 :
|
16898
|
+
projectData.companyId.map(function (companyId, index) {
|
16899
|
+
if (formTwo.getFieldValue("percentage") &&
|
16900
|
+
formTwo.getFieldValue("percentage")[index] &&
|
16901
|
+
companyId == stepOneData.toCompanyId) {
|
16902
|
+
formTwo.getFieldValue("percentage")[index] = 0;
|
16903
|
+
}
|
16904
|
+
return (React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16905
|
+
React.createElement(Col, { xl: 8, md: 15 },
|
16906
|
+
React.createElement("div", { className: "label" },
|
16907
|
+
govData.companyId == companyId
|
16908
|
+
? govData.name
|
16909
|
+
: companyNames[Number(companyId)],
|
16910
|
+
React.createElement("span", { className: "required-mark" }, "*"))),
|
16911
|
+
React.createElement(Col, { xl: 8, md: 9 },
|
16912
|
+
React.createElement(Form.Item, { className: "inline", name: ["percentage", index], initialValue: 0, rules: [
|
16913
|
+
{
|
16914
|
+
pattern: new RegExp(/^[+]?([.]\d+|\d+[.]?\d*)$/g),
|
16915
|
+
message: "Percentage Should be a positive number",
|
16916
|
+
},
|
16917
|
+
{
|
16918
|
+
required: true,
|
16919
|
+
message: "Required field",
|
16920
|
+
},
|
16921
|
+
function (_a) {
|
16922
|
+
var getFieldValue = _a.getFieldValue;
|
16923
|
+
return ({
|
16924
|
+
validator: function (rule, v) {
|
16925
|
+
if (getFieldValue([
|
16926
|
+
"percentage",
|
16927
|
+
index,
|
16928
|
+
]) &&
|
16929
|
+
parseFloat(getFieldValue([
|
16930
|
+
"percentage",
|
16931
|
+
index,
|
16932
|
+
])) >
|
16933
|
+
projectData
|
16934
|
+
.proponentPercentage[index]) {
|
16935
|
+
// eslint-disable-next-line prefer-promise-reject-errors
|
16936
|
+
return Promise.reject("Amount > Available");
|
16937
|
+
}
|
16938
|
+
return Promise.resolve();
|
16939
|
+
},
|
16940
|
+
});
|
16941
|
+
},
|
16942
|
+
] },
|
16943
|
+
React.createElement(InputNumber, { placeholder: "", controls: false, disabled: govData.companyId ==
|
16944
|
+
companyId ||
|
16945
|
+
companyId ==
|
16946
|
+
stepOneData.toCompanyId, value: 0,
|
16947
|
+
// disabled={userInfoState?.companyId === Number(companyId)}
|
16948
|
+
onKeyPress: function (event) {
|
16949
|
+
if (!/[0-9\.]/.test(event.key)) {
|
16950
|
+
event.preventDefault();
|
16951
|
+
}
|
16952
|
+
} })),
|
16953
|
+
React.createElement("div", { className: "inline separator" }, "/"),
|
16954
|
+
React.createElement(Form.Item, { className: "inline" },
|
16955
|
+
React.createElement(InputNumber, { placeholder: String(projectData === null || projectData === void 0 ? void 0 : projectData.proponentPercentage[index]), disabled: true })))));
|
16956
|
+
}),
|
16957
|
+
React.createElement(Row, { className: "row", gutter: [16, 16] },
|
16958
|
+
React.createElement(Col, { xl: 8, md: 15 },
|
16959
|
+
React.createElement("div", { className: "label" }, t("programme:total"))),
|
16960
|
+
React.createElement(Col, { xl: 8, md: 9 },
|
16961
|
+
React.createElement(Form.Item, { className: "inline", name: ["total"] },
|
16962
|
+
React.createElement(InputNumber, { placeholder: currentPercTotal + "", controls: false, disabled: true, onKeyPress: function (event) {
|
16963
|
+
if (!/[0-9\.]/.test(event.key)) {
|
16964
|
+
event.preventDefault();
|
16965
|
+
}
|
16966
|
+
} })),
|
16967
|
+
React.createElement("div", { className: "inline separator" }, "/"),
|
16968
|
+
React.createElement(Form.Item, { className: "inline" },
|
16969
|
+
React.createElement(InputNumber, { disabled: true, placeholder: "100" })))))),
|
16970
|
+
React.createElement(Form.Item, null,
|
16971
|
+
React.createElement("div", { className: "steps-actions" },
|
16972
|
+
React.createElement(Button, { type: "primary", htmlType: "submit", loading: loading, onSubmit: submitInvestment }, t("programme:submit")),
|
16973
|
+
React.createElement(Button, { className: "back-btn", onClick: function () { return prevOne(); }, loading: loading }, t("programme:back"))))))))),
|
16256
16974
|
},
|
16257
16975
|
] })))));
|
16258
16976
|
};
|
@@ -16363,7 +17081,7 @@ var InvestmentActionModel = function (props) {
|
|
16363
17081
|
};
|
16364
17082
|
|
16365
17083
|
var InvestmentManagementComponent = function (props) {
|
16366
|
-
var translator = props.translator,
|
17084
|
+
var translator = props.translator, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onClickAddOwnership = props.onClickAddOwnership, enableAddOwnership = props.enableAddOwnership;
|
16367
17085
|
var t = translator.t;
|
16368
17086
|
var statusOptions = Object.keys(InvestmentStatus).map(function (k, index) { return ({
|
16369
17087
|
label: addSpaces(Object.values(InvestmentStatus)[index]),
|
@@ -16753,7 +17471,10 @@ var InvestmentManagementComponent = function (props) {
|
|
16753
17471
|
sorter: true,
|
16754
17472
|
align: "left",
|
16755
17473
|
render: function (item) {
|
16756
|
-
|
17474
|
+
if (item) {
|
17475
|
+
return React.createElement("span", { className: "clickable" }, item);
|
17476
|
+
}
|
17477
|
+
return React.createElement("span", null, "-");
|
16757
17478
|
},
|
16758
17479
|
onCell: function (record, rowIndex) {
|
16759
17480
|
return {
|
@@ -16811,6 +17532,12 @@ var InvestmentManagementComponent = function (props) {
|
|
16811
17532
|
key: "programmeSector",
|
16812
17533
|
sorter: true,
|
16813
17534
|
align: "left",
|
17535
|
+
render: function (item) {
|
17536
|
+
if (item) {
|
17537
|
+
return React.createElement("span", null, item);
|
17538
|
+
}
|
17539
|
+
return React.createElement("span", null, "-");
|
17540
|
+
},
|
16814
17541
|
},
|
16815
17542
|
{
|
16816
17543
|
title: t("programme:investor"),
|
@@ -16894,7 +17621,11 @@ var InvestmentManagementComponent = function (props) {
|
|
16894
17621
|
React.createElement("div", { className: "title-bar" },
|
16895
17622
|
React.createElement("div", { className: "body-title" }, t("programme:investmentTitle")),
|
16896
17623
|
React.createElement("div", { className: "body-sub-title" }, t("programme:investmentDesc"))),
|
16897
|
-
React.createElement("div", { className: "actions" }, enableAddOwnership &&
|
17624
|
+
React.createElement("div", { className: "actions" }, enableAddOwnership &&
|
17625
|
+
((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == CompanyRole.MINISTRY ||
|
17626
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == CompanyRole.GOVERNMENT ||
|
17627
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == CompanyRole.PROGRAMME_DEVELOPER) &&
|
17628
|
+
userInfoState.userRole != Role.ViewOnly && (React.createElement("div", { className: "action-bar" },
|
16898
17629
|
React.createElement(Button, { type: "primary", size: "large", block: true, icon: React.createElement(PlusOutlined, null), onClick: onClickAddOwnership }, t("programme:addOwnership")))))),
|
16899
17630
|
React.createElement("div", { className: "content-card" },
|
16900
17631
|
React.createElement(Row, null,
|
@@ -16941,7 +17672,7 @@ var InvestmentManagementComponent = function (props) {
|
|
16941
17672
|
return handleTableChange(val, sorter);
|
16942
17673
|
}, locale: {
|
16943
17674
|
emptyText: (React.createElement(Empty, { image: Empty.PRESENTED_IMAGE_SIMPLE, description: tableData.length === 0
|
16944
|
-
? t("
|
17675
|
+
? t("programme:noInvestmentData")
|
16945
17676
|
: null })),
|
16946
17677
|
} }))))),
|
16947
17678
|
popupInfo && selectedReq && (React.createElement(InvestmentActionModel, { investment: selectedReq, onCancel: function () {
|
@@ -16954,7 +17685,7 @@ var css_248z$l = ".steps-actions {\n display: flex;\n flex-direction: row-reve
|
|
16954
17685
|
styleInject(css_248z$l);
|
16955
17686
|
|
16956
17687
|
var SupportCreationComponent = function (props) {
|
16957
|
-
var t = props.t,
|
17688
|
+
var t = props.t, useLocation = props.useLocation; props.onNavigateToProgrammeManagementView; props.onNavigateToProgrammeView;
|
16958
17689
|
useLocation().state;
|
16959
17690
|
var _a = useState(); _a[0]; _a[1];
|
16960
17691
|
var formOne = Form.useForm()[0];
|
@@ -16967,6 +17698,7 @@ var SupportCreationComponent = function (props) {
|
|
16967
17698
|
var _f = useState([]), organisationsList = _f[0], setOrganisationList = _f[1];
|
16968
17699
|
var _g = useState([]), instrument = _g[0], setInstrument = _g[1];
|
16969
17700
|
var _h = useState(); _h[0]; var setStepOneData = _h[1];
|
17701
|
+
var userInfoState = useUserContext().userInfoState;
|
16970
17702
|
var instrumentOptions = Object.keys(Instrument).map(function (k, index) { return ({
|
16971
17703
|
label: addSpaces(Object.values(Instrument)[index]),
|
16972
17704
|
value: Object.values(Instrument)[index],
|
@@ -17309,7 +18041,7 @@ var SupportCreationComponent = function (props) {
|
|
17309
18041
|
};
|
17310
18042
|
|
17311
18043
|
var SupportManagementComponent = function (props) {
|
17312
|
-
var translator = props.translator
|
18044
|
+
var translator = props.translator; props.onNavigateToProgrammeView; var enableAddSupport = props.enableAddSupport, onClickAddSupport = props.onClickAddSupport;
|
17313
18045
|
var t = translator.t;
|
17314
18046
|
var statusOptions = Object.keys(InvestmentStatus).map(function (k, index) { return ({
|
17315
18047
|
label: addSpaces(Object.values(InvestmentStatus)[index]),
|
@@ -17811,7 +18543,7 @@ var css_248z$k = ".ndc-management .ant-checkbox-checked .ant-checkbox-input[valu
|
|
17811
18543
|
styleInject(css_248z$k);
|
17812
18544
|
|
17813
18545
|
var NdcActionManagementComponent = function (props) {
|
17814
|
-
var t = props.t,
|
18546
|
+
var t = props.t, onNavigateToNdcManagementView = props.onNavigateToNdcManagementView, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView;
|
17815
18547
|
var _a = useState(true), checkAll = _a[0], setCheckAll = _a[1];
|
17816
18548
|
var _b = useState([]), tableData = _b[0], setTableData = _b[1];
|
17817
18549
|
var _c = useState(), totalProgramme = _c[0], setTotalProgramme = _c[1];
|
@@ -19225,7 +19957,7 @@ var GenderParity = function (props) {
|
|
19225
19957
|
};
|
19226
19958
|
|
19227
19959
|
var Assessment = function (props) {
|
19228
|
-
var onFormSubmit = props.onFormSubmit, assessmentViewData = props.assessmentViewData, viewOnly = props.viewOnly,
|
19960
|
+
var onFormSubmit = props.onFormSubmit, assessmentViewData = props.assessmentViewData, viewOnly = props.viewOnly, translator = props.translator;
|
19229
19961
|
translator.setDefaultNamespace("coBenifits");
|
19230
19962
|
var t = translator.t;
|
19231
19963
|
var form1 = Form.useForm()[0];
|
@@ -21630,7 +22362,7 @@ var SocialEnvironmentalRisk = function (props) {
|
|
21630
22362
|
};
|
21631
22363
|
|
21632
22364
|
var CoBenifitsComponent = function (props) {
|
21633
|
-
var onClickedBackBtn = props.onClickedBackBtn, onFormSubmit = props.onFormSubmit, coBenefitsDetails = props.coBenefitsDetails, submitButtonText = props.submitButtonText, viewOnly = props.viewOnly, coBenifitsViewDetails = props.coBenifitsViewDetails, _a = props.loading, loading = _a === void 0 ? false : _a, sdgGoalImages = props.sdgGoalImages, translator = props.translator
|
22365
|
+
var onClickedBackBtn = props.onClickedBackBtn, onFormSubmit = props.onFormSubmit, coBenefitsDetails = props.coBenefitsDetails, submitButtonText = props.submitButtonText, viewOnly = props.viewOnly, coBenifitsViewDetails = props.coBenifitsViewDetails, _a = props.loading, loading = _a === void 0 ? false : _a, sdgGoalImages = props.sdgGoalImages, translator = props.translator;
|
21634
22366
|
var _b = useState(), coBenefitDetails = _b[0], setCoBenefitDetails = _b[1];
|
21635
22367
|
var _c = useState(true), isSocialFormValid = _c[0], setIsSocialFormValid = _c[1];
|
21636
22368
|
var _d = useState(true), isAssessmentFormValid = _d[0], setIsAssessmentFormValid = _d[1];
|
@@ -21704,7 +22436,7 @@ var CoBenifitsComponent = function (props) {
|
|
21704
22436
|
label: t("coBenifits:assessment"),
|
21705
22437
|
key: "7",
|
21706
22438
|
children: (React.createElement(Assessment, { onFormSubmit: onAssessmentFormSubmit, assessmentViewData: (viewOnly && (coBenifitsViewDetails === null || coBenifitsViewDetails === void 0 ? void 0 : coBenifitsViewDetails.assessmentDetails)) ||
|
21707
|
-
(!viewOnly && (coBenefitsDetails === null || coBenefitsDetails === void 0 ? void 0 : coBenefitsDetails.assessmentDetails)), viewOnly: viewOnly || false,
|
22439
|
+
(!viewOnly && (coBenefitsDetails === null || coBenefitsDetails === void 0 ? void 0 : coBenefitsDetails.assessmentDetails)), viewOnly: viewOnly || false, translator: translator })),
|
21708
22440
|
},
|
21709
22441
|
{
|
21710
22442
|
label: t("coBenifits:socialEnvironmentalRisk"),
|
@@ -21873,7 +22605,7 @@ var CoBenifitsComponent = function (props) {
|
|
21873
22605
|
};
|
21874
22606
|
|
21875
22607
|
var AddNdcActionComponent = function (props) {
|
21876
|
-
var
|
22608
|
+
var useLocation = props.useLocation, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView, onNavigateToProgrammeView = props.onNavigateToProgrammeView, sdgGoalImages = props.sdgGoalImages, translator = props.translator;
|
21877
22609
|
translator.setDefaultNamespace("ndcAction");
|
21878
22610
|
var t = translator.t;
|
21879
22611
|
var _a = useState(1), current = _a[0], setCurrent = _a[1];
|
@@ -22015,7 +22747,7 @@ var AddNdcActionComponent = function (props) {
|
|
22015
22747
|
description: (React.createElement("div", { className: current !== 2 ? "hide" : "" },
|
22016
22748
|
React.createElement(CoBenifitsComponent, { onClickedBackBtn: onClickBackCoBenefits, coBenefitsDetails: ndcActionDetails ? ndcActionDetails.coBenefitsProperties : {}, onFormSubmit: onCoBenefitsSubmit, submitButtonText: isProjectReportsVisible()
|
22017
22749
|
? t("ndcAction:next")
|
22018
|
-
: t("ndcAction:submit"), loading: loading, sdgGoalImages: sdgGoalImages,
|
22750
|
+
: t("ndcAction:submit"), loading: loading, sdgGoalImages: sdgGoalImages, translator: translator }))),
|
22019
22751
|
},
|
22020
22752
|
];
|
22021
22753
|
if (isProjectReportsVisible()) {
|
@@ -22152,7 +22884,7 @@ var uploadDocUserPermission = function (userInfoState, docType, programmeOwnerId
|
|
22152
22884
|
var NdcActionViewComponent = function (props) {
|
22153
22885
|
var _a;
|
22154
22886
|
var _b, _c;
|
22155
|
-
var
|
22887
|
+
var useLocation = props.useLocation, onNavigateToNdcManagementView = props.onNavigateToNdcManagementView, translator = props.translator, sdgGoalImages = props.sdgGoalImages, Chart = props.Chart;
|
22156
22888
|
translator.setDefaultNamespace("ndcAction");
|
22157
22889
|
var t = translator.t;
|
22158
22890
|
var userInfoState = useUserContext().userInfoState;
|
@@ -22651,7 +23383,7 @@ var NdcActionViewComponent = function (props) {
|
|
22651
23383
|
React.createElement(Card, { className: "card-container" },
|
22652
23384
|
React.createElement("div", { className: "co-benifits-view" },
|
22653
23385
|
React.createElement("div", { className: "title" }, t("ndcAction:coBenefitsSubTitle")),
|
22654
|
-
React.createElement(CoBenifitsComponent, { viewOnly: true, coBenifitsViewDetails: (_c = state === null || state === void 0 ? void 0 : state.record) === null || _c === void 0 ? void 0 : _c.coBenefitsProperties, sdgGoalImages: sdgGoalImages,
|
23386
|
+
React.createElement(CoBenifitsComponent, { viewOnly: true, coBenifitsViewDetails: (_c = state === null || state === void 0 ? void 0 : state.record) === null || _c === void 0 ? void 0 : _c.coBenefitsProperties, sdgGoalImages: sdgGoalImages, translator: translator })))))))));
|
22655
23387
|
};
|
22656
23388
|
|
22657
23389
|
var css_248z$e = ".credit-transfer-management .certify-list {\n width: 110px;\n display: flex;\n align-items: center;\n flex-wrap: wrap; }\n .credit-transfer-management .certify-list .profile-icon {\n margin-bottom: 4px; }\n\n.credit-transfer-management .table-actions-section {\n margin-bottom: 0px; }\n .credit-transfer-management .table-actions-section input {\n font-family: \"Inter\";\n font-size: 0.8rem; }\n\n.credit-transfer-management .all-check {\n margin-right: 10px; }\n .credit-transfer-management .all-check .ant-checkbox-inner::after {\n background-color: rgba(58, 53, 65, 0.5); }\n .credit-transfer-management .all-check .ant-checkbox-checked .ant-checkbox-inner::after {\n background-color: transparent; }\n .credit-transfer-management .all-check .ant-checkbox-checked .ant-checkbox-inner {\n background-color: rgba(58, 53, 65, 0.5);\n border: none; }\n\n.credit-transfer-management .ant-checkbox-checked .ant-checkbox-input[value='Retired'] + .ant-checkbox-inner {\n background-color: rgba(58, 53, 65, 0.4);\n border: none; }\n\n.credit-transfer-management .ant-checkbox-checked .ant-checkbox-input[value='AwaitingAuthorization'] + .ant-checkbox-inner {\n background-color: rgba(237, 77, 71, 0.6);\n border: none; }\n\n.credit-transfer-management .ant-checkbox-checked .ant-checkbox-input[value='Rejected'] + .ant-checkbox-inner {\n background-color: rgba(58, 53, 65, 0.4);\n border: none; }\n\n.credit-transfer-management .ant-checkbox-checked .ant-checkbox-input[value='Issued'] + .ant-checkbox-inner {\n background-color: #16b1ff;\n border: none; }\n\n.credit-transfer-management .ant-checkbox-checked .ant-checkbox-input[value='Transferred'] + .ant-checkbox-inner {\n background-color: rgba(118, 195, 39, 0.6);\n border: none; }\n\n.credit-transfer-modal-container {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n margin: 2rem 0 0 0;\n width: 100%; }\n .credit-transfer-modal-container .icon-credit {\n margin-bottom: 15px; }\n .credit-transfer-modal-container .credit-transfer-details {\n display: flex;\n flex-direction: column;\n align-items: center;\n justify-content: center;\n width: 100%;\n margin-bottom: 10px; }\n .credit-transfer-modal-container .credit-transfer-details .content-credit-transfer {\n font-family: 'Inter' !important;\n font-style: normal;\n font-weight: 600;\n font-size: 0.9rem;\n line-height: 1.3rem;\n padding: 0 1rem 0 1rem;\n text-align: center;\n color: rgba(58, 53, 65, 0.8) !important; }\n .credit-transfer-modal-container .credit-transfer-details .sub-content-credit-transfer {\n font-family: 'Inter';\n font-style: normal;\n font-weight: 600;\n font-size: 0.8rem;\n line-height: 1.375rem;\n text-align: center;\n color: rgba(58, 53, 65, 0.5); }\n .credit-transfer-modal-container .remarks-credit-transfer {\n flex-direction: row;\n width: 100%;\n padding: 0.5rem 1rem 0 1rem; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .ant-form-item-explain-error {\n display: flex;\n flex-direction: row; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .ant-form {\n width: 100%; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .ant-form .ant-form-item-label > label {\n font-size: 0.8rem; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .modal-credit-transfer-btns {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: center;\n width: 100%;\n margin-top: 1rem; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .modal-credit-transfer-btns .center {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: space-between; }\n .credit-transfer-modal-container .remarks-credit-transfer .modal-form .modal-credit-transfer-btns .width-60 {\n width: 60%; }\n\n.common-table-class .ant-table .ant-table-thead .ant-table-cell {\n font-size: 0.75rem;\n font-weight: 600; }\n";
|
@@ -22804,7 +23536,7 @@ var TransferActionModel = function (props) {
|
|
22804
23536
|
};
|
22805
23537
|
|
22806
23538
|
var CreditTransferComponent = function (props) {
|
22807
|
-
var
|
23539
|
+
var translator = props.translator, onNavigateToProgrammeView = props.onNavigateToProgrammeView;
|
22808
23540
|
var userInfoState = useUserContext().userInfoState;
|
22809
23541
|
var t = translator.t;
|
22810
23542
|
var statusOptions = Object.keys(CreditTransferStage).map(function (k, index) { return ({
|
@@ -23797,8 +24529,8 @@ var MapStatsComponent = function (props) {
|
|
23797
24529
|
|
23798
24530
|
var RangePicker$2 = DatePicker.RangePicker;
|
23799
24531
|
var MrvDashboardComponent = function (props) {
|
23800
|
-
var
|
23801
|
-
var _b = useConnection(); _b.get; var post = _b.post; _b.delete;
|
24532
|
+
var Link = props.Link, Chart = props.Chart, t = props.t, ButtonGroup = props.ButtonGroup, _a = props.isMultipleDashboardsVisible, isMultipleDashboardsVisible = _a === void 0 ? false : _a;
|
24533
|
+
var _b = useConnection(); _b.get; var post = _b.post; _b.delete; var statServerUrl = _b.statServerUrl;
|
23802
24534
|
var _c = useState({}), data = _c[0], setData = _c[1];
|
23803
24535
|
var _e = useState(false), loading = _e[0], setLoading = _e[1];
|
23804
24536
|
var userInfoState = useUserContext().userInfoState;
|
@@ -24281,7 +25013,7 @@ var MrvDashboardComponent = function (props) {
|
|
24281
25013
|
_e.label = 1;
|
24282
25014
|
case 1:
|
24283
25015
|
_e.trys.push([1, 3, 4, 5]);
|
24284
|
-
return [4 /*yield*/, post("stats/programme/agg", genPayload(), undefined,
|
25016
|
+
return [4 /*yield*/, post("stats/programme/agg", genPayload(), undefined, statServerUrl)];
|
24285
25017
|
case 2:
|
24286
25018
|
response = _e.sent();
|
24287
25019
|
console.log("Response", response);
|
@@ -25532,8 +26264,8 @@ var RegistryBarChartsStatComponent = function (props) {
|
|
25532
26264
|
|
25533
26265
|
var RangePicker$1 = DatePicker.RangePicker;
|
25534
26266
|
var RegistryDashboardComponent = function (props) {
|
25535
|
-
var
|
25536
|
-
var _b = useConnection(); _b.get; var post = _b.post; _b.delete;
|
26267
|
+
var Chart = props.Chart, t = props.t, ButtonGroup = props.ButtonGroup, Link = props.Link, _a = props.isMultipleDashboardsVisible, isMultipleDashboardsVisible = _a === void 0 ? false : _a;
|
26268
|
+
var _b = useConnection(); _b.get; var post = _b.post; _b.delete; var statServerUrl = _b.statServerUrl;
|
25537
26269
|
var userInfoState = useUserContext().userInfoState;
|
25538
26270
|
var _c = useState(false), loadingWithoutTimeRange = _c[0], setLoadingWithoutTimeRange = _c[1];
|
25539
26271
|
var _e = useState(false), loading = _e[0], setLoading = _e[1];
|
@@ -25980,7 +26712,7 @@ var RegistryDashboardComponent = function (props) {
|
|
25980
26712
|
_253.label = 1;
|
25981
26713
|
case 1:
|
25982
26714
|
_253.trys.push([1, 3, 4, 5]);
|
25983
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllChartsParams(), undefined,
|
26715
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllChartsParams(), undefined, statServerUrl)];
|
25984
26716
|
case 2:
|
25985
26717
|
response = _253.sent();
|
25986
26718
|
totalCreditsCertifiedStats = void 0;
|
@@ -26257,7 +26989,7 @@ var RegistryDashboardComponent = function (props) {
|
|
26257
26989
|
_77.label = 1;
|
26258
26990
|
case 1:
|
26259
26991
|
_77.trys.push([1, 3, 4, 5]);
|
26260
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParamsWithoutTimeRange(), undefined,
|
26992
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParamsWithoutTimeRange(), undefined, statServerUrl)];
|
26261
26993
|
case 2:
|
26262
26994
|
response = _77.sent();
|
26263
26995
|
programmeByStatusAggregationResponse = (_c = (_b = (_a = response === null || response === void 0 ? void 0 : response.data) === null || _a === void 0 ? void 0 : _a.stats) === null || _b === void 0 ? void 0 : _b.AGG_PROGRAMME_BY_STATUS) === null || _c === void 0 ? void 0 : _c.data;
|
@@ -26350,7 +27082,7 @@ var RegistryDashboardComponent = function (props) {
|
|
26350
27082
|
_188.label = 1;
|
26351
27083
|
case 1:
|
26352
27084
|
_188.trys.push([1, 3, 4, 5]);
|
26353
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParams(), undefined,
|
27085
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParams(), undefined, statServerUrl)];
|
26354
27086
|
case 2:
|
26355
27087
|
response = _188.sent();
|
26356
27088
|
programmeByStatusAuthAggregationResponse = void 0;
|
@@ -27331,7 +28063,7 @@ var getNdcActionStatusTagType = function (status) {
|
|
27331
28063
|
};
|
27332
28064
|
|
27333
28065
|
var NdcDetailsComponent = function (props) {
|
27334
|
-
var t = props.t
|
28066
|
+
var t = props.t;
|
27335
28067
|
var RangePicker = DatePicker.RangePicker;
|
27336
28068
|
var _a = useState([]), ndcActionsList = _a[0], setNdcActionsList = _a[1];
|
27337
28069
|
var _b = useState(false), loading = _b[0], setLoading = _b[1];
|
@@ -28328,7 +29060,7 @@ var ProgrammeIssueForm = function (props) {
|
|
28328
29060
|
};
|
28329
29061
|
|
28330
29062
|
var ProgrammeRetireForm = function (props) {
|
28331
|
-
var programme = props.programme, onFinish = props.onFinish, onCancel = props.onCancel, actionBtnText = props.actionBtnText, subText = props.subText, hideType = props.hideType, myCompanyId = props.myCompanyId, translator = props.translator
|
29063
|
+
var programme = props.programme, onFinish = props.onFinish, onCancel = props.onCancel, actionBtnText = props.actionBtnText, subText = props.subText, hideType = props.hideType, myCompanyId = props.myCompanyId, translator = props.translator;
|
28332
29064
|
var t = translator.t;
|
28333
29065
|
var _a = useState(undefined), popupError = _a[0], setPopupError = _a[1];
|
28334
29066
|
var _b = useState(false), loading = _b[0], setLoading = _b[1];
|
@@ -28704,7 +29436,7 @@ var ProgrammeRevokeForm = function (props) {
|
|
28704
29436
|
};
|
28705
29437
|
|
28706
29438
|
var ProgrammeTransferForm = function (props) {
|
28707
|
-
var programme = props.programme, onFinish = props.onFinish, onCancel = props.onCancel, actionBtnText = props.actionBtnText; props.subText; var toCompanyDefault = props.toCompanyDefault, disableToCompany = props.disableToCompany, receiverLabelText = props.receiverLabelText, userCompanyId = props.userCompanyId, companyRole = props.companyRole, translator = props.translator,
|
29439
|
+
var programme = props.programme, onFinish = props.onFinish, onCancel = props.onCancel, actionBtnText = props.actionBtnText; props.subText; var toCompanyDefault = props.toCompanyDefault, disableToCompany = props.disableToCompany, receiverLabelText = props.receiverLabelText, userCompanyId = props.userCompanyId, companyRole = props.companyRole, translator = props.translator, _a = props.ministryLevelPermission, ministryLevelPermission = _a === void 0 ? false : _a;
|
28708
29440
|
var t = translator.t;
|
28709
29441
|
var _b = useState(undefined), popupError = _b[0], setPopupError = _b[1];
|
28710
29442
|
var _c = useState(false), loading = _c[0], setLoading = _c[1];
|
@@ -28935,7 +29667,7 @@ var css_248z$5 = ".ndc-action-body {\n display: flex;\n flex-direction: column
|
|
28935
29667
|
styleInject(css_248z$5);
|
28936
29668
|
|
28937
29669
|
var NdcActionBody = function (props) {
|
28938
|
-
var data = props.data, programmeId = props.programmeId, canUploadMonitorReport = props.canUploadMonitorReport, programmeOwnerId = props.programmeOwnerId, getProgrammeDocs = props.getProgrammeDocs, ministryLevelPermission = props.ministryLevelPermission,
|
29670
|
+
var data = props.data, programmeId = props.programmeId, canUploadMonitorReport = props.canUploadMonitorReport, programmeOwnerId = props.programmeOwnerId, getProgrammeDocs = props.getProgrammeDocs, ministryLevelPermission = props.ministryLevelPermission, translator = props.translator, onFinish = props.onFinish, programme = props.programme;
|
28939
29671
|
var t = translator.t;
|
28940
29672
|
var userInfoState = useUserContext().userInfoState;
|
28941
29673
|
var fileInputMonitoringRef = useRef(null);
|
@@ -29371,7 +30103,7 @@ var css_248z$4 = ".info-view .title-icon {\n padding-right: 10px; }\n\n.info-vi
|
|
29371
30103
|
styleInject(css_248z$4);
|
29372
30104
|
|
29373
30105
|
var ProgrammeDocuments = function (props) {
|
29374
|
-
var data = props.data, title = props.title, icon = props.icon, programmeId = props.programmeId, programmeOwnerId = props.programmeOwnerId, getDocumentDetails = props.getDocumentDetails, getProgrammeById = props.getProgrammeById, ministryLevelPermission = props.ministryLevelPermission,
|
30106
|
+
var data = props.data, title = props.title, icon = props.icon, programmeId = props.programmeId, programmeOwnerId = props.programmeOwnerId, getDocumentDetails = props.getDocumentDetails, getProgrammeById = props.getProgrammeById, ministryLevelPermission = props.ministryLevelPermission, translator = props.translator, methodologyDocumentUpdated = props.methodologyDocumentUpdated, programmeStatus = props.programmeStatus;
|
29375
30107
|
var t = translator.t;
|
29376
30108
|
var userInfoState = useUserContext().userInfoState;
|
29377
30109
|
var _a = useConnection(); _a.delete; var post = _a.post;
|
@@ -30322,7 +31054,7 @@ var GHGUserActionConfirmationModel = function (props) {
|
|
30322
31054
|
};
|
30323
31055
|
|
30324
31056
|
var GHGEmissionsComponent = function (props) {
|
30325
|
-
var t = props.t
|
31057
|
+
var t = props.t;
|
30326
31058
|
var userInfoState = useUserContext().userInfoState;
|
30327
31059
|
var _a = useState([]), data = _a[0], setData = _a[1];
|
30328
31060
|
var _b = useConnection(), get = _b.get, post = _b.post;
|
@@ -32239,7 +32971,7 @@ var ProjectionTypes = {
|
|
32239
32971
|
};
|
32240
32972
|
|
32241
32973
|
var GHGProjectionsComponent = function (props) {
|
32242
|
-
var t = props.t
|
32974
|
+
var t = props.t;
|
32243
32975
|
var userInfoState = useUserContext().userInfoState;
|
32244
32976
|
var _a = useState([]), data = _a[0], setData = _a[1];
|
32245
32977
|
var _b = useConnection(); _b.put; var get = _b.get, post = _b.post;
|
@@ -34420,7 +35152,7 @@ var emissionComparisonOptionsSub = function (labels, chartColors) {
|
|
34420
35152
|
|
34421
35153
|
var RangePicker = DatePicker.RangePicker;
|
34422
35154
|
var GHGDashboardComponent = function (props) {
|
34423
|
-
var t = props.t,
|
35155
|
+
var t = props.t, Chart = props.Chart, ButtonGroup = props.ButtonGroup, Link = props.Link, isMultipleDashboardsVisible = props.isMultipleDashboardsVisible;
|
34424
35156
|
var _a = useConnection(); _a.get; var post = _a.post; _a.delete;
|
34425
35157
|
var userInfoState = useUserContext().userInfoState;
|
34426
35158
|
var _b = useState(moment().year()), endYear = _b[0], setEndYear = _b[1];
|
@@ -34799,5 +35531,5 @@ var GHGDashboardComponent = function (props) {
|
|
34799
35531
|
React.createElement(Row, { gutter: [40, 40], className: "statics-card-row" }, row.map(function (item, j) { return getWidgetJSX(item); })))); }))));
|
34800
35532
|
};
|
34801
35533
|
|
34802
|
-
export { Action, AddNdcActionComponent, AddNewCompanyComponent, AddNewUserComponent, AdminBGColor, AdminColor, BaseEntity, CarbonSystemType, CertBGColor, CertColor, CoBenifitsComponent, Company, CompanyManagementColumns, CompanyManagementComponent, CompanyProfileComponent, CompanyRole, CompanyState, ConfigurationSettingsType, CreditTransferComponent, CreditTransferStage, DevBGColor, DevColor, DocType, DocumentStatus, ESGType, Emission, EmissionGas, EmissionSector, EmissionSubSectors, EnergyGenerationUnits, FormElementType, GHGDashboardComponent, GHGEmissionsComponent, GHGProjectionsComponent, GhgStatCardTypes, GovBGColor, GovColor, ImgWithFallback, InfoView, Instrument, InvestmentBGColor, InvestmentBody, InvestmentColor, InvestmentCreationComponent, InvestmentCreationType, InvestmentLevel, InvestmentManagementComponent, InvestmentStatus, InvestmentStream, InvestmentType, LandAreaUnits, LegendItem, Loading, ManagerBGColor, ManagerColor, MapComponent, MapTypes, MapboxComponent, MinBGColor, MinColor, MitigationSubTypes, MitigationTypes, MrvDashboardComponent, MrvStatsCardsTypes, NdcActionBody, NdcActionManagementComponent, NdcActionStatus, NdcActionTypes, NdcActionViewComponent, NdcDetailsComponent, OrganisationStatus, ProfileIcon, ProgrammeCertify, ProgrammeCreationComponent, ProgrammeDocuments, ProgrammeEntity, ProgrammeIssueForm, ProgrammeManagementColumns, ProgrammeManagementComponent, ProgrammeRetireForm, ProgrammeRevokeForm, ProgrammeStageLegend, ProgrammeStageMRV, ProgrammeStageR, ProgrammeStageUnified, ProgrammeTransfer, ProgrammeTransferForm, Projection, ProjectionTypes$1 as ProjectionTypes, RadioButtonStatus, RadioButtonStatus2, RegistryDashboardComponent, RejectDocumentationConfirmationModel, RetireType, Role, RoleIcon, RootBGColor, RootColor, SdgGoals$1 as SdgGoals, Sector, SectoralScope, StasticCard, StatsCardsTypes, SubTypeOfMitigation, SupportCreationComponent, SupportManagementComponent, SystemNames, TimelineBody, Titles, TooltipColor, TransferActionModel, TxType, TypeOfMitigation, UnitField, User, UserManagementColumns, UserManagementComponent, UserProfileComponent, UserRoleIcon, ViewBGColor, ViewColor, WidgetType, addCommSep, addCommSepRound$1 as addCommSepRound, addNdcDesc, addRoundNumber, addSpaces, consumerGroupList, creditUnit, dateFormat, dateTimeFormat, energyGenerationUnitList, getBase64, getCompanyBgColor, getCreditStageVal, getFinancialFields, getGeneralFields, getInvestmentStatusEnumVal, getNdcActionStatusEnumVal$1 as getNdcActionStatusEnumVal, getNdcStatusTagType, getRetirementTypeString, getStageEnumVal, getStageTagType, getStageTagTypeMRV, getStageTransferEnumVal, getStatusTagType, getTransferStageTagType, getValidNdcActions, isBase64, landAreaUnitList, methodologyOptions, mitigationSubTypeList, mitigationSubTypesListMapped, mitigationTypeList, ndcActionTypeList, sectorMitigationTypesListMapped, sumArray, titleList };
|
35534
|
+
export { Action, AddNdcActionComponent, AddNewCompanyComponent, AddNewUserComponent, AdminBGColor, AdminColor, BaseEntity, CarbonSystemType, CertBGColor, CertColor, CoBenifitsComponent, Company, CompanyManagementColumns, CompanyManagementComponent, CompanyProfileComponent, CompanyRole, CompanyState, ConfigurationSettingsType, ConnectionContextProvider, CreditTransferComponent, CreditTransferStage, DevBGColor, DevColor, DocType, DocumentStatus, ESGType, Emission, EmissionGas, EmissionSector, EmissionSubSectors, EnergyGenerationUnits, FormElementType, GHGDashboardComponent, GHGEmissionsComponent, GHGProjectionsComponent, GhgStatCardTypes, GovBGColor, GovColor, ImgWithFallback, InfoView, Instrument, InvestmentBGColor, InvestmentBody, InvestmentColor, InvestmentCreationComponent, InvestmentCreationType, InvestmentLevel, InvestmentManagementComponent, InvestmentOwnershipType, InvestmentStatus, InvestmentStream, InvestmentType, LandAreaUnits, LegendItem, Loading, ManagerBGColor, ManagerColor, MapComponent, MapTypes, MapboxComponent, MinBGColor, MinColor, MitigationSubTypes, MitigationTypes, MrvDashboardComponent, MrvStatsCardsTypes, NdcActionBody, NdcActionManagementComponent, NdcActionStatus, NdcActionTypes, NdcActionViewComponent, NdcDetailsComponent, OrganisationStatus, ProfileIcon, ProgrammeCertify, ProgrammeCreationComponent, ProgrammeDocuments, ProgrammeEntity, ProgrammeIssueForm, ProgrammeManagementColumns, ProgrammeManagementComponent, ProgrammeRetireForm, ProgrammeRevokeForm, ProgrammeStageLegend, ProgrammeStageMRV, ProgrammeStageR, ProgrammeStageUnified, ProgrammeTransfer, ProgrammeTransferForm, Projection, ProjectionTypes$1 as ProjectionTypes, RadioButtonStatus, RadioButtonStatus2, RegistryDashboardComponent, RejectDocumentationConfirmationModel, RetireType, Role, RoleIcon, RootBGColor, RootColor, SdgGoals$1 as SdgGoals, Sector, SectoralScope, SettingsContext, SettingsContextProvider, StasticCard, StatsCardsTypes, SubTypeOfMitigation, SupportCreationComponent, SupportManagementComponent, SystemNames, TimelineBody, Titles, TooltipColor, TransferActionModel, TxType, TypeOfMitigation, UnitField, User, UserContext, UserInformationContextProvider, UserManagementColumns, UserManagementComponent, UserProfileComponent, UserRoleIcon, ViewBGColor, ViewColor, WidgetType, addCommSep, addCommSepRound$1 as addCommSepRound, addNdcDesc, addRoundNumber, addSpaces, consumerGroupList, creditUnit, dateFormat, dateTimeFormat, energyGenerationUnitList, getBase64, getCompanyBgColor, getCreditStageVal, getFinancialFields, getGeneralFields, getInvestmentStatusEnumVal, getNdcActionStatusEnumVal$1 as getNdcActionStatusEnumVal, getNdcStatusTagType, getRetirementTypeString, getStageEnumVal, getStageTagType, getStageTagTypeMRV, getStageTransferEnumVal, getStatusTagType, getTransferStageTagType, getValidNdcActions, isBase64, landAreaUnitList, methodologyOptions, mitigationSubTypeList, mitigationSubTypesListMapped, mitigationTypeList, ndcActionTypeList, sectorMitigationTypesListMapped, sumArray, titleList, useConnection, useSettingsContext, useUserContext };
|
34803
35535
|
//# sourceMappingURL=index.js.map
|