Browse Source

Merge remote-tracking branch 'origin/master'

java8
qiezi 2 years ago
parent
commit
cf023eb585
  1. 7
      src/main/java/com/xujie/sys/modules/project/entity/Project.java
  2. 104
      src/main/java/com/xujie/sys/modules/quote/service/impl/QuotationInformationServiceImpl.java
  3. 6
      src/main/resources/mapper/project/ProjectMapper.xml
  4. 6
      src/main/resources/mapper/quote/QuotationInformationMapper.xml

7
src/main/java/com/xujie/sys/modules/project/entity/Project.java

@ -1,5 +1,6 @@
package com.xujie.sys.modules.project.entity;
import com.baomidou.mybatisplus.annotation.IdType;
import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import com.baomidou.mybatisplus.annotation.TableName;
@ -13,8 +14,8 @@ import java.util.Date;
@Data
public class Project {
@TableId
private Integer id;
@TableId(value = "id",type = IdType.AUTO)
private Integer projectId;
private String projectNo;
@ -96,5 +97,7 @@ public class Project {
private String buDesc;
@TableField(exist = false)
private Integer buId;
@TableField(exist = false)
private String finalCustomerName;
}

104
src/main/java/com/xujie/sys/modules/quote/service/impl/QuotationInformationServiceImpl.java

@ -84,8 +84,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
private static final Logger logger = LoggerFactory.getLogger(HttpClientUtil.class);
/**
* @description: 价信息列表
* @author: fengyuan_yang
* @description: 价信息列表
* @author: jiayang_yue
* @date: 2023/9/11 13:08
* @param: [data]
* @return: com.spring.common.utils.PageUtils
@ -100,16 +100,16 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 价信息新增
* @author: fengyuan_yang
* @date: 2023/9/12 9:27
* @description: 价信息新增
* @author: jiayang_yue
* @date: 2024/8/15 9:27
* @param: [data]
* @return: void
**/
@Override
@Transactional
public void quotationInformationSave(QuotationInformationVo data) {
// 价主单号
// 价主单号
String quotationNo = Constant.XJ+quotationInformationMapper.getQuotationNo(data);
// 创建序列规则
SeqRule seqRule = seqRuleService.lambdaQuery().eq(SeqRule::getSite, data.getSite()).eq(SeqRule::getType, Constant.XJ).eq(SeqRule::getPrefix, quotationNo).one();
@ -130,7 +130,7 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
// 获取序列号
String seqNo = seqRuleService.getSeqNo(data.getSite(),Constant.XJ, quotationNo);
String[] seqNoStr = seqNo.split("-");
// 获取价单号
// 获取价单号
data.setQuotationNo(seqNo);
data.setQuotationBatchNo(quotationNo);
data.setQuotationItemNo(Integer.valueOf(seqNoStr[1]));
@ -139,24 +139,24 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
data.setStepId(10);
quotationInformationMapper.insert(data);
//属性新增
// PriceCheckProperties properties = new PriceCheckProperties();
// properties.setSite(data.getSite());
// properties.setQuotationNo(data.getQuotationNo());
// priceCheckPropertiesService.searchPriceCheckPropertiesListFlushed(properties);
PriceCheckProperties properties = new PriceCheckProperties();
properties.setSite(data.getSite());
properties.setQuotationNo(data.getQuotationNo());
priceCheckPropertiesService.searchPriceCheckPropertiesListFlushed(properties);
}
}
/**
* @description: 价信息编辑
* @author: fengyuan_yang
* @date: 2023/9/12 10:33
* @description: 价信息编辑
* @author: jiayang_yue
* @date: 2024/8/15 10:33
* @param: [data]
* @return: void
**/
@Override
@Transactional
public void quotationInformationEdit(QuotationInformationVo data) {
// 编辑价信息
// 编辑价信息
UpdateWrapper<QuotationInformationEntity> updateInformationWrapper = new UpdateWrapper<>();
updateInformationWrapper.eq("site", data.getSite());
updateInformationWrapper.eq("quotation_no", data.getQuotationNo());
@ -164,9 +164,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 价信息删除
* @author: fengyuan_yang
* @date: 2023/9/12 11:01
* @description: 价信息删除
* @author: jiayang_yue
* @date: 2024/8/15 11:01
* @param: [data]
* @return: void
**/
@ -181,9 +181,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
map1.put("quotation_no", entity.getQuotationNo());
map2.put("order_ref1", entity.getSite());
map2.put("order_ref2", entity.getQuotationNo());
// 删除价信息数据
// 删除价信息数据
quotationInformationMapper.deleteByMap(map1);
// 删除价相关文件
// 删除价相关文件
sysOssDao.deleteByMap(map2);
// 删除详情
priceCheckDetailService.lambdaUpdate().eq(PriceCheckDetail::getSite,entity.getSite()).eq(PriceCheckDetail::getQuotationNo,entity.getQuotationNo()).remove();
@ -191,9 +191,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 获取价单附件列表
* @author: fengyuan_yang
* @date: 2023/9/19 14:57
* @description: 获取价单附件列表
* @author: jiayang_yue
* @date: 2024/8/15 14:57
* @param: [inData]
* @return: java.util.List<com.spring.modules.oss.entity.SysOssEntity>
**/
@ -206,9 +206,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 获取价结果对象
* @author: fengyuan_yang
* @date: 2023/9/19 15:10
* @description: 获取价结果对象
* @author: jiayang_yue
* @date: 2024/8/15 15:10
* @param: [data]
* @return: java.util.List<com.spring.modules.quotation.entity.QuotationInformationEntity>
**/
@ -222,9 +222,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 价结果文件上传
* @author: fengyuan_yang
* @date: 2023/9/25 10:25
* @description: 价结果文件上传
* @author: jiayang_yue
* @date: 2024/8/15 10:25
* @param: [file, inData]
* @return: com.spring.modules.oss.entity.SysOssEntity
**/
@ -277,8 +277,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 文件删除
* @author: fengyuan_yang
* @date: 2023/9/25 11:05
* @author: jiayang_yue
* @date: 2024/8/15 11:05
* @param: [inData]
* @return: void
**/
@ -288,9 +288,9 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 保存价结果
* @author: fengyuan_yang
* @date: 2023/9/25 13:21
* @description: 保存价结果
* @author: jiayang_yue
* @date: 2024/8/15 13:21
* @param: [data]
* @return: void
**/
@ -312,8 +312,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 文件下载
* @author: fengyuan_yang
* @date: 2023/9/25 14:47
* @author: jiayang_yue
* @date: 2024/8/15 14:47
* @param: [id, response]
* @return: void
**/
@ -365,8 +365,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 保存提交结果
* @author: fengyuan_yang
* @date: 2023/9/25 14:49
* @author: jiayang_yue
* @date: 2024/8/15 14:49
* @param: [data]
* @return: void
**/
@ -389,8 +389,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 保存客户回复
* @author: fengyuan_yang
* @date: 2023/9/25 15:29
* @author: jiayang_yue
* @date: 2024/8/15 15:29
* @param: [data]
* @return: void
**/
@ -413,17 +413,17 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
}
/**
* @description: 检查价进度是否一致
* @author: fengyuan_yang
* @date: 2023/9/28 13:34
* @description: 检查价进度是否一致
* @author: jiayang_yue
* @date: 2024/8/15 13:34
* @param: [data]
* @return: void
**/
@Override
public Integer checkQuotationStatus(QuotationInformationVo data) {
// 判断价进度是否符合当前按钮
// 判断价进度是否符合当前按钮
boolean b = data.getInformationList().stream().anyMatch(a -> !a.getQuotationResultStatus().equals(data.getCurrentStatus()));
// 判断选中的报价单的报价进度是否一致如果全部相等count应该等于1
// 判断选中的询价单的询价进度是否一致如果全部相等count应该等于1
long count = data.getInformationList().stream().map(QuotationInformationEntity::getQuotationResultStatus).distinct().count();
if (b || count != 1) {
return 2;
@ -434,19 +434,19 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 批量文件删除
* @author: fengyuan_yang
* @date: 2023/10/10 17:12
* @author: jiayang_yue
* @date: 2024/8/15 17:12
* @param: [data]
* @return: void
**/
@Override
@Transactional
public void batchDeleteQuotationFile(SysOssVo data) {
// 根据文件名site价单删除
// 根据文件名site价单删除
SysOssVo sov = new SysOssVo();
sov.setOrderRef1(data.getOrderRef1());
sov.setFileName(data.getFileName());
// 拿到选中的价单
// 拿到选中的价单
for (String quotationNo : data.getQuotationNo().split(";")) {
sov.setOrderRef2(quotationNo);
quotationInformationMapper.batchDeleteQuotationFile(sov);
@ -455,8 +455,8 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
/**
* @description: 关闭模态框删除文件
* @author: fengyuan_yang
* @date: 2023/10/11 8:52
* @author: jiayang_yue
* @date: 2024/8/15 8:52
* @param: [data]
* @return: void
**/
@ -512,7 +512,7 @@ public class QuotationInformationServiceImpl extends ServiceImpl<QuotationInform
* @param site
* @param quotationNo
* @author: zelian_wu
* @date: 2023/11/8
* @date: 2024/8/15
* @return
*/
@Override

6
src/main/resources/mapper/project/ProjectMapper.xml

@ -3,7 +3,8 @@
<mapper namespace="com.xujie.sys.modules.project.mapper.ProjectMapper">
<select id="queryProject" resultType="com.xujie.sys.modules.project.entity.Project">
select p.project_category,
select p.id as projectId,
p.project_category,
p.project_name,
p.status,
p.project_source,
@ -37,7 +38,8 @@
p.project_no,
b.bu_desc,
b.id as buId,
c.customer_desc
c.customer_desc,
CKT_MES_II_REAL.dbo.plm_get_customer_desc(p.site,p.final_customer_id) as final_customer_name
from plm_project_info p
left join BU b on p.bu_no = b.bu_no and p.site = b.site
left join plm_customer_information c on p.site = c.site and p.customer_no = c.customer_no

6
src/main/resources/mapper/quote/QuotationInformationMapper.xml

@ -352,9 +352,9 @@
<result column="min_value" property="minValue"/>
<result column="text_value" property="textValue"/>
<result column="num_value" property="numValue"/>
<collection select="com.spring.modules.test.mapper.TestInformationMapper.selectAvailBleValue" column="{site=site,itemNo=item_no,functionType=function_type}" property="list" ofType="com.xujie.sys.modules.part.entity.PlmPropertiesItemAvailable">
<!-- <collection select="com.spring.modules.test.mapper.TestInformationMapper.selectAvailBleValue" column="{site=site,itemNo=item_no,functionType=function_type}" property="list" ofType="com.xujie.sys.modules.part.entity.PlmPropertiesItemAvailable">-->
</collection>
<!-- </collection>-->
</resultMap>
<select id="searchPriceCheckPropertiesVo" resultMap="getTestPropertiesVo">
SELECT
@ -373,7 +373,7 @@
a.num_value,
a.quotation_no
FROM plm_price_check_properties a
left join plm_properties_model_detail b on a.site = b.site and a.function_type = b.function_type and b.code_no = #{codeNo} and a.item_no = b.properties_item_no
left join plm_properties_model_detail b on a.site = b.site and a.function_type = b.function_type and b.code_no = 'XJ001' and a.item_no = b.properties_item_no
where quotation_no = #{quotationNo} and a.site = #{site} order by b.order_id
</select>

Loading…
Cancel
Save