<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="org.jeecg.modules.projectManagement.mapper.FdClinicalProjectMilestonesItemsMapper">
    <update id="parentIdBatch" parameterType="java.util.List">
        <foreach collection="templateItemList" item="templateItem" index="index" open="" close="" separator=";">
            update fd_clinical_project_milestones_items
            <set>
                parent_id =#{templateItem.parentId}
            </set>
            <where>
                id=#{templateItem.id}
            </where>
        </foreach>
    </update>


    <update id="tempItemsBatch" parameterType="java.util.List">
        <foreach collection="templateItemList" item="templateItem" index="index" open="" close="" separator=";">
            update fd_bioanalysis_sample_milestones_items
            <set>
                actual_start_time =#{templateItem.actualStartTime},
                actual_end_time=#{templateItem.actualEndTime},
                estimate_days=#{templateItem.estimateDays},
                completion_time_difference=#{templateItem.completionTimeDifference},
                project_progress=#{templateItem.projectProgress}
            </set>
            <where>
                id=#{templateItem.id}
            </where>
        </foreach>
    </update>
</mapper>