jeecg-boot/ant-design-vue-jeecg/src/components/jeecgbiz/JSelectMultiUser.vue

46 lines
1.3 KiB
Java
Raw Blame History

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<template>
<!-- -->
<j-select-biz-component
:value="value"
:listUrl="url.list"
:columns="columns"
v-on="$listeners"
v-bind="attrs"
/>
</template>
<script>
import JSelectBizComponent from './JSelectBizComponent'
export default {
name: 'JSelectMultiUser',
components: { JSelectBizComponent },
props: ['value'],
data() {
return {
url: { list: '/sys/user/list' },
columns: [
{ title: '', align: 'center', width: '20%', widthRight: '70%', dataIndex: 'realname' },
{ title: '', align: 'center', width: '20%', dataIndex: 'username' },
{ title: '', align: 'center', width: '23%', dataIndex: 'phone' },
{ title: '', align: 'center', width: '23%', dataIndex: 'birthday' }
],
// 定义在这里的参数都是可以在外部传递覆盖的,可以更灵活的定制化使用的组件
default: {
name: '',
width: 1000,
displayKey: 'realname',
returnKeys: ['id', 'username'],
queryParamText: '',
}
}
},
computed: {
attrs() {
return Object.assign(this.default, this.$attrs)
}
}
}
</script>
<style lang="scss" scoped></style>