|  | @@ -6,6 +6,8 @@
 | 
											
												
													
														|  |      <resultMap type="com.ym.mec.biz.dal.entity.CooperationOrgan"
 |  |      <resultMap type="com.ym.mec.biz.dal.entity.CooperationOrgan"
 | 
											
												
													
														|  |                 id="CooperationOrgan">
 |  |                 id="CooperationOrgan">
 | 
											
												
													
														|  |          <result column="id_" property="id"/>
 |  |          <result column="id_" property="id"/>
 | 
											
												
													
														|  | 
 |  | +        <result column="education_user_id_" property="educationUserId"/>
 | 
											
												
													
														|  | 
 |  | +        <result column="real_name_" property="realName"/>
 | 
											
												
													
														|  |          <result column="name_" property="name"/>
 |  |          <result column="name_" property="name"/>
 | 
											
												
													
														|  |          <result column="linkman_" property="linkman"/>
 |  |          <result column="linkman_" property="linkman"/>
 | 
											
												
													
														|  |          <result column="organ_id_" property="organId"/>
 |  |          <result column="organ_id_" property="organId"/>
 | 
											
										
											
												
													
														|  | @@ -45,16 +47,19 @@
 | 
											
												
													
														|  |              useGeneratedKeys="true" keyColumn="id" keyProperty="id">
 |  |              useGeneratedKeys="true" keyColumn="id" keyProperty="id">
 | 
											
												
													
														|  |          INSERT INTO cooperation_organ
 |  |          INSERT INTO cooperation_organ
 | 
											
												
													
														|  |          (id_, name_, linkman_, job_, mobile_no_, address_, organ_id_, create_time_, update_time_, ownership_type_,
 |  |          (id_, name_, linkman_, job_, mobile_no_, address_, organ_id_, create_time_, update_time_, ownership_type_,
 | 
											
												
													
														|  | -         is_enable_, full_job_resource_)
 |  | 
 | 
											
												
													
														|  | 
 |  | +         is_enable_, full_job_resource_,education_user_id_)
 | 
											
												
													
														|  |          VALUES (#{id}, #{name}, #{linkman}, #{job}, #{mobileNo}, #{address}, #{organId}, now(), now(),
 |  |          VALUES (#{id}, #{name}, #{linkman}, #{job}, #{mobileNo}, #{address}, #{organId}, now(), now(),
 | 
											
												
													
														|  |                  #{ownershipType,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}, #{isEnable},
 |  |                  #{ownershipType,typeHandler=com.ym.mec.common.dal.CustomEnumTypeHandler}, #{isEnable},
 | 
											
												
													
														|  | -                #{fullJobResource})
 |  | 
 | 
											
												
													
														|  | 
 |  | +                #{fullJobResource},#{educationUserId})
 | 
											
												
													
														|  |      </insert>
 |  |      </insert>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      <!-- 根据主键查询一条记录 -->
 |  |      <!-- 根据主键查询一条记录 -->
 | 
											
												
													
														|  |      <update id="update" parameterType="com.ym.mec.biz.dal.entity.CooperationOrgan">
 |  |      <update id="update" parameterType="com.ym.mec.biz.dal.entity.CooperationOrgan">
 | 
											
												
													
														|  |          UPDATE cooperation_organ
 |  |          UPDATE cooperation_organ
 | 
											
												
													
														|  |          <set>
 |  |          <set>
 | 
											
												
													
														|  | 
 |  | +            <if test="educationUserId != null">
 | 
											
												
													
														|  | 
 |  | +                education_user_id_ = #{educationUserId},
 | 
											
												
													
														|  | 
 |  | +            </if>
 | 
											
												
													
														|  |              <if test="fullJobResource != null">
 |  |              <if test="fullJobResource != null">
 | 
											
												
													
														|  |                  full_job_resource_ = #{fullJobResource},
 |  |                  full_job_resource_ = #{fullJobResource},
 | 
											
												
													
														|  |              </if>
 |  |              </if>
 | 
											
										
											
												
													
														|  | @@ -99,11 +104,20 @@
 | 
											
												
													
														|  |      <!-- 分页查询 -->
 |  |      <!-- 分页查询 -->
 | 
											
												
													
														|  |      <select id="queryPage" resultMap="ExtCooperationOrgan"
 |  |      <select id="queryPage" resultMap="ExtCooperationOrgan"
 | 
											
												
													
														|  |              parameterType="map">
 |  |              parameterType="map">
 | 
											
												
													
														|  | -        SELECT co.*,o.name_ organ_name_ FROM cooperation_organ co left join organization o on co.organ_id_ = o.id_
 |  | 
 | 
											
												
													
														|  | 
 |  | +        SELECT co.*,o.name_ organ_name_,su.real_name_ FROM cooperation_organ co
 | 
											
												
													
														|  | 
 |  | +        LEFT JOIN organization o ON co.organ_id_ = o.id_
 | 
											
												
													
														|  | 
 |  | +        LEFT JOIN sys_user su ON su.id_ = co.education_user_id_
 | 
											
												
													
														|  | 
 |  | +        <include refid="queryPageSql"/>
 | 
											
												
													
														|  | 
 |  | +        ORDER BY co.update_time_ DESC
 | 
											
												
													
														|  | 
 |  | +        <include refid="global.limit"/>
 | 
											
												
													
														|  | 
 |  | +    </select>
 | 
											
												
													
														|  | 
 |  | +
 | 
											
												
													
														|  | 
 |  | +    <sql id="queryPageSql">
 | 
											
												
													
														|  |          <where>
 |  |          <where>
 | 
											
												
													
														|  |              co.del_flag_ != 1
 |  |              co.del_flag_ != 1
 | 
											
												
													
														|  |              <if test="search != null">
 |  |              <if test="search != null">
 | 
											
												
													
														|  | -                AND (co.id_ LIKE CONCAT('%',#{search},'%') OR co.name_ LIKE CONCAT('%',#{search},'%'))
 |  | 
 | 
											
												
													
														|  | 
 |  | +                AND (co.education_user_id_ = #{search} OR su.real_name_ LIKE CONCAT('%',#{search},'%')
 | 
											
												
													
														|  | 
 |  | +                OR co.id_ LIKE CONCAT('%',#{search},'%') OR co.name_ LIKE CONCAT('%',#{search},'%'))
 | 
											
												
													
														|  |              </if>
 |  |              </if>
 | 
											
												
													
														|  |              <if test="organId != null">
 |  |              <if test="organId != null">
 | 
											
												
													
														|  |                  AND FIND_IN_SET(co.organ_id_,#{organId})
 |  |                  AND FIND_IN_SET(co.organ_id_,#{organId})
 | 
											
										
											
												
													
														|  | @@ -115,28 +129,13 @@
 | 
											
												
													
														|  |                  AND co.full_job_resource_ = #{fullJobResource}
 |  |                  AND co.full_job_resource_ = #{fullJobResource}
 | 
											
												
													
														|  |              </if>
 |  |              </if>
 | 
											
												
													
														|  |          </where>
 |  |          </where>
 | 
											
												
													
														|  | -        ORDER BY co.update_time_ DESC
 |  | 
 | 
											
												
													
														|  | -        <include refid="global.limit"/>
 |  | 
 | 
											
												
													
														|  | -    </select>
 |  | 
 | 
											
												
													
														|  | 
 |  | +    </sql>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      <!-- 查询当前表的总记录数 -->
 |  |      <!-- 查询当前表的总记录数 -->
 | 
											
												
													
														|  |      <select id="queryCount" resultType="int">
 |  |      <select id="queryCount" resultType="int">
 | 
											
												
													
														|  | -        SELECT COUNT(*) FROM cooperation_organ
 |  | 
 | 
											
												
													
														|  | -        <where>
 |  | 
 | 
											
												
													
														|  | -            del_flag_ != 1
 |  | 
 | 
											
												
													
														|  | -            <if test="search != null">
 |  | 
 | 
											
												
													
														|  | -                AND (id_ LIKE CONCAT('%',#{search},'%') OR name_ LIKE CONCAT('%',#{search},'%'))
 |  | 
 | 
											
												
													
														|  | -            </if>
 |  | 
 | 
											
												
													
														|  | -            <if test="organId != null">
 |  | 
 | 
											
												
													
														|  | -                AND FIND_IN_SET(organ_id_,#{organId})
 |  | 
 | 
											
												
													
														|  | -            </if>
 |  | 
 | 
											
												
													
														|  | -            <if test="isEnable != null">
 |  | 
 | 
											
												
													
														|  | -                AND is_enable_ = #{isEnable}
 |  | 
 | 
											
												
													
														|  | -            </if>
 |  | 
 | 
											
												
													
														|  | -            <if test="fullJobResource != null">
 |  | 
 | 
											
												
													
														|  | -                AND full_job_resource_ = #{fullJobResource}
 |  | 
 | 
											
												
													
														|  | -            </if>
 |  | 
 | 
											
												
													
														|  | -        </where>
 |  | 
 | 
											
												
													
														|  | 
 |  | +        SELECT COUNT(co.id_) FROM cooperation_organ co
 | 
											
												
													
														|  | 
 |  | +        LEFT JOIN sys_user su ON su.id_ = co.education_user_id_
 | 
											
												
													
														|  | 
 |  | +        <include refid="queryPageSql"/>
 | 
											
												
													
														|  |      </select>
 |  |      </select>
 | 
											
												
													
														|  |  
 |  |  
 | 
											
												
													
														|  |      <select id="queryByOrganId" resultMap="CooperationOrgan">
 |  |      <select id="queryByOrganId" resultMap="CooperationOrgan">
 |