|
|
@@ -28,12 +28,13 @@
|
|
|
<result column="approval_aid" jdbcType="VARCHAR" property="approvalAid" />
|
|
|
<result column="expense_finance_id" jdbcType="VARCHAR" property="expenseFinanceId" />
|
|
|
<result column="expense_retrial_finance_id" jdbcType="VARCHAR" property="expenseRetrialFinanceId" />
|
|
|
+ <result column="cashier_id" jdbcType="VARCHAR" property="cashierId" />
|
|
|
</resultMap>
|
|
|
<sql id="Base_Column_List">
|
|
|
id, create_id, create_time, update_time, deleted_sign, `name`, `type`, manager_id,
|
|
|
dep_no, super_id, remarks, `status`, abbreviation, finance_id, province, working_hours_type,
|
|
|
hide_sign, lvl, current_amount, subordinate_amount, total_amount, retrial_finance_id,
|
|
|
- approval, approval_aid, expense_finance_id, expense_retrial_finance_id
|
|
|
+ approval, approval_aid, expense_finance_id, expense_retrial_finance_id, cashier_id
|
|
|
</sql>
|
|
|
<select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
|
|
|
select
|
|
|
@@ -54,7 +55,7 @@
|
|
|
hide_sign, lvl, current_amount,
|
|
|
subordinate_amount, total_amount, retrial_finance_id,
|
|
|
approval, approval_aid, expense_finance_id,
|
|
|
- expense_retrial_finance_id)
|
|
|
+ expense_retrial_finance_id, cashier_id)
|
|
|
values (#{createId,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP},
|
|
|
#{deletedSign,jdbcType=INTEGER}, #{name,jdbcType=VARCHAR}, #{type,jdbcType=VARCHAR},
|
|
|
#{managerId,jdbcType=VARCHAR}, #{depNo,jdbcType=VARCHAR}, #{superId,jdbcType=VARCHAR},
|
|
|
@@ -63,7 +64,7 @@
|
|
|
#{hideSign,jdbcType=INTEGER}, #{lvl,jdbcType=INTEGER}, #{currentAmount,jdbcType=DECIMAL},
|
|
|
#{subordinateAmount,jdbcType=DECIMAL}, #{totalAmount,jdbcType=DECIMAL}, #{retrialFinanceId,jdbcType=VARCHAR},
|
|
|
#{approval,jdbcType=INTEGER}, #{approvalAid,jdbcType=VARCHAR}, #{expenseFinanceId,jdbcType=VARCHAR},
|
|
|
- #{expenseRetrialFinanceId,jdbcType=VARCHAR})
|
|
|
+ #{expenseRetrialFinanceId,jdbcType=VARCHAR}, #{cashierId,jdbcType=VARCHAR})
|
|
|
</insert>
|
|
|
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.Department" useGeneratedKeys="true">
|
|
|
insert into department
|
|
|
@@ -143,6 +144,9 @@
|
|
|
<if test="expenseRetrialFinanceId != null">
|
|
|
expense_retrial_finance_id,
|
|
|
</if>
|
|
|
+ <if test="cashierId != null">
|
|
|
+ cashier_id,
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="createId != null">
|
|
|
@@ -220,6 +224,9 @@
|
|
|
<if test="expenseRetrialFinanceId != null">
|
|
|
#{expenseRetrialFinanceId,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
+ <if test="cashierId != null">
|
|
|
+ #{cashierId,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
</trim>
|
|
|
</insert>
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.Department">
|
|
|
@@ -300,6 +307,9 @@
|
|
|
<if test="expenseRetrialFinanceId != null">
|
|
|
expense_retrial_finance_id = #{expenseRetrialFinanceId,jdbcType=VARCHAR},
|
|
|
</if>
|
|
|
+ <if test="cashierId != null">
|
|
|
+ cashier_id = #{cashierId,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
</set>
|
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
|
</update>
|
|
|
@@ -329,7 +339,8 @@
|
|
|
approval = #{approval,jdbcType=INTEGER},
|
|
|
approval_aid = #{approvalAid,jdbcType=VARCHAR},
|
|
|
expense_finance_id = #{expenseFinanceId,jdbcType=VARCHAR},
|
|
|
- expense_retrial_finance_id = #{expenseRetrialFinanceId,jdbcType=VARCHAR}
|
|
|
+ expense_retrial_finance_id = #{expenseRetrialFinanceId,jdbcType=VARCHAR},
|
|
|
+ cashier_id = #{cashierId,jdbcType=VARCHAR}
|
|
|
where id = #{id,jdbcType=VARCHAR}
|
|
|
</update>
|
|
|
<select id="selectOrganizationList" parameterType="java.lang.String" resultType="com.goafanti.organization.bo.OrganizationListOut">
|
|
|
@@ -440,11 +451,13 @@
|
|
|
d.name retrialFinanceName, a.deleted_sign as deletedSign, a.name, a.type, a.manager_id as managerId, a.dep_no as depNo,
|
|
|
a.super_id as superId, a.remarks, a.status, a.abbreviation, a.finance_id financeId,a.hide_sign hideSign,
|
|
|
a.expense_finance_id expenseFinanceId,f.name expenseFinanceName,a.expense_retrial_finance_id expenseRetrialFinanceId,
|
|
|
- g.name expenseRetrialFinanceName, a.province, c.name financeName, a.working_hours_type workingHoursType, b.name as managerName,
|
|
|
+ g.name expenseRetrialFinanceName,a.cashier_id cashierId,h.name cashierName,
|
|
|
+ a.province, c.name financeName, a.working_hours_type workingHoursType, b.name as managerName,
|
|
|
a.retrial_finance_id retrialFinanceId, d.name retrialFinanceName,a.approval,a.approval_aid approvalAid,e.name approvalName
|
|
|
from department a left join admin b on a.manager_id = b.id left join admin c on a.finance_id = c.id
|
|
|
left join admin d on a.retrial_finance_id=d.id left join admin e on a.approval_aid =e.id
|
|
|
left join admin f on a.expense_finance_id=f.id left join admin g on a.expense_retrial_finance_id=g.id
|
|
|
+ left join admin h on a.cashier_id=h.id
|
|
|
where a.id=#{id,jdbcType=VARCHAR}
|
|
|
</select>
|
|
|
<delete id="deleteById" parameterType="java.lang.String">
|