super-pages 0.0.23-up → 0.0.24-up

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,7 +1,7 @@
1
1
  {
2
2
  "name": "super-pages",
3
3
  "private": false,
4
- "version": "0.0.23-up",
4
+ "version": "0.0.24-up",
5
5
  "type": "module",
6
6
  "main": "./lib/super-pages.js",
7
7
  "scripts": {
@@ -14,7 +14,7 @@
14
14
  "@vitejs/plugin-vue": "^4.2.3",
15
15
  "axios": "^1.6.1",
16
16
  "element-plus": "^2.4.1",
17
- "imatrix-ui": "0.2.31-up",
17
+ "imatrix-ui": "0.2.41-up",
18
18
  "sass": "^1.69.4",
19
19
  "super-charts-new": "0.0.2-up",
20
20
  "super-form-editor": "0.0.5-up",
package/packages/index.js CHANGED
@@ -1,30 +1,30 @@
1
- // 本文件用来整合所有的组件,对外导出,形成一个完整的组件库
2
- import SuperPage from './super-page'
3
- import SuperPageDialog from './super-page-dialog'
4
- // 后续可以import其他的组件
5
-
6
- // 存储组件列表
7
- const components = [SuperPage, SuperPageDialog]
8
-
9
- // 定义 install 方法,接收 Vue 作为参数。如果使用 use 注册插件,则所有的组件都将被注册
10
- const install = function (Vue) {
11
- // 判断是否安装
12
- if (install.installed) return
13
- // 遍历注册全局组件
14
- // components.map(component => Vue.component(component.name, component))
15
- components.forEach((component) => {
16
- window.$vueApp.component(component.name, component)
17
- })
18
- }
19
-
20
- // 判断是否是直接引入文件
21
- if (typeof window !== 'undefined' && window.Vue) {
22
- install(window.Vue)
23
- }
24
-
25
- export default {
26
- // 导出的对象必须具有 install,才能被 Vue.use() 方法安装
27
- install,
28
- SuperPage,
29
- SuperPageDialog,
30
- }
1
+ // 本文件用来整合所有的组件,对外导出,形成一个完整的组件库
2
+ import SuperPage from './super-page'
3
+ import SuperPageDialog from './super-page-dialog'
4
+ // 后续可以import其他的组件
5
+
6
+ // 存储组件列表
7
+ const components = [SuperPage, SuperPageDialog]
8
+
9
+ // 定义 install 方法,接收 Vue 作为参数。如果使用 use 注册插件,则所有的组件都将被注册
10
+ const install = function (Vue) {
11
+ // 判断是否安装
12
+ if (install.installed) return
13
+ // 遍历注册全局组件
14
+ // components.map(component => Vue.component(component.name, component))
15
+ components.forEach((component) => {
16
+ window.$vueApp.component(component.name, component)
17
+ })
18
+ }
19
+
20
+ // 判断是否是直接引入文件
21
+ if (typeof window !== 'undefined' && window.Vue) {
22
+ install(window.Vue)
23
+ }
24
+
25
+ export default {
26
+ // 导出的对象必须具有 install,才能被 Vue.use() 方法安装
27
+ install,
28
+ SuperPage,
29
+ SuperPageDialog,
30
+ }
@@ -1,9 +1,9 @@
1
- // 本文件用来导出单个组件
2
- import SuperPage from './src/super-page.vue'
3
-
4
- // 每个组件都提供了install方法,这样就可以按需引入单个组件
5
- SuperPage.install = function (Vue) {
6
- window.$vueApp.component(SuperPage.name, SuperPage)
7
- }
8
-
9
- export default SuperPage
1
+ // 本文件用来导出单个组件
2
+ import SuperPage from './src/super-page.vue'
3
+
4
+ // 每个组件都提供了install方法,这样就可以按需引入单个组件
5
+ SuperPage.install = function (Vue) {
6
+ window.$vueApp.component(SuperPage.name, SuperPage)
7
+ }
8
+
9
+ export default SuperPage
@@ -136,7 +136,7 @@ export default {
136
136
  // 预览时,统计按钮不生效
137
137
  return
138
138
  }
139
- if (isInitSearch && this.isInitialQuery === false) {
139
+ if (isInitSearch && that.isInitialQuery === false) {
140
140
  // 当是初始化触发且禁止初始化时,不查询
141
141
  return
142
142
  }
@@ -1,74 +1,74 @@
1
- <template>
2
- <div
3
- :style="{ marginTop: formButtonPosition === 'topLeft' ? '72px' : '' }"
4
- class="formHead"
5
- >
6
- <div
7
- v-if="formTitle && formTitle !== '' && formTitle !== null"
8
- class="formTitle"
9
- >
10
- {{ formTitle }}
11
- </div>
12
- <span
13
- v-if="formNo"
14
- style="
15
- font-size: 18px;
16
- white-space: nowrap;
17
- display: block;
18
- text-align: right;
19
- "
20
- >{{
21
- formNoLabel && formNoLabel !== null && formNoLabel.trim() !== ''
22
- ? formNoLabel + ':'
23
- : $t('superPage.formNo')
24
- }}{{ formNo }}</span
25
- >
26
- </div>
27
- </template>
28
-
29
- <script>
30
- export default {
31
- name: 'FormHead',
32
- components: {},
33
- props: {
34
- // 表单标题
35
- formTitle: {
36
- type: String,
37
- default: null,
38
- },
39
- // 表单编码规则解析获得的表单编码
40
- formNo: {
41
- type: String,
42
- default: null,
43
- },
44
- formNoLabel: {
45
- type: String,
46
- default: null,
47
- },
48
- formButtonPosition: {
49
- type: String,
50
- default: null,
51
- },
52
- },
53
- }
54
- </script>
55
-
56
- <style lang="scss" scoped>
57
- .formTitle {
58
- color: #333;
59
- padding: 0;
60
- border: 0;
61
- display: block;
62
- margin-left: 40%;
63
- margin-bottom: 20px;
64
- font-weight: 700;
65
- font-size: 24px;
66
- }
67
- .formHead {
68
- color: #333;
69
- padding: 10px;
70
- border: 0;
71
- display: block;
72
- width: 100%;
73
- }
74
- </style>
1
+ <template>
2
+ <div
3
+ :style="{ marginTop: formButtonPosition === 'topLeft' ? '72px' : '' }"
4
+ class="formHead"
5
+ >
6
+ <div
7
+ v-if="formTitle && formTitle !== '' && formTitle !== null"
8
+ class="formTitle"
9
+ >
10
+ {{ formTitle }}
11
+ </div>
12
+ <span
13
+ v-if="formNo"
14
+ style="
15
+ font-size: 18px;
16
+ white-space: nowrap;
17
+ display: block;
18
+ text-align: right;
19
+ "
20
+ >{{
21
+ formNoLabel && formNoLabel !== null && formNoLabel.trim() !== ''
22
+ ? formNoLabel + ':'
23
+ : $t('superPage.formNo')
24
+ }}{{ formNo }}</span
25
+ >
26
+ </div>
27
+ </template>
28
+
29
+ <script>
30
+ export default {
31
+ name: 'FormHead',
32
+ components: {},
33
+ props: {
34
+ // 表单标题
35
+ formTitle: {
36
+ type: String,
37
+ default: null,
38
+ },
39
+ // 表单编码规则解析获得的表单编码
40
+ formNo: {
41
+ type: String,
42
+ default: null,
43
+ },
44
+ formNoLabel: {
45
+ type: String,
46
+ default: null,
47
+ },
48
+ formButtonPosition: {
49
+ type: String,
50
+ default: null,
51
+ },
52
+ },
53
+ }
54
+ </script>
55
+
56
+ <style lang="scss" scoped>
57
+ .formTitle {
58
+ color: #333;
59
+ padding: 0;
60
+ border: 0;
61
+ display: block;
62
+ margin-left: 40%;
63
+ margin-bottom: 20px;
64
+ font-weight: 700;
65
+ font-size: 24px;
66
+ }
67
+ .formHead {
68
+ color: #333;
69
+ padding: 10px;
70
+ border: 0;
71
+ display: block;
72
+ width: 100%;
73
+ }
74
+ </style>
@@ -1,21 +1,21 @@
1
- <template>
2
- <div>
3
- <el-menu default-active="1" class="el-menu-group" mode="horizontal">
4
- <el-menu-item index="1">
5
- {{ label }}
6
- </el-menu-item>
7
- </el-menu>
8
- </div>
9
- </template>
10
-
11
- <script>
12
- export default {
13
- name: 'GroupTag',
14
- props: {
15
- label: {
16
- type: String,
17
- default: null,
18
- },
19
- },
20
- }
21
- </script>
1
+ <template>
2
+ <div>
3
+ <el-menu default-active="1" class="el-menu-group" mode="horizontal">
4
+ <el-menu-item index="1">
5
+ {{ label }}
6
+ </el-menu-item>
7
+ </el-menu>
8
+ </div>
9
+ </template>
10
+
11
+ <script>
12
+ export default {
13
+ name: 'GroupTag',
14
+ props: {
15
+ label: {
16
+ type: String,
17
+ default: null,
18
+ },
19
+ },
20
+ }
21
+ </script>
@@ -1,103 +1,103 @@
1
- <template>
2
- <div>
3
- <el-dialog
4
- model-value
5
- :title="$t('superPage.selectRemoveUsers')"
6
- :close-on-click-modal="false"
7
- append-to-body
8
- width="30%"
9
- max-height="400"
10
- @open="$emit('open')"
11
- @opend="$emit('opend')"
12
- @close="$emit('close')"
13
- @closed="$emit('closed')"
14
- >
15
- <el-table
16
- :data="canRemoveTasks"
17
- border
18
- style="width: 100%"
19
- @select="select"
20
- >
21
- <el-table-column type="selection" width="55" />
22
- <el-table-column
23
- prop="transactorName"
24
- :label="$t('superPage.transactorName')"
25
- width="180"
26
- />
27
- <el-table-column
28
- prop="transactor"
29
- :label="$t('superPage.transactor')"
30
- width="180"
31
- />
32
- <el-table-column
33
- prop="trustorName"
34
- :label="$t('superPage.trustorName')"
35
- width="180"
36
- />
37
- </el-table>
38
- <template v-slot:footer>
39
- <div class="dialog-footer">
40
- <el-button type="primary" @click="selectRemoveUsers">
41
- {{ $t('superPageMessage.sure') }}
42
- </el-button>
43
- <el-button @click="$emit('close')">
44
- {{ $t('superPageMessage.cancel') }}
45
- </el-button>
46
- </div>
47
- </template>
48
- </el-dialog>
49
- </div>
50
- </template>
51
-
52
- <script>
53
- import { $on, $off, $once, $emit } from '../../utils/gogocodeTransfer'
54
- export default {
55
- name: 'RemoveSignerDialog',
56
- components: {},
57
- props: {
58
- taskId: {
59
- type: Number,
60
- default: null,
61
- },
62
- // 当前环节所有待办任务集合
63
- activeTasks: {
64
- type: Array,
65
- default: null,
66
- },
67
- },
68
- data() {
69
- const canRemoveTasks = this.getCanRemoveTasks()
70
- return {
71
- selections: [],
72
- canRemoveTasks, // 除当前任务外,所有任务都可移除
73
- }
74
- },
75
- methods: {
76
- select(selection) {
77
- this.selections = selection
78
- },
79
- selectRemoveUsers() {
80
- if (this.selections.length === 0) {
81
- this.$message({
82
- showClose: true,
83
- type: 'warning',
84
- message: this.$t('superPageMessage.pleaseSelectRemoverUsers'),
85
- })
86
- return
87
- }
88
- $emit(this, 'result', this.selections)
89
- },
90
- // 获得可减签的任务集合。除当前任务外,所有任务都可移除
91
- getCanRemoveTasks() {
92
- if (this.activeTasks && this.taskId) {
93
- // 过滤掉当前任务
94
- return this.activeTasks.filter((task) =>
95
- this.taskId !== task.id ? task.id : task.ID ? task.ID : null
96
- )
97
- }
98
- return []
99
- },
100
- },
101
- emits: ['open', 'opend', 'close', 'closed', 'result'],
102
- }
103
- </script>
1
+ <template>
2
+ <div>
3
+ <el-dialog
4
+ model-value
5
+ :title="$t('superPage.selectRemoveUsers')"
6
+ :close-on-click-modal="false"
7
+ append-to-body
8
+ width="30%"
9
+ max-height="400"
10
+ @open="$emit('open')"
11
+ @opend="$emit('opend')"
12
+ @close="$emit('close')"
13
+ @closed="$emit('closed')"
14
+ >
15
+ <el-table
16
+ :data="canRemoveTasks"
17
+ border
18
+ style="width: 100%"
19
+ @select="select"
20
+ >
21
+ <el-table-column type="selection" width="55" />
22
+ <el-table-column
23
+ prop="transactorName"
24
+ :label="$t('superPage.transactorName')"
25
+ width="180"
26
+ />
27
+ <el-table-column
28
+ prop="transactor"
29
+ :label="$t('superPage.transactor')"
30
+ width="180"
31
+ />
32
+ <el-table-column
33
+ prop="trustorName"
34
+ :label="$t('superPage.trustorName')"
35
+ width="180"
36
+ />
37
+ </el-table>
38
+ <template v-slot:footer>
39
+ <div class="dialog-footer">
40
+ <el-button type="primary" @click="selectRemoveUsers">
41
+ {{ $t('superPageMessage.sure') }}
42
+ </el-button>
43
+ <el-button @click="$emit('close')">
44
+ {{ $t('superPageMessage.cancel') }}
45
+ </el-button>
46
+ </div>
47
+ </template>
48
+ </el-dialog>
49
+ </div>
50
+ </template>
51
+
52
+ <script>
53
+ import { $on, $off, $once, $emit } from '../../utils/gogocodeTransfer'
54
+ export default {
55
+ name: 'RemoveSignerDialog',
56
+ components: {},
57
+ props: {
58
+ taskId: {
59
+ type: Number,
60
+ default: null,
61
+ },
62
+ // 当前环节所有待办任务集合
63
+ activeTasks: {
64
+ type: Array,
65
+ default: null,
66
+ },
67
+ },
68
+ data() {
69
+ const canRemoveTasks = this.getCanRemoveTasks()
70
+ return {
71
+ selections: [],
72
+ canRemoveTasks, // 除当前任务外,所有任务都可移除
73
+ }
74
+ },
75
+ methods: {
76
+ select(selection) {
77
+ this.selections = selection
78
+ },
79
+ selectRemoveUsers() {
80
+ if (this.selections.length === 0) {
81
+ this.$message({
82
+ showClose: true,
83
+ type: 'warning',
84
+ message: this.$t('superPageMessage.pleaseSelectRemoverUsers'),
85
+ })
86
+ return
87
+ }
88
+ $emit(this, 'result', this.selections)
89
+ },
90
+ // 获得可减签的任务集合。除当前任务外,所有任务都可移除
91
+ getCanRemoveTasks() {
92
+ if (this.activeTasks && this.taskId) {
93
+ // 过滤掉当前任务
94
+ return this.activeTasks.filter((task) =>
95
+ this.taskId !== task.id ? task.id : task.ID ? task.ID : null
96
+ )
97
+ }
98
+ return []
99
+ },
100
+ },
101
+ emits: ['open', 'opend', 'close', 'closed', 'result'],
102
+ }
103
+ </script>
@@ -1,79 +1,79 @@
1
- <template>
2
- <div>
3
- <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
4
- <el-tab-pane
5
- v-for="tab in colSetting.options.tabContent"
6
- :key="tab.code"
7
- :label="tab.label"
8
- :name="tab.code"
9
- >
10
- <widget-sub-tab-pane-page
11
- :page-code="pageCode"
12
- :data-id="dataId"
13
- :one-tab-content="tab.list ? tab.list : []"
14
- :workflow-id="workflowId"
15
- :task-id="taskId"
16
- @update-value="updateValues"
17
- />
18
- </el-tab-pane>
19
- </el-tabs>
20
- </div>
21
- </template>
22
-
23
- <script>
24
- import { $on, $off, $once, $emit } from '../../utils/gogocodeTransfer'
25
- import WidgetSubTabPanePage from './widget-sub-tab-pane-page'
26
- import util from './util/util'
27
- import eventBus from './util/eventBus'
28
- export default {
29
- name: 'SubTabPage',
30
- components: {
31
- WidgetSubTabPanePage,
32
- },
33
- props: {
34
- // 页面编码
35
- pageCode: {
36
- type: String,
37
- default: null,
38
- },
39
- // 表单页面修改记录id
40
- dataId: {
41
- type: Number,
42
- default: null,
43
- },
44
- // 流程表单页面办理任务时任务id
45
- taskId: {
46
- type: Number,
47
- default: null,
48
- },
49
- colSetting: {
50
- type: Object,
51
- default: null,
52
- },
53
- },
54
- data() {
55
- let activeName = ''
56
- const tabContent = this.colSetting.options.tabContent
57
- if (tabContent && tabContent.length > 0) {
58
- activeName = tabContent[0].code
59
- }
60
- return {
61
- activeName,
62
- workflowId: null, // 流程实例id,第1个子页签是流转历史时需要该参数
63
- }
64
- },
65
- created() {},
66
- mounted() {},
67
- methods: {
68
- handleClick(tab, event) {
69
- // 先清空实例id,为了更新显示流转历史
70
- this.workflowId = util.getWorkflowId(this.pageCode)
71
- $emit(eventBus, 'refreshHistory')
72
- },
73
- updateValues(sourceModel, sourceTableName, targetRowIndex) {
74
- $emit(this, 'update-value', sourceModel, sourceTableName, targetRowIndex)
75
- },
76
- },
77
- emits: ['update-value', 'refreshHistory'],
78
- }
79
- </script>
1
+ <template>
2
+ <div>
3
+ <el-tabs v-model="activeName" type="card" @tab-click="handleClick">
4
+ <el-tab-pane
5
+ v-for="tab in colSetting.options.tabContent"
6
+ :key="tab.code"
7
+ :label="tab.label"
8
+ :name="tab.code"
9
+ >
10
+ <widget-sub-tab-pane-page
11
+ :page-code="pageCode"
12
+ :data-id="dataId"
13
+ :one-tab-content="tab.list ? tab.list : []"
14
+ :workflow-id="workflowId"
15
+ :task-id="taskId"
16
+ @update-value="updateValues"
17
+ />
18
+ </el-tab-pane>
19
+ </el-tabs>
20
+ </div>
21
+ </template>
22
+
23
+ <script>
24
+ import { $on, $off, $once, $emit } from '../../utils/gogocodeTransfer'
25
+ import WidgetSubTabPanePage from './widget-sub-tab-pane-page'
26
+ import util from './util/util'
27
+ import eventBus from './util/eventBus'
28
+ export default {
29
+ name: 'SubTabPage',
30
+ components: {
31
+ WidgetSubTabPanePage,
32
+ },
33
+ props: {
34
+ // 页面编码
35
+ pageCode: {
36
+ type: String,
37
+ default: null,
38
+ },
39
+ // 表单页面修改记录id
40
+ dataId: {
41
+ type: Number,
42
+ default: null,
43
+ },
44
+ // 流程表单页面办理任务时任务id
45
+ taskId: {
46
+ type: Number,
47
+ default: null,
48
+ },
49
+ colSetting: {
50
+ type: Object,
51
+ default: null,
52
+ },
53
+ },
54
+ data() {
55
+ let activeName = ''
56
+ const tabContent = this.colSetting.options.tabContent
57
+ if (tabContent && tabContent.length > 0) {
58
+ activeName = tabContent[0].code
59
+ }
60
+ return {
61
+ activeName,
62
+ workflowId: null, // 流程实例id,第1个子页签是流转历史时需要该参数
63
+ }
64
+ },
65
+ created() {},
66
+ mounted() {},
67
+ methods: {
68
+ handleClick(tab, event) {
69
+ // 先清空实例id,为了更新显示流转历史
70
+ this.workflowId = util.getWorkflowId(this.pageCode)
71
+ $emit(eventBus, 'refreshHistory')
72
+ },
73
+ updateValues(sourceModel, sourceTableName, targetRowIndex) {
74
+ $emit(this, 'update-value', sourceModel, sourceTableName, targetRowIndex)
75
+ },
76
+ },
77
+ emits: ['update-value', 'refreshHistory'],
78
+ }
79
+ </script>