初步 提交客户/供应商管理
This commit is contained in:
@@ -0,0 +1,473 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.customer.customerinfo.mapper.BmsCustomerMapper">
|
||||
|
||||
<resultMap type="BmsCustomer" id="BmsCustomerResult">
|
||||
<result property="customerId" column="customer_id" />
|
||||
<result property="customerCode" column="customer_code" />
|
||||
<result property="customerName" column="customer_name" />
|
||||
<result property="customerCodeDw" column="customer_code_dw" />
|
||||
<result property="creditCode" column="credit_code" />
|
||||
<result property="customerType" column="customer_type" />
|
||||
<result property="isEnable" column="is_enable" />
|
||||
<result property="salesUserId" column="sales_user_id" />
|
||||
<result property="salesUser" column="sales_user" />
|
||||
<result property="ed" column="ed" />
|
||||
<result property="zq" column="zq" />
|
||||
<result property="settlementUserId" column="settlement_user_id" />
|
||||
<result property="settlementUser" column="settlement_user" />
|
||||
<result property="serviceUserId" column="service_user_id" />
|
||||
<result property="serviceUser" column="service_user" />
|
||||
<result property="settlementType" column="settlement_type" />
|
||||
<result property="tempEd" column="temp_ed" />
|
||||
<result property="accountBalance" column="account_balance" />
|
||||
<result property="foreignCurrencyBalance" column="foreign_currency_balance" />
|
||||
<result property="weightThreshold" column="weight_threshold" />
|
||||
<result property="throwRatio" column="throw_ratio" />
|
||||
<result property="creditEd" column="credit_ed" />
|
||||
<result property="productIds" column="product_ids" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBmsCustomerVo">
|
||||
select customer_id, customer_code, customer_name, customer_code_dw, credit_code, customer_type, is_enable, sales_user_id, sales_user, ed, zq, settlement_user_id, settlement_user, service_user_id, service_user, settlement_type, temp_ed, account_balance, foreign_currency_balance, weight_threshold, throw_ratio, credit_ed, product_ids, remark, create_by, create_time, update_by, update_time, del_flag from bms_customer
|
||||
</sql>
|
||||
|
||||
<select id="selectBmsCustomerList" parameterType="BmsCustomer" resultMap="BmsCustomerResult">
|
||||
<include refid="selectBmsCustomerVo"/>
|
||||
<where>
|
||||
<if test="customerCode != null and customerCode != ''"> and customer_code = #{customerCode}</if>
|
||||
<if test="customerName != null and customerName != ''"> and customer_name like concat('%', #{customerName}, '%')</if>
|
||||
<if test="customerCodeDw != null and customerCodeDw != ''"> and customer_code_dw = #{customerCodeDw}</if>
|
||||
<if test="creditCode != null and creditCode != ''"> and credit_code = #{creditCode}</if>
|
||||
<if test="customerType != null and customerType != ''"> and customer_type = #{customerType}</if>
|
||||
<if test="isEnable != null and isEnable != ''"> and is_enable = #{isEnable}</if>
|
||||
<if test="salesUserId != null and salesUserId != ''"> and sales_user_id = #{salesUserId}</if>
|
||||
<if test="salesUser != null and salesUser != ''"> and sales_user = #{salesUser}</if>
|
||||
<if test="ed != null "> and ed = #{ed}</if>
|
||||
<if test="zq != null "> and zq = #{zq}</if>
|
||||
<if test="settlementUserId != null and settlementUserId != ''"> and settlement_user_id = #{settlementUserId}</if>
|
||||
<if test="settlementUser != null and settlementUser != ''"> and settlement_user = #{settlementUser}</if>
|
||||
<if test="serviceUserId != null and serviceUserId != ''"> and service_user_id = #{serviceUserId}</if>
|
||||
<if test="serviceUser != null and serviceUser != ''"> and service_user = #{serviceUser}</if>
|
||||
<if test="settlementType != null and settlementType != ''"> and settlement_type = #{settlementType}</if>
|
||||
<if test="tempEd != null "> and temp_ed = #{tempEd}</if>
|
||||
<if test="accountBalance != null "> and account_balance = #{accountBalance}</if>
|
||||
<if test="foreignCurrencyBalance != null "> and foreign_currency_balance = #{foreignCurrencyBalance}</if>
|
||||
<if test="weightThreshold != null "> and weight_threshold = #{weightThreshold}</if>
|
||||
<if test="throwRatio != null "> and throw_ratio = #{throwRatio}</if>
|
||||
<if test="creditEd != null "> and credit_ed = #{creditEd}</if>
|
||||
<if test="productIds != null and productIds != ''"> and product_ids = #{productIds}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectBmsCustomerByCustomerId" parameterType="String" resultMap="BmsCustomerResult">
|
||||
<include refid="selectBmsCustomerVo"/>
|
||||
where customer_id = #{customerId}
|
||||
</select>
|
||||
|
||||
<resultMap type="com.ruoyi.customer.customerinfo.domain.BmsCustomerAttachment" id="BmsCustomerAttachmentResult">
|
||||
<result property="attachmentId" column="attachment_id" />
|
||||
<result property="customerId" column="customer_id" />
|
||||
<result property="fileName" column="file_name" />
|
||||
<result property="filePath" column="file_path" />
|
||||
<result property="fileSize" column="file_size" />
|
||||
<result property="fileType" column="file_type" />
|
||||
<result property="fileExtension" column="file_extension" />
|
||||
<result property="attachmentType" column="attachment_type" />
|
||||
<result property="isLogo" column="is_logo" />
|
||||
<result property="sortOrder" column="sort_order" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBmsCustomerAttachmentVo">
|
||||
select attachment_id, customer_id, file_name, file_path, file_size, file_type, file_extension, attachment_type, is_logo, sort_order, remark, create_by, create_time, update_by, update_time, del_flag from bms_customer_attachment
|
||||
</sql>
|
||||
|
||||
<select id="selectBmsCustomerAttachmentList" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerAttachment" resultMap="BmsCustomerAttachmentResult">
|
||||
<include refid="selectBmsCustomerAttachmentVo"/>
|
||||
<where>
|
||||
<if test="customerId != null "> and customer_id = #{customerId}</if>
|
||||
<if test="fileName != null and fileName != ''"> and file_name like concat('%', #{fileName}, '%')</if>
|
||||
<if test="attachmentType != null and attachmentType != ''"> and attachment_type = #{attachmentType}</if>
|
||||
<if test="isLogo != null and isLogo != ''"> and is_logo = #{isLogo}</if>
|
||||
and del_flag = '0'
|
||||
</where>
|
||||
order by sort_order asc
|
||||
</select>
|
||||
|
||||
<insert id="insertBmsCustomerAttachment" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerAttachment" useGeneratedKeys="true" keyProperty="attachmentId">
|
||||
insert into bms_customer_attachment
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">customer_id,</if>
|
||||
<if test="fileName != null">file_name,</if>
|
||||
<if test="filePath != null">file_path,</if>
|
||||
<if test="fileSize != null">file_size,</if>
|
||||
<if test="fileType != null">file_type,</if>
|
||||
<if test="fileExtension != null">file_extension,</if>
|
||||
<if test="attachmentType != null">attachment_type,</if>
|
||||
<if test="isLogo != null">is_logo,</if>
|
||||
<if test="sortOrder != null">sort_order,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="delFlag != null">del_flag,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">#{customerId},</if>
|
||||
<if test="fileName != null">#{fileName},</if>
|
||||
<if test="filePath != null">#{filePath},</if>
|
||||
<if test="fileSize != null">#{fileSize},</if>
|
||||
<if test="fileType != null">#{fileType},</if>
|
||||
<if test="fileExtension != null">#{fileExtension},</if>
|
||||
<if test="attachmentType != null">#{attachmentType},</if>
|
||||
<if test="isLogo != null">#{isLogo},</if>
|
||||
<if test="sortOrder != null">#{sortOrder},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="delFlag != null">#{delFlag},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBmsCustomerAttachment" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerAttachment">
|
||||
update bms_customer_attachment
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="customerId != null">customer_id = #{customerId},</if>
|
||||
<if test="fileName != null">file_name = #{fileName},</if>
|
||||
<if test="filePath != null">file_path = #{filePath},</if>
|
||||
<if test="fileSize != null">file_size = #{fileSize},</if>
|
||||
<if test="fileType != null">file_type = #{fileType},</if>
|
||||
<if test="fileExtension != null">file_extension = #{fileExtension},</if>
|
||||
<if test="attachmentType != null">attachment_type = #{attachmentType},</if>
|
||||
<if test="isLogo != null">is_logo = #{isLogo},</if>
|
||||
<if test="sortOrder != null">sort_order = #{sortOrder},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
</trim>
|
||||
where attachment_id = #{attachmentId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBmsCustomerAttachmentByCustomerId" parameterType="String">
|
||||
update bms_customer_attachment set del_flag = '2' where customer_id = #{customerId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBmsCustomerAttachmentByAttachmentIds" parameterType="String">
|
||||
update bms_customer_attachment set del_flag = '2' where attachment_id in
|
||||
<foreach item="attachmentId" collection="array" open="(" separator="," close=")">
|
||||
#{attachmentId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<insert id="insertBmsCustomer" parameterType="BmsCustomer">
|
||||
insert into bms_customer
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
customer_id,
|
||||
<if test="customerCode != null and customerCode != ''">customer_code,</if>
|
||||
<if test="customerName != null and customerName != ''">customer_name,</if>
|
||||
<if test="customerCodeDw != null">customer_code_dw,</if>
|
||||
<if test="creditCode != null">credit_code,</if>
|
||||
<if test="customerType != null">customer_type,</if>
|
||||
<if test="isEnable != null">is_enable,</if>
|
||||
<if test="salesUserId != null">sales_user_id,</if>
|
||||
<if test="salesUser != null">sales_user,</if>
|
||||
<if test="ed != null">ed,</if>
|
||||
<if test="zq != null">zq,</if>
|
||||
<if test="settlementUserId != null">settlement_user_id,</if>
|
||||
<if test="settlementUser != null">settlement_user,</if>
|
||||
<if test="serviceUserId != null">service_user_id,</if>
|
||||
<if test="serviceUser != null">service_user,</if>
|
||||
<if test="settlementType != null">settlement_type,</if>
|
||||
<if test="tempEd != null">temp_ed,</if>
|
||||
<if test="accountBalance != null">account_balance,</if>
|
||||
<if test="foreignCurrencyBalance != null">foreign_currency_balance,</if>
|
||||
<if test="weightThreshold != null">weight_threshold,</if>
|
||||
<if test="throwRatio != null">throw_ratio,</if>
|
||||
<if test="creditEd != null">credit_ed,</if>
|
||||
<if test="productIds != null">product_ids,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="updateBy != null">update_by,</if>
|
||||
<if test="updateTime != null">update_time,</if>
|
||||
<if test="delFlag != null">del_flag,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
#{customerId},
|
||||
<if test="customerCode != null and customerCode != ''">#{customerCode},</if>
|
||||
<if test="customerName != null and customerName != ''">#{customerName},</if>
|
||||
<if test="customerCodeDw != null">#{customerCodeDw},</if>
|
||||
<if test="creditCode != null">#{creditCode},</if>
|
||||
<if test="customerType != null">#{customerType},</if>
|
||||
<if test="isEnable != null">#{isEnable},</if>
|
||||
<if test="salesUserId != null">#{salesUserId},</if>
|
||||
<if test="salesUser != null">#{salesUser},</if>
|
||||
<if test="ed != null">#{ed},</if>
|
||||
<if test="zq != null">#{zq},</if>
|
||||
<if test="settlementUserId != null">#{settlementUserId},</if>
|
||||
<if test="settlementUser != null">#{settlementUser},</if>
|
||||
<if test="serviceUserId != null">#{serviceUserId},</if>
|
||||
<if test="serviceUser != null">#{serviceUser},</if>
|
||||
<if test="settlementType != null">#{settlementType},</if>
|
||||
<if test="tempEd != null">#{tempEd},</if>
|
||||
<if test="accountBalance != null">#{accountBalance},</if>
|
||||
<if test="foreignCurrencyBalance != null">#{foreignCurrencyBalance},</if>
|
||||
<if test="weightThreshold != null">#{weightThreshold},</if>
|
||||
<if test="throwRatio != null">#{throwRatio},</if>
|
||||
<if test="creditEd != null">#{creditEd},</if>
|
||||
<if test="productIds != null">#{productIds},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="updateBy != null">#{updateBy},</if>
|
||||
<if test="updateTime != null">#{updateTime},</if>
|
||||
<if test="delFlag != null">#{delFlag},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBmsCustomer" parameterType="BmsCustomer">
|
||||
update bms_customer
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="customerCode != null and customerCode != ''">customer_code = #{customerCode},</if>
|
||||
<if test="customerName != null and customerName != ''">customer_name = #{customerName},</if>
|
||||
<if test="customerCodeDw != null">customer_code_dw = #{customerCodeDw},</if>
|
||||
<if test="creditCode != null">credit_code = #{creditCode},</if>
|
||||
<if test="customerType != null">customer_type = #{customerType},</if>
|
||||
<if test="isEnable != null">is_enable = #{isEnable},</if>
|
||||
<if test="salesUserId != null">sales_user_id = #{salesUserId},</if>
|
||||
<if test="salesUser != null">sales_user = #{salesUser},</if>
|
||||
<if test="ed != null">ed = #{ed},</if>
|
||||
<if test="zq != null">zq = #{zq},</if>
|
||||
<if test="settlementUserId != null">settlement_user_id = #{settlementUserId},</if>
|
||||
<if test="settlementUser != null">settlement_user = #{settlementUser},</if>
|
||||
<if test="serviceUserId != null">service_user_id = #{serviceUserId},</if>
|
||||
<if test="serviceUser != null">service_user = #{serviceUser},</if>
|
||||
<if test="settlementType != null">settlement_type = #{settlementType},</if>
|
||||
<if test="tempEd != null">temp_ed = #{tempEd},</if>
|
||||
<if test="accountBalance != null">account_balance = #{accountBalance},</if>
|
||||
<if test="foreignCurrencyBalance != null">foreign_currency_balance = #{foreignCurrencyBalance},</if>
|
||||
<if test="weightThreshold != null">weight_threshold = #{weightThreshold},</if>
|
||||
<if test="throwRatio != null">throw_ratio = #{throwRatio},</if>
|
||||
<if test="creditEd != null">credit_ed = #{creditEd},</if>
|
||||
<if test="productIds != null">product_ids = #{productIds},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="createBy != null">create_by = #{createBy},</if>
|
||||
<if test="createTime != null">create_time = #{createTime},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
<if test="delFlag != null">del_flag = #{delFlag},</if>
|
||||
</trim>
|
||||
where customer_id = #{customerId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBmsCustomerByCustomerId" parameterType="String">
|
||||
delete from bms_customer where customer_id = #{customerId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBmsCustomerByCustomerIds" parameterType="String">
|
||||
delete from bms_customer where customer_id in
|
||||
<foreach item="customerId" collection="array" open="(" separator="," close=")">
|
||||
#{customerId}
|
||||
</foreach>
|
||||
</delete>
|
||||
|
||||
<!-- ========== bms_customer_company 子表 ========== -->
|
||||
<resultMap type="com.ruoyi.customer.customerinfo.domain.BmsCustomerCompany" id="BmsCustomerCompanyResult">
|
||||
<result property="companyId" column="company_id" />
|
||||
<result property="customerId" column="customer_id" />
|
||||
<result property="companyNameFull" column="company_name_full" />
|
||||
<result property="englishName" column="english_name" />
|
||||
<result property="creditCode" column="credit_code" />
|
||||
<result property="legalPerson" column="legal_person" />
|
||||
<result property="legalPersonPhone" column="legal_person_phone" />
|
||||
<result property="legalPersonIdCard" column="legal_person_id_card" />
|
||||
<result property="registeredCapital" column="registered_capital" />
|
||||
<result property="capitalCurrency" column="capital_currency" />
|
||||
<result property="paidInCapital" column="paid_in_capital" />
|
||||
<result property="establishDate" column="establish_date" />
|
||||
<result property="businessTermStart" column="business_term_start" />
|
||||
<result property="businessTermEnd" column="business_term_end" />
|
||||
<result property="businessTermPermanent" column="business_term_permanent" />
|
||||
<result property="registrationAuthority" column="registration_authority" />
|
||||
<result property="registrationNumber" column="registration_number" />
|
||||
<result property="operatingStatus" column="operating_status" />
|
||||
<result property="businessScope" column="business_scope" />
|
||||
<result property="shareholders" column="shareholders" />
|
||||
<result property="employeeCount" column="employee_count" />
|
||||
<result property="companyPhone" column="company_phone" />
|
||||
<result property="companyFax" column="company_fax" />
|
||||
<result property="companyWebsite" column="company_website" />
|
||||
<result property="companyEmail" column="company_email" />
|
||||
<result property="registeredProvince" column="registered_province" />
|
||||
<result property="registeredCity" column="registered_city" />
|
||||
<result property="registeredDistrict" column="registered_district" />
|
||||
<result property="registeredAddressDetail" column="registered_address_detail" />
|
||||
<result property="businessLicenseOssId" column="business_license_oss_id" />
|
||||
<result property="attachmentIds" column="attachment_ids" />
|
||||
<result property="remark" column="remark" />
|
||||
<result property="createBy" column="create_by" />
|
||||
<result property="createTime" column="create_time" />
|
||||
<result property="updateBy" column="update_by" />
|
||||
<result property="updateTime" column="update_time" />
|
||||
<result property="delFlag" column="del_flag" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectBmsCustomerCompanyVo">
|
||||
select company_id, customer_id, company_name_full, english_name, credit_code, legal_person, legal_person_phone, legal_person_id_card, registered_capital, capital_currency, paid_in_capital, establish_date, business_term_start, business_term_end, business_term_permanent, registration_authority, registration_number, operating_status, business_scope, shareholders, employee_count, company_phone, company_fax, company_website, company_email, registered_province, registered_city, registered_district, registered_address_detail, business_license_oss_id, attachment_ids, remark, create_by, create_time, update_by, update_time, del_flag from bms_customer_company
|
||||
</sql>
|
||||
|
||||
<select id="selectBmsCustomerCompanyList" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerCompany" resultMap="BmsCustomerCompanyResult">
|
||||
<include refid="selectBmsCustomerCompanyVo"/>
|
||||
<where>
|
||||
<if test="customerId != null"> and customer_id = #{customerId}</if>
|
||||
<if test="companyNameFull != null and companyNameFull != ''"> and company_name_full like concat('%', #{companyNameFull}, '%')</if>
|
||||
<if test="creditCode != null and creditCode != ''"> and credit_code = #{creditCode}</if>
|
||||
<if test="legalPerson != null and legalPerson != ''"> and legal_person like concat('%', #{legalPerson}, '%')</if>
|
||||
<if test="operatingStatus != null and operatingStatus != ''"> and operating_status = #{operatingStatus}</if>
|
||||
and del_flag = '0'
|
||||
</where>
|
||||
order by company_id asc
|
||||
</select>
|
||||
|
||||
<select id="selectBmsCustomerCompanyByCompanyId" parameterType="Long" resultMap="BmsCustomerCompanyResult">
|
||||
<include refid="selectBmsCustomerCompanyVo"/>
|
||||
where company_id = #{companyId} and del_flag = '0'
|
||||
</select>
|
||||
|
||||
<insert id="insertBmsCustomerCompany" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerCompany" useGeneratedKeys="true" keyProperty="companyId">
|
||||
insert into bms_customer_company
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">customer_id,</if>
|
||||
<if test="companyNameFull != null">company_name_full,</if>
|
||||
<if test="englishName != null">english_name,</if>
|
||||
<if test="creditCode != null">credit_code,</if>
|
||||
<if test="legalPerson != null">legal_person,</if>
|
||||
<if test="legalPersonPhone != null">legal_person_phone,</if>
|
||||
<if test="legalPersonIdCard != null">legal_person_id_card,</if>
|
||||
<if test="registeredCapital != null">registered_capital,</if>
|
||||
<if test="capitalCurrency != null">capital_currency,</if>
|
||||
<if test="paidInCapital != null">paid_in_capital,</if>
|
||||
<if test="establishDate != null">establish_date,</if>
|
||||
<if test="businessTermStart != null">business_term_start,</if>
|
||||
<if test="businessTermEnd != null">business_term_end,</if>
|
||||
<if test="businessTermPermanent != null">business_term_permanent,</if>
|
||||
<if test="registrationAuthority != null">registration_authority,</if>
|
||||
<if test="registrationNumber != null">registration_number,</if>
|
||||
<if test="operatingStatus != null">operating_status,</if>
|
||||
<if test="businessScope != null">business_scope,</if>
|
||||
<if test="shareholders != null">shareholders,</if>
|
||||
<if test="employeeCount != null">employee_count,</if>
|
||||
<if test="companyPhone != null">company_phone,</if>
|
||||
<if test="companyFax != null">company_fax,</if>
|
||||
<if test="companyWebsite != null">company_website,</if>
|
||||
<if test="companyEmail != null">company_email,</if>
|
||||
<if test="registeredProvince != null">registered_province,</if>
|
||||
<if test="registeredCity != null">registered_city,</if>
|
||||
<if test="registeredDistrict != null">registered_district,</if>
|
||||
<if test="registeredAddressDetail != null">registered_address_detail,</if>
|
||||
<if test="businessLicenseOssId != null">business_license_oss_id,</if>
|
||||
<if test="attachmentIds != null">attachment_ids,</if>
|
||||
<if test="remark != null">remark,</if>
|
||||
<if test="createBy != null">create_by,</if>
|
||||
<if test="createTime != null">create_time,</if>
|
||||
<if test="delFlag != null">del_flag,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="customerId != null">#{customerId},</if>
|
||||
<if test="companyNameFull != null">#{companyNameFull},</if>
|
||||
<if test="englishName != null">#{englishName},</if>
|
||||
<if test="creditCode != null">#{creditCode},</if>
|
||||
<if test="legalPerson != null">#{legalPerson},</if>
|
||||
<if test="legalPersonPhone != null">#{legalPersonPhone},</if>
|
||||
<if test="legalPersonIdCard != null">#{legalPersonIdCard},</if>
|
||||
<if test="registeredCapital != null">#{registeredCapital},</if>
|
||||
<if test="capitalCurrency != null">#{capitalCurrency},</if>
|
||||
<if test="paidInCapital != null">#{paidInCapital},</if>
|
||||
<if test="establishDate != null">#{establishDate},</if>
|
||||
<if test="businessTermStart != null">#{businessTermStart},</if>
|
||||
<if test="businessTermEnd != null">#{businessTermEnd},</if>
|
||||
<if test="businessTermPermanent != null">#{businessTermPermanent},</if>
|
||||
<if test="registrationAuthority != null">#{registrationAuthority},</if>
|
||||
<if test="registrationNumber != null">#{registrationNumber},</if>
|
||||
<if test="operatingStatus != null">#{operatingStatus},</if>
|
||||
<if test="businessScope != null">#{businessScope},</if>
|
||||
<if test="shareholders != null">#{shareholders},</if>
|
||||
<if test="employeeCount != null">#{employeeCount},</if>
|
||||
<if test="companyPhone != null">#{companyPhone},</if>
|
||||
<if test="companyFax != null">#{companyFax},</if>
|
||||
<if test="companyWebsite != null">#{companyWebsite},</if>
|
||||
<if test="companyEmail != null">#{companyEmail},</if>
|
||||
<if test="registeredProvince != null">#{registeredProvince},</if>
|
||||
<if test="registeredCity != null">#{registeredCity},</if>
|
||||
<if test="registeredDistrict != null">#{registeredDistrict},</if>
|
||||
<if test="registeredAddressDetail != null">#{registeredAddressDetail},</if>
|
||||
<if test="businessLicenseOssId != null">#{businessLicenseOssId},</if>
|
||||
<if test="attachmentIds != null">#{attachmentIds},</if>
|
||||
<if test="remark != null">#{remark},</if>
|
||||
<if test="createBy != null">#{createBy},</if>
|
||||
<if test="createTime != null">#{createTime},</if>
|
||||
<if test="delFlag != null">#{delFlag},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateBmsCustomerCompany" parameterType="com.ruoyi.customer.customerinfo.domain.BmsCustomerCompany">
|
||||
update bms_customer_company
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="customerId != null">customer_id = #{customerId},</if>
|
||||
<if test="companyNameFull != null">company_name_full = #{companyNameFull},</if>
|
||||
<if test="englishName != null">english_name = #{englishName},</if>
|
||||
<if test="creditCode != null">credit_code = #{creditCode},</if>
|
||||
<if test="legalPerson != null">legal_person = #{legalPerson},</if>
|
||||
<if test="legalPersonPhone != null">legal_person_phone = #{legalPersonPhone},</if>
|
||||
<if test="legalPersonIdCard != null">legal_person_id_card = #{legalPersonIdCard},</if>
|
||||
<if test="registeredCapital != null">registered_capital = #{registeredCapital},</if>
|
||||
<if test="capitalCurrency != null">capital_currency = #{capitalCurrency},</if>
|
||||
<if test="paidInCapital != null">paid_in_capital = #{paidInCapital},</if>
|
||||
<if test="establishDate != null">establish_date = #{establishDate},</if>
|
||||
<if test="businessTermStart != null">business_term_start = #{businessTermStart},</if>
|
||||
<if test="businessTermEnd != null">business_term_end = #{businessTermEnd},</if>
|
||||
<if test="businessTermPermanent != null">business_term_permanent = #{businessTermPermanent},</if>
|
||||
<if test="registrationAuthority != null">registration_authority = #{registrationAuthority},</if>
|
||||
<if test="registrationNumber != null">registration_number = #{registrationNumber},</if>
|
||||
<if test="operatingStatus != null">operating_status = #{operatingStatus},</if>
|
||||
<if test="businessScope != null">business_scope = #{businessScope},</if>
|
||||
<if test="shareholders != null">shareholders = #{shareholders},</if>
|
||||
<if test="employeeCount != null">employee_count = #{employeeCount},</if>
|
||||
<if test="companyPhone != null">company_phone = #{companyPhone},</if>
|
||||
<if test="companyFax != null">company_fax = #{companyFax},</if>
|
||||
<if test="companyWebsite != null">company_website = #{companyWebsite},</if>
|
||||
<if test="companyEmail != null">company_email = #{companyEmail},</if>
|
||||
<if test="registeredProvince != null">registered_province = #{registeredProvince},</if>
|
||||
<if test="registeredCity != null">registered_city = #{registeredCity},</if>
|
||||
<if test="registeredDistrict != null">registered_district = #{registeredDistrict},</if>
|
||||
<if test="registeredAddressDetail != null">registered_address_detail = #{registeredAddressDetail},</if>
|
||||
<if test="businessLicenseOssId != null">business_license_oss_id = #{businessLicenseOssId},</if>
|
||||
<if test="attachmentIds != null">attachment_ids = #{attachmentIds},</if>
|
||||
<if test="remark != null">remark = #{remark},</if>
|
||||
<if test="updateBy != null">update_by = #{updateBy},</if>
|
||||
<if test="updateTime != null">update_time = #{updateTime},</if>
|
||||
</trim>
|
||||
where company_id = #{companyId}
|
||||
</update>
|
||||
|
||||
<delete id="deleteBmsCustomerCompanyByCustomerId" parameterType="String">
|
||||
update bms_customer_company set del_flag = '2' where customer_id = #{customerId}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteBmsCustomerCompanyByCompanyId" parameterType="Long">
|
||||
update bms_customer_company set del_flag = '2' where company_id = #{companyId}
|
||||
</delete>
|
||||
</mapper>
|
||||
Reference in New Issue
Block a user