@yeeyoon/library 3.7.2 → 3.7.5

Sign up to get free protection for your applications and to get access to all the features.
@@ -51,9 +51,11 @@ export function getProfileRedirectUrl(path) {
51
51
  case 'localhost:8003':
52
52
  case 'localhost:8009':
53
53
  case 'localhost:8010':
54
+ case 'localhost:8011':
54
55
  case 'testing-collab.yeeyoon.com':
55
56
  case 'testing-profile.yeeyoon.com':
56
57
  case 'testing-bpm.yeeyoon.com':
58
+ case 'testing-wms.yeeyoon.com':
57
59
  return `https://testing-profile.yeeyoon.com/${path}`;
58
60
  case 'demo-profile.yeeyoon.com':
59
61
  return `https://demo-profile.yeeyoon.com/${path}`;
@@ -339,9 +339,10 @@ const Header = (props) => {
339
339
  onClick={() => {
340
340
  if (productName === 'wms' || productName === 'bpm') {
341
341
  window.location.href = `${HOST_PROFILE_TASK}?token=${token}&source=${productName}&tenantId=${tenantId}`;
342
+ } else {
343
+ setRedirectUrl(HOST_PROFILE_TASK);
344
+ setPlatformsModalShow(true);
342
345
  }
343
- setRedirectUrl(HOST_PROFILE_TASK);
344
- setPlatformsModalShow(true);
345
346
  }}
346
347
  >
347
348
  <IconTodo style={IconStyle} />
@@ -10,6 +10,8 @@ const TenantSelector = (props) => {
10
10
  tenantId,
11
11
  tenantIdChangeCb,
12
12
  appId,
13
+ isSharePlatform,
14
+ shareTenantIdList,
13
15
  // handleException,
14
16
  } = props;
15
17
  const [options, setOptions] = useState([]);
@@ -35,6 +37,11 @@ const TenantSelector = (props) => {
35
37
  value: item.id,
36
38
  });
37
39
  });
40
+ if (isSharePlatform) {
41
+ tenantList = tenantList.filter((item) =>
42
+ shareTenantIdList.includes(item.value)
43
+ );
44
+ }
38
45
  setOptions(tenantList);
39
46
  }
40
47
  };
@@ -64,8 +71,9 @@ const TenantSelector = (props) => {
64
71
  // }
65
72
  }}
66
73
  onSelect={(value, option) => {
67
- setValue(option.label);
68
- tenantIdChangeCb && tenantIdChangeCb(value, option);
74
+ const { label } = option;
75
+ setValue(label);
76
+ tenantIdChangeCb && tenantIdChangeCb(value, label, option);
69
77
  }}
70
78
  />
71
79
  );
@@ -76,6 +84,8 @@ TenantSelector.propTypes = {
76
84
  appId: PropTypes.string,
77
85
  tenantIdChangeCb: PropTypes.func,
78
86
  handleException: PropTypes.func,
87
+ shareTenantIdList: PropTypes.array,
88
+ isSharePlatform: PropTypes.bool,
79
89
  };
80
90
 
81
91
  export default TenantSelector;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yeeyoon/library",
3
- "version": "3.7.2",
3
+ "version": "3.7.5",
4
4
  "description": "宜云前端组件库和通用服务",
5
5
  "main": "index.js",
6
6
  "repository": {