Browse Source

表格改名对应修改

Michael 8 years ago
parent
commit
606e9dd4c6

+ 23 - 23
src/main/java/com/goafanti/common/mapper/OrganizationManagementMapper.xml

@@ -108,7 +108,7 @@
       distinct
       distinct
     </if>
     </if>
     <include refid="Base_Column_List" />
     <include refid="Base_Column_List" />
-    from organization_management
+    from department_management
     <if test="_parameter != null">
     <if test="_parameter != null">
       <include refid="Example_Where_Clause" />
       <include refid="Example_Where_Clause" />
     </if>
     </if>
@@ -124,7 +124,7 @@
     -->
     -->
     select 
     select 
     <include refid="Base_Column_List" />
     <include refid="Base_Column_List" />
-    from organization_management
+    from department_management
     where id = #{id,jdbcType=VARCHAR}
     where id = #{id,jdbcType=VARCHAR}
   </select>
   </select>
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
   <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
@@ -133,7 +133,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    delete from organization_management
+    delete from department_management
     where id = #{id,jdbcType=VARCHAR}
     where id = #{id,jdbcType=VARCHAR}
   </delete>
   </delete>
   <delete id="deleteByExample" parameterType="com.goafanti.common.model.OrganizationManagementExample">
   <delete id="deleteByExample" parameterType="com.goafanti.common.model.OrganizationManagementExample">
@@ -142,7 +142,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    delete from organization_management
+    delete from department_management
     <if test="_parameter != null">
     <if test="_parameter != null">
       <include refid="Example_Where_Clause" />
       <include refid="Example_Where_Clause" />
     </if>
     </if>
@@ -153,7 +153,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    insert into organization_management (id, create_id, create_time, 
+    insert into department_management (id, create_id, create_time, 
       update_time, deleted_sign, name, 
       update_time, deleted_sign, name, 
       type, manager_id, dep_no, 
       type, manager_id, dep_no, 
       super_id, remarks, status
       super_id, remarks, status
@@ -170,7 +170,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    insert into organization_management
+    insert into department_management
     <trim prefix="(" suffix=")" suffixOverrides=",">
     <trim prefix="(" suffix=")" suffixOverrides=",">
       <if test="id != null">
       <if test="id != null">
         id,
         id,
@@ -254,7 +254,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    select count(*) from organization_management
+    select count(*) from department_management
     <if test="_parameter != null">
     <if test="_parameter != null">
       <include refid="Example_Where_Clause" />
       <include refid="Example_Where_Clause" />
     </if>
     </if>
@@ -265,7 +265,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    update organization_management
+    update department_management
     <set>
     <set>
       <if test="record.id != null">
       <if test="record.id != null">
         id = #{record.id,jdbcType=VARCHAR},
         id = #{record.id,jdbcType=VARCHAR},
@@ -314,7 +314,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    update organization_management
+    update department_management
     set id = #{record.id,jdbcType=VARCHAR},
     set id = #{record.id,jdbcType=VARCHAR},
       create_id = #{record.createId,jdbcType=VARCHAR},
       create_id = #{record.createId,jdbcType=VARCHAR},
       create_time = #{record.createTime,jdbcType=TIMESTAMP},
       create_time = #{record.createTime,jdbcType=TIMESTAMP},
@@ -337,7 +337,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    update organization_management
+    update department_management
     <set>
     <set>
       <if test="createId != null">
       <if test="createId != null">
         create_id = #{createId,jdbcType=VARCHAR},
         create_id = #{createId,jdbcType=VARCHAR},
@@ -381,7 +381,7 @@
       This element is automatically generated by MyBatis Generator, do not modify.
       This element is automatically generated by MyBatis Generator, do not modify.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
       This element was generated on Thu Nov 30 11:09:29 CST 2017.
     -->
     -->
-    update organization_management
+    update department_management
     set create_id = #{createId,jdbcType=VARCHAR},
     set create_id = #{createId,jdbcType=VARCHAR},
       create_time = #{createTime,jdbcType=TIMESTAMP},
       create_time = #{createTime,jdbcType=TIMESTAMP},
       update_time = #{updateTime,jdbcType=TIMESTAMP},
       update_time = #{updateTime,jdbcType=TIMESTAMP},
@@ -403,7 +403,7 @@
 		om.dep_no as depNo,
 		om.dep_no as depNo,
 		om.super_id as superId,
 		om.super_id as superId,
 		om.remarks,om.status
 		om.remarks,om.status
-		from organization_management om 
+		from department_management om 
 		where
 		where
 		om.deleted_sign = '0'
 		om.deleted_sign = '0'
 		<if test="name !=null">
 		<if test="name !=null">
@@ -425,7 +425,7 @@
 	<select id="selectOrganizationCount" resultType="java.lang.Integer">
 	<select id="selectOrganizationCount" resultType="java.lang.Integer">
 		select
 		select
 		count(0)
 		count(0)
-		from organization_management om
+		from department_management om
 		where
 		where
 		om.deleted_sign='0'
 		om.deleted_sign='0'
 		<if test="name !=null">
 		<if test="name !=null">
@@ -444,12 +444,12 @@
 	<select id="selectSuperId" resultType="com.goafanti.organization.bo.OrganizationListOut">
 	<select id="selectSuperId" resultType="com.goafanti.organization.bo.OrganizationListOut">
 		select
 		select
 		id,name,dep_no as depNo
 		id,name,dep_no as depNo
-		from organization_management
+		from department_management
 		where
 		where
 		status ='0'
 		status ='0'
 	</select>
 	</select>
 	<insert id="insert1" parameterType="com.goafanti.organization.bo.OrganizationListOut">
 	<insert id="insert1" parameterType="com.goafanti.organization.bo.OrganizationListOut">
-		insert into organization_management(
+		insert into department_management(
 		id,create_id,create_time,update_time,deleted_sign,
 		id,create_id,create_time,update_time,deleted_sign,
 		name,type,manager_id,dep_no,super_id,desc,status)
 		name,type,manager_id,dep_no,super_id,desc,status)
 		values(#{id,jdbcType=VARCHAR},#{createId,jdbcType=VARCHAR},
 		values(#{id,jdbcType=VARCHAR},#{createId,jdbcType=VARCHAR},
@@ -462,14 +462,14 @@
 	<select id="selectDepNoByName" resultType="String">
 	<select id="selectDepNoByName" resultType="String">
 		select
 		select
 		dep_no as depNo
 		dep_no as depNo
-		from organization_management
+		from department_management
 		where
 		where
 		name=#{name,jdbcType=VARCHAR}
 		name=#{name,jdbcType=VARCHAR}
 	</select>
 	</select>
 	<select id="selectDepNoCount" parameterType="String" resultType="java.lang.Integer">
 	<select id="selectDepNoCount" parameterType="String" resultType="java.lang.Integer">
 		select
 		select
 		count(0)
 		count(0)
-		from organization_management
+		from department_management
 		where
 		where
 		<!-- dep_no like concat(#{depNo,jdbcType=VARCHAR},'%') -->
 		<!-- dep_no like concat(#{depNo,jdbcType=VARCHAR},'%') -->
 		super_id=#{superId,jdbcType=VARCHAR}
 		super_id=#{superId,jdbcType=VARCHAR}
@@ -489,12 +489,12 @@
 		dep_no as depNo,
 		dep_no as depNo,
 		super_id as superId,
 		super_id as superId,
 		remarks,status
 		remarks,status
-		from organization_management
+		from department_management
 		where 
 		where 
 		id=#{id,jdbcType=VARCHAR}
 		id=#{id,jdbcType=VARCHAR}
 	</select>
 	</select>
 	<delete id="deleteById" parameterType="java.lang.String">
 	<delete id="deleteById" parameterType="java.lang.String">
-	    delete from organization_management
+	    delete from department_management
 	    where id = #{id,jdbcType=VARCHAR}
 	    where id = #{id,jdbcType=VARCHAR}
   	</delete>
   	</delete>
   	<select id="selectAdminNameById" parameterType="java.lang.String" resultType="java.lang.String">
   	<select id="selectAdminNameById" parameterType="java.lang.String" resultType="java.lang.String">
@@ -507,7 +507,7 @@
   	<select id="selectIdByDepNo" parameterType="java.lang.String" resultType="java.lang.String">
   	<select id="selectIdByDepNo" parameterType="java.lang.String" resultType="java.lang.String">
   		select
   		select
   		id
   		id
-  		from organization_management
+  		from department_management
   		where
   		where
   		dep_no=#{depNo,jdbcType=VARCHAR}
   		dep_no=#{depNo,jdbcType=VARCHAR}
   	</select>
   	</select>
@@ -519,13 +519,13 @@
 		dep_no as depNo,
 		dep_no as depNo,
 		super_id as superId,
 		super_id as superId,
 		remarks,status
 		remarks,status
-  		from organization_management 		
+  		from department_management 		
   		where
   		where
   		super_id=#{superId,jdbcType=VARCHAR}
   		super_id=#{superId,jdbcType=VARCHAR}
   		order by dep_no
   		order by dep_no
   	</select>
   	</select>
   	<update id="updateByNumber" parameterType="com.goafanti.organization.bo.OrganizationListOut">
   	<update id="updateByNumber" parameterType="com.goafanti.organization.bo.OrganizationListOut">
-  		update organization_management
+  		update department_management
 	    <set>
 	    <set>
 	    	dep_no = #{depNo,jdbcType=VARCHAR}
 	    	dep_no = #{depNo,jdbcType=VARCHAR}
 	    </set>
 	    </set>
@@ -535,7 +535,7 @@
   	<select id="selectCountBySuperId" parameterType="String" resultType="java.lang.Integer">
   	<select id="selectCountBySuperId" parameterType="String" resultType="java.lang.Integer">
   		select
   		select
 		count(0)
 		count(0)
-		from organization_management
+		from department_management
 		where
 		where
 		super_id=#{superId,jdbcType=VARCHAR}
 		super_id=#{superId,jdbcType=VARCHAR}
   	</select>
   	</select>

+ 1 - 1
src/main/java/com/goafanti/organization/controller/OrganizationManagementController.java

@@ -16,7 +16,7 @@ import com.goafanti.organization.bo.OrganizationListOut;
 import com.goafanti.organization.service.OrganizationService;
 import com.goafanti.organization.service.OrganizationService;
 
 
 @RestController
 @RestController
-@RequestMapping("api/admin/organization")
+@RequestMapping("open/api/admin/organization")
 public class OrganizationManagementController extends BaseApiController{
 public class OrganizationManagementController extends BaseApiController{
 	@Resource
 	@Resource
 	private OrganizationService organizationService;
 	private OrganizationService organizationService;