vue2-client 1.8.90 → 1.8.91

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/CHANGELOG.md CHANGED
@@ -1,6 +1,9 @@
1
1
  # Change Log
2
2
  > 所有关于本项目的变化都在该文档里。
3
3
 
4
+ **1.8.91 -2024-3-9 @陈博晨**
5
+ - 用户处理工单页面点击回退/提交修改工单状态的api
6
+
4
7
  **1.8.90 -2024-3-9 @江超**
5
8
  - 增加XAddForm自定义组表单项处理
6
9
 
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "vue2-client",
3
- "version": "1.8.90",
3
+ "version": "1.8.91",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "SET NODE_OPTIONS=--openssl-legacy-provider && vue-cli-service serve --no-eslint",
@@ -1,51 +1,51 @@
1
- <template>
2
- <div>
3
- <a-list v-show="!loading" size="small" :data-source="data">
4
- <a-list-item slot="renderItem" slot-scope="item">
5
- <div>
6
- <p><a @click="$emit('openFavorites', item.uuid)">{{ item.question }} </a></p>
7
- <p>{{ item.date }}</p>
8
- </div>
9
- <a class="delete_item">
10
- <a-icon type="close" @click="$emit('saveToFavorites', item.uuid)"/>
11
- </a>
12
- </a-list-item>
13
- </a-list>
14
- </div>
15
- </template>
16
-
17
- <script>
18
- import { indexedDB } from '@vue2-client/utils/indexedDB'
19
-
20
- export default {
21
- name: 'FavoriteList',
22
- data () {
23
- return {
24
- data: [],
25
- loading: false
26
- }
27
- },
28
- mounted () {
29
- this.loadData()
30
- },
31
- methods: {
32
- loadData () {
33
- console.warn(123)
34
- indexedDB.getAll((data) => {
35
- const realData = data.filter(item => item.data && item.data.uuid)
36
- .map(item => item.data)
37
- this.data = realData
38
- })
39
- }
40
- }
41
- }
42
- </script>
43
- <style lang="less" scoped>
44
- .delete_item {
45
- margin-left: 8px;
46
- color: #333;
47
- }
48
- p {
49
- margin: 0
50
- }
51
- </style>
1
+ <template>
2
+ <div>
3
+ <a-list v-show="!loading" size="small" :data-source="data">
4
+ <a-list-item slot="renderItem" slot-scope="item">
5
+ <div>
6
+ <p><a @click="$emit('openFavorites', item.uuid)">{{ item.question }} </a></p>
7
+ <p>{{ item.date }}</p>
8
+ </div>
9
+ <a class="delete_item">
10
+ <a-icon type="close" @click="$emit('saveToFavorites', item.uuid)"/>
11
+ </a>
12
+ </a-list-item>
13
+ </a-list>
14
+ </div>
15
+ </template>
16
+
17
+ <script>
18
+ import { indexedDB } from '@vue2-client/utils/indexedDB'
19
+
20
+ export default {
21
+ name: 'FavoriteList',
22
+ data () {
23
+ return {
24
+ data: [],
25
+ loading: false
26
+ }
27
+ },
28
+ mounted () {
29
+ this.loadData()
30
+ },
31
+ methods: {
32
+ loadData () {
33
+ console.warn(123)
34
+ indexedDB.getAll((data) => {
35
+ const realData = data.filter(item => item.data && item.data.uuid)
36
+ .map(item => item.data)
37
+ this.data = realData
38
+ })
39
+ }
40
+ }
41
+ }
42
+ </script>
43
+ <style lang="less" scoped>
44
+ .delete_item {
45
+ margin-left: 8px;
46
+ color: #333;
47
+ }
48
+ p {
49
+ margin: 0
50
+ }
51
+ </style>
@@ -253,7 +253,7 @@
253
253
  </template>
254
254
 
255
255
  <script>
256
- import { TicketDetailsViewApi, post } from '@vue2-client/services/api'
256
+ import { TicketDetailsViewApi, post, manageApi } from '@vue2-client/services/api'
257
257
  import XFormTable from '@vue2-client/base-client/components/common/XFormTable/XFormTable'
258
258
  import submitTicketSuccess from './submitTicketSuccess'
259
259
  import Upload from '@vue2-client/base-client/components/common/Upload'
@@ -325,6 +325,29 @@ export default {
325
325
  this.form.contact = this.$route.query.contact
326
326
  this.form.phone = this.$route.query.phone
327
327
  this.fixedQueryForm.t_uploader = this.currUser.orgName
328
+ const params = {}
329
+ post(manageApi.getDictionaryValue, {}).then((res) => {
330
+ Object.assign(params, res)
331
+ const badgeItemArray = {}
332
+ for (const key of Object.keys(params)) {
333
+ badgeItemArray[key] = {}
334
+ for (const item of params[key]) {
335
+ let status
336
+ if (!item.status) {
337
+ status = 'none'
338
+ } else {
339
+ status = item.status
340
+ }
341
+ badgeItemArray[key][item.value] = {
342
+ status: status,
343
+ text: item.text
344
+ }
345
+ }
346
+ }
347
+ // 追加参数
348
+ localStorage.setItem(process.env.VUE_APP_DICTIONARY_KEY, JSON.stringify(params))
349
+ localStorage.setItem(process.env.VUE_APP_BADGE_KEY, JSON.stringify(badgeItemArray))
350
+ })
328
351
  },
329
352
  methods: {
330
353
  toDetail (record, id) {
@@ -3,7 +3,7 @@ import { formatRoutes } from '@vue2-client/utils/routerUtil'
3
3
  // 不需要登录拦截的路由配置
4
4
  const loginIgnore = {
5
5
  names: ['404', '403'], // 根据路由名称匹配
6
- paths: ['/login', '/submitTicket', '/ServiceReview', '/DynamicStatistics'], // 根据路由fullPath匹配
6
+ paths: ['/login', '/submitTicket', '/submitTicket/', '/ServiceReview', '/DynamicStatistics'], // 根据路由fullPath匹配
7
7
  /**
8
8
  * 判断路由是否包含在该配置中
9
9
  * @param route vue-router 的 route 对象
package/src/router.js CHANGED
@@ -11,6 +11,8 @@ const routes = [
11
11
  { path: '/Amis', component: () => import('@vue2-client/pages/AMisDemo/AMisDemo') },
12
12
  { path: '/Amis2', component: () => import('@vue2-client/pages/AMisDemo/AMisDemo2') },
13
13
  { path: '/DynamicStatistics', component: () => import('@vue2-client/pages/DynamicStatistics/index') },
14
+ { path: '/submitTicket', component: () => import('@vue2-client/pages/system/ticket') },
15
+ { path: '/submitTicket/', component: () => import('@vue2-client/pages/system/ticket') }
14
16
  // ... 其他路由
15
17
  ]
16
18
  export default routes
@@ -37,6 +37,8 @@ const TicketDetailsViewApi = {
37
37
  afterApplyFinalStepSubmit: '/api/af-system/logic/afterApplyFinalStepSubmit',
38
38
  // 保存用户每一步输入的表单内容
39
39
  saveApplyStepFormData: '/api/af-system/logic/saveApplyStepFormData',
40
+ // 用户点击 回退/提交 修改工单状态
41
+ clientSubmit: '/api/af-system/logic/clientSubmit'
40
42
  }
41
43
 
42
44
  export { TicketDetailsViewApi }
@@ -1,18 +1,18 @@
1
- import { post } from '@vue2-client/services/api/restTools'
2
-
3
- const entityApi = {
4
- // 根据ID查询数据
5
- getById: (entityName, id, data = {}, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
6
- return post(`/api/${serviceName}/entity/query/${entityName}/${id}`, data)
7
- },
8
- // 根据ID集合查询所有数据
9
- findAllByIds: (entityName, data, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
10
- return post(`/api/${serviceName}/entity/query/${entityName}`, data)
11
- },
12
- // 查询实体的总数量
13
- getCount: (entityName, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
14
- return post(`/api/${serviceName}/entity/queryCount/${entityName}`, {})
15
- }
16
- }
17
-
18
- export { entityApi }
1
+ import { post } from '@vue2-client/services/api/restTools'
2
+
3
+ const entityApi = {
4
+ // 根据ID查询数据
5
+ getById: (entityName, id, data = {}, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
6
+ return post(`/api/${serviceName}/entity/query/${entityName}/${id}`, data)
7
+ },
8
+ // 根据ID集合查询所有数据
9
+ findAllByIds: (entityName, data, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
10
+ return post(`/api/${serviceName}/entity/query/${entityName}`, data)
11
+ },
12
+ // 查询实体的总数量
13
+ getCount: (entityName, serviceName = process.env.VUE_APP_SYSTEM_NAME) => {
14
+ return post(`/api/${serviceName}/entity/queryCount/${entityName}`, {})
15
+ }
16
+ }
17
+
18
+ export { entityApi }
@@ -1,31 +1,31 @@
1
- /**
2
- * @description: createWaterMark.js 加水印功能
3
- */
4
- let waterMarkDOM
5
-
6
- const clearWaterMark = () => {
7
- if (waterMarkDOM) waterMarkDOM.remove()
8
- }
9
- /**
10
- * @description: 创建水印
11
- * @param waterMarkName 水印内容
12
- */
13
- export default function createWaterMark (waterMarkName) {
14
- clearWaterMark()
15
- if (!waterMarkName) {
16
- return
17
- }
18
- const width = window.parseInt(document.body.clientWidth)
19
- const canvasWidth = width / window.parseInt(width / 320)
20
- const fontFamily = window.getComputedStyle(document.body)['font-family']
21
- const fragment = document.createDocumentFragment()
22
- waterMarkDOM = document.createElement('div')
23
- waterMarkDOM.className = 'water-mark-wrap'
24
- let spanStr = ''
25
- for (let i = 0; i < 100; i++) {
26
- spanStr += `<span class="water-word" style=width:${canvasWidth}px;height:200px;font: ${fontFamily}>${waterMarkName}</span>`
27
- }
28
- waterMarkDOM.innerHTML = spanStr
29
- fragment.appendChild(waterMarkDOM)
30
- document.body.appendChild(fragment)
31
- }
1
+ /**
2
+ * @description: createWaterMark.js 加水印功能
3
+ */
4
+ let waterMarkDOM
5
+
6
+ const clearWaterMark = () => {
7
+ if (waterMarkDOM) waterMarkDOM.remove()
8
+ }
9
+ /**
10
+ * @description: 创建水印
11
+ * @param waterMarkName 水印内容
12
+ */
13
+ export default function createWaterMark (waterMarkName) {
14
+ clearWaterMark()
15
+ if (!waterMarkName) {
16
+ return
17
+ }
18
+ const width = window.parseInt(document.body.clientWidth)
19
+ const canvasWidth = width / window.parseInt(width / 320)
20
+ const fontFamily = window.getComputedStyle(document.body)['font-family']
21
+ const fragment = document.createDocumentFragment()
22
+ waterMarkDOM = document.createElement('div')
23
+ waterMarkDOM.className = 'water-mark-wrap'
24
+ let spanStr = ''
25
+ for (let i = 0; i < 100; i++) {
26
+ spanStr += `<span class="water-word" style=width:${canvasWidth}px;height:200px;font: ${fontFamily}>${waterMarkName}</span>`
27
+ }
28
+ waterMarkDOM.innerHTML = spanStr
29
+ fragment.appendChild(waterMarkDOM)
30
+ document.body.appendChild(fragment)
31
+ }