@yqg/permission 1.3.2-alpha.0 → 1.3.2-alpha.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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@yqg/permission",
3
- "version": "1.3.2-alpha.0",
3
+ "version": "1.3.2-alpha.2",
4
4
  "main": "dist/index.js",
5
5
  "module": "dist/index.js",
6
6
  "type": "module",
package/src/App.vue CHANGED
@@ -6,22 +6,17 @@ import {Button} from 'ant-design-vue';
6
6
  type LocaleType = 'zh-CN' | 'en-US' | 'id-ID' | 'fil-PH';
7
7
 
8
8
  const color = ref<string>('#1677ff');
9
- const locale = ref<LocaleType>('zh-CN');
9
+ const locale = ref<LocaleType>('id-ID');
10
10
 
11
11
  const permissions = reactive([
12
- 'CRANE.PERMISSION.QUERY',
13
- 'CRANE.EMPLOYEE.QUERY',
14
- 'CRANE.EMPLOYEE.DETAIL_QUERY',
15
- 'CRANE.EMPLOYEE.ATTRIBUTE_CREATE',
16
- 'CRANE.EMPLOYEE.ROLE_ASSIGN',
17
- 'CRANE.EMPLOYEE.DEPARTMENT_ROLE.ATTRIBUTE_ROLE_CREATE',
12
+ 'yewei0313.REAQS.DEPAWED_ANQ2.QUERY',
18
13
  ]);
19
14
  // const permissions = reactive(['CRANE.BUSINESS.QUERY', 'RANE.BUSINESS.CREATE', 'CRANE.BUSINESS.UPDATE', 'CRANE.BUSINESS.DELETE']);
20
15
  const changeColor = () => {
21
16
  color.value = color.value === '#f00' ? '#1677ff' : '#f00';
22
17
  }
23
18
  const changeLocale = () => {
24
- locale.value = locale.value === 'zh-CN' ? 'en-US' : 'zh-CN';
19
+ locale.value = locale.value === 'id-ID' ? 'en-US' : 'id-ID';
25
20
  }
26
21
 
27
22
  </script>
@@ -36,7 +31,7 @@ const changeLocale = () => {
36
31
  <!-- 03541 -->
37
32
  <!-- 02124 -->
38
33
  <!-- 05184 -->
39
- <yqg-permission :permissions="permissions" workNumber="04697" :color="color" :locale="locale"
34
+ <yqg-permission :permissions="permissions" workNumber="03817" :color="color" :locale="locale"
40
35
  @onSuccess="() => {console.log('成功')}">
41
36
  </yqg-permission>
42
37
  </div>
@@ -9,7 +9,7 @@ type apiType = {
9
9
  export default {
10
10
  getPermissions: (params: any) => axios.get(`${urlPrefix}/permission/apply`, {params}),
11
11
 
12
- getFlowPreview: (params: any)=> axios.post(`${urlPrefix}/permission/apply/oa/flow/submit/preview`, params),
12
+ getFlowPreview: (params: any) => axios.post(`${urlPrefix}/permission/apply/oa/flow/submit/preview`, params),
13
13
 
14
14
  submitApply: (params: any) => axios.post(`${urlPrefix}/permission/apply/oa/flow/submit`, params),
15
15
 
@@ -1,6 +1,14 @@
1
1
  <template>
2
- <Modal v-model:open="open" :title="t('permissionApply')" width="1100px" @ok="handleOk" :okText="t('submit')"
3
- :maskClosable="false" :ok-button-props="{ loading: loading }" :cancelText="t('cancel')">
2
+ <Modal v-model:open="open" width="1100px" :maskClosable="false" :zIndex="zIndex">
3
+ <template #footer>
4
+ <Button @click="open = false" v-show="!isAllChecked && permissionList.length">{{ t('cancel') }}</Button>
5
+ <Button type="primary" @click="handleOk" :loading="loading">{{ t('submit') }}</Button>
6
+ </template>
7
+ <template #title>
8
+ <span>{{ t('permissionApply') }}</span>
9
+ <span v-show="isAllChecked && permissionList.length" class="crane-permission-title-tips">{{
10
+ t('isAllOwnTips') }}</span>
11
+ </template>
4
12
  <Form ref="formRef" :model="formState" :labelCol="{ span: 4 }" :wrapperCol="{ span: 19 }">
5
13
  <FormItem :label="t('applyPermission')" name="features"
6
14
  :rules="[{ required: true, message: t('selectPlaceholder') }]">
@@ -30,8 +38,8 @@
30
38
  max: 300, message: t('maxLengthTips', { length: 300 }), trigger: ['change', 'blur']
31
39
  }]">
32
40
  <Textarea v-model:value.trim="formState.applyReason" :placeholder="t('applyReasonPlaceholder')"
33
- :auto-size="{ minRows: 4, maxRows: 4 }">
34
- </Textarea>
41
+ :auto-size="{ minRows: 4, maxRows: 4 }" :disabled="isAllChecked || !permissionList.length">
42
+ </Textarea>
35
43
  <span class="reason-tips" style="font-size: 12px">
36
44
  {{ t('applyReasonTips') }}
37
45
  </span>
@@ -64,7 +72,8 @@ import {
64
72
  Textarea,
65
73
  message,
66
74
  Tree,
67
- Spin
75
+ Spin,
76
+ Button
68
77
  } from 'ant-design-vue';
69
78
  import SuccessModal from './success-modal.vue';
70
79
  import ApprovalSteps from './approval-steps.vue';
@@ -94,7 +103,19 @@ const props = defineProps({
94
103
  spining: {
95
104
  type: Boolean,
96
105
  default: false
97
- }
106
+ },
107
+ defaultCheckedIds: {
108
+ type: Array as PropType<string[]>,
109
+ default: () => []
110
+ },
111
+ isAllChecked: {
112
+ type: Boolean,
113
+ default: false
114
+ },
115
+ zIndex: {
116
+ type: Number,
117
+ default: 10000
118
+ },
98
119
 
99
120
  });
100
121
  const emit = defineEmits(['onSubmit', 'onSuccess']);
@@ -130,6 +151,10 @@ const getValidTimeOptions = async () => {
130
151
 
131
152
  getValidTimeOptions();
132
153
  const handleOk = async () => {
154
+ if (props.isAllChecked || !permissionList.value.length) {
155
+ open.value = false;
156
+ return;
157
+ }
133
158
  await Promise.all([formRef.value.validate(), categoryRef.value?.validate()])
134
159
  loading.value = true;
135
160
  const params = getParams();
@@ -161,7 +186,7 @@ const getParams = () => {
161
186
 
162
187
  });
163
188
  deepTree(permissionList.value, (item: any) => {
164
- if (!item.children && formState.features.includes(item.feature)) {
189
+ if (!item.children && formState.features.includes(item.feature) && !item.disabled) {
165
190
  roleVoList.push({
166
191
  roleId: item.roleId,
167
192
  validTime: item.validTime
@@ -188,20 +213,22 @@ const onChangeTime = throttle(async () => {
188
213
  if (params.roleVoList.length === 0) {
189
214
  stepNodes.value = [];
190
215
  return;
191
- }
216
+ };
217
+
192
218
  let res = await Http.getFlowPreview(params);
193
219
  stepNodes.value = res?.body?.nodes || [];
194
- }, 0)
220
+ }, 1)
195
221
  const onCheck = (checkedIds: any, info: any) => {
196
222
  // 如果选择的是子节点,判断是否超过5个,超过的话,删除当前选的节点,并给予提示
197
223
  // 如果选择的是父节点,判断是否超过5个,超过的话,从当前选择的父节点的叶子节点中删除多出的个数,并给予提示
198
224
  let total = 0;
199
225
  let curTotal = 0;
226
+
200
227
  deepTree(permissionList.value, (item: any) => {
201
- if (!item.children && checkedIds.includes(item.feature)) {
228
+ if (!item.children && checkedIds.includes(item.feature) && !item.disabled) {
202
229
  total += 1;
203
230
  }
204
- if (!item.children && formState.features.includes(item.feature)) {
231
+ if (!item.children && formState.features.includes(item.feature) && !item.disabled) {
205
232
  curTotal += 1;
206
233
  }
207
234
  if (!item.children && !formState.features.includes(item.feature)) {
@@ -257,6 +284,10 @@ watch(() => props.permissionList, (cur) => {
257
284
  })
258
285
  })
259
286
 
287
+ watch(() => props.defaultCheckedIds, (cur) => {
288
+ formState.features = cur.concat(formState.features);
289
+ }, { immediate: true })
290
+
260
291
  watch(() => open.value, (cur) => {
261
292
  if (cur) {
262
293
  formRef.value?.resetFields();
@@ -267,6 +298,13 @@ watch(() => open.value, (cur) => {
267
298
  </script>
268
299
 
269
300
  <style scoped>
301
+ .crane-permission-title-tips {
302
+ color: #FF4D4F;
303
+ font-size: 14px;
304
+ margin-left: 8px;
305
+ font-weight: 400;
306
+ }
307
+
270
308
  :deep(.yqg-permission-tree-list) {
271
309
  margin-top: 4px;
272
310
  }
@@ -34,10 +34,11 @@
34
34
 
35
35
  <Popover v-if="item.relatedCompleteNames?.length">
36
36
  <template #content>
37
- <div style="max-width: 400px;">
38
- {{ t('adaptDepartment') }}:{{item.relatedCompleteNames.map((item: any) => {
39
- return item;
40
- }).join('、')}}
37
+ <div class="crane-department-wraper">
38
+ <div>
39
+ {{ t('adaptDepartment') }}:
40
+ </div>
41
+ <div v-for="item in item.relatedCompleteNames">{{ item }}</div>
41
42
  </div>
42
43
  </template>
43
44
  <div class="crane-flex-center crane-margin-left-4">
@@ -67,7 +68,7 @@
67
68
  </Popover>
68
69
 
69
70
  <!-- 选择框 -->
70
- <span v-if="checkedKeys.includes(item.feature)" class="crane-weak-color crane-margin-left-12">
71
+ <span v-if="checkedKeys.includes(item.feature) && !item.disabled" class="crane-weak-color crane-margin-left-12">
71
72
  {{ t('availableTime') }}:
72
73
  <Select v-model:value="item.validTime" style="width: 100px"
73
74
  :disabled="item.businessApplyType === OWNER_STATUS"
@@ -145,6 +146,11 @@ const onChangeTimeHandler = () => {
145
146
 
146
147
  </script>
147
148
  <style scoped>
149
+ .crane-department-wraper {
150
+ max-width: 600px;
151
+ max-height: 300px;
152
+ overflow-y: scroll;
153
+ }
148
154
  .crane-flex-center {
149
155
  display: flex;
150
156
  align-items: center;
@@ -62,8 +62,9 @@
62
62
  </template>
63
63
  </div>
64
64
 
65
- <ApplyModal v-model="open" :permissionList="permissionList" :spining="loading" :workNumber="workNumber"
66
- @onSuccess="() => emit('onSuccess')" @onSubmit="getPermissions">
65
+ <ApplyModal v-model="open" :permissionList="permissionList" :spining="loading" :workNumber="workNumber" :zIndex="zIndex"
66
+ :defaultCheckedIds="defaultCheckedIds" :isAllChecked="isAllChecked" @onSuccess="() => emit('onSuccess')"
67
+ @onSubmit="getPermissions">
67
68
  </ApplyModal>
68
69
 
69
70
  </ConfigProvider>
@@ -124,12 +125,18 @@ const props = defineProps({
124
125
  top: {
125
126
  type: String,
126
127
  default: '100px'
127
- }
128
+ },
129
+ zIndex: {
130
+ type: Number,
131
+ default: 10000
132
+ },
128
133
  });
129
134
 
130
135
  const open = ref(false);
131
136
  const curApproving = ref<PermissionType>();
132
137
  const loading = ref(false);
138
+ const defaultCheckedIds = ref<string[]>([]);
139
+ const isAllChecked = ref(false);
133
140
  let permissionList = ref<PermissionListType>([]);
134
141
  let curStatus = ref<Record<string, any>>({
135
142
  imageUrl: noauthority,
@@ -163,7 +170,10 @@ const getPermissions = async () => {
163
170
 
164
171
  loading.value = true;
165
172
  const res = await Http.getPermissions(params);
166
- permissionList.value = useFormat(res.body || []);
173
+ const datalist = useFormat(res.body || []);
174
+ permissionList.value = datalist.data;
175
+ defaultCheckedIds.value = datalist.checkList;
176
+ isAllChecked.value = datalist.isAllChecked;
167
177
  curStatus.value = useStatus(permissionList.value, curApproving);
168
178
  loading.value = false;
169
179
  };
@@ -202,5 +212,4 @@ watch(() => props.locale, (cur, pre) => {
202
212
  .crane-margin-right10 {
203
213
  margin-right: 10px;
204
214
  }
205
- </style>
206
- ../hooks/useSort../hooks/useFormat
215
+ </style>
@@ -9,6 +9,8 @@ const StatusType = {
9
9
  TEMP_OWNER: 'TEMP_OWNER'
10
10
  }
11
11
  export default function useFormat(tree: PermissionListType) {
12
+ const checkList: string[] = [];
13
+ let allCount: number = 0;
12
14
  function sortTree(
13
15
  tree: PermissionListType,
14
16
  sortMap: Map<string | null, number>,
@@ -16,26 +18,33 @@ export default function useFormat(tree: PermissionListType) {
16
18
  ) {
17
19
  return tree.map((node) => {
18
20
  node.key = node.feature;
19
-
21
+ allCount++;
20
22
  if (!node.children || node.children.length === 0) {
21
23
  node.categoryVOS = (node.categoryVOS || []).filter((item: any) => item.configWay !== Category.AUTO);
22
24
 
23
- if ([StatusType.NO, StatusType.PENDING].includes(node.businessApplyType)) {
25
+ if ([StatusType.NO].includes(node.businessApplyType)) {
24
26
  node.disabled = true;
25
27
  }
26
28
 
27
- if ([StatusType.OWNER].includes(node.businessApplyType) && !node.categoryVOS.length) {
29
+ if (([StatusType.OWNER].includes(node.businessApplyType) && !node.categoryVOS.length) || [StatusType.PENDING].includes(node.businessApplyType)) {
28
30
  node.disabled = true;
31
+ checkList.push(node.feature);
29
32
  }
30
33
  } else {
31
34
  // 递归对子节点进行排序
32
35
  node.children = sortTree(node.children, sortMap, levelSortMap);
33
36
 
37
+ // 如果所有子节点都在 checkList 中,那么当前节点也加入 checkList
38
+ if (node.children.every((child) => checkList.includes(child.feature))) {
39
+ checkList.push(node.feature);
40
+ }
41
+
34
42
  // 检查所有子节点是否 `disabled === true`
35
43
  if (node.children.every((child) => child.disabled)) {
36
44
  node.disabled = true;
37
45
  }
38
- }
46
+ };
47
+
39
48
 
40
49
  return node;
41
50
  }).sort((a, b) => {
@@ -51,6 +60,10 @@ export default function useFormat(tree: PermissionListType) {
51
60
  const sortMap = new Map(sort.map((value, index) => [value, index]));
52
61
  const levelSortMap = new Map(levelSort.map((value, index) => [value, index]));
53
62
 
54
- return sortTree(tree, sortMap, levelSortMap);
63
+ return {
64
+ data: sortTree(tree, sortMap, levelSortMap),
65
+ checkList,
66
+ isAllChecked: allCount === checkList.length
67
+ };
55
68
  }
56
69
 
package/src/i18n/en-US.ts CHANGED
@@ -3,54 +3,55 @@ export default {
3
3
  applyPermission: 'Apply for Permission',
4
4
  applyReason: 'Application Reason',
5
5
  approvalProcess: 'Approval Process',
6
- applyReasonPlaceholder: 'Please describe the reason for application and usage scenarios in as much detail as possible. Avoid simply stating "work requirements" to prevent delays in the approval process.',
6
+ isAllOwnTips: 'The current page already has permission or is under approval, no need to apply',
7
+ applyReasonPlaceholder: 'Please describe your reason and usage scenario in detail. Avoid vague explanations like "work needs" to prevent delays in approval.',
7
8
  applyReasonTips: 'Example: Due to requirements of XX project, need to view/operate XXXX scenario/issue, which involves the use of XXX permission, hence submitting this application!',
8
9
  cancel: 'Cancel',
9
10
  submit: 'Confirm',
10
11
  close: 'Close',
11
12
  viewApprovalDetail: 'View Approval Details',
12
- applyMore: 'Apply for Other Permissions',
13
+ applyMore: 'Continue applying for other permissions',
13
14
  successTips: 'Application submitted. Relevant permissions will be granted upon approval.',
14
15
  resoultTitle: 'Operation Result Feedback',
15
- start: 'Initiate',
16
+ start: 'Start',
16
17
  end: 'End',
17
18
  noNeed: 'No Approval Required',
18
19
  adaptDepartment: 'Applicable Department',
19
- noApprovalProcess: 'No Approval Process',
20
- excessTips: 'Maximum {number} permissions can be applied for at once',
20
+ noApprovalProcess: 'No approval process required',
21
+ excessTips: 'You can apply for up to {number} permissions at a time',
21
22
  unavailableTips: 'You currently don\'t have permission to view/operate this page. Please click the button below to apply.',
22
- appliedTips: 'Permission has been applied, currently {status}...',
23
- unapplyTips: 'You don\'t have permission to view/operate this page, and there are no applicable permissions you can apply for in this page.',
23
+ appliedTips: 'Permission request submitted, currently {status}...',
24
+ unapplyTips: 'You dont have permission to view or operate this page. There are no available permissions to apply for.',
24
25
  callManager: 'If needed, please contact the system administrator',
25
26
  manager: 'System Administrator',
26
27
  availableTime: 'Validity Period',
27
- selectPlaceholder: 'Please select permission point',
28
- reasonPlaceholder: 'Please enter application reason',
28
+ selectPlaceholder: 'Please select permission points',
29
+ reasonPlaceholder: 'Please enter your reason for applying',
29
30
  pleaseChoose: 'Please select',
30
- maxCountTips: 'Maximum {count} permissions can be applied for at once',
31
- maxLengthTips: 'Maximum {length} characters',
31
+ maxCountTips: 'You can apply for up to {count} permissions at a time',
32
+ maxLengthTips: 'Up to {length} characters',
32
33
  today: 'Expires today',
33
34
  clickToApply: 'Click to apply for permission',
34
- noPermissionTips: 'No permission points under this menu',
35
+ noPermissionTips: 'There are no permission points under this menu, no need to apply',
35
36
  lastDays: '{count} days',
36
- categoryTips: 'Your current data scope is as follows:',
37
- empty: 'Empty',
37
+ categoryTips: 'Your current data scope:',
38
+ empty: 'None',
38
39
  category: 'Data Permission',
39
- categotySelectTips: 'The selected permission above includes data permissions. Please apply for/change the data scope according to actual work requirements.',
40
- categoryChangeTips: 'Reminder: The data permission scope you selected is relatively large! Please confirm whether your actual work scenario requires full access to 「{category}」permission, and clearly state it in the application reason to avoid rejection!',
40
+ categotySelectTips: 'The selected permissions include data scope settings. Please apply for or update the scope based on your actual needs.',
41
+ categoryChangeTips: 'Please verify whether full access to "{category}" is necessary for your role. Be sure to explain the use case clearly in your application to avoid rejection.',
41
42
  levels: {
42
43
  L1: 'Low',
43
44
  L2: 'Medium',
44
45
  L3: 'High',
45
46
  },
46
47
  status: {
47
- PENDING: 'Pending Approval',
48
- NO: 'Not Applicable',
49
- OWNER: 'Permanently Owned',
50
- TEMP_OWNER: 'Temporarily Owned',
48
+ PENDING: 'Under review',
49
+ NO: 'Not applicable for application',
50
+ OWNER: 'Permanent permission',
51
+ TEMP_OWNER: 'Temporary permission',
51
52
  },
52
53
  operationType: {
53
54
  QUERY: 'Query',
54
- MANAGE: 'Operation',
55
+ MANAGE: 'Action',
55
56
  }
56
57
  };
package/src/i18n/in-ID.ts CHANGED
@@ -1,56 +1,57 @@
1
1
  export default {
2
2
  permissionApply: 'Aplikasi Izin',
3
- applyPermission: 'Ajukan Izin',
4
- applyReason: 'Alasan Pengajuan',
3
+ applyPermission: 'Ajukan Permohonan Izin',
4
+ applyReason: 'Alasan Permohonan',
5
5
  approvalProcess: 'Proses Persetujuan',
6
- applyReasonPlaceholder: 'Harap jelaskan alasan pengajuan dan skenario penggunaan selengkap mungkin. Hindari hanya menyebutkan "kebutuhan kerja" untuk mencegah penundaan dalam proses persetujuan.',
6
+ isAllOwnTips: 'Halaman ini sudah memiliki izin atau sedang dalam proses persetujuan, tidak perlu mengajukan permohonan',
7
+ applyReasonPlaceholder: 'Harap jelaskan alasan dan skenario penggunaan secara detail. Hindari penjelasan yang tidak jelas seperti "kebutuhan kerja" untuk mencegah penundaan persetujuan.',
7
8
  applyReasonTips: 'Contoh: Karena kebutuhan proyek XX, perlu melihat/mengoperasikan skenario/masalah XXXX, yang melibatkan penggunaan izin XXX, oleh karena itu mengajukan permohonan ini!',
8
9
  cancel: 'Batal',
9
10
  submit: 'Konfirmasi',
10
11
  close: 'Tutup',
11
12
  viewApprovalDetail: 'Lihat Detail Persetujuan',
12
- applyMore: 'Ajukan Izin Lainnya',
13
- successTips: 'Pengajuan telah dikirim. Izin terkait akan diberikan setelah disetujui.',
13
+ applyMore: 'Lanjutkan mengajukan izin lainnya',
14
+ successTips: 'Permohonan telah diajukan. Izin terkait akan diberikan setelah disetujui.',
14
15
  resoultTitle: 'Umpan Balik Hasil Operasi',
15
16
  start: 'Mulai',
16
17
  end: 'Selesai',
17
18
  noNeed: 'Tidak Perlu Persetujuan',
18
19
  adaptDepartment: 'Departemen yang Berlaku',
19
- noApprovalProcess: 'Tidak Ada Proses Persetujuan',
20
- excessTips: 'Maksimal {number} izin dapat diajukan sekaligus',
21
- unavailableTips: 'Anda saat ini tidak memiliki izin untuk melihat/mengoperasikan halaman ini. Silakan klik tombol di bawah untuk mengajukan.',
22
- appliedTips: 'Izin telah diajukan, saat ini {status}...',
23
- unapplyTips: 'Anda tidak memiliki izin untuk melihat/mengoperasikan halaman ini, dan tidak ada izin yang dapat diajukan di halaman ini.',
20
+ noApprovalProcess: 'Tidak perlu proses persetujuan',
21
+ excessTips: 'Anda dapat mengajukan hingga {number} izin sekaligus',
22
+ unavailableTips: 'Anda saat ini tidak memiliki izin untuk melihat/mengoperasikan halaman ini. Silakan klik tombol di bawah untuk mengajukan permohonan.',
23
+ appliedTips: 'Permohonan izin telah diajukan, saat ini {status}...',
24
+ unapplyTips: 'Anda tidak memiliki izin untuk melihat atau mengoperasikan halaman ini. Tidak ada izin yang tersedia untuk diajukan.',
24
25
  callManager: 'Jika diperlukan, silakan hubungi administrator sistem',
25
26
  manager: 'Administrator Sistem',
26
27
  availableTime: 'Masa Berlaku',
27
28
  selectPlaceholder: 'Silakan pilih titik izin',
28
- reasonPlaceholder: 'Silakan masukkan alasan pengajuan',
29
+ reasonPlaceholder: 'Silakan masukkan alasan permohonan Anda',
29
30
  pleaseChoose: 'Silakan pilih',
30
- maxCountTips: 'Maksimal {count} izin dapat diajukan sekaligus',
31
+ maxCountTips: 'Anda dapat mengajukan hingga {count} izin sekaligus',
31
32
  maxLengthTips: 'Maksimal {length} karakter',
32
33
  today: 'Kadaluarsa hari ini',
33
34
  clickToApply: 'Klik untuk mengajukan izin',
34
- noPermissionTips: 'Tidak ada titik izin di menu ini',
35
+ noPermissionTips: 'Tidak ada titik izin di bawah menu ini, tidak perlu mengajukan permohonan',
35
36
  lastDays: '{count} hari',
36
- categoryTips: 'Cakupan data Anda saat ini adalah sebagai berikut:',
37
- empty: 'Kosong',
37
+ categoryTips: 'Cakupan data Anda saat ini:',
38
+ empty: 'Tidak ada',
38
39
  category: 'Izin Data',
39
- categotySelectTips: 'Izin yang dipilih di atas mencakup izin data. Silakan ajukan/ubah cakupan data sesuai kebutuhan kerja aktual.',
40
- categoryChangeTips: 'Peringatan: Cakupan izin data yang Anda pilih relatif besar! Harap konfirmasi apakah skenario kerja aktual Anda memerlukan akses penuh ke izin 「{category}」, dan jelaskan secara jelas dalam alasan pengajuan untuk menghindari penolakan!',
40
+ categotySelectTips: 'Izin yang dipilih termasuk pengaturan cakupan data. Silakan ajukan atau perbarui cakupan berdasarkan kebutuhan aktual Anda.',
41
+ categoryChangeTips: 'Harap verifikasi apakah akses penuh ke "{category}" diperlukan untuk peran Anda. Pastikan untuk menjelaskan kasus penggunaan secara jelas dalam permohonan Anda untuk menghindari penolakan.',
41
42
  levels: {
42
43
  L1: 'Rendah',
43
44
  L2: 'Sedang',
44
45
  L3: 'Tinggi',
45
46
  },
46
47
  status: {
47
- PENDING: 'Menunggu Persetujuan',
48
- NO: 'Tidak Dapat Diajukan',
49
- OWNER: 'Dimiliki Secara Permanen',
50
- TEMP_OWNER: 'Dimiliki Sementara',
48
+ PENDING: 'Dalam tinjauan',
49
+ NO: 'Tidak berlaku untuk aplikasi',
50
+ OWNER: 'Izin permanen',
51
+ TEMP_OWNER: 'Izin sementara',
51
52
  },
52
53
  operationType: {
53
54
  QUERY: 'Kueri',
54
- MANAGE: 'Operasi',
55
+ MANAGE: 'Aksi',
55
56
  }
56
57
  };
package/src/i18n/zh-CH.ts CHANGED
@@ -3,6 +3,7 @@ export default {
3
3
  applyPermission: '申请权限',
4
4
  applyReason: '申请理由',
5
5
  approvalProcess: '审批流程',
6
+ isAllOwnTips: '当前页面权限已拥有或审批中,无需申请',
6
7
  applyReasonPlaceholder: '请尽可能详细说明申请原因和使用场景,不要只填写“工作需要”之类的理由,以免影响你获取权限的审批时间。',
7
8
  applyReasonTips: '示例:由于XX项目需要,需要查看/操作XXXX场景/问题,涉及到XXX权限的使用,因此提交申请!',
8
9
  cancel: '取消',
@@ -31,7 +32,7 @@ export default {
31
32
  maxLengthTips: '最多{length}个字符',
32
33
  today: '今天到期',
33
34
  clickToApply: '点击申请权限',
34
- noPermissionTips: '该菜单下暂无权限点',
35
+ noPermissionTips: '该菜单下暂无权限点,无需申请',
35
36
  lastDays: '{count}天',
36
37
  categoryTips: '当前您所拥有的数据范围如下:',
37
38
  empty: '空',
@@ -39,6 +39,7 @@ declare type PermissionType = {
39
39
  admin?: any[];
40
40
  checked?: boolean;
41
41
  disabled?: boolean;
42
+ disableCheckbox?: boolean;
42
43
  children?: PermissionListType;
43
44
  };
44
45
  declare type PermissionListType = PermissionType[];