diff --git a/src/components/XyTable/index.vue b/src/components/XyTable/index.vue
index 7b4fd53..26959ba 100644
--- a/src/components/XyTable/index.vue
+++ b/src/components/XyTable/index.vue
@@ -149,7 +149,7 @@ export default {
},
btnWidth: {
type: Number,
- default: 140,
+ default: 200,
},
// 分页相关
diff --git a/src/views/component/detail.vue b/src/views/component/detail.vue
new file mode 100644
index 0000000..5f01508
--- /dev/null
+++ b/src/views/component/detail.vue
@@ -0,0 +1,30 @@
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/component/dialog.vue b/src/views/component/dialog.vue
index c40e792..ab17c76 100644
--- a/src/views/component/dialog.vue
+++ b/src/views/component/dialog.vue
@@ -13,15 +13,15 @@ export default {
},
render(h) {
return h(
- "el-dialog",
+ "Modal",
{
props: {
title: "新增",
- visible: this.dialogVisible,
- width: "600px",
+ value: this.dialogVisible,
+ width: 80,
},
on: {
- "update:visible": (val) => {
+ "on-visible-change": (val) => {
this.dialogVisible = val;
},
},
@@ -30,6 +30,7 @@ export default {
h(
"el-form",
{
+ class: "form-body",
ref: "elForm",
props: {
model: this.form,
@@ -46,6 +47,7 @@ export default {
h(
"el-form-item",
{
+ class: "form-body__item",
ref: `elFormItem${i.field}`,
style: {
width: "100%",
@@ -154,6 +156,9 @@ export default {
h(
"el-button",
{
+ props: {
+ size: "mini"
+ },
on: {
click: () => (this.dialogVisible = false),
},
@@ -166,6 +171,7 @@ export default {
props: {
type: "warning",
plain: true,
+ size: 'mini'
},
on: {
click: () => this.init(),
@@ -178,6 +184,7 @@ export default {
{
props: {
type: "primary",
+ size: 'mini'
},
on: {
click: this.submit,
@@ -429,6 +436,8 @@ export default {
}
}
});
+
+ document.documentElement.style.setProperty('--column-num', Math.floor(newVal.length / 8).toString())
},
//immediate: true,
},
@@ -450,7 +459,13 @@ export default {
};
+
diff --git a/src/views/component/table.vue b/src/views/component/table.vue
index 7a51e00..81573e3 100644
--- a/src/views/component/table.vue
+++ b/src/views/component/table.vue
@@ -4,7 +4,7 @@
@@ -22,7 +22,7 @@
v-for="item in form"
:key="item.id"
:value="item.field"
- >{{ item.name }}{{ item.name }}
{{
+ >{{
item.key || item.value || item.name || item.no || item.mingcheng || item.id
}}
@@ -83,7 +83,7 @@
display: flex;
align-items: center;
"
- >至至
查询查询
{{ item.name }}{{ item.name }}
{{
+ >{{
item.key || item.value || item.name || item.no || item.mingcheng || item.id
}}
@@ -215,19 +215,19 @@
@click="
$refs['dialog'].setType('add'), $refs['dialog'].show()
"
- >新增新增
导入
导出
@@ -411,6 +411,16 @@ export default {
['admins',[]]
])
let { fields, relation } = res;
+ let fieldRes = (await fieldIndex(
+ {
+ page: 1,
+ page_size: 999,
+ custom_form_id: this.customForm.customFormId,
+ sort_name: "sort",
+ sort_type: "asc",
+ },
+ false
+ )).data;
if (
!fields ||
!relation ||
@@ -419,7 +429,8 @@ export default {
) {
throw new Error("fields或relation格式错误");
}
- fields.forEach((i, index) => {
+ console.log(fieldRes)
+ fieldRes?.forEach((i, index) => {
i._relations = relation.find((j) => j.local_key === i.field);
if (i.select_item && typeof i.select_item === 'object') {
let keys = Object.keys(i.select_item)
@@ -468,7 +479,7 @@ export default {
return (
- { paramMap.get(row[i.field].toString()) }
+ { paramMap.get(row[i.field]?.toString()) }
)
}
diff --git a/src/views/system/components/linkWith.vue b/src/views/system/components/linkWith.vue
index 9c0c33d..484efd1 100644
--- a/src/views/system/components/linkWith.vue
+++ b/src/views/system/components/linkWith.vue
@@ -19,7 +19,7 @@
@@ -58,7 +58,7 @@ export default {
}
}}>
{
- this.localFields.map(i => {
+ [{field:'id',name:'id'},...this.localFields].map(i => {
return (
)