Checkbox 选中时查询库存数量为0的数据 - Ant Design FormSchema 示例
export const searchFormSchema: FormSchema[] = [{\n label: '库存数量',\n field: 'Quantity',\n component: 'Checkbox',\n defaultValue: null,\n componentProps: {\n checkedValue: 0, // 复选框选中时的值\n uncheckedValue: null, // 复选框未选中时的值\n },\n renderComponentContent: '库存为0',\n onChange: (value) => {\n if (value) {\n // 当checkbox选中时,查询数据库里库存数量为0的数据\n // 执行相应的操作\n }\n },\n}];
原文地址: https://www.cveoy.top/t/topic/qr5Q 著作权归作者所有。请勿转载和采集!