Browse Source

修改:添加供应商审核节点字段,修改查询语句方法返回为SysSupplierVo对象。

dev
zhangsiqi 5 months ago
parent
commit
538710a006
  1. 7
      ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSupplierController.java
  2. 123
      ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSupplier.java
  3. 13
      ruoyi-admin/src/main/java/com/ruoyi/system/mapper/SysSupplierMapper.java
  4. 7
      ruoyi-admin/src/main/java/com/ruoyi/system/service/ISysSupplierService.java
  5. 13
      ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSupplierServiceImpl.java
  6. 239
      ruoyi-admin/src/main/resources/mapper/system/SysSupplierMapper.xml

7
ruoyi-admin/src/main/java/com/ruoyi/system/controller/SysSupplierController.java

@ -18,6 +18,7 @@ import com.ruoyi.common.utils.ShiroUtils;
import com.ruoyi.process.general.service.IProcessService;
import com.ruoyi.system.domain.SysSalesOrderVo;
import com.ruoyi.system.domain.SysSupplier;
import com.ruoyi.system.domain.Vo.SysSupplierVo;
import com.ruoyi.system.domain.exportDto.SysSupplierDto;
import com.ruoyi.system.service.ISysDictTypeService;
import com.ruoyi.system.service.ISysRoleService;
@ -89,7 +90,7 @@ public class SysSupplierController extends BaseController
{
try {
startPage();
List<SysSupplier> list = sysSupplierService.selectSysSupplierList(sysSupplier);
List<SysSupplierVo> list = sysSupplierService.selectSysSupplierList(sysSupplier);
SysUser curUser = ShiroUtils.getSysUser();
String loginName = ShiroUtils.getLoginName();
Long userId = curUser.getUserId();
@ -99,7 +100,7 @@ public class SysSupplierController extends BaseController
if (curUser.getUserName().contains("admin")) {
SysSupplier sysSupplier2 = new SysSupplier();
startPage();
List<SysSupplier> list2 = sysSupplierService.selectSysSupplierList(sysSupplier2);
List<SysSupplierVo> list2 = sysSupplierService.selectSysSupplierList(sysSupplier2);
return getDataTable(list2);
}
//如果主管审批,查看当前自己部门的审核
@ -115,7 +116,7 @@ public class SysSupplierController extends BaseController
if (roleKeys.contains("cgjlRole")) {
sysSupplier.setCreateBy(curUser.getLoginName());
startPage();
List<SysSupplier> list2 = sysSupplierService.selectSysSupplierList(sysSupplier);
List<SysSupplierVo> list2 = sysSupplierService.selectSysSupplierList(sysSupplier);
return getDataTable(list2);
}
return getDataTable(list);

123
ruoyi-admin/src/main/java/com/ruoyi/system/domain/SysSupplier.java

@ -5,6 +5,8 @@ import org.apache.commons.lang3.builder.ToStringStyle;
import com.ruoyi.common.annotation.Excel;
import com.ruoyi.common.core.domain.BaseEntity;
import java.util.Date;
/**
* 供应商资料对象 sys_supplier
*
@ -151,9 +153,33 @@ public class SysSupplier extends BaseEntity
@Excel(name = "税率")
private String taxRate;
private String firstAddTime;
/** 流程实例ID */
private String instanceId;
/** 流程实例类型 */
private String instanceType;
/** 提交流程实例ID */
private String submitInstanceId;
/** 作废流程实例ID */
private String cancelInstanceId;
/** 恢复流程实例ID */
private String restoreInstanceId;
/** 申请人 */
private String applyTitle;
/** 申请人 */
private String applyUser;
private String updateInfoTime;
/** 申请时间 */
private Date applyTime;
// private String firstAddTime;
//
// private String updateInfoTime;
private Long photoAttachId;
@ -164,6 +190,80 @@ public class SysSupplier extends BaseEntity
private String removeFileIdStr;
private String delFlag;
public String getDelFlag() {
return delFlag;
}
public void setDelFlag(String delFlag) {
this.delFlag = delFlag;
}
public String getInstanceId() {
return instanceId;
}
public void setInstanceId(String instanceId) {
this.instanceId = instanceId;
}
public String getInstanceType() {
return instanceType;
}
public void setInstanceType(String instanceType) {
this.instanceType = instanceType;
}
public String getSubmitInstanceId() {
return submitInstanceId;
}
public void setSubmitInstanceId(String submitInstanceId) {
this.submitInstanceId = submitInstanceId;
}
public String getCancelInstanceId() {
return cancelInstanceId;
}
public void setCancelInstanceId(String cancelInstanceId) {
this.cancelInstanceId = cancelInstanceId;
}
public String getRestoreInstanceId() {
return restoreInstanceId;
}
public void setRestoreInstanceId(String restoreInstanceId) {
this.restoreInstanceId = restoreInstanceId;
}
public String getApplyTitle() {
return applyTitle;
}
public void setApplyTitle(String applyTitle) {
this.applyTitle = applyTitle;
}
public String getApplyUser() {
return applyUser;
}
public void setApplyUser(String applyUser) {
this.applyUser = applyUser;
}
public Date getApplyTime() {
return applyTime;
}
public void setApplyTime(Date applyTime) {
this.applyTime = applyTime;
}
public Long getPhotoAttachId() {
return photoAttachId;
}
@ -235,23 +335,6 @@ public class SysSupplier extends BaseEntity
public void setPurchaseBuyer(String purchaseBuyer) {
this.purchaseBuyer = purchaseBuyer;
}
public String getFirstAddTime() {
return firstAddTime;
}
public void setFirstAddTime(String firstAddTime) {
this.firstAddTime = firstAddTime;
}
public String getUpdateInfoTime() {
return updateInfoTime;
}
public void setUpdateInfoTime(String updateInfoTime) {
this.updateInfoTime = updateInfoTime;
}
public void setSupplierId(Long supplierId)
{
this.supplierId = supplierId;
@ -578,8 +661,6 @@ public class SysSupplier extends BaseEntity
.append("financialContact", getFinancialContact())
.append("confirmTax", getConfirmTax())
.append("taxRate", getTaxRate())
.append("firstAddTime", getFirstAddTime())
.append("updateInfoTime", getUpdateInfoTime())
.toString();
}
}

13
ruoyi-admin/src/main/java/com/ruoyi/system/mapper/SysSupplierMapper.java

@ -1,6 +1,7 @@
package com.ruoyi.system.mapper;
import com.ruoyi.system.domain.SysSupplier;
import com.ruoyi.system.domain.Vo.SysSupplierVo;
import java.util.List;
@ -18,7 +19,7 @@ public interface SysSupplierMapper
* @param supplierId 供应商资料ID
* @return 供应商资料
*/
public SysSupplier selectSysSupplierById(Long supplierId);
public SysSupplierVo selectSysSupplierById(Long supplierId);
/**
* 查询供应商资料列表
@ -26,7 +27,7 @@ public interface SysSupplierMapper
* @param sysSupplier 供应商资料
* @return 供应商资料集合
*/
public List<SysSupplier> selectSysSupplierList(SysSupplier sysSupplier);
public List<SysSupplierVo> selectSysSupplierList(SysSupplier sysSupplier);
/**
* 新增供应商资料
@ -76,4 +77,12 @@ public interface SysSupplierMapper
* 关联退换货 入库后退货-选择供应商-无供应商
* */
List<SysSupplier> getSupplierCodes();
Integer deleteSysSupplierBySupplierCodes(String[] supplierCodes);
Integer deleteSysSupplierBySupplierCode(String supplierCode);
Integer updateSysSupplierBySupplierCode(String delFlag,String sysSupplierCode);
Integer updateSysSupplierBySupplierCodes(String delFlag,SysSupplier[] sysSupplierCodes);
}

7
ruoyi-admin/src/main/java/com/ruoyi/system/service/ISysSupplierService.java

@ -1,6 +1,7 @@
package com.ruoyi.system.service;
import com.ruoyi.system.domain.SysSupplier;
import com.ruoyi.system.domain.Vo.SysSupplierVo;
import org.springframework.stereotype.Service;
import java.util.List;
@ -24,11 +25,11 @@ public interface ISysSupplierService
/**
* 查询供应商资料列表
*
*
* @param sysSupplier 供应商资料
* @return 供应商资料集合
*/
public List<SysSupplier> selectSysSupplierList(SysSupplier sysSupplier);
public List<SysSupplierVo> selectSysSupplierList(SysSupplier sysSupplier);
/**
* 新增供应商资料
@ -71,7 +72,7 @@ public interface ISysSupplierService
Object getId();
public List<SysSupplier> selectSysSupplierListAll();
public List<SysSupplierVo> selectSysSupplierListAll();
/**
* 关联退换货 入库后退货-选择供应商-无供应商

13
ruoyi-admin/src/main/java/com/ruoyi/system/service/impl/SysSupplierServiceImpl.java

@ -7,6 +7,7 @@ import com.ruoyi.common.utils.ShiroUtils;
import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.system.domain.SysAttach;
import com.ruoyi.system.domain.SysSupplier;
import com.ruoyi.system.domain.Vo.SysSupplierVo;
import com.ruoyi.system.mapper.SysSupplierMapper;
import com.ruoyi.system.service.ISysAttachFileService;
import com.ruoyi.system.service.ISysAttachService;
@ -49,19 +50,19 @@ public class SysSupplierServiceImpl implements ISysSupplierService
* @return 供应商资料
*/
@Override
public SysSupplier selectSysSupplierById(Long supplierId)
public SysSupplierVo selectSysSupplierById(Long supplierId)
{
return sysSupplierMapper.selectSysSupplierById(supplierId);
}
/**
* 查询供应商资料列表
*
*
* @param sysSupplier 供应商资料
* @return 供应商资料
*/
@Override
public List<SysSupplier> selectSysSupplierList(SysSupplier sysSupplier)
public List<SysSupplierVo> selectSysSupplierList(SysSupplier sysSupplier)
{
return sysSupplierMapper.selectSysSupplierList(sysSupplier);
}
@ -140,7 +141,7 @@ public class SysSupplierServiceImpl implements ISysSupplierService
}
@Override
public List selectSysSupplierBycode() {
public List<SysSupplier> selectSysSupplierBycode() {
return sysSupplierMapper.selectSysSupplierBycode();
}
@ -158,7 +159,7 @@ public class SysSupplierServiceImpl implements ISysSupplierService
return redisCache.generateBillNo("GYS");
}
@Override
public List<SysSupplier> selectSysSupplierListAll() {
public List<SysSupplierVo> selectSysSupplierListAll() {
SysSupplier sysSupplier = new SysSupplier();
sysSupplier.setAuditStatus("1");
return sysSupplierMapper.selectSysSupplierList(sysSupplier);
@ -174,7 +175,6 @@ public class SysSupplierServiceImpl implements ISysSupplierService
return list;
}
/**
* 关联退换货 入库后退货-选择供应商-无供应商
* */
@ -184,4 +184,5 @@ public class SysSupplierServiceImpl implements ISysSupplierService
List<SysSupplier> list = sysSupplierMapper.getSupplierCodes();
return list;
}
}

239
ruoyi-admin/src/main/resources/mapper/system/SysSupplierMapper.xml

@ -3,48 +3,60 @@
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.ruoyi.system.mapper.SysSupplierMapper">
<resultMap type="SysSupplier" id="SysSupplierResult">
<result property="supplierId" column="supplier_id" />
<result property="useStatus" column="use_status" />
<result property="auditStatus" column="audit_status" />
<result property="supplierQualification" column="supplier_qualification" />
<result property="purchaseBuyer" column="purchase_buyer" />
<result property="supplierType" column="supplier_type" />
<result property="supplierCode" column="supplier_code" />
<result property="supplierName" column="supplier_name" />
<result property="exportSales" column="export_sales" />
<result property="enterpriseName" column="enterprise_name" />
<result property="enterpriseNature" column="enterprise_nature" />
<result property="customerAddress" column="customer_address" />
<result property="manufacturerCategory" column="manufacturer_category" />
<result property="postalCode" column="postal_code" />
<result property="businessScope" column="business_scope" />
<result property="customerCountry" column="customer_country" />
<result property="establishedTime" column="established_time" />
<result property="legalRepresentative" column="legal_representative" />
<result property="customerContact" column="customer_contact" />
<result property="contactNumber" column="contact_number" />
<result property="customerFax" column="customer_fax" />
<result property="customerEmail" column="customer_email" />
<result property="website" column="website" />
<result property="paymentTerms" column="payment_terms" />
<result property="supplierDays" column="supplier_days" />
<result property="actualPaymentDays" column="actual_payment_days" />
<result property="settlementBank" column="settlement_bank" />
<result property="exchangeSettlementAccount" column="exchange_settlement_account" />
<result property="depositBank" column="deposit_bank" />
<result property="bankAccount" column="bank_account" />
<result property="rmbRegisteredCapital" column="rmb_registered_capital" />
<result property="industryCode" column="Industry_code" />
<result property="merchandiser" column="merchandiser" />
<result property="merchandiserTelephone" column="merchandiser_telephone" />
<result property="financialContact" column="financial_contact" />
<result property="confirmTax" column="confirm_tax" />
<result property="taxRate" column="tax_rate" />
<result property="firstAddTime" column="first_add_time" />
<result property="updateInfoTime" column="update_info_time" />
<result property="photoAttachId" column="photo_attach_id" />
<result property="photoUrl" column="photo_url" />
<resultMap type="SysSupplierVo" id="SysSupplierResult">
<result property="supplierId" column="supplier_id" />
<result property="useStatus" column="use_status" />
<result property="auditStatus" column="audit_status" />
<result property="supplierQualification" column="supplier_qualification" />
<result property="purchaseBuyer" column="purchase_buyer" />
<result property="supplierType" column="supplier_type" />
<result property="supplierCode" column="supplier_code" />
<result property="supplierName" column="supplier_name" />
<result property="exportSales" column="export_sales" />
<result property="enterpriseName" column="enterprise_name" />
<result property="enterpriseNature" column="enterprise_nature" />
<result property="customerAddress" column="customer_address" />
<result property="manufacturerCategory" column="manufacturer_category" />
<result property="postalCode" column="postal_code" />
<result property="businessScope" column="business_scope" />
<result property="customerCountry" column="customer_country" />
<result property="establishedTime" column="established_time" />
<result property="legalRepresentative" column="legal_representative" />
<result property="customerContact" column="customer_contact" />
<result property="contactNumber" column="contact_number" />
<result property="customerFax" column="customer_fax" />
<result property="customerEmail" column="customer_email" />
<result property="website" column="website" />
<result property="paymentTerms" column="payment_terms" />
<result property="supplierDays" column="supplier_days" />
<result property="actualPaymentDays" column="actual_payment_days" />
<result property="settlementBank" column="settlement_bank" />
<result property="exchangeSettlementAccount" column="exchange_settlement_account"/>
<result property="depositBank" column="deposit_bank" />
<result property="bankAccount" column="bank_account" />
<result property="rmbRegisteredCapital" column="rmb_registered_capital" />
<result property="industryCode" column="Industry_code" />
<result property="merchandiser" column="merchandiser" />
<result property="merchandiserTelephone" column="merchandiser_telephone" />
<result property="financialContact" column="financial_contact" />
<result property="confirmTax" column="confirm_tax" />
<result property="taxRate" column="tax_rate" />
<result property="photoAttachId" column="photo_attach_id" />
<result property="photoUrl" column="photo_url" />
<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="remark" column="remark" />
<result property="instanceType" column="instance_type" />
<result property="instanceId" column="instance_id" />
<result property="restoreInstanceId" column="restore_instance_id" />
<result property="cancelInstanceId" column="cancel_instance_id" />
<result property="submitInstanceId" column="submit_instance_id" />
<result property="applyTitle" column="apply_title" />
<result property="applyUser" column="apply_user" />
<result property="applyTime" column="apply_time" />
<result property="delFlag" column="del_flag" />
</resultMap>
<sql id="selectSysSupplierVo">
@ -56,7 +68,10 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
customer_email, website, payment_terms, supplier_days, actual_payment_days,
settlement_bank, exchange_settlement_account, deposit_bank, bank_account,
rmb_registered_capital, Industry_code, merchandiser, merchandiser_telephone,
financial_contact, confirm_tax, tax_rate, first_add_time, update_info_time
financial_contact, confirm_tax, tax_rate, photo_attach_id, photo_url, create_by,
create_time, update_by, update_time, remark,
instance_type, instance_id, restore_instance_id, cancel_instance_id, submit_instance_id,
apply_title, apply_user, apply_time,del_flag
from sys_supplier
</sql>
@ -69,34 +84,47 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
sup.customer_email, sup.website, sup.payment_terms, sup.supplier_days, sup.actual_payment_days,
sup.settlement_bank, sup.exchange_settlement_account, sup.deposit_bank, sup.bank_account,
sup.rmb_registered_capital, sup.Industry_code, sup.merchandiser, sup.merchandiser_telephone,
sup.financial_contact, sup.confirm_tax, sup.tax_rate, sup.first_add_time, sup.update_info_time
sup.financial_contact, sup.confirm_tax, sup.tax_rate, sup.first_add_time, sup.update_info_time,
sup.photo_attach_id, sup.create_by, sup.create_time, sup.update_by, sup.update_time, sup.remark,sup.del_flag,
sup.instance_type, sup.instance_id, sup.restore_instance_id, sup.cancel_instance_id, sup.submit_instance_id,
sup.apply_title, sup.apply_user, sup.apply_time,p.dict_value as instance_type_name,file.url as photo_url
from sys_supplier as sup
left join(
select dict_value,dict_label from sys_dict_data
where dict_type = 'processType'
) as p on sup.instance_type = p.dict_value
left join (
select
att.rel_id
,file.url
,min(file.create_time) as create_time
from sys_attach as att
left join sys_attach_file as file
on att.id = file.attach_id
where att.source_type = 'supplier' and att.source_sub_type = 'photo'
group by att.rel_id
)file
on sup.supplier_id = file.rel_id
<where>
select att.rel_id,file.url,min(file.create_time) as create_time
from sys_attach as att left join sys_attach_file as file on att.id = file.attach_id
where att.source_type = 'supplier' and att.source_sub_type = 'photo'
group by att.rel_id
) as file on sup.supplier_id = file.rel_id
<where>
<if test="supplierCode != null and supplierCode != ''"> and sup.supplier_code like concat('%', #{supplierCode}, '%')</if>
<if test="supplierName != null and supplierName != ''"> and sup.supplier_name like concat('%', #{supplierName}, '%')</if>
<if test="supplierType != null and supplierType != ''"> and sup.supplier_type = #{supplierType}</if>
<if test="useStatus != null and useStatus != ''"> and sup.use_status = #{useStatus}</if>
<if test="auditStatus != null and auditStatus != ''"> and sup.audit_status = #{auditStatus}</if>
<if test="purchaseBuyer != null and purchaseBuyer != ''"> and sup.purchase_buyer = #{purchaseBuyer}</if>
<if test="supplierType != null and supplierType != ''"> and sup.supplier_type = #{supplierType}</if>
<if test="useStatus != null and useStatus != ''"> and sup.use_status = #{useStatus}</if>
<if test="auditStatus != null and auditStatus != ''"> and sup.audit_status = #{auditStatus}</if>
<if test="purchaseBuyer != null and purchaseBuyer != ''"> and sup.purchase_buyer = #{purchaseBuyer}</if>
<if test="exportSales != null and exportSales != ''"> and sup.export_sales = #{exportSales}</if>
<if test="enterpriseName != null and enterpriseName != ''"> and sup.enterprise_name like concat('%', #{enterpriseName}, '%')</if>
<if test="customerContact != null and customerContact != ''"> and sup.customer_contact like concat('%', #{customerContact}, '%')</if>
<if test="merchandiser != null and merchandiser != ''"> and sup.merchandiser like concat('%', #{merchandiser}, '%')</if>
<if test="instanceId != null and instanceId != ''"> and sup.instance_id = #{instanceId}</if>
<if test="instanceType != null and instanceType != ''"> and sup.instance_type = #{instanceType}</if>
<if test="submitInstanceId != null and submitInstanceId != ''"> and sup.submit_instance_id = #{submitInstanceId}</if>
<if test="cancelInstanceId != null and cancelInstanceId != ''"> and sup.cancel_instance_id = #{cancelInstanceId}</if>
<if test="restoreInstanceId != null and restoreInstanceId != ''"> and sup.restore_instance_id = #{restoreInstanceId}</if>
<if test="applyTitle != null and applyTitle != ''"> and sup.apply_title = #{applyTitle}</if>
<if test="applyUser != null and applyUser != ''"> and sup.apply_user = #{applyUser}</if>
<if test="applyTime != null "> and sup.apply_time = #{applyTime}</if>
<if test="params.beginCreateTime != null and params.beginCreateTime != '' and params.endCreateTime != null and params.endCreateTime != ''">
and sup.create_time between #{params.beginCreateTime} and #{params.endCreateTime}
</if>
<if test="keyword != null and keyword != ''"> and ((sup.supplierCode like concat('%',#{keyword},'%') or sup.suppplierName like concat('%',#{keyword},'%'))</if>
</where>
order by sup.create_time,sup.supplier_id desc
</select>
<select id="selectSysSupplierById" parameterType="Long" resultMap="SysSupplierResult">
select sup.supplier_id, sup.supplier_code, sup.supplier_name, sup.export_sales,
sup.supplier_type, sup.use_status, sup.audit_status, sup.supplier_qualification, sup.purchase_buyer,
@ -106,24 +134,26 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
sup.customer_email, sup.website, sup.payment_terms, sup.supplier_days, sup.actual_payment_days,
sup.settlement_bank, sup.exchange_settlement_account, sup.deposit_bank, sup.bank_account,
sup.rmb_registered_capital, sup.Industry_code, sup.merchandiser, sup.merchandiser_telephone,
sup.financial_contact, sup.confirm_tax, sup.tax_rate, sup.first_add_time, sup.update_info_time
sup.financial_contact, sup.confirm_tax, sup.tax_rate, sup.first_add_time, sup.update_info_time,
sup.photo_attach_id, sup.create_by, sup.create_time, sup.update_by, sup.update_time, sup.remark,sup.del_flag,
sup.instance_type, sup.instance_id, sup.restore_instance_id, sup.cancel_instance_id, sup.submit_instance_id,
sup.apply_title, sup.apply_user, sup.apply_time,p.dict_value as instance_type_name,file.url as photo_url
from sys_supplier as sup
left join (
select
att.rel_id
,file.url
,min(file.create_time) as create_time
left join(
select dict_value,dict_label from sys_dict_data
where dict_type = 'processType'
) as p on sup.instance_type = p.dict_value
left join (
select att.rel_id,file.url,min(file.create_time) as create_time
from sys_attach as att
left join sys_attach_file as file
on att.id = file.attach_id
where att.source_type = 'supplier' and att.source_sub_type = 'photo'
left join sys_attach_file as file on att.id = file.attach_id
where att.source_type = 'supplier' and att.source_sub_type = 'photo'
group by att.rel_id
)file
on sup.supplier_id = file.rel_id
where sup.supplier_id = #{supplierId}
) as file on sup.supplier_id = file.rel_id where sup.supplier_id = #{supplierId}
</select>
<select id="selectSysSupplierBycode" resultMap="SysSupplierResult">
select supplier_id,supplier_code,supplier_name from sys_supplier where audit_status = 1
<include refid="selectSysSupplierVo"/>
where audit_status = 1 and use_status = 1
</select>
<select id="selectSysSupplierWithMaterial" resultMap="SysSupplierResult">
@ -178,7 +208,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="financialContact != null">financial_contact,</if>
<if test="confirmTax != null">confirm_tax,</if>
<if test="taxRate != null">tax_rate,</if>
audit_status,use_status,first_add_time,
<if test="instanceId != null">instance_id,</if>
<if test="instanceType != null">instance_type,</if>
<if test="submitInstanceId != null">submit_instance_id,</if>
<if test="cancelInstanceId != null">cancel_instance_id,</if>
<if test="restoreInstanceId != null">restore_instance_id,</if>
<if test="applyTitle != null">apply_title,</if>
<if test="applyUser != null">apply_user,</if>
<if test="applyTime != null">apply_time,</if>
<if test="useStatus != null">use_status,</if>
<if test="auditStatus != null">audit_status,</if>
<if test="createBy != null and createBy != ''" >create_by,</if>
<if test="createTime != null">create_time,</if>
<if test="remark != null and remark != ''" >remark,</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
@ -218,7 +260,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="financialContact != null">#{financialContact},</if>
<if test="confirmTax != null">#{confirmTax},</if>
<if test="taxRate != null">#{taxRate},</if>
'1','1',CONCAT_WS(',',NOW(),update_info_time),
<if test="instanceId != null">#{instanceId},</if>
<if test="instanceType != null">#{instanceType},</if>
<if test="submitInstanceId != null">#{submitInstanceId},</if>
<if test="cancelInstanceId != null">#{cancelInstanceId},</if>
<if test="restoreInstanceId != null">#{restoreInstanceId},</if>
<if test="applyTitle != null">#{applyTitle},</if>
<if test="applyUser != null">#{applyUser},</if>
<if test="applyTime != null">#{applyTime},</if>
<if test="useStatus != null">#{useStatus},</if>
<if test="auditStatus != null and auditStatus != ''">#{auditStatus},</if>
<if test="createBy != null and createBy != ''" >#{createBy},</if>
<if test="createTime != null">#{createTime},</if>
<if test="remark != null and remark != ''" >#{remark},</if>
</trim>
</insert>
@ -261,7 +315,19 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="financialContact != null">financial_contact = #{financialContact},</if>
<if test="confirmTax != null">confirm_tax = #{confirmTax},</if>
<if test="taxRate != null">tax_rate = #{taxRate},</if>
update_info_time = CONCAT_WS(',',NOW(),update_info_time),
<if test="instanceId != null">instance_id = #{instanceId},</if>
<if test="instanceType != null">instance_type = #{instanceType},</if>
<if test="submitInstanceId != null">submit_instance_id = #{submitInstanceId},</if>
<if test="cancelInstanceId != null">cancel_instance_id = #{cancelInstanceId},</if>
<if test="restoreInstanceId != null">restore_instance_id = #{restoreInstanceId},</if>
<if test="applyTitle != null">apply_title = #{applyTitle},</if>
<if test="applyUser != null">apply_user = #{applyUser},</if>
<if test="applyTime != null">apply_time = #{applyTime},</if>
<if test="useStatus != null and useStatus != ''" >use_status = #{useStatus},</if>
<if test="auditStatus != null and auditStatus != ''">audit_status = #{auditStatus},</if>
<if test="remark != null and remark != ''" >remark = #{remark},</if>
<if test="updateBy != null and updateBy != ''" >update_by = #{updateBy},</if>
<if test="updateTime != null">update_time = #{updateTime},</if>
</trim>
where supplier_id = #{supplierId}
</update>
@ -270,6 +336,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
delete from sys_supplier where supplier_id = #{supplierId}
</delete>
<delete id="deleteSysSupplierBySupplierCode" parameterType="Long">
delete from sys_supplier where supplier_code = #{supplierCode}
</delete>
<delete id="deleteSysSupplierByIds" parameterType="String">
delete from sys_supplier where supplier_id in
<foreach item="supplierId" collection="array" open="(" separator="," close=")">
@ -277,4 +346,20 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</foreach>
</delete>
<delete id="deleteSysSupplierBySupplierCodes" parameterType="String">
delete from sys_supplier where supplier_id in
<foreach item="supplierCode" collection="array" open="(" separator="," close=")">
#{supplierCode}
</foreach>
</delete>
<update id="updateSysSupplierBySupplierCode" parameterType="String">
update sys_supplier set del_falg = #{delFlag} where supplier_code = #{supplierCode}
</update>
<update id="updateSysSupplierBySupplierCodes" parameterType="String">
update sys_supplier set del_falg = #{delFlag} where supplier_code in
<foreach item="supplierCode" collection="array" open="(" separator="," close=")">
#{supplierCode}
</foreach>
</update>
</mapper>
Loading…
Cancel
Save