Files
certd/packages/ui/certd-client/src/views/crud/feature/local-v-model/local.vue
T
GitHub Actions Bot ad360e81cb 🔱: [client] sync upgrade with 21 commits [trident-sync]
perf: 优化antdv4 示例授权页面tree的样式
build: publish success
chore: 1
chore: 1
chore: 1
fix: getFileName支持item参数

https://github.com/fast-crud/fast-crud/issues/385
fix: fs-form独立使用支持插槽

https://github.com/fast-crud/fast-crud/issues/389
fix: 修复三级以上路由页面无法缓存的问题

https://github.com/fast-crud/fast-crud/issues/394
perf: form.wrapper.buttons支持compute动态计算
feat: 表单支持变更关闭前提醒保存,form.wrapper支持beforeClose事件
fix: 修复图片裁剪按钮上下和左右相反的bug

https://github.com/fast-crud/fast-crud/issues/402
perf: alioss getAuthorization接口支持后台返回key

https://github.com/fast-crud/fast-crud/issues/405
perf: alioss getAuthorization接口支持后台返回key

https://github.com/fast-crud/fast-crud/issues/405
perf: fs-dict-tree支持插槽

https://github.com/fast-crud/fast-crud/issues/407
perf: 单选、多选、select、tree-select、table-select 都提供selected-change事件,可以获取选中的dict选项
feat: table-select 支持查看模式

https://github.com/fast-crud/fast-crud/issues/413
perf: 优化fs-admin可以在手机上操作
chore: pnpm workspace问题优化
docs: 1
chore: antdv4 支持主题色选择
...
2024-06-15 18:32:36 +00:00

58 lines
1.2 KiB
Vue

<template>
<fs-crud ref="crudRef" v-bind="crudBinding" />
</template>
<script lang="ts">
import { defineComponent, onMounted, watch } from "vue";
import createCrudOptions from "./crud";
import {useFs, utils} from "@fast-crud/fast-crud";
export default defineComponent({
name: "FeatureLocalModelValueInput",
props: {
modelValue: {
default() {
return [];
}
}
},
setup(props) {
const { crudBinding, crudRef, crudExpose } = useFs({ createCrudOptions });
onMounted(() => {
//启用行编辑模式
crudExpose.editable.enable({ mode: "row" });
});
//通过导出modelValue, 可以导出成为一个input组件
watch(
() => {
return props.modelValue;
},
(value = []) => {
crudBinding.value.data = value;
},
{
immediate: true
}
);
// 通过crudBinding.value.data 可以获取表格实时数据
function showData() {
utils.logger.info("data:", crudBinding.value.data);
}
return {
crudBinding,
crudRef,
showData
};
}
});
</script>
<style lang="less">
.fs-crud-container.compact .el-table--border {
border-left: 1px solid #eee;
}
</style>