@undp/carbon-library 1.0.274-CARBON-359.0 → 1.0.274-CARBON-347.2
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/cjs/index.js +1089 -413
- 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 +1083 -415
- 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 +3 -1
- package/package.json +29 -2
package/dist/cjs/index.js
CHANGED
@@ -5,6 +5,7 @@ var antd = require('antd');
|
|
5
5
|
var React = require('react');
|
6
6
|
var luxon = require('luxon');
|
7
7
|
var buffer = require('buffer');
|
8
|
+
var axios = require('axios');
|
8
9
|
var PhoneInput = require('react-phone-number-input');
|
9
10
|
var validator = require('validator');
|
10
11
|
var classTransformer = require('class-transformer');
|
@@ -509,9 +510,317 @@ var OrganisationStatus = function (props) {
|
|
509
510
|
return orgState;
|
510
511
|
};
|
511
512
|
|
513
|
+
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";
|
514
|
+
|
515
|
+
var ConnectionContext = React.createContext({});
|
516
|
+
var ConnectionContextProvider = function (props) {
|
517
|
+
var _a = React.useState(), token = _a[0], setToken = _a[1];
|
518
|
+
var serverURL = props.serverURL, t = props.t, children = props.children, statServerUrl = props.statServerUrl;
|
519
|
+
React.useEffect(function () {
|
520
|
+
var timer = setInterval(function () { return __awaiter(void 0, void 0, void 0, function () {
|
521
|
+
var newToken;
|
522
|
+
return __generator(this, function (_a) {
|
523
|
+
switch (_a.label) {
|
524
|
+
case 0: return [4 /*yield*/, localStorage.getItem('token')];
|
525
|
+
case 1:
|
526
|
+
newToken = _a.sent();
|
527
|
+
if (token !== newToken) {
|
528
|
+
setToken(newToken);
|
529
|
+
}
|
530
|
+
return [2 /*return*/];
|
531
|
+
}
|
532
|
+
});
|
533
|
+
}); }, 3000);
|
534
|
+
if (token) {
|
535
|
+
clearTimeout(timer);
|
536
|
+
}
|
537
|
+
return function () {
|
538
|
+
clearTimeout(timer);
|
539
|
+
};
|
540
|
+
}, [token]);
|
541
|
+
var send = React.useCallback(function (method, path, data, config, extraUrl) {
|
542
|
+
return new Promise(function (resolve, reject) {
|
543
|
+
var url = "".concat(extraUrl ? extraUrl : serverURL, "/").concat(path);
|
544
|
+
var headers;
|
545
|
+
if (token) {
|
546
|
+
headers = { authorization: "Bearer ".concat(token.toString()) };
|
547
|
+
}
|
548
|
+
else {
|
549
|
+
if (localStorage.getItem('token')) {
|
550
|
+
headers = {
|
551
|
+
authorization: "Bearer ".concat(localStorage.getItem('token')),
|
552
|
+
};
|
553
|
+
}
|
554
|
+
else {
|
555
|
+
headers = {
|
556
|
+
authorization: "Bearer ".concat(process.env.STORYBOOK_ACCESS_TOKEN),
|
557
|
+
};
|
558
|
+
}
|
559
|
+
}
|
560
|
+
axios(__assign({ method: method, url: url, data: data, headers: headers }, config))
|
561
|
+
.then(function (response) {
|
562
|
+
var _a, _b, _c;
|
563
|
+
if (response.status) {
|
564
|
+
if (response.status === 200 || response.status === 201) {
|
565
|
+
resolve({
|
566
|
+
status: response.status,
|
567
|
+
data: (_a = response.data.data) !== null && _a !== void 0 ? _a : response.data,
|
568
|
+
response: response,
|
569
|
+
statusText: 'SUCCESS',
|
570
|
+
message: response.data.message,
|
571
|
+
});
|
572
|
+
}
|
573
|
+
else if (response.status === 422) {
|
574
|
+
reject({
|
575
|
+
status: response.status,
|
576
|
+
data: (_b = response.data) === null || _b === void 0 ? void 0 : _b.data,
|
577
|
+
statusText: 'ERROR',
|
578
|
+
response: response,
|
579
|
+
message: response.data.message,
|
580
|
+
errors: (_c = response.data) === null || _c === void 0 ? void 0 : _c.errors,
|
581
|
+
});
|
582
|
+
}
|
583
|
+
}
|
584
|
+
else {
|
585
|
+
reject({
|
586
|
+
status: 500,
|
587
|
+
statusText: 'UNKNOWN',
|
588
|
+
message: t('common:systemError'),
|
589
|
+
});
|
590
|
+
}
|
591
|
+
})
|
592
|
+
.catch(function (e) {
|
593
|
+
var _a;
|
594
|
+
if (e.response) {
|
595
|
+
if (e.response.status) {
|
596
|
+
if (e.response.data.message === 'jwt expired') {
|
597
|
+
localStorage.removeItem('token');
|
598
|
+
window.location.reload();
|
599
|
+
}
|
600
|
+
reject({
|
601
|
+
status: e.response.status,
|
602
|
+
statusText: 'ERROR',
|
603
|
+
errors: (_a = e.response.data) === null || _a === void 0 ? void 0 : _a.errors,
|
604
|
+
message: e.response.data.message,
|
605
|
+
});
|
606
|
+
}
|
607
|
+
else {
|
608
|
+
reject({
|
609
|
+
statusText: 'ERROR',
|
610
|
+
message: t('common:systemError'),
|
611
|
+
});
|
612
|
+
}
|
613
|
+
}
|
614
|
+
else {
|
615
|
+
reject({
|
616
|
+
statusText: 'ERROR',
|
617
|
+
message: t('common:networkError'),
|
618
|
+
});
|
619
|
+
}
|
620
|
+
});
|
621
|
+
});
|
622
|
+
}, [token, serverURL]);
|
623
|
+
var post = React.useCallback(function (path, data, config, extraUrl) {
|
624
|
+
return send('post', path, data, config, extraUrl);
|
625
|
+
}, [send]);
|
626
|
+
var put = React.useCallback(function (path, data, config) {
|
627
|
+
return send('put', path, data, config);
|
628
|
+
}, [send]);
|
629
|
+
var get = React.useCallback(function (path, config) {
|
630
|
+
return send('get', path, undefined, config);
|
631
|
+
}, [send]);
|
632
|
+
var patch = React.useCallback(function (path, data, config) {
|
633
|
+
return send('patch', path, data, config);
|
634
|
+
}, [send]);
|
635
|
+
var del = React.useCallback(function (path, config) {
|
636
|
+
return send('delete', path, config);
|
637
|
+
}, [send]);
|
638
|
+
var updateToken = React.useCallback(function (newToken) { return __awaiter(void 0, void 0, void 0, function () {
|
639
|
+
return __generator(this, function (_a) {
|
640
|
+
if (newToken) {
|
641
|
+
localStorage.setItem('token', newToken);
|
642
|
+
setToken(newToken);
|
643
|
+
}
|
644
|
+
else {
|
645
|
+
localStorage.setItem('token', '');
|
646
|
+
setToken(undefined);
|
647
|
+
}
|
648
|
+
return [2 /*return*/];
|
649
|
+
});
|
650
|
+
}); }, []);
|
651
|
+
var removeToken = function (tkn) {
|
652
|
+
if (tkn) {
|
653
|
+
var exp = o(tkn).exp;
|
654
|
+
if (Date.now() > exp * 1000) {
|
655
|
+
localStorage.setItem('token', '');
|
656
|
+
localStorage.removeItem('userRole');
|
657
|
+
localStorage.removeItem('userId');
|
658
|
+
localStorage.removeItem('companyId');
|
659
|
+
localStorage.removeItem('companyRole');
|
660
|
+
}
|
661
|
+
else {
|
662
|
+
var diff = exp * 1000 - Date.now();
|
663
|
+
setTimeout(function () {
|
664
|
+
setToken(undefined);
|
665
|
+
localStorage.setItem('token', '');
|
666
|
+
localStorage.removeItem('userRole');
|
667
|
+
localStorage.removeItem('userId');
|
668
|
+
localStorage.removeItem('companyId');
|
669
|
+
localStorage.removeItem('companyRole');
|
670
|
+
}, diff);
|
671
|
+
console.log(diff, 'Remaining Token expire time');
|
672
|
+
}
|
673
|
+
}
|
674
|
+
};
|
675
|
+
React.useEffect(function () {
|
676
|
+
removeToken(token);
|
677
|
+
}, [token]);
|
678
|
+
return (React.createElement(ConnectionContext.Provider, { value: {
|
679
|
+
connection: { post: post, put: put, get: get, patch: patch, delete: del, updateToken: updateToken, token: token, removeToken: removeToken, statServerUrl: statServerUrl },
|
680
|
+
} }, children));
|
681
|
+
};
|
682
|
+
var useConnection = function () {
|
683
|
+
var context = React.useContext(ConnectionContext);
|
684
|
+
return context.connection;
|
685
|
+
};
|
686
|
+
|
687
|
+
var UserContext = React.createContext({
|
688
|
+
setUserInfo: function () { },
|
689
|
+
removeUserInfo: function () { },
|
690
|
+
IsAuthenticated: function (tkn) { return false; },
|
691
|
+
isTokenExpired: false,
|
692
|
+
setIsTokenExpired: function (val) { },
|
693
|
+
});
|
694
|
+
var UserInformationContextProvider = function (_a) {
|
695
|
+
var children = _a.children;
|
696
|
+
var token = useConnection().token;
|
697
|
+
var _b = React.useState(false), isTokenExpired = _b[0], setIsTokenExpired = _b[1];
|
698
|
+
var initialUserProps = {
|
699
|
+
id: localStorage.getItem('userId') ? localStorage.getItem('userId') : process.env.STORYBOOK_USER_ID ? process.env.STORYBOOK_USER_ID : '',
|
700
|
+
userRole: localStorage.getItem('userRole') ? localStorage.getItem('userRole') : process.env.STORYBOOK_USER_ROLE ? process.env.STORYBOOK_USER_ROLE : '',
|
701
|
+
companyRole: localStorage.getItem('companyRole')
|
702
|
+
? localStorage.getItem('companyRole')
|
703
|
+
: process.env.STORYBOOK_COMPANY_ROLE ? process.env.STORYBOOK_COMPANY_ROLE : '',
|
704
|
+
companyId: localStorage.getItem('companyId')
|
705
|
+
? parseInt(localStorage.getItem('companyId'))
|
706
|
+
: process.env.STORYBOOK_COMPANY_ID ? parseInt(process.env.STORYBOOK_COMPANY_ID) : -1,
|
707
|
+
companyLogo: localStorage.getItem('companyLogo')
|
708
|
+
? localStorage.getItem('companyLogo')
|
709
|
+
: process.env.STORYBOOK_COMPANY_LOGO ? process.env.STORYBOOK_COMPANY_LOGO : '',
|
710
|
+
companyName: localStorage.getItem('companyName')
|
711
|
+
? localStorage.getItem('companyName')
|
712
|
+
: process.env.STORYBOOK_COMPANY_NAME ? process.env.STORYBOOK_COMPANY_NAME : '',
|
713
|
+
companyState: localStorage.getItem('companyState')
|
714
|
+
? parseInt(localStorage.getItem('companyState'))
|
715
|
+
: process.env.STORYBOOK_COMPANY_STATE ? parseInt(process.env.STORYBOOK_COMPANY_STATE) : 0,
|
716
|
+
};
|
717
|
+
var _c = React.useState(initialUserProps), userInfoState = _c[0], setUserInfoState = _c[1];
|
718
|
+
var setUserInfo = function (value) {
|
719
|
+
var state = (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyState) === 1 ? userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyState : 0;
|
720
|
+
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;
|
721
|
+
if (id) {
|
722
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { id: id })); });
|
723
|
+
localStorage.setItem('userId', id);
|
724
|
+
}
|
725
|
+
if (userRole) {
|
726
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { userRole: userRole })); });
|
727
|
+
localStorage.setItem('userRole', userRole);
|
728
|
+
}
|
729
|
+
if (companyId) {
|
730
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyId: companyId })); });
|
731
|
+
localStorage.setItem('companyId', companyId + '');
|
732
|
+
}
|
733
|
+
if (companyLogo) {
|
734
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyLogo: companyLogo })); });
|
735
|
+
localStorage.setItem('companyLogo', companyLogo);
|
736
|
+
}
|
737
|
+
else {
|
738
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyLogo: '' })); });
|
739
|
+
localStorage.setItem('companyLogo', '');
|
740
|
+
}
|
741
|
+
if (companyName) {
|
742
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyName: companyName })); });
|
743
|
+
localStorage.setItem('companyName', companyName);
|
744
|
+
}
|
745
|
+
if (userRole) {
|
746
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyRole: companyRole })); });
|
747
|
+
localStorage.setItem('companyRole', companyRole);
|
748
|
+
}
|
749
|
+
setUserInfoState(function (prev) { return (__assign(__assign({}, prev), { companyState: companyState })); });
|
750
|
+
localStorage.setItem('companyState', companyState + '');
|
751
|
+
};
|
752
|
+
var IsAuthenticated = React.useCallback(function (tokenNew) {
|
753
|
+
var tokenVal;
|
754
|
+
if (tokenNew) {
|
755
|
+
tokenVal = tokenNew;
|
756
|
+
}
|
757
|
+
else if (token) {
|
758
|
+
tokenVal = token;
|
759
|
+
}
|
760
|
+
else {
|
761
|
+
tokenVal = localStorage.getItem('token');
|
762
|
+
if (tokenVal === '') {
|
763
|
+
if (history.length !== 1) {
|
764
|
+
setIsTokenExpired(true);
|
765
|
+
}
|
766
|
+
}
|
767
|
+
}
|
768
|
+
try {
|
769
|
+
if (tokenVal) {
|
770
|
+
var exp = o(tokenVal).exp;
|
771
|
+
return Date.now() < exp * 1000;
|
772
|
+
}
|
773
|
+
return false;
|
774
|
+
}
|
775
|
+
catch (err) {
|
776
|
+
return false;
|
777
|
+
}
|
778
|
+
}, [token]);
|
779
|
+
var removeUserInfo = function () {
|
780
|
+
localStorage.removeItem('userId');
|
781
|
+
localStorage.removeItem('userRole');
|
782
|
+
localStorage.removeItem('companyId');
|
783
|
+
localStorage.removeItem('companyRole');
|
784
|
+
localStorage.removeItem('companyName');
|
785
|
+
localStorage.removeItem('companyState');
|
786
|
+
localStorage.removeItem('companyLogo');
|
787
|
+
setUserInfoState(initialUserProps);
|
788
|
+
};
|
789
|
+
return (React.createElement(UserContext.Provider, { value: {
|
790
|
+
userInfoState: userInfoState,
|
791
|
+
setUserInfo: setUserInfo,
|
792
|
+
removeUserInfo: removeUserInfo,
|
793
|
+
IsAuthenticated: IsAuthenticated,
|
794
|
+
isTokenExpired: isTokenExpired,
|
795
|
+
setIsTokenExpired: setIsTokenExpired,
|
796
|
+
} }, children));
|
797
|
+
};
|
798
|
+
var useUserContext = function () {
|
799
|
+
return React.useContext(UserContext);
|
800
|
+
};
|
801
|
+
|
802
|
+
var SettingsContext = React.createContext({
|
803
|
+
isTransferFrozen: false,
|
804
|
+
setTransferFrozen: function (value) { },
|
805
|
+
});
|
806
|
+
var SettingsContextProvider = function (_a) {
|
807
|
+
var children = _a.children;
|
808
|
+
var _b = React.useState(false), isTransferFrozen = _b[0], setIsTransferFrozen = _b[1];
|
809
|
+
var setTransferFrozen = function (value) {
|
810
|
+
setIsTransferFrozen(value);
|
811
|
+
};
|
812
|
+
return (React.createElement(SettingsContext.Provider, { value: {
|
813
|
+
isTransferFrozen: isTransferFrozen,
|
814
|
+
setTransferFrozen: setTransferFrozen,
|
815
|
+
} }, children));
|
816
|
+
};
|
817
|
+
var useSettingsContext = function () {
|
818
|
+
return React.useContext(SettingsContext);
|
819
|
+
};
|
820
|
+
|
512
821
|
var Search$2 = antd.Input.Search;
|
513
822
|
var CompanyManagementComponent = function (props) {
|
514
|
-
var t = props.t, useAbilityContext = props.useAbilityContext,
|
823
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, visibleColumns = props.visibleColumns, onNavigateToCompanyProfile = props.onNavigateToCompanyProfile, onClickAddCompany = props.onClickAddCompany;
|
515
824
|
var _a = React.useState(), totalCompany = _a[0], setTotalCompany = _a[1];
|
516
825
|
var _b = React.useState(false), loading = _b[0], setLoading = _b[1];
|
517
826
|
var _c = React.useState([]), tableData = _c[0], setTableData = _c[1];
|
@@ -525,6 +834,7 @@ var CompanyManagementComponent = function (props) {
|
|
525
834
|
var _k = React.useState(""), sortOrder = _k[0], setSortOrder = _k[1];
|
526
835
|
var _l = React.useState(""), sortField = _l[0], setSortField = _l[1];
|
527
836
|
var ability = useAbilityContext();
|
837
|
+
var post = useConnection().post;
|
528
838
|
document.addEventListener("mousedown", function (event) {
|
529
839
|
var organisationFilterArea1 = document.querySelector(".filter-bar");
|
530
840
|
var organisationFilterArea2 = document.querySelector(".filter-dropdown");
|
@@ -857,7 +1167,7 @@ var CompanyManagementComponent = function (props) {
|
|
857
1167
|
var css_248z$s = ".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";
|
858
1168
|
styleInject(css_248z$s);
|
859
1169
|
|
860
|
-
var css_248z$r = "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.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";
|
1170
|
+
var css_248z$r = "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 .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 .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 .ant-row {\n align-items: unset; }\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";
|
861
1171
|
styleInject(css_248z$r);
|
862
1172
|
|
863
1173
|
exports.UserManagementColumns = void 0;
|
@@ -929,6 +1239,11 @@ exports.InvestmentCreationType = void 0;
|
|
929
1239
|
InvestmentCreationType["EXISTING"] = "Existing";
|
930
1240
|
InvestmentCreationType["NEW"] = "New";
|
931
1241
|
})(exports.InvestmentCreationType || (exports.InvestmentCreationType = {}));
|
1242
|
+
exports.InvestmentOwnershipType = void 0;
|
1243
|
+
(function (InvestmentOwnershipType) {
|
1244
|
+
InvestmentOwnershipType["PROJECT"] = "Project";
|
1245
|
+
InvestmentOwnershipType["NATIONAL"] = "National";
|
1246
|
+
})(exports.InvestmentOwnershipType || (exports.InvestmentOwnershipType = {}));
|
932
1247
|
exports.InvestmentStream = void 0;
|
933
1248
|
(function (InvestmentStream) {
|
934
1249
|
InvestmentStream["CLIMATE_FINANCE"] = "ClimateFinance";
|
@@ -5754,7 +6069,7 @@ var ProgrammeCertify = /** @class */ (function () {
|
|
5754
6069
|
|
5755
6070
|
var AddNewCompanyComponent = function (props) {
|
5756
6071
|
var _a;
|
5757
|
-
var t = props.t, onNavigateToCompanyManagement = props.onNavigateToCompanyManagement, maximumImageSize = props.maximumImageSize,
|
6072
|
+
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;
|
5758
6073
|
var formOne = antd.Form.useForm()[0];
|
5759
6074
|
var formTwo = antd.Form.useForm()[0];
|
5760
6075
|
var _b = React.useState(), stepOneData = _b[0], setStepOneData = _b[1];
|
@@ -6543,7 +6858,7 @@ var css_248z$q = ".company-profile {\n padding: 0px 50px; }\n .company-profile
|
|
6543
6858
|
styleInject(css_248z$q);
|
6544
6859
|
|
6545
6860
|
var CompanyProfileComponent = function (props) {
|
6546
|
-
var t = props.t, useAbilityContext = props.useAbilityContext, useLocation = props.useLocation,
|
6861
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, useLocation = props.useLocation, onNavigateToCompanyManagement = props.onNavigateToCompanyManagement, onNavigateToCompanyEdit = props.onNavigateToCompanyEdit, regionField = props.regionField, systemType = props.systemType;
|
6547
6862
|
var _a = useConnection(), get = _a.get, put = _a.put, post = _a.post;
|
6548
6863
|
var _b = React.useState(undefined), companyDetails = _b[0], setCompanyDetails = _b[1];
|
6549
6864
|
var _c = React.useState(undefined), userDetails = _c[0], setUserDetails = _c[1];
|
@@ -6976,7 +7291,7 @@ styleInject(css_248z$p);
|
|
6976
7291
|
|
6977
7292
|
var Search$1 = antd.Input.Search;
|
6978
7293
|
var ProgrammeManagementComponent = function (props) {
|
6979
|
-
var t = props.t, visibleColumns = props.visibleColumns,
|
7294
|
+
var t = props.t, visibleColumns = props.visibleColumns, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onClickAddProgramme = props.onClickAddProgramme, enableAddProgramme = props.enableAddProgramme, useAbilityContext = props.useAbilityContext;
|
6980
7295
|
var _a = useConnection(); _a.get; _a.delete; var post = _a.post;
|
6981
7296
|
var _b = React.useState(), totalProgramme = _b[0], setTotalProgramme = _b[1];
|
6982
7297
|
var _c = React.useState(false), loading = _c[0], setLoading = _c[1];
|
@@ -7361,7 +7676,7 @@ var ProgrammeManagementComponent = function (props) {
|
|
7361
7676
|
React.createElement("div", { className: "filter-section" },
|
7362
7677
|
React.createElement("div", { className: "search-filter" },
|
7363
7678
|
React.createElement(antd.Checkbox, { className: "label", onChange: function (v) {
|
7364
|
-
if (userInfoState.companyRole === exports.CompanyRole.MINISTRY) {
|
7679
|
+
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === exports.CompanyRole.MINISTRY) {
|
7365
7680
|
if (v.target.checked) {
|
7366
7681
|
setMinistryLevelFilter(true);
|
7367
7682
|
}
|
@@ -7378,7 +7693,7 @@ var ProgrammeManagementComponent = function (props) {
|
|
7378
7693
|
}
|
7379
7694
|
: undefined);
|
7380
7695
|
}
|
7381
|
-
} }, userInfoState.companyRole === exports.CompanyRole.MINISTRY
|
7696
|
+
} }, (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === exports.CompanyRole.MINISTRY
|
7382
7697
|
? t("view:ministryLevel")
|
7383
7698
|
: t("view:seeMine"))),
|
7384
7699
|
React.createElement("div", { className: "search-bar" },
|
@@ -13159,7 +13474,7 @@ var sectoralScopes = {
|
|
13159
13474
|
};
|
13160
13475
|
var ProgrammeCreationComponent = function (props) {
|
13161
13476
|
var _a, _b, _c;
|
13162
|
-
var
|
13477
|
+
var useLocation = props.useLocation, onNavigateToProgrammeView = props.onNavigateToProgrammeView, translator = props.translator;
|
13163
13478
|
var t = translator.t;
|
13164
13479
|
var state = useLocation().state;
|
13165
13480
|
var formOne = antd.Form.useForm()[0];
|
@@ -14224,7 +14539,7 @@ var ChangePasswordModel = function (props) {
|
|
14224
14539
|
|
14225
14540
|
var AddNewUserComponent = function (props) {
|
14226
14541
|
var _a, _b, _c, _d, _e, _f;
|
14227
|
-
var t = props.t, onNavigateToUserManagement = props.onNavigateToUserManagement, onNavigateLogin = props.onNavigateLogin,
|
14542
|
+
var t = props.t, onNavigateToUserManagement = props.onNavigateToUserManagement, onNavigateLogin = props.onNavigateLogin, useLocation = props.useLocation, useAbilityContext = props.useAbilityContext, themeColor = props.themeColor;
|
14228
14543
|
var _g = useConnection(), post = _g.post, put = _g.put, del = _g.delete, get = _g.get;
|
14229
14544
|
var formOne = antd.Form.useForm()[0];
|
14230
14545
|
var state = useLocation().state;
|
@@ -14642,7 +14957,7 @@ var LanguageSelection = function (props) {
|
|
14642
14957
|
};
|
14643
14958
|
|
14644
14959
|
var UserProfileComponent = function (props) {
|
14645
|
-
var t = props.t, i18n = props.i18n,
|
14960
|
+
var t = props.t, i18n = props.i18n, onNavigateUpdateUser = props.onNavigateUpdateUser, onNavigateLogin = props.onNavigateLogin;
|
14646
14961
|
var get = useConnection().get;
|
14647
14962
|
var _a = React.useState(undefined), organisationDetails = _a[0], setOrganisationDetails = _a[1];
|
14648
14963
|
var _b = React.useState(undefined), userDetails = _b[0], setUserDetails = _b[1];
|
@@ -14810,7 +15125,7 @@ styleInject(css_248z$k);
|
|
14810
15125
|
|
14811
15126
|
var Search = antd.Input.Search;
|
14812
15127
|
var UserManagementComponent = function (props) {
|
14813
|
-
var t = props.t, useAbilityContext = props.useAbilityContext,
|
15128
|
+
var t = props.t, useAbilityContext = props.useAbilityContext, visibleColumns = props.visibleColumns, onNavigateToUpdateUser = props.onNavigateToUpdateUser, onClickAddUser = props.onClickAddUser;
|
14814
15129
|
antd.Form.useForm()[0];
|
14815
15130
|
var _a = useConnection(), post = _a.post, del = _a.delete;
|
14816
15131
|
var _b = React.useState(), totalUser = _b[0], setTotalUser = _b[1];
|
@@ -14832,6 +15147,7 @@ var UserManagementComponent = function (props) {
|
|
14832
15147
|
var _s = React.useState(""), errorMsg = _s[0], setErrorMsg = _s[1];
|
14833
15148
|
var _t = React.useState(false), openDeleteConfirmationModal = _t[0], setOpenDeleteConfirmationModal = _t[1];
|
14834
15149
|
var ability = useAbilityContext();
|
15150
|
+
var userInfoState = useUserContext().userInfoState;
|
14835
15151
|
document.addEventListener("mousedown", function (event) {
|
14836
15152
|
var userFilterArea1 = document.querySelector(".filter-bar");
|
14837
15153
|
var userFilterArea2 = document.querySelector(".filter-dropdown");
|
@@ -15344,7 +15660,7 @@ var UserManagementComponent = function (props) {
|
|
15344
15660
|
React.createElement(UserActionConfirmationModel, { t: t, actionInfo: actionInfo, onActionConfirmed: handleOk, onActionCanceled: handleCancel, openModal: openDeleteConfirmationModal, errorMsg: errorMsg, loading: loading })));
|
15345
15661
|
};
|
15346
15662
|
|
15347
|
-
var css_248z$j = ".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
|
15663
|
+
var css_248z$j = ".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";
|
15348
15664
|
styleInject(css_248z$j);
|
15349
15665
|
|
15350
15666
|
var Loading = function () {
|
@@ -15352,21 +15668,34 @@ var Loading = function () {
|
|
15352
15668
|
};
|
15353
15669
|
|
15354
15670
|
var InvestmentCreationComponent = function (props) {
|
15355
|
-
var t = props.t,
|
15671
|
+
var t = props.t, useLocation = props.useLocation, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onNavigateToInvestmentManagementView = props.onNavigateToInvestmentManagementView;
|
15356
15672
|
var state = useLocation().state;
|
15357
15673
|
var _a = React.useState(), data = _a[0], setData = _a[1];
|
15674
|
+
var _b = React.useState({}), companyNames = _b[0], setCompanyNames = _b[1];
|
15675
|
+
var _c = React.useState({}); _c[0]; var setUserOrganization = _c[1];
|
15676
|
+
var _d = React.useState({}), investmentNames = _d[0], setInvestmentNames = _d[1];
|
15677
|
+
var _e = React.useState(), projectData = _e[0], setProjectData = _e[1];
|
15678
|
+
var _f = React.useState(), investmentData = _f[0], setInvestmentData = _f[1];
|
15679
|
+
var _g = React.useState([]), allProjectData = _g[0], setAllProjectData = _g[1];
|
15358
15680
|
var formOne = antd.Form.useForm()[0];
|
15359
15681
|
var formTwo = antd.Form.useForm()[0];
|
15360
15682
|
var post = useConnection().post;
|
15361
|
-
var
|
15362
|
-
var
|
15363
|
-
var
|
15364
|
-
var
|
15365
|
-
var
|
15366
|
-
var
|
15367
|
-
var
|
15368
|
-
var
|
15369
|
-
var
|
15683
|
+
var _h = React.useState(false), loading = _h[0], setLoading = _h[1];
|
15684
|
+
var _j = React.useState("New"), typeCreation = _j[0], setTypeCreation = _j[1];
|
15685
|
+
var _k = React.useState(exports.InvestmentOwnershipType.PROJECT), investmentOwnershipType = _k[0], setInvestmentOwnershipType = _k[1];
|
15686
|
+
var _l = React.useState(false), loadingList = _l[0], setLoadingList = _l[1];
|
15687
|
+
var _m = React.useState(false), loadingInvestment = _m[0], setLoadingInvestment = _m[1];
|
15688
|
+
var _o = React.useState(false), loadingProgData = _o[0], setLoadingProgData = _o[1];
|
15689
|
+
var _p = React.useState(0), current = _p[0], setCurrent = _p[1];
|
15690
|
+
var _q = React.useState(0), currentPercTotal = _q[0], setCurrentPercTotal = _q[1];
|
15691
|
+
var _r = React.useState([]), organisationsList = _r[0], setOrganisationList = _r[1];
|
15692
|
+
var _s = React.useState([]), nationalInvestmentList = _s[0], setNationalInvestmentList = _s[1];
|
15693
|
+
var _t = React.useState([]), instrument = _t[0], setInstrument = _t[1];
|
15694
|
+
var _u = React.useState(), stepOneData = _u[0], setStepOneData = _u[1];
|
15695
|
+
var _v = React.useState(), govData = _v[0], setGovData = _v[1];
|
15696
|
+
var userInfoState = useUserContext().userInfoState;
|
15697
|
+
var _w = React.useState([]), ministrySectoralScope = _w[0], setMinistrySectoralScope = _w[1];
|
15698
|
+
var _x = React.useState({}), prevInvestor = _x[0], setPrevInvestor = _x[1];
|
15370
15699
|
var instrumentOptions = Object.keys(exports.Instrument).map(function (k, index) { return ({
|
15371
15700
|
label: addSpaces(Object.values(exports.Instrument)[index]),
|
15372
15701
|
value: Object.values(exports.Instrument)[index],
|
@@ -15417,52 +15746,215 @@ var InvestmentCreationComponent = function (props) {
|
|
15417
15746
|
}
|
15418
15747
|
});
|
15419
15748
|
}); };
|
15420
|
-
var
|
15421
|
-
var
|
15749
|
+
var getAllProjectData = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15750
|
+
var response, error_2;
|
15751
|
+
return __generator(this, function (_a) {
|
15752
|
+
switch (_a.label) {
|
15753
|
+
case 0:
|
15754
|
+
setLoadingProgData(true);
|
15755
|
+
_a.label = 1;
|
15756
|
+
case 1:
|
15757
|
+
_a.trys.push([1, 5, 6, 7]);
|
15758
|
+
if (!data) return [3 /*break*/, 4];
|
15759
|
+
if (!!(data === null || data === void 0 ? void 0 : data.programmeId)) return [3 /*break*/, 3];
|
15760
|
+
console.log("data non existing", data);
|
15761
|
+
console.log("getting all Project data");
|
15762
|
+
return [4 /*yield*/, post("national/programme/query", {
|
15763
|
+
page: 1,
|
15764
|
+
size: 100,
|
15765
|
+
filterAnd: [
|
15766
|
+
{
|
15767
|
+
key: "currentStage",
|
15768
|
+
operation: "!=",
|
15769
|
+
value: exports.ProgrammeStageUnified.Rejected,
|
15770
|
+
},
|
15771
|
+
],
|
15772
|
+
})];
|
15773
|
+
case 2:
|
15774
|
+
response = _a.sent();
|
15775
|
+
if (response.data) {
|
15776
|
+
setAllProjectData(response === null || response === void 0 ? void 0 : response.data);
|
15777
|
+
console.log("all Project data", response === null || response === void 0 ? void 0 : response.data);
|
15778
|
+
}
|
15779
|
+
return [3 /*break*/, 4];
|
15780
|
+
case 3:
|
15781
|
+
console.log("setting current Project data");
|
15782
|
+
setAllProjectData([data]);
|
15783
|
+
_a.label = 4;
|
15784
|
+
case 4: return [3 /*break*/, 7];
|
15785
|
+
case 5:
|
15786
|
+
error_2 = _a.sent();
|
15787
|
+
console.log("Error in getting all programme data", error_2);
|
15788
|
+
return [3 /*break*/, 7];
|
15789
|
+
case 6:
|
15790
|
+
setLoadingProgData(false);
|
15791
|
+
return [7 /*endfinally*/];
|
15792
|
+
case 7: return [2 /*return*/];
|
15793
|
+
}
|
15794
|
+
});
|
15795
|
+
}); };
|
15796
|
+
var setSelectedProgramme = function (value) { return __awaiter(void 0, void 0, void 0, function () {
|
15797
|
+
var _i, allProjectData_1, obj;
|
15798
|
+
return __generator(this, function (_a) {
|
15799
|
+
console.log("setSelectedProgramme", value);
|
15800
|
+
for (_i = 0, allProjectData_1 = allProjectData; _i < allProjectData_1.length; _i++) {
|
15801
|
+
obj = allProjectData_1[_i];
|
15802
|
+
if (obj.programmeId == value) {
|
15803
|
+
setProjectData(obj);
|
15804
|
+
break;
|
15805
|
+
}
|
15806
|
+
}
|
15807
|
+
return [2 /*return*/];
|
15808
|
+
});
|
15809
|
+
}); };
|
15810
|
+
var setSelectedInvestment = function (value) { return __awaiter(void 0, void 0, void 0, function () {
|
15811
|
+
return __generator(this, function (_a) {
|
15812
|
+
console.log("setSelectedInvestment", value);
|
15813
|
+
setInvestmentData(investmentNames[value]);
|
15814
|
+
return [2 /*return*/];
|
15815
|
+
});
|
15816
|
+
}); };
|
15817
|
+
var getNationalInvestmentDetails = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15818
|
+
var filterAnd, response, investmentData_1, _i, _a, investment, error_3;
|
15422
15819
|
return __generator(this, function (_b) {
|
15423
15820
|
switch (_b.label) {
|
15424
15821
|
case 0:
|
15425
|
-
|
15822
|
+
setLoadingInvestment(true);
|
15426
15823
|
_b.label = 1;
|
15427
15824
|
case 1:
|
15428
15825
|
_b.trys.push([1, 3, 4, 5]);
|
15429
15826
|
filterAnd = [];
|
15430
15827
|
filterAnd = [
|
15431
15828
|
{
|
15432
|
-
key: "
|
15829
|
+
key: "category",
|
15433
15830
|
operation: "=",
|
15434
|
-
value: exports.
|
15831
|
+
value: exports.InvestmentOwnershipType.NATIONAL.toString(),
|
15832
|
+
},
|
15833
|
+
{
|
15834
|
+
key: "amount",
|
15835
|
+
operation: ">",
|
15836
|
+
value: 0,
|
15435
15837
|
},
|
15436
15838
|
];
|
15437
15839
|
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === exports.CompanyRole.PROGRAMME_DEVELOPER) {
|
15438
15840
|
filterAnd.push({
|
15439
|
-
key: "
|
15440
|
-
operation: "
|
15841
|
+
key: "toCompanyId",
|
15842
|
+
operation: "=",
|
15441
15843
|
value: userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyId,
|
15442
15844
|
});
|
15443
15845
|
}
|
15444
|
-
|
15445
|
-
c = _a[_i];
|
15446
|
-
filterAnd.push({
|
15447
|
-
key: "companyId",
|
15448
|
-
operation: "!=",
|
15449
|
-
value: c,
|
15450
|
-
});
|
15451
|
-
}
|
15452
|
-
return [4 /*yield*/, post("national/organisation/queryNames", {
|
15846
|
+
return [4 /*yield*/, post("national/programme/investmentQuery", {
|
15453
15847
|
page: 1,
|
15454
15848
|
size: 100,
|
15455
15849
|
filterAnd: filterAnd,
|
15456
15850
|
})];
|
15457
15851
|
case 2:
|
15458
15852
|
response = _b.sent();
|
15853
|
+
if (response.data) {
|
15854
|
+
setNationalInvestmentList(response === null || response === void 0 ? void 0 : response.data);
|
15855
|
+
investmentData_1 = {};
|
15856
|
+
for (_i = 0, _a = response === null || response === void 0 ? void 0 : response.data; _i < _a.length; _i++) {
|
15857
|
+
investment = _a[_i];
|
15858
|
+
investmentData_1[investment.requestId] = investment;
|
15859
|
+
}
|
15860
|
+
setInvestmentNames(investmentData_1);
|
15861
|
+
console.log(investmentData_1);
|
15862
|
+
}
|
15863
|
+
return [3 /*break*/, 5];
|
15864
|
+
case 3:
|
15865
|
+
error_3 = _b.sent();
|
15866
|
+
console.log("Error in getting national Investments list", error_3);
|
15867
|
+
return [3 /*break*/, 5];
|
15868
|
+
case 4:
|
15869
|
+
setLoadingInvestment(false);
|
15870
|
+
return [7 /*endfinally*/];
|
15871
|
+
case 5: return [2 /*return*/];
|
15872
|
+
}
|
15873
|
+
});
|
15874
|
+
}); };
|
15875
|
+
var getUserOrganization = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15876
|
+
var response, error_4;
|
15877
|
+
return __generator(this, function (_a) {
|
15878
|
+
switch (_a.label) {
|
15879
|
+
case 0:
|
15880
|
+
_a.trys.push([0, 2, , 3]);
|
15881
|
+
return [4 /*yield*/, post("national/organisation/query", {
|
15882
|
+
page: 1,
|
15883
|
+
size: 100,
|
15884
|
+
filterAnd: [
|
15885
|
+
{ key: "companyId", operation: "=", value: userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyId },
|
15886
|
+
],
|
15887
|
+
})];
|
15888
|
+
case 1:
|
15889
|
+
response = _a.sent();
|
15890
|
+
console.log("getUserOrganization", response.data[0]);
|
15891
|
+
setUserOrganization(response.data[0]);
|
15892
|
+
setMinistrySectoralScope(response.data[0].sectoralScope);
|
15893
|
+
return [3 /*break*/, 3];
|
15894
|
+
case 2:
|
15895
|
+
error_4 = _a.sent();
|
15896
|
+
console.log("Error in getting user organization", error_4);
|
15897
|
+
return [3 /*break*/, 3];
|
15898
|
+
case 3: return [2 /*return*/];
|
15899
|
+
}
|
15900
|
+
});
|
15901
|
+
}); };
|
15902
|
+
var getOrganisationsDetails = function () { return __awaiter(void 0, void 0, void 0, function () {
|
15903
|
+
var filterAnd, filterOr, _i, _a, c, filters, response, companyName, _b, _c, company, error_5;
|
15904
|
+
return __generator(this, function (_d) {
|
15905
|
+
switch (_d.label) {
|
15906
|
+
case 0:
|
15907
|
+
setLoadingList(true);
|
15908
|
+
_d.label = 1;
|
15909
|
+
case 1:
|
15910
|
+
_d.trys.push([1, 3, 4, 5]);
|
15911
|
+
filterAnd = [];
|
15912
|
+
filterOr = [];
|
15913
|
+
filterAnd = [
|
15914
|
+
{
|
15915
|
+
key: "companyRole",
|
15916
|
+
operation: "=",
|
15917
|
+
value: exports.CompanyRole.PROGRAMME_DEVELOPER.toString(),
|
15918
|
+
},
|
15919
|
+
];
|
15920
|
+
// if (userInfoState?.companyRole === CompanyRole.PROGRAMME_DEVELOPER) {
|
15921
|
+
// filterAnd.push({
|
15922
|
+
// key: "companyId",
|
15923
|
+
// operation: "!=",
|
15924
|
+
// value: userInfoState?.companyId,
|
15925
|
+
// });
|
15926
|
+
// }
|
15927
|
+
if (data === null || data === void 0 ? void 0 : data.companyId) {
|
15928
|
+
for (_i = 0, _a = data === null || data === void 0 ? void 0 : data.companyId; _i < _a.length; _i++) {
|
15929
|
+
c = _a[_i];
|
15930
|
+
filterOr.push({
|
15931
|
+
key: "companyId",
|
15932
|
+
operation: "=",
|
15933
|
+
value: c,
|
15934
|
+
});
|
15935
|
+
}
|
15936
|
+
}
|
15937
|
+
filters = void 0;
|
15938
|
+
if (filterOr.length) {
|
15939
|
+
filters.filterOr = filterOr;
|
15940
|
+
}
|
15941
|
+
return [4 /*yield*/, post("national/organisation/queryNames", __assign({ page: 1, size: 100, filterAnd: filterAnd }, filters))];
|
15942
|
+
case 2:
|
15943
|
+
response = _d.sent();
|
15459
15944
|
if (response.data) {
|
15460
15945
|
setOrganisationList(response === null || response === void 0 ? void 0 : response.data);
|
15946
|
+
companyName = {};
|
15947
|
+
for (_b = 0, _c = response === null || response === void 0 ? void 0 : response.data; _b < _c.length; _b++) {
|
15948
|
+
company = _c[_b];
|
15949
|
+
companyName[Number(company.companyId)] = company.name;
|
15950
|
+
}
|
15951
|
+
setCompanyNames(companyName);
|
15952
|
+
console.log(companyName);
|
15461
15953
|
}
|
15462
15954
|
return [3 /*break*/, 5];
|
15463
15955
|
case 3:
|
15464
|
-
|
15465
|
-
console.log("Error in getting organization list",
|
15956
|
+
error_5 = _d.sent();
|
15957
|
+
console.log("Error in getting organization list", error_5);
|
15466
15958
|
return [3 /*break*/, 5];
|
15467
15959
|
case 4:
|
15468
15960
|
setLoadingList(false);
|
@@ -15477,52 +15969,71 @@ var InvestmentCreationComponent = function (props) {
|
|
15477
15969
|
return;
|
15478
15970
|
}
|
15479
15971
|
if (state === null || state === void 0 ? void 0 : state.record) {
|
15972
|
+
console.log("condition 1 data", state === null || state === void 0 ? void 0 : state.record);
|
15480
15973
|
setData(state === null || state === void 0 ? void 0 : state.record);
|
15481
15974
|
}
|
15482
15975
|
else {
|
15976
|
+
console.log("condition 2 data", { ownership: true });
|
15483
15977
|
setData({ ownership: true });
|
15484
15978
|
}
|
15485
15979
|
}, []);
|
15486
15980
|
React.useEffect(function () {
|
15487
|
-
if (data) {
|
15488
|
-
|
15489
|
-
|
15490
|
-
|
15491
|
-
|
15492
|
-
}
|
15981
|
+
// if (data) {
|
15982
|
+
// const keys = Object.keys(data);
|
15983
|
+
// if (keys[0] !== "ownership") {
|
15984
|
+
// getOrganisationsDetails();
|
15985
|
+
// }
|
15986
|
+
// }
|
15987
|
+
getNationalInvestmentDetails();
|
15988
|
+
getOrganisationsDetails();
|
15493
15989
|
getGovernmentDetails();
|
15990
|
+
getAllProjectData();
|
15991
|
+
getUserOrganization();
|
15494
15992
|
}, [data]);
|
15495
|
-
if (!data) {
|
15993
|
+
if (!data && allProjectData.length == 0) {
|
15496
15994
|
return React.createElement(Loading, null);
|
15497
15995
|
}
|
15498
|
-
console.log(
|
15499
|
-
var companyName = {};
|
15996
|
+
console.log("data", data);
|
15500
15997
|
if (data && Object.keys(data)[0] !== "ownership") {
|
15501
|
-
for (
|
15502
|
-
|
15503
|
-
|
15504
|
-
}
|
15998
|
+
// for (const company of data!?.company) {
|
15999
|
+
// companyName[company?.companyId] = company;
|
16000
|
+
// }
|
15505
16001
|
if (!data.proponentPercentage) {
|
15506
16002
|
data.proponentPercentage = [100];
|
15507
16003
|
}
|
15508
16004
|
}
|
15509
16005
|
var nextOne = function (val) {
|
16006
|
+
console.log("step 1 values", val);
|
16007
|
+
if (val.typeCreation == exports.InvestmentCreationType.EXISTING) {
|
16008
|
+
val.toCompanyId = investmentData.toCompanyId;
|
16009
|
+
}
|
15510
16010
|
setCurrent(current + 1);
|
15511
16011
|
setStepOneData(val);
|
16012
|
+
if (data === null || data === void 0 ? void 0 : data.programmeId)
|
16013
|
+
setSelectedProgramme(data.programmeId);
|
16014
|
+
if (prevInvestor && prevInvestor != val.toCompanyId && !(data === null || data === void 0 ? void 0 : data.programmeId)) {
|
16015
|
+
formTwo.resetFields();
|
16016
|
+
setCurrentPercTotal(0);
|
16017
|
+
setProjectData(undefined);
|
16018
|
+
}
|
15512
16019
|
};
|
15513
16020
|
var prevOne = function () {
|
15514
16021
|
setCurrent(current - 1);
|
16022
|
+
setPrevInvestor(stepOneData.toCompanyId);
|
16023
|
+
// formTwo.resetFields();
|
16024
|
+
// setCurrentPercTotal(0);
|
16025
|
+
// setProjectData(undefined);
|
15515
16026
|
};
|
15516
16027
|
var submitInvestment = function (val) { return __awaiter(void 0, void 0, void 0, function () {
|
15517
|
-
var payload, response,
|
16028
|
+
var payload, response, error_6;
|
15518
16029
|
return __generator(this, function (_a) {
|
15519
16030
|
switch (_a.label) {
|
15520
16031
|
case 0:
|
15521
16032
|
console.log(val);
|
15522
16033
|
console.log(stepOneData);
|
16034
|
+
console.log("OwnershipType", investmentOwnershipType);
|
15523
16035
|
setLoading(true);
|
15524
16036
|
payload = stepOneData;
|
15525
|
-
payload.programmeId = data.programmeId;
|
15526
16037
|
payload.amount = parseFloat(payload.amount);
|
15527
16038
|
if (payload.interestRate) {
|
15528
16039
|
payload.interestRate = parseFloat(payload.interestRate);
|
@@ -15530,15 +16041,27 @@ var InvestmentCreationComponent = function (props) {
|
|
15530
16041
|
if (payload.paymentPerMetric) {
|
15531
16042
|
payload.paymentPerMetric = parseFloat(payload.paymentPerMetric);
|
15532
16043
|
}
|
15533
|
-
payload.fromCompanyIds = data.companyId.map(function (e) { return Number(e); });
|
15534
|
-
payload.percentage = val.percentage;
|
15535
16044
|
payload.toCompanyId = Number(payload.toCompanyId);
|
15536
16045
|
_a.label = 1;
|
15537
16046
|
case 1:
|
15538
|
-
_a.trys.push([1,
|
16047
|
+
_a.trys.push([1, 6, 7, 8]);
|
16048
|
+
response = void 0;
|
16049
|
+
if (!(investmentOwnershipType == exports.InvestmentOwnershipType.PROJECT)) return [3 /*break*/, 3];
|
16050
|
+
if (typeCreation == exports.InvestmentCreationType.EXISTING) {
|
16051
|
+
payload.nationalInvestmentId = investmentData.requestId;
|
16052
|
+
}
|
16053
|
+
payload.programmeId = projectData === null || projectData === void 0 ? void 0 : projectData.programmeId;
|
16054
|
+
payload.fromCompanyIds = projectData === null || projectData === void 0 ? void 0 : projectData.companyId.map(function (e) { return Number(e); });
|
16055
|
+
payload.percentage = val.percentage;
|
15539
16056
|
return [4 /*yield*/, post("national/programme/addInvestment", payload)];
|
15540
16057
|
case 2:
|
15541
16058
|
response = _a.sent();
|
16059
|
+
return [3 /*break*/, 5];
|
16060
|
+
case 3: return [4 /*yield*/, post("national/organisation/addInvestment", payload)];
|
16061
|
+
case 4:
|
16062
|
+
response = _a.sent();
|
16063
|
+
_a.label = 5;
|
16064
|
+
case 5:
|
15542
16065
|
console.log("investment creation -> ", response);
|
15543
16066
|
if ((response === null || response === void 0 ? void 0 : response.statusText) === "SUCCESS") {
|
15544
16067
|
antd.message.open({
|
@@ -15548,22 +16071,24 @@ var InvestmentCreationComponent = function (props) {
|
|
15548
16071
|
style: { textAlign: "right", marginRight: 15, marginTop: 10 },
|
15549
16072
|
});
|
15550
16073
|
}
|
15551
|
-
|
15552
|
-
|
15553
|
-
|
15554
|
-
|
15555
|
-
|
16074
|
+
(data === null || data === void 0 ? void 0 : data.programmeId)
|
16075
|
+
? onNavigateToProgrammeView(data === null || data === void 0 ? void 0 : data.programmeId)
|
16076
|
+
: onNavigateToInvestmentManagementView();
|
16077
|
+
return [3 /*break*/, 8];
|
16078
|
+
case 6:
|
16079
|
+
error_6 = _a.sent();
|
16080
|
+
console.log("Error in investment creation - ", error_6);
|
15556
16081
|
antd.message.open({
|
15557
16082
|
type: "error",
|
15558
|
-
content:
|
16083
|
+
content: error_6 === null || error_6 === void 0 ? void 0 : error_6.message,
|
15559
16084
|
duration: 4,
|
15560
16085
|
style: { textAlign: "right", marginRight: 15, marginTop: 10 },
|
15561
16086
|
});
|
15562
|
-
return [3 /*break*/,
|
15563
|
-
case
|
16087
|
+
return [3 /*break*/, 8];
|
16088
|
+
case 7:
|
15564
16089
|
setLoading(false);
|
15565
16090
|
return [7 /*endfinally*/];
|
15566
|
-
case
|
16091
|
+
case 8: return [2 /*return*/];
|
15567
16092
|
}
|
15568
16093
|
});
|
15569
16094
|
}); };
|
@@ -15575,8 +16100,16 @@ var InvestmentCreationComponent = function (props) {
|
|
15575
16100
|
}
|
15576
16101
|
};
|
15577
16102
|
var onChangeTypeCreation = function (e) {
|
15578
|
-
console.log(
|
16103
|
+
console.log("radio checked", e.target.value);
|
15579
16104
|
setTypeCreation(e.target.value);
|
16105
|
+
formOne.resetFields();
|
16106
|
+
formTwo.resetFields();
|
16107
|
+
setCurrentPercTotal(0);
|
16108
|
+
setProjectData(undefined);
|
16109
|
+
};
|
16110
|
+
var onChangeInvestmentOwnershipType = function (e) {
|
16111
|
+
console.log("investment ownership type radio checked", e.target.value);
|
16112
|
+
setInvestmentOwnershipType(e.target.value);
|
15580
16113
|
};
|
15581
16114
|
return (React.createElement("div", { className: "add-programme-main-container" },
|
15582
16115
|
React.createElement("div", { className: "title-container" },
|
@@ -15601,242 +16134,263 @@ var InvestmentCreationComponent = function (props) {
|
|
15601
16134
|
] },
|
15602
16135
|
React.createElement(antd.Radio.Group, { size: "large", defaultValue: typeCreation }, Object.values(exports.InvestmentCreationType).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
15603
16136
|
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onChange: onChangeTypeCreation }, t("programme:" + k)))); }))))),
|
15604
|
-
React.createElement(
|
15605
|
-
React.createElement(antd.
|
15606
|
-
React.createElement(
|
15607
|
-
React.createElement(
|
15608
|
-
|
15609
|
-
|
15610
|
-
|
15611
|
-
|
15612
|
-
|
15613
|
-
|
15614
|
-
|
15615
|
-
|
15616
|
-
|
15617
|
-
|
15618
|
-
|
15619
|
-
|
15620
|
-
|
15621
|
-
|
15622
|
-
|
15623
|
-
return
|
15624
|
-
|
15625
|
-
|
15626
|
-
|
15627
|
-
|
15628
|
-
|
15629
|
-
|
15630
|
-
|
15631
|
-
|
15632
|
-
|
15633
|
-
|
15634
|
-
|
15635
|
-
|
15636
|
-
|
15637
|
-
|
15638
|
-
|
15639
|
-
|
15640
|
-
|
15641
|
-
|
15642
|
-
|
15643
|
-
|
15644
|
-
|
15645
|
-
|
15646
|
-
|
15647
|
-
|
15648
|
-
|
15649
|
-
|
15650
|
-
|
15651
|
-
|
15652
|
-
|
15653
|
-
|
15654
|
-
},
|
15655
|
-
|
15656
|
-
|
15657
|
-
|
15658
|
-
|
15659
|
-
|
15660
|
-
|
15661
|
-
|
15662
|
-
|
15663
|
-
|
15664
|
-
|
15665
|
-
|
15666
|
-
|
15667
|
-
|
15668
|
-
|
15669
|
-
|
15670
|
-
|
15671
|
-
|
15672
|
-
|
15673
|
-
|
15674
|
-
|
15675
|
-
|
15676
|
-
|
15677
|
-
|
15678
|
-
|
15679
|
-
|
15680
|
-
|
15681
|
-
|
15682
|
-
|
15683
|
-
|
15684
|
-
|
16137
|
+
typeCreation == exports.InvestmentCreationType.NEW && (React.createElement("div", null,
|
16138
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16139
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16140
|
+
React.createElement("div", { className: "details-part-one" },
|
16141
|
+
React.createElement(antd.Form.Item, { label: t("programme:investorName"), name: "toCompanyId", wrapperCol: { span: 24 }, className: "organisation", rules: [
|
16142
|
+
{
|
16143
|
+
required: true,
|
16144
|
+
message: "".concat(t("programme:investorName"), " ").concat(t("isRequired")),
|
16145
|
+
},
|
16146
|
+
] },
|
16147
|
+
React.createElement(antd.Select, { size: "large", loading: loadingList }, organisationsList.map(function (organisation) {
|
16148
|
+
if (data === null || data === void 0 ? void 0 : data.programmeId) {
|
16149
|
+
if (data.companyId
|
16150
|
+
.map(function (id) { return Number(id); })
|
16151
|
+
.includes(Number(organisation.companyId))) {
|
16152
|
+
return (React.createElement(antd.Select.Option, { key: organisation.companyId, value: organisation.companyId }, organisation.name));
|
16153
|
+
}
|
16154
|
+
}
|
16155
|
+
else {
|
16156
|
+
return (React.createElement(antd.Select.Option, { key: organisation.companyId, value: organisation.companyId }, organisation.name));
|
16157
|
+
}
|
16158
|
+
}))))),
|
16159
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16160
|
+
React.createElement("div", { className: "details-part-two" },
|
16161
|
+
React.createElement(antd.Form.Item, { label: t("programme:amountInvested"), name: "amount", rules: [
|
16162
|
+
{
|
16163
|
+
required: true,
|
16164
|
+
message: "",
|
16165
|
+
},
|
16166
|
+
{
|
16167
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16168
|
+
return __generator(this, function (_a) {
|
16169
|
+
if (String(value).trim() === "" ||
|
16170
|
+
String(value).trim() ===
|
16171
|
+
undefined ||
|
16172
|
+
value === null ||
|
16173
|
+
value === undefined) {
|
16174
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isRequired")));
|
16175
|
+
}
|
16176
|
+
else if (!isNaN(value) &&
|
16177
|
+
Number(value) > 0) {
|
16178
|
+
return [2 /*return*/, Promise.resolve()];
|
16179
|
+
}
|
16180
|
+
else {
|
16181
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isInvalid")));
|
16182
|
+
}
|
16183
|
+
});
|
16184
|
+
}); },
|
16185
|
+
},
|
16186
|
+
] },
|
16187
|
+
React.createElement(antd.Input, { size: "large" }))))),
|
16188
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16189
|
+
React.createElement(antd.Col, { xl: 24, md: 24 },
|
16190
|
+
React.createElement(antd.Form.Item, { label: t("programme:instrument"), name: "instrument", wrapperCol: { span: 24 }, className: "" },
|
16191
|
+
React.createElement(antd.Checkbox.Group, { options: instrumentOptions, defaultValue: instrumentOptions.map(function (e) { return e.value; }), onChange: onInstrumentChange })))),
|
16192
|
+
instrument &&
|
16193
|
+
instrument.indexOf(exports.Instrument.LOAN) >= 0 && (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16194
|
+
React.createElement(antd.Col, { xl: 8, md: 12 },
|
16195
|
+
React.createElement("div", { className: "details-part-two" },
|
16196
|
+
React.createElement(antd.Form.Item, { label: t("programme:interestRate"), name: "interestRate", rules: [
|
16197
|
+
{
|
16198
|
+
required: true,
|
16199
|
+
message: "",
|
16200
|
+
},
|
16201
|
+
{
|
16202
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16203
|
+
return __generator(this, function (_a) {
|
16204
|
+
if (String(value).trim() === "" ||
|
16205
|
+
String(value).trim() ===
|
16206
|
+
undefined ||
|
16207
|
+
value === null ||
|
16208
|
+
value === undefined) {
|
16209
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isRequired")));
|
16210
|
+
}
|
16211
|
+
else if (!isNaN(value)) {
|
16212
|
+
return [2 /*return*/, Promise.resolve()];
|
16213
|
+
}
|
16214
|
+
else {
|
16215
|
+
throw new Error("".concat(t("programme:interestRate"), " ").concat(t("isInvalid")));
|
16216
|
+
}
|
16217
|
+
});
|
16218
|
+
}); },
|
16219
|
+
},
|
16220
|
+
] },
|
16221
|
+
React.createElement(antd.Input, { size: "large" })))))),
|
16222
|
+
instrument &&
|
16223
|
+
instrument.indexOf(exports.Instrument.RESULT_BASED) >=
|
16224
|
+
0 && (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16225
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16226
|
+
React.createElement("div", { className: "details-part-two" },
|
16227
|
+
React.createElement(antd.Form.Item, { label: t("programme:resultMetric"), name: "resultMetric", rules: [
|
16228
|
+
{
|
16229
|
+
required: true,
|
16230
|
+
message: "",
|
16231
|
+
},
|
16232
|
+
{
|
16233
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16234
|
+
return __generator(this, function (_a) {
|
16235
|
+
if (String(value).trim() === "" ||
|
16236
|
+
String(value).trim() ===
|
16237
|
+
undefined ||
|
16238
|
+
value === null ||
|
16239
|
+
value === undefined) {
|
16240
|
+
throw new Error("".concat(t("programme:resultMetric"), " ").concat(t("isRequired")));
|
16241
|
+
}
|
16242
|
+
return [2 /*return*/];
|
16243
|
+
});
|
16244
|
+
}); },
|
16245
|
+
},
|
16246
|
+
] },
|
16247
|
+
React.createElement(antd.Input, { size: "large" })))),
|
16248
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16249
|
+
React.createElement("div", { className: "details-part-two" },
|
16250
|
+
React.createElement(antd.Form.Item, { label: t("programme:paymentPerMetric"), name: "paymentPerMetric", rules: [
|
16251
|
+
{
|
16252
|
+
required: true,
|
16253
|
+
message: "",
|
16254
|
+
},
|
16255
|
+
{
|
16256
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16257
|
+
return __generator(this, function (_a) {
|
16258
|
+
if (String(value).trim() === "" ||
|
16259
|
+
String(value).trim() ===
|
16260
|
+
undefined ||
|
16261
|
+
value === null ||
|
16262
|
+
value === undefined) {
|
16263
|
+
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isRequired")));
|
16264
|
+
}
|
16265
|
+
else if (!isNaN(value)) {
|
16266
|
+
return [2 /*return*/, Promise.resolve()];
|
16267
|
+
}
|
16268
|
+
else {
|
16269
|
+
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isInvalid")));
|
16270
|
+
}
|
16271
|
+
});
|
16272
|
+
}); },
|
16273
|
+
},
|
16274
|
+
] },
|
16275
|
+
React.createElement(antd.Input, { size: "large" })))))),
|
16276
|
+
instrument &&
|
16277
|
+
instrument.indexOf(exports.Instrument.INKIND) >= 0 && (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16278
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16279
|
+
React.createElement("div", { className: "details-part-two" },
|
16280
|
+
React.createElement(antd.Form.Item, { label: t("programme:description"), name: "description", rules: [
|
16281
|
+
{
|
16282
|
+
required: false,
|
16283
|
+
message: "",
|
16284
|
+
},
|
16285
|
+
] },
|
16286
|
+
React.createElement(antd.Input, { size: "large" })))))),
|
16287
|
+
instrument &&
|
16288
|
+
instrument.indexOf(exports.Instrument.OTHER) >= 0 && (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16289
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16290
|
+
React.createElement("div", { className: "details-part-two" },
|
16291
|
+
React.createElement(antd.Form.Item, { label: t("programme:comments"), name: "comments", rules: [
|
16292
|
+
{
|
16293
|
+
required: true,
|
16294
|
+
message: "",
|
16295
|
+
},
|
16296
|
+
{
|
16297
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16298
|
+
return __generator(this, function (_a) {
|
16299
|
+
if (String(value).trim() === "" ||
|
16300
|
+
String(value).trim() ===
|
16301
|
+
undefined ||
|
16302
|
+
value === null ||
|
16303
|
+
value === undefined) {
|
16304
|
+
throw new Error("".concat(t("programme:comments"), " ").concat(t("isRequired")));
|
16305
|
+
}
|
16306
|
+
return [2 /*return*/];
|
16307
|
+
});
|
16308
|
+
}); },
|
16309
|
+
},
|
16310
|
+
] },
|
16311
|
+
React.createElement(antd.Input, { size: "large" })))))),
|
16312
|
+
React.createElement(antd.Row, { className: "row", gutter: [4, 4] },
|
16313
|
+
React.createElement(antd.Col, { xl: 8, md: 12 },
|
16314
|
+
React.createElement(antd.Form.Item, { label: t("programme:type"), wrapperCol: { span: 13 }, className: "role-group", name: "type", rules: [
|
15685
16315
|
{
|
15686
|
-
|
15687
|
-
return __generator(this, function (_a) {
|
15688
|
-
if (String(value).trim() === "" ||
|
15689
|
-
String(value).trim() ===
|
15690
|
-
undefined ||
|
15691
|
-
value === null ||
|
15692
|
-
value === undefined) {
|
15693
|
-
throw new Error("".concat(t("programme:resultMetric"), " ").concat(t("isRequired")));
|
15694
|
-
}
|
15695
|
-
return [2 /*return*/];
|
15696
|
-
});
|
15697
|
-
}); },
|
16316
|
+
required: false,
|
15698
16317
|
},
|
15699
16318
|
] },
|
15700
|
-
React.createElement(antd.
|
15701
|
-
|
15702
|
-
|
15703
|
-
|
15704
|
-
|
15705
|
-
|
15706
|
-
message: "",
|
15707
|
-
},
|
15708
|
-
{
|
15709
|
-
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
15710
|
-
return __generator(this, function (_a) {
|
15711
|
-
if (String(value).trim() === "" ||
|
15712
|
-
String(value).trim() ===
|
15713
|
-
undefined ||
|
15714
|
-
value === null ||
|
15715
|
-
value === undefined) {
|
15716
|
-
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isRequired")));
|
15717
|
-
}
|
15718
|
-
else if (!isNaN(value)) {
|
15719
|
-
return [2 /*return*/, Promise.resolve()];
|
15720
|
-
}
|
15721
|
-
else {
|
15722
|
-
throw new Error("".concat(t("programme:paymentPerMetric"), " ").concat(t("isInvalid")));
|
15723
|
-
}
|
15724
|
-
});
|
15725
|
-
}); },
|
15726
|
-
},
|
15727
|
-
] },
|
15728
|
-
React.createElement(antd.Input, { size: "large" })))))),
|
15729
|
-
instrument &&
|
15730
|
-
instrument.indexOf(exports.Instrument.INKIND) >= 0 && (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
15731
|
-
React.createElement(antd.Col, { xl: 12, md: 24 },
|
15732
|
-
React.createElement("div", { className: "details-part-two" },
|
15733
|
-
React.createElement(antd.Form.Item, { label: t("programme:description"), name: "description", rules: [
|
16319
|
+
React.createElement(antd.Radio.Group, { size: "large" }, Object.values(exports.InvestmentType).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16320
|
+
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16321
|
+
return deselectOnClick(e, "type");
|
16322
|
+
} }, t("programme:" + k)))); })))),
|
16323
|
+
React.createElement(antd.Col, { xl: 8, md: 12 },
|
16324
|
+
React.createElement(antd.Form.Item, { label: t("programme:level"), wrapperCol: { span: 13 }, className: "role-group", name: "level", rules: [
|
15734
16325
|
{
|
15735
16326
|
required: false,
|
15736
|
-
message: "",
|
15737
16327
|
},
|
15738
16328
|
] },
|
15739
|
-
React.createElement(antd.
|
15740
|
-
|
15741
|
-
|
15742
|
-
|
15743
|
-
React.createElement(
|
15744
|
-
React.createElement(antd.Form.Item, { label: t("programme:
|
15745
|
-
{
|
15746
|
-
required: true,
|
15747
|
-
message: "",
|
15748
|
-
},
|
16329
|
+
React.createElement(antd.Radio.Group, { size: "large" }, Object.values(exports.InvestmentLevel).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16330
|
+
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16331
|
+
return deselectOnClick(e, "level");
|
16332
|
+
} }, t("programme:" + k)))); })))),
|
16333
|
+
React.createElement(antd.Col, { xl: 8, md: 12 },
|
16334
|
+
React.createElement(antd.Form.Item, { label: t("programme:stream"), wrapperCol: { span: 13 }, className: "role-group", name: "stream", rules: [
|
15749
16335
|
{
|
15750
|
-
|
15751
|
-
return __generator(this, function (_a) {
|
15752
|
-
if (String(value).trim() === "" ||
|
15753
|
-
String(value).trim() ===
|
15754
|
-
undefined ||
|
15755
|
-
value === null ||
|
15756
|
-
value === undefined) {
|
15757
|
-
throw new Error("".concat(t("programme:comments"), " ").concat(t("isRequired")));
|
15758
|
-
}
|
15759
|
-
return [2 /*return*/];
|
15760
|
-
});
|
15761
|
-
}); },
|
16336
|
+
required: false,
|
15762
16337
|
},
|
15763
16338
|
] },
|
15764
|
-
React.createElement(antd.
|
15765
|
-
|
15766
|
-
|
15767
|
-
|
15768
|
-
|
15769
|
-
|
15770
|
-
|
15771
|
-
|
15772
|
-
|
15773
|
-
|
15774
|
-
|
15775
|
-
|
15776
|
-
|
15777
|
-
React.createElement(antd.Form.Item, { label: t("programme:level"), wrapperCol: { span: 13 }, className: "role-group", name: "level", rules: [
|
15778
|
-
{
|
15779
|
-
required: false,
|
15780
|
-
},
|
15781
|
-
] },
|
15782
|
-
React.createElement(antd.Radio.Group, { size: "large" }, Object.values(exports.InvestmentLevel).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
15783
|
-
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
15784
|
-
return deselectOnClick(e, "level");
|
15785
|
-
} }, t("programme:" + k)))); })))),
|
15786
|
-
React.createElement(antd.Col, { xl: 8, md: 12 },
|
15787
|
-
React.createElement(antd.Form.Item, { label: t("programme:stream"), wrapperCol: { span: 13 }, className: "role-group", name: "stream", rules: [
|
15788
|
-
{
|
15789
|
-
required: false,
|
15790
|
-
},
|
15791
|
-
] },
|
15792
|
-
React.createElement(antd.Radio.Group, { size: "large" }, Object.values(exports.InvestmentStream).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
15793
|
-
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
15794
|
-
return deselectOnClick(e, "stream");
|
15795
|
-
} }, t("programme:" + k)))); }))))),
|
15796
|
-
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
15797
|
-
React.createElement(antd.Col, { xl: 12, md: 24 },
|
15798
|
-
React.createElement(antd.Form.Item, { label: t("programme:esgType"), name: "esgClassification" },
|
15799
|
-
React.createElement(antd.Select, { size: "large" }, Object.values(exports.ESGType).map(function (esg) { return (React.createElement(antd.Select.Option, { value: esg }, esg)); }))))),
|
15800
|
-
React.createElement(antd.Form.Item, null,
|
15801
|
-
React.createElement("div", { className: "steps-actions" },
|
15802
|
-
React.createElement(antd.Button, { type: "primary", htmlType: "submit", loading: loading, onSubmit: nextOne }, t("programme:next")))))))),
|
15803
|
-
},
|
15804
|
-
{
|
15805
|
-
title: (React.createElement("div", { className: "step-title-container" },
|
15806
|
-
React.createElement("div", { className: "step-count" }, "02"),
|
15807
|
-
React.createElement("div", { className: "title" }, t("programme:ownership")))),
|
15808
|
-
description: current === 1 && (React.createElement("div", null,
|
15809
|
-
React.createElement("div", { className: "programme-sought-form-container ownership-container" }, Object.keys(data).length > 0 &&
|
15810
|
-
React.createElement("div", { className: "programme-sought-form" },
|
15811
|
-
React.createElement(antd.Form, { labelCol: { span: 20 }, wrapperCol: { span: 24 }, form: formTwo, name: "investment-sought", className: "investment-sought-form", layout: "vertical", requiredMark: true, onChange: onPercentageChange, onFinish: submitInvestment }, data === null || data === void 0 ? void 0 :
|
15812
|
-
data.companyId.map(function (companyId, index) {
|
15813
|
-
return (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
15814
|
-
React.createElement(antd.Col, { xl: 8, md: 15 },
|
15815
|
-
React.createElement("div", { className: "label" },
|
15816
|
-
companyName[companyId].name,
|
15817
|
-
React.createElement("span", { className: "required-mark" }, "*"))),
|
15818
|
-
React.createElement(antd.Col, { xl: 8, md: 9 },
|
15819
|
-
React.createElement(antd.Form.Item, { className: "inline", name: ["percentage", index], initialValue: 0, rules: [
|
16339
|
+
React.createElement(antd.Radio.Group, { size: "large" }, Object.values(exports.InvestmentStream).map(function (k, index) { return (React.createElement("div", { className: "condition-radio-container" },
|
16340
|
+
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onClick: function (e) {
|
16341
|
+
return deselectOnClick(e, "stream");
|
16342
|
+
} }, t("programme:" + k)))); }))))),
|
16343
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16344
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16345
|
+
React.createElement(antd.Form.Item, { label: t("programme:esgType"), name: "esgClassification" },
|
16346
|
+
React.createElement(antd.Select, { size: "large" }, Object.values(exports.ESGType).map(function (esg) { return (React.createElement(antd.Select.Option, { value: esg }, esg)); }))))))),
|
16347
|
+
typeCreation == exports.InvestmentCreationType.EXISTING && (React.createElement("div", null,
|
16348
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16349
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16350
|
+
React.createElement("div", { className: "details-part-one" },
|
16351
|
+
React.createElement(antd.Form.Item, { label: t("programme:existingInvestmentSource"), name: "existinngInvestmentId", wrapperCol: { span: 24 }, rules: [
|
15820
16352
|
{
|
15821
|
-
|
15822
|
-
message: "
|
16353
|
+
required: true,
|
16354
|
+
message: "".concat(t("programme:existingInvestmentSource"), " ").concat(t("isRequired")),
|
15823
16355
|
},
|
16356
|
+
] },
|
16357
|
+
React.createElement(antd.Select, { size: "large", loading: loadingInvestment, onChange: setSelectedInvestment }, nationalInvestmentList.map(function (investment) { return (React.createElement(antd.Select.Option, { key: investment.requestId, value: investment.requestId }, investment.investmentName)); })))))),
|
16358
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16359
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16360
|
+
React.createElement("div", { className: "details-part-two" },
|
16361
|
+
React.createElement(antd.Form.Item, { label: t("programme:amountInvested"), name: "amount", rules: [
|
15824
16362
|
{
|
15825
16363
|
required: true,
|
15826
|
-
message: "
|
16364
|
+
message: "",
|
16365
|
+
},
|
16366
|
+
{
|
16367
|
+
validator: function (rule, value) { return __awaiter(void 0, void 0, void 0, function () {
|
16368
|
+
return __generator(this, function (_a) {
|
16369
|
+
if (String(value).trim() === "" ||
|
16370
|
+
String(value).trim() ===
|
16371
|
+
undefined ||
|
16372
|
+
value === null ||
|
16373
|
+
value === undefined) {
|
16374
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isRequired")));
|
16375
|
+
}
|
16376
|
+
else if (!isNaN(value) &&
|
16377
|
+
Number(value) > 0) {
|
16378
|
+
return [2 /*return*/, Promise.resolve()];
|
16379
|
+
}
|
16380
|
+
else {
|
16381
|
+
throw new Error("".concat(t("programme:amountInvested"), " ").concat(t("isInvalid")));
|
16382
|
+
}
|
16383
|
+
});
|
16384
|
+
}); },
|
15827
16385
|
},
|
15828
16386
|
function (_a) {
|
15829
16387
|
var getFieldValue = _a.getFieldValue;
|
15830
16388
|
return ({
|
15831
16389
|
validator: function (rule, v) {
|
15832
|
-
if (getFieldValue(
|
15833
|
-
|
15834
|
-
|
15835
|
-
|
15836
|
-
parseFloat(getFieldValue([
|
15837
|
-
"percentage",
|
15838
|
-
index,
|
15839
|
-
])) > data.proponentPercentage[index]) {
|
16390
|
+
if (getFieldValue("amount") &&
|
16391
|
+
investmentData &&
|
16392
|
+
investmentData.amount <
|
16393
|
+
parseFloat(getFieldValue("amount"))) {
|
15840
16394
|
// eslint-disable-next-line prefer-promise-reject-errors
|
15841
16395
|
return Promise.reject("Amount > Available");
|
15842
16396
|
}
|
@@ -15845,30 +16399,178 @@ var InvestmentCreationComponent = function (props) {
|
|
15845
16399
|
});
|
15846
16400
|
},
|
15847
16401
|
] },
|
15848
|
-
React.createElement(antd.
|
15849
|
-
|
15850
|
-
|
16402
|
+
React.createElement(antd.Input, { size: "large" })))),
|
16403
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16404
|
+
React.createElement("div", { className: "details-part-two" },
|
16405
|
+
React.createElement(antd.Form.Item, { label: " ", name: "sourceAmount" },
|
16406
|
+
React.createElement("div", null,
|
16407
|
+
"/",
|
16408
|
+
React.createElement(antd.InputNumber, { size: "large", width: "100%", formatter: function (value) {
|
16409
|
+
return "$".concat(addCommSep(value));
|
16410
|
+
}, disabled: true, value: investmentData
|
16411
|
+
? investmentData.amount
|
16412
|
+
: 0 })))))))),
|
16413
|
+
React.createElement(antd.Form.Item, null,
|
16414
|
+
React.createElement("div", { className: "steps-actions" },
|
16415
|
+
React.createElement(antd.Button, { type: "primary", htmlType: "submit", loading: loading, onSubmit: nextOne }, t("programme:next")))))))),
|
16416
|
+
},
|
16417
|
+
{
|
16418
|
+
title: (React.createElement("div", { className: "step-title-container" },
|
16419
|
+
React.createElement("div", { className: "step-count" }, "02"),
|
16420
|
+
React.createElement("div", { className: "title" }, t("programme:ownership")))),
|
16421
|
+
description: current === 1 && (React.createElement("div", null,
|
16422
|
+
React.createElement("div", { className: "investment-sought-form-container" },
|
16423
|
+
React.createElement("div", { className: "investment-sought-form" },
|
16424
|
+
React.createElement(antd.Form, { labelCol: { span: 20 }, wrapperCol: { span: 24 }, name: "investment-sought", className: "investment-sought-form", layout: "vertical", requiredMark: true },
|
16425
|
+
React.createElement(antd.Row, { className: "row", gutter: [4, 4] },
|
16426
|
+
React.createElement(antd.Col, { xl: 8, md: 12 },
|
16427
|
+
React.createElement(antd.Form.Item, { label: t("programme:typeCreation"), wrapperCol: { span: 13 }, className: "role-group", name: "investmentOwnershipType", rules: [
|
16428
|
+
{
|
16429
|
+
required: false,
|
16430
|
+
},
|
16431
|
+
] },
|
16432
|
+
React.createElement(antd.Radio.Group, { size: "large", defaultValue: typeCreation ==
|
16433
|
+
exports.InvestmentCreationType.EXISTING
|
16434
|
+
? exports.InvestmentOwnershipType.PROJECT
|
16435
|
+
: investmentOwnershipType }, Object.values(exports.InvestmentOwnershipType).map(function (k, index) {
|
16436
|
+
if (!(typeCreation ==
|
16437
|
+
exports.InvestmentCreationType.EXISTING &&
|
16438
|
+
k == exports.InvestmentOwnershipType.NATIONAL) &&
|
16439
|
+
!(k ==
|
16440
|
+
exports.InvestmentOwnershipType.NATIONAL &&
|
16441
|
+
(data === null || data === void 0 ? void 0 : data.programmeId))) {
|
16442
|
+
return (React.createElement("div", { className: "condition-radio-container" },
|
16443
|
+
React.createElement(antd.Tooltip, { title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16444
|
+
exports.CompanyRole.PROGRAMME_DEVELOPER &&
|
16445
|
+
stepOneData.toCompanyId !=
|
16446
|
+
userInfoState.companyId &&
|
16447
|
+
k ==
|
16448
|
+
exports.InvestmentOwnershipType.NATIONAL
|
16449
|
+
? "This action is unauthorized due to the selected investor name."
|
16450
|
+
: "", color: TooltipColor, key: TooltipColor },
|
16451
|
+
React.createElement(antd.Radio.Button, { className: "condition-radio", value: k, onChange: onChangeInvestmentOwnershipType, disabled: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16452
|
+
exports.CompanyRole.PROGRAMME_DEVELOPER &&
|
16453
|
+
stepOneData.toCompanyId !=
|
16454
|
+
userInfoState.companyId &&
|
16455
|
+
k ==
|
16456
|
+
exports.InvestmentOwnershipType.NATIONAL }, t("programme:" + k)))));
|
16457
|
+
}
|
16458
|
+
})))))))),
|
16459
|
+
React.createElement("div", { className: "programme-sought-form-container ownership-container" },
|
16460
|
+
React.createElement("div", { className: "programme-sought-form" },
|
16461
|
+
React.createElement(antd.Form, { labelCol: { span: 20 }, wrapperCol: { span: 24 }, form: formTwo, name: "investment-sought", className: "investment-sought-form", layout: "vertical", requiredMark: true, onChange: onPercentageChange, onFinish: submitInvestment },
|
16462
|
+
allProjectData.length > 0 &&
|
16463
|
+
investmentOwnershipType ==
|
16464
|
+
exports.InvestmentOwnershipType.PROJECT && (React.createElement("div", null,
|
16465
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16466
|
+
React.createElement(antd.Col, { xl: 12, md: 24 },
|
16467
|
+
React.createElement("div", { className: "details-part-one" },
|
16468
|
+
React.createElement(antd.Form.Item, { label: t("programme:title"), name: "projectId", wrapperCol: { span: 24 }, initialValue: (data === null || data === void 0 ? void 0 : data.programmeId) != undefined
|
16469
|
+
? allProjectData[0].programmeId
|
16470
|
+
: null, rules: [
|
16471
|
+
{
|
16472
|
+
required: true,
|
16473
|
+
message: "".concat(t("programme:title"), " ").concat(t("isRequired")),
|
16474
|
+
},
|
16475
|
+
] },
|
16476
|
+
React.createElement(antd.Select, { size: "large", loading: loadingProgData,
|
16477
|
+
// defaultValue={
|
16478
|
+
// allProjectData.length == 1
|
16479
|
+
// ? allProjectData[0].programmeId
|
16480
|
+
// : null
|
16481
|
+
// }
|
16482
|
+
disabled: allProjectData.length == 1 &&
|
16483
|
+
(data === null || data === void 0 ? void 0 : data.programmeId) != undefined, onChange: setSelectedProgramme }, allProjectData.map(function (project) {
|
16484
|
+
if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ==
|
16485
|
+
exports.CompanyRole.PROGRAMME_DEVELOPER &&
|
16486
|
+
Number(stepOneData.toCompanyId) !=
|
16487
|
+
userInfoState.companyId) {
|
16488
|
+
if (project.companyId
|
16489
|
+
.map(function (id) { return Number(id); })
|
16490
|
+
.includes(userInfoState.companyId)) {
|
16491
|
+
return (React.createElement(antd.Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16492
|
+
}
|
16493
|
+
}
|
16494
|
+
else if ((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) ===
|
16495
|
+
exports.CompanyRole.MINISTRY) {
|
16496
|
+
if (ministrySectoralScope.includes(project.sectoralScope)) {
|
16497
|
+
return (React.createElement(antd.Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16498
|
+
}
|
16499
|
+
}
|
16500
|
+
else {
|
16501
|
+
return (React.createElement(antd.Select.Option, { key: project.programmeId, value: project.programmeId }, project.title));
|
16502
|
+
}
|
16503
|
+
})))))), projectData === null || projectData === void 0 ? void 0 :
|
16504
|
+
projectData.companyId.map(function (companyId, index) {
|
16505
|
+
if (formTwo.getFieldValue("percentage") &&
|
16506
|
+
formTwo.getFieldValue("percentage")[index] &&
|
16507
|
+
companyId == stepOneData.toCompanyId) {
|
16508
|
+
formTwo.getFieldValue("percentage")[index] = 0;
|
16509
|
+
}
|
16510
|
+
return (React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16511
|
+
React.createElement(antd.Col, { xl: 8, md: 15 },
|
16512
|
+
React.createElement("div", { className: "label" },
|
16513
|
+
companyNames[Number(companyId)],
|
16514
|
+
React.createElement("span", { className: "required-mark" }, "*"))),
|
16515
|
+
React.createElement(antd.Col, { xl: 8, md: 9 },
|
16516
|
+
React.createElement(antd.Form.Item, { className: "inline", name: ["percentage", index], initialValue: 0, rules: [
|
16517
|
+
{
|
16518
|
+
pattern: new RegExp(/^[+]?([.]\d+|\d+[.]?\d*)$/g),
|
16519
|
+
message: "Percentage Should be a positive number",
|
16520
|
+
},
|
16521
|
+
{
|
16522
|
+
required: true,
|
16523
|
+
message: "Required field",
|
16524
|
+
},
|
16525
|
+
function (_a) {
|
16526
|
+
var getFieldValue = _a.getFieldValue;
|
16527
|
+
return ({
|
16528
|
+
validator: function (rule, v) {
|
16529
|
+
if (getFieldValue([
|
16530
|
+
"percentage",
|
16531
|
+
index,
|
16532
|
+
]) &&
|
16533
|
+
parseFloat(getFieldValue([
|
16534
|
+
"percentage",
|
16535
|
+
index,
|
16536
|
+
])) >
|
16537
|
+
projectData
|
16538
|
+
.proponentPercentage[index]) {
|
16539
|
+
// eslint-disable-next-line prefer-promise-reject-errors
|
16540
|
+
return Promise.reject("Amount > Available");
|
16541
|
+
}
|
16542
|
+
return Promise.resolve();
|
16543
|
+
},
|
16544
|
+
});
|
16545
|
+
},
|
16546
|
+
] },
|
16547
|
+
React.createElement(antd.InputNumber, { placeholder: "", controls: false, disabled: govData.companyId ==
|
16548
|
+
companyId ||
|
16549
|
+
companyId ==
|
16550
|
+
stepOneData.toCompanyId, value: 0,
|
16551
|
+
// disabled={userInfoState?.companyId === Number(companyId)}
|
16552
|
+
onKeyPress: function (event) {
|
16553
|
+
if (!/[0-9\.]/.test(event.key)) {
|
16554
|
+
event.preventDefault();
|
16555
|
+
}
|
16556
|
+
} })),
|
16557
|
+
React.createElement("div", { className: "inline separator" }, "/"),
|
16558
|
+
React.createElement(antd.Form.Item, { className: "inline" },
|
16559
|
+
React.createElement(antd.InputNumber, { placeholder: String(projectData === null || projectData === void 0 ? void 0 : projectData.proponentPercentage[index]), disabled: true })))));
|
16560
|
+
}),
|
16561
|
+
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
16562
|
+
React.createElement(antd.Col, { xl: 8, md: 15 },
|
16563
|
+
React.createElement("div", { className: "label" }, t("programme:total"))),
|
16564
|
+
React.createElement(antd.Col, { xl: 8, md: 9 },
|
16565
|
+
React.createElement(antd.Form.Item, { className: "inline", name: ["total"] },
|
16566
|
+
React.createElement(antd.InputNumber, { placeholder: currentPercTotal + "", controls: false, disabled: true, onKeyPress: function (event) {
|
15851
16567
|
if (!/[0-9\.]/.test(event.key)) {
|
15852
16568
|
event.preventDefault();
|
15853
16569
|
}
|
15854
16570
|
} })),
|
15855
16571
|
React.createElement("div", { className: "inline separator" }, "/"),
|
15856
16572
|
React.createElement(antd.Form.Item, { className: "inline" },
|
15857
|
-
React.createElement(antd.InputNumber, {
|
15858
|
-
}),
|
15859
|
-
React.createElement(antd.Row, { className: "row", gutter: [16, 16] },
|
15860
|
-
React.createElement(antd.Col, { xl: 8, md: 15 },
|
15861
|
-
React.createElement("div", { className: "label" }, t("programme:total"))),
|
15862
|
-
React.createElement(antd.Col, { xl: 8, md: 9 },
|
15863
|
-
React.createElement(antd.Form.Item, { className: "inline", name: ["total"] },
|
15864
|
-
React.createElement(antd.InputNumber, { placeholder: currentPercTotal + "", controls: false, disabled: true, onKeyPress: function (event) {
|
15865
|
-
if (!/[0-9\.]/.test(event.key)) {
|
15866
|
-
event.preventDefault();
|
15867
|
-
}
|
15868
|
-
} })),
|
15869
|
-
React.createElement("div", { className: "inline separator" }, "/"),
|
15870
|
-
React.createElement(antd.Form.Item, { className: "inline" },
|
15871
|
-
React.createElement(antd.InputNumber, { disabled: true, placeholder: "100" })))),
|
16573
|
+
React.createElement(antd.InputNumber, { disabled: true, placeholder: "100" })))))),
|
15872
16574
|
React.createElement(antd.Form.Item, null,
|
15873
16575
|
React.createElement("div", { className: "steps-actions" },
|
15874
16576
|
React.createElement(antd.Button, { type: "primary", htmlType: "submit", loading: loading, onSubmit: submitInvestment }, t("programme:submit")),
|
@@ -15983,7 +16685,7 @@ var InvestmentActionModel = function (props) {
|
|
15983
16685
|
};
|
15984
16686
|
|
15985
16687
|
var InvestmentManagementComponent = function (props) {
|
15986
|
-
var translator = props.translator,
|
16688
|
+
var translator = props.translator, onNavigateToProgrammeView = props.onNavigateToProgrammeView, onClickAddOwnership = props.onClickAddOwnership, enableAddOwnership = props.enableAddOwnership;
|
15987
16689
|
var t = translator.t;
|
15988
16690
|
var statusOptions = Object.keys(exports.InvestmentStatus).map(function (k, index) { return ({
|
15989
16691
|
label: addSpaces(Object.values(exports.InvestmentStatus)[index]),
|
@@ -16321,7 +17023,10 @@ var InvestmentManagementComponent = function (props) {
|
|
16321
17023
|
sorter: true,
|
16322
17024
|
align: "left",
|
16323
17025
|
render: function (item) {
|
16324
|
-
|
17026
|
+
if (item) {
|
17027
|
+
return React.createElement("span", { className: "clickable" }, item);
|
17028
|
+
}
|
17029
|
+
return React.createElement("span", null, "-");
|
16325
17030
|
},
|
16326
17031
|
onCell: function (record, rowIndex) {
|
16327
17032
|
return {
|
@@ -16379,6 +17084,12 @@ var InvestmentManagementComponent = function (props) {
|
|
16379
17084
|
key: "programmeSector",
|
16380
17085
|
sorter: true,
|
16381
17086
|
align: "left",
|
17087
|
+
render: function (item) {
|
17088
|
+
if (item) {
|
17089
|
+
return React.createElement("span", null, item);
|
17090
|
+
}
|
17091
|
+
return React.createElement("span", null, "-");
|
17092
|
+
},
|
16382
17093
|
},
|
16383
17094
|
{
|
16384
17095
|
title: t("programme:investor"),
|
@@ -16462,7 +17173,11 @@ var InvestmentManagementComponent = function (props) {
|
|
16462
17173
|
React.createElement("div", { className: "title-bar" },
|
16463
17174
|
React.createElement("div", { className: "body-title" }, t("programme:investmentTitle")),
|
16464
17175
|
React.createElement("div", { className: "body-sub-title" }, t("programme:investmentDesc"))),
|
16465
|
-
React.createElement("div", { className: "actions" }, enableAddOwnership &&
|
17176
|
+
React.createElement("div", { className: "actions" }, enableAddOwnership &&
|
17177
|
+
((userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == exports.CompanyRole.MINISTRY ||
|
17178
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == exports.CompanyRole.GOVERNMENT ||
|
17179
|
+
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) == exports.CompanyRole.PROGRAMME_DEVELOPER) &&
|
17180
|
+
userInfoState.userRole != exports.Role.ViewOnly && (React.createElement("div", { className: "action-bar" },
|
16466
17181
|
React.createElement(antd.Button, { type: "primary", size: "large", block: true, icon: React.createElement(icons.PlusOutlined, null), onClick: onClickAddOwnership }, t("programme:addOwnership")))))),
|
16467
17182
|
React.createElement("div", { className: "content-card" },
|
16468
17183
|
React.createElement(antd.Row, null,
|
@@ -16503,7 +17218,7 @@ var InvestmentManagementComponent = function (props) {
|
|
16503
17218
|
return handleTableChange(val, sorter);
|
16504
17219
|
}, locale: {
|
16505
17220
|
emptyText: (React.createElement(antd.Empty, { image: antd.Empty.PRESENTED_IMAGE_SIMPLE, description: tableData.length === 0
|
16506
|
-
? t("
|
17221
|
+
? t("programme:noInvestmentData")
|
16507
17222
|
: null })),
|
16508
17223
|
} }))))),
|
16509
17224
|
popupInfo && selectedReq && (React.createElement(InvestmentActionModel, { investment: selectedReq, onCancel: function () {
|
@@ -16516,7 +17231,7 @@ var css_248z$i = ".steps-actions {\n display: flex;\n flex-direction: row-reve
|
|
16516
17231
|
styleInject(css_248z$i);
|
16517
17232
|
|
16518
17233
|
var SupportCreationComponent = function (props) {
|
16519
|
-
var t = props.t,
|
17234
|
+
var t = props.t, useLocation = props.useLocation; props.onNavigateToProgrammeManagementView; props.onNavigateToProgrammeView;
|
16520
17235
|
useLocation().state;
|
16521
17236
|
var _a = React.useState(); _a[0]; _a[1];
|
16522
17237
|
var formOne = antd.Form.useForm()[0];
|
@@ -16529,6 +17244,7 @@ var SupportCreationComponent = function (props) {
|
|
16529
17244
|
var _f = React.useState([]), organisationsList = _f[0], setOrganisationList = _f[1];
|
16530
17245
|
var _g = React.useState([]), instrument = _g[0], setInstrument = _g[1];
|
16531
17246
|
var _h = React.useState(); _h[0]; var setStepOneData = _h[1];
|
17247
|
+
var userInfoState = useUserContext().userInfoState;
|
16532
17248
|
var instrumentOptions = Object.keys(exports.Instrument).map(function (k, index) { return ({
|
16533
17249
|
label: addSpaces(Object.values(exports.Instrument)[index]),
|
16534
17250
|
value: Object.values(exports.Instrument)[index],
|
@@ -16871,7 +17587,7 @@ var SupportCreationComponent = function (props) {
|
|
16871
17587
|
};
|
16872
17588
|
|
16873
17589
|
var SupportManagementComponent = function (props) {
|
16874
|
-
var translator = props.translator
|
17590
|
+
var translator = props.translator; props.onNavigateToProgrammeView; var enableAddSupport = props.enableAddSupport, onClickAddSupport = props.onClickAddSupport;
|
16875
17591
|
var t = translator.t;
|
16876
17592
|
var statusOptions = Object.keys(exports.InvestmentStatus).map(function (k, index) { return ({
|
16877
17593
|
label: addSpaces(Object.values(exports.InvestmentStatus)[index]),
|
@@ -17373,7 +18089,7 @@ var css_248z$h = ".ndc-management .ant-checkbox-checked .ant-checkbox-input[valu
|
|
17373
18089
|
styleInject(css_248z$h);
|
17374
18090
|
|
17375
18091
|
var NdcActionManagementComponent = function (props) {
|
17376
|
-
var t = props.t,
|
18092
|
+
var t = props.t, onNavigateToNdcManagementView = props.onNavigateToNdcManagementView, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView;
|
17377
18093
|
var _a = React.useState(true), checkAll = _a[0], setCheckAll = _a[1];
|
17378
18094
|
var _b = React.useState([]), tableData = _b[0], setTableData = _b[1];
|
17379
18095
|
var _c = React.useState(), totalProgramme = _c[0], setTotalProgramme = _c[1];
|
@@ -18732,7 +19448,7 @@ var GenderParity = function (props) {
|
|
18732
19448
|
};
|
18733
19449
|
|
18734
19450
|
var Assessment = function (props) {
|
18735
|
-
var onFormSubmit = props.onFormSubmit, assessmentViewData = props.assessmentViewData, viewOnly = props.viewOnly,
|
19451
|
+
var onFormSubmit = props.onFormSubmit, assessmentViewData = props.assessmentViewData, viewOnly = props.viewOnly, translator = props.translator;
|
18736
19452
|
translator.setDefaultNamespace("coBenifits");
|
18737
19453
|
var t = translator.t;
|
18738
19454
|
var form1 = antd.Form.useForm()[0];
|
@@ -21137,7 +21853,7 @@ var SocialEnvironmentalRisk = function (props) {
|
|
21137
21853
|
};
|
21138
21854
|
|
21139
21855
|
var CoBenifitsComponent = function (props) {
|
21140
|
-
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
|
21856
|
+
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;
|
21141
21857
|
var _b = React.useState(), coBenefitDetails = _b[0], setCoBenefitDetails = _b[1];
|
21142
21858
|
var _c = React.useState(true), isSocialFormValid = _c[0], setIsSocialFormValid = _c[1];
|
21143
21859
|
var _d = React.useState(true), isAssessmentFormValid = _d[0], setIsAssessmentFormValid = _d[1];
|
@@ -21211,7 +21927,7 @@ var CoBenifitsComponent = function (props) {
|
|
21211
21927
|
label: t("coBenifits:assessment"),
|
21212
21928
|
key: "7",
|
21213
21929
|
children: (React.createElement(Assessment, { onFormSubmit: onAssessmentFormSubmit, assessmentViewData: (viewOnly && (coBenifitsViewDetails === null || coBenifitsViewDetails === void 0 ? void 0 : coBenifitsViewDetails.assessmentDetails)) ||
|
21214
|
-
(!viewOnly && (coBenefitsDetails === null || coBenefitsDetails === void 0 ? void 0 : coBenefitsDetails.assessmentDetails)), viewOnly: viewOnly || false,
|
21930
|
+
(!viewOnly && (coBenefitsDetails === null || coBenefitsDetails === void 0 ? void 0 : coBenefitsDetails.assessmentDetails)), viewOnly: viewOnly || false, translator: translator })),
|
21215
21931
|
},
|
21216
21932
|
{
|
21217
21933
|
label: t("coBenifits:socialEnvironmentalRisk"),
|
@@ -21380,7 +22096,7 @@ var CoBenifitsComponent = function (props) {
|
|
21380
22096
|
};
|
21381
22097
|
|
21382
22098
|
var AddNdcActionComponent = function (props) {
|
21383
|
-
var
|
22099
|
+
var useLocation = props.useLocation, onNavigateToProgrammeManagementView = props.onNavigateToProgrammeManagementView, onNavigateToProgrammeView = props.onNavigateToProgrammeView, sdgGoalImages = props.sdgGoalImages, translator = props.translator;
|
21384
22100
|
translator.setDefaultNamespace("ndcAction");
|
21385
22101
|
var t = translator.t;
|
21386
22102
|
var _a = React.useState(1), current = _a[0], setCurrent = _a[1];
|
@@ -21522,7 +22238,7 @@ var AddNdcActionComponent = function (props) {
|
|
21522
22238
|
description: (React.createElement("div", { className: current !== 2 ? "hide" : "" },
|
21523
22239
|
React.createElement(CoBenifitsComponent, { onClickedBackBtn: onClickBackCoBenefits, coBenefitsDetails: ndcActionDetails ? ndcActionDetails.coBenefitsProperties : {}, onFormSubmit: onCoBenefitsSubmit, submitButtonText: isProjectReportsVisible()
|
21524
22240
|
? t("ndcAction:next")
|
21525
|
-
: t("ndcAction:submit"), loading: loading, sdgGoalImages: sdgGoalImages,
|
22241
|
+
: t("ndcAction:submit"), loading: loading, sdgGoalImages: sdgGoalImages, translator: translator }))),
|
21526
22242
|
},
|
21527
22243
|
];
|
21528
22244
|
if (isProjectReportsVisible()) {
|
@@ -21659,7 +22375,7 @@ var uploadDocUserPermission = function (userInfoState, docType, programmeOwnerId
|
|
21659
22375
|
var NdcActionViewComponent = function (props) {
|
21660
22376
|
var _a;
|
21661
22377
|
var _b, _c;
|
21662
|
-
var
|
22378
|
+
var useLocation = props.useLocation, onNavigateToNdcManagementView = props.onNavigateToNdcManagementView, translator = props.translator, sdgGoalImages = props.sdgGoalImages, Chart = props.Chart;
|
21663
22379
|
translator.setDefaultNamespace("ndcAction");
|
21664
22380
|
var t = translator.t;
|
21665
22381
|
var userInfoState = useUserContext().userInfoState;
|
@@ -22152,7 +22868,7 @@ var NdcActionViewComponent = function (props) {
|
|
22152
22868
|
React.createElement(antd.Card, { className: "card-container" },
|
22153
22869
|
React.createElement("div", { className: "co-benifits-view" },
|
22154
22870
|
React.createElement("div", { className: "title" }, t("ndcAction:coBenefitsSubTitle")),
|
22155
|
-
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,
|
22871
|
+
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 })))))))));
|
22156
22872
|
};
|
22157
22873
|
|
22158
22874
|
var css_248z$b = ".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";
|
@@ -22305,7 +23021,7 @@ var TransferActionModel = function (props) {
|
|
22305
23021
|
};
|
22306
23022
|
|
22307
23023
|
var CreditTransferComponent = function (props) {
|
22308
|
-
var
|
23024
|
+
var translator = props.translator, onNavigateToProgrammeView = props.onNavigateToProgrammeView;
|
22309
23025
|
var userInfoState = useUserContext().userInfoState;
|
22310
23026
|
var t = translator.t;
|
22311
23027
|
var statusOptions = Object.keys(exports.CreditTransferStage).map(function (k, index) { return ({
|
@@ -23240,8 +23956,8 @@ var MapStatsComponent = function (props) {
|
|
23240
23956
|
|
23241
23957
|
var RangePicker$1 = antd.DatePicker.RangePicker;
|
23242
23958
|
var MrvDashboardComponent = function (props) {
|
23243
|
-
var
|
23244
|
-
var _b = useConnection(); _b.get; var post = _b.post; _b.delete;
|
23959
|
+
var Link = props.Link, Chart = props.Chart, t = props.t, ButtonGroup = props.ButtonGroup, _a = props.isMultipleDashboardsVisible, isMultipleDashboardsVisible = _a === void 0 ? false : _a;
|
23960
|
+
var _b = useConnection(); _b.get; var post = _b.post; _b.delete; var statServerUrl = _b.statServerUrl;
|
23245
23961
|
var _c = React.useState({}), data = _c[0], setData = _c[1];
|
23246
23962
|
var _e = React.useState(false), loading = _e[0], setLoading = _e[1];
|
23247
23963
|
var userInfoState = useUserContext().userInfoState;
|
@@ -23724,7 +24440,7 @@ var MrvDashboardComponent = function (props) {
|
|
23724
24440
|
_e.label = 1;
|
23725
24441
|
case 1:
|
23726
24442
|
_e.trys.push([1, 3, 4, 5]);
|
23727
|
-
return [4 /*yield*/, post("stats/programme/agg", genPayload(), undefined,
|
24443
|
+
return [4 /*yield*/, post("stats/programme/agg", genPayload(), undefined, statServerUrl)];
|
23728
24444
|
case 2:
|
23729
24445
|
response = _e.sent();
|
23730
24446
|
console.log("Response", response);
|
@@ -24973,8 +25689,8 @@ var RegistryBarChartsStatComponent = function (props) {
|
|
24973
25689
|
|
24974
25690
|
var RangePicker = antd.DatePicker.RangePicker;
|
24975
25691
|
var RegistryDashboardComponent = function (props) {
|
24976
|
-
var
|
24977
|
-
var _b = useConnection(); _b.get; var post = _b.post; _b.delete;
|
25692
|
+
var Chart = props.Chart, t = props.t, ButtonGroup = props.ButtonGroup, Link = props.Link, _a = props.isMultipleDashboardsVisible, isMultipleDashboardsVisible = _a === void 0 ? false : _a;
|
25693
|
+
var _b = useConnection(); _b.get; var post = _b.post; _b.delete; var statServerUrl = _b.statServerUrl;
|
24978
25694
|
var userInfoState = useUserContext().userInfoState;
|
24979
25695
|
var _c = React.useState(false), loadingWithoutTimeRange = _c[0], setLoadingWithoutTimeRange = _c[1];
|
24980
25696
|
var _e = React.useState(false), loading = _e[0], setLoading = _e[1];
|
@@ -25421,7 +26137,7 @@ var RegistryDashboardComponent = function (props) {
|
|
25421
26137
|
_253.label = 1;
|
25422
26138
|
case 1:
|
25423
26139
|
_253.trys.push([1, 3, 4, 5]);
|
25424
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllChartsParams(), undefined,
|
26140
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllChartsParams(), undefined, statServerUrl)];
|
25425
26141
|
case 2:
|
25426
26142
|
response = _253.sent();
|
25427
26143
|
totalCreditsCertifiedStats = void 0;
|
@@ -25698,7 +26414,7 @@ var RegistryDashboardComponent = function (props) {
|
|
25698
26414
|
_77.label = 1;
|
25699
26415
|
case 1:
|
25700
26416
|
_77.trys.push([1, 3, 4, 5]);
|
25701
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParamsWithoutTimeRange(), undefined,
|
26417
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParamsWithoutTimeRange(), undefined, statServerUrl)];
|
25702
26418
|
case 2:
|
25703
26419
|
response = _77.sent();
|
25704
26420
|
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;
|
@@ -25791,7 +26507,7 @@ var RegistryDashboardComponent = function (props) {
|
|
25791
26507
|
_188.label = 1;
|
25792
26508
|
case 1:
|
25793
26509
|
_188.trys.push([1, 3, 4, 5]);
|
25794
|
-
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParams(), undefined,
|
26510
|
+
return [4 /*yield*/, post("stats/programme/agg", getAllProgrammeAnalyticsStatsParams(), undefined, statServerUrl)];
|
25795
26511
|
case 2:
|
25796
26512
|
response = _188.sent();
|
25797
26513
|
programmeByStatusAuthAggregationResponse = void 0;
|
@@ -26740,7 +27456,7 @@ var NdcActionType;
|
|
26740
27456
|
NdcActionType[NdcActionType["sub"] = 1] = "sub";
|
26741
27457
|
})(NdcActionType || (NdcActionType = {}));
|
26742
27458
|
var NdcDetailsComponent = function (props) {
|
26743
|
-
var t = props.t;
|
27459
|
+
var t = props.t;
|
26744
27460
|
var RangePicker = antd.DatePicker.RangePicker;
|
26745
27461
|
var _a = React.useState([]), ndcDetailsData = _a[0], setNdcDetailsData = _a[1];
|
26746
27462
|
var _b = React.useState(false), loading = _b[0]; _b[1];
|
@@ -27462,7 +28178,7 @@ var ProgrammeIssueForm = function (props) {
|
|
27462
28178
|
};
|
27463
28179
|
|
27464
28180
|
var ProgrammeRetireForm = function (props) {
|
27465
|
-
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
|
28181
|
+
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;
|
27466
28182
|
var t = translator.t;
|
27467
28183
|
var _a = React.useState(undefined), popupError = _a[0], setPopupError = _a[1];
|
27468
28184
|
var _b = React.useState(false), loading = _b[0], setLoading = _b[1];
|
@@ -27838,7 +28554,7 @@ var ProgrammeRevokeForm = function (props) {
|
|
27838
28554
|
};
|
27839
28555
|
|
27840
28556
|
var ProgrammeTransferForm = function (props) {
|
27841
|
-
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,
|
28557
|
+
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;
|
27842
28558
|
var t = translator.t;
|
27843
28559
|
var _b = React.useState(undefined), popupError = _b[0], setPopupError = _b[1];
|
27844
28560
|
var _c = React.useState(false), loading = _c[0], setLoading = _c[1];
|
@@ -28065,11 +28781,11 @@ var RejectDocumentationConfirmationModel = function (props) {
|
|
28065
28781
|
React.createElement(antd.Button, { className: "mg-left-2", type: "primary", danger: true, htmlType: "submit", loading: loading, disabled: actionInfo.type === "reject" && comment === "" }, "REJECT")))));
|
28066
28782
|
};
|
28067
28783
|
|
28068
|
-
var css_248z$2 = ".ndc-action-body {\n display: flex;\n flex-direction: column;\n width: 100%; }\n .ndc-action-body .report-details {\n display: flex;\n flex-direction: row;\n width: 100%;\n align-items: flex-start;\n justify-content: space-between; }\n .ndc-action-body .report-details .report-type {\n display: flex;\n flex-direction: row;\n width: 60%;\n align-items: flex-start; }\n .ndc-action-body .report-details .report-type .name-time-container {\n display: flex;\n flex-direction: column;\n width: 70%;\n margin-bottom: 0.5rem; }\n .ndc-action-body .report-details .report-type .name {\n font-weight: 600;\n color: rgba(58, 53, 65, 0.8); }\n .ndc-action-body .report-details .report-type .icon {\n display: flex;\n width: 30%; }\n .ndc-action-body .report-details .report-type .empty {\n font-weight: 600;\n color: #cacaca; }\n .ndc-action-body .report-details .report-link {\n display: flex;\n flex-direction: row;\n width: 40%;\n justify-content: flex-start;\n gap: 20px
|
28784
|
+
var css_248z$2 = ".ndc-action-body {\n display: flex;\n flex-direction: column;\n width: 100%; }\n .ndc-action-body .report-details {\n display: flex;\n flex-direction: row;\n width: 100%;\n align-items: flex-start;\n justify-content: space-between; }\n .ndc-action-body .report-details .report-type {\n display: flex;\n flex-direction: row;\n width: 60%;\n align-items: flex-start; }\n .ndc-action-body .report-details .report-type .name-time-container {\n display: flex;\n flex-direction: column;\n width: 70%;\n margin-bottom: 0.5rem; }\n .ndc-action-body .report-details .report-type .name {\n font-weight: 600;\n color: rgba(58, 53, 65, 0.8); }\n .ndc-action-body .report-details .report-type .icon {\n display: flex;\n align-items: center;\n width: 30%; }\n .ndc-action-body .report-details .report-type .empty {\n font-weight: 600;\n color: #cacaca; }\n .ndc-action-body .report-details .report-link {\n display: flex;\n flex-direction: row;\n width: 40%;\n align-items: center;\n justify-content: flex-start;\n gap: 20px; }\n .ndc-action-body .report-details .report-link .version {\n font-weight: 600;\n color: #cacaca; }\n .ndc-action-body .report-details .report-link .link {\n margin-left: 1rem; }\n";
|
28069
28785
|
styleInject(css_248z$2);
|
28070
28786
|
|
28071
28787
|
var NdcActionBody = function (props) {
|
28072
|
-
var data = props.data, programmeId = props.programmeId, canUploadMonitorReport = props.canUploadMonitorReport, programmeOwnerId = props.programmeOwnerId, getProgrammeDocs = props.getProgrammeDocs, ministryLevelPermission = props.ministryLevelPermission,
|
28788
|
+
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;
|
28073
28789
|
var t = translator.t;
|
28074
28790
|
var userInfoState = useUserContext().userInfoState;
|
28075
28791
|
var fileInputMonitoringRef = React.useRef(null);
|
@@ -28331,7 +29047,7 @@ var NdcActionBody = function (props) {
|
|
28331
29047
|
React.createElement("div", { className: "icon" }, (monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.url) ? (monitoringReportPending ? ((companyRolePermission || ministryLevelPermission) && (React.createElement(React.Fragment, null,
|
28332
29048
|
React.createElement(icons.LikeOutlined, { onClick: function () {
|
28333
29049
|
return docAction(monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.id, exports.DocumentStatus.ACCEPTED, monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.actionId, monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.type);
|
28334
|
-
}, className: "common-progress-icon", style: { color: "#976ED7"
|
29050
|
+
}, className: "common-progress-icon", style: { color: "#976ED7" } }),
|
28335
29051
|
React.createElement(icons.DislikeOutlined, { onClick: function () {
|
28336
29052
|
setRejectDocData({
|
28337
29053
|
id: monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.id,
|
@@ -28346,8 +29062,8 @@ var NdcActionBody = function (props) {
|
|
28346
29062
|
icon: React.createElement(icons.DislikeOutlined, null),
|
28347
29063
|
});
|
28348
29064
|
setOpenRejectDocConfirmationModal(true);
|
28349
|
-
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70"
|
28350
|
-
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70"
|
29065
|
+
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70" } })))) : monitoringReportAccepted ? (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })) : (monitoringReportRejected && (React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: t("programme:rejectTip"), overlayClassName: "custom-tooltip" },
|
29066
|
+
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } }))))) : (React.createElement(React.Fragment, null,
|
28351
29067
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly
|
28352
29068
|
? t("programme:notAuthToUploadDoc")
|
28353
29069
|
: uploadDocUserPermission(userInfoState, exports.DocType.MONITORING_REPORT, programmeOwnerId, ministryLevelPermission)
|
@@ -28378,7 +29094,7 @@ var NdcActionBody = function (props) {
|
|
28378
29094
|
} }))))),
|
28379
29095
|
(monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.url) && (React.createElement("div", { className: "report-link" },
|
28380
29096
|
React.createElement("div", { className: "link" }, linkDocVisible(monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.status) && (React.createElement("a", { href: monitoringReportData === null || monitoringReportData === void 0 ? void 0 : monitoringReportData.url, target: "_blank", rel: "noopener noreferrer", download: true },
|
28381
|
-
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47"
|
29097
|
+
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } })))),
|
28382
29098
|
!monitoringReportAccepted && (React.createElement(React.Fragment, null,
|
28383
29099
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly
|
28384
29100
|
? t("programme:notAuthToUploadDoc")
|
@@ -28421,7 +29137,7 @@ var NdcActionBody = function (props) {
|
|
28421
29137
|
ministryLevelPermission) && (React.createElement(React.Fragment, null,
|
28422
29138
|
React.createElement(icons.LikeOutlined, { onClick: function () {
|
28423
29139
|
return docAction(verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.id, exports.DocumentStatus.ACCEPTED, verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.actionId, verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.type);
|
28424
|
-
}, className: "common-progress-icon", style: { color: "#976ED7"
|
29140
|
+
}, className: "common-progress-icon", style: { color: "#976ED7" } }),
|
28425
29141
|
React.createElement(icons.DislikeOutlined, { onClick: function () {
|
28426
29142
|
setRejectDocData({
|
28427
29143
|
id: verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.id,
|
@@ -28436,8 +29152,8 @@ var NdcActionBody = function (props) {
|
|
28436
29152
|
icon: React.createElement(icons.DislikeOutlined, null),
|
28437
29153
|
});
|
28438
29154
|
setOpenRejectDocConfirmationModal(true);
|
28439
|
-
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70"
|
28440
|
-
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70"
|
29155
|
+
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70" } })))) : verificationReportAccepted ? (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })) : (verifcationReportRejected && (React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: t("programme:rejectTip"), overlayClassName: "custom-tooltip" },
|
29156
|
+
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } }))))) : (React.createElement(React.Fragment, null,
|
28441
29157
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly
|
28442
29158
|
? t("programme:notAuthToUploadDoc")
|
28443
29159
|
: uploadDocUserPermission(userInfoState, exports.DocType.VERIFICATION_REPORT, programmeOwnerId, ministryLevelPermission)
|
@@ -28468,7 +29184,7 @@ var NdcActionBody = function (props) {
|
|
28468
29184
|
} })))))),
|
28469
29185
|
(verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.url) && (React.createElement("div", { className: "report-link" },
|
28470
29186
|
React.createElement("div", { className: "link" }, linkDocVisible(verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.status) && (React.createElement("a", { href: verificationReportData === null || verificationReportData === void 0 ? void 0 : verificationReportData.url, target: "_blank", rel: "noopener noreferrer", download: true },
|
28471
|
-
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47"
|
29187
|
+
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } })))),
|
28472
29188
|
!verificationReportAccepted && monitoringReportAccepted && (React.createElement(React.Fragment, null,
|
28473
29189
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly
|
28474
29190
|
? t("programme:notAuthToUploadDoc")
|
@@ -28501,11 +29217,11 @@ var NdcActionBody = function (props) {
|
|
28501
29217
|
React.createElement(RejectDocumentationConfirmationModel, { actionInfo: actionInfo, onActionConfirmed: handleOk, onActionCanceled: handleCancel, openModal: openRejectDocConfirmationModal, errorMsg: "", loading: loading, translator: translator })));
|
28502
29218
|
};
|
28503
29219
|
|
28504
|
-
var css_248z$1 = ".info-view .title-icon {\n padding-right: 10px; }\n\n.info-view .title-text {\n color: rgba(58, 53, 65, 0.8);\n font-weight: 600; }\n\n.info-view .title {\n margin-bottom: 5px; }\n\n.info-view .field-key {\n color: rgba(58, 53, 65, 0.6);\n font-weight: 500;\n text-overflow: ellipsis;\n overflow: hidden; }\n .info-view .field-key .label-container {\n display: flex;\n flex-direction: row
|
29220
|
+
var css_248z$1 = ".info-view .title-icon {\n padding-right: 10px; }\n\n.info-view .title-text {\n color: rgba(58, 53, 65, 0.8);\n font-weight: 600; }\n\n.info-view .title {\n margin-bottom: 5px; }\n\n.info-view .field-key {\n color: rgba(58, 53, 65, 0.6);\n font-weight: 500;\n text-overflow: ellipsis;\n overflow: hidden; }\n .info-view .field-key .label-container {\n display: flex;\n flex-direction: row; }\n .info-view .field-key .label {\n width: 70%; }\n .info-view .field-key .label-uploaded {\n color: rgba(58, 53, 65, 0.8);\n width: 70%; }\n\n.info-view .field-value {\n color: rgba(58, 53, 65, 0.6);\n text-overflow: ellipsis;\n overflow: hidden; }\n .info-view .field-value .link {\n display: flex;\n flex-direction: row;\n align-items: center;\n justify-content: flex-start;\n gap: 20px; }\n\n.info-view .field {\n margin: 15px 25px;\n font-size: 0.8rem; }\n";
|
28505
29221
|
styleInject(css_248z$1);
|
28506
29222
|
|
28507
29223
|
var ProgrammeDocuments = function (props) {
|
28508
|
-
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,
|
29224
|
+
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;
|
28509
29225
|
var t = translator.t;
|
28510
29226
|
var userInfoState = useUserContext().userInfoState;
|
28511
29227
|
var _a = useConnection(); _a.delete; var post = _a.post;
|
@@ -28748,7 +29464,7 @@ var ProgrammeDocuments = function (props) {
|
|
28748
29464
|
(designDocActionPermission || ministryLevelPermission) && (React.createElement(React.Fragment, null,
|
28749
29465
|
React.createElement(icons.LikeOutlined, { onClick: function () {
|
28750
29466
|
return docAction(designDocId, exports.DocumentStatus.ACCEPTED);
|
28751
|
-
}, className: "common-progress-icon", style: { color: "#976ED7"
|
29467
|
+
}, className: "common-progress-icon", style: { color: "#976ED7" } }),
|
28752
29468
|
React.createElement(icons.DislikeOutlined, { onClick: function () {
|
28753
29469
|
setRejectDocData({ id: designDocId });
|
28754
29470
|
setActionInfo({
|
@@ -28759,8 +29475,8 @@ var ProgrammeDocuments = function (props) {
|
|
28759
29475
|
icon: React.createElement(icons.DislikeOutlined, null),
|
28760
29476
|
});
|
28761
29477
|
setOpenRejectDocConfirmationModal(true);
|
28762
|
-
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70"
|
28763
|
-
designDocStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380"
|
29478
|
+
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70" } }))),
|
29479
|
+
designDocStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })),
|
28764
29480
|
designDocStatus === exports.DocumentStatus.REJECTED && (React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: t("programme:rejectTip"), overlayClassName: "custom-tooltip" },
|
28765
29481
|
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } })))),
|
28766
29482
|
designDocUrl !== "" && (React.createElement("div", { className: "time" },
|
@@ -28768,23 +29484,15 @@ var ProgrammeDocuments = function (props) {
|
|
28768
29484
|
" ~ " + designDocversion))),
|
28769
29485
|
React.createElement(antd.Col, { span: 6, className: "field-value" }, designDocUrl !== "" ? (React.createElement("div", { className: "link" },
|
28770
29486
|
linkDocVisible(designDocStatus) && (React.createElement("a", { href: designDocUrl, target: "_blank", rel: "noopener noreferrer", download: true },
|
28771
|
-
React.createElement(icons.BookOutlined, { className: "common-progress-icon", style: { color: "#3F3A47" } }))),
|
29487
|
+
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } }))),
|
28772
29488
|
designDocStatus !== exports.DocumentStatus.ACCEPTED && (React.createElement(React.Fragment, null,
|
28773
29489
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly ||
|
28774
29490
|
(userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.companyRole) === exports.CompanyRole.CERTIFIER
|
28775
29491
|
? t("programme:notAuthToUploadDoc")
|
28776
29492
|
: !uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission) && t("programme:orgNotAuth"), overlayClassName: "custom-tooltip" },
|
28777
29493
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission)
|
28778
|
-
? {
|
28779
|
-
|
28780
|
-
cursor: "pointer",
|
28781
|
-
margin: "0px 0px 1.5px 0px",
|
28782
|
-
}
|
28783
|
-
: {
|
28784
|
-
color: "#cacaca",
|
28785
|
-
cursor: "default",
|
28786
|
-
margin: "0px 0px 1.5px 0px",
|
28787
|
-
}, onClick: function () {
|
29494
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29495
|
+
: { color: "#cacaca", cursor: "default", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28788
29496
|
return uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission) && handleDesignDocFileUpload();
|
28789
29497
|
} })),
|
28790
29498
|
React.createElement("input", { type: "file", ref: fileInputRef, style: { display: "none" }, accept: ".xls, .xlsx, .ppt, .pptx, .csv, .doc, .docx, .pdf, .png, .jpg", onChange: function (e) {
|
@@ -28797,16 +29505,8 @@ var ProgrammeDocuments = function (props) {
|
|
28797
29505
|
? t("programme:notAuthToUploadDoc")
|
28798
29506
|
: !uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission) && t("programme:orgNotAuth"), overlayClassName: "custom-tooltip" },
|
28799
29507
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission)
|
28800
|
-
? {
|
28801
|
-
|
28802
|
-
cursor: "pointer",
|
28803
|
-
margin: "0px 0px 1.5px 0px",
|
28804
|
-
}
|
28805
|
-
: {
|
28806
|
-
color: "#cacaca",
|
28807
|
-
cursor: "default",
|
28808
|
-
margin: "0px 0px 1.5px 0px",
|
28809
|
-
}, onClick: function () {
|
29508
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29509
|
+
: { color: "#cacaca", cursor: "default", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28810
29510
|
return uploadDocUserPermission(userInfoState, exports.DocType.DESIGN_DOCUMENT, programmeOwnerId, ministryLevelPermission) && handleDesignDocFileUpload();
|
28811
29511
|
} })),
|
28812
29512
|
React.createElement("input", { type: "file", ref: fileInputRef, style: { display: "none" }, accept: ".xls, .xlsx, .ppt, .pptx, .csv, .doc, .docx, .pdf, .png, .jpg", onChange: function (e) {
|
@@ -28832,7 +29532,7 @@ var ProgrammeDocuments = function (props) {
|
|
28832
29532
|
(companyRolePermission || ministryLevelPermission) && (React.createElement(React.Fragment, null,
|
28833
29533
|
React.createElement(icons.LikeOutlined, { onClick: function () {
|
28834
29534
|
return docAction(methDocId, exports.DocumentStatus.ACCEPTED);
|
28835
|
-
}, className: "common-progress-icon", style: { color: "#976ED7"
|
29535
|
+
}, className: "common-progress-icon", style: { color: "#976ED7" } }),
|
28836
29536
|
React.createElement(icons.DislikeOutlined, { onClick: function () {
|
28837
29537
|
setRejectDocData({ id: methDocId });
|
28838
29538
|
setActionInfo({
|
@@ -28843,8 +29543,8 @@ var ProgrammeDocuments = function (props) {
|
|
28843
29543
|
icon: React.createElement(icons.DislikeOutlined, null),
|
28844
29544
|
});
|
28845
29545
|
setOpenRejectDocConfirmationModal(true);
|
28846
|
-
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70"
|
28847
|
-
methodDocStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380"
|
29546
|
+
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70" } }))),
|
29547
|
+
methodDocStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })),
|
28848
29548
|
methodDocStatus === exports.DocumentStatus.REJECTED && (React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: t("programme:rejectTip"), overlayClassName: "custom-tooltip" },
|
28849
29549
|
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } })))),
|
28850
29550
|
methodologyDocUrl !== "" && (React.createElement("div", { className: "time" },
|
@@ -28852,22 +29552,15 @@ var ProgrammeDocuments = function (props) {
|
|
28852
29552
|
" ~ " + methDocversion))),
|
28853
29553
|
React.createElement(antd.Col, { span: 6, className: "field-value" }, methodologyDocUrl !== "" ? (React.createElement("div", { className: "link" },
|
28854
29554
|
linkDocVisible(methodDocStatus) && (React.createElement("a", { href: methodologyDocUrl, target: "_blank", rel: "noopener noreferrer", download: true },
|
28855
|
-
React.createElement(icons.BookOutlined, { className: "common-progress-icon", style: { color: "#3F3A47" } }))),
|
29555
|
+
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } }))),
|
28856
29556
|
methodDocStatus !== exports.DocumentStatus.ACCEPTED && (React.createElement(React.Fragment, null,
|
28857
29557
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: (userInfoState === null || userInfoState === void 0 ? void 0 : userInfoState.userRole) === exports.Role.ViewOnly
|
28858
29558
|
? t("programme:notAuthToUploadDoc")
|
28859
29559
|
: !uploadDocUserPermission(userInfoState, exports.DocType.METHODOLOGY_DOCUMENT, programmeOwnerId, ministryLevelPermission) && t("programme:orgNotAuth"), overlayClassName: "custom-tooltip" },
|
28860
29560
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: designDocStatus === exports.DocumentStatus.ACCEPTED &&
|
28861
29561
|
uploadDocUserPermission(userInfoState, exports.DocType.METHODOLOGY_DOCUMENT, programmeOwnerId, ministryLevelPermission)
|
28862
|
-
? {
|
28863
|
-
|
28864
|
-
cursor: "pointer",
|
28865
|
-
margin: "0px 0px 1.5px 0px",
|
28866
|
-
}
|
28867
|
-
: {
|
28868
|
-
color: "#cacaca",
|
28869
|
-
margin: "0px 0px 1.5px 0px",
|
28870
|
-
}, onClick: function () {
|
29562
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29563
|
+
: { color: "#cacaca", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28871
29564
|
return designDocStatus === exports.DocumentStatus.ACCEPTED &&
|
28872
29565
|
uploadDocUserPermission(userInfoState, exports.DocType.METHODOLOGY_DOCUMENT, programmeOwnerId, ministryLevelPermission) &&
|
28873
29566
|
handleMethodologyFileUpload();
|
@@ -28886,16 +29579,8 @@ var ProgrammeDocuments = function (props) {
|
|
28886
29579
|
: t("programme:orgNotAuth"), overlayClassName: "custom-tooltip" },
|
28887
29580
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: designDocStatus === exports.DocumentStatus.ACCEPTED &&
|
28888
29581
|
uploadDocUserPermission(userInfoState, exports.DocType.METHODOLOGY_DOCUMENT, programmeOwnerId, ministryLevelPermission)
|
28889
|
-
? {
|
28890
|
-
|
28891
|
-
cursor: "pointer",
|
28892
|
-
margin: "0px 0px 1.5px 0px",
|
28893
|
-
}
|
28894
|
-
: {
|
28895
|
-
color: "#cacaca",
|
28896
|
-
cursor: "default",
|
28897
|
-
margin: "0px 0px 1.5px 0px",
|
28898
|
-
}, onClick: function () {
|
29582
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29583
|
+
: { color: "#cacaca", cursor: "default", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28899
29584
|
return designDocStatus === exports.DocumentStatus.ACCEPTED &&
|
28900
29585
|
uploadDocUserPermission(userInfoState, exports.DocType.METHODOLOGY_DOCUMENT, programmeOwnerId, ministryLevelPermission) &&
|
28901
29586
|
handleMethodologyFileUpload();
|
@@ -28924,7 +29609,7 @@ var ProgrammeDocuments = function (props) {
|
|
28924
29609
|
(ministryLevelPermission || companyRolePermission) && (React.createElement(React.Fragment, null,
|
28925
29610
|
React.createElement(icons.LikeOutlined, { onClick: function () {
|
28926
29611
|
return docAction(impactAssessmentId, exports.DocumentStatus.ACCEPTED);
|
28927
|
-
}, className: "common-progress-icon", style: { color: "#976ED7"
|
29612
|
+
}, className: "common-progress-icon", style: { color: "#976ED7" } }),
|
28928
29613
|
React.createElement(icons.DislikeOutlined, { onClick: function () {
|
28929
29614
|
setRejectDocData({ id: impactAssessmentId });
|
28930
29615
|
setActionInfo({
|
@@ -28935,8 +29620,8 @@ var ProgrammeDocuments = function (props) {
|
|
28935
29620
|
icon: React.createElement(icons.DislikeOutlined, null),
|
28936
29621
|
});
|
28937
29622
|
setOpenRejectDocConfirmationModal(true);
|
28938
|
-
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70"
|
28939
|
-
impactAssessmentStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380"
|
29623
|
+
}, className: "common-progress-icon margin-left-1", style: { color: "#FD6F70" } }))),
|
29624
|
+
impactAssessmentStatus === exports.DocumentStatus.ACCEPTED && (React.createElement(icons.CheckCircleOutlined, { className: "common-progress-icon", style: { color: "#5DC380" } })),
|
28940
29625
|
impactAssessmentStatus === exports.DocumentStatus.REJECTED && (React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: t("programme:rejectTip"), overlayClassName: "custom-tooltip" },
|
28941
29626
|
React.createElement(icons.ExclamationCircleOutlined, { className: "common-progress-icon", style: { color: "#FD6F70" } })))),
|
28942
29627
|
impactAssessmentUrl !== "" && (React.createElement("div", { className: "time" },
|
@@ -28944,22 +29629,13 @@ var ProgrammeDocuments = function (props) {
|
|
28944
29629
|
" ~ " + impactAssessmentversion))),
|
28945
29630
|
React.createElement(antd.Col, { span: 6, className: "field-value" }, impactAssessmentUrl !== "" ? (React.createElement("div", { className: "link" },
|
28946
29631
|
linkDocVisible(impactAssessmentStatus) && (React.createElement("a", { href: impactAssessmentUrl, target: "_blank", rel: "noopener noreferrer", download: true },
|
28947
|
-
React.createElement("
|
28948
|
-
React.createElement(icons.BookOutlined, { className: "common-progress-icon", style: { color: "#3F3A47" } })))),
|
29632
|
+
React.createElement(icons.BookOutlined, { className: "common-progress-icon margin-right-1", style: { color: "#3F3A47" } }))),
|
28949
29633
|
impactAssessmentStatus !== exports.DocumentStatus.ACCEPTED && (React.createElement(React.Fragment, null,
|
28950
29634
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: impactAssessmentToolTipTitle, overlayClassName: "custom-tooltip" },
|
28951
29635
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: uploadImpactAssessmentDocUserPermission &&
|
28952
29636
|
!isProjectRejected
|
28953
|
-
? {
|
28954
|
-
|
28955
|
-
cursor: "pointer",
|
28956
|
-
margin: "0px 0px 1.5px 0px",
|
28957
|
-
}
|
28958
|
-
: {
|
28959
|
-
color: "#cacaca",
|
28960
|
-
cursor: "default",
|
28961
|
-
margin: "0px 0px 1.5px 0px",
|
28962
|
-
}, onClick: function () {
|
29637
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29638
|
+
: { color: "#cacaca", cursor: "default", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28963
29639
|
return uploadImpactAssessmentDocUserPermission &&
|
28964
29640
|
!isProjectRejected &&
|
28965
29641
|
handleImpactAssessmentFileUpload();
|
@@ -28972,16 +29648,8 @@ var ProgrammeDocuments = function (props) {
|
|
28972
29648
|
React.createElement(antd.Tooltip, { arrowPointAtCenter: true, placement: "top", trigger: "hover", title: impactAssessmentToolTipTitle, overlayClassName: "custom-tooltip" },
|
28973
29649
|
React.createElement(icons.FileAddOutlined, { className: "common-progress-icon", style: uploadImpactAssessmentDocUserPermission &&
|
28974
29650
|
!isProjectRejected
|
28975
|
-
? {
|
28976
|
-
|
28977
|
-
cursor: "pointer",
|
28978
|
-
margin: "0px 0px 1.5px 0px",
|
28979
|
-
}
|
28980
|
-
: {
|
28981
|
-
color: "#cacaca",
|
28982
|
-
cursor: "default",
|
28983
|
-
margin: "0px 0px 1.5px 0px",
|
28984
|
-
}, onClick: function () {
|
29651
|
+
? { color: "#3F3A47", cursor: "pointer", margin: "0px 0px 2.5px 0px" }
|
29652
|
+
: { color: "#cacaca", cursor: "default", margin: "0px 0px 2.5px 0px" }, onClick: function () {
|
28985
29653
|
return uploadImpactAssessmentDocUserPermission &&
|
28986
29654
|
!isProjectRejected &&
|
28987
29655
|
handleImpactAssessmentFileUpload();
|
@@ -29060,6 +29728,7 @@ exports.CoBenifitsComponent = CoBenifitsComponent;
|
|
29060
29728
|
exports.Company = Company;
|
29061
29729
|
exports.CompanyManagementComponent = CompanyManagementComponent;
|
29062
29730
|
exports.CompanyProfileComponent = CompanyProfileComponent;
|
29731
|
+
exports.ConnectionContextProvider = ConnectionContextProvider;
|
29063
29732
|
exports.CreditTransferComponent = CreditTransferComponent;
|
29064
29733
|
exports.DevBGColor = DevBGColor;
|
29065
29734
|
exports.DevColor = DevColor;
|
@@ -29102,6 +29771,8 @@ exports.RejectDocumentationConfirmationModel = RejectDocumentationConfirmationMo
|
|
29102
29771
|
exports.RoleIcon = RoleIcon;
|
29103
29772
|
exports.RootBGColor = RootBGColor;
|
29104
29773
|
exports.RootColor = RootColor;
|
29774
|
+
exports.SettingsContext = SettingsContext;
|
29775
|
+
exports.SettingsContextProvider = SettingsContextProvider;
|
29105
29776
|
exports.StasticCard = StasticCard;
|
29106
29777
|
exports.SupportCreationComponent = SupportCreationComponent;
|
29107
29778
|
exports.SupportManagementComponent = SupportManagementComponent;
|
@@ -29110,6 +29781,8 @@ exports.TooltipColor = TooltipColor;
|
|
29110
29781
|
exports.TransferActionModel = TransferActionModel;
|
29111
29782
|
exports.UnitField = UnitField;
|
29112
29783
|
exports.User = User;
|
29784
|
+
exports.UserContext = UserContext;
|
29785
|
+
exports.UserInformationContextProvider = UserInformationContextProvider;
|
29113
29786
|
exports.UserManagementComponent = UserManagementComponent;
|
29114
29787
|
exports.UserProfileComponent = UserProfileComponent;
|
29115
29788
|
exports.UserRoleIcon = UserRoleIcon;
|
@@ -29151,4 +29824,7 @@ exports.ndcActionTypeList = ndcActionTypeList;
|
|
29151
29824
|
exports.sectorMitigationTypesListMapped = sectorMitigationTypesListMapped;
|
29152
29825
|
exports.sumArray = sumArray;
|
29153
29826
|
exports.titleList = titleList;
|
29827
|
+
exports.useConnection = useConnection;
|
29828
|
+
exports.useSettingsContext = useSettingsContext;
|
29829
|
+
exports.useUserContext = useUserContext;
|
29154
29830
|
//# sourceMappingURL=index.js.map
|