awing-library 2.1.3 → 2.1.4
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/lib/ACM-AXN/Campaign/index.js +2 -1
- package/lib/ACM-AXN/DomainPreview/PreviewButton.js +50 -27
- package/lib/ACM-AXN/Notifications/Constant.d.ts +144 -0
- package/lib/ACM-AXN/Notifications/Constant.js +134 -0
- package/lib/ACM-AXN/Notifications/Context.d.ts +8 -0
- package/lib/ACM-AXN/Notifications/Context.js +10 -0
- package/lib/ACM-AXN/Notifications/Hooks.d.ts +7 -0
- package/lib/ACM-AXN/Notifications/Hooks.js +17 -0
- package/lib/ACM-AXN/Notifications/NotificationDetail/HeaderInfo/ButtonTabs.js +26 -20
- package/lib/ACM-AXN/Notifications/NotificationDetail/HeaderInfo/MenuNotification.d.ts +1 -1
- package/lib/ACM-AXN/Notifications/NotificationDetail/HeaderInfo/MenuNotification.js +30 -39
- package/lib/ACM-AXN/Notifications/NotificationDetail/HeaderInfo/index.d.ts +2 -5
- package/lib/ACM-AXN/Notifications/NotificationDetail/HeaderInfo/index.js +18 -15
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationEmpty.d.ts +1 -1
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationEmpty.js +15 -15
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationEmpty.test.d.ts +0 -6
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationEmpty.test.js +29 -28
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/Message.d.ts +10 -0
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/Message.js +380 -0
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationAvatar.d.ts +1 -1
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationAvatar.js +3 -3
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationAvatar.test.d.ts +0 -6
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationAvatar.test.js +38 -48
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationContent.d.ts +2 -2
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationContent.js +32 -32
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationContent.test.d.ts +0 -6
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/NotificationContent.test.js +65 -73
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/index.d.ts +4 -11
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/index.js +46 -36
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/index.test.d.ts +0 -6
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/index.test.js +56 -50
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationLoading.js +30 -30
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/index.d.ts +3 -15
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/index.js +35 -4
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/index.test.d.ts +0 -6
- package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/index.test.js +88 -83
- package/lib/ACM-AXN/Notifications/NotificationDetail/index.d.ts +1 -1
- package/lib/ACM-AXN/Notifications/NotificationDetail/index.js +101 -100
- package/lib/ACM-AXN/Notifications/{NotificationPopover.d.ts → NotificationPopover/Container.d.ts} +2 -2
- package/lib/ACM-AXN/Notifications/NotificationPopover/Container.js +149 -0
- package/lib/ACM-AXN/Notifications/{NotificationPopover.test.d.ts → NotificationPopover/Container.test.d.ts} +1 -1
- package/lib/ACM-AXN/Notifications/{NotificationPopover.test.js → NotificationPopover/Container.test.js} +5 -5
- package/lib/ACM-AXN/Notifications/NotificationPopover/index.d.ts +8 -0
- package/lib/ACM-AXN/Notifications/NotificationPopover/index.js +13 -0
- package/lib/ACM-AXN/Notifications/NotificationScreen.d.ts +1 -1
- package/lib/ACM-AXN/Notifications/NotificationScreen.js +4 -4
- package/lib/ACM-AXN/Notifications/Types.d.ts +241 -0
- package/lib/ACM-AXN/Notifications/Types.js +290 -0
- package/lib/ACM-AXN/Notifications/index.d.ts +2 -2
- package/lib/ACM-AXN/Notifications/index.js +5 -5
- package/lib/ACM-AXN/Page/Container.js +2 -2
- package/lib/ACM-AXN/Page/index.js +2 -1
- package/lib/ACM-AXN/PlaceGroup/Context.d.ts +1 -1
- package/lib/ACM-AXN/ViewTemplate/TemplateField/Fields/BasicField/index.js +1 -1
- package/lib/AWING/Directory/CreateDirectory.d.ts +3 -0
- package/lib/AWING/Directory/CreateDirectory.js +27 -10
- package/lib/Commons/Components/ClassicBaseDrawer.d.ts +1 -0
- package/lib/Commons/Components/ClassicBaseDrawer.js +7 -3
- package/lib/translate/en/translation.json +53 -0
- package/lib/translate/vi/translation.json +53 -0
- package/package.json +2 -1
- package/lib/ACM-AXN/Notifications/NotificationDetail/Common.d.ts +0 -39
- package/lib/ACM-AXN/Notifications/NotificationDetail/Common.js +0 -304
- package/lib/ACM-AXN/Notifications/NotificationPopover.js +0 -69
- package/lib/ACM-AXN/Page/ViewDomain/index.d.ts +0 -9
- package/lib/ACM-AXN/Page/ViewDomain/index.js +0 -148
|
@@ -4,16 +4,13 @@
|
|
|
4
4
|
*
|
|
5
5
|
**/
|
|
6
6
|
/// <reference types="react" />
|
|
7
|
-
|
|
8
|
-
id: string | number;
|
|
9
|
-
status: boolean;
|
|
10
|
-
}
|
|
7
|
+
import { IValueItem } from '../../Types';
|
|
11
8
|
interface PropsHeaderInfo {
|
|
12
9
|
valueFilter: {
|
|
13
10
|
textSearch: string;
|
|
14
11
|
tabs: string;
|
|
15
12
|
};
|
|
16
|
-
onUpdateStatus: (dataSent:
|
|
13
|
+
onUpdateStatus: (dataSent: IValueItem | string) => void;
|
|
17
14
|
onValueFilter: (textSearch: string, tabs: string) => void;
|
|
18
15
|
}
|
|
19
16
|
declare const HeaderInfo: (props: PropsHeaderInfo) => JSX.Element;
|
|
@@ -12,20 +12,23 @@ var jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
12
12
|
var react_1 = __importDefault(require("react"));
|
|
13
13
|
var react_i18next_1 = require("react-i18next");
|
|
14
14
|
var material_1 = require("@mui/material");
|
|
15
|
-
var Common_1 = require("../Common");
|
|
16
|
-
var SearchBox_1 = __importDefault(require("../../../../AWING/SearchBox"));
|
|
17
15
|
var ButtonTabs_1 = __importDefault(require("./ButtonTabs"));
|
|
16
|
+
var Constant_1 = require("../../Constant");
|
|
18
17
|
var MenuNotification_1 = __importDefault(require("./MenuNotification"));
|
|
18
|
+
var SearchBox_1 = __importDefault(require("../../../../AWING/SearchBox"));
|
|
19
|
+
var Router_1 = require("../../../../AWING/Router");
|
|
19
20
|
var HeaderInfo = function (props) {
|
|
21
|
+
var navigate = (0, Router_1.useNavigate)();
|
|
20
22
|
var t = (0, react_i18next_1.useTranslation)().t;
|
|
21
23
|
var valueFilter = props.valueFilter, _a = props.onValueFilter, onValueFilter = _a === void 0 ? function () { return null; } : _a, _b = props.onUpdateStatus, onUpdateStatus = _b === void 0 ? function () { return null; } : _b;
|
|
22
24
|
var handleUpdateMenuItem = function (value) {
|
|
23
|
-
if (value ===
|
|
24
|
-
onUpdateStatus(
|
|
25
|
+
if (value === Constant_1.Constants.SELECT_ALL) {
|
|
26
|
+
onUpdateStatus(Constant_1.Constants.ALL);
|
|
25
27
|
}
|
|
26
28
|
else {
|
|
27
29
|
// Chuyển đến trang tương ứng
|
|
28
|
-
console.log('value : =============HeaderInfo========:>', value)
|
|
30
|
+
// console.log('value : =============HeaderInfo========:>', value) // Quandx
|
|
31
|
+
navigate("".concat(value));
|
|
29
32
|
}
|
|
30
33
|
};
|
|
31
34
|
var handleKeyWordPassing = react_1.default.useCallback(function (searchType, searchString) {
|
|
@@ -35,18 +38,18 @@ var HeaderInfo = function (props) {
|
|
|
35
38
|
onValueFilter(valueFilter.textSearch, tabItem);
|
|
36
39
|
}, [valueFilter]);
|
|
37
40
|
return ((0, jsx_runtime_1.jsxs)(material_1.Box, { component: "div", children: [(0, jsx_runtime_1.jsxs)(material_1.Box, { mb: 1, component: "div", sx: {
|
|
38
|
-
display:
|
|
39
|
-
flexDirection:
|
|
40
|
-
justifyContent:
|
|
41
|
+
display: 'flex',
|
|
42
|
+
flexDirection: 'row',
|
|
43
|
+
justifyContent: 'space-between',
|
|
41
44
|
}, children: [(0, jsx_runtime_1.jsx)(material_1.Typography, { variant: "h1", style: {
|
|
42
|
-
fontWeight:
|
|
43
|
-
fontSize:
|
|
44
|
-
}, children: t(
|
|
45
|
+
fontWeight: '700',
|
|
46
|
+
fontSize: '1.5em',
|
|
47
|
+
}, children: t('Common.Notification') }), (0, jsx_runtime_1.jsx)(MenuNotification_1.default, { onUpdateMenuItem: handleUpdateMenuItem })] }), (0, jsx_runtime_1.jsx)(SearchBox_1.default, { variantPaper: "outlined", onSearch: handleKeyWordPassing, stylePaper: {
|
|
45
48
|
flex: 1,
|
|
46
|
-
width:
|
|
47
|
-
maxWidth:
|
|
48
|
-
borderRadius:
|
|
49
|
-
padding:
|
|
49
|
+
width: 'auto',
|
|
50
|
+
maxWidth: '100%',
|
|
51
|
+
borderRadius: '24px',
|
|
52
|
+
padding: '2px 20px 2px 10px',
|
|
50
53
|
} }), (0, jsx_runtime_1.jsx)(ButtonTabs_1.default, { tabActive: valueFilter.tabs, onUpdateTabActive: handleUpdateTabActive })] }));
|
|
51
54
|
};
|
|
52
55
|
exports.default = HeaderInfo;
|
|
@@ -12,25 +12,25 @@ var jsx_runtime_1 = require("react/jsx-runtime");
|
|
|
12
12
|
var react_1 = __importDefault(require("react"));
|
|
13
13
|
var react_i18next_1 = require("react-i18next");
|
|
14
14
|
var material_1 = require("@mui/material");
|
|
15
|
-
var bell_svg_1 = __importDefault(require("Assets/Images/bell.svg"));
|
|
16
|
-
var binoculars_svg_1 = __importDefault(require("Assets/Images/binoculars.svg"));
|
|
15
|
+
var bell_svg_1 = __importDefault(require("../../../../Assets/Images/bell.svg"));
|
|
16
|
+
var binoculars_svg_1 = __importDefault(require("../../../../Assets/Images/binoculars.svg"));
|
|
17
17
|
var NotificationEmpty = function (props) {
|
|
18
18
|
var _a = props.isSearch, isSearch = _a === void 0 ? false : _a;
|
|
19
19
|
var t = (0, react_i18next_1.useTranslation)().t;
|
|
20
20
|
return ((0, jsx_runtime_1.jsxs)(material_1.Box, { component: "div", sx: {
|
|
21
|
-
paddingBottom:
|
|
22
|
-
display:
|
|
23
|
-
flexDirection:
|
|
24
|
-
alignItems:
|
|
25
|
-
justifyContent:
|
|
26
|
-
}, children: [(0, jsx_runtime_1.jsx)("img", { src: (isSearch ? binoculars_svg_1.default : bell_svg_1.default), alt: isSearch ?
|
|
27
|
-
fontSize:
|
|
28
|
-
color:
|
|
29
|
-
fontWeight:
|
|
30
|
-
marginTop:
|
|
31
|
-
textAlign:
|
|
21
|
+
paddingBottom: '30px',
|
|
22
|
+
display: 'flex',
|
|
23
|
+
flexDirection: 'column',
|
|
24
|
+
alignItems: 'center',
|
|
25
|
+
justifyContent: 'space-between',
|
|
26
|
+
}, children: [(0, jsx_runtime_1.jsx)("img", { src: (isSearch ? binoculars_svg_1.default : bell_svg_1.default), alt: isSearch ? 'iconBinoculars' : 'iconBell', style: { width: '80px', height: '80px' } }), (0, jsx_runtime_1.jsx)(material_1.Typography, { style: {
|
|
27
|
+
fontSize: '1.3em',
|
|
28
|
+
color: '#65676B',
|
|
29
|
+
fontWeight: '600',
|
|
30
|
+
marginTop: '10px',
|
|
31
|
+
textAlign: 'center',
|
|
32
32
|
}, children: isSearch
|
|
33
|
-
? t(
|
|
34
|
-
: t(
|
|
33
|
+
? t('Notifications.InappropriateNotification')
|
|
34
|
+
: t('Notifications.TitleNoNotifications') })] }));
|
|
35
35
|
};
|
|
36
36
|
exports.default = react_1.default.memo(NotificationEmpty);
|
package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationEmpty.test.js
CHANGED
|
@@ -1,29 +1,30 @@
|
|
|
1
1
|
"use strict";
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
});
|
|
2
|
+
// /**
|
|
3
|
+
// *
|
|
4
|
+
// * @author dauquan1108@gmail.com on 12/06/2023.
|
|
5
|
+
// *
|
|
6
|
+
// **/
|
|
7
|
+
// import React from 'react';
|
|
8
|
+
// import {render} from '@testing-library/react';
|
|
9
|
+
// import '@testing-library/jest-dom';
|
|
10
|
+
// import NotificationEmpty from './NotificationEmpty';
|
|
11
|
+
// describe("NotificationEmpty component", () => {
|
|
12
|
+
// it("Hiển thị thông báo mặc định đối với trường hợp 'isSearch = false'.", () => {
|
|
13
|
+
// const {getByText, getByAltText} = render(<NotificationEmpty isSearch={false}/>);
|
|
14
|
+
// // kiểm tra icon hiển thị khi trạng thái bằng false.
|
|
15
|
+
// const iconEmpty = getByAltText("iconBell");
|
|
16
|
+
// expect(iconEmpty).toBeInTheDocument();
|
|
17
|
+
// // Kiểm tra text hiển thị khi trạng thái bằng false.
|
|
18
|
+
// const titleText = getByText("Notifications.TitleNoNotifications");
|
|
19
|
+
// expect(titleText).toBeInTheDocument();
|
|
20
|
+
// });
|
|
21
|
+
// it("Hiển thị thông báo khi đối với trường hợp 'isSearch=true'.", () => {
|
|
22
|
+
// const {getByText, getByAltText} = render(<NotificationEmpty isSearch={true}/>);
|
|
23
|
+
// // kiểm tra icon hiển thị khi trạng thái bằng true.
|
|
24
|
+
// const iconEmpty = getByAltText("iconBinoculars");
|
|
25
|
+
// expect(iconEmpty).toBeInTheDocument();
|
|
26
|
+
// // Kiểm tra text hiển thị khi trạng thái bằng true.
|
|
27
|
+
// const titleText = getByText("Notifications.InappropriateNotification");
|
|
28
|
+
// expect(titleText).toBeInTheDocument();
|
|
29
|
+
// });
|
|
30
|
+
// });
|
package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/Message.d.ts
ADDED
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
*
|
|
3
|
+
* @author dauquan1108@gmail.com on 11/27/2023.
|
|
4
|
+
*
|
|
5
|
+
**/
|
|
6
|
+
import { NotificationMessageField, SagaTransactionType } from '../../../Types';
|
|
7
|
+
export declare const getFullDescription: (type: SagaTransactionType, translation: any, fields: NotificationMessageField[]) => {
|
|
8
|
+
title: import("react/jsx-runtime").JSX.Element;
|
|
9
|
+
url: string;
|
|
10
|
+
};
|
package/lib/ACM-AXN/Notifications/NotificationDetail/NotificationList/NotificationItem/Message.js
ADDED
|
@@ -0,0 +1,380 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.getFullDescription = void 0;
|
|
4
|
+
var jsx_runtime_1 = require("react/jsx-runtime");
|
|
5
|
+
var react_router_dom_1 = require("react-router-dom");
|
|
6
|
+
var Constant_1 = require("../../../Constant");
|
|
7
|
+
var Types_1 = require("../../../Types");
|
|
8
|
+
// CampaignAction
|
|
9
|
+
var CampaignActionBuildCreateDescription = function (translation, fields) {
|
|
10
|
+
var _a, _b;
|
|
11
|
+
var campaign = (_a = fields.find(function (x) { return x.name === 'CampaignId'; })) !== null && _a !== void 0 ? _a : {
|
|
12
|
+
value: '',
|
|
13
|
+
text: '[No name]',
|
|
14
|
+
};
|
|
15
|
+
return {
|
|
16
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Campaign'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.CAMPAIGN_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(campaign.value), children: (_b = campaign.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.created') })] })),
|
|
17
|
+
url: "".concat(Constant_1.Constants.CAMPAIGN_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(campaign.value),
|
|
18
|
+
};
|
|
19
|
+
};
|
|
20
|
+
var CampaignActionBuildUpdateDescription = function (translation, fields) {
|
|
21
|
+
var _a, _b;
|
|
22
|
+
var campaign = (_a = fields.find(function (x) { return x.name === 'CampaignId'; })) !== null && _a !== void 0 ? _a : {
|
|
23
|
+
value: '',
|
|
24
|
+
text: '[No name]',
|
|
25
|
+
};
|
|
26
|
+
return {
|
|
27
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Campaign'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.CAMPAIGN_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(campaign.value), children: (_b = campaign.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.updated') })] })),
|
|
28
|
+
url: "".concat(Constant_1.Constants.CAMPAIGN_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(campaign.value),
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
var CampaignActionBuildDeleteDescription = function (translation, fields) {
|
|
32
|
+
var _a, _b;
|
|
33
|
+
var campaign = (_a = fields.find(function (x) { return x.name === 'CampaignId'; })) !== null && _a !== void 0 ? _a : {
|
|
34
|
+
value: '',
|
|
35
|
+
text: '[No name]',
|
|
36
|
+
};
|
|
37
|
+
return {
|
|
38
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Campaign'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_b = campaign.text) !== null && _b !== void 0 ? _b : "[No name]" }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.deleted') })] })),
|
|
39
|
+
url: '',
|
|
40
|
+
};
|
|
41
|
+
};
|
|
42
|
+
// End CampaignAction
|
|
43
|
+
// PageAction
|
|
44
|
+
var PageActionBuildCreateDescription = function (translation, fields) {
|
|
45
|
+
var _a, _b, _c;
|
|
46
|
+
var page = (_a = fields.find(function (x) { return x.name === 'PageId'; })) !== null && _a !== void 0 ? _a : {
|
|
47
|
+
value: '',
|
|
48
|
+
text: '[No name]',
|
|
49
|
+
};
|
|
50
|
+
var pageCode = (_b = fields.find(function (x) { return x.name === 'PageCode'; })) !== null && _b !== void 0 ? _b : {
|
|
51
|
+
value: '',
|
|
52
|
+
text: '[No name]',
|
|
53
|
+
};
|
|
54
|
+
return {
|
|
55
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
56
|
+
? translation('Notification.PageLogin')
|
|
57
|
+
: translation('Notification.PageWelcome'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
58
|
+
? Constant_1.Constants.PAGE_LOGIN
|
|
59
|
+
: Constant_1.Constants.PAGE_WELCOME, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(page.value), children: (_c = page.text) !== null && _c !== void 0 ? _c : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.created') })] })),
|
|
60
|
+
url: "".concat(pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
61
|
+
? Constant_1.Constants.PAGE_LOGIN
|
|
62
|
+
: Constant_1.Constants.PAGE_WELCOME, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(page.value),
|
|
63
|
+
};
|
|
64
|
+
};
|
|
65
|
+
var PageActionBuildUpdateDescription = function (translation, fields) {
|
|
66
|
+
var _a, _b, _c;
|
|
67
|
+
var page = (_a = fields.find(function (x) { return x.name === 'PageId'; })) !== null && _a !== void 0 ? _a : {
|
|
68
|
+
value: '',
|
|
69
|
+
text: '[No name]',
|
|
70
|
+
};
|
|
71
|
+
var pageCode = (_b = fields.find(function (x) { return x.name === 'PageCode'; })) !== null && _b !== void 0 ? _b : {
|
|
72
|
+
value: '',
|
|
73
|
+
text: '[No name]',
|
|
74
|
+
};
|
|
75
|
+
return {
|
|
76
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
77
|
+
? translation('Notification.PageLogin')
|
|
78
|
+
: translation('Notification.PageWelcome'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
79
|
+
? Constant_1.Constants.PAGE_LOGIN
|
|
80
|
+
: Constant_1.Constants.PAGE_WELCOME, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(page.value), children: (_c = page.text) !== null && _c !== void 0 ? _c : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.updated') })] })),
|
|
81
|
+
url: "".concat(pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
82
|
+
? Constant_1.Constants.PAGE_LOGIN
|
|
83
|
+
: Constant_1.Constants.PAGE_WELCOME, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(page.value),
|
|
84
|
+
};
|
|
85
|
+
};
|
|
86
|
+
var PageActionBuildDeleteDescription = function (translation, fields) {
|
|
87
|
+
var _a, _b, _c;
|
|
88
|
+
var page = (_a = fields.find(function (x) { return x.name === 'PageId'; })) !== null && _a !== void 0 ? _a : {
|
|
89
|
+
value: '',
|
|
90
|
+
text: '[No name]',
|
|
91
|
+
};
|
|
92
|
+
var pageCode = (_b = fields.find(function (x) { return x.name === 'PageCode'; })) !== null && _b !== void 0 ? _b : {
|
|
93
|
+
value: '',
|
|
94
|
+
text: '[No name]',
|
|
95
|
+
};
|
|
96
|
+
return {
|
|
97
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [pageCode.value === Constant_1.PAGE_CODES.PageCodeLogin
|
|
98
|
+
? translation('Notification.PageLogin')
|
|
99
|
+
: translation('Notification.PageWelcome'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = page.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.deleted') })] })),
|
|
100
|
+
url: '',
|
|
101
|
+
};
|
|
102
|
+
};
|
|
103
|
+
// End PageAction
|
|
104
|
+
// DomainAction
|
|
105
|
+
var DomainActionBuildUpdateDescription = function (translation, fields) {
|
|
106
|
+
var _a, _b;
|
|
107
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
108
|
+
value: '',
|
|
109
|
+
text: '[No name]',
|
|
110
|
+
};
|
|
111
|
+
return {
|
|
112
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.updated') })] })),
|
|
113
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
114
|
+
};
|
|
115
|
+
};
|
|
116
|
+
// End DomainAction
|
|
117
|
+
// DomainTransaction
|
|
118
|
+
var DomainTransactionBuildJoinRequestDescription = function (translation, fields) {
|
|
119
|
+
var _a, _b, _c;
|
|
120
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
121
|
+
value: '',
|
|
122
|
+
text: '[No name]',
|
|
123
|
+
};
|
|
124
|
+
var request = (_b = fields.find(function (x) { return x.name === 'RequestId'; })) !== null && _b !== void 0 ? _b : {
|
|
125
|
+
value: '',
|
|
126
|
+
text: '[No name]',
|
|
127
|
+
};
|
|
128
|
+
return {
|
|
129
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = domain.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.send'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(request.value, "/DomainJoinRequest"), children: translation('Notification.request') }) }), "join network"] })),
|
|
130
|
+
url: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(request.value, "/DomainJoinRequest"),
|
|
131
|
+
};
|
|
132
|
+
};
|
|
133
|
+
var DomainTransactionBuildJoinApproveDescription = function (translation, fields) {
|
|
134
|
+
var _a, _b;
|
|
135
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
136
|
+
value: '',
|
|
137
|
+
text: '[No name]',
|
|
138
|
+
};
|
|
139
|
+
return {
|
|
140
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.approved') }), "join network"] })),
|
|
141
|
+
url: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
142
|
+
};
|
|
143
|
+
};
|
|
144
|
+
var DomainTransactionBuildJoinRejectDescription = function (translation, fields) {
|
|
145
|
+
var _a, _b;
|
|
146
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
147
|
+
value: '',
|
|
148
|
+
text: '[No name]',
|
|
149
|
+
};
|
|
150
|
+
return {
|
|
151
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.rejected') }), "join network"] })),
|
|
152
|
+
url: '',
|
|
153
|
+
};
|
|
154
|
+
};
|
|
155
|
+
var DomainTransactionBuildJoinDeleteDescription = function (translation, fields) {
|
|
156
|
+
var _a, _b;
|
|
157
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
158
|
+
value: '',
|
|
159
|
+
text: '[No name]',
|
|
160
|
+
};
|
|
161
|
+
return {
|
|
162
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.EventObject.Delete') }), translation('Notification.EventObject.JoinRequest')] })),
|
|
163
|
+
url: '',
|
|
164
|
+
};
|
|
165
|
+
};
|
|
166
|
+
var DomainTransactionBuildUnjoinRequestDescription = function (translation, fields) {
|
|
167
|
+
var _a, _b, _c;
|
|
168
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
169
|
+
value: '',
|
|
170
|
+
text: '[No name]',
|
|
171
|
+
};
|
|
172
|
+
var request = (_b = fields.find(function (x) { return x.name === 'RequestId'; })) !== null && _b !== void 0 ? _b : {
|
|
173
|
+
value: '',
|
|
174
|
+
text: '[No name]',
|
|
175
|
+
};
|
|
176
|
+
return {
|
|
177
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_c = domain.text) !== null && _c !== void 0 ? _c : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(request.value, "/PlaceUnjoinRequest"), children: translation('Notification.request') }) }), "unjoin network"] })),
|
|
178
|
+
url: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
179
|
+
};
|
|
180
|
+
};
|
|
181
|
+
var DomainTransactionBuildUnjoinApproveDescription = function (translation, fields) {
|
|
182
|
+
var _a, _b;
|
|
183
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
184
|
+
value: '',
|
|
185
|
+
text: '[No name]',
|
|
186
|
+
};
|
|
187
|
+
return {
|
|
188
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.approved') }), "unjoin network"] })),
|
|
189
|
+
url: '',
|
|
190
|
+
};
|
|
191
|
+
};
|
|
192
|
+
var DomainTransactionBuildUnjoinRejectDescription = function (translation, fields) {
|
|
193
|
+
var _a, _b;
|
|
194
|
+
var domain = (_a = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _a !== void 0 ? _a : {
|
|
195
|
+
value: '',
|
|
196
|
+
text: '[No name]',
|
|
197
|
+
};
|
|
198
|
+
return {
|
|
199
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_b = domain.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.rejected') }), "unjoin network"] })),
|
|
200
|
+
url: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
201
|
+
};
|
|
202
|
+
};
|
|
203
|
+
// End DomainTransaction
|
|
204
|
+
// PlaceAction
|
|
205
|
+
var PlaceActionBuildUpdateDescription = function (translation, fields) {
|
|
206
|
+
var _a, _b;
|
|
207
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
208
|
+
value: '',
|
|
209
|
+
text: '[No name]',
|
|
210
|
+
};
|
|
211
|
+
return {
|
|
212
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value), children: (_b = place.text) !== null && _b !== void 0 ? _b : "[No name]" }) }), translation('Notification.has been'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.updated') })] })),
|
|
213
|
+
url: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value),
|
|
214
|
+
};
|
|
215
|
+
};
|
|
216
|
+
// End PlaceAction
|
|
217
|
+
// PlaceTransaction
|
|
218
|
+
var PlaceTransactionBuildJoinRequestDescription = function (translation, fields) {
|
|
219
|
+
var _a, _b, _c, _d;
|
|
220
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
221
|
+
value: '',
|
|
222
|
+
text: '[No name]',
|
|
223
|
+
};
|
|
224
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
225
|
+
value: '',
|
|
226
|
+
text: '[No name]',
|
|
227
|
+
};
|
|
228
|
+
return {
|
|
229
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.send'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.CAMPAIGN_DETAIL, "/").concat(place.value, "/PlaceJoinRequest"), children: translation('Notification.request') }) }), "join network"] })),
|
|
230
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
231
|
+
};
|
|
232
|
+
};
|
|
233
|
+
var PlaceTransactionBuildJoinApproveDescription = function (translation, fields) {
|
|
234
|
+
var _a, _b, _c, _d;
|
|
235
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
236
|
+
value: '',
|
|
237
|
+
text: '[No name]',
|
|
238
|
+
};
|
|
239
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
240
|
+
value: '',
|
|
241
|
+
text: '[No name]',
|
|
242
|
+
};
|
|
243
|
+
return {
|
|
244
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value), children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }) }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.approved') }), "join network"] })),
|
|
245
|
+
url: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value),
|
|
246
|
+
};
|
|
247
|
+
};
|
|
248
|
+
var PlaceTransactionBuildJoinRejectDescription = function (translation, fields) {
|
|
249
|
+
var _a, _b, _c, _d;
|
|
250
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
251
|
+
value: '',
|
|
252
|
+
text: '[No name]',
|
|
253
|
+
};
|
|
254
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
255
|
+
value: '',
|
|
256
|
+
text: '[No name]',
|
|
257
|
+
};
|
|
258
|
+
return {
|
|
259
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.rejected') }), "join network"] })),
|
|
260
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
261
|
+
};
|
|
262
|
+
};
|
|
263
|
+
var PlaceTransactionBuildUnjoinRequestDescription = function (translation, fields) {
|
|
264
|
+
var _a, _b, _c, _d;
|
|
265
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
266
|
+
value: '',
|
|
267
|
+
text: '[No name]',
|
|
268
|
+
};
|
|
269
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
270
|
+
value: '',
|
|
271
|
+
text: '[No name]',
|
|
272
|
+
};
|
|
273
|
+
return {
|
|
274
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value), children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }) }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.NETWORK_PATH, "/").concat(Constant_1.Constants.DETAIL_PATH, "/").concat(place.value, "/PlaceUnjoinRequest"), children: translation('Notification.request') }) }), "unjoin network"] })),
|
|
275
|
+
url: "".concat(Constant_1.Constants.PLACE_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(place.value),
|
|
276
|
+
};
|
|
277
|
+
};
|
|
278
|
+
var PlaceTransactionBuildUnjoinApproveDescription = function (translation, fields) {
|
|
279
|
+
var _a, _b, _c, _d;
|
|
280
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
281
|
+
value: '',
|
|
282
|
+
text: '[No name]',
|
|
283
|
+
};
|
|
284
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
285
|
+
value: '',
|
|
286
|
+
text: '[No name]',
|
|
287
|
+
};
|
|
288
|
+
return {
|
|
289
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.approved') }), "unjoin network"] })),
|
|
290
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
291
|
+
};
|
|
292
|
+
};
|
|
293
|
+
var PlaceTransactionBuildUnjoinRejectDescription = function (translation, fields) {
|
|
294
|
+
var _a, _b, _c, _d;
|
|
295
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
296
|
+
value: '',
|
|
297
|
+
text: '[No name]',
|
|
298
|
+
};
|
|
299
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
300
|
+
value: '',
|
|
301
|
+
text: '[No name]',
|
|
302
|
+
};
|
|
303
|
+
return {
|
|
304
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: translation('Notification.rejected') }), "unjoin network"] })),
|
|
305
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
306
|
+
};
|
|
307
|
+
};
|
|
308
|
+
var PlaceTransactionBuildPlaceStatusDescription = function (translation, fields) {
|
|
309
|
+
var _a, _b, _c, _d;
|
|
310
|
+
var place = (_a = fields.find(function (x) { return x.name === 'PlaceId'; })) !== null && _a !== void 0 ? _a : {
|
|
311
|
+
value: '',
|
|
312
|
+
text: '[No name]',
|
|
313
|
+
};
|
|
314
|
+
var domain = (_b = fields.find(function (x) { return x.name === 'DomainId'; })) !== null && _b !== void 0 ? _b : {
|
|
315
|
+
value: '',
|
|
316
|
+
text: '[No name]',
|
|
317
|
+
};
|
|
318
|
+
return {
|
|
319
|
+
title: ((0, jsx_runtime_1.jsxs)(jsx_runtime_1.Fragment, { children: [translation('Notification.Place'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (_c = place.text) !== null && _c !== void 0 ? _c : "[No name]" }), translation('Notification.of domain'), (0, jsx_runtime_1.jsx)("span", { style: { padding: '0px 3px' }, children: (0, jsx_runtime_1.jsx)(react_router_dom_1.NavLink, { to: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value), children: (_d = domain.text) !== null && _d !== void 0 ? _d : "[No name]" }) }), translation('Notification.has'), "unjoin network"] })),
|
|
320
|
+
url: "".concat(Constant_1.Constants.DOMAINS_PATH, "/").concat(Constant_1.Constants.EDIT_PATH, "/").concat(domain.value),
|
|
321
|
+
};
|
|
322
|
+
};
|
|
323
|
+
// End PlaceTransaction
|
|
324
|
+
var getFullDescription = function (type, translation, fields) {
|
|
325
|
+
try {
|
|
326
|
+
switch (type) {
|
|
327
|
+
case Types_1.SagaTransactionType.CampaignCreate:
|
|
328
|
+
return CampaignActionBuildCreateDescription(translation, fields);
|
|
329
|
+
case Types_1.SagaTransactionType.CampaignUpdate:
|
|
330
|
+
return CampaignActionBuildUpdateDescription(translation, fields);
|
|
331
|
+
case Types_1.SagaTransactionType.CampaignDelete:
|
|
332
|
+
return CampaignActionBuildDeleteDescription(translation, fields);
|
|
333
|
+
case Types_1.SagaTransactionType.PageCreate:
|
|
334
|
+
return PageActionBuildCreateDescription(translation, fields);
|
|
335
|
+
case Types_1.SagaTransactionType.PageUpdate:
|
|
336
|
+
return PageActionBuildUpdateDescription(translation, fields);
|
|
337
|
+
case Types_1.SagaTransactionType.PageDelete:
|
|
338
|
+
return PageActionBuildDeleteDescription(translation, fields);
|
|
339
|
+
case Types_1.SagaTransactionType.DomainUpdate:
|
|
340
|
+
return DomainActionBuildUpdateDescription(translation, fields);
|
|
341
|
+
case Types_1.SagaTransactionType.DomainJoinRequest:
|
|
342
|
+
return DomainTransactionBuildJoinRequestDescription(translation, fields);
|
|
343
|
+
case Types_1.SagaTransactionType.DomainJoinApprove:
|
|
344
|
+
return DomainTransactionBuildJoinApproveDescription(translation, fields);
|
|
345
|
+
case Types_1.SagaTransactionType.DomainJoinReject:
|
|
346
|
+
return DomainTransactionBuildJoinRejectDescription(translation, fields);
|
|
347
|
+
case Types_1.SagaTransactionType.DomainUnjoinRequest:
|
|
348
|
+
return DomainTransactionBuildUnjoinRequestDescription(translation, fields);
|
|
349
|
+
case Types_1.SagaTransactionType.DomainUnjoinApprove:
|
|
350
|
+
return DomainTransactionBuildUnjoinApproveDescription(translation, fields);
|
|
351
|
+
case Types_1.SagaTransactionType.DomainUnjoinReject:
|
|
352
|
+
return DomainTransactionBuildUnjoinRejectDescription(translation, fields);
|
|
353
|
+
case Types_1.SagaTransactionType.DomainJoinDelete:
|
|
354
|
+
return DomainTransactionBuildJoinDeleteDescription(translation, fields);
|
|
355
|
+
case Types_1.SagaTransactionType.PlaceUpdate:
|
|
356
|
+
return PlaceActionBuildUpdateDescription(translation, fields);
|
|
357
|
+
case Types_1.SagaTransactionType.PlaceJoinRequest:
|
|
358
|
+
return PlaceTransactionBuildJoinRequestDescription(translation, fields);
|
|
359
|
+
case Types_1.SagaTransactionType.PlaceJoinApprove:
|
|
360
|
+
return PlaceTransactionBuildJoinApproveDescription(translation, fields);
|
|
361
|
+
case Types_1.SagaTransactionType.PlaceJoinReject:
|
|
362
|
+
return PlaceTransactionBuildJoinRejectDescription(translation, fields);
|
|
363
|
+
case Types_1.SagaTransactionType.PlaceUnjoinRequest:
|
|
364
|
+
return PlaceTransactionBuildUnjoinRequestDescription(translation, fields);
|
|
365
|
+
case Types_1.SagaTransactionType.PlaceUnjoinApprove:
|
|
366
|
+
return PlaceTransactionBuildUnjoinApproveDescription(translation, fields);
|
|
367
|
+
case Types_1.SagaTransactionType.PlaceUnjoinReject:
|
|
368
|
+
return PlaceTransactionBuildUnjoinRejectDescription(translation, fields);
|
|
369
|
+
case Types_1.SagaTransactionType.PlaceStatusUpdate:
|
|
370
|
+
return PlaceTransactionBuildPlaceStatusDescription(translation, fields);
|
|
371
|
+
default:
|
|
372
|
+
return { title: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {}), url: '' };
|
|
373
|
+
}
|
|
374
|
+
}
|
|
375
|
+
catch (error) {
|
|
376
|
+
console.log('[Error: Content Notification]: ', error);
|
|
377
|
+
return { title: (0, jsx_runtime_1.jsx)(jsx_runtime_1.Fragment, {}), url: '' };
|
|
378
|
+
}
|
|
379
|
+
};
|
|
380
|
+
exports.getFullDescription = getFullDescription;
|