幼儿信息家长端维护 优化
This commit is contained in:
parent
ee479f68ee
commit
214fefc509
@ -468,7 +468,7 @@ export default {
|
||||
updateContactpeople(this.form_jhr).then(response => {
|
||||
if (response.code === 200) {
|
||||
this.msgSuccess("修改成功");
|
||||
this.hide = false;
|
||||
// this.hide = false;
|
||||
}
|
||||
});
|
||||
this.hide = false;
|
||||
|
@ -107,7 +107,16 @@ public class ByChildContactpeopleController extends BaseController {
|
||||
@Log(title = "幼儿紧急情况联系人", businessType = BusinessType.UPDATE)
|
||||
@PutMapping
|
||||
public AjaxResult edit(@RequestBody ByChildContactpeople byChildContactpeople) {
|
||||
return toAjax(byChildContactpeopleService.updateByChildContactpeople(byChildContactpeople));
|
||||
//如果存在,就更新,否则删除
|
||||
ByChildContactpeople byChildContactpeoplenew = new ByChildContactpeople();
|
||||
byChildContactpeoplenew.setChildid(byChildContactpeople.getChildid());
|
||||
List<ByChildContactpeople> list = byChildContactpeopleService.selectByChildContactpeopleList(byChildContactpeoplenew);
|
||||
if (list!=null&&list.size()>0){
|
||||
return toAjax(byChildContactpeopleService.updateByChildContactpeople(byChildContactpeople));
|
||||
}else{
|
||||
return toAjax(byChildContactpeopleService.insertByChildContactpeople(byChildContactpeople));
|
||||
}
|
||||
|
||||
}
|
||||
|
||||
/**
|
||||
|
Loading…
x
Reference in New Issue
Block a user