@yeeyoon/library 2.2.0 → 2.2.1
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/components/Header/assets/bpm.svg +1 -1
- package/lib/components/Header/components/PlatformModal/index.jsx +15 -3
- package/lib/components/Header/components/ProductListMenu/index.jsx +15 -3
- package/lib/components/Header/index.jsx +11 -11
- package/lib/components/Notification/recent.jsx +1 -1
- package/package.json +1 -1
- package/src/pages/index.js +1 -1
@@ -1 +1 @@
|
|
1
|
-
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="
|
1
|
+
<?xml version="1.0" standalone="no"?><!DOCTYPE svg PUBLIC "-//W3C//DTD SVG 1.1//EN" "http://www.w3.org/Graphics/SVG/1.1/DTD/svg11.dtd"><svg t="1632654024999" class="icon" viewBox="0 0 1024 1024" version="1.1" xmlns="http://www.w3.org/2000/svg" p-id="3310" xmlns:xlink="http://www.w3.org/1999/xlink" width="32" height="32"><defs><style type="text/css"></style></defs><path d="M621.4144 214.528a351.9488 351.9488 0 0 0-288.7168-98.304h-0.256C170.752 135.7824 40.96 268.8 22.272 433.5616l49.5616 5.7856L0 628.5312l49.408-7.8848c43.0592 101.0176 130.3552 177.92 236.2368 206.1824 23.6032 8.0384 48.8448 12.288 74.6496 12.288h421.632c135.1168 0 244.5312-112.7424 242.0224-251.1872v-0.1024a240.2304 240.2304 0 0 0-45.5168-136.704 236.6976 236.6976 0 0 0-39.4752-43.52 248.6784 248.6784 0 0 0-163.4816-61.3376v49.4592l-96.8192-176.128-21.1968 36.2496a384.1024 384.1024 0 0 0-35.6864-41.0112l-0.2048-0.1536-0.1536-0.2048zM152.576 604.0064l43.9808-7.0144-124.7744-157.696 49.6128 5.8368C134.7584 327.168 228.352 231.3216 344.064 217.2416a253.2864 253.2864 0 0 1 208.0256 70.4512c19.456 19.456 35.9424 41.3696 48.5376 65.28l-23.7568 40.6016 198.6048 3.072V448c37.2736 0 72.192 13.824 98.7136 37.0688l0.256 0.256 0.3072 0.2048c8.4992 7.2704 16.1792 15.7184 22.8864 25.2416l0.2048 0.256 0.1536 0.256c6.6048 9.1136 11.776 18.1248 15.36 27.136l0.2048 0.4096 0.1536 0.4096c6.4 15.1552 10.0864 32.1024 10.4448 50.6368 1.4848 81.2544-62.72 147.5072-142.2336 147.5072H360.2944c-15.4624 0-30.464-2.6112-44.2368-7.424l-1.8432-0.6656-1.8944-0.512a258.3552 258.3552 0 0 1-159.6928-124.7232z" fill="#02B6CE" p-id="3311"></path></svg>
|
@@ -8,31 +8,43 @@ import ls from 'local-storage';
|
|
8
8
|
const PlatformModal = (props) => {
|
9
9
|
const { platforms, redirectUrl, tenantId } = props;
|
10
10
|
const enterProductDetail = (plat) => {
|
11
|
+
let _link = document.createElement('a');
|
12
|
+
let link = document.body.appendChild(_link);
|
13
|
+
link.setAttribute('target', '_blank');
|
11
14
|
if (plat.code == '20210811003') {
|
12
|
-
|
15
|
+
link.setAttribute(
|
16
|
+
'href',
|
13
17
|
`${plat.forwardDomainName}?token=${ls.get(
|
14
18
|
'X-Auth-Token'
|
15
19
|
)}&userId=${ls.get('X-Auth-Id')}&tenantId=${tenantId}`
|
16
20
|
);
|
21
|
+
link.click();
|
17
22
|
} else {
|
18
23
|
getSystemToken(plat);
|
19
24
|
}
|
20
25
|
};
|
21
26
|
const getSystemToken = async (plat) => {
|
27
|
+
let _link = document.createElement('a');
|
28
|
+
let link = document.body.appendChild(_link);
|
29
|
+
link.setAttribute('target', '_blank');
|
22
30
|
const resp = await fetchSystemToken({ platformId: plat.id });
|
23
31
|
const { success, data } = resp;
|
24
32
|
if (success) {
|
25
33
|
const { token, ...rest } = data;
|
26
34
|
if (redirectUrl) {
|
27
|
-
|
35
|
+
link.setAttribute(
|
36
|
+
'href',
|
28
37
|
`${redirectUrl}?token=${token}&userId=${rest.userId}&tenantId=${tenantId}`
|
29
38
|
);
|
39
|
+
link.click();
|
30
40
|
} else if (plat.forwardDomainName) {
|
31
|
-
|
41
|
+
link.setAttribute(
|
42
|
+
'href',
|
32
43
|
`${plat.forwardDomainName}?token=${token}&userInfo=${JSON.stringify(
|
33
44
|
rest
|
34
45
|
)}&tenantId=${tenantId}`
|
35
46
|
);
|
47
|
+
link.click();
|
36
48
|
} else {
|
37
49
|
message.error('该系统尚未开发,敬请期待');
|
38
50
|
return;
|
@@ -16,12 +16,17 @@ const ProductListMenu = (props) => {
|
|
16
16
|
const [platModal, setPlatModal] = useState(false);
|
17
17
|
const [platforms, setPlatforms] = useState([]);
|
18
18
|
const enterDetail = (item) => {
|
19
|
+
let _link = document.createElement('a');
|
20
|
+
let link = document.body.appendChild(_link);
|
21
|
+
link.setAttribute('target', '_blank');
|
19
22
|
if (item.code == 200000729) {
|
20
|
-
|
23
|
+
link.setAttribute(
|
24
|
+
'href',
|
21
25
|
`${getCollabRedirectUrl()}?token=${ls.get(
|
22
26
|
'X-Auth-Token'
|
23
27
|
)}&tenantId=${tenantId}`
|
24
28
|
);
|
29
|
+
link.click();
|
25
30
|
} else if (item.platforms?.length > 1) {
|
26
31
|
setPlatModal(true);
|
27
32
|
setPlatforms(item.platforms);
|
@@ -32,11 +37,18 @@ const ProductListMenu = (props) => {
|
|
32
37
|
const getSystemToken = async (item) => {
|
33
38
|
const resp = await fetchSystemToken({ platformId: item.id });
|
34
39
|
const { success, data } = resp;
|
40
|
+
let _link = document.createElement('a');
|
41
|
+
let link = document.body.appendChild(_link);
|
42
|
+
link.setAttribute('target', '_blank');
|
35
43
|
if (success) {
|
36
44
|
const { token, ...rest } = data;
|
37
|
-
|
38
|
-
|
45
|
+
link.setAttribute(
|
46
|
+
'href',
|
47
|
+
`${item.forwardDomainName}?token=${token}&userInfo=${JSON.stringify(
|
48
|
+
rest
|
49
|
+
)}&tenantId=${tenantId}`
|
39
50
|
);
|
51
|
+
link.click();
|
40
52
|
}
|
41
53
|
};
|
42
54
|
return (
|
@@ -224,7 +224,7 @@ const Header = (props) => {
|
|
224
224
|
</span>
|
225
225
|
</div>
|
226
226
|
<div className={styles['comp-header__right-content']}>
|
227
|
-
{/* <Tooltip title="
|
227
|
+
{/* <Tooltip title="工作台" className={styles['comp-header__icon']}> */}
|
228
228
|
<span className={styles['comp-header__icon']}>
|
229
229
|
<FundProjectionScreenOutlined
|
230
230
|
style={{ fontSize: '20px', color: 'rgba(0, 0, 0, .85)' }}
|
@@ -232,18 +232,9 @@ const Header = (props) => {
|
|
232
232
|
window.location.href = `${HOST_PROFILE_DASH_BOARD}?token=${token}`;
|
233
233
|
}}
|
234
234
|
/>
|
235
|
-
 
|
235
|
+
工作台
|
236
236
|
</span>
|
237
237
|
{/* </Tooltip> */}
|
238
|
-
{systemUserInfo && (
|
239
|
-
<Notification
|
240
|
-
customStyles={{
|
241
|
-
icon: { height: '62px', display: 'flex' },
|
242
|
-
list: { top: '44px' },
|
243
|
-
}}
|
244
|
-
userInfo={systemUserInfo}
|
245
|
-
/>
|
246
|
-
)}
|
247
238
|
{/* <Tooltip title="任务中心" className={styles['comp-header__icon']}> */}
|
248
239
|
<span className={styles['comp-header__icon']}>
|
249
240
|
<BarsOutlined
|
@@ -256,6 +247,15 @@ const Header = (props) => {
|
|
256
247
|
任务中心
|
257
248
|
</span>
|
258
249
|
{/* </Tooltip> */}
|
250
|
+
{systemUserInfo && (
|
251
|
+
<Notification
|
252
|
+
customStyles={{
|
253
|
+
icon: { height: '62px', display: 'flex' },
|
254
|
+
list: { top: '44px' },
|
255
|
+
}}
|
256
|
+
userInfo={systemUserInfo}
|
257
|
+
/>
|
258
|
+
)}
|
259
259
|
<Divider type="vertical" />
|
260
260
|
{userInfo && (
|
261
261
|
<>
|
@@ -3,7 +3,7 @@ import PropTypes from 'prop-types';
|
|
3
3
|
import moment from 'moment';
|
4
4
|
import qs from 'qs';
|
5
5
|
|
6
|
-
import { Badge, Button,
|
6
|
+
import { Badge, Button, notification } from 'antd';
|
7
7
|
import { BellOutlined } from '@ant-design/icons';
|
8
8
|
import ProList from '@ant-design/pro-list';
|
9
9
|
|
package/package.json
CHANGED
package/src/pages/index.js
CHANGED
@@ -7,7 +7,7 @@ export default function () {
|
|
7
7
|
return (
|
8
8
|
<>
|
9
9
|
<Header
|
10
|
-
productName="
|
10
|
+
productName="profile"
|
11
11
|
tenantId="053a033a063711ecb0c00c42a1ff8370"
|
12
12
|
token="ZmI1YzU4NzEyOTdlNDM2MTg2YjI0N2IyZGQzOGI3NDg1NDE2MzI2MjU4NjMzNzY="
|
13
13
|
avatar="https://demo-yeeyoon-fm.oss-cn-zhangjiakou.aliyuncs.com/userCenter/userAvatar/user_avatar2.png"
|