Browse Source

管理员新增公出抄送

anderx 1 year ago
parent
commit
a06e047f79

+ 11 - 2
src/main/java/com/goafanti/common/dao/AdminMapper.java

@@ -2,13 +2,22 @@ package com.goafanti.common.dao;
 
 import com.goafanti.admin.bo.*;
 import com.goafanti.common.bo.AdminNoticeBo;
-import com.goafanti.common.model.*;
+import com.goafanti.common.model.Admin;
+import com.goafanti.common.model.AdminUserCount;
+import com.goafanti.common.model.Department;
+import com.goafanti.common.model.Role;
 import org.apache.ibatis.annotations.Param;
 
 import java.math.BigDecimal;
 import java.util.List;
-
+/**
+* @author Administrator
+* @description 针对表【admin】的数据库操作Mapper
+* @createDate 2024-06-12 08:51:13
+* @Entity com.goafanti.common.model.Admin
+*/
 public interface AdminMapper {
+
     int deleteByPrimaryKey(String id);
 
     int insert(Admin record);

+ 14 - 7
src/main/java/com/goafanti/common/mapper/AdminMapper.xml

@@ -35,6 +35,7 @@
             <result property="publicPurview" column="public_purview" jdbcType="INTEGER"/>
             <result property="expenseOpenId" column="expense_open_id" jdbcType="VARCHAR"/>
             <result property="expenseSuperExamine" column="expense_super_examine" jdbcType="INTEGER"/>
+            <result property="publicCarbonCopy" column="public_carbon_copy" jdbcType="VARCHAR"/>
     </resultMap>
 
     <sql id="Base_Column_List">
@@ -47,17 +48,18 @@
         last_login_time,open_id,type,
         reviewer,amb_id,amb_role,
         amb_manage,manager_id,senior_staff,
-        public_purview,expense_open_id,expense_super_examine
+        public_purview,expense_open_id,expense_super_examine,
+        public_carbon_copy
     </sql>
 
-    <select id="selectByPrimaryKey"  resultMap="BaseResultMap">
+    <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
         select
         <include refid="Base_Column_List" />
         from admin
         where  id = #{id,jdbcType=VARCHAR} 
     </select>
 
-    <delete id="deleteByPrimaryKey" >
+    <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
         delete from admin
         where  id = #{id,jdbcType=VARCHAR} 
     </delete>
@@ -73,7 +75,7 @@
         ,reviewer,amb_id,amb_role
         ,amb_manage,manager_id,senior_staff
         ,public_purview,expense_open_id,expense_super_examine
-        )
+        ,public_carbon_copy)
         values (#{id,jdbcType=VARCHAR},#{mobile,jdbcType=VARCHAR},#{name,jdbcType=VARCHAR}
         ,#{password,jdbcType=VARCHAR},#{email,jdbcType=VARCHAR},#{createTime,jdbcType=TIMESTAMP}
         ,#{number,jdbcType=INTEGER},#{province,jdbcType=VARCHAR},#{position,jdbcType=VARCHAR}
@@ -84,7 +86,7 @@
         ,#{reviewer,jdbcType=VARCHAR},#{ambId,jdbcType=VARCHAR},#{ambRole,jdbcType=VARCHAR}
         ,#{ambManage,jdbcType=INTEGER},#{managerId,jdbcType=VARCHAR},#{seniorStaff,jdbcType=INTEGER}
         ,#{publicPurview,jdbcType=INTEGER},#{expenseOpenId,jdbcType=VARCHAR},#{expenseSuperExamine,jdbcType=INTEGER}
-        )
+        ,#{publicCarbonCopy,jdbcType=VARCHAR})
     </insert>
     <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.Admin" useGeneratedKeys="true">
         insert into admin
@@ -119,6 +121,7 @@
                 <if test="publicPurview != null">public_purview,</if>
                 <if test="expenseOpenId != null">expense_open_id,</if>
                 <if test="expenseSuperExamine != null">expense_super_examine,</if>
+                <if test="publicCarbonCopy != null">public_carbon_copy,</if>
         </trim>
         <trim prefix="values (" suffix=")" suffixOverrides=",">
                 <if test="id != null">#{id,jdbcType=VARCHAR},</if>
@@ -151,6 +154,7 @@
                 <if test="publicPurview != null">#{publicPurview,jdbcType=INTEGER},</if>
                 <if test="expenseOpenId != null">#{expenseOpenId,jdbcType=VARCHAR},</if>
                 <if test="expenseSuperExamine != null">#{expenseSuperExamine,jdbcType=INTEGER},</if>
+                <if test="publicCarbonCopy != null">#{publicCarbonCopy,jdbcType=VARCHAR},</if>
         </trim>
     </insert>
     <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.Admin">
@@ -243,6 +247,9 @@
                 <if test="expenseSuperExamine != null">
                     expense_super_examine = #{expenseSuperExamine,jdbcType=INTEGER},
                 </if>
+                <if test="publicCarbonCopy != null">
+                    public_carbon_copy = #{publicCarbonCopy,jdbcType=VARCHAR},
+                </if>
         </set>
         where   id = #{id,jdbcType=VARCHAR} 
     </update>
@@ -277,7 +284,8 @@
             senior_staff =  #{seniorStaff,jdbcType=INTEGER},
             public_purview =  #{publicPurview,jdbcType=INTEGER},
             expense_open_id =  #{expenseOpenId,jdbcType=VARCHAR},
-            expense_super_examine =  #{expenseSuperExamine,jdbcType=INTEGER}
+            expense_super_examine =  #{expenseSuperExamine,jdbcType=INTEGER},
+            public_carbon_copy =  #{publicCarbonCopy,jdbcType=VARCHAR}
         where   id = #{id,jdbcType=VARCHAR} 
     </update>
 
@@ -1333,4 +1341,3 @@
     </select>
 
 </mapper>
-

File diff suppressed because it is too large
+ 643 - 445
src/main/java/com/goafanti/common/model/Admin.java