|
@@ -71,8 +71,7 @@ export default defineComponent({
|
|
|
getList()
|
|
|
})
|
|
|
const onSearch = (val: string) => {
|
|
|
- if (!val) return
|
|
|
- params.userName = val
|
|
|
+ params.userName = val || ''
|
|
|
getList()
|
|
|
}
|
|
|
const toggle = (n: IStudent) => {
|
|
@@ -89,7 +88,7 @@ export default defineComponent({
|
|
|
return () => (
|
|
|
<div class={styles.container}>
|
|
|
<Sticky offsetTop={0}>
|
|
|
- <ColHeader isBack title="选择学员" />
|
|
|
+ <ColHeader title="选择学员" />
|
|
|
<ColSearch
|
|
|
placeholder="请输入学员名称"
|
|
|
onSearch={onSearch}
|
|
@@ -121,7 +120,7 @@ export default defineComponent({
|
|
|
>
|
|
|
<Student item={n}>
|
|
|
<div class={styles.check}>
|
|
|
- <Checkbox v-model={n.checked} name={n.userId}></Checkbox>
|
|
|
+ <Checkbox modelValue={n.checked} name={n.userId}></Checkbox>
|
|
|
</div>
|
|
|
</Student>
|
|
|
</div>
|
|
@@ -135,7 +134,7 @@ export default defineComponent({
|
|
|
onClick={() => {
|
|
|
let stus = cleanDeep(list.value.filter(n => n.checked))
|
|
|
// console.log(stus)
|
|
|
- props.onSetStudents(stus)
|
|
|
+ props.onSetStudents && props.onSetStudents(stus)
|
|
|
}}
|
|
|
>
|
|
|
确认
|