type QueryField = { key: any; name: any; title: any; type: any; dict: any; url: any; query: any; boolean?: any; show: boolean; stable: boolean; } declare type QueryFields = T[]; type IPage = { pageNum: number, pageSize: number, total?: number } type IBaseField = { label: string, prop: string, width?:number, minWidth?:number, fixed?:string, } /** * *type 字段类型,不同类型字段在查询、列表、编辑页表现形式不同,取值范围 * render|text|textarea|number|dict|radio|checkbox|rich|image|attach| * dept|user|calendar|datetime|date|time|daterange|table|map|rate| * progress|color|search|cascade|title|split|select|treeselect|switch| * slide|button|tip|bool|divider|cron *
* label 字段名称 *
* prop 字段key *
* rules 校验规则 *
* placeholder 提示语 *
* readonly 只读 *
* rules 校验规则 *
* conf 高级配置 (长度、可选值等) *
* tips 浮层提示 * */ type IField = { fixed?:string, query?:boolean, xs?: number, sm?: number, md?: number, lg?: number, xl?: number, width?:number, autoWidth?:boolean, label: string, prop: string, type: string, queryType?: string, //查询渲染,优先级比type高 rules?: [], placeholder?: string, readonly?: boolean, hide?: boolean, // config?: IFieldConfig, conf?: IFieldConfig, tips?: string, //提示语句,在表单中使用 render?: Function, //组件渲染 列表中使用 renderHeader?: Function, //表头渲染 列表中使用 } type IFieldConfig = { dict?:string, //数据字典key , 同range format?: Function, //显示的格式化方法 range?: Array, min?: number, //最小值 长度 max?: number, //最大值 长度 require?: boolean, // 是否必填 rowspan?: number, //行高 deft?: any, //默认值 password?: boolean, //显示密码 clearable?: boolean, //是否可以清除 multiple?: boolean, //多选 direction?: string, //展示方向 url?:string, //搜索 query?:object, //搜索参数 op?:string, //操作符,控制查询条件的展示方式 fmt?:string, //组件中展示的格式 set vfmt?:string , //v-model返回值的格式 get } /** * 字段取值范围定义 */ type IFieldRange = { deft?: boolean, label: string, color?: string, value: number } /* */