diff --git a/emis-biz/src/main/resources/mapper/EmisCustomerUserMapper.xml b/emis-biz/src/main/resources/mapper/EmisCustomerUserMapper.xml index 655a34956..8212c096e 100644 --- a/emis-biz/src/main/resources/mapper/EmisCustomerUserMapper.xml +++ b/emis-biz/src/main/resources/mapper/EmisCustomerUserMapper.xml @@ -184,74 +184,74 @@ a.del_flag='0' - and owner_site = #{ownerSite} + and a.owner_site = #{ownerSite} - and ( FIND_IN_SET(#{bizSite},biz_site) or #{bizSite}=owner_site) + and ( FIND_IN_SET(#{bizSite},a.biz_site) or #{bizSite}=a.owner_site) - and customer_name like concat('%', #{custName}, '%') + and a.customer_name like concat('%', #{custName}, '%') - and id = #{id} - and customer_code =#{customerCode} - and customer_name like concat('%', #{customerName}, '%') + and a.id = #{id} + and a.customer_code =#{customerCode} + and a.customer_name like concat('%', #{customerName}, '%') - and customer_name_en like concat('%', #{customerNameEn}, '%') - and simple_name like concat('%', #{simpleName}, '%') - and contact like concat('%', #{contact}, '%') - and phone like concat('%', #{phone}, '%') - and mobile like concat('%', #{mobile}, '%') - and customer_type=#{customerType} - and settled_type=#{settledType} - and user_type=#{userType} - and company like concat('%', #{company}, '%') - and lic_no like concat('%', #{licNo}, '%') - and dept_id like concat('%', #{deptId}, '%') - and avatar like concat('%', #{avatar}, '%') - and sex= #{sex} - and invitation_info like concat('%', #{invitationInfo}, '%') - and login_ip like concat('%', #{loginIp}, '%') - and login_date like concat('%', #{loginDate}, '%') - and nick_name like concat('%', #{nickName}, '%') - and union_id like concat('%', #{unionId}, '%') - and openid like concat('%', #{openid}, '%') - and monthly_pay_code= #{monthlyPayCode} - and user_name like concat('%', #{userName}, '%') + and a.customer_name_en like concat('%', #{customerNameEn}, '%') + and a.simple_name like concat('%', #{simpleName}, '%') + and a.contact like concat('%', #{contact}, '%') + and a.phone like concat('%', #{phone}, '%') + and a.mobile like concat('%', #{mobile}, '%') + and a.customer_type=#{customerType} + and a.settled_type=#{settledType} + and a.user_type=#{userType} + and a.company like concat('%', #{company}, '%') + and a.lic_no like concat('%', #{licNo}, '%') + and a.dept_id like concat('%', #{deptId}, '%') + and a.avatar like concat('%', #{avatar}, '%') + and a.sex= #{sex} + and a.invitation_info like concat('%', #{invitationInfo}, '%') + and a.login_ip like concat('%', #{loginIp}, '%') + and a.login_date like concat('%', #{loginDate}, '%') + and a.nick_name like concat('%', #{nickName}, '%') + and a.union_id like concat('%', #{unionId}, '%') + and a.openid like concat('%', #{openid}, '%') + and a.monthly_pay_code= #{monthlyPayCode} + and a.user_name like concat('%', #{userName}, '%') - and biz_site_name like concat('%', #{bizSiteName}, '%') - and country=#{country} - and province=#{province} - and city=#{city} - and county=#{county} - and town=#{town} - and address like concat('%', #{address}, '%') - and email like concat('%', #{email}, '%') - and post_code like concat('%', #{postCode}, '%') - and real_name like concat('%', #{realName}, '%') - and id_no like concat('%', #{idNo}, '%') + and a.biz_site_name like concat('%', #{bizSiteName}, '%') + and a.country=#{country} + and a.province=#{province} + and a.city=#{city} + and a.county=#{county} + and a.town=#{town} + and a.address like concat('%', #{address}, '%') + and a.email like concat('%', #{email}, '%') + and a.post_code like concat('%', #{postCode}, '%') + and a.real_name like concat('%', #{realName}, '%') + and a.id_no like concat('%', #{idNo}, '%') - and enterprise_name like concat('%', #{enterpriseName}, '%') - and enterprise_tax_id like concat('%', #{enterpriseTaxId}, '%') - and data_from like concat('%', #{dataFrom}, '%') - and bl_open_oms=#{blOpenOms} - and bl_sms=#{blSms} - and op_emp_code like concat('%', #{opEmpCode}, '%') - and first_signing_day like concat('%', #{firstSigningDay}, '%') + and a.enterprise_name like concat('%', #{enterpriseName}, '%') + and a.enterprise_tax_id like concat('%', #{enterpriseTaxId}, '%') + and a.data_from like concat('%', #{dataFrom}, '%') + and a.bl_open_oms=#{blOpenOms} + and a.bl_sms=#{blSms} + and a.op_emp_code like concat('%', #{opEmpCode}, '%') + and a.first_signing_day like concat('%', #{firstSigningDay}, '%') and a.status=#{status} - and order_num like concat('%', #{orderNum}, '%') - and remark like concat('%', #{remark}, '%') + and a.order_num like concat('%', #{orderNum}, '%') + and a.remark like concat('%', #{remark}, '%') and a.del_flag like concat('%', #{delFlag}, '%') - and create_by like concat('%', #{createBy}, '%') - and create_time = #{createTime} - and update_by like concat('%', #{updateBy}, '%') - and update_time = #{updateTime} - and create_site like concat('%', #{createSite}, '%') - and update_site like concat('%', #{updateSite}, '%') + and a.create_by like concat('%', #{createBy}, '%') + and a.create_time = #{createTime} + and a.update_by like concat('%', #{updateBy}, '%') + and a.update_time = #{updateTime} + and a.create_site like concat('%', #{createSite}, '%') + and a.update_site like concat('%', #{updateSite}, '%') - and credit_period_type=#{creditPeriodType} - and credit_period = #{creditPeriod} - and settle_day = #{settleDay} - and sales_support = #{salesSupport} - and sales_executive = #{salesExecutive} + and a.credit_period_type=#{creditPeriodType} + and a.credit_period = #{creditPeriod} + and a.settle_day = #{settleDay} + and a.sales_support = #{salesSupport} + and a.sales_executive = #{salesExecutive} and ( a.salesmen=#{params.privEmpName} @@ -264,18 +264,18 @@ - and (payee=#{payee} or salesmen=#{salesmen}) + and (a.payee=#{payee} or a.salesmen=#{salesmen}) - and payee=#{payee} - and salesmen=#{salesmen} + and a.payee=#{payee} + and a.salesmen=#{salesmen} - order by create_time desc + order by a.create_time desc