@steedos-labs/content-compliance-bev 0.0.1 → 0.0.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.
Files changed (97) hide show
  1. package/dist/index.js +1 -1
  2. package/lib/actions/submit.d.ts +9 -1
  3. package/lib/actions/submit.js +50 -11
  4. package/lib/actions/submit.js.map +1 -1
  5. package/lib/actions/submitMaterial.js +1 -1
  6. package/lib/actions/submitMaterial.js.map +1 -1
  7. package/lib/index.js +12 -3
  8. package/lib/index.js.map +1 -1
  9. package/lib/methods/approval_engine.js +66 -50
  10. package/lib/methods/approval_engine.js.map +1 -1
  11. package/lib/methods/consts.d.ts +3 -1
  12. package/lib/methods/consts.js.map +1 -1
  13. package/lib/methods/content_hub.js +5 -0
  14. package/lib/methods/content_hub.js.map +1 -1
  15. package/lib/methods/index.d.ts +1 -0
  16. package/lib/methods/index.js +1 -0
  17. package/lib/methods/index.js.map +1 -1
  18. package/lib/methods/material.js +5 -5
  19. package/lib/methods/material.js.map +1 -1
  20. package/lib/methods/task.d.ts +7 -0
  21. package/lib/methods/task.js +269 -0
  22. package/lib/methods/task.js.map +1 -0
  23. package/main/default/applications/approve_workflow.app.yml +92 -0
  24. package/main/default/applications/pepsico_content_setting.app.yml +26 -19
  25. package/main/default/client/pepsico_content.client.js +30 -0
  26. package/main/default/objects/pepsico_approval_process/fields/approved.field.yml +1 -2
  27. package/main/default/objects/pepsico_approval_process/fields/current_step.field.yml +1 -1
  28. package/main/default/objects/pepsico_approval_process/fields/type.field.yml +1 -1
  29. package/main/default/objects/pepsico_approval_task/fields/approval_field.field.yml +23 -0
  30. package/main/default/objects/pepsico_approval_task/fields/approval_status.field.yml +15 -0
  31. package/main/default/objects/pepsico_approval_task/fields/approve_time.field.yml +7 -0
  32. package/main/default/objects/pepsico_approval_task/fields/comment.field.yml +9 -0
  33. package/main/default/objects/pepsico_approval_task/fields/owner.field.yml +11 -0
  34. package/main/default/objects/pepsico_approval_task/fields/pepsico_material.field.yml +8 -0
  35. package/main/default/objects/pepsico_approval_task/fields/pepsico_material_approval.field.yml +8 -0
  36. package/main/default/objects/pepsico_approval_task/listviews/all.listview.yml +17 -0
  37. package/main/default/objects/pepsico_approval_task/listviews/recent.listview.yml +14 -0
  38. package/main/default/objects/pepsico_approval_task/pepsico_approval_task.object.yml +26 -0
  39. package/main/default/objects/pepsico_approval_task/permissions/admin.permission.yml +17 -0
  40. package/main/default/objects/pepsico_approval_task/permissions/user.permission.yml +16 -0
  41. package/main/default/objects/pepsico_brand_leader/fields/classification.field.yml +0 -26
  42. package/main/default/objects/pepsico_mail_send_log/fields/classification.field.yml +0 -26
  43. package/main/default/objects/pepsico_material/buttons/pepsico_material_approve.button.yml +4 -0
  44. package/main/default/objects/pepsico_material/buttons/pepsico_material_reject.button.yml +4 -0
  45. package/main/default/objects/pepsico_material/buttons/pepsico_onedrive_edit_material.button.yml +1 -1
  46. package/main/default/objects/pepsico_material/buttons/pepsico_onedrive_review_material.button.yml +1 -1
  47. package/main/default/objects/pepsico_material/buttons/pepsico_update_material.button.yml +2 -2
  48. package/main/default/objects/pepsico_material/buttons/pepsico_upload_supplement.button.yml +3 -3
  49. package/main/default/objects/pepsico_material/fields/approval_status.field.yml +1 -1
  50. package/main/default/objects/pepsico_material/fields/classification.field.yml +0 -31
  51. package/main/default/objects/pepsico_material/fields/material_one_drive_history.field.yml +1 -1
  52. package/main/default/objects/pepsico_material/fields/material_update_history.field.yml +1 -1
  53. package/main/default/objects/pepsico_material/fields/social_media.field.yml +2 -0
  54. package/main/default/objects/pepsico_material/permissions/user.permission.yml +1 -0
  55. package/main/default/objects/pepsico_material_approval/buttons/pepsico_copyright_upload.button.yml +5 -2
  56. package/main/default/objects/pepsico_material_approval/buttons/pepsico_material_upload.button.yml +6 -4
  57. package/main/default/objects/pepsico_material_approval/buttons/pepsico_submit.button.yml +104 -42
  58. package/main/default/objects/pepsico_material_approval/buttons/pepsico_terminate.button.yml +6 -5
  59. package/main/default/objects/pepsico_material_approval/buttons/standard_delete.button.js +1 -1
  60. package/main/default/objects/pepsico_material_approval/buttons/standard_edit.button.js +1 -1
  61. package/main/default/objects/pepsico_material_approval/fields/approval_status.field.yml +1 -1
  62. package/main/default/objects/pepsico_material_approval/fields/approval_type.field.yml +2 -2
  63. package/main/default/objects/pepsico_material_approval/fields/assistance.field.yml +1 -1
  64. package/main/default/objects/pepsico_material_approval/fields/ca_spot_check.field.yml +2 -2
  65. package/main/default/objects/pepsico_material_approval/fields/classification.field.yml +33 -0
  66. package/main/default/objects/pepsico_material_approval/fields/current_step.field.yml +1 -1
  67. package/main/default/objects/pepsico_material_approval/fields/followers.field.yml +12 -0
  68. package/main/default/objects/pepsico_material_approval/fields/handler_guding.field.yml +1 -1
  69. package/main/default/objects/pepsico_material_approval/fields/internal_collaborator_edit.field.yml +1 -1
  70. package/main/default/objects/pepsico_material_approval/fields/kids_assistance.field.yml +4 -6
  71. package/main/default/objects/pepsico_material_approval/fields/kids_reviewer.field.yml +3 -2
  72. package/main/default/objects/pepsico_material_approval/fields/legal_spot_check.field.yml +2 -2
  73. package/main/default/objects/pepsico_material_approval/fields/ns_spot_check.field.yml +2 -2
  74. package/main/default/objects/pepsico_material_approval/fields/owner.field.yml +0 -2
  75. package/main/default/objects/pepsico_material_approval/fields/product.field.yml +34 -0
  76. package/main/default/objects/pepsico_material_approval/fields/reviewer.field.yml +1 -1
  77. package/main/default/objects/pepsico_material_approval/fields/social_media.field.yml +8 -0
  78. package/main/default/objects/pepsico_material_approval/fields/special_spot_check.field.yml +3 -3
  79. package/main/default/objects/pepsico_material_approval/fields/sra_spot_check.field.yml +2 -2
  80. package/main/default/objects/pepsico_material_approval/listviews/handle.listview.yml +1 -1
  81. package/main/default/objects/pepsico_material_approval/pepsico_material_approval.object.yml +2 -0
  82. package/main/default/objects/pepsico_reviewer/fields/assistance.field.yml +1 -1
  83. package/main/default/objects/pepsico_reviewer/fields/reviewer.field.yml +1 -1
  84. package/main/default/objects/pepsico_reviewer/fields/special_spot_check.field.yml +1 -1
  85. package/main/default/pages/pepsico_content_review_detail.page.amis.json +80 -7
  86. package/main/default/pages/pepsico_material_detail.page.amis.json +2 -2
  87. package/main/default/pages/pepsico_material_detail_mobile.page.amis.json +1 -1
  88. package/main/default/pages/pepsico_midtier_spot_check.page.amis.json +1 -1
  89. package/main/default/pages/pepsico_spot_check.page.amis.json +1 -1
  90. package/main/default/pages/pepsico_spot_check_dco.page.amis.json +1 -1
  91. package/package.json +2 -2
  92. package/public/content-review/amis.css +32 -0
  93. package/public/content-review/topic.css +8 -1
  94. package/public/pepsico_login.css +196 -0
  95. package/public/{dynamic.js → pepsico_login.js} +0 -2
  96. package/public/privacy-policy/index.html +657 -879
  97. package/public/dynamic.css +0 -191
@@ -0,0 +1,14 @@
1
+ name: recent
2
+ columns:
3
+ - field: name
4
+ crud_mode: table
5
+ filter_scope: space
6
+ is_enable: true
7
+ label: 最近查看
8
+ scrolling_mode: standard
9
+ shared_to: space
10
+ sort:
11
+ - field_name: created
12
+ order: desc
13
+ sort_no: 100
14
+ type: grid
@@ -0,0 +1,26 @@
1
+ name: pepsico_approval_task
2
+ enable_api: true
3
+ enable_audit: false
4
+ enable_chatter: false
5
+ enable_dataloader: true
6
+ enable_enhanced_lookup: true
7
+ enable_events: false
8
+ enable_files: false
9
+ enable_form_tabs: false
10
+ enable_inline_edit: true
11
+ enable_instances: false
12
+ enable_lock_detail: true
13
+ enable_print: false
14
+ enable_split: false
15
+ enable_tasks: false
16
+ enable_tree: false
17
+ enable_workflow: true
18
+ field_groups:
19
+ - group_name: 通用
20
+ - group_name: 系统信息
21
+ collapsed: true
22
+ icon: task
23
+ is_enable: true
24
+ label: 审批任务
25
+ locked: false
26
+ version: 2
@@ -0,0 +1,17 @@
1
+ name: pepsico_approval_task.admin
2
+ allowCreate: true
3
+ allowCreateFiles: true
4
+ allowCreateListViews: true
5
+ allowDelete: true
6
+ allowDeleteFiles: true
7
+ allowEdit: true
8
+ allowEditFiles: true
9
+ allowExport: true
10
+ allowRead: true
11
+ allowReadFiles: true
12
+ modifyAllFiles: true
13
+ modifyAllRecords: true
14
+ permission_set_id: admin
15
+ viewAllFiles: true
16
+ viewAllRecords: true
17
+ field_permissions: []
@@ -0,0 +1,16 @@
1
+ name: pepsico_approval_task.user
2
+ allowCreate: true
3
+ allowCreateFiles: true
4
+ allowCreateListViews: true
5
+ allowDelete: true
6
+ allowDeleteFiles: true
7
+ allowEdit: true
8
+ allowEditFiles: true
9
+ allowExport: true
10
+ allowRead: true
11
+ allowReadFiles: true
12
+ modifyAllRecords: false
13
+ permission_set_id: user
14
+ viewAllFiles: true
15
+ viewAllRecords: true
16
+ field_permissions: []
@@ -62,32 +62,6 @@ data_type: text
62
62
  description: ''
63
63
  enable_thousands: true
64
64
  filters: []
65
- inlineHelpText: >-
66
- <b>Top KOL account: </b><br>
67
-
68
- - Tiktok fans >800w;<br>
69
-
70
- - XHS fans >100w;<br>
71
-
72
- - Weibo fans >1000w;<br>
73
-
74
- - WeChat fans >100w;<br>
75
-
76
- - Bilibili fans > 100w;<br>
77
-
78
- - Kuaishou fans >800w ;<br>
79
-
80
- <br>
81
-
82
- <b>Top Media account: </b><br>
83
-
84
- -State owned media platforms with national coverage - CCTV series; National /
85
- Provincial Satellite TV;<br>
86
-
87
- - Newspaper/Radio/website affiliated to National ministries and
88
- commissions;<br>
89
-
90
- - social accounts affiliated to above media owners;
91
65
  is_wide: false
92
66
  label: 分类
93
67
  options:
@@ -62,32 +62,6 @@ data_type: text
62
62
  description: ''
63
63
  enable_thousands: true
64
64
  filters: []
65
- inlineHelpText: >-
66
- <b>Top KOL account: </b><br>
67
-
68
- - Tiktok fans >800w;<br>
69
-
70
- - XHS fans >100w;<br>
71
-
72
- - Weibo fans >1000w;<br>
73
-
74
- - WeChat fans >100w;<br>
75
-
76
- - Bilibili fans > 100w;<br>
77
-
78
- - Kuaishou fans >800w ;<br>
79
-
80
- <br>
81
-
82
- <b>Top Media account: </b><br>
83
-
84
- -State owned media platforms with national coverage - CCTV series; National /
85
- Provincial Satellite TV;<br>
86
-
87
- - Newspaper/Radio/website affiliated to National ministries and
88
- commissions;<br>
89
-
90
- - social accounts affiliated to above media owners;
91
65
  is_wide: false
92
66
  label: 分类
93
67
  options:
@@ -51,6 +51,10 @@ amis_schema: |-
51
51
  "groupType": "component",
52
52
  "actionType": "reload"
53
53
  },
54
+ {
55
+ "actionType": "custom",
56
+ "script": "$('.list-view-btn-reload').trigger('click')"
57
+ },
54
58
  {
55
59
  "actionType": "closeDialog",
56
60
  "ignoreError": false
@@ -53,6 +53,10 @@ amis_schema: |-
53
53
  "groupType": "component",
54
54
  "actionType": "reload"
55
55
  },
56
+ {
57
+ "actionType": "custom",
58
+ "script": "$('.list-view-btn-reload').trigger('click')"
59
+ },
56
60
  {
57
61
  "actionType": "closeDialog",
58
62
  "ignoreError": false
@@ -11,7 +11,7 @@ amis_schema: |-
11
11
  "label": "编辑素材",
12
12
  "id": "u:f7ac1cc7ac3a",
13
13
  "editorState": "default",
14
- "visibleOn": "${void_material !== true && (extension_type === 'doc' || extension_type === 'docx' || extension_type === 'ppt' || extension_type === 'pptx') &&(((current_step == 'departmental_review' || current_step == 'personnel_review') && !((owner === context.userId || created_by === context.userId)))|| (current_step == 'submitter_revisions' && owner === context.userId)) && formFactor != 'SMALL'}",
14
+ "visibleOn": "${void_material !== true && (extension_type === 'doc' || extension_type === 'docx' || extension_type === 'ppt' || extension_type === 'pptx' || extension_type == 'xls' || extension_type == 'xlsx') &&(((current_step == 'departmental_review' || current_step == 'personnel_review') && !((owner === context.userId || created_by === context.userId)))|| (current_step == 'submitter_revisions' && owner === context.userId)) && formFactor != 'SMALL'}",
15
15
  "onEvent": {
16
16
  "click": {
17
17
  "actions": [
@@ -7,7 +7,7 @@ amis_schema: |-
7
7
  "type": "button",
8
8
  "label": "${ permanent_deleted == true ? '下载素材' : '查看素材'}",
9
9
  "id": "u:pepsico_review_material",
10
- "visibleOn": "${(extension_type === 'doc' || extension_type === 'docx' || extension_type === 'ppt' || extension_type === 'pptx') && !(current_step == 'draft'||current_step == 'ai_review')}",
10
+ "visibleOn": "${(extension_type === 'doc' || extension_type === 'docx' || extension_type === 'ppt' || extension_type === 'pptx' || extension_type == 'xls' || extension_type == 'xlsx') && !(current_step == 'draft'||current_step == 'ai_review')}",
11
11
  "onEvent": {
12
12
  "click": {
13
13
  "actions": [
@@ -11,7 +11,7 @@ amis_schema: |-
11
11
  "label": "替换素材",
12
12
  "id": "u:683f062fed98",
13
13
  "editorState": "default",
14
- "visibleOn": "${void_material !== true && (current_step == 'submitter_revisions' && extension_type !== 'doc' && extension_type !== 'docx' && extension_type !== 'ppt' && extension_type !== 'pptx') && owner === context.userId && formFactor != 'SMALL'}",
14
+ "visibleOn": "${void_material !== true && (current_step == 'submitter_revisions' && extension_type !== 'doc' && extension_type !== 'docx' && extension_type !== 'ppt' && extension_type !== 'pptx' && extension_type !== 'xls' && extension_type !== 'xlsx') && owner === context.userId && formFactor != 'SMALL'}",
15
15
  "onEvent": {
16
16
  "click": {
17
17
  "weight": 0,
@@ -35,7 +35,7 @@ amis_schema: |-
35
35
  "maxSize": 1073741824,
36
36
  "multiple": false,
37
37
  "useChunk": false,
38
- "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx",
38
+ "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx, .xls, .xlsx",
39
39
  "drag": true,
40
40
  "onEvent": {
41
41
  "success": {
@@ -43,10 +43,10 @@ amis_schema: |-
43
43
  }
44
44
  },
45
45
  "receiver": {
46
- "url": "/s3/files",
46
+ "url": "/api/v6/files/cfs.files.filerecord",
47
47
  "method": "post",
48
- "requestAdaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\n\nreturn api;",
49
- "adaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { context: pageContext } = superData;\nvar rootUrl = pageContext.rootUrl + \"/api/files/files/\";\npayload = {\n status: response.status == 200 ? 0 : response.status,\n msg: response.statusText,\n data: {\n value: payload._id,\n name: payload.original.name,\n url: rootUrl + payload._id,\n }\n}\nreturn payload;",
48
+ "requestAdaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\napi.data.append('owner_name', user.name);\n\nreturn api;",
49
+ "adaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { context: pageContext } = superData;\nvar rootUrl = pageContext.rootUrl + \"/api/files/files/\";\npayload = {\n status: response.status == 200 ? 0 : response.status,\n msg: response.statusText,\n data: {\n value: {id: payload._id, md5: payload.original.md5},\n name: payload.original.name,\n url: rootUrl + payload._id,\n }\n}\nreturn payload;",
50
50
  "messages": {},
51
51
  "dataType": "form-data"
52
52
  }
@@ -4,7 +4,7 @@ amis:
4
4
  data_type: boolean
5
5
  group: 审核情况
6
6
  is_wide: false
7
- label: Special List审核
7
+ label: 固定人员审批
8
8
  options:
9
9
  - label: √
10
10
  value: true
@@ -10,37 +10,6 @@ amis:
10
10
  clearable: true
11
11
  onlyLeaf: true
12
12
  description: ''
13
- labelRemark:
14
- trigger:
15
- - hover
16
- className: Remark--warning
17
- placement: bottom
18
- content: >-
19
- Top KOL account:<br>
20
-
21
- - Tiktok fans >800w;<br>
22
-
23
- - XHS fans >100w;<br>
24
-
25
- - Weibo fans >1000w;<br>
26
-
27
- - WeChat fans >100w;<br>
28
-
29
- - Bilibili fans > 100w;<br>
30
-
31
- - Kuaishou fans >800w;<br>
32
-
33
- <br>
34
-
35
- Top Media account:<br>
36
-
37
- - CCTV series; National / Provincial Satellite TV;<br>
38
-
39
- - Newspaper/Radio/website affiliated to National ministries and
40
- commissions;<br>
41
-
42
- - social accounts affiliated to above media owners;<br>
43
- title: 分类说明
44
13
  searchable: true
45
14
  label: 分类
46
15
  showOutline: false
@@ -12,4 +12,4 @@ static: false
12
12
  type: file
13
13
  visible_on: >-
14
14
  {{extension_type == 'doc' || extension_type == 'docx' || extension_type ==
15
- 'ppt' || extension_type == 'pptx'}}
15
+ 'ppt' || extension_type == 'pptx' && extension_type == 'xls' && extension_type == 'xlsx'}}
@@ -12,4 +12,4 @@ static: false
12
12
  type: file
13
13
  visible_on: >-
14
14
  {{extension_type !== 'doc' && extension_type !== 'docx' && extension_type !==
15
- 'ppt' && extension_type !== 'pptx'}}
15
+ 'ppt' && extension_type !== 'pptx' && extension_type !== 'xls' && extension_type !== 'xlsx'}}
@@ -74,6 +74,8 @@ options:
74
74
  value: Bilibili
75
75
  - label: Kuaishou
76
76
  value: Kuaishou
77
+ - label: 大众点评
78
+ value: 大众点评
77
79
  required: true
78
80
  sort_no: 350
79
81
  type: select
@@ -13,3 +13,4 @@ permission_set_id: user
13
13
  viewAllFiles: true
14
14
  viewAllRecords: true
15
15
  field_permissions: []
16
+ allowExport: true
@@ -36,7 +36,9 @@ amis_schema: |-
36
36
  "subtitles",
37
37
  "font_copyright",
38
38
  "copyright_front",
39
- "copyright_other"
39
+ "copyright_other",
40
+ "is_trademark_checked",
41
+ "trademark_files"
40
42
  ]
41
43
  }
42
44
  ],
@@ -62,7 +64,8 @@ amis_schema: |-
62
64
  "showErrorMsg": true,
63
65
  "showLoading": true,
64
66
  "draggable": false,
65
- "size": "lg"
67
+ "size": "lg",
68
+ "actionType": "dialog"
66
69
  }
67
70
  }
68
71
  ]
@@ -38,9 +38,10 @@ amis_schema: |-
38
38
  "btnLabel": "文件上传",
39
39
  "multiple": true,
40
40
  "maxSize": 10737418240,
41
+ "description": "Office文件大小不能超过250MB.",
41
42
  "maxLength": 300,
42
43
  "useChunk": false,
43
- "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx",
44
+ "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx, .xls, .xlsx",
44
45
  "drag": true,
45
46
  "onEvent": {
46
47
  "success": {
@@ -51,7 +52,7 @@ amis_schema: |-
51
52
  "receiver": {
52
53
  "url": "/api/v6/files/cfs.files.filerecord",
53
54
  "method": "post",
54
- "requestAdaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\napi.data.append('owner_name', user.name);\n\nreturn api;",
55
+ "requestAdaptor": "function validateFileSize(file) { const restrictedTypes = { 'word': ['.doc', '.docx'], 'ppt': ['.ppt', '.pptx'], 'excel': ['.xls', '.xlsx'] }; const fileName = file.name.toLowerCase(); const fileExtension = fileName.substring(fileName.lastIndexOf('.')); const isRestrictedType = Object.values(restrictedTypes) .flat() .includes(fileExtension); if (isRestrictedType) { const maxSize = 250 * 1024 * 1024; if (file.size > maxSize) { throw new Error(`Office文件大小不能超过250MB,当前文件大小为 ${(file.size / (1024 * 1024)).toFixed(2)}MB`) } }};validateFileSize(api.data.get('file'));; const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\napi.data.append('owner_name', user.name);\n\nreturn api;",
55
56
  "adaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { context: pageContext } = superData;\nvar rootUrl = pageContext.rootUrl + \"/api/files/files/\";\npayload = {\n status: response.status == 200 ? 0 : response.status,\n msg: response.statusText,\n data: {\n value: payload._id,\n name: payload.original.name,\n url: rootUrl + payload._id,\n }\n}\nreturn payload;",
56
57
  "messages": {},
57
58
  "dataType": "form-data"
@@ -236,11 +237,12 @@ amis_schema: |-
236
237
  "name": "files",
237
238
  "id": "u:353a3c44dde9",
238
239
  "btnLabel": "文件上传",
240
+ "description": "Office文件大小不能超过250MB.",
239
241
  "multiple": true,
240
242
  "maxSize": 1073741824,
241
243
  "maxLength": 50,
242
244
  "useChunk": false,
243
- "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx",
245
+ "accept": ".jpg, .jpeg, .png, .pptx, .mp4, .avi, .mov, .doc, .docx, .xls, .xlsx",
244
246
  "drag": true,
245
247
  "onEvent": {
246
248
  "success": {
@@ -251,7 +253,7 @@ amis_schema: |-
251
253
  "receiver": {
252
254
  "url": "/api/v6/files/cfs.files.filerecord",
253
255
  "method": "post",
254
- "requestAdaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\napi.data.append('owner_name', user.name);\n\nreturn api;",
256
+ "requestAdaptor": "function validateFileSize(file) { const restrictedTypes = { 'word': ['.doc', '.docx'], 'ppt': ['.ppt', '.pptx'], 'excel': ['.xls', '.xlsx'] }; const fileName = file.name.toLowerCase(); const fileExtension = fileName.substring(fileName.lastIndexOf('.')); const isRestrictedType = Object.values(restrictedTypes) .flat() .includes(fileExtension); if (isRestrictedType) { const maxSize = 250 * 1024 * 1024; if (file.size > maxSize) { throw new Error(`Office文件大小不能超过250MB,当前文件大小为 ${(file.size / (1024 * 1024)).toFixed(2)}MB`) } }};validateFileSize(api.data.get('file'));; const superData = (typeof context != 'undefined') ? context : api.body;\nconst { _master, global } = superData;\nconst { spaceId, userId, user } = global;\n\napi.data.append('space', spaceId);\napi.data.append('owner', userId);\napi.data.append('owner_name', user.name);\n\nreturn api;",
255
257
  "adaptor": "const superData = (typeof context != 'undefined') ? context : api.body;\nconst { context: pageContext } = superData;\nvar rootUrl = pageContext.rootUrl + \"/api/files/files/\";\npayload = {\n status: response.status == 200 ? 0 : response.status,\n msg: response.statusText,\n data: {\n value: payload._id,\n name: payload.original.name,\n url: rootUrl + payload._id,\n }\n}\nreturn payload;",
256
258
  "messages": {},
257
259
  "dataType": "form-data"
@@ -9,8 +9,6 @@ amis_schema: |-
9
9
  "id": "u:pepsico_submit",
10
10
  "editorState": "default",
11
11
  "visibleOn": "${owner === context.userId && current_step == 'submitter_revisions' && formFactor != 'SMALL'}",
12
- "actionType": "ajax",
13
- "confirmText": "您已经修改完成,确认要再次提交审核吗?",
14
12
  "confirmTitle": "提交人修改",
15
13
  "themeCss": {
16
14
  "className": {
@@ -30,45 +28,108 @@ amis_schema: |-
30
28
  }
31
29
  }
32
30
  },
33
- "onEvent": {
34
- "click": {
35
- "weight": 0,
36
- "actions": [
37
- {
38
- "ignoreError": false,
39
- "actionType": "disabled",
40
- "componentId": "u:pepsico_submit"
41
- },
42
- {
43
- "actionType": "ajax",
44
- "ignoreError": false,
45
- "outputVar": "responseResult",
46
- "options": {},
47
- "api": {
48
- "url": "/api/pepsico-content/approve/submit/${recordId}",
49
- "method": "post",
50
- "requestAdaptor": "api.data = {}",
51
- "adaptor": "",
52
- "messages": {}
53
- }
54
- },
55
- {
56
- "actionType": "broadcast",
57
- "args": {
58
- "eventName": "@data.changed.pepsico_material_approval"
59
- },
60
- "data": {
61
- "objectName": "pepsico_material_approval"
62
- }
63
- },
64
- {
65
- "ignoreError": false,
66
- "actionType": "enabled",
67
- "componentId": "u:pepsico_submit"
68
- }
69
- ]
70
- }
71
- }
31
+ "onEvent": {
32
+ "click": {
33
+ "weight": 0,
34
+ "actions": [
35
+ {
36
+ "ignoreError": false,
37
+ "actionType": "dialog",
38
+ "dialog": {
39
+ "type": "dialog",
40
+ "title": "再次提交素材审核操作",
41
+ "body": [
42
+ {
43
+ "id": "u:39a0fdfa57ab",
44
+ "type": "form",
45
+ "title": "表单",
46
+ "mode": "normal",
47
+ "dsType": "api",
48
+ "feat": "Insert",
49
+ "body": [
50
+ {
51
+ "type": "textarea",
52
+ "label": "请简要说明本次修改素材内容",
53
+ "name": "comment",
54
+ "id": "u:fc0716485c3f",
55
+ "minRows": 3,
56
+ "maxRows": 20,
57
+ "placeholder": "",
58
+ "required": true
59
+ }
60
+ ],
61
+ "actions": [
62
+ {
63
+ "type": "button",
64
+ "label": "提交",
65
+ "onEvent": {
66
+ "click": {
67
+ "actions": [
68
+ {
69
+ "actionType": "submit",
70
+ "componentId": "u:39a0fdfa57ab"
71
+ }
72
+ ]
73
+ }
74
+ },
75
+ "level": "primary"
76
+ }
77
+ ],
78
+ "resetAfterSubmit": true,
79
+ "api": {
80
+ "url": "/api/pepsico-content/approve/submit/${recordId}",
81
+ "method": "post",
82
+ "requestAdaptor": "",
83
+ "adaptor": "",
84
+ "messages": {}
85
+ },
86
+ "onEvent": {
87
+ "submitSucc": {
88
+ "actions": [
89
+ {
90
+ "actionType": "broadcast",
91
+ "args": {
92
+ "eventName": "@data.changed.pepsico_material_approval"
93
+ },
94
+ "data": {
95
+ "objectName": "pepsico_material_approval"
96
+ }
97
+ }
98
+ ]
99
+ }
100
+ }
101
+ }
102
+ ],
103
+ "id": "u:c047b964da8e",
104
+ "actions": [
105
+ {
106
+ "type": "button",
107
+ "actionType": "cancel",
108
+ "label": "取消",
109
+ "id": "u:82ec6564ce74"
110
+ },
111
+ {
112
+ "type": "button",
113
+ "actionType": "confirm",
114
+ "label": "提交",
115
+ "primary": true,
116
+ "id": "u:356364a5efc0",
117
+ "editorState": "default"
118
+ }
119
+ ],
120
+ "showCloseButton": true,
121
+ "closeOnOutside": false,
122
+ "closeOnEsc": false,
123
+ "showErrorMsg": true,
124
+ "showLoading": true,
125
+ "draggable": false,
126
+ "actionType": "dialog",
127
+ "size": "md"
128
+ }
129
+ }
130
+ ]
131
+ }
132
+ }
72
133
  }
73
134
  ],
74
135
  "regions": [
@@ -83,7 +144,8 @@ amis_schema: |-
83
144
  },
84
145
  "id": "u:432b344de69a",
85
146
  "bodyClassName": "p-0",
86
- "dsType": "api"
147
+ "dsType": "api",
148
+ "definitions": {}
87
149
  }
88
150
  is_enable: true
89
151
  label: 再次提交审核
@@ -18,7 +18,7 @@ amis_schema: |-
18
18
  "actionType": "dialog",
19
19
  "dialog": {
20
20
  "type": "dialog",
21
- "title": "确定要中止审核?",
21
+ "title": "请确定是否要中止审核?",
22
22
  "body": [
23
23
  {
24
24
  "id": "u:a00aca5cd32e",
@@ -29,14 +29,15 @@ amis_schema: |-
29
29
  "feat": "Insert",
30
30
  "body": [
31
31
  {
32
- "type": "textarea",
33
- "label": "",
32
+ "type": "textarea",
33
+ "label": "请填写中止原因",
34
34
  "name": "description",
35
35
  "id": "u:371555242000",
36
36
  "minRows": 3,
37
37
  "maxRows": 20,
38
- "value": "",
39
- "placeholder": "请填写中止审核的原因"
38
+ "value": "",
39
+ "requiredOn": "${true}",
40
+ "placeholder": ""
40
41
  }
41
42
  ],
42
43
  "actions": [
@@ -1,7 +1,7 @@
1
1
  module.exports = {
2
2
 
3
3
  standard_deleteVisible: function(object_name, record_id, record_permissions, record) {
4
- return record.review_status === 'draft' && record.owner === Steedos.userId() && Steedos.isMobile() != true
4
+ return record.review_status === 'draft' && record.owner === Steedos.User.get().userId && Steedos.isMobile() != true
5
5
  }
6
6
 
7
7
  }
@@ -7,6 +7,6 @@
7
7
  */
8
8
  module.exports = {
9
9
  standard_editVisible: function (object_name, record_id, record_permissions, record) {
10
- return record.current_step === 'draft' && record.owner === Steedos.userId() && Steedos.isMobile() != true
10
+ return record.current_step === 'draft' && record.owner === Steedos.User.get().userId && Steedos.isMobile() != true
11
11
  }
12
12
  }
@@ -7,7 +7,7 @@ enable_thousands: true
7
7
  group: 审核情况
8
8
  inlineHelpText: ''
9
9
  is_wide: false
10
- label: Special List审核
10
+ label: 固定人员审核
11
11
  options:
12
12
  - label: √
13
13
  value: true
@@ -7,9 +7,9 @@ enable_thousands: true
7
7
  group: 审核人员
8
8
  inlineHelpText: ''
9
9
  is_wide: true
10
- label: Special List/部门审核
10
+ label: 固定人员/部门审核
11
11
  options:
12
- - label: Special List
12
+ - label: 固定人员
13
13
  value: personnel_review
14
14
  - label: 部门并行审核
15
15
  value: departmental_review
@@ -10,7 +10,7 @@ filters: []
10
10
  group: 审核人员
11
11
  inlineHelpText: ''
12
12
  is_wide: false
13
- label: Special List审核协作人
13
+ label: 固定审核协作人
14
14
  multiple: true
15
15
  reference_to: space_users
16
16
  reference_to_field: user