Commit 8389ae0f authored by huangjie's avatar huangjie

Merge branch 'dev20230707' of http://192.168.60.201/root/dsk-operate-sys into dev20230707

parents abf9632b 6d2e4a11
package com.dsk.common.utils; package com.dsk.common.utils;
import java.math.BigDecimal;
import java.util.regex.Matcher; import java.util.regex.Matcher;
import java.util.regex.Pattern; import java.util.regex.Pattern;
...@@ -51,7 +52,8 @@ public class CheckUtils { ...@@ -51,7 +52,8 @@ public class CheckUtils {
* @return * @return
*/ */
public static int checkIntegerPlaces(Double number) { public static int checkIntegerPlaces(Double number) {
String strNumber = Double.toString(Math.abs(number)); BigDecimal bigDecimal = new BigDecimal(number);
String strNumber = bigDecimal.toString();
int integerPlaces = strNumber.indexOf('.'); int integerPlaces = strNumber.indexOf('.');
if (integerPlaces == -1) { if (integerPlaces == -1) {
return strNumber.length(); return strNumber.length();
...@@ -66,7 +68,8 @@ public class CheckUtils { ...@@ -66,7 +68,8 @@ public class CheckUtils {
* @return * @return
*/ */
public static int checkDecimalPlaces(Double number) { public static int checkDecimalPlaces(Double number) {
String strNumber = Double.toString(Math.abs(number)); BigDecimal bigDecimal = new BigDecimal(number);
String strNumber = bigDecimal.toString();
int decimalPlaces = 0; int decimalPlaces = 0;
int index = strNumber.indexOf('.'); int index = strNumber.indexOf('.');
if (index != -1) { if (index != -1) {
......
...@@ -394,8 +394,11 @@ ul, li { ...@@ -394,8 +394,11 @@ ul, li {
} }
} }
} }
}
.el-table__body tr.hover-row > td.el-table__cell{
background-color: #DCEBFF;
} }
.common-title{ .common-title{
border-left: 2px solid #445781; border-left: 2px solid #445781;
padding-left: 8px; padding-left: 8px;
......
...@@ -35,7 +35,7 @@ ...@@ -35,7 +35,7 @@
</span> </span>
<label class="label">中标时间</label> <label class="label">中标时间</label>
<span>{{info.winBidTime||"--"}}</span> <span>{{info.winBidTime||"--"}}</span>
<label class="label">中标金额(万)</label> <label class="label">中标金额</label>
<span>{{info.winBidAmount||"--"}}</span> <span>{{info.winBidAmount||"--"}}</span>
</p> </p>
<p> <p>
...@@ -49,7 +49,7 @@ ...@@ -49,7 +49,7 @@
<p> <p>
<label class="label">工期(天)</label> <label class="label">工期(天)</label>
<span>{{info.period||"--"}}</span> <span>{{info.period||"--"}}</span>
<label class="label">下浮率</label> <label class="label">下浮率(%)</label>
<span>{{info.lowerRate||"--"}}</span> <span>{{info.lowerRate||"--"}}</span>
<label class="label">建设性质</label> <label class="label">建设性质</label>
<span>{{info.projectNature||"--"}}</span> <span>{{info.projectNature||"--"}}</span>
......
...@@ -3,7 +3,7 @@ ...@@ -3,7 +3,7 @@
<div class="content"> <div class="content">
<div class="content_item"> <div class="content_item">
<div class="content_right item_ckquery_list"> <div class="content_right item_ckquery_list">
<el-input class="ename_input" placeholder="请输入企业名称关键字" v-model="keys" > <el-input class="ename_input" placeholder="请输入企业名称关键字" clearable v-model="keys" >
<div slot="append" class="btn-search" @click="search()">搜索</div> <div slot="append" class="btn-search" @click="search()">搜索</div>
</el-input> </el-input>
......
...@@ -4,7 +4,7 @@ ...@@ -4,7 +4,7 @@
<div class="content"> <div class="content">
<div class="content_item content_item_padding0"> <div class="content_item content_item_padding0">
<div class="content_right item_ckquery_list"> <div class="content_right item_ckquery_list">
<el-input class="ename_input" placeholder="请输入关键字,如企业名称、统一社会信用代码等" v-model="ename" @input="projectNamebtn('ename',ename,'关键字:')"> <el-input class="ename_input" clearable placeholder="请输入关键字,如企业名称、统一社会信用代码等" v-model="ename" @input="projectNamebtn('ename',ename,'关键字:')">
<div slot="append" class="btn-search" @click="search()">搜索</div> <div slot="append" class="btn-search" @click="search()">搜索</div>
</el-input> </el-input>
<!-- <template v-if="ename"> <!-- <template v-if="ename">
......
...@@ -87,7 +87,10 @@ ...@@ -87,7 +87,10 @@
</p> </p>
<p> <p>
<label class="label">项目联系方式</label> <label class="label">项目联系方式</label>
<span>{{textList.personTel||'--'}}</span> <span v-if="textList.personTel && textList.personTel.length>0">
<template v-for="item in JSON.parse(textList.personTel)">{{ item.tel }} </template>
</span>
<span v-else>--</span>
<label class="label">行业分类</label> <label class="label">行业分类</label>
<span>{{textList.projectIndustry||'--'}}</span> <span>{{textList.projectIndustry||'--'}}</span>
</p> </p>
......
...@@ -35,6 +35,7 @@ import com.dsk.system.mapper.BusinessUserMapper; ...@@ -35,6 +35,7 @@ import com.dsk.system.mapper.BusinessUserMapper;
import com.dsk.system.service.IBusinessInfoService; import com.dsk.system.service.IBusinessInfoService;
import com.dsk.system.service.ICustomerService; import com.dsk.system.service.ICustomerService;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.apache.commons.collections4.CollectionUtils;
import org.apache.commons.collections4.MapUtils; import org.apache.commons.collections4.MapUtils;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service; import org.springframework.stereotype.Service;
...@@ -141,7 +142,13 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService { ...@@ -141,7 +142,13 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService {
@Override @Override
public List<BusinessLikeProjectNameListVo> selectProjectName(BusinessListDto dto) { public List<BusinessLikeProjectNameListVo> selectProjectName(BusinessListDto dto) {
return businessInfoMapper.selectProjectName(dto); List<BusinessLikeProjectNameListVo> vos = businessInfoMapper.selectProjectName(dto);
if (!CollectionUtils.isEmpty(vos)) {
for (BusinessLikeProjectNameListVo vo : vos) {
vo.setProjectName(vo.getProjectName().replace(dto.getProjectName(), "<font color='#FF204E'>" + dto.getProjectName() + "</font>"));
}
}
return vos;
} }
@Override @Override
......
...@@ -3,10 +3,12 @@ package com.dsk.system.service.impl; ...@@ -3,10 +3,12 @@ package com.dsk.system.service.impl;
import cn.hutool.core.bean.BeanException; import cn.hutool.core.bean.BeanException;
import cn.hutool.core.bean.BeanUtil; import cn.hutool.core.bean.BeanUtil;
import cn.hutool.core.map.MapUtil; import cn.hutool.core.map.MapUtil;
import cn.hutool.core.util.ObjectUtil;
import com.baomidou.mybatisplus.core.toolkit.Wrappers; import com.baomidou.mybatisplus.core.toolkit.Wrappers;
import com.dsk.common.core.domain.R; import com.dsk.common.core.domain.R;
import com.dsk.common.exception.ServiceException; import com.dsk.common.exception.ServiceException;
import com.dsk.common.utils.SecurityUtils; import com.dsk.common.utils.SecurityUtils;
import com.dsk.common.utils.StringUtils;
import com.dsk.system.domain.customer.Customer; import com.dsk.system.domain.customer.Customer;
import com.dsk.system.domain.customer.CustomerUser; import com.dsk.system.domain.customer.CustomerUser;
import com.dsk.system.domain.customer.dto.CustomerBusinessSearchDto; import com.dsk.system.domain.customer.dto.CustomerBusinessSearchDto;
...@@ -179,36 +181,53 @@ public class CustomerServiceImpl implements ICustomerService { ...@@ -179,36 +181,53 @@ public class CustomerServiceImpl implements ICustomerService {
private void dealWithcustomerData(Customer customer) { private void dealWithcustomerData(Customer customer) {
if (ObjectUtils.isEmpty(customer.getCompanyName())) throw new BeanException("企业名称不能为空"); if (ObjectUtils.isEmpty(customer.getCompanyName())) throw new BeanException("企业名称不能为空");
if (ObjectUtils.isEmpty(customer.getCompanyId())) { try {
try { Map<String, Object> map = opportunityRadarService.enterpriseByName(customer.getCompanyName());
Map<String, Object> map = opportunityRadarService.enterpriseByName(customer.getCompanyName()); if (!ObjectUtils.isEmpty(map.get("data"))) {
if (!ObjectUtils.isEmpty(map.get("data"))) { Map<String, Object> data = BeanUtil.beanToMap(map.get("data"));
customer.setCompanyId(MapUtil.getInt(BeanUtil.beanToMap(map.get("data")), "jskEid")); Integer companyId = MapUtil.getInt(data, "jskEid");
if (ObjectUtils.isEmpty(customer.getLegalPerson())) { if(ObjectUtil.isNotEmpty(customer.getCompanyId()) && !customer.getCompanyId().equals(companyId)) {
customer.setLegalPerson(MapUtil.getStr(map, "legalPerson")); return;
} }
if (ObjectUtils.isEmpty(customer.getRegisterCapital())) { customer.setCompanyId(companyId);
customer.setRegisterCapital(MapUtil.getStr(map, "registeredCapitalStr")); if (ObjectUtils.isEmpty(customer.getLegalPerson())) {
} customer.setLegalPerson(MapUtil.getStr(data, "legalPerson"));
if (ObjectUtils.isEmpty(customer.getProvinceId())) { }
customer.setProvinceId(MapUtil.getInt(map, "provinceId")); if (ObjectUtils.isEmpty(customer.getRegisterCapital())) {
} customer.setRegisterCapital(MapUtil.getStr(data, "registeredCapitalStr"));
if (ObjectUtils.isEmpty(customer.getCityId())) { }
customer.setCityId(MapUtil.getInt(map, "cityId")); if (ObjectUtils.isEmpty(customer.getProvinceId())) {
} customer.setProvinceId(MapUtil.getInt(data, "provinceId"));
if (ObjectUtils.isEmpty(customer.getDistrictId())) { }
customer.setDistrictId(MapUtil.getInt(map, "countyId")); if (ObjectUtils.isEmpty(customer.getCityId())) {
} customer.setCityId(MapUtil.getInt(data, "cityId"));
if (ObjectUtils.isEmpty(customer.getRegisterAddress())) { }
customer.setRegisterAddress(MapUtil.getStr(map, "domicile")); if (ObjectUtils.isEmpty(customer.getDistrictId())) {
} customer.setDistrictId(MapUtil.getInt(data, "countyId"));
if (ObjectUtils.isEmpty(customer.getCreditCode())) { }
customer.setCreditCode(MapUtil.getStr(map, "creditCode")); if (ObjectUtils.isEmpty(customer.getRegisterAddress())) {
if(ObjectUtil.isNotEmpty(MapUtil.getStr(data, "domicile"))){
customer.setRegisterAddress(MapUtil.getStr(data, "domicile"));
}else {
String address = null;
if (ObjectUtils.isEmpty(MapUtil.getStr(data, "province"))) {
address = MapUtil.getStr(data, "province");
if (ObjectUtils.isEmpty(MapUtil.getStr(data, "city"))) {
address = address.concat("-").concat(MapUtil.getStr(data, "city"));
if (ObjectUtils.isEmpty(MapUtil.getStr(data, "county"))) {
address = address.concat("-").concat(MapUtil.getStr(data, "county"));
}
}
}
customer.setRegisterAddress(address);
} }
} }
} catch (Exception e) { if (ObjectUtils.isEmpty(customer.getCreditCode())) {
log.debug("获取企业id错误!error:{}", e.getMessage()); customer.setCreditCode(MapUtil.getStr(data, "creditCode"));
}
} }
} catch (Exception e) {
log.debug("获取企业id错误!error:{}", e.getMessage());
} }
} }
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment