n20-common-lib 2.4.38 → 2.4.40

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": "n20-common-lib",
3
- "version": "2.4.38",
3
+ "version": "2.4.40",
4
4
  "private": false,
5
5
  "main": "src/index.js",
6
6
  "scripts": {
@@ -1,6 +1,6 @@
1
1
  .content-box {
2
2
  box-sizing: border-box;
3
- margin: 0 8px 8px 8px;
3
+ margin: 0 4px 4px 4px;
4
4
  padding: 8px;
5
5
  border-radius: 0 0 6px 6px;
6
6
  height: var(--client-height);
@@ -8,7 +8,7 @@
8
8
  overflow: auto;
9
9
 
10
10
  &.element-doc {
11
- margin: 0 8px 8px 8px;
11
+ margin: 0 4px 4px 4px;
12
12
  padding: 8px;
13
13
  height: var(--client-height);
14
14
  overflow: auto;
@@ -1,7 +1,8 @@
1
- $--item-margin: 4px;
1
+ $--item-margin: 0;
2
2
  $--item-radius: 4px;
3
- $--layout-margin-top: 0;
3
+ $--layout-margin-top: 1px;
4
4
  $--item-hover-padding: 12px;
5
+ $--tabs-item-margin: 4px;
5
6
 
6
7
  .tabs-nav-wrap {
7
8
  &.el-tabs--card > .el-tabs__header {
@@ -18,37 +19,78 @@ $--item-hover-padding: 12px;
18
19
  padding-top: $--layout-margin-top;
19
20
  }
20
21
  .el-tabs__item {
22
+ position: relative;
21
23
  height: $--tabsnav-height;
22
24
  line-height: $--tabsnav-height;
23
25
  padding-left: $--item-hover-padding !important;
24
26
  padding-right: $--item-hover-padding !important;
25
27
  margin-right: $--item-margin;
26
- border-radius: $--item-radius $--item-radius 0 0;
27
- background: $--button-default-border-color;
28
28
  border: none !important;
29
+ border-radius: $--item-radius $--item-radius 0 0;
30
+ background: $--body-background;
29
31
  font-weight: $--font-weight-primary;
32
+ &:not(:first-child) {
33
+ &::before {
34
+ content: '';
35
+ position: absolute;
36
+ top: 15%;
37
+ left: 0;
38
+ height: 60%;
39
+ border-left: 1px solid $--color-text-secondary;
40
+ }
41
+ }
42
+
30
43
  &:first-child {
31
- margin-left: $--layou-margin;
44
+ margin-left: $--tabs-item-margin;
32
45
  .el-icon-close {
33
46
  display: none;
34
47
  }
35
48
  }
36
49
  &:last-child {
37
- margin-right: $--layou-margin;
50
+ margin-right: $--tabs-item-margin;
38
51
  }
39
52
 
40
53
  &:hover {
41
54
  color: $--color-text-primary;
42
- background: $--color-white;
43
- font-weight: $--font-weight-bold;
55
+ background-color: rgba(255, 255, 255, 0.6);
56
+ font-weight: $--font-weight-primary;
57
+ backdrop-filter: blur(5px);
58
+ &::before {
59
+ content: '';
60
+ position: absolute;
61
+ top: 15%;
62
+ right: 0;
63
+ height: 70%;
64
+ border: none;
65
+ }
66
+ }
67
+ &:hover + .el-tabs__item::before {
68
+ content: '';
69
+ position: absolute;
70
+ top: 15%;
71
+ right: 0;
72
+ height: 70%;
73
+ border: none;
44
74
  }
45
75
 
46
76
  &.is-active {
47
77
  color: $--color-text-primary;
48
78
  background: $--color-white;
49
- font-weight: $--font-weight-bold;
79
+ font-weight: $--font-weight-primary;
50
80
  }
51
81
 
82
+ &.is-active::before {
83
+ border: none;
84
+ }
85
+
86
+ &.is-active + .el-tabs__item::before {
87
+ content: '';
88
+ position: absolute;
89
+ top: 15%;
90
+ right: 0;
91
+ height: 70%;
92
+ border-left: none;
93
+ }
52
94
  &:focus.is-active.is-focus {
53
95
  box-shadow: none;
54
96
  border-radius: 0;
@@ -71,12 +113,12 @@ $--item-hover-padding: 12px;
71
113
  .el-tabs__nav-next,
72
114
  .el-tabs__nav-prev {
73
115
  width: 12px;
74
- height: $--tabsnav-height - 2 * $--layou-margin;
75
- line-height: $--tabsnav-height - 2 * $--layou-margin;
116
+ height: $--tabsnav-height - 2 * $--tabs-item-margin;
117
+ line-height: $--tabsnav-height - 2 * $--tabs-item-margin;
76
118
  border-radius: $--item-radius;
77
119
  background: $--color-white;
78
120
 
79
- top: $--layou-margin;
121
+ top: $--tabs-item-margin;
80
122
  z-index: 9;
81
123
  &:hover {
82
124
  background: $--body-background;
@@ -14,13 +14,13 @@
14
14
  <el-form-item v-if="authList.includes('isAddtask')" :label="'加签' | $lc" :error="addMsg" class="flex-1 m-b-s">
15
15
  <label slot="label">
16
16
  <span>{{ '加签' | $lc }}</span>
17
- <el-tooltip placement="top">
17
+ <!-- <el-tooltip placement="top">
18
18
  <span class="n20-icon-xinxitishi m-l-ss" style="position: static"></span>
19
19
  <div slot="content" style="width: 16em; line-height: 1.6">
20
20
  {{ '会签并行:增加一个会签节点,全部审批人同意才可通过审批' | $lc }}<br />
21
21
  {{ '普通串行:按照加签人数增加节点,每个节点审批通过才可完成当前加签流程' | $lc }}
22
22
  </div>
23
- </el-tooltip>
23
+ </el-tooltip> -->
24
24
  </label>
25
25
  <div class="flex-box">
26
26
  <el-select
@@ -30,15 +30,20 @@
30
30
  clearable
31
31
  :placeholder="'请选择加签类型' | $lc"
32
32
  style="width: 10em"
33
- @change="() => addTaskWay === '2' && addTaskType === '2' && (addTaskType = '3')"
34
33
  >
35
34
  <el-option :label="'向前加签' | $lc" value="2" />
36
35
  <el-option :label="'向后加签' | $lc" value="1" />
37
36
  </el-select>
38
- <el-select v-model="addTaskType" clearable :placeholder="'请选择审批方式' | $lc" style="width: 10em">
39
- <!-- <el-option :label="'普通节点' | $lc" value="1" /> -->
40
- <el-option :label="'会签并行' | $lc" value="2" :disabled="addTaskWay === '2'" />
41
- <el-option :label="'普通串行' | $lc" value="3" />
37
+ <el-select
38
+ v-model="addTaskType"
39
+ disabled
40
+ clearable
41
+ :placeholder="'请选择审批方式' | $lc"
42
+ style="width: 10em"
43
+ >
44
+ <el-option :label="'普通节点' | $lc" value="1" />
45
+ <!-- <el-option :label="'会签并行' | $lc" value="2" :disabled="addTaskWay === '2'" /> -->
46
+ <!-- <el-option :label="'普通串行' | $lc" value="3" /> -->
42
47
  </el-select>
43
48
  <el-input
44
49
  class="flex-item"
@@ -95,8 +100,10 @@
95
100
  />
96
101
  </el-form-item>
97
102
  </el-form>
98
-
99
- <div class="text-c">
103
+ <div v-if="authList.includes('byAddTask') && addTaskList.length > 0" class="text-c">
104
+ <el-button v-if="authList.includes('approval')" type="primary" @click="approvalFn">{{ '加 签' | $lc }}</el-button>
105
+ </div>
106
+ <div v-else class="text-c">
100
107
  <el-button v-if="authList.includes('approval')" type="primary" @click="approvalFn">{{ '批 准' | $lc }}</el-button>
101
108
  <el-button v-if="showApprovalTo" type="primary" @click="approvalToV = true">{{ '批准至' | $lc }}</el-button>
102
109
  <el-button v-if="authList.includes('rejectTo')" plain @click="rejectToB">{{ '驳回至' | $lc }}</el-button>
@@ -250,7 +257,7 @@ export default {
250
257
  addMsg: undefined,
251
258
  setAddtaskV: false,
252
259
  addTaskList: [],
253
- addTaskType: undefined,
260
+ addTaskType: '1',
254
261
  preAddTask: false,
255
262
  addTaskWay: undefined,
256
263
  rejectToV: false,
@@ -55,6 +55,10 @@ export default {
55
55
  type: Function,
56
56
  default: undefined
57
57
  },
58
+ customTemplateDownload: {
59
+ type: Function,
60
+ default: undefined
61
+ },
58
62
  validateResult: {
59
63
  type: Object,
60
64
  default: undefined
@@ -118,9 +122,13 @@ export default {
118
122
  })
119
123
  },
120
124
  downFn() {
121
- axios.get(this.templateUrl, null, { responseType: 'blob', ...this.templateOpt }).then((blob) => {
122
- downloadBlob(blob, this.fileName)
123
- })
125
+ if (this.customTemplateDownload) {
126
+ this.customTemplateDownload()
127
+ } else {
128
+ axios.get(this.templateUrl, null, { responseType: 'blob', ...this.templateOpt }).then((blob) => {
129
+ downloadBlob(blob, this.fileName)
130
+ })
131
+ }
124
132
  }
125
133
  }
126
134
  }
@@ -50,6 +50,8 @@ export default {
50
50
  },
51
51
  methods: {
52
52
  tabClick(C) {
53
+ console.log(C)
54
+
53
55
  let item = C.$attrs['tab-info']
54
56
  this.$emit('tab-click', item)
55
57
  },
@@ -87,15 +87,15 @@ export default {
87
87
  },
88
88
  data() {
89
89
  let headerH = 48
90
- let tabsH = 35
91
- let clientM = 8
90
+ let tabsH = 28
91
+ let clientM = 4
92
92
 
93
93
  return {
94
94
  dnsKey: this.isTest || (process.env.NODE_ENV === 'production' && process.env.VUE_APP_KEEP_ALIVE === 'true'),
95
95
  headerH,
96
96
  tabsH,
97
97
  clientM,
98
- clientHeight: document.documentElement.offsetHeight - headerH - tabsH - 2 * clientM,
98
+ clientHeight: document.documentElement.offsetHeight - headerH - tabsH - 1 * clientM,
99
99
  collapse: window.localStorage.getItem('aside-nav-collapse') === 'true',
100
100
 
101
101
  menusC: [],
@@ -93,14 +93,14 @@ export default {
93
93
  data() {
94
94
  let headerH = 48
95
95
  let tabsH = 28
96
- let clientM = 0
96
+ let clientM = 4
97
97
 
98
98
  return {
99
99
  dnsKey: this.isTest || (process.env.NODE_ENV === 'production' && process.env.VUE_APP_KEEP_ALIVE === 'true'),
100
100
  headerH,
101
101
  tabsH,
102
102
  clientM,
103
- clientHeight: document.documentElement.offsetHeight - headerH - tabsH - 2 * clientM,
103
+ clientHeight: document.documentElement.offsetHeight - headerH - tabsH - 1 * clientM,
104
104
  collapse: window.localStorage.getItem('aside-nav-collapse') === 'true',
105
105
 
106
106
  menusC: [],
package/src/i18n.json CHANGED
@@ -830,6 +830,9 @@
830
830
  "批准": {
831
831
  "en": "Approval"
832
832
  },
833
+ "加 签": {
834
+ "en": "Add signature"
835
+ },
833
836
  "消息中心": {
834
837
  "en": "Message center"
835
838
  },