vue2-client 1.4.59 → 1.4.60

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 (102) hide show
  1. package/CHANGELOG.md +480 -477
  2. package/index.js +30 -30
  3. package/package.json +78 -78
  4. package/src/base-client/components/common/AddressSearchCombobox/AddressSearchCombobox.vue +225 -225
  5. package/src/base-client/components/common/CreateQuery/CreateQueryItem.vue +778 -778
  6. package/src/base-client/components/common/FormGroupEdit/FormGroupEdit.vue +151 -151
  7. package/src/base-client/components/common/FormGroupQuery/FormGroupQuery.vue +165 -165
  8. package/src/base-client/components/common/JSONToTree/jsontotree.vue +275 -275
  9. package/src/base-client/components/common/XAddNativeForm/XAddNativeForm.vue +327 -327
  10. package/src/base-client/components/common/XCard/XCard.vue +64 -64
  11. package/src/base-client/components/common/XForm/XForm.vue +274 -274
  12. package/src/base-client/components/common/XForm/XFormItem.vue +519 -471
  13. package/src/base-client/components/common/XFormTable/XFormTable.vue +570 -570
  14. package/src/base-client/components/common/XFormTable/index.md +96 -96
  15. package/src/base-client/components/common/XTreeOne/XTreeOne.vue +109 -109
  16. package/src/base-client/components/system/QueryParamsDetailsView/QueryParamsDetailsView.vue +281 -281
  17. package/src/base-client/components/ticket/TicketDetailsView/TicketDetailsView.vue +807 -807
  18. package/src/base-client/components/ticket/TicketDetailsView/index.md +29 -29
  19. package/src/base-client/components/ticket/TicketDetailsView/part/TicketDetailsFlow.vue +260 -260
  20. package/src/base-client/components/ticket/TicketSubmitSuccessView/TicketSubmitSuccessView.vue +532 -532
  21. package/src/base-client/components/ticket/TicketSubmitSuccessView/index.md +29 -29
  22. package/src/base-client/plugins/AppData.js +73 -73
  23. package/src/base-client/plugins/GetLoginInfoService.js +179 -179
  24. package/src/base-client/plugins/PagedList.js +177 -177
  25. package/src/base-client/plugins/compatible/LoginServiceOA.js +20 -20
  26. package/src/base-client/plugins/i18n-extend.js +32 -32
  27. package/src/components/Ellipsis/index.md +38 -38
  28. package/src/components/NumberInfo/index.md +43 -43
  29. package/src/components/STable/README.md +341 -341
  30. package/src/components/STable/index.js +318 -318
  31. package/src/components/Trend/index.md +45 -45
  32. package/src/components/checkbox/ColorCheckbox.vue +157 -157
  33. package/src/components/checkbox/ImgCheckbox.vue +163 -163
  34. package/src/components/exception/ExceptionPage.vue +70 -70
  35. package/src/components/form/FormRow.vue +52 -52
  36. package/src/components/index.js +36 -36
  37. package/src/components/menu/SideMenu.vue +62 -62
  38. package/src/components/menu/menu.js +273 -273
  39. package/src/components/page/header/index.less +40 -40
  40. package/src/components/setting/Setting.vue +235 -235
  41. package/src/components/table/StandardTable.vue +141 -141
  42. package/src/components/table/advance/ActionColumns.vue +158 -158
  43. package/src/components/table/advance/SearchArea.vue +355 -355
  44. package/src/components/tool/AStepItem.vue +60 -60
  45. package/src/components/tool/AvatarList.vue +68 -68
  46. package/src/components/tool/Drawer.vue +142 -142
  47. package/src/components/tool/TagSelect.vue +83 -83
  48. package/src/components/transition/PageToggleTransition.vue +97 -97
  49. package/src/config/CreateQueryConfig.js +7 -4
  50. package/src/config/default/admin.config.js +18 -18
  51. package/src/config/default/setting.config.js +44 -44
  52. package/src/config/replacer/resolve.config.js +67 -67
  53. package/src/layouts/AdminLayout.vue +174 -174
  54. package/src/layouts/CommonLayout.vue +42 -42
  55. package/src/layouts/ComponentLayoutOne.vue +47 -47
  56. package/src/layouts/PageLayout.vue +151 -151
  57. package/src/layouts/SinglePageView.vue +111 -111
  58. package/src/layouts/footer/PageFooter.vue +49 -49
  59. package/src/layouts/header/AdminHeader.vue +104 -104
  60. package/src/layouts/header/HeaderNotice.vue +167 -167
  61. package/src/layouts/header/HeaderSearch.vue +67 -67
  62. package/src/layouts/header/InstitutionDetail.vue +181 -181
  63. package/src/layouts/header/index.less +92 -92
  64. package/src/layouts/tabs/TabsHead.vue +190 -190
  65. package/src/layouts/tabs/TabsView.vue +379 -379
  66. package/src/mock/goods/index.js +108 -108
  67. package/src/pages/exception/404.vue +25 -25
  68. package/src/pages/login/Login.vue +348 -348
  69. package/src/pages/report/ReportTable.js +124 -124
  70. package/src/pages/report/ReportTableHome.vue +28 -28
  71. package/src/pages/resourceManage/orgListManage.vue +98 -98
  72. package/src/pages/system/dictionary/index.vue +43 -43
  73. package/src/pages/system/file/index.vue +317 -317
  74. package/src/pages/system/monitor/loginInfor/index.vue +36 -36
  75. package/src/pages/system/monitor/operLog/index.vue +36 -36
  76. package/src/pages/system/queryParams/index.vue +43 -43
  77. package/src/router/async/config.async.js +27 -27
  78. package/src/router/async/router.map.js +68 -68
  79. package/src/router/guards.js +104 -104
  80. package/src/router/index.js +27 -27
  81. package/src/services/api/DictionaryDetailsViewApi.js +6 -6
  82. package/src/services/api/LogDetailsViewApi.js +10 -10
  83. package/src/services/api/QueryParamsDetailsViewApi.js +6 -6
  84. package/src/services/api/TicketDetailsViewApi.js +34 -34
  85. package/src/services/api/cas.js +79 -79
  86. package/src/services/api/commonTempTable.js +10 -10
  87. package/src/services/api/index.js +17 -17
  88. package/src/services/api/logininfor/index.js +6 -6
  89. package/src/services/api/manage.js +8 -8
  90. package/src/services/apiService.js +13 -13
  91. package/src/services/user.js +53 -53
  92. package/src/store/modules/index.js +4 -4
  93. package/src/theme/default/nprogress.less +76 -76
  94. package/src/theme/default/style.less +47 -47
  95. package/src/utils/colors.js +107 -107
  96. package/src/utils/excel/Blob.js +180 -180
  97. package/src/utils/excel/Export2Excel.js +141 -141
  98. package/src/utils/formatter.js +68 -68
  99. package/src/utils/i18n.js +80 -80
  100. package/src/utils/theme-color-replacer-extend.js +91 -91
  101. package/src/utils/themeUtil.js +100 -100
  102. package/src/utils/util.js +230 -230
@@ -1,151 +1,151 @@
1
- <template>
2
- <a-drawer
3
- title="选择参数组"
4
- placement="right"
5
- :width="isMobile ? screenWidth : screenWidth * 0.85"
6
- :visible="visible"
7
- @close="onClose"
8
- >
9
- <x-add-form
10
- business-title="参数设置"
11
- business-type="编辑"
12
- :visible.sync="editQueryVisible"
13
- :json-data="formObj.formJson"
14
- :modify-model-data="modifyModelDataItem"
15
- :loading="loading"
16
- @onSubmit="submit"/>
17
- <a-list
18
- :grid="{gutter: 24, lg: 4, md: 3, sm: 1, xs: 1}"
19
- :dataSource="columnJson.groups"
20
- >
21
- <a-list-item slot="renderItem" slot-scope="item">
22
- <a-card :hoverable="true" @click="toEdit(item)">
23
- <a-card-meta >
24
- <div style="margin-bottom: 3px" slot="title">{{ item.group }}</div>
25
- <a-icon type="tags" slot="avatar" :style="{ fontSize:'2em' }"/>
26
- <div class="meta-content" slot="description">{{ item.describe }}</div>
27
- </a-card-meta>
28
- </a-card>
29
- </a-list-item>
30
- </a-list>
31
- </a-drawer>
32
- </template>
33
-
34
- <script>
35
- import { mapState } from 'vuex'
36
- import XAddForm from '@vue2-client/base-client/components/common/XAddForm/XAddForm'
37
- import { commonApi, post } from '@vue2-client/services/api'
38
-
39
- export default {
40
- name: 'FormGroupEdit',
41
- components: {
42
- XAddForm
43
- },
44
- data () {
45
- return {
46
- // 页面宽度
47
- screenWidth: document.documentElement.clientWidth,
48
- // 是否显示参数下发抽屉
49
- editQueryVisible: false,
50
- targetIndex: 0,
51
- columnJson: {},
52
- editIndex: -1,
53
- formObj: {
54
- groupName: '',
55
- formJson: []
56
- },
57
- modifyModelDataItem: {},
58
- // 参数设置业务执行状态
59
- loading: false
60
- }
61
- },
62
- mounted () {
63
- this.initView()
64
- },
65
- computed: {
66
- ...mapState('setting', ['isMobile'])
67
- },
68
- props: {
69
- visible: {
70
- type: Boolean,
71
- default: false
72
- },
73
- modifyModelData: {
74
- type: Object,
75
- default: () => {
76
- return {}
77
- }
78
- }
79
- },
80
- watch: {
81
- visible (rel) {
82
- if (rel) {
83
- this.initView()
84
- }
85
- }
86
- },
87
- methods: {
88
- // 初始化组件
89
- initView () {
90
- this.$emit('getColumnJson', val => {
91
- this.columnJson = val
92
- })
93
- },
94
- toEdit (item) {
95
- post(commonApi.getColumnsJson, { queryObject: item }).then(res => {
96
- this.formObj = res
97
- this.modifyModelDataItem = { data: this.modifyModelData[this.formObj.groupName] }
98
- this.editQueryVisible = true
99
- })
100
- },
101
- onClose () {
102
- this.$emit('update:visible', false)
103
- },
104
- submit (res) {
105
- if (res.valid) {
106
- this.loading = true
107
- const requestParameters = {
108
- paramsJson: {}
109
- }
110
- requestParameters.paramsJson[this.formObj.groupName] = {}
111
- for (const key of Object.keys(res.form)) {
112
- const realKey = key.substring(key.indexOf('_') + 1)
113
- requestParameters.paramsJson[this.formObj.groupName][realKey] = res.form[key]
114
- }
115
- this.$emit('onSubmit', requestParameters, result => {
116
- if (result) {
117
- this.$message.success('参数设置成功!')
118
- } else {
119
- this.$message.error('参数设置失败!')
120
- }
121
- this.loading = false
122
- this.editQueryVisible = false
123
- })
124
- } else {
125
- return false
126
- }
127
- }
128
- }
129
- }
130
- </script>
131
- <style lang="less" scoped>
132
- .card-avatar {
133
- width: 48px;
134
- height: 48px;
135
- border-radius: 48px;
136
- }
137
- .new-btn{
138
- border-radius: 2px;
139
- width: 100%;
140
- height: 187px;
141
- }
142
- .meta-content{
143
- position: relative;
144
- overflow: hidden;
145
- text-overflow: ellipsis;
146
- display: -webkit-box;
147
- height: 64px;
148
- -webkit-line-clamp: 3;
149
- -webkit-box-orient: vertical;
150
- }
151
- </style>
1
+ <template>
2
+ <a-drawer
3
+ title="选择参数组"
4
+ placement="right"
5
+ :width="isMobile ? screenWidth : screenWidth * 0.85"
6
+ :visible="visible"
7
+ @close="onClose"
8
+ >
9
+ <x-add-form
10
+ business-title="参数设置"
11
+ business-type="编辑"
12
+ :visible.sync="editQueryVisible"
13
+ :json-data="formObj.formJson"
14
+ :modify-model-data="modifyModelDataItem"
15
+ :loading="loading"
16
+ @onSubmit="submit"/>
17
+ <a-list
18
+ :grid="{gutter: 24, lg: 4, md: 3, sm: 1, xs: 1}"
19
+ :dataSource="columnJson.groups"
20
+ >
21
+ <a-list-item slot="renderItem" slot-scope="item">
22
+ <a-card :hoverable="true" @click="toEdit(item)">
23
+ <a-card-meta >
24
+ <div style="margin-bottom: 3px" slot="title">{{ item.group }}</div>
25
+ <a-icon type="tags" slot="avatar" :style="{ fontSize:'2em' }"/>
26
+ <div class="meta-content" slot="description">{{ item.describe }}</div>
27
+ </a-card-meta>
28
+ </a-card>
29
+ </a-list-item>
30
+ </a-list>
31
+ </a-drawer>
32
+ </template>
33
+
34
+ <script>
35
+ import { mapState } from 'vuex'
36
+ import XAddForm from '@vue2-client/base-client/components/common/XAddForm/XAddForm'
37
+ import { commonApi, post } from '@vue2-client/services/api'
38
+
39
+ export default {
40
+ name: 'FormGroupEdit',
41
+ components: {
42
+ XAddForm
43
+ },
44
+ data () {
45
+ return {
46
+ // 页面宽度
47
+ screenWidth: document.documentElement.clientWidth,
48
+ // 是否显示参数下发抽屉
49
+ editQueryVisible: false,
50
+ targetIndex: 0,
51
+ columnJson: {},
52
+ editIndex: -1,
53
+ formObj: {
54
+ groupName: '',
55
+ formJson: []
56
+ },
57
+ modifyModelDataItem: {},
58
+ // 参数设置业务执行状态
59
+ loading: false
60
+ }
61
+ },
62
+ mounted () {
63
+ this.initView()
64
+ },
65
+ computed: {
66
+ ...mapState('setting', ['isMobile'])
67
+ },
68
+ props: {
69
+ visible: {
70
+ type: Boolean,
71
+ default: false
72
+ },
73
+ modifyModelData: {
74
+ type: Object,
75
+ default: () => {
76
+ return {}
77
+ }
78
+ }
79
+ },
80
+ watch: {
81
+ visible (rel) {
82
+ if (rel) {
83
+ this.initView()
84
+ }
85
+ }
86
+ },
87
+ methods: {
88
+ // 初始化组件
89
+ initView () {
90
+ this.$emit('getColumnJson', val => {
91
+ this.columnJson = val
92
+ })
93
+ },
94
+ toEdit (item) {
95
+ post(commonApi.getColumnsJson, { queryObject: item }).then(res => {
96
+ this.formObj = res
97
+ this.modifyModelDataItem = { data: this.modifyModelData[this.formObj.groupName] }
98
+ this.editQueryVisible = true
99
+ })
100
+ },
101
+ onClose () {
102
+ this.$emit('update:visible', false)
103
+ },
104
+ submit (res) {
105
+ if (res.valid) {
106
+ this.loading = true
107
+ const requestParameters = {
108
+ paramsJson: {}
109
+ }
110
+ requestParameters.paramsJson[this.formObj.groupName] = {}
111
+ for (const key of Object.keys(res.form)) {
112
+ const realKey = key.substring(key.indexOf('_') + 1)
113
+ requestParameters.paramsJson[this.formObj.groupName][realKey] = res.form[key]
114
+ }
115
+ this.$emit('onSubmit', requestParameters, result => {
116
+ if (result) {
117
+ this.$message.success('参数设置成功!')
118
+ } else {
119
+ this.$message.error('参数设置失败!')
120
+ }
121
+ this.loading = false
122
+ this.editQueryVisible = false
123
+ })
124
+ } else {
125
+ return false
126
+ }
127
+ }
128
+ }
129
+ }
130
+ </script>
131
+ <style lang="less" scoped>
132
+ .card-avatar {
133
+ width: 48px;
134
+ height: 48px;
135
+ border-radius: 48px;
136
+ }
137
+ .new-btn{
138
+ border-radius: 2px;
139
+ width: 100%;
140
+ height: 187px;
141
+ }
142
+ .meta-content{
143
+ position: relative;
144
+ overflow: hidden;
145
+ text-overflow: ellipsis;
146
+ display: -webkit-box;
147
+ height: 64px;
148
+ -webkit-line-clamp: 3;
149
+ -webkit-box-orient: vertical;
150
+ }
151
+ </style>
@@ -1,165 +1,165 @@
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
- :visible.sync="createQueryVisible"
12
- @saveSimpleFormQueryParams="saveQueryParams"
13
- />
14
- <a-list
15
- :dataSource="columnJsonCopy()"
16
- :grid="{gutter: 24, lg: 4, md: 3, sm: 1, xs: 1}"
17
- >
18
- <a-list-item slot="renderItem" slot-scope="item, index">
19
- <template v-if="item.type">
20
- <a-button class="new-btn" type="dashed" @click="toCreateQuery">
21
- <a-icon type="plus" />新增参数组
22
- </a-button>
23
- </template>
24
- <template v-else>
25
- <a-card :hoverable="true">
26
- <a-card-meta >
27
- <div slot="title" style="margin-bottom: 3px">{{ item.group }}</div>
28
- <a-icon slot="avatar" :style="{ fontSize:'2em' }" type="tags"/>
29
- <div slot="description" class="meta-content">{{ item.describe }}</div>
30
- </a-card-meta>
31
- <a slot="actions" @click="toEditQuery(index)">编辑</a>
32
- <a slot="actions" @click="toDelete(index)">删除</a>
33
- </a-card>
34
- </template>
35
- </a-list-item>
36
- </a-list>
37
- </a-drawer>
38
- </template>
39
-
40
- <script>
41
- import { mapState } from 'vuex'
42
- import CreateSimpleFormQuery from '@vue2-client/base-client/components/common/CreateSimpleFormQuery'
43
-
44
- export default {
45
- name: 'FormGroupQuery',
46
- components: {
47
- CreateSimpleFormQuery
48
- },
49
- data () {
50
- return {
51
- // 页面宽度
52
- screenWidth: document.documentElement.clientWidth,
53
- // 是否显示生成查询配置抽屉
54
- createQueryVisible: false,
55
- targetIndex: 0,
56
- columnJson: {},
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
- },
72
- watch: {
73
- visible (rel) {
74
- if (rel) {
75
- this.initView()
76
- }
77
- }
78
- },
79
- methods: {
80
- // 初始化组件
81
- initView () {
82
- this.editIndex = -1
83
- this.$emit('getColumnJson', val => {
84
- this.columnJson = val
85
- })
86
- },
87
- toCreateQuery () {
88
- this.editIndex = -1
89
- this.createQueryVisible = true
90
- },
91
- toEditQuery (index) {
92
- this.editIndex = index
93
- this.createQueryVisible = true
94
- },
95
- toDelete (index) {
96
- const _this = this
97
- this.$confirm({
98
- title: '您确定要删除该参数组?',
99
- content: '删除的参数组无法恢复',
100
- okText: '确定',
101
- okType: 'danger',
102
- cancelText: '取消',
103
- onOk () {
104
- _this.columnJson.groups.splice(index, 1)
105
- _this.$emit('saveQueryParams', _this.columnJson)
106
- }
107
- })
108
- },
109
- onClose () {
110
- this.$emit('update:visible', false)
111
- },
112
- // 存储查询配置信息
113
- saveQueryParams (source) {
114
- if (!this.columnJson.groups) {
115
- this.columnJson.groups = []
116
- }
117
- if (this.editIndex !== -1) {
118
- this.columnJson.groups[this.editIndex] = source
119
- } else {
120
- this.columnJson.groups.push(source)
121
- }
122
- this.$emit('saveQueryParams', this.columnJson)
123
- this.createQueryVisible = false
124
- },
125
- columnJsonCopy () {
126
- let groups
127
- if (this.columnJson.groups) {
128
- groups = JSON.parse(JSON.stringify(this.columnJson.groups))
129
- } else {
130
- groups = []
131
- }
132
- groups.push({ type: 'add' })
133
- return groups
134
- },
135
- editItem () {
136
- if (this.editIndex !== -1) {
137
- return JSON.parse(JSON.stringify(this.columnJson.groups[this.editIndex]))
138
- } else {
139
- return {}
140
- }
141
- }
142
- }
143
- }
144
- </script>
145
- <style lang="less" scoped>
146
- .card-avatar {
147
- width: 48px;
148
- height: 48px;
149
- border-radius: 48px;
150
- }
151
- .new-btn{
152
- border-radius: 2px;
153
- width: 100%;
154
- height: 187px;
155
- }
156
- .meta-content{
157
- position: relative;
158
- overflow: hidden;
159
- text-overflow: ellipsis;
160
- display: -webkit-box;
161
- height: 64px;
162
- -webkit-line-clamp: 3;
163
- -webkit-box-orient: vertical;
164
- }
165
- </style>
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
+ :visible.sync="createQueryVisible"
12
+ @saveSimpleFormQueryParams="saveQueryParams"
13
+ />
14
+ <a-list
15
+ :dataSource="columnJsonCopy()"
16
+ :grid="{gutter: 24, lg: 4, md: 3, sm: 1, xs: 1}"
17
+ >
18
+ <a-list-item slot="renderItem" slot-scope="item, index">
19
+ <template v-if="item.type">
20
+ <a-button class="new-btn" type="dashed" @click="toCreateQuery">
21
+ <a-icon type="plus" />新增参数组
22
+ </a-button>
23
+ </template>
24
+ <template v-else>
25
+ <a-card :hoverable="true">
26
+ <a-card-meta >
27
+ <div slot="title" style="margin-bottom: 3px">{{ item.group }}</div>
28
+ <a-icon slot="avatar" :style="{ fontSize:'2em' }" type="tags"/>
29
+ <div slot="description" class="meta-content">{{ item.describe }}</div>
30
+ </a-card-meta>
31
+ <a slot="actions" @click="toEditQuery(index)">编辑</a>
32
+ <a slot="actions" @click="toDelete(index)">删除</a>
33
+ </a-card>
34
+ </template>
35
+ </a-list-item>
36
+ </a-list>
37
+ </a-drawer>
38
+ </template>
39
+
40
+ <script>
41
+ import { mapState } from 'vuex'
42
+ import CreateSimpleFormQuery from '@vue2-client/base-client/components/common/CreateSimpleFormQuery'
43
+
44
+ export default {
45
+ name: 'FormGroupQuery',
46
+ components: {
47
+ CreateSimpleFormQuery
48
+ },
49
+ data () {
50
+ return {
51
+ // 页面宽度
52
+ screenWidth: document.documentElement.clientWidth,
53
+ // 是否显示生成查询配置抽屉
54
+ createQueryVisible: false,
55
+ targetIndex: 0,
56
+ columnJson: {},
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
+ },
72
+ watch: {
73
+ visible (rel) {
74
+ if (rel) {
75
+ this.initView()
76
+ }
77
+ }
78
+ },
79
+ methods: {
80
+ // 初始化组件
81
+ initView () {
82
+ this.editIndex = -1
83
+ this.$emit('getColumnJson', val => {
84
+ this.columnJson = val
85
+ })
86
+ },
87
+ toCreateQuery () {
88
+ this.editIndex = -1
89
+ this.createQueryVisible = true
90
+ },
91
+ toEditQuery (index) {
92
+ this.editIndex = index
93
+ this.createQueryVisible = true
94
+ },
95
+ toDelete (index) {
96
+ const _this = this
97
+ this.$confirm({
98
+ title: '您确定要删除该参数组?',
99
+ content: '删除的参数组无法恢复',
100
+ okText: '确定',
101
+ okType: 'danger',
102
+ cancelText: '取消',
103
+ onOk () {
104
+ _this.columnJson.groups.splice(index, 1)
105
+ _this.$emit('saveQueryParams', _this.columnJson)
106
+ }
107
+ })
108
+ },
109
+ onClose () {
110
+ this.$emit('update:visible', false)
111
+ },
112
+ // 存储查询配置信息
113
+ saveQueryParams (source) {
114
+ if (!this.columnJson.groups) {
115
+ this.columnJson.groups = []
116
+ }
117
+ if (this.editIndex !== -1) {
118
+ this.columnJson.groups[this.editIndex] = source
119
+ } else {
120
+ this.columnJson.groups.push(source)
121
+ }
122
+ this.$emit('saveQueryParams', this.columnJson)
123
+ this.createQueryVisible = false
124
+ },
125
+ columnJsonCopy () {
126
+ let groups
127
+ if (this.columnJson.groups) {
128
+ groups = JSON.parse(JSON.stringify(this.columnJson.groups))
129
+ } else {
130
+ groups = []
131
+ }
132
+ groups.push({ type: 'add' })
133
+ return groups
134
+ },
135
+ editItem () {
136
+ if (this.editIndex !== -1) {
137
+ return JSON.parse(JSON.stringify(this.columnJson.groups[this.editIndex]))
138
+ } else {
139
+ return {}
140
+ }
141
+ }
142
+ }
143
+ }
144
+ </script>
145
+ <style lang="less" scoped>
146
+ .card-avatar {
147
+ width: 48px;
148
+ height: 48px;
149
+ border-radius: 48px;
150
+ }
151
+ .new-btn{
152
+ border-radius: 2px;
153
+ width: 100%;
154
+ height: 187px;
155
+ }
156
+ .meta-content{
157
+ position: relative;
158
+ overflow: hidden;
159
+ text-overflow: ellipsis;
160
+ display: -webkit-box;
161
+ height: 64px;
162
+ -webkit-line-clamp: 3;
163
+ -webkit-box-orient: vertical;
164
+ }
165
+ </style>