n20-common-lib 2.7.45 → 2.7.47

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.7.45",
3
+ "version": "2.7.47",
4
4
  "private": false,
5
5
  "scripts": {
6
6
  "serve": "vue-cli-service serve",
@@ -250,7 +250,7 @@ export default {
250
250
  const calcSelectWidth = (item, value) => {
251
251
  let textMaxWidth = 426 - getWidth(item.label) - 16
252
252
  let textMinWidth = 76
253
- const multiple = item.props?.multiple || false
253
+ const multiple = item.props?.multiple || item?.multiple || false
254
254
  if (!multiple) {
255
255
  if (!value) {
256
256
  return textMinWidth + 'px'
@@ -279,12 +279,13 @@ export default {
279
279
  item.props?.valueKey || 'value',
280
280
  item.props?.labelKey || 'label'
281
281
  )
282
+ console.log(selectedName)
282
283
  if (value?.length > 1) {
283
284
  return getWidth(selectedName) + 32 > textMaxWidth
284
285
  ? textMaxWidth + 'px'
285
- : getWidth(selectedName) + 110 + 'px'
286
+ : getWidth(selectedName) + 32 + 'px'
286
287
  } else {
287
- return getWidth(selectedName) + 32 < textMinWidth ? textMinWidth + 'px' : getWidth(selectedName) + 84 + 'px'
288
+ return getWidth(selectedName) + 32 < textMinWidth ? textMinWidth + 'px' : getWidth(selectedName) + 48 + 'px'
288
289
  }
289
290
  }
290
291
  }
@@ -173,13 +173,13 @@
173
173
  </template>
174
174
 
175
175
  <script>
176
- import { $lc } from '../../utils/i18n/index'
177
176
  import axios from '../../utils/axios'
177
+ import { $lc } from '../../utils/i18n/index'
178
178
 
179
+ import { Message } from 'element-ui'
180
+ import forEachs from '../../utils/forEachs'
179
181
  import dialogWrap from '../Dialog/index.vue'
180
182
  import dragList from '../DragList/index.vue'
181
- import forEachs from '../../utils/forEachs'
182
- import { Message } from 'element-ui'
183
183
  export default {
184
184
  name: 'ShowColumn',
185
185
  components: { dialogWrap, dragList },
@@ -424,8 +424,11 @@ export default {
424
424
  // 自动保存设置的显示列
425
425
  this.userNo = sessionStorage.getItem('userNo')
426
426
  !this.isExport && this.autoSave && this.saveColumns(list)
427
-
427
+
428
428
  this.$emit('setColumns', list)
429
+ if (this.isExport) {
430
+ this.visible = false
431
+ }
429
432
  },
430
433
  saveColumns(list) {
431
434
  let columns = saveTransform(list, this.labelKey, this.isFilter)