INSERT INTO bm_unit
unit_name,
depart_id,
dept_id,
link_man,
telphone,
create_time,
create_by,
del_flag,
project_id,
bzz_idcard,
type_id,
#{teamName},
#{departId},
#{deptId},
#{relName},
#{relPhone},
NOW(),
#{createUser},
0,
#{projectId},
#{idCard},
#{typeId},
UPDATE bm_unit
unit_name = #{teamName},
type_id = #{typeId},
link_man = #{relName},
telphone = #{relPhone},
update_by = #{updateUser},
status = #{status},
project_id = #{projectId},
bzz_idcard = #{idCard},
update_time = NOW()
WHERE unit_id = #{id}
update bm_unit
set del_flag = '2'
where unit_id = #{id}