id,pid,aid, name,project_status,content, annex_url,create_time,process_status, duration,examine_id,examine_time, examine_name,record_time,examine_content, init_duration,check_duration,check_status, tianhe_url,tianhe_type delete from project_staff_record where id = #{id,jdbcType=BIGINT} insert into project_staff_record ( id,pid,aid ,name,project_status,content ,annex_url,create_time,process_status ,duration,examine_id,examine_time ,examine_name,record_time,examine_content ,init_duration,check_duration,check_status ,tianhe_url,tianhe_type) values (#{id,jdbcType=BIGINT},#{pid,jdbcType=BIGINT},#{aid,jdbcType=BIGINT} ,#{name,jdbcType=VARCHAR},#{projectStatus,jdbcType=INTEGER},#{content,jdbcType=VARCHAR} ,#{annexUrl,jdbcType=VARCHAR},#{createTime,jdbcType=TIMESTAMP},#{processStatus,jdbcType=INTEGER} ,#{duration,jdbcType=DOUBLE},#{examineId,jdbcType=BIGINT},#{examineTime,jdbcType=TIMESTAMP} ,#{examineName,jdbcType=VARCHAR},#{recordTime,jdbcType=TIMESTAMP},#{examineContent,jdbcType=VARCHAR} ,#{initDuration,jdbcType=DOUBLE},#{checkDuration,jdbcType=DOUBLE},#{checkStatus,jdbcType=INTEGER} ,#{tianheUrl,jdbcType=VARCHAR},#{tianheType,jdbcType=INTEGER}) insert into project_staff_record id, pid, aid, name, project_status, content, annex_url, create_time, process_status, duration, examine_id, examine_time, examine_name, record_time, examine_content, init_duration, check_duration, check_status, tianhe_url, tianhe_type, #{id,jdbcType=BIGINT}, #{pid,jdbcType=BIGINT}, #{aid,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{projectStatus,jdbcType=INTEGER}, #{content,jdbcType=VARCHAR}, #{annexUrl,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{processStatus,jdbcType=INTEGER}, #{duration,jdbcType=DOUBLE}, #{examineId,jdbcType=BIGINT}, #{examineTime,jdbcType=TIMESTAMP}, #{examineName,jdbcType=VARCHAR}, #{recordTime,jdbcType=TIMESTAMP}, #{examineContent,jdbcType=VARCHAR}, #{initDuration,jdbcType=DOUBLE}, #{checkDuration,jdbcType=DOUBLE}, #{checkStatus,jdbcType=INTEGER}, #{tianheUrl,jdbcType=VARCHAR}, #{tianheType,jdbcType=INTEGER}, update project_staff_record pid = #{pid,jdbcType=BIGINT}, aid = #{aid,jdbcType=BIGINT}, name = #{name,jdbcType=VARCHAR}, project_status = #{projectStatus,jdbcType=INTEGER}, content = #{content,jdbcType=VARCHAR}, annex_url = #{annexUrl,jdbcType=VARCHAR}, create_time = #{createTime,jdbcType=TIMESTAMP}, process_status = #{processStatus,jdbcType=INTEGER}, duration = #{duration,jdbcType=DOUBLE}, examine_id = #{examineId,jdbcType=BIGINT}, examine_time = #{examineTime,jdbcType=TIMESTAMP}, examine_name = #{examineName,jdbcType=VARCHAR}, record_time = #{recordTime,jdbcType=TIMESTAMP}, examine_content = #{examineContent,jdbcType=VARCHAR}, init_duration = #{initDuration,jdbcType=DOUBLE}, check_duration = #{checkDuration,jdbcType=DOUBLE}, check_status = #{checkStatus,jdbcType=INTEGER}, tianhe_url = #{tianheUrl,jdbcType=VARCHAR}, tianhe_type = #{tianheType,jdbcType=INTEGER}, where id = #{id,jdbcType=BIGINT} update project_staff_record set pid = #{pid,jdbcType=BIGINT}, aid = #{aid,jdbcType=BIGINT}, name = #{name,jdbcType=VARCHAR}, project_status = #{projectStatus,jdbcType=INTEGER}, content = #{content,jdbcType=VARCHAR}, annex_url = #{annexUrl,jdbcType=VARCHAR}, create_time = #{createTime,jdbcType=TIMESTAMP}, process_status = #{processStatus,jdbcType=INTEGER}, duration = #{duration,jdbcType=DOUBLE}, examine_id = #{examineId,jdbcType=BIGINT}, examine_time = #{examineTime,jdbcType=TIMESTAMP}, examine_name = #{examineName,jdbcType=VARCHAR}, record_time = #{recordTime,jdbcType=TIMESTAMP}, examine_content = #{examineContent,jdbcType=VARCHAR}, init_duration = #{initDuration,jdbcType=DOUBLE}, check_duration = #{checkDuration,jdbcType=DOUBLE}, check_status = #{checkStatus,jdbcType=INTEGER}, tianhe_url = #{tianheUrl,jdbcType=VARCHAR}, tianhe_type = #{tianheType,jdbcType=INTEGER} where id = #{id,jdbcType=BIGINT} update project_staff_record set name= #{nickName} where aid= #{userId} update project_task x,(select pid ,sum(duration)duration from project_staff_record where pid =#{pid} group by pid )y set x.duration =y.duration where x.id =y.pid update sys_user x,(select aid ,sum(duration)duration from project_staff_record where pid = #{pid} group by aid)y set x.duration=y.duration where x.user_id =y.aid update project_staff_record set duration =check_duration,check_status=2 where id in #{e} update project_staff_record set tianhe_type=1 where tianhe_type=0 and id in #{e.id}