namirasoft-account-react 1.3.77 → 1.3.78
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/config-overrides.js +72 -72
- package/dist/App.css +57 -0
- package/dist/IAccountProps.d.ts +22 -0
- package/dist/IAccountProps.js +3 -0
- package/dist/IAccountProps.js.map +10 -0
- package/dist/IRouterMaker.d.ts +8 -0
- package/dist/IRouterMaker.js +3 -0
- package/dist/IRouterMaker.js.map +1 -0
- package/dist/IRouterState.d.ts +5 -0
- package/dist/IRouterState.js +3 -0
- package/dist/IRouterState.js.map +1 -0
- package/dist/IStorageCookie.d.ts +10 -0
- package/dist/IStorageCookie.js +27 -0
- package/dist/IStorageCookie.js.map +1 -0
- package/dist/Messenger.d.ts +16 -0
- package/dist/Messenger.js +78 -0
- package/dist/Messenger.js.map +1 -0
- package/dist/Notification.d.ts +6 -0
- package/dist/Notification.js +3 -0
- package/dist/Notification.js.map +1 -0
- package/dist/NotificationType.d.ts +6 -0
- package/dist/NotificationType.js +11 -0
- package/dist/NotificationType.js.map +1 -0
- package/dist/RouterMaker.d.ts +25 -0
- package/dist/RouterMaker.js +125 -0
- package/dist/RouterMaker.js.map +1 -0
- package/dist/RouterMaker.jsx +118 -0
- package/dist/RouterMaker.jsx.map +1 -0
- package/dist/components/NSALayoutAction.d.ts +17 -0
- package/dist/components/NSALayoutAction.js +6 -0
- package/dist/components/NSALayoutAction.js.map +1 -0
- package/dist/components/NSALayoutAction.module.css +0 -0
- package/dist/components/NSAMessageDialog.module.css +62 -62
- package/dist/index.css +0 -0
- package/dist/layouts/NSALayoutList.d.ts +17 -0
- package/dist/layouts/NSALayoutList.js +19 -0
- package/dist/layouts/NSALayoutList.js.map +1 -0
- package/dist/layouts/NSASectionList.js +1 -1
- package/dist/layouts/NSASectionList.js.map +1 -1
- package/dist/layouts/NSASectionNew.d.ts +9 -0
- package/dist/layouts/NSASectionNew.js +5 -0
- package/dist/layouts/NSASectionNew.js.map +1 -0
- package/dist/pages/NSALoginPage.module.css +19 -19
- package/package.json +64 -64
- package/public/index.html +21 -21
- package/src/App.css +56 -56
- package/src/App.tsx +10 -10
- package/src/IEntityInfo.ts +23 -23
- package/src/INSARouterMaker.ts +8 -8
- package/src/INSARouterProps.ts +17 -17
- package/src/INSARouterState.ts +5 -5
- package/src/Info.ts +20 -20
- package/src/NSARouterMaker.tsx +138 -138
- package/src/components/NSADeleteModal.tsx +24 -24
- package/src/components/NSAMessageDialog.module.css +62 -62
- package/src/components/NSAMessageDialog.tsx +65 -65
- package/src/index.tsx +7 -7
- package/src/layouts/Actions.ts +92 -92
- package/src/layouts/NSALayout.tsx +193 -193
- package/src/layouts/NSASectionEdit.tsx +97 -97
- package/src/layouts/NSASectionList.tsx +105 -105
- package/src/layouts/NSASectionTabs.tsx +36 -36
- package/src/layouts/NSASectionView.tsx +15 -15
- package/src/main.ts +16 -16
- package/src/pages/NSALoginPage.module.css +19 -19
- package/src/pages/NSALoginPage.tsx +37 -37
- package/tsconfig.json +43 -43
|
@@ -1,63 +1,63 @@
|
|
|
1
|
-
.nsa_message_icon {
|
|
2
|
-
cursor: pointer;
|
|
3
|
-
}
|
|
4
|
-
|
|
5
|
-
.nsa_message_title {
|
|
6
|
-
color: hsla(212, 100%, 51%, 1)
|
|
7
|
-
}
|
|
8
|
-
|
|
9
|
-
.nsa_message_item_title {
|
|
10
|
-
color: hsla(234, 64%, 22%, 1);
|
|
11
|
-
display: flex;
|
|
12
|
-
align-items: center;
|
|
13
|
-
gap: 8px;
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.nsa_message_item_content {
|
|
17
|
-
color: hsla(234, 64%, 22%, 1);
|
|
18
|
-
margin: 0;
|
|
19
|
-
}
|
|
20
|
-
|
|
21
|
-
.nsa_message_item_dot_green {
|
|
22
|
-
width: 8px;
|
|
23
|
-
height: 8px;
|
|
24
|
-
background: hsla(157, 94%, 42%, 1);
|
|
25
|
-
border-radius: 50%;
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.nsa_message_item_dot_gray {
|
|
29
|
-
width: 8px;
|
|
30
|
-
height: 8px;
|
|
31
|
-
background: hsla(228, 9%, 66%, 1);
|
|
32
|
-
border-radius: 50%;
|
|
33
|
-
}
|
|
34
|
-
|
|
35
|
-
.nsa_body_green {
|
|
36
|
-
background-color: hsla(157, 94%, 42%, 0.1);
|
|
37
|
-
padding: 16px;
|
|
38
|
-
}
|
|
39
|
-
|
|
40
|
-
.nsa_body_gray {
|
|
41
|
-
background-color: #fff;
|
|
42
|
-
padding: 16px;
|
|
43
|
-
box-shadow: 0px 2px 5px #e6e6e6;
|
|
44
|
-
}
|
|
45
|
-
|
|
46
|
-
.nsa_count {
|
|
47
|
-
position: absolute;
|
|
48
|
-
background: rgba(3, 119, 255, 1);
|
|
49
|
-
right: -5px;
|
|
50
|
-
top: -5px;
|
|
51
|
-
color: #fff;
|
|
52
|
-
width: 18px;
|
|
53
|
-
height: 18px;
|
|
54
|
-
border-radius: 50%;
|
|
55
|
-
display: flex;
|
|
56
|
-
justify-content: center;
|
|
57
|
-
align-items: center;
|
|
58
|
-
}
|
|
59
|
-
|
|
60
|
-
.nsa_parent_count {
|
|
61
|
-
position: relative;
|
|
62
|
-
width: max-content;
|
|
1
|
+
.nsa_message_icon {
|
|
2
|
+
cursor: pointer;
|
|
3
|
+
}
|
|
4
|
+
|
|
5
|
+
.nsa_message_title {
|
|
6
|
+
color: hsla(212, 100%, 51%, 1)
|
|
7
|
+
}
|
|
8
|
+
|
|
9
|
+
.nsa_message_item_title {
|
|
10
|
+
color: hsla(234, 64%, 22%, 1);
|
|
11
|
+
display: flex;
|
|
12
|
+
align-items: center;
|
|
13
|
+
gap: 8px;
|
|
14
|
+
}
|
|
15
|
+
|
|
16
|
+
.nsa_message_item_content {
|
|
17
|
+
color: hsla(234, 64%, 22%, 1);
|
|
18
|
+
margin: 0;
|
|
19
|
+
}
|
|
20
|
+
|
|
21
|
+
.nsa_message_item_dot_green {
|
|
22
|
+
width: 8px;
|
|
23
|
+
height: 8px;
|
|
24
|
+
background: hsla(157, 94%, 42%, 1);
|
|
25
|
+
border-radius: 50%;
|
|
26
|
+
}
|
|
27
|
+
|
|
28
|
+
.nsa_message_item_dot_gray {
|
|
29
|
+
width: 8px;
|
|
30
|
+
height: 8px;
|
|
31
|
+
background: hsla(228, 9%, 66%, 1);
|
|
32
|
+
border-radius: 50%;
|
|
33
|
+
}
|
|
34
|
+
|
|
35
|
+
.nsa_body_green {
|
|
36
|
+
background-color: hsla(157, 94%, 42%, 0.1);
|
|
37
|
+
padding: 16px;
|
|
38
|
+
}
|
|
39
|
+
|
|
40
|
+
.nsa_body_gray {
|
|
41
|
+
background-color: #fff;
|
|
42
|
+
padding: 16px;
|
|
43
|
+
box-shadow: 0px 2px 5px #e6e6e6;
|
|
44
|
+
}
|
|
45
|
+
|
|
46
|
+
.nsa_count {
|
|
47
|
+
position: absolute;
|
|
48
|
+
background: rgba(3, 119, 255, 1);
|
|
49
|
+
right: -5px;
|
|
50
|
+
top: -5px;
|
|
51
|
+
color: #fff;
|
|
52
|
+
width: 18px;
|
|
53
|
+
height: 18px;
|
|
54
|
+
border-radius: 50%;
|
|
55
|
+
display: flex;
|
|
56
|
+
justify-content: center;
|
|
57
|
+
align-items: center;
|
|
58
|
+
}
|
|
59
|
+
|
|
60
|
+
.nsa_parent_count {
|
|
61
|
+
position: relative;
|
|
62
|
+
width: max-content;
|
|
63
63
|
}
|
|
@@ -1,66 +1,66 @@
|
|
|
1
|
-
import { Component } from 'react';
|
|
2
|
-
import messageHeader from '../assets/images/icon-notification-header.png';
|
|
3
|
-
import Styles from './NSAMessageDialog.module.css';
|
|
4
|
-
import Toast from 'react-bootstrap/Toast';
|
|
5
|
-
import { NSButtonBlue } from "namirasoft-site-react";
|
|
6
|
-
|
|
7
|
-
export interface NSAMessageDialogProps
|
|
8
|
-
{ }
|
|
9
|
-
|
|
10
|
-
export interface NSAMessageDialogState
|
|
11
|
-
{
|
|
12
|
-
show: boolean;
|
|
13
|
-
}
|
|
14
|
-
|
|
15
|
-
export class NSAMessageDialog extends Component<NSAMessageDialogProps, NSAMessageDialogState>
|
|
16
|
-
{
|
|
17
|
-
constructor(props: NSAMessageDialogProps)
|
|
18
|
-
{
|
|
19
|
-
super(props);
|
|
20
|
-
this.state = { show: false };
|
|
21
|
-
this.show = this.show.bind(this);
|
|
22
|
-
this.hide = this.hide.bind(this);
|
|
23
|
-
}
|
|
24
|
-
show()
|
|
25
|
-
{
|
|
26
|
-
this.setState({ show: true });
|
|
27
|
-
}
|
|
28
|
-
hide()
|
|
29
|
-
{
|
|
30
|
-
this.setState({ show: false });
|
|
31
|
-
}
|
|
32
|
-
override render()
|
|
33
|
-
{
|
|
34
|
-
return (
|
|
35
|
-
<Toast show={this.state.show} onClose={this.hide}>
|
|
36
|
-
<Toast.Header>
|
|
37
|
-
<div>
|
|
38
|
-
<img
|
|
39
|
-
src={messageHeader}
|
|
40
|
-
alt="messageHeader"
|
|
41
|
-
width={22}
|
|
42
|
-
/>
|
|
43
|
-
<span className={`${Styles.nsa_message_title} ms-2`}>Mark All As Read</span>
|
|
44
|
-
</div>
|
|
45
|
-
</Toast.Header>
|
|
46
|
-
<Toast.Body>
|
|
47
|
-
<div className={Styles.nsa_body_green}>
|
|
48
|
-
<h3 className={`${Styles.nsa_message_item_title} nsa_font_16_bold`}>
|
|
49
|
-
<div className={`${Styles.nsa_message_item_dot_green}`}></div>
|
|
50
|
-
You’ve Unlocked Our Gold Membership!</h3>
|
|
51
|
-
<p className={`${Styles.nsa_message_item_content} nsa_font_13_normal`}>Learn More!</p>
|
|
52
|
-
</div>
|
|
53
|
-
<div className={Styles.nsa_body_gray}>
|
|
54
|
-
<h3 className={`${Styles.nsa_message_item_title} nsa_font_16_bold`}>
|
|
55
|
-
<div className={`${Styles.nsa_message_item_dot_gray}`}></div>
|
|
56
|
-
You’ve Unlocked Our Gold Membership!</h3>
|
|
57
|
-
<p className={`${Styles.nsa_message_item_content} nsa_font_13_normal`}>Learn More!</p>
|
|
58
|
-
</div>
|
|
59
|
-
<div className='p-3 mx-0 d-flex justify-content-center'>
|
|
60
|
-
<NSButtonBlue onClick={() => { }} title='View All' />
|
|
61
|
-
</div>
|
|
62
|
-
</Toast.Body>
|
|
63
|
-
</Toast>
|
|
64
|
-
);
|
|
65
|
-
}
|
|
1
|
+
import { Component } from 'react';
|
|
2
|
+
import messageHeader from '../assets/images/icon-notification-header.png';
|
|
3
|
+
import Styles from './NSAMessageDialog.module.css';
|
|
4
|
+
import Toast from 'react-bootstrap/Toast';
|
|
5
|
+
import { NSButtonBlue } from "namirasoft-site-react";
|
|
6
|
+
|
|
7
|
+
export interface NSAMessageDialogProps
|
|
8
|
+
{ }
|
|
9
|
+
|
|
10
|
+
export interface NSAMessageDialogState
|
|
11
|
+
{
|
|
12
|
+
show: boolean;
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
export class NSAMessageDialog extends Component<NSAMessageDialogProps, NSAMessageDialogState>
|
|
16
|
+
{
|
|
17
|
+
constructor(props: NSAMessageDialogProps)
|
|
18
|
+
{
|
|
19
|
+
super(props);
|
|
20
|
+
this.state = { show: false };
|
|
21
|
+
this.show = this.show.bind(this);
|
|
22
|
+
this.hide = this.hide.bind(this);
|
|
23
|
+
}
|
|
24
|
+
show()
|
|
25
|
+
{
|
|
26
|
+
this.setState({ show: true });
|
|
27
|
+
}
|
|
28
|
+
hide()
|
|
29
|
+
{
|
|
30
|
+
this.setState({ show: false });
|
|
31
|
+
}
|
|
32
|
+
override render()
|
|
33
|
+
{
|
|
34
|
+
return (
|
|
35
|
+
<Toast show={this.state.show} onClose={this.hide}>
|
|
36
|
+
<Toast.Header>
|
|
37
|
+
<div>
|
|
38
|
+
<img
|
|
39
|
+
src={messageHeader}
|
|
40
|
+
alt="messageHeader"
|
|
41
|
+
width={22}
|
|
42
|
+
/>
|
|
43
|
+
<span className={`${Styles.nsa_message_title} ms-2`}>Mark All As Read</span>
|
|
44
|
+
</div>
|
|
45
|
+
</Toast.Header>
|
|
46
|
+
<Toast.Body>
|
|
47
|
+
<div className={Styles.nsa_body_green}>
|
|
48
|
+
<h3 className={`${Styles.nsa_message_item_title} nsa_font_16_bold`}>
|
|
49
|
+
<div className={`${Styles.nsa_message_item_dot_green}`}></div>
|
|
50
|
+
You’ve Unlocked Our Gold Membership!</h3>
|
|
51
|
+
<p className={`${Styles.nsa_message_item_content} nsa_font_13_normal`}>Learn More!</p>
|
|
52
|
+
</div>
|
|
53
|
+
<div className={Styles.nsa_body_gray}>
|
|
54
|
+
<h3 className={`${Styles.nsa_message_item_title} nsa_font_16_bold`}>
|
|
55
|
+
<div className={`${Styles.nsa_message_item_dot_gray}`}></div>
|
|
56
|
+
You’ve Unlocked Our Gold Membership!</h3>
|
|
57
|
+
<p className={`${Styles.nsa_message_item_content} nsa_font_13_normal`}>Learn More!</p>
|
|
58
|
+
</div>
|
|
59
|
+
<div className='p-3 mx-0 d-flex justify-content-center'>
|
|
60
|
+
<NSButtonBlue onClick={() => { }} title='View All' />
|
|
61
|
+
</div>
|
|
62
|
+
</Toast.Body>
|
|
63
|
+
</Toast>
|
|
64
|
+
);
|
|
65
|
+
}
|
|
66
66
|
}
|
package/src/index.tsx
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import ReactDOM from 'react-dom/client';
|
|
2
|
-
import './index.css';
|
|
3
|
-
import { App } from './App';
|
|
4
|
-
|
|
5
|
-
const root = ReactDOM.createRoot(
|
|
6
|
-
document.getElementById('root') as HTMLElement
|
|
7
|
-
);
|
|
1
|
+
import ReactDOM from 'react-dom/client';
|
|
2
|
+
import './index.css';
|
|
3
|
+
import { App } from './App';
|
|
4
|
+
|
|
5
|
+
const root = ReactDOM.createRoot(
|
|
6
|
+
document.getElementById('root') as HTMLElement
|
|
7
|
+
);
|
|
8
8
|
root.render(<App />);
|
package/src/layouts/Actions.ts
CHANGED
|
@@ -1,93 +1,93 @@
|
|
|
1
|
-
import { INSActionMenuProps } from "namirasoft-site-react";
|
|
2
|
-
import { INSARouterProps } from "../INSARouterProps";
|
|
3
|
-
import { IEntityInfo } from "../IEntityInfo";
|
|
4
|
-
|
|
5
|
-
export class Actions
|
|
6
|
-
{
|
|
7
|
-
static apply(handler: () => void): INSActionMenuProps
|
|
8
|
-
{
|
|
9
|
-
return {
|
|
10
|
-
id: "0",
|
|
11
|
-
menu_item: "Apply",
|
|
12
|
-
handler,
|
|
13
|
-
isActive() { return true; }
|
|
14
|
-
}
|
|
15
|
-
}
|
|
16
|
-
static new(props: INSARouterProps, entity: IEntityInfo<any>): INSActionMenuProps
|
|
17
|
-
{
|
|
18
|
-
return {
|
|
19
|
-
id: "1",
|
|
20
|
-
menu_item: "New",
|
|
21
|
-
handler: () =>
|
|
22
|
-
{
|
|
23
|
-
let link = props.url.getLink(entity.client.getNewURL(), {});
|
|
24
|
-
window.open(link, "_blank");
|
|
25
|
-
},
|
|
26
|
-
isActive() { return true; }
|
|
27
|
-
};
|
|
28
|
-
}
|
|
29
|
-
static view(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
30
|
-
{
|
|
31
|
-
return {
|
|
32
|
-
id: "2",
|
|
33
|
-
menu_item: "View",
|
|
34
|
-
handler: () =>
|
|
35
|
-
{
|
|
36
|
-
let ids = getIDs();
|
|
37
|
-
let link = props.url.getLink(entity.client.getViewURL(ids[0]), {});
|
|
38
|
-
window.open(link, "_blank");
|
|
39
|
-
},
|
|
40
|
-
isActive() { return getIDs().length == 1; }
|
|
41
|
-
};
|
|
42
|
-
}
|
|
43
|
-
static viewHistory(getIDs: () => string[]): INSActionMenuProps
|
|
44
|
-
{
|
|
45
|
-
return {
|
|
46
|
-
id: "3",
|
|
47
|
-
menu_item: "View History",
|
|
48
|
-
handler: () =>
|
|
49
|
-
{
|
|
50
|
-
let link = "https://history.namirasoft.com/history/view?id=" + getIDs()[0];
|
|
51
|
-
window.open(link, "_blank");
|
|
52
|
-
},
|
|
53
|
-
isActive() { return getIDs().length == 1; }
|
|
54
|
-
};
|
|
55
|
-
}
|
|
56
|
-
static copy(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
57
|
-
{
|
|
58
|
-
return {
|
|
59
|
-
id: "4",
|
|
60
|
-
menu_item: "Copy",
|
|
61
|
-
handler: () =>
|
|
62
|
-
{
|
|
63
|
-
let ids = getIDs();
|
|
64
|
-
let link = props.url.getLink(entity.client.getCopyURL(ids[0]), {});
|
|
65
|
-
window.open(link, "_blank");
|
|
66
|
-
},
|
|
67
|
-
isActive() { return getIDs().length == 1; }
|
|
68
|
-
};
|
|
69
|
-
}
|
|
70
|
-
static edit(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
71
|
-
{
|
|
72
|
-
return {
|
|
73
|
-
id: "5",
|
|
74
|
-
menu_item: "Edit",
|
|
75
|
-
handler: () =>
|
|
76
|
-
{
|
|
77
|
-
let ids = getIDs();
|
|
78
|
-
let link = props.url.getLink(entity.client.getEditURL(ids[0]), {});
|
|
79
|
-
window.open(link, "_blank");
|
|
80
|
-
},
|
|
81
|
-
isActive() { return getIDs().length == 1; }
|
|
82
|
-
};
|
|
83
|
-
}
|
|
84
|
-
static delete(getIDs: () => string[], showDeleteModal: () => void): INSActionMenuProps
|
|
85
|
-
{
|
|
86
|
-
return {
|
|
87
|
-
id: "6",
|
|
88
|
-
menu_item: "Delete",
|
|
89
|
-
handler: showDeleteModal,
|
|
90
|
-
isActive() { return getIDs().length != 0; }
|
|
91
|
-
}
|
|
92
|
-
}
|
|
1
|
+
import { INSActionMenuProps } from "namirasoft-site-react";
|
|
2
|
+
import { INSARouterProps } from "../INSARouterProps";
|
|
3
|
+
import { IEntityInfo } from "../IEntityInfo";
|
|
4
|
+
|
|
5
|
+
export class Actions
|
|
6
|
+
{
|
|
7
|
+
static apply(handler: () => void): INSActionMenuProps
|
|
8
|
+
{
|
|
9
|
+
return {
|
|
10
|
+
id: "0",
|
|
11
|
+
menu_item: "Apply",
|
|
12
|
+
handler,
|
|
13
|
+
isActive() { return true; }
|
|
14
|
+
}
|
|
15
|
+
}
|
|
16
|
+
static new(props: INSARouterProps, entity: IEntityInfo<any>): INSActionMenuProps
|
|
17
|
+
{
|
|
18
|
+
return {
|
|
19
|
+
id: "1",
|
|
20
|
+
menu_item: "New",
|
|
21
|
+
handler: () =>
|
|
22
|
+
{
|
|
23
|
+
let link = props.url.getLink(entity.client.getNewURL(), {});
|
|
24
|
+
window.open(link, "_blank");
|
|
25
|
+
},
|
|
26
|
+
isActive() { return true; }
|
|
27
|
+
};
|
|
28
|
+
}
|
|
29
|
+
static view(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
30
|
+
{
|
|
31
|
+
return {
|
|
32
|
+
id: "2",
|
|
33
|
+
menu_item: "View",
|
|
34
|
+
handler: () =>
|
|
35
|
+
{
|
|
36
|
+
let ids = getIDs();
|
|
37
|
+
let link = props.url.getLink(entity.client.getViewURL(ids[0]), {});
|
|
38
|
+
window.open(link, "_blank");
|
|
39
|
+
},
|
|
40
|
+
isActive() { return getIDs().length == 1; }
|
|
41
|
+
};
|
|
42
|
+
}
|
|
43
|
+
static viewHistory(getIDs: () => string[]): INSActionMenuProps
|
|
44
|
+
{
|
|
45
|
+
return {
|
|
46
|
+
id: "3",
|
|
47
|
+
menu_item: "View History",
|
|
48
|
+
handler: () =>
|
|
49
|
+
{
|
|
50
|
+
let link = "https://history.namirasoft.com/history/view?id=" + getIDs()[0];
|
|
51
|
+
window.open(link, "_blank");
|
|
52
|
+
},
|
|
53
|
+
isActive() { return getIDs().length == 1; }
|
|
54
|
+
};
|
|
55
|
+
}
|
|
56
|
+
static copy(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
57
|
+
{
|
|
58
|
+
return {
|
|
59
|
+
id: "4",
|
|
60
|
+
menu_item: "Copy",
|
|
61
|
+
handler: () =>
|
|
62
|
+
{
|
|
63
|
+
let ids = getIDs();
|
|
64
|
+
let link = props.url.getLink(entity.client.getCopyURL(ids[0]), {});
|
|
65
|
+
window.open(link, "_blank");
|
|
66
|
+
},
|
|
67
|
+
isActive() { return getIDs().length == 1; }
|
|
68
|
+
};
|
|
69
|
+
}
|
|
70
|
+
static edit(props: INSARouterProps, entity: IEntityInfo<any>, getIDs: () => string[]): INSActionMenuProps
|
|
71
|
+
{
|
|
72
|
+
return {
|
|
73
|
+
id: "5",
|
|
74
|
+
menu_item: "Edit",
|
|
75
|
+
handler: () =>
|
|
76
|
+
{
|
|
77
|
+
let ids = getIDs();
|
|
78
|
+
let link = props.url.getLink(entity.client.getEditURL(ids[0]), {});
|
|
79
|
+
window.open(link, "_blank");
|
|
80
|
+
},
|
|
81
|
+
isActive() { return getIDs().length == 1; }
|
|
82
|
+
};
|
|
83
|
+
}
|
|
84
|
+
static delete(getIDs: () => string[], showDeleteModal: () => void): INSActionMenuProps
|
|
85
|
+
{
|
|
86
|
+
return {
|
|
87
|
+
id: "6",
|
|
88
|
+
menu_item: "Delete",
|
|
89
|
+
handler: showDeleteModal,
|
|
90
|
+
isActive() { return getIDs().length != 0; }
|
|
91
|
+
}
|
|
92
|
+
}
|
|
93
93
|
}
|