wanghui лет назад: 8
Родитель
Сommit
4d281ffe8c

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

@@ -7,7 +7,7 @@
 				select  
 				select  
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
-					b.aft_username as aftUsername,b.contacts,b.contact_mobile as contactMobile,b.international,b.expert,b.celebrity,
+					b.username as name,b.contacts,b.contact_mobile as contactMobile,b.international,b.expert,b.celebrity,
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 				from 
 				from 
 				(select 
 				(select 
@@ -44,8 +44,8 @@
 				left join district_glossory dg3 on b.area = dg3.id
 				left join district_glossory dg3 on b.area = dg3.id
 				left join industry_category c on b.industry = c.id 
 				left join industry_category c on b.industry = c.id 
 				where 1=1 
 				where 1=1 
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name''">
+					and b.username = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.province = #{province,jdbcType=INTEGER}
 					and b.province = #{province,jdbcType=INTEGER}
@@ -64,7 +64,7 @@
 				select  
 				select  
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
-					b.aft_username as aftUsername,b.contacts,b.contact_mobile as contactMobile,b.international,0 as expert,0 as celebrity,
+					b.unit_name as name,b.contacts,b.contact_mobile as contactMobile,b.international,0 as expert,0 as celebrity,
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 				from 
 				from 
 				(select 
 				(select 
@@ -101,8 +101,8 @@
 				left join district_glossory dg3 on b.licence_area = dg3.id
 				left join district_glossory dg3 on b.licence_area = dg3.id
 				left join industry_category c on b.industry = c.id 
 				left join industry_category c on b.industry = c.id 
 				where 1=1
 				where 1=1
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name''">
+					and b.unit_name = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.licence_province = #{province,jdbcType=INTEGER}
 					and b.licence_province = #{province,jdbcType=INTEGER}
@@ -121,7 +121,7 @@
 				select  
 				select  
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
-					b.aft_username as aftUsername,b.contacts,b.contact_mobile as contactMobile,b.international,b.expert,b.celebrity,
+					b.username as name,b.contacts,b.contact_mobile as contactMobile,b.international,b.expert,b.celebrity,
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 				from 
 				from 
 				(select 
 				(select 
@@ -158,8 +158,8 @@
 				left join district_glossory dg3 on b.area = dg3.id
 				left join district_glossory dg3 on b.area = dg3.id
 				left join industry_category c on b.industry = c.id 
 				left join industry_category c on b.industry = c.id 
 				where 1=1 
 				where 1=1 
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name''">
+					and b.username = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.province = #{province,jdbcType=INTEGER}
 					and b.province = #{province,jdbcType=INTEGER}
@@ -177,7 +177,7 @@
 				select  
 				select  
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.id as uid,a.type,a.status, a.create_time as createTime,a.service_certification as serviceCertification,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
 					a.user_certification as userCertification,a.current_member_status as currentMemberStatus,
-					b.aft_username as aftUsername,b.contacts,b.contact_mobile as contactMobile,b.international,0 as expert,0 as celebrity,
+					b.unit_name as name,b.contacts,b.contact_mobile as contactMobile,b.international,0 as expert,0 as celebrity,
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 					dg1.name as province,dg2.name as city, dg3.name as area,c.name as industry
 				from 
 				from 
 				(select 
 				(select 
@@ -214,8 +214,8 @@
 				left join district_glossory dg3 on b.licence_area = dg3.id
 				left join district_glossory dg3 on b.licence_area = dg3.id
 				left join industry_category c on b.industry = c.id 
 				left join industry_category c on b.industry = c.id 
 				where 1=1
 				where 1=1
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name''">
+					and b.unit_name = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.licence_province = #{province,jdbcType=INTEGER}
 					and b.licence_province = #{province,jdbcType=INTEGER}
@@ -272,8 +272,8 @@
 					   	</if>
 					   	</if>
 					)as a inner join user_identity b on a.id = b.uid 	
 					)as a inner join user_identity b on a.id = b.uid 	
 				where 1=1
 				where 1=1
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name !=''">
+					and b.username = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.province = #{province,jdbcType=INTEGER}
 					and b.province = #{province,jdbcType=INTEGER}
@@ -322,8 +322,8 @@
 					   	</if>
 					   	</if>
 					)as a inner join organization_identity b on a.id = b.uid
 					)as a inner join organization_identity b on a.id = b.uid
 				where 1=1
 				where 1=1
-				<if test="aftUsername != null and aftUsername!=''">
-					and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+				<if test="name != null and name !=''">
+					and b.unit_name = #{name,jdbcType=VARCHAR}
 				</if>
 				</if>
 				<if test="province != null">
 				<if test="province != null">
 					and b.licence_province = #{province,jdbcType=INTEGER}
 					and b.licence_province = #{province,jdbcType=INTEGER}
@@ -339,10 +339,10 @@
 				</if>
 				</if>
 			</when>
 			</when>
 			<otherwise>
 			<otherwise>
-				select x.count1 + x.count2 
+				select count(0)
 				from(
 				from(
 					select  
 					select  
-						count(0) as count1,0 as count2
+						a.id
 					from 
 					from 
 						(select 
 						(select 
 							id
 							id
@@ -374,8 +374,8 @@
 						   	</if>
 						   	</if>
 						)as a inner join user_identity b on a.id = b.uid 	
 						)as a inner join user_identity b on a.id = b.uid 	
 					where 1=1
 					where 1=1
-					<if test="aftUsername != null and aftUsername!=''">
-						and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+					<if test="name != null and name !=''">
+						and b.username = #{name,jdbcType=VARCHAR}
 					</if>
 					</if>
 					<if test="province != null">
 					<if test="province != null">
 						and b.province = #{province,jdbcType=INTEGER}
 						and b.province = #{province,jdbcType=INTEGER}
@@ -391,7 +391,7 @@
 					</if>
 					</if>
 					union
 					union
 					select  
 					select  
-						0 as count1,count(0) as count2
+						a.id
 					from 
 					from 
 						(select 
 						(select 
 							id
 							id
@@ -423,8 +423,8 @@
 						   	</if>
 						   	</if>
 						)as a inner join organization_identity b on a.id = b.uid
 						)as a inner join organization_identity b on a.id = b.uid
 					where 1=1
 					where 1=1
-					<if test="aftUsername != null and aftUsername!=''">
-						and b.aft_username = #{aftUsername,jdbcType=VARCHAR}
+					<if test="name != null and name !=''">
+						and b.unit_name = #{name,jdbcType=VARCHAR}
 					</if>
 					</if>
 					<if test="province != null">
 					<if test="province != null">
 						and b.licence_province = #{province,jdbcType=INTEGER}
 						and b.licence_province = #{province,jdbcType=INTEGER}

+ 5 - 5
src/main/java/com/goafanti/customer/bo/CustomerListIn.java

@@ -6,7 +6,7 @@ public class CustomerListIn {
 	private String type;
 	private String type;
 	
 	
 	/** 客户名称 **/
 	/** 客户名称 **/
-	private String aftUsername;
+	private String name;
 	
 	
 	/** 省 **/
 	/** 省 **/
 	private String province;
 	private String province;
@@ -70,12 +70,12 @@ public class CustomerListIn {
 		this.type = type;
 		this.type = type;
 	}
 	}
 
 
-	public String getAftUsername() {
-		return aftUsername;
+	public String getName() {
+		return name;
 	}
 	}
 
 
-	public void setAftUsername(String aftUsername) {
-		this.aftUsername = aftUsername;
+	public void setName(String name) {
+		this.name = name;
 	}
 	}
 
 
 	public String getProvince() {
 	public String getProvince() {

+ 5 - 5
src/main/java/com/goafanti/customer/bo/CustomerListOut.java

@@ -8,7 +8,7 @@ public class CustomerListOut {
 	private String type;
 	private String type;
 	
 	
 	/** 客户名称 **/
 	/** 客户名称 **/
-	private String aftUsername;
+	private String name;
 	
 	
 	/** 客户状态  0-正常 1-注销 2-锁定**/
 	/** 客户状态  0-正常 1-注销 2-锁定**/
 	private String status;
 	private String status;
@@ -71,12 +71,12 @@ public class CustomerListOut {
 		this.type = type;
 		this.type = type;
 	}
 	}
 
 
-	public String getAftUsername() {
-		return aftUsername;
+	public String getName() {
+		return name;
 	}
 	}
 
 
-	public void setAftUsername(String aftUsername) {
-		this.aftUsername = aftUsername;
+	public void setName(String name) {
+		this.name = name;
 	}
 	}
 
 
 	public String getStatus() {
 	public String getStatus() {

+ 2 - 2
src/main/java/com/goafanti/customer/service/impl/CustomerServiceImpl.java

@@ -47,7 +47,7 @@ public class CustomerServiceImpl  extends BaseMybatisDao<UserMapper> implements
 		Map<String,Object> params = new HashMap<String, Object>();
 		Map<String,Object> params = new HashMap<String, Object>();
 		if(StringUtils.isNotBlank(cli.getType())) params.put("type", Integer.parseInt(cli.getType()));
 		if(StringUtils.isNotBlank(cli.getType())) params.put("type", Integer.parseInt(cli.getType()));
 		if(StringUtils.isNotBlank(cli.getShareType())) params.put("shareType", Integer.parseInt(cli.getShareType()));
 		if(StringUtils.isNotBlank(cli.getShareType())) params.put("shareType", Integer.parseInt(cli.getShareType()));
-		if(StringUtils.isNotBlank(cli.getAftUsername())) params.put("aftUserName", cli.getAftUsername());
+		if(StringUtils.isNotBlank(cli.getName())) params.put("name", cli.getName());
 		if(StringUtils.isNotBlank(cli.getProvince())) params.put("province", Integer.parseInt(cli.getProvince()));
 		if(StringUtils.isNotBlank(cli.getProvince())) params.put("province", Integer.parseInt(cli.getProvince()));
 		if(StringUtils.isNotBlank(cli.getCity())) params.put("city", Integer.parseInt(cli.getCity()));
 		if(StringUtils.isNotBlank(cli.getCity())) params.put("city", Integer.parseInt(cli.getCity()));
 		if(StringUtils.isNotBlank(cli.getArea())) params.put("area", Integer.parseInt(cli.getArea()));
 		if(StringUtils.isNotBlank(cli.getArea())) params.put("area", Integer.parseInt(cli.getArea()));
@@ -67,4 +67,4 @@ public class CustomerServiceImpl  extends BaseMybatisDao<UserMapper> implements
 		if(StringUtils.isNotBlank(cli.getEndDate())) params.put("endDate", cli.getEndDate()+" 23:59:59");
 		if(StringUtils.isNotBlank(cli.getEndDate())) params.put("endDate", cli.getEndDate()+" 23:59:59");
 		return params;
 		return params;
 	}
 	}
-}
+}