wui-components-v2 1.1.1 → 1.1.3

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.
@@ -21,7 +21,7 @@ const props = defineProps<{
21
21
  ractions?: rowActions[]
22
22
  zpaging?: any
23
23
  enumColumn?: Enums
24
- detailButtonHandle?: () => void
24
+ detailButtonHandle?: (data: Entities) => void
25
25
  }>()
26
26
  const toast = useGlobalToast()
27
27
  const pageType = ref('')
@@ -89,7 +89,7 @@ function raction(subitem: rowActions) {
89
89
  // 跳转详情页面
90
90
  function detail() {
91
91
  if (props.detailButtonHandle) {
92
- props.detailButtonHandle()
92
+ props.detailButtonHandle(props.data)
93
93
  return
94
94
  }
95
95
  router.push(`/pages/details-page/index?sourceId=${props.sourceId}&id=${props.code}&title=${props.item.title}`)
@@ -12,7 +12,7 @@ defineOptions({
12
12
  name: 'WuiList',
13
13
  })
14
14
  defineProps<{
15
- detailButtonHandle?: () => void
15
+ detailButtonHandle?: (data: Entities) => void
16
16
  }>()
17
17
  const Zpaging = ref<any>(null)
18
18
  const config = ref<Config>({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "wui-components-v2",
3
- "version": "1.1.1",
3
+ "version": "1.1.3",
4
4
  "description": "wui 组件库",
5
5
  "author": "wgxshh",
6
6
  "license": "MIT",
package/utils/index.ts CHANGED
@@ -21,7 +21,7 @@ export function getCurrentPath() {
21
21
  * @returns 格式化后的数据
22
22
  */
23
23
  export function formatItemData(data: any, type: string) {
24
- if (type === 'relselect' || type === 'tree-entity-select') {
24
+ if (type === 'relselect' || type === 'tree-entity-select' || type === 'table-entity-select') {
25
25
  // 判断data是否为数组
26
26
  if (Array.isArray(data)) {
27
27
  const dataArr = data.map(item => item.split('@R@')[1]).join(',')