vue2-client 1.18.60 → 1.18.62

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 (26) hide show
  1. package/package.json +1 -1
  2. package/src/base-client/components/common/PersonSetting/PersonSetting.vue +1 -1
  3. package/src/base-client/components/common/XForm/XForm.vue +9 -3
  4. package/src/base-client/components/index.js +0 -6
  5. package/src/base-client/components/ticket/TicketDetailsView/TicketDetailsView.vue +5 -1
  6. package/src/base-client/plugins/AppData.js +10 -5
  7. package/src/main.js +1 -1
  8. package/src/mock/user/routes.js +1 -1
  9. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowHandle.vue +8 -3
  10. package/src/pages/WorkflowDetail/WorkflowPageDetail/WorkFlowHandleReso.vue +12 -10
  11. package/src/router/async/config.async.js +0 -1
  12. package/src/services/api/index.js +0 -2
  13. package/src/base-client/components/common/CreateQuery/CreateQuery.vue +0 -669
  14. package/src/base-client/components/common/CreateQuery/CreateQueryItem.vue +0 -1014
  15. package/src/base-client/components/common/CreateQuery/index.js +0 -3
  16. package/src/base-client/components/common/CreateQuery/index.md +0 -42
  17. package/src/base-client/components/common/CreateSimpleFormQuery/CreateSimpleFormQuery.vue +0 -452
  18. package/src/base-client/components/common/CreateSimpleFormQuery/CreateSimpleFormQueryItem.vue +0 -511
  19. package/src/base-client/components/common/CreateSimpleFormQuery/index.js +0 -3
  20. package/src/base-client/components/common/CreateSimpleFormQuery/index.md +0 -42
  21. package/src/base-client/components/common/FormGroupQuery/FormGroupQuery.vue +0 -166
  22. package/src/base-client/components/common/FormGroupQuery/index.js +0 -3
  23. package/src/base-client/components/common/FormGroupQuery/index.md +0 -43
  24. package/src/base-client/components/system/QueryParamsDetailsView/QueryParamsDetailsView.vue +0 -281
  25. package/src/base-client/components/system/QueryParamsDetailsView/index.js +0 -3
  26. package/src/services/api/QueryParamsDetailsViewApi.js +0 -6
@@ -1,166 +0,0 @@
1
- <template>
2
- <a-drawer
3
- :visible="visible"
4
- :width="isMobile ? screenWidth : screenWidth * 0.85"
5
- placement="right"
6
- title="表单参数组配置"
7
- @close="onClose"
8
- >
9
- <create-simple-form-query
10
- :to-edit-json="editItem()"
11
- :as-a-params-group="true"
12
- :visible.sync="createQueryVisible"
13
- @saveQueryParams="saveQueryParams"
14
- />
15
- <a-list
16
- :dataSource="contentCopy()"
17
- :grid="{gutter: 24, lg: 4, md: 3, sm: 1, xs: 1}"
18
- >
19
- <a-list-item slot="renderItem" slot-scope="item, index">
20
- <template v-if="item.type">
21
- <a-button class="new-btn" type="dashed" @click="toCreateQuery">
22
- <a-icon type="plus" />新增参数组
23
- </a-button>
24
- </template>
25
- <template v-else>
26
- <a-card :hoverable="true">
27
- <a-card-meta >
28
- <div slot="title" style="margin-bottom: 3px">{{ item.group }}</div>
29
- <a-icon slot="avatar" :style="{ fontSize:'2em' }" type="tags"/>
30
- <div slot="description" class="meta-content">{{ item.describe }}</div>
31
- </a-card-meta>
32
- <a slot="actions" @click="toEditQuery(index)">编辑</a>
33
- <a slot="actions" @click="toDelete(index)">删除</a>
34
- </a-card>
35
- </template>
36
- </a-list-item>
37
- </a-list>
38
- </a-drawer>
39
- </template>
40
-
41
- <script>
42
- import { mapState } from 'vuex'
43
- import CreateSimpleFormQuery from '../CreateSimpleFormQuery'
44
-
45
- export default {
46
- name: 'FormGroupQuery',
47
- components: {
48
- CreateSimpleFormQuery
49
- },
50
- data () {
51
- return {
52
- // 页面宽度
53
- screenWidth: document.documentElement.clientWidth,
54
- // 是否显示生成查询配置抽屉
55
- createQueryVisible: false,
56
- targetIndex: 0,
57
- editIndex: -1
58
- }
59
- },
60
- mounted () {
61
- this.initView()
62
- },
63
- computed: {
64
- ...mapState('setting', ['isMobile'])
65
- },
66
- props: {
67
- visible: {
68
- type: Boolean,
69
- default: false
70
- },
71
- content: {
72
- type: Object,
73
- required: true
74
- }
75
- },
76
- watch: {
77
- visible (rel) {
78
- if (rel) {
79
- this.initView()
80
- }
81
- }
82
- },
83
- methods: {
84
- // 初始化组件
85
- initView () {
86
- this.editIndex = -1
87
- },
88
- toCreateQuery () {
89
- this.editIndex = -1
90
- this.createQueryVisible = true
91
- },
92
- toEditQuery (index) {
93
- this.editIndex = index
94
- this.createQueryVisible = true
95
- },
96
- toDelete (index) {
97
- const _this = this
98
- this.$confirm({
99
- title: '您确定要删除该参数组?',
100
- content: '删除的参数组无法恢复',
101
- okText: '确定',
102
- okType: 'danger',
103
- cancelText: '取消',
104
- onOk () {
105
- _this.content.groups.splice(index, 1)
106
- _this.$emit('saveQueryParams', _this.content)
107
- }
108
- })
109
- },
110
- onClose () {
111
- this.$emit('update:visible', false)
112
- },
113
- // 存储查询配置信息
114
- saveQueryParams (source) {
115
- if (!this.content.groups) {
116
- this.content.groups = []
117
- }
118
- if (this.editIndex !== -1) {
119
- this.content.groups[this.editIndex] = source
120
- } else {
121
- this.content.groups.push(source)
122
- }
123
- this.$emit('saveQueryParams', this.content)
124
- this.createQueryVisible = false
125
- },
126
- contentCopy () {
127
- let groups
128
- if (this.content.groups) {
129
- groups = JSON.parse(JSON.stringify(this.content.groups))
130
- } else {
131
- groups = []
132
- }
133
- groups.push({ type: 'add' })
134
- return groups
135
- },
136
- editItem () {
137
- if (this.editIndex !== -1) {
138
- return JSON.parse(JSON.stringify(this.content.groups[this.editIndex]))
139
- } else {
140
- return {}
141
- }
142
- }
143
- }
144
- }
145
- </script>
146
- <style lang="less" scoped>
147
- .card-avatar {
148
- width: 48px;
149
- height: 48px;
150
- border-radius: 48px;
151
- }
152
- .new-btn{
153
- border-radius: 2px;
154
- width: 100%;
155
- height: 187px;
156
- }
157
- .meta-content{
158
- position: relative;
159
- overflow: hidden;
160
- text-overflow: ellipsis;
161
- display: -webkit-box;
162
- height: 64px;
163
- -webkit-line-clamp: 3;
164
- -webkit-box-orient: vertical;
165
- }
166
- </style>
@@ -1,3 +0,0 @@
1
- import FormGroupQuery from './FormGroupQuery'
2
-
3
- export default FormGroupQuery
@@ -1,43 +0,0 @@
1
- # FormGroupQuery 表单参数组配置生成
2
-
3
- 提供表单参数组配置生成的快捷组件
4
-
5
-
6
-
7
- ## 何时使用
8
-
9
- 允许生成表单参数组
10
-
11
-
12
-
13
- 引用方式:
14
-
15
- ```javascript
16
- import FormGroupQuery from '@vue2-client/base-client/components/FormGroupQuery'
17
-
18
- export default {
19
- components: {
20
- FormGroupQuery
21
- }
22
- }
23
- ```
24
-
25
-
26
-
27
- ## 代码演示
28
-
29
- ```html
30
- <form-group-query
31
- @getColumnJson="getColumnJson"
32
- :visible.sync="createQueryVisible"
33
- @saveQueryParams="saveQueryParams"
34
- />
35
- ```
36
-
37
- ## API
38
-
39
- | 参数 | 说明 | 类型 | 默认值 |
40
- |------------------|------------|---------|-------|
41
- | visible | 是否显示 | Boolean | false |
42
- | @getColumnJson | 获取表单配置方法 | event | - |
43
- | @saveQueryParams | 存储查询配置信息事件 | event | - |
@@ -1,281 +0,0 @@
1
- <template>
2
- <div>
3
- <a-drawer
4
- ref="QueryParamsDetailsView"
5
- :visible="visible"
6
- :width="isMobile ? screenWidth : screenWidth * 0.85"
7
- placement="right"
8
- title="查询配置详情"
9
- @close="onClose"
10
- >
11
- <create-query
12
- :to-edit-json="editJson"
13
- :visible.sync="createQueryVisible"
14
- @saveQueryParams="saveQueryParams"
15
- />
16
- <a-modal
17
- :getContainer="getContainer"
18
- :visible="importJsonVisible"
19
- title="导入JSON配置"
20
- @cancel="importJsonVisible = false"
21
- @ok="importJsonHandleOk"
22
- >
23
- <a-textarea v-model="ImportEditJson" placeholder="输入现有的JSON配置"/>
24
- </a-modal>
25
- <a-spin :spinning="loadDetails">
26
- <a-page-header :title="details.f_name+(details.f_remark ? '(' + details.f_remark + ')' : '')">
27
- <div class="row">
28
- <div class="content">
29
- <a-descriptions :column="isMobile ? 1 : 2" size="small">
30
- <a-descriptions-item label="所属模块">{{ details.f_module }}</a-descriptions-item>
31
- <a-descriptions-item label="创建人">{{ details.f_inputtor }}</a-descriptions-item>
32
- <a-descriptions-item label="创建时间">{{ details.f_input_date }}</a-descriptions-item>
33
- <a-descriptions-item label="描述">{{ details.f_remark }}</a-descriptions-item>
34
- </a-descriptions>
35
- </div>
36
- </div>
37
- <!-- actions -->
38
- <template #extra>
39
- <a-button-group style="margin-right: 4px;">
40
- <a-button :loading="loadDetails" type="dashed" @click="initView">刷新</a-button>
41
- </a-button-group>
42
- <a-button-group style="margin-right: 4px;">
43
- </a-button-group>
44
- </template>
45
- <template slot="footer">
46
- <a-tabs :activeKey="tabActiveKey" :default-active-key="tabActiveKey" style="margin-bottom: 23px;" @change="handleTabChange">
47
- <template v-for="value in tabList">
48
- <a-tab-pane :key="value.key" :tab="value.tab"/>
49
- </template>
50
- </a-tabs>
51
- <div v-if="!loadDetails">
52
- <div v-if="tabActiveKey === '1'">
53
- <a-space>
54
- <a-button type="primary" @click="toCreateQuery">
55
- <a-icon :style="iconStyle" type="edit"/>编辑查询配置
56
- </a-button>
57
- <a-button type="primary" @click="importJsonVisible = true">
58
- <a-icon :style="iconStyle" type="api"/>导入查询配置
59
- </a-button>
60
- </a-space>
61
-
62
- <a-card :bordered="true" size="small" style="margin-top: 20px;" title="查询配置预览">
63
- <json-viewer :copyable="{copyText: '复制', copiedText: '已复制'}" :expand-depth="parseInt('100')" :value="editJson" style="overflow: auto;max-height: 440px"></json-viewer>
64
- </a-card>
65
- </div>
66
- </div>
67
- </template>
68
- </a-page-header>
69
- </a-spin>
70
- </a-drawer>
71
- </div>
72
- </template>
73
-
74
- <script>
75
- import JsonViewer from 'vue-json-viewer'
76
- import { mapGetters, mapState } from 'vuex'
77
- import { post, QueryParamsDetailsViewApi } from '@vue2-client/services/api'
78
- import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable'
79
- import CreateQuery from '@vue2-client/base-client/components/common/CreateQuery'
80
-
81
- export default {
82
- name: 'QueryParamsDetailsView',
83
- components: {
84
- JsonViewer,
85
- XFormTable,
86
- CreateQuery
87
- },
88
- data () {
89
- return {
90
- // 页面宽度
91
- screenWidth: document.documentElement.clientWidth,
92
- // Tab页签
93
- tabActiveKey: '1',
94
- // 图标样式
95
- iconStyle: {
96
- position: 'relative',
97
- top: '1px'
98
- },
99
- // 是否显示生成查询配置抽屉
100
- createQueryVisible: false,
101
- // 设备类型详情
102
- details: {
103
- f_module: '',
104
- f_name: '',
105
- f_remark: '',
106
- f_content: '',
107
- f_input_date: '',
108
- f_inputtor: ''
109
- },
110
- // 查询表单配置json
111
- editJson: {},
112
- ImportEditJson: '',
113
- // importJsonVisible
114
- // 导入json对话框
115
- importJsonVisible: false,
116
- tabList: [
117
- { key: '1', tab: '编辑查询配置' }
118
- ],
119
- // 详情加载
120
- loadDetails: false
121
- }
122
- },
123
- mounted () {
124
- this.initView()
125
- },
126
- computed: {
127
- ...mapGetters(['account/user']),
128
- ...mapState('account', { currUser: 'user' }),
129
- ...mapState('setting', ['isMobile'])
130
- },
131
- props: {
132
- id: {
133
- type: String,
134
- required: true
135
- },
136
- visible: {
137
- type: Boolean,
138
- default: false
139
- }
140
- },
141
- methods: {
142
- // 获取model渲染上下文
143
- getContainer () {
144
- // return document.getElementById('QueryParamsDetailsView')
145
- return this.$refs.QueryParamsDetailsView.$el
146
- },
147
- // 初始化组件
148
- initView () {
149
- this.tabActiveKey = '1'
150
- this.editJson = {}
151
- this.getDetails(this.id)
152
- },
153
- toCreateQuery () {
154
- this.createQueryVisible = true
155
- },
156
- importJsonHandleOk () {
157
- try {
158
- this.editJson = JSON.parse(this.ImportEditJson)
159
- } catch (e) {
160
- this.$message.warn('操作失败,输入配置不是JSON格式')
161
- }
162
- this.importJsonVisible = false
163
- },
164
- onClose () {
165
- this.$emit('update:visible', false)
166
- },
167
- // 获取详情信息
168
- getDetails (id) {
169
- this.loadDetails = true
170
- return post(QueryParamsDetailsViewApi.getQueryParamsDetails, {
171
- id: id
172
- }).then(res => {
173
- this.details = res
174
- this.loadDetails = false
175
- if (this.details.f_content) {
176
- this.editJson = JSON.parse(this.details.f_content)
177
- }
178
- }, err => {
179
- this.loadDetails = false
180
- console.error(err)
181
- })
182
- },
183
- // 存储查询配置信息
184
- saveQueryParams (source) {
185
- return post('/api/af-system/logic/updateQueryParamsData', {
186
- id: this.id,
187
- source: source
188
- }).then(res => {
189
- this.$message.success('保存查询配置成功')
190
- this.getDetails(this.id)
191
- }, err => {
192
- console.error(err)
193
- })
194
- },
195
- // Tab切换
196
- handleTabChange (key) {
197
- this.tabActiveKey = key
198
- }
199
- },
200
- watch: {
201
- 'visible' (val) {
202
- if (val) {
203
- this.initView()
204
- }
205
- }
206
- }
207
- }
208
- </script>
209
-
210
- <style lang="less" scoped>
211
- .business {
212
- color: #ffffff;
213
- }
214
- .business:enabled:hover {
215
- background-color: #85CE61 !important;
216
- border-color: #85CE61 !important;
217
- }
218
- .business:enabled {
219
- background-color: #67c23a;
220
- border-color: #67c23a;
221
- }
222
- .business:disabled {
223
- color: rgba(0, 0, 0, 0.25);
224
- }
225
- .detail-layout {
226
- margin-left: 44px;
227
- }
228
- .text {
229
- color: rgba(0, 0, 0, .45);
230
- }
231
-
232
- .heading {
233
- color: rgba(0, 0, 0, .85);
234
- font-size: 20px;
235
- }
236
-
237
- .no-data {
238
- color: rgba(0, 0, 0, .25);
239
- text-align: center;
240
- line-height: 64px;
241
- font-size: 16px;
242
-
243
- i {
244
- font-size: 24px;
245
- margin-right: 16px;
246
- position: relative;
247
- top: 3px;
248
- }
249
- }
250
-
251
- .mobile {
252
- .detail-layout {
253
- margin-left: unset;
254
- }
255
- .text {
256
-
257
- }
258
- .status-list {
259
- text-align: left;
260
- }
261
- }
262
-
263
- .row {
264
- display: flex;
265
-
266
- .content {
267
- -webkit-box-flex: 1;
268
- flex: auto;
269
- -ms-flex: auto;
270
- }
271
-
272
- .extra {
273
- flex: 0 1 auto;
274
- -webkit-box-flex: 0;
275
- -ms-flex: 0 1 auto;
276
- min-width: 242px;
277
- margin-left: 88px;
278
- text-align: right;
279
- }
280
- }
281
- </style>
@@ -1,3 +0,0 @@
1
- import QueryParamsDetailsView from './QueryParamsDetailsView'
2
-
3
- export default QueryParamsDetailsView
@@ -1,6 +0,0 @@
1
- const QueryParamsDetailsViewApi = {
2
- // 查询:获取查询配置详情
3
- getQueryParamsDetails: '/api/af-system/logic/getQueryParamsDetails'
4
- }
5
-
6
- export { QueryParamsDetailsViewApi }