vue2-client 1.22.6 → 1.22.7

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 (164) hide show
  1. package/.claude/settings.local.json +30 -30
  2. package/.env.his +19 -19
  3. package/.eslintrc.js +74 -74
  4. package/.history/.eslintrc_20260521171150.js +74 -0
  5. package/.history/.eslintrc_20260521171213.js +74 -0
  6. package/.history/src/base-client/components/common/HIS/HAddNativeForm/HAddNativeForm_20260601154443.vue +726 -0
  7. package/.history/src/base-client/components/common/HIS/HAddNativeForm/HAddNativeForm_20260601154700.vue +478 -0
  8. package/.history/src/base-client/components/common/HIS/HButtons/HButtons_20260512175435.vue +706 -0
  9. package/.history/src/base-client/components/common/HIS/HButtons/HButtons_20260512175450.vue +694 -0
  10. package/.history/src/base-client/components/common/HIS/HButtons/HButtons_20260611152602.vue +755 -0
  11. package/.history/src/base-client/components/common/HIS/HForm/HForm_20260513145941.vue +524 -0
  12. package/.history/src/base-client/components/common/HIS/HForm/HForm_20260513153133.vue +731 -0
  13. package/.history/src/base-client/components/common/HIS/HForm/HForm_20260513160316.vue +525 -0
  14. package/.history/src/base-client/components/common/HIS/HForm/HForm_20260601144150.vue +1046 -0
  15. package/.history/src/base-client/components/common/HIS/HFormTable/HFormTable_20260310142713.vue +512 -0
  16. package/.history/src/base-client/components/common/HIS/HFormTable/HFormTable_20260310145118.vue +511 -0
  17. package/.history/src/base-client/components/common/HIS/HFormTable/HFormTable_20260311094834.vue +696 -0
  18. package/.history/src/base-client/components/common/HIS/HFormTable/HFormTable_20260320143028.vue +693 -0
  19. package/.history/src/base-client/components/common/HIS/HFormTable/HFormTable_20260409101450.vue +677 -0
  20. package/.history/src/base-client/components/common/HIS/HTab/HTab_20260508164645.vue +758 -0
  21. package/.history/src/base-client/components/common/HIS/HTab/HTab_20260508164714.vue +693 -0
  22. package/.history/src/base-client/components/common/HIS/HTab/HTab_20260508171651.vue +716 -0
  23. package/.history/src/base-client/components/common/HIS/HTab/HTab_20260509133717.vue +695 -0
  24. package/.history/src/base-client/components/common/HIS/HTab/HTab_20260509171115.vue +664 -0
  25. package/.history/src/base-client/components/common/XAddNativeForm/XAddNativeForm_20260513140637.vue +1455 -0
  26. package/.history/src/base-client/components/common/XAddNativeForm/XAddNativeForm_20260513140935.vue +1441 -0
  27. package/.history/src/base-client/components/common/XAddNativeForm/XAddNativeForm_20260513150818.vue +1441 -0
  28. package/.history/src/base-client/components/common/XAddNativeForm/XAddNativeForm_20260513153119.vue +1442 -0
  29. package/.history/src/base-client/components/common/XAddNativeForm/XAddNativeForm_20260513153126.vue +1486 -0
  30. package/.history/src/base-client/components/common/XForm/XFormItem_20260513140854.vue +1607 -0
  31. package/.history/src/base-client/components/common/XMarkdownViewer/XMarkdownViewer_20260519140403.vue +643 -0
  32. package/.history/src/base-client/components/common/XMarkdownViewer/XMarkdownViewer_20260519140829.vue +628 -0
  33. package/.history/src/base-client/components/common/XMarkdownViewer/demo_20260519142824.vue +104 -0
  34. package/.history/src/base-client/components/common/XMarkdownViewer/demo_20260519143155.vue +102 -0
  35. package/.history/src/base-client/components/common/XReportGrid/XReport_20260309171231.vue +1241 -0
  36. package/.history/src/base-client/components/common/XReportGrid/XReport_20260309171441.vue +1223 -0
  37. package/.history/src/base-client/components/his/HAi/HAi_20260612174826.vue +472 -0
  38. package/.history/src/base-client/components/his/HAi/HAi_20260612175839.vue +538 -0
  39. package/.history/src/base-client/components/his/HAi/HAi_20260615103331.vue +650 -0
  40. package/.history/src/base-client/components/his/XHDescriptions/XHDescriptions_20260424134504.vue +1469 -0
  41. package/.history/src/base-client/components/his/XSidebar/XSidebar_20260610171133.vue +788 -0
  42. package/.history/src/base-client/components/his/XSidebar/XSidebar_20260610171151.vue +780 -0
  43. package/.history/src/base-client/components/his/XTransfer/XTransfer_20260511170841.vue +585 -0
  44. package/.history/src/base-client/components/his/XTransfer/XTransfer_20260511171138.vue +787 -0
  45. package/.history/src/base-client/components/his/XTransfer/XTransfer_20260512141830.vue +739 -0
  46. package/.history/src/components/STable/index_20260409155138.js +806 -0
  47. package/.history/src/components/STable/index_20260409155218.js +814 -0
  48. package/.history/src/expression/core/Expression_20260305164427.js +1371 -0
  49. package/.history/src/expression/core/Expression_20260305170258.js +1358 -0
  50. package/.history/src/expression/core/Program_20260305111830.js +944 -0
  51. package/.history/src/expression/core/Program_20260305112041.js +931 -0
  52. package/.history/src/logic/LogicRunner_20260304154306.js +170 -0
  53. package/.history/src/logic/LogicRunner_20260304155553.js +112 -0
  54. package/.history/src/logic/LogicRunner_20260305105834.js +112 -0
  55. package/.history/src/logic/LogicRunner_20260305112718.js +129 -0
  56. package/.history/src/logic/LogicRunner_20260305182436.js +133 -0
  57. package/.history/src/logic/LogicRunner_20260306151301.js +213 -0
  58. package/.history/src/logic/LogicRunner_20260306152419.js +213 -0
  59. package/.history/src/logic/plugins/common/DateTools_20260305154159.js +61 -0
  60. package/.history/src/logic/plugins/common/DateTools_20260305154217.js +44 -0
  61. package/.history/src/logic/plugins/common/DateTools_20260305161014.js +44 -0
  62. package/.history/src/logic/plugins/common/HttpTools_20260305164352.js +80 -0
  63. package/.history/src/logic/plugins/common/HttpTools_20260305170258.js +75 -0
  64. package/.history/src/logic/plugins/common/HttpTools_20260305171634.js +75 -0
  65. package/.history/src/logic/plugins/common/HttpTools_20260306152419.js +72 -0
  66. package/.history/src/services/api/restTools_20260427142149.js +245 -0
  67. package/.history/src/services/api/restTools_20260427142853.js +230 -0
  68. package/.history/src/services/api/restTools_20260519135558.js +230 -0
  69. package/.history/src/services/api/restTools_20260519140825.js +230 -0
  70. package/.history/src/services/api/restTools_20260519151223.js +230 -0
  71. package/.history/src/utils/indexedDB_20260306150918.js +593 -0
  72. package/.history/src/utils/indexedDB_20260306151301.js +586 -0
  73. package/.idea/af-vue2-client.iml +9 -0
  74. package/.idea/codeStyles/Project.xml +62 -0
  75. package/.idea/codeStyles/codeStyleConfig.xml +5 -0
  76. package/.idea/misc.xml +6 -0
  77. package/.idea/modules.xml +1 -1
  78. package/Components.md +60 -60
  79. package/index.js +31 -31
  80. package/jest-transform-stub.js +8 -8
  81. package/jest.setup.js +7 -7
  82. package/package.json +1 -1
  83. package/preview-input-box.html +180 -0
  84. package/src/assets/img/querySlotDemo.svg +15 -15
  85. package/src/base-client/components/common/AmapMarker/AmapPointRendering.vue +120 -120
  86. package/src/base-client/components/common/CitySelect/index.js +3 -3
  87. package/src/base-client/components/common/CitySelect/index.md +109 -109
  88. package/src/base-client/components/common/FormGroupEdit/index.js +3 -3
  89. package/src/base-client/components/common/FormGroupEdit/index.md +43 -43
  90. package/src/base-client/components/common/HIS/HForm/HForm.vue +1186 -1186
  91. package/src/base-client/components/common/JSONToTree/jsontotree.vue +271 -271
  92. package/src/base-client/components/common/PersonSetting/index.js +3 -3
  93. package/src/base-client/components/common/Tree/index.js +2 -2
  94. package/src/base-client/components/common/Upload/index.js +3 -3
  95. package/src/base-client/components/common/XAddNativeForm/index.md +146 -146
  96. package/src/base-client/components/common/XCard/XCard.vue +64 -64
  97. package/src/base-client/components/common/XDataDrawer/XDataDrawer.vue +180 -180
  98. package/src/base-client/components/common/XDataDrawer/index.js +3 -3
  99. package/src/base-client/components/common/XDataDrawer/index.md +41 -41
  100. package/src/base-client/components/common/XDescriptions/index.js +3 -3
  101. package/src/base-client/components/common/XDescriptions/index.md +382 -382
  102. package/src/base-client/components/common/XForm/index.md +178 -178
  103. package/src/base-client/components/common/XMarkdownViewer/demo.vue +102 -102
  104. package/src/base-client/components/common/XStepView/XStepView.vue +252 -252
  105. package/src/base-client/components/common/XStepView/index.js +3 -3
  106. package/src/base-client/components/common/XStepView/index.md +31 -31
  107. package/src/base-client/components/common/XTable/index.md +255 -255
  108. package/src/base-client/components/his/HAi/HAi.vue +349 -141
  109. package/src/base-client/components/his/XList/XList.vue +130 -17
  110. package/src/base-client/components/his/XTransfer/index.md +327 -327
  111. package/src/base-client/components/system/DictionaryDetailsView/DictionaryDetailsView.vue +232 -232
  112. package/src/base-client/plugins/Config.js +19 -19
  113. package/src/base-client/plugins/tabs-page-plugin.js +39 -39
  114. package/src/components/Charts/Bar.vue +62 -62
  115. package/src/components/Charts/ChartCard.vue +134 -134
  116. package/src/components/Charts/Liquid.vue +67 -67
  117. package/src/components/Charts/MiniArea.vue +39 -39
  118. package/src/components/Charts/MiniBar.vue +39 -39
  119. package/src/components/Charts/MiniProgress.vue +75 -75
  120. package/src/components/Charts/MiniSmoothArea.vue +40 -40
  121. package/src/components/Charts/Radar.vue +68 -68
  122. package/src/components/Charts/RankList.vue +77 -77
  123. package/src/components/Charts/TagCloud.vue +113 -113
  124. package/src/components/Charts/TransferBar.vue +64 -64
  125. package/src/components/Charts/Trend.vue +82 -82
  126. package/src/components/Charts/chart.less +12 -12
  127. package/src/components/Charts/smooth.area.less +13 -13
  128. package/src/components/NumberInfo/NumberInfo.vue +54 -54
  129. package/src/components/NumberInfo/index.js +3 -3
  130. package/src/components/NumberInfo/index.less +54 -54
  131. package/src/components/NumberInfo/index.md +43 -43
  132. package/src/components/STable/index.js +953 -953
  133. package/src/components/card/ChartCard.vue +79 -79
  134. package/src/components/chart/Bar.vue +60 -60
  135. package/src/components/chart/MiniArea.vue +67 -67
  136. package/src/components/chart/MiniBar.vue +59 -59
  137. package/src/components/chart/MiniProgress.vue +57 -57
  138. package/src/components/chart/Radar.vue +80 -80
  139. package/src/components/chart/RankingList.vue +60 -60
  140. package/src/components/chart/Trend.vue +79 -79
  141. package/src/components/chart/index.less +9 -9
  142. package/src/components/checkbox/ColorCheckbox.vue +157 -157
  143. package/src/components/input/IInput.vue +66 -66
  144. package/src/components/menu/SideMenu.vue +75 -75
  145. package/src/components/menu/menu.js +273 -273
  146. package/src/components/tool/AStepItem.vue +60 -60
  147. package/src/layouts/CommonLayout.vue +56 -56
  148. package/src/lib.js +1 -1
  149. package/src/mock/extend/index.js +84 -84
  150. package/src/mock/goods/index.js +108 -108
  151. package/src/pages/dashboard/workplace/WorkPlace.vue +141 -141
  152. package/src/pages/system/dictionary/index.vue +44 -44
  153. package/src/pages/system/monitor/loginInfor/index.vue +37 -37
  154. package/src/pages/system/monitor/operLog/index.vue +37 -37
  155. package/src/services/api/cas.js +79 -79
  156. package/src/store/modules/setting.js +119 -119
  157. package/src/utils/errorCode.js +6 -6
  158. package//350/277/201/347/247/273/346/227/245/345/277/227.md +15 -15
  159. package/.idea/MarsCodeWorkspaceAppSettings.xml +0 -7
  160. package/.idea/google-java-format.xml +0 -6
  161. package/.idea/inspectionProfiles/Project_Default.xml +0 -24
  162. package/.idea/jsLinters/eslint.xml +0 -6
  163. package/.idea/vue2-client.iml +0 -12
  164. package/.vscode/settings.json +0 -28
@@ -134,8 +134,8 @@
134
134
  @mouseenter="handleGroupMouseEnter(getGroupItemIndex(gIdx, index))"
135
135
  @mouseleave="handleMouseLeave"
136
136
  :class="{
137
- 'hover-active': hoveredIndex === getGroupItemIndex(gIdx, index),
138
- 'selected-active': enableSelectRow && currentSelectedIndex === getGroupItemIndex(gIdx, index)
137
+ 'hover-active': !isEditingIndex(getGroupItemIndex(gIdx, index)) && hoveredIndex === getGroupItemIndex(gIdx, index),
138
+ 'selected-active': !isEditingIndex(getGroupItemIndex(gIdx, index)) && enableSelectRow && currentSelectedIndex === getGroupItemIndex(gIdx, index)
139
139
  }"
140
140
  >
141
141
  <span
@@ -143,7 +143,19 @@
143
143
  :class="{ 'text-truncated': hoveredIndex === getGroupItemIndex(gIdx, index) }"
144
144
  :style="getTextStyle(getGroupItemIndex(gIdx, index))"
145
145
  >
146
- <template v-if="showNumber">{{ getGroupItemIndex(gIdx, index) + 1 }}. </template>{{ item.label }}
146
+ <template v-if="showNumber">{{ getGroupItemIndex(gIdx, index) + 1 }}. </template>
147
+ <template v-if="editingIndex === getGroupItemIndex(gIdx, index)">
148
+ <a-input
149
+ :value="editingValue"
150
+ size="small"
151
+ @input="editingValue = $event.target.value"
152
+ @blur="finishEditing(getGroupItemIndex(gIdx, index))"
153
+ @keyup.enter="$event.target.blur()"
154
+ />
155
+ </template>
156
+ <template v-else>
157
+ {{ item.label }}
158
+ </template>
147
159
  </span>
148
160
 
149
161
  <div v-if="button" class="button-group">
@@ -170,8 +182,12 @@
170
182
  class="group-more-icon"
171
183
  @click.stop="handleGroupIconClick(getGroupItemIndex(gIdx, index), $event)"
172
184
  />
173
- <a-menu slot="overlay" @click="({ key }) => handleGroupIconSelect(getGroupItemIndex(gIdx, index), key)">
174
- <a-menu-item v-for="opt in effectiveIconSelect" :key="opt.value">
185
+ <a-menu slot="overlay">
186
+ <a-menu-item
187
+ v-for="opt in effectiveIconSelect"
188
+ :key="opt.value"
189
+ @click="handleGroupIconSelect(getGroupItemIndex(gIdx, index), opt)"
190
+ >
175
191
  {{ opt.label }}
176
192
  </a-menu-item>
177
193
  </a-menu>
@@ -291,10 +307,10 @@ export default {
291
307
  type: String,
292
308
  default: 'af-his'
293
309
  },
294
- // 点击是否触发选中(默认不通过点击选中,仅手动控制)
310
+ // 点击是否触发选中(默认点击即选中)
295
311
  selectOnClick: {
296
312
  type: Boolean,
297
- default: false
313
+ default: true
298
314
  },
299
315
  // 受控选中索引;不传则内部维护
300
316
  selectedIndex: {
@@ -384,6 +400,9 @@ export default {
384
400
  groupIconDropdownVisible: false,
385
401
  activeGroupIconIndex: -1,
386
402
  iconSelect: [], // 图标下拉选项列表
403
+ editingIndex: -1,
404
+ editingValue: '',
405
+ currentEditingOption: null
387
406
  }
388
407
  },
389
408
  inject: ['getComponentByName'],
@@ -505,8 +524,10 @@ export default {
505
524
  this.busy = true
506
525
  this.loading = true
507
526
  this.nowPage = this.nowPage + this.pageSize
508
- this.fixedQueryForm.condition = `Limit ${this.nowPage}, ${this.pageSize}`
509
- runLogic(this.logicName, this.fixedQueryForm, 'af-his')
527
+ const queryForm = Object.assign({}, this.fixedQueryForm, {
528
+ condition: `Limit ${this.nowPage}, ${this.pageSize}`
529
+ })
530
+ runLogic(this.logicName, queryForm, 'af-his')
510
531
  .then(async res => {
511
532
  this.localData = [...this.localData, ...res]
512
533
  if (res.length < this.pageSize) {
@@ -752,6 +773,8 @@ export default {
752
773
  this.setSelectedIndex(-1)
753
774
  },
754
775
  refreshList(param) {
776
+ this.nowPage = 0
777
+ this.allLoaded = false
755
778
  this.getData(this.queryParamsName, param)
756
779
  },
757
780
  /**
@@ -808,19 +831,37 @@ export default {
808
831
  setSelectedById(id, field = 'id') {
809
832
  const list = this.listMode ? this.localData : this.data
810
833
  if (!Array.isArray(list)) return
811
- const index = list.findIndex(item => {
812
- if (Array.isArray(item)) {
813
- const f = item.find(d => d && d.label === field)
814
- return f && f.value === id
834
+ if (this.listMode) {
835
+ for (let gIdx = 0; gIdx < list.length; gIdx++) {
836
+ const row = list[gIdx]
837
+ if (!Array.isArray(row.titlelist)) continue
838
+ const innerIndex = row.titlelist.findIndex(item => item && item[field] === id)
839
+ if (innerIndex >= 0) {
840
+ this.setSelectedIndex(this.getGroupItemIndex(gIdx, innerIndex))
841
+ return
842
+ }
815
843
  }
816
- return item && item[field] === id
817
- })
844
+ return
845
+ }
846
+ const index = list.findIndex(item => item && item[field] === id)
818
847
  if (index >= 0) this.setSelectedIndex(index)
819
848
  },
820
849
  // 根据 label/value(卡片数组数据场景)匹配选中
821
850
  setSelectedByLabelValue(label, value) {
822
851
  const list = this.listMode ? this.localData : this.data
823
852
  if (!Array.isArray(list)) return
853
+ if (this.listMode) {
854
+ for (let gIdx = 0; gIdx < list.length; gIdx++) {
855
+ const row = list[gIdx]
856
+ if (!Array.isArray(row.titlelist)) continue
857
+ const innerIndex = row.titlelist.findIndex(item => item && item.label === label && item.value === value)
858
+ if (innerIndex >= 0) {
859
+ this.setSelectedIndex(this.getGroupItemIndex(gIdx, innerIndex))
860
+ return
861
+ }
862
+ }
863
+ return
864
+ }
824
865
  const index = list.findIndex(
825
866
  item => Array.isArray(item) && item.some(d => d && d.label === label && d.value === value)
826
867
  )
@@ -896,7 +937,74 @@ export default {
896
937
  handleGroupIconSelect(index, opt) {
897
938
  this.groupIconDropdownVisible = false
898
939
  this.activeGroupIconIndex = -1
899
- this.$emit('groupIconSelect', { index, option: opt })
940
+ try {
941
+ const opts = Array.isArray(this.effectiveIconSelect) ? this.effectiveIconSelect : []
942
+ console.log('[XList] effectiveIconSelect=', JSON.stringify(opts), 'click opt=', JSON.stringify(opt))
943
+ } catch (e) {}
944
+ const action = (opt && opt.action) ? String(opt.action).trim().toLowerCase() : ''
945
+ const isEdit = action === 'edit' || action === 'rename'
946
+ if (isEdit) {
947
+ this.editingIndex = index
948
+ this.editingValue = this.getEditingValue(index)
949
+ this.currentEditingOption = opt
950
+ this.$nextTick(() => {
951
+ const el = this.$el.querySelector('.editing-input')
952
+ if (el) el.focus()
953
+ })
954
+ return
955
+ }
956
+ const eventName = opt && typeof opt.event === 'string' ? opt.event : 'groupIconSelect'
957
+ const data = this.getLocalItemByIndex(index)
958
+ this.$emit(eventName, { index, option: opt, data })
959
+ },
960
+ // 获取当前编辑项的初始文本
961
+ getEditingValue(index) {
962
+ const globalIndex = index
963
+ const item = this.getLocalItemByIndex(globalIndex)
964
+ return item ? String(item.label || '') : ''
965
+ },
966
+ isEditingIndex(index) {
967
+ return index === this.editingIndex
968
+ },
969
+ // 根据全局索引获取当前本地数据项
970
+ getLocalItemByIndex(globalIndex) {
971
+ if (!Array.isArray(this.localData)) return null
972
+ for (const row of this.localData) {
973
+ const list = Array.isArray(row.titlelist) ? row.titlelist : []
974
+ if (globalIndex < list.length) {
975
+ return list[globalIndex]
976
+ }
977
+ globalIndex -= list.length
978
+ }
979
+ return null
980
+ },
981
+ // 编辑完成
982
+ finishEditing(index) {
983
+ const trimmed = (this.editingValue || '').trim()
984
+ const option = this.currentEditingOption
985
+ this.editingIndex = -1
986
+ this.editingValue = ''
987
+ this.currentEditingOption = null
988
+ if (trimmed) {
989
+ this.updateLocalItemLabel(index, trimmed)
990
+ }
991
+ const data = this.getLocalItemByIndex(index)
992
+ const eventName = option && typeof option.event === 'string' ? option.event : 'groupIconSelect'
993
+ this.$emit(eventName, { index, option, label: trimmed, data })
994
+ },
995
+ // 更新本地数据 label
996
+ updateLocalItemLabel(index, label) {
997
+ const cloned = JSON.parse(JSON.stringify(this.localData || []))
998
+ let current = index
999
+ for (const row of cloned) {
1000
+ const list = Array.isArray(row.titlelist) ? row.titlelist : []
1001
+ if (current < list.length) {
1002
+ list[current].label = label
1003
+ break
1004
+ }
1005
+ current -= list.length
1006
+ }
1007
+ this.localData = cloned
900
1008
  },
901
1009
  // 清除所有定时器
902
1010
  clearAllTimers() {
@@ -911,7 +1019,8 @@ export default {
911
1019
  },
912
1020
  // 选项框点击
913
1021
  handleOptionClick(index, action) {
914
- this.$emit('optionClick', { data: this.data[index], action })
1022
+ const data = this.getLocalItemByIndex(index)
1023
+ this.$emit('optionClick', { data, action })
915
1024
  },
916
1025
  // 获取文本样式(简化版本,主要依赖CSS类控制)
917
1026
  getTextStyle(index) {
@@ -1322,6 +1431,10 @@ export default {
1322
1431
 
1323
1432
  /* 分组模式样式(enableGroupStyle) */
1324
1433
  .x-list-enableGroupStyle {
1434
+ &.x-list-wrapper.list-wrapper {
1435
+ height: 100%;
1436
+ max-height: none !important;
1437
+ }
1325
1438
  .x-list-group {
1326
1439
  margin-bottom: 12px;
1327
1440
  }