修复树表上级关系绑定验证,优化CURD代码生成

This commit is contained in:
孟帅
2023-05-29 20:24:13 +08:00
parent d8024d73f8
commit c8a808fcfd
49 changed files with 1453 additions and 1001 deletions

View File

@@ -174,4 +174,4 @@
);
</script>
<style lang="less"></style>
<style lang="less"></style>

View File

@@ -6,6 +6,7 @@
<!-- 这是系统自动生成的CURD表格你可以将此行注释改为表格的描述 -->
</n-card>
</div>
<BasicForm
@register="register"
@submit="reloadTable"

View File

@@ -65,6 +65,36 @@ export const options = ref<Options>({
});
export const rules = {
categoryId: {
required: true,
trigger: ['blur', 'input'],
type: 'number',
message: '请输入分类ID',
},
title: {
required: true,
trigger: ['blur', 'input'],
type: 'string',
message: '请输入标题',
},
description: {
required: true,
trigger: ['blur', 'input'],
type: 'string',
message: '请输入描述',
},
content: {
required: true,
trigger: ['blur', 'input'],
type: 'string',
message: '请输入内容',
},
sort: {
required: true,
trigger: ['blur', 'input'],
type: 'number',
message: '请输入排序',
},
};
export const schemas = ref<FormSchema[]>([
@@ -171,6 +201,10 @@ export const columns = [
);
},
},
{
title: '所在城市',
key: 'cityId',
},
{
title: '显示开关',
key: 'switch',
@@ -217,6 +251,14 @@ export const columns = [
);
},
},
{
title: '创建者',
key: 'createdBy',
},
{
title: '更新者',
key: 'updatedBy',
},
{
title: '创建时间',
key: 'createdAt',

View File

@@ -154,7 +154,7 @@
<QuestionCircleOutlined />
</n-icon>
</template>
<span>只会强制覆盖需要生成的文件但不包含SQL文件</span>
<span>强制覆盖所有需要生成的代码文件但不包含菜单SQL文件</span>
</n-popover>
</n-space>
</n-checkbox-group>