vue2-client 1.2.20 → 1.2.23

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,6 +1,6 @@
1
1
  {
2
2
  "name": "vue2-client",
3
- "version": "1.2.20",
3
+ "version": "1.2.23",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -276,7 +276,9 @@
276
276
  // 描述加载控制
277
277
  descriptionLoading: false,
278
278
  // 用于刷新按钮倒计时显示
279
- btnCountdownText: 5
279
+ btnCountdownText: 5,
280
+ // 当前登陆用户在数据库表中id,临时使用,之后会替换
281
+ empIdInDataBase: undefined
280
282
  }
281
283
  },
282
284
  mounted () {
@@ -492,10 +494,10 @@
492
494
  },
493
495
  // 确认工单按钮业务逻辑
494
496
  confirmTicketBtn () {
495
- const currentEmpId = this.getCurrentEmpId()
497
+ this.getCurrentEmpId()
496
498
  return post(TicketDetailsViewApi.confirmTicket, {
497
499
  ticketId: this.ticketId,
498
- empId: currentEmpId,
500
+ empId: this.empIdInDataBase,
499
501
  time: new Date()
500
502
  })
501
503
  .then(res => {
@@ -513,7 +515,14 @@
513
515
  },
514
516
  // 获取当前登陆员工ID
515
517
  getCurrentEmpId () {
516
- return this.currUser.id
518
+ return post(EmployeeDetailsViewApi.getEmployeeId, {
519
+ name: this.currUser.ename
520
+ })
521
+ .then(res => {
522
+ this.empIdInDataBase = res
523
+ }, err => {
524
+ console.log(err)
525
+ })
517
526
  },
518
527
  // 转移工单按钮业务逻辑
519
528
  transferBtn () {
@@ -663,7 +672,6 @@
663
672
  },
664
673
  // 控制关闭工单按钮可用状态
665
674
  closeBtnDisable () {
666
- // TODO 改变对比方式,改为用名称对比
667
675
  return this.step === 0 || this.disableCloseBtn || this.details.name != this.currUser.ename
668
676
  },
669
677
  // 优先级文字显示
@@ -1,14 +1,16 @@
1
- const EmployeeDetailsViewApi = {
2
- // 查询:获取员工详细信息
3
- getEmployeeDetails: '/webmeterapi/getEmployeeDetails',
4
- // 查询:获取员工上一周应答工单数量
5
- getConfirmTicketsCountWeekly: '/webmeterapi/getConfirmTicketsCountWeekly',
6
- // 查询:获取员工上一周完成工单数量
7
- getFinishedTicketsCountWeekly: '/webmeterapi/getFinishedTicketsCountWeekly',
8
- // 查询:是否存在此员工
9
- findEmpName: '/webmeterapi/findEmpName',
10
- // 查询:获取所有员工名,供前端展示备选项
11
- getAllEmployeeName: '/webmeterapi/getAllEmployeeName'
12
- }
13
-
14
- export { EmployeeDetailsViewApi }
1
+ const EmployeeDetailsViewApi = {
2
+ // 查询:获取员工详细信息
3
+ getEmployeeDetails: '/webmeterapi/getEmployeeDetails',
4
+ // 查询:获取员工上一周应答工单数量
5
+ getConfirmTicketsCountWeekly: '/webmeterapi/getConfirmTicketsCountWeekly',
6
+ // 查询:获取员工上一周完成工单数量
7
+ getFinishedTicketsCountWeekly: '/webmeterapi/getFinishedTicketsCountWeekly',
8
+ // 查询:是否存在此员工
9
+ findEmpName: '/webmeterapi/findEmpName',
10
+ // 查询:获取所有员工名,供前端展示备选项
11
+ getAllEmployeeName: '/webmeterapi/getAllEmployeeName',
12
+ // 查询:根据员工名,获取员工id
13
+ getEmployeeId: '/webmeterapi/getEmployeeId'
14
+ }
15
+
16
+ export { EmployeeDetailsViewApi }