Commit ad6aaa35 authored by 远方不远's avatar 远方不远
parents f0a73a63 e99e8008
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List; import com.dsk.common.core.controller.BaseController;
import javax.annotation.PostConstruct; import com.dsk.common.core.domain.AjaxResult;
import javax.servlet.http.HttpServletResponse;
import com.dsk.common.core.domain.entity.BusinessBacklog; import com.dsk.common.core.domain.entity.BusinessBacklog;
import com.dsk.common.utils.poi.ExcelUtil; import com.dsk.common.core.page.TableDataInfo;
import com.dsk.system.service.IBusinessBacklogService; import com.dsk.system.service.IBusinessBacklogService;
import io.swagger.annotations.Api; import io.swagger.annotations.Api;
import io.swagger.annotations.ApiOperation; import io.swagger.annotations.ApiOperation;
import lombok.extern.slf4j.Slf4j; import lombok.extern.slf4j.Slf4j;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping; import java.util.List;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType;
import com.dsk.common.core.page.TableDataInfo;
/** /**
* 项目工作待办Controller * 项目工作待办Controller
......
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List;
import javax.servlet.http.HttpServletResponse;
import com.dsk.common.core.domain.entity.BusinessContacts;
import com.dsk.common.utils.poi.ExcelUtil;
import com.dsk.system.service.IBusinessContactsService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController; import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult; import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType; import com.dsk.common.core.domain.entity.BusinessContacts;
import com.dsk.common.core.page.TableDataInfo; import com.dsk.common.core.page.TableDataInfo;
import com.dsk.system.service.IBusinessContactsService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import java.util.List;
/** /**
* 项目联系人Controller * 项目联系人Controller
......
package com.dsk.web.controller.business;
import com.dsk.common.config.RuoYiConfig;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.page.TableDataInfo;
import com.dsk.common.utils.file.FileUploadUtils;
import com.dsk.common.utils.file.FileUtils;
import com.dsk.framework.config.ServerConfig;
import com.dsk.system.domain.BusinessIdDto;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest;
import java.io.IOException;
import java.util.List;
/**
* @author lxl
* @Description: 项目文件管理Controller
* @Date 2023/5/30 上午 8:44
**/
@Slf4j
@RestController
@RequestMapping("/business/file")
public class BusinessFileController extends BaseController {
@Autowired
private ServerConfig serverConfig;
/**
* 新建文件夹
*/
// @PreAuthorize("@ss.hasPermi('system:file:add')")
// @Log(title = "项目资料文档", businessType = BusinessType.INSERT)
@GetMapping("/new/{filePath}")
public AjaxResult newFolder(@PathVariable String filePath) {
return FileUtils.newFolder(RuoYiConfig.getProfile() + filePath) ? AjaxResult.success() : AjaxResult.error();
}
/**
* 删除某个文件或整个文件夹
*/
@PostMapping("/remove")
public AjaxResult removeFile(@RequestBody(required=false) BusinessIdDto folderPath) {
return FileUtils.delFolder(RuoYiConfig.getProfile() + folderPath.getFolderPath()) ? AjaxResult.success() : AjaxResult.error();
}
/**
* 分页查询项目的所有文件
* 获取文件夹中所有文件
*/
@GetMapping(value = "/list")
public TableDataInfo getAllFiles(@RequestBody(required=false) BusinessIdDto folderPath) {
startPage();
List<String> allFiles = FileUtils.getAllFiles(RuoYiConfig.getProfile() + folderPath.getFolderPath());
return getDataTable(allFiles);
}
/* *//**
* 上传文件及文件夹
* @param url
* @param folderPath
* @return
*//*
@GetMapping("/upload/{url}/{folderPath}")
public AjaxResult uploadFolder(@PathVariable("url") String url,@PathVariable("folderPath") String folderPath) throws IOException {
return toAjax(FileUtils.uploadFolder(url, LOCALPATH + folderPath));
}*/
/**
* 上传文件及文件夹
* @param file 文件流
* @param request 请求头参数
* @return
*/
@PostMapping("/upload/")
public AjaxResult uploadFolder(@RequestPart("file") MultipartFile file, HttpServletRequest request){
try {
String businessFileName = request.getParameter("filePath");
// 上传文件路径
String filePath = RuoYiConfig.getUploadPath()+businessFileName;
// 上传并返回新文件名称
String fileName = FileUploadUtils.upload(filePath, file);
String url = serverConfig.getUrl() + fileName;
AjaxResult ajax = AjaxResult.success();
ajax.put("url", url);
ajax.put("fileName", fileName);
ajax.put("newFileName", FileUtils.getName(fileName));
ajax.put("originalFilename", file.getOriginalFilename());
return ajax;
} catch (IOException e) {
return AjaxResult.error(e.getMessage());
}
}
/**
* 下载文件
* @param url
* @param targetFolder
* @return
*/
@GetMapping("/download/{url}/{targetFolder}")
public AjaxResult downloadFolder(@PathVariable("url") String url,@PathVariable("targetFolder") String targetFolder) throws IOException {
return toAjax(FileUtils.downloadFolder(url, targetFolder));
}
}
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List; import com.dsk.common.core.controller.BaseController;
import javax.servlet.http.HttpServletResponse; import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.domain.entity.BusinessFollowRecord; import com.dsk.common.core.domain.entity.BusinessFollowRecord;
import com.dsk.common.core.page.TableDataInfo;
import com.dsk.system.domain.BusinessIdDto; import com.dsk.system.domain.BusinessIdDto;
import com.dsk.system.service.IBusinessFollowRecordService; import com.dsk.system.service.IBusinessFollowRecordService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping; import java.util.List;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType;
import com.dsk.common.utils.poi.ExcelUtil;
import com.dsk.common.core.page.TableDataInfo;
/** /**
* 项目跟进记录Controller * 项目跟进记录Controller
......
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List; import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.domain.entity.BusinessInfo; import com.dsk.common.core.domain.entity.BusinessInfo;
import com.dsk.common.dtos.BusinessInfoDto; import com.dsk.common.core.page.TableDataInfo;
import com.dsk.common.exception.base.BaseException;
import com.dsk.common.utils.CheckUtils;
import com.dsk.system.domain.BusinessAddDto; import com.dsk.system.domain.BusinessAddDto;
import com.dsk.system.domain.BusinessListDto; import com.dsk.system.domain.BusinessListDto;
import com.dsk.system.domain.vo.BusinessBrowseVo;
import com.dsk.system.domain.vo.BusinessListVo; import com.dsk.system.domain.vo.BusinessListVo;
import com.dsk.system.service.IBusinessInfoService; import com.dsk.system.service.IBusinessInfoService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*; import org.springframework.web.bind.annotation.*;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType;
import com.dsk.common.core.page.TableDataInfo;
import org.springframework.web.multipart.MultipartFile; import org.springframework.web.multipart.MultipartFile;
import javax.servlet.http.HttpServletRequest; import java.util.List;
import javax.servlet.http.HttpServletResponse;
/** /**
* 项目详情Controller * 项目详情Controller
...@@ -90,7 +80,7 @@ public class BusinessInfoController extends BaseController ...@@ -90,7 +80,7 @@ public class BusinessInfoController extends BaseController
* 删除项目列表 * 删除项目列表
*/ */
// @PreAuthorize("@ss.hasPermi('system:business:remove')") // @PreAuthorize("@ss.hasPermi('system:business:remove')")
@Log(title = "项目管理", businessType = BusinessType.DELETE) // @Log(title = "项目管理", businessType = BusinessType.DELETE)
@DeleteMapping("/remove/{ids}") @DeleteMapping("/remove/{ids}")
public AjaxResult remove(@PathVariable(value = "ids",required=false) Long[] ids) public AjaxResult remove(@PathVariable(value = "ids",required=false) Long[] ids)
{ {
...@@ -101,7 +91,7 @@ public class BusinessInfoController extends BaseController ...@@ -101,7 +91,7 @@ public class BusinessInfoController extends BaseController
* 新增项目详情 * 新增项目详情
*/ */
// @PreAuthorize("@ss.hasPermi('system:business:add')") // @PreAuthorize("@ss.hasPermi('system:business:add')")
@Log(title = "项目管理", businessType = BusinessType.INSERT) // @Log(title = "项目管理", businessType = BusinessType.INSERT)
@PostMapping("/add") @PostMapping("/add")
public AjaxResult add(@RequestBody BusinessAddDto dto) public AjaxResult add(@RequestBody BusinessAddDto dto)
{ {
...@@ -112,7 +102,7 @@ public class BusinessInfoController extends BaseController ...@@ -112,7 +102,7 @@ public class BusinessInfoController extends BaseController
* 修改项目详情 * 修改项目详情
*/ */
// @PreAuthorize("@ss.hasPermi('system:business:edit')") // @PreAuthorize("@ss.hasPermi('system:business:edit')")
@Log(title = "项目管理", businessType = BusinessType.UPDATE) // @Log(title = "项目管理", businessType = BusinessType.UPDATE)
@PostMapping("/edit") @PostMapping("/edit")
public AjaxResult edit(@RequestBody BusinessInfo businessInfo) public AjaxResult edit(@RequestBody BusinessInfo businessInfo)
{ {
......
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List; import com.dsk.common.core.controller.BaseController;
import javax.servlet.http.HttpServletResponse; import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.domain.entity.BusinessLabel; import com.dsk.common.core.domain.entity.BusinessLabel;
import com.dsk.common.utils.poi.ExcelUtil;
import com.dsk.system.domain.BusinessIdDto; import com.dsk.system.domain.BusinessIdDto;
import com.dsk.system.service.IBusinessLabelService; import com.dsk.system.service.IBusinessLabelService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.PostMapping; import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType;
import com.dsk.common.core.page.TableDataInfo;
/** /**
* 项目标签Controller * 项目标签Controller
......
package com.dsk.web.controller.business; package com.dsk.web.controller.business;
import java.util.List; import com.dsk.common.core.controller.BaseController;
import javax.servlet.http.HttpServletResponse; import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.domain.entity.BusinessRelateCompany; import com.dsk.common.core.domain.entity.BusinessRelateCompany;
import com.dsk.common.utils.poi.ExcelUtil; import com.dsk.common.core.page.TableDataInfo;
import com.dsk.system.domain.BusinessIdDto; import com.dsk.system.domain.BusinessIdDto;
import com.dsk.system.service.IBusinessRelateCompanyService; import com.dsk.system.service.IBusinessRelateCompanyService;
import org.springframework.security.access.prepost.PreAuthorize;
import org.springframework.beans.factory.annotation.Autowired; import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping; import org.springframework.web.bind.annotation.*;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.PutMapping; import java.util.List;
import org.springframework.web.bind.annotation.DeleteMapping;
import org.springframework.web.bind.annotation.PathVariable;
import org.springframework.web.bind.annotation.RequestBody;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;
import com.dsk.common.annotation.Log;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.enums.BusinessType;
import com.dsk.common.core.page.TableDataInfo;
/** /**
* 项目关联单位Controller * 项目相关企业Controller
* *
* @author lxl * @author lxl
* @date 2023-05-17 * @date 2023-05-17
...@@ -37,7 +25,7 @@ public class BusinessRelateCompanyController extends BaseController ...@@ -37,7 +25,7 @@ public class BusinessRelateCompanyController extends BaseController
private IBusinessRelateCompanyService businessRelateCompanyService; private IBusinessRelateCompanyService businessRelateCompanyService;
/** /**
* 查询关联单位角色 * 查询相关企业角色
*/ */
@PostMapping("/role/list") @PostMapping("/role/list")
public AjaxResult companyRoleList(@RequestBody BusinessIdDto dto){ public AjaxResult companyRoleList(@RequestBody BusinessIdDto dto){
...@@ -45,7 +33,7 @@ public class BusinessRelateCompanyController extends BaseController ...@@ -45,7 +33,7 @@ public class BusinessRelateCompanyController extends BaseController
} }
/** /**
* 查询项目关联单位列表 * 查询项目相关企业列表
*/ */
// @PreAuthorize("@ss.hasPermi('system:company:list')") // @PreAuthorize("@ss.hasPermi('system:company:list')")
@GetMapping("/list") @GetMapping("/list")
...@@ -78,6 +66,17 @@ public class BusinessRelateCompanyController extends BaseController ...@@ -78,6 +66,17 @@ public class BusinessRelateCompanyController extends BaseController
return toAjax(businessRelateCompanyService.updateBusinessRelateCompany(businessRelateCompany)); return toAjax(businessRelateCompanyService.updateBusinessRelateCompany(businessRelateCompany));
} }
/**
* 删除项目关联单位
*/
// @PreAuthorize("@ss.hasPermi('system:company:remove')")
// @Log(title = "项目关联单位", businessType = BusinessType.DELETE)
@DeleteMapping("/remove/{ids}")
public AjaxResult remove(@PathVariable Long[] ids)
{
return toAjax(businessRelateCompanyService.deleteBusinessRelateCompanyByIds(ids));
}
// /** // /**
// * 导出项目关联单位列表 // * 导出项目关联单位列表
// */ // */
...@@ -101,15 +100,4 @@ public class BusinessRelateCompanyController extends BaseController ...@@ -101,15 +100,4 @@ public class BusinessRelateCompanyController extends BaseController
// return success(businessRelateCompanyService.selectBusinessRelateCompanyById(id)); // return success(businessRelateCompanyService.selectBusinessRelateCompanyById(id));
// } // }
//
// /**
// * 删除项目关联单位
// */
// @PreAuthorize("@ss.hasPermi('system:company:remove')")
// @Log(title = "项目关联单位", businessType = BusinessType.DELETE)
// @DeleteMapping("/{ids}")
// public AjaxResult remove(@PathVariable Long[] ids)
// {
// return toAjax(businessRelateCompanyService.deleteBusinessRelateCompanyByIds(ids));
// }
} }
package com.dsk.web.controller.search.controller; package com.dsk.web.controller.search.controller;
import com.alibaba.fastjson2.JSONObject; import com.alibaba.fastjson2.JSONObject;
import com.dsk.common.core.controller.BaseController;
import com.dsk.common.core.domain.AjaxResult; import com.dsk.common.core.domain.AjaxResult;
import com.dsk.common.core.page.TableDataInfo;
import com.dsk.common.dtos.ComposeQueryDto; import com.dsk.common.dtos.ComposeQueryDto;
import com.dsk.web.controller.search.service.MarketAnalysisService; import com.dsk.web.controller.search.service.MarketAnalysisService;
import org.springframework.web.bind.annotation.RequestBody; import org.springframework.web.bind.annotation.RequestBody;
...@@ -9,6 +11,9 @@ import org.springframework.web.bind.annotation.RequestMapping; ...@@ -9,6 +11,9 @@ import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController; import org.springframework.web.bind.annotation.RestController;
import javax.annotation.Resource; import javax.annotation.Resource;
import java.util.ArrayList;
import java.util.Calendar;
import java.util.List;
/** /**
...@@ -18,7 +23,7 @@ import javax.annotation.Resource; ...@@ -18,7 +23,7 @@ import javax.annotation.Resource;
*/ */
@RequestMapping("/marketAnalysis") @RequestMapping("/marketAnalysis")
@RestController @RestController
public class MarketAnalysisController { public class MarketAnalysisController extends BaseController {
@Resource @Resource
...@@ -46,9 +51,8 @@ public class MarketAnalysisController { ...@@ -46,9 +51,8 @@ public class MarketAnalysisController {
/* /*
* 资质等级按照大类、省份、等级类型分组 * 资质等级按照大类、省份、等级类型分组
*/ */
@RequestMapping("/certGroupByCategoryProvinceLevel") @RequestMapping("/certGroupByMajorProvinceLevel")
public AjaxResult certGroupByCategoryProvinceLevel() { public AjaxResult certGroupByMajorProvinceLevel() {
return marketAnalysisService.certGroupByMajorProvinceLevel(); return marketAnalysisService.certGroupByMajorProvinceLevel();
} }
...@@ -82,15 +86,27 @@ public class MarketAnalysisController { ...@@ -82,15 +86,27 @@ public class MarketAnalysisController {
* 中标数量按省份分组 * 中标数量按省份分组
*/ */
@RequestMapping("/countGroupByProvince") @RequestMapping("/countGroupByProvince")
public AjaxResult countGroupByProvince(@RequestBody ComposeQueryDto compose) { public AjaxResult countGroupByProvince(@RequestBody JSONObject object) {
return marketAnalysisService.countGroupByProvince(compose); return marketAnalysisService.countGroupByProvince(object);
}
@RequestMapping("/getYear")
public TableDataInfo getYear(){
List<Integer> list = new ArrayList<>();
Calendar calendar = Calendar.getInstance();
int nowYear = calendar.get(Calendar.YEAR);
list.add(nowYear);
for (int i = 1; i < 5; i++) {
list.add(nowYear-i);
}
return getDataTable(list);
} }
/* /*
* 中标数量按月份分组 * 中标数量按月份分组
*/ */
@RequestMapping("/countGroupByMonth") @RequestMapping("/countGroupByMonth")
public AjaxResult countGroupByMonth(@RequestBody ComposeQueryDto compose) { public AjaxResult countGroupByMonth(@RequestBody JSONObject object) {
return marketAnalysisService.countGroupByMonth(compose); return marketAnalysisService.countGroupByMonth(object);
} }
} }
...@@ -17,9 +17,9 @@ public interface MarketAnalysisService { ...@@ -17,9 +17,9 @@ public interface MarketAnalysisService {
AjaxResult certGroupByMajorProvinceLevel(); AjaxResult certGroupByMajorProvinceLevel();
AjaxResult countGroupByProvince(ComposeQueryDto compose); AjaxResult countGroupByProvince(JSONObject object);
AjaxResult countGroupByMonth(ComposeQueryDto compose); AjaxResult countGroupByMonth(JSONObject object);
AjaxResult bidMoneyGroupByProjectType(JSONObject object); AjaxResult bidMoneyGroupByProjectType(JSONObject object);
......
...@@ -56,14 +56,14 @@ public class MarketAnalysisServiceImpl implements MarketAnalysisService { ...@@ -56,14 +56,14 @@ public class MarketAnalysisServiceImpl implements MarketAnalysisService {
} }
@Override @Override
public AjaxResult countGroupByProvince(ComposeQueryDto compose) { public AjaxResult countGroupByProvince(JSONObject object) {
Map<String, Object> map = dskOpenApiUtil.requestBody("/nationzj/marketAnalysis/countGroupByProvince", BeanUtil.beanToMap(compose, false, false)); Map<String, Object> map = dskOpenApiUtil.requestBody("/nationzj/marketAnalysis/countGroupByProvince", object);
return BeanUtil.toBean(map, AjaxResult.class); return BeanUtil.toBean(map, AjaxResult.class);
} }
@Override @Override
public AjaxResult countGroupByMonth(ComposeQueryDto compose) { public AjaxResult countGroupByMonth(JSONObject object) {
Map<String, Object> map = dskOpenApiUtil.requestBody("/nationzj/marketAnalysis/countGroupByDate", BeanUtil.beanToMap(compose, false, false)); Map<String, Object> map = dskOpenApiUtil.requestBody("/nationzj/marketAnalysis/countGroupByMonth", object);
return BeanUtil.toBean(map, AjaxResult.class); return BeanUtil.toBean(map, AjaxResult.class);
} }
} }
...@@ -8,8 +8,9 @@ ruoyi: ...@@ -8,8 +8,9 @@ ruoyi:
copyrightYear: 2023 copyrightYear: 2023
# 实例演示开关 # 实例演示开关
demoEnabled: true demoEnabled: true
# 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/ruoyi/uploadPath) # 文件路径 示例( Windows配置D:/ruoyi/uploadPath,Linux配置 /home/server/dsk-operate-sys/uploadPath)
profile: D:/dsk-operate-sys/uploadPath/ # profile: D:/dsk-operate-sys/uploadPath/
profile: /home/server/dsk-operate-sys/uploadPath/
# 获取ip地址开关 # 获取ip地址开关
addressEnabled: false addressEnabled: false
# 验证码类型 math 数组计算 char 字符验证 # 验证码类型 math 数组计算 char 字符验证
......
...@@ -53,6 +53,10 @@ public class BusinessRelateCompany extends BaseEntity ...@@ -53,6 +53,10 @@ public class BusinessRelateCompany extends BaseEntity
@Excel(name = "对接深度/竞争力度") @Excel(name = "对接深度/竞争力度")
private String depth; private String depth;
/** 企业类型 */
@Excel(name = "企业类型")
private String companyType;
@Override @Override
public String toString() { public String toString() {
return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE) return new ToStringBuilder(this, ToStringStyle.MULTI_LINE_STYLE)
...@@ -66,6 +70,7 @@ public class BusinessRelateCompany extends BaseEntity ...@@ -66,6 +70,7 @@ public class BusinessRelateCompany extends BaseEntity
.append("createTime", getCreateTime()) .append("createTime", getCreateTime())
.append("updateTime", getUpdateTime()) .append("updateTime", getUpdateTime())
.append("depth", getDepth()) .append("depth", getDepth())
.append("companyType", getCompanyType())
.toString(); .toString();
} }
......
...@@ -32,5 +32,15 @@ public class EnterpriseCreditLawsuitsPageBody extends BasePage { ...@@ -32,5 +32,15 @@ public class EnterpriseCreditLawsuitsPageBody extends BasePage {
*/ */
private String keys; private String keys;
/**
* 开始时间(年月日)
*/
private String dateFrom;
/**
* 截止时间(年月日)
*/
private String dateTo;
} }
...@@ -27,7 +27,7 @@ public class EnterpriseProjectBidNoticePageBody extends BasePage { ...@@ -27,7 +27,7 @@ public class EnterpriseProjectBidNoticePageBody extends BasePage {
/** /**
* 类型 * 类型
*/ */
private String tenderStage; private List<String> tenderStage;
/* /*
* 1金额倒序,2金额正序,3时间倒序,4时间正序 * 1金额倒序,2金额正序,3时间倒序,4时间正序
......
package com.dsk.common.utils.file; package com.dsk.common.utils.file;
import java.io.File; import com.dsk.common.config.RuoYiConfig;
import java.io.FileInputStream; import com.dsk.common.exception.base.BaseException;
import java.io.FileNotFoundException; import com.dsk.common.utils.DateUtils;
import java.io.FileOutputStream; import com.dsk.common.utils.StringUtils;
import java.io.IOException; import com.dsk.common.utils.uuid.IdUtils;
import java.io.OutputStream; import lombok.extern.slf4j.Slf4j;
import java.io.UnsupportedEncodingException; import org.apache.commons.io.FilenameUtils;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.ArrayUtils;
import org.apache.http.HttpEntity;
import org.apache.http.HttpResponse;
import org.apache.http.client.methods.HttpPost;
import org.apache.http.entity.ContentType;
import org.apache.http.entity.mime.MultipartEntityBuilder;
import org.apache.http.entity.mime.content.FileBody;
import org.apache.http.impl.client.CloseableHttpClient;
import org.apache.http.impl.client.HttpClients;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import java.io.*;
import java.net.HttpURLConnection; import java.net.HttpURLConnection;
import java.net.URL; import java.net.URL;
import java.net.URLEncoder; import java.net.URLEncoder;
...@@ -15,17 +29,6 @@ import java.util.ArrayList; ...@@ -15,17 +29,6 @@ import java.util.ArrayList;
import java.util.List; import java.util.List;
import java.util.zip.ZipEntry; import java.util.zip.ZipEntry;
import java.util.zip.ZipInputStream; import java.util.zip.ZipInputStream;
import javax.servlet.http.HttpServletRequest;
import javax.servlet.http.HttpServletResponse;
import com.dsk.common.utils.DateUtils;
import com.dsk.common.utils.StringUtils;
import lombok.extern.slf4j.Slf4j;
import org.apache.commons.io.IOUtils;
import org.apache.commons.lang3.ArrayUtils;
import com.dsk.common.config.RuoYiConfig;
import com.dsk.common.utils.uuid.IdUtils;
import org.apache.commons.io.FilenameUtils;
/** /**
* 文件处理工具类 * 文件处理工具类
...@@ -38,6 +41,10 @@ public class FileUtils ...@@ -38,6 +41,10 @@ public class FileUtils
public static String FILENAME_PATTERN = "[a-zA-Z0-9_\\-\\|\\.\\u4e00-\\u9fa5]+"; public static String FILENAME_PATTERN = "[a-zA-Z0-9_\\-\\|\\.\\u4e00-\\u9fa5]+";
public static void main(String[] args) {
System.out.println(RuoYiConfig.getProfile());
}
/** /**
* 检查目录是否存在,如果不存在,则创建目录,如果创建失败则返回false * 检查目录是否存在,如果不存在,则创建目录,如果创建失败则返回false
* *
...@@ -49,8 +56,10 @@ public class FileUtils ...@@ -49,8 +56,10 @@ public class FileUtils
if (!file.exists()) { if (!file.exists()) {
boolean isSuccess = file.mkdir(); boolean isSuccess = file.mkdir();
if (!isSuccess) if (!isSuccess)
if (!file.exists()) {
file.mkdirs(); file.mkdirs();
return !isSuccess; }
return isSuccess;
} else { } else {
return true; return true;
} }
...@@ -152,12 +161,12 @@ public class FileUtils ...@@ -152,12 +161,12 @@ public class FileUtils
return FileUploadUtils.getPathFileName(uploadDir, pathName); return FileUploadUtils.getPathFileName(uploadDir, pathName);
} }
/* *//** /**
* 删除文件 * 删除文件
* *
* @param filePath 文件 * @param filePath 文件
* @return * @return
*//* */
public static boolean deleteFile(String filePath) public static boolean deleteFile(String filePath)
{ {
boolean flag = false; boolean flag = false;
...@@ -168,22 +177,20 @@ public class FileUtils ...@@ -168,22 +177,20 @@ public class FileUtils
flag = file.delete(); flag = file.delete();
} }
return flag; return flag;
}*/ }
/** /**
* 删除整个文件夹或者文某个文件 * 删除整个文件夹或者文某个文件
* *
* @param filePath 文件 * @param filePath 文件
* @return * @return
*/ */
public static boolean deleteFile(String filePath) { public static boolean delFolder(String filePath) {
try { try {
if(StringUtils.isNotEmpty(delAllFile(filePath))) return false; delAllFile(filePath); // 删除里面的所有文件
File file = new File(filePath); File file = new File(filePath);
return file.delete(); return file.delete(); // 删除空文件夹
} catch (Exception e) { } catch (Exception e) {
log.info("删除文件失败"); throw new BaseException("删除文件夹失败",e.getMessage());
e.printStackTrace();
return false;
} }
} }
...@@ -192,32 +199,50 @@ public class FileUtils ...@@ -192,32 +199,50 @@ public class FileUtils
* *
* @param path 文件夹路径 * @param path 文件夹路径
*/ */
public static String delAllFile(String path) { public static void delAllFile(String path) {
String hint = "这是一个根目录,请更换目录!"; String hint = "这是一个根目录,请更换目录!";
File file = new File(path); File file = new File(path);
if (!file.exists()) { if (!file.exists()) {
return hint; throw new BaseException("文件不存在");
} }
// if (!file.isDirectory()) { // if (!file.isDirectory()) {
// return false; // return false;
// } // }
if (file.getAbsolutePath().equalsIgnoreCase("/")) { if (file.getAbsolutePath().equalsIgnoreCase("/")) {
return hint; throw new BaseException(hint);
} }
if (file.getAbsolutePath().equalsIgnoreCase("/root")) { if (file.getAbsolutePath().equalsIgnoreCase("/root")) {
return hint; throw new BaseException(hint);
} }
if (file.getAbsolutePath().equalsIgnoreCase("/usr") || file.getAbsolutePath().equalsIgnoreCase("/opt") if (file.getAbsolutePath().equalsIgnoreCase("/usr") || file.getAbsolutePath().equalsIgnoreCase("/opt")
|| file.getAbsolutePath().equalsIgnoreCase("/bin") || file.getAbsolutePath().equalsIgnoreCase("/sbin") || file.getAbsolutePath().equalsIgnoreCase("/bin") || file.getAbsolutePath().equalsIgnoreCase("/sbin")
|| file.getAbsolutePath().equalsIgnoreCase("/etc") || file.getAbsolutePath().equalsIgnoreCase("/selinux") || file.getAbsolutePath().equalsIgnoreCase("/etc") || file.getAbsolutePath().equalsIgnoreCase("/selinux")
|| file.getAbsolutePath().equalsIgnoreCase("/sys") || file.getAbsolutePath().equalsIgnoreCase("/var") || file.getAbsolutePath().equalsIgnoreCase("/sys") || file.getAbsolutePath().equalsIgnoreCase("/var")
|| file.getAbsolutePath().equalsIgnoreCase("/home") || file.getAbsolutePath().equalsIgnoreCase("/net")) { || file.getAbsolutePath().equalsIgnoreCase("/home") || file.getAbsolutePath().equalsIgnoreCase("/net")) {
return hint; throw new BaseException(hint);
} }
if (file.getAbsolutePath().equalsIgnoreCase("C://") || file.getAbsolutePath().equalsIgnoreCase("C:\\\\")) { if (file.getAbsolutePath().equalsIgnoreCase("C://") || file.getAbsolutePath().equalsIgnoreCase("C:\\\\")) {
return hint; throw new BaseException(hint);
}
String[] tempList = file.list();
File temp;
if (tempList == null) {
return;
}
for (String aTempList : tempList) {
if (path.endsWith(File.separator)) {
temp = new File(path + aTempList);
} else {
temp = new File(path + File.separator + aTempList);
}
if (temp.isFile()) {
temp.delete();
}
if (temp.isDirectory()) {
delAllFile(path + "/" + aTempList);// 删除里面的所有文件
delFolder(path + "/" + aTempList);// 删除空文件夹
}
} }
return "";
} }
...@@ -292,12 +317,12 @@ public class FileUtils ...@@ -292,12 +317,12 @@ public class FileUtils
/** /**
* 下载文件 * 下载文件
*
* @param url 要下载的文件链接 * @param url 要下载的文件链接
* @param targetFolder 目标文件 * @param targetFolder 目标文件
* @return
* @throws IOException * @throws IOException
*/ */
public static void downloadFolder(String url, String targetFolder) throws IOException { public static boolean downloadFolder(String url, String targetFolder) throws IOException {
URL downloadUrl = new URL(url); URL downloadUrl = new URL(url);
HttpURLConnection connection = (HttpURLConnection) downloadUrl.openConnection(); HttpURLConnection connection = (HttpURLConnection) downloadUrl.openConnection();
connection.setRequestMethod("GET"); connection.setRequestMethod("GET");
...@@ -330,6 +355,52 @@ public class FileUtils ...@@ -330,6 +355,52 @@ public class FileUtils
} }
} }
} }
return true;
}
/**
* 上传文件
* @param url 上传链接
* @param folderPath 文件路径
* @return
* @throws IOException
*/
public static boolean uploadFolder(String url, String folderPath) throws IOException {
File folder = new File(folderPath);
if (!folder.exists() || !folder.isDirectory()) {
throw new IllegalArgumentException("文件夹路径无效: " + folderPath);
}
List<File> files = new ArrayList<>();
listFiles(folder, files);
try (CloseableHttpClient httpClient = HttpClients.createDefault()) {
HttpPost httpPost = new HttpPost(url);
MultipartEntityBuilder builder = MultipartEntityBuilder.create();
for (File file : files) {
FileBody fileBody = new FileBody(file, ContentType.DEFAULT_BINARY);
builder.addPart("file", fileBody);
}
HttpEntity multipart = builder.build();
httpPost.setEntity(multipart);
HttpResponse response = httpClient.execute(httpPost);
int statusCode = response.getStatusLine().getStatusCode();
if (statusCode != 200) {
throw new RuntimeException("上传文件夹失败: " + response.getStatusLine().getReasonPhrase());
}
}
return true;
}
private static void listFiles(File folder, List<File> files) {
File[] subFiles = folder.listFiles();
for (File subFile : subFiles) {
if (subFile.isDirectory()) {
listFiles(subFile, files);
} else {
files.add(subFile);
}
}
} }
......
...@@ -64,7 +64,7 @@ public class SysLoginService ...@@ -64,7 +64,7 @@ public class SysLoginService
public String login(String username, String password, String code, String uuid) public String login(String username, String password, String code, String uuid)
{ {
// 验证码校验 // 验证码校验
// validateCaptcha(username, code, uuid); validateCaptcha(username, code, uuid);
// 登录前置校验 // 登录前置校验
loginPreCheck(username, password); loginPreCheck(username, password);
// 用户验证 // 用户验证
......
...@@ -32,3 +32,11 @@ export function urbanInvestmentPage(data) { ...@@ -32,3 +32,11 @@ export function urbanInvestmentPage(data) {
data data
}) })
} }
// 同地区城投-查询选项
export function uipGroupData(data) {
return request({
url: '/enterprise/uipGroupData',
method: 'post',
data
})
}
...@@ -158,3 +158,28 @@ export function addXGQY(param) { ...@@ -158,3 +158,28 @@ export function addXGQY(param) {
data:param data:param
}) })
} }
//删除相关企业
export function delXGQY(param) {
return request({
url: '/business/company/remove/'+param,
method: 'DELETE',
})
}
//查询资料文档
export function getZLWD(param) {
return request({
url: '/business/file/list',
method: 'GET',
params:param
})
}
//删除资料文档
export function delZLWD(param) {
return request({
url: '/business/file/remove',
method: 'POST',
data:param
})
}
...@@ -656,6 +656,7 @@ ...@@ -656,6 +656,7 @@
background: #F6F9FD; background: #F6F9FD;
border-radius: 6px; border-radius: 6px;
padding: 24px; padding: 24px;
border: 1px solid #F6F9FD;
//box-sizing: content-box; //box-sizing: content-box;
box-sizing: border-box; box-sizing: border-box;
>div{ >div{
...@@ -676,7 +677,6 @@ ...@@ -676,7 +677,6 @@
} }
} }
.rec_detail:hover{ .rec_detail:hover{
.operate{ .operate{
display: block; display: block;
......
...@@ -173,7 +173,7 @@ ...@@ -173,7 +173,7 @@
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="bottems" v-if="tableData.total>0"> <div class="bottems" v-if="tableData.total>searchParam.pageSize">
<el-pagination <el-pagination
background background
:page-size="searchParam.pageSize" :page-size="searchParam.pageSize"
......
...@@ -99,7 +99,7 @@ ...@@ -99,7 +99,7 @@
<div class="trendcon">{{item.text}}</div> <div class="trendcon">{{item.text}}</div>
<div class="time">{{item.time}}</div> <div class="time">{{item.time}}</div>
</div> </div>
<div class="tables" style="width: 100%"> <div class="tables" style="width: 100%" v-if="datalist.length>10">
<div class="bottems"> <div class="bottems">
<el-pagination <el-pagination
background background
...@@ -236,7 +236,7 @@ export default { ...@@ -236,7 +236,7 @@ export default {
{ {
name: '', name: '',
type: 'bar', type: 'bar',
barWidth: '20%', barWidth: '12px',
data: [100, 152, 200, 334, 390, 330, 220,256,178], data: [100, 152, 200, 334, 390, 330, 220,256,178],
itemStyle:{ itemStyle:{
normal: { normal: {
...@@ -280,7 +280,7 @@ export default { ...@@ -280,7 +280,7 @@ export default {
{ {
name: '', name: '',
type: 'bar', type: 'bar',
barWidth: '20%', barWidth: '12px',
data: [110, 112, 190, 234, 310, 350, 220,276,198], data: [110, 112, 190, 234, 310, 350, 220,276,198],
itemStyle:{ itemStyle:{
normal:{ normal:{
...@@ -551,6 +551,12 @@ export default { ...@@ -551,6 +551,12 @@ export default {
line-height: 18px; line-height: 18px;
padding-bottom: 16px; padding-bottom: 16px;
} }
&:last-child{
.trendcon{
border: none;
}
}
.time{ .time{
position: absolute; position: absolute;
right: 16px; right: 16px;
......
...@@ -8,6 +8,7 @@ ...@@ -8,6 +8,7 @@
border border
fit fit
highlight-current-row highlight-current-row
:default-sort = 'defaultSort'
@sort-change="sortChange" @sort-change="sortChange"
> >
<el-table-column <el-table-column
...@@ -27,7 +28,7 @@ ...@@ -27,7 +28,7 @@
:min-width="item.minWidth" :min-width="item.minWidth"
:align="item.align?item.align:'left'" :align="item.align?item.align:'left'"
:fixed="item.fixed" :fixed="item.fixed"
:sortable="item.sortable" :sortable="item.sortable ? 'custom' : false"
:resizable="false"> :resizable="false">
<template v-if="item.slotHeader" slot="header"> <template v-if="item.slotHeader" slot="header">
<slot :name="item.slotName"></slot> <slot :name="item.slotName"></slot>
...@@ -65,6 +66,10 @@ export default { ...@@ -65,6 +66,10 @@ export default {
type: Boolean, type: Boolean,
default: false default: false
}, },
defaultSort: {
type: Object,
default: null
},
tableData: { tableData: {
type: Array, type: Array,
default: [] default: []
...@@ -109,4 +114,7 @@ export default { ...@@ -109,4 +114,7 @@ export default {
::v-deep .el-table__body tr.current-row > td.el-table__cell{ ::v-deep .el-table__body tr.current-row > td.el-table__cell{
background-color: #ffffff; background-color: #ffffff;
} }
::v-deep .el-table__fixed{
height: calc(100% - 16px) !important;
}
</style> </style>
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<tables <tables
:indexFixed="true" :indexFixed="true"
:defaultSort="defaultSort"
:tableLoading="tableLoading" :tableLoading="tableLoading"
:tableData="tableData" :tableData="tableData"
:forData="forData" :forData="forData"
...@@ -56,10 +57,11 @@ export default { ...@@ -56,10 +57,11 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10 pageSize: 10
}, },
defaultSort: {prop: 'issueTime', order: 'descending'},
forData: [ forData: [
{label: '招标代理单位名称', prop: 'agency', minWidth: '350', slot: true}, {label: '招标代理单位名称', prop: 'agency', minWidth: '350', slot: true},
{label: '合作项目/工程名称', prop: 'projectInfo', minWidth: '400', sortable: 'custom', slot: true}, {label: '合作项目/工程名称', prop: 'projectInfo', minWidth: '400', slot: true, sortable: 'custom', descending: '5', ascending: '6'},
{label: '最近一次合作时间', prop: 'issueTime', minWidth: '140', sortable: 'custom'} {label: '最近一次合作时间', prop: 'issueTime', minWidth: '140', sortable: 'custom', descending: '3', ascending: '4'}
], ],
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []},
......
...@@ -73,7 +73,7 @@ export default { ...@@ -73,7 +73,7 @@ export default {
pageSize: 10 pageSize: 10
}, },
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入合作项目/工程名称查询', options: []},
], ],
forData: [ forData: [
{label: '合作项目/工程名称', prop: 'dealTitle', width: '720', slot: true}, {label: '合作项目/工程名称', prop: 'dealTitle', width: '720', slot: true},
......
...@@ -79,10 +79,10 @@ export default { ...@@ -79,10 +79,10 @@ export default {
pageSize: 10 pageSize: 10
}, },
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入项目/工程名称查询', options: []},
], ],
forData: [ forData: [
{label: '合作项目/工程名称', prop: 'projectAllName', width: '720', slot: true}, {label: '合作项目/工程名称', prop: 'projectAllName', width: '720', fixed: true, slot: true},
{label: '项目/工程金额(万元)', prop: 'winBidAmount', width: '160'}, {label: '项目/工程金额(万元)', prop: 'winBidAmount', width: '160'},
{label: '合作时间', prop: 'winBidTime', width: '100'}, {label: '合作时间', prop: 'winBidTime', width: '100'},
{label: '项目地区', prop: 'province', width: '160', slot: true}, {label: '项目地区', prop: 'province', width: '160', slot: true},
......
...@@ -79,10 +79,10 @@ export default { ...@@ -79,10 +79,10 @@ export default {
pageSize: 10 pageSize: 10
}, },
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入合作项目/工程名称查询', options: []},
], ],
forData: [ forData: [
{label: '合作项目/工程名称', prop: 'projectAllName', width: '720', slot: true}, {label: '合作项目/工程名称', prop: 'projectAllName', width: '720', fixed: true, slot: true},
{label: '项目/工程金额(万元)', prop: 'winBidAmount', width: '160'}, {label: '项目/工程金额(万元)', prop: 'winBidAmount', width: '160'},
{label: '合作时间', prop: 'winBidTime', width: '100'}, {label: '合作时间', prop: 'winBidTime', width: '100'},
{label: '项目地区', prop: 'province', width: '160', slot: true}, {label: '项目地区', prop: 'province', width: '160', slot: true},
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<tables <tables
:indexFixed="true" :indexFixed="true"
:defaultSort="defaultSort"
:tableLoading="tableLoading" :tableLoading="tableLoading"
:tableData="tableData" :tableData="tableData"
:forData="forData" :forData="forData"
...@@ -57,11 +58,12 @@ export default { ...@@ -57,11 +58,12 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10 pageSize: 10
}, },
defaultSort: {prop: 'time', order: 'descending'},
forData: [ forData: [
{label: '客户名称', prop: 'companyName', minWidth: '350', slot: true}, {label: '客户名称', prop: 'companyName', minWidth: '350', slot: true},
{label: '合作项目/工程名称', prop: 'projectAllName', minWidth: '400', sortable: 'custom', slot: true}, {label: '合作项目/工程名称', prop: 'projectAllName', minWidth: '400', slot: true, sortable: 'custom', descending: '5', ascending: '6'},
{label: '合作总金额(万元)', prop: 'amount', minWidth: '150', sortable: 'custom'}, {label: '合作总金额(万元)', prop: 'amount', minWidth: '150', sortable: 'custom', descending: '1', ascending: '2'},
{label: '最近一次合作时间', prop: 'time', minWidth: '140', sortable: 'custom'} {label: '最近一次合作时间', prop: 'time', minWidth: '140', sortable: 'custom', descending: '3', ascending: '4'}
], ],
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []},
...@@ -90,32 +92,6 @@ export default { ...@@ -90,32 +92,6 @@ export default {
} }
this.tableDataTotal = res.total this.tableDataTotal = res.total
}, },
//排序-测试
sortChange(e){
this.tableData = []
let sortRule = e.prop+','+e.order
switch (sortRule){
case 'amount,descending':
this.queryParams.sort = 1
break
case 'amount,ascending':
this.queryParams.sort = 2
break
case 'time,descending':
this.queryParams.sort = 3
break
case 'time,ascending':
this.queryParams.sort = 4
break
case 'projectAllName,descending':
this.queryParams.sort = 5
break
case 'projectAllName,ascending':
this.queryParams.sort = 6
break
}
this.handleSearch()
},
handleClick(e, data) { handleClick(e, data) {
this.rowData = data this.rowData = data
this.isDetails = true this.isDetails = true
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<tables <tables
:indexFixed="true" :indexFixed="true"
:defaultSort="defaultSort"
:tableLoading="tableLoading" :tableLoading="tableLoading"
:tableData="tableData" :tableData="tableData"
:forData="forData" :forData="forData"
...@@ -20,8 +21,8 @@ ...@@ -20,8 +21,8 @@
@sort-change="sortChange" @sort-change="sortChange"
> >
<template slot="projectAllName" slot-scope="scope"> <template slot="projectAllName" slot-scope="scope">
<router-link to="" tag="a" class="a-link" v-if="scope.row.id&&scope.row.projectAllName ">{{ scope.row.projectAllName }}</router-link> <router-link to="" tag="a" class="a-link" v-if="scope.row.id&&scope.row.projectAllName " v-html="scope.row.projectAllName"></router-link>
<div v-else>{{ scope.row.projectAllName || '--' }}</div> <div v-else v-html="scope.row.projectAllName || '--'"></div>
</template> </template>
<template slot="companyName" slot-scope="scope"> <template slot="companyName" slot-scope="scope">
<router-link to="" tag="a" class="a-link" v-if="scope.row.companyId&&scope.row.companyName">{{ scope.row.companyName }}</router-link> <router-link to="" tag="a" class="a-link" v-if="scope.row.companyId&&scope.row.companyName">{{ scope.row.companyName }}</router-link>
...@@ -49,22 +50,23 @@ export default { ...@@ -49,22 +50,23 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10 pageSize: 10
}, },
defaultSort: {prop: 'winBidTime', order: 'descending'},
forData: [ forData: [
{label: '项目名称', prop: 'projectAllName', minWidth: '560', slot: true}, {label: '项目名称', prop: 'projectAllName', minWidth: '560', slot: true},
{label: '中标时间', prop: 'winBidTime', minWidth: '100', sortable: 'custom'}, {label: '中标时间', prop: 'winBidTime', minWidth: '100', sortable: 'custom', descending: '3', ascending: '4'},
{label: '中标企业', prop: 'companyName', minWidth: '320', slot: true}, {label: '中标企业', prop: 'companyName', minWidth: '320', slot: true},
{label: '中标金额(万元)', prop: 'winBidAmount', minWidth: '140', sortable: 'custom'}, {label: '中标金额(万元)', prop: 'winBidAmount', minWidth: '140', sortable: 'custom', descending: '1', ascending: '2'},
{label: '下浮率(%)', prop: 'lowerRate', minWidth: '120', sortable: 'custom'}, {label: '下浮率(%)', prop: 'lowerRate', minWidth: '120', sortable: 'custom', descending: '7', ascending: '8'},
{label: '项目经理 / 负责人', prop: 'staffName', minWidth: '130'}, {label: '项目经理 / 负责人', prop: 'staffName', minWidth: '130'},
{label: '中标地区', prop: 'region', minWidth: '160'}, {label: '中标地区', prop: 'region', minWidth: '160'},
{label: '工期(天)', prop: 'period', minWidth: '110', sortable: 'custom'}, {label: '工期(天)', prop: 'period', minWidth: '110', sortable: 'custom', descending: '9', ascending: '10'},
{label: '业绩类别', prop: 'boundType', minWidth: '110'} {label: '业绩类别', prop: 'boundType', minWidth: '110'}
], ],
formData: [ formData: [
{ type: 1, fieldName: 'provinceId', value: '', placeholder: '项目地区', options: [] }, { type: 1, fieldName: 'provinceId', value: '', placeholder: '项目地区', options: [] },
{ type: 5, fieldName: 'time', value: '', placeholder: '中标时间', startTime: 'dateFrom', endTime: 'dateTo' }, { type: 5, fieldName: 'time', value: '', placeholder: '中标时间', startTime: 'dateFrom', endTime: 'dateTo' },
{ type: 6, fieldName: 'money', value: '', placeholder: '中标金额', startMoney: 'amountMin', endMoney: 'amountMax' }, { type: 6, fieldName: 'money', value: '', placeholder: '中标金额', startMoney: 'amountMin', endMoney: 'amountMax' },
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入关键词查询', options: [] } { type: 3, fieldName: 'keys', value: '', placeholder: '输入项目名称查询', options: [] }
], ],
//列表 //列表
tableLoading:false, tableLoading:false,
......
...@@ -11,6 +11,7 @@ ...@@ -11,6 +11,7 @@
<tables <tables
:indexFixed="true" :indexFixed="true"
:defaultSort="defaultSort"
:tableLoading="tableLoading" :tableLoading="tableLoading"
:tableData="tableData" :tableData="tableData"
:forData="forData" :forData="forData"
...@@ -57,11 +58,12 @@ export default { ...@@ -57,11 +58,12 @@ export default {
pageNum: 1, pageNum: 1,
pageSize: 10 pageSize: 10
}, },
defaultSort: {prop: 'time', order: 'descending'},
forData: [ forData: [
{label: '供应商', prop: 'companyName', minWidth: '350', slot: true}, {label: '供应商', prop: 'companyName', minWidth: '350', slot: true},
{label: '合作项目/工程名称', prop: 'projectAllName', minWidth: '400', sortable: 'custom', slot: true}, {label: '合作项目/工程名称', prop: 'projectAllName', minWidth: '400', slot: true, sortable: 'custom', descending: '5', ascending: '6'},
{label: '合作总金额(万元)', prop: 'amount', minWidth: '150', sortable: 'custom'}, {label: '合作总金额(万元)', prop: 'amount', minWidth: '150', sortable: 'custom', descending: '1', ascending: '2'},
{label: '最近一次合作时间', prop: 'time', minWidth: '140', sortable: 'custom'} {label: '最近一次合作时间', prop: 'time', minWidth: '140', sortable: 'custom', descending: '3', ascending: '4'}
], ],
formData: [ formData: [
{ type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []}, { type: 3, fieldName: 'keys', value: '', placeholder: '输入企业名称查询', options: []},
......
...@@ -70,7 +70,9 @@ export default { ...@@ -70,7 +70,9 @@ export default {
}, },
//排序 //排序
sortChange(e){ sortChange(e){
console.log(e) let item = this.forData.find(item => item.prop === e.prop)
this.queryParams.sort = item[e.order]
this.handleSearch()
} }
} }
} }
...@@ -60,8 +60,6 @@ export default { ...@@ -60,8 +60,6 @@ export default {
//列表 //列表
tableLoading:false, tableLoading:false,
tableData:[], tableData:[],
pageIndex:1,
pageSize:10,
tableDataTotal:0, tableDataTotal:0,
} }
}, },
......
...@@ -75,8 +75,6 @@ export default { ...@@ -75,8 +75,6 @@ export default {
//列表 //列表
tableLoading:false, tableLoading:false,
tableData:[], tableData:[],
pageIndex:1,
pageSize:10,
tableDataTotal:0, tableDataTotal:0,
} }
}, },
......
...@@ -4,6 +4,7 @@ ...@@ -4,6 +4,7 @@
<div class="flex-box query-params"> <div class="flex-box query-params">
<span class="common-title">区域经济</span> <span class="common-title">区域经济</span>
</div> </div>
<div class="params-dw"><img src="@/assets/images/addree.png" />广东省-广州市</div>
</div> </div>
<div class="table-item"> <div class="table-item">
<el-table <el-table
...@@ -253,6 +254,16 @@ export default { ...@@ -253,6 +254,16 @@ export default {
} }
.query-box{ .query-box{
margin: 10px 0 20px; margin: 10px 0 20px;
.params-dw{
font-size: 14px;
font-weight: 400;
color: #0081FF;
img{
width: 14px;
height: 14px;
margin-right: 5px;
}
}
} }
} }
......
...@@ -323,8 +323,8 @@ export default { ...@@ -323,8 +323,8 @@ export default {
// trigger: 'axis' // trigger: 'axis'
}, },
legend: { legend: {
right: '151px', left: '12px',
top:"0px", top:"15px",
data: ['成交金额', '储备项目', '跟进动态'] data: ['成交金额', '储备项目', '跟进动态']
}, },
series: [ series: [
...@@ -513,12 +513,12 @@ export default { ...@@ -513,12 +513,12 @@ export default {
} }
} }
.chart-bot{ .chart-bot{
height: 354px; height: auto;
margin-bottom: 12px; margin-bottom: 12px;
.left{ .left{
float: left; float: left;
width: 353px; width: 353px;
height: 100%; height: 354px;
background: url("../../../assets/images/project/glbj.png")no-repeat top center; background: url("../../../assets/images/project/glbj.png")no-repeat top center;
background-size: 100% 100%; background-size: 100% 100%;
color: #FFFFFF; color: #FFFFFF;
...@@ -569,11 +569,11 @@ export default { ...@@ -569,11 +569,11 @@ export default {
} }
.right{ .right{
float: right; float: right;
height: 100%; height: auto;
width: calc(100% - 369px); width: calc(100% - 369px);
.records{ .records{
margin-top: -17px; margin-top: -17px;
height: 327px; height: 627px;
overflow-y: auto; overflow-y: auto;
width: 100%; width: 100%;
padding-right: 47px; padding-right: 47px;
...@@ -621,6 +621,7 @@ export default { ...@@ -621,6 +621,7 @@ export default {
.chart2{ .chart2{
width: 100%; width: 100%;
padding: 0 0 0 16px;
height: 285px; height: 285px;
margin-top: -20px; margin-top: -20px;
} }
......
...@@ -34,7 +34,7 @@ ...@@ -34,7 +34,7 @@
<el-option v-for="(item,index) in projectCategory" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option> <el-option v-for="(item,index) in projectCategory" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="投资估算:" class="row"> <el-form-item label="投资估算(万元):" class="row">
<el-input type="text" placeholder="请输入金额" @input="number" v-model="queryParam.investmentAmount"></el-input> <el-input type="text" placeholder="请输入金额" @input="number" v-model="queryParam.investmentAmount"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="可见范围:" class="row"> <el-form-item label="可见范围:" class="row">
......
...@@ -4,20 +4,18 @@ ...@@ -4,20 +4,18 @@
<el-card class="box-card noborder"> <el-card class="box-card noborder">
<div class="cardtitles">相关企业</div> <div class="cardtitles">相关企业</div>
<div class="searchbtns"> <div class="searchbtns">
<el-select class="select" placeholder="企业类型"> <el-select class="select" placeholder="企业类型" v-model="searchParam.companyType" @change="handleCurrentChange(1)">
<el-select placeholder="请选择">
<el-option v-for="(item,index) in companytype" :label="item.dictLabel" :value="item.dictValue"></el-option> <el-option v-for="(item,index) in companytype" :label="item.dictLabel" :value="item.dictValue"></el-option>
</el-select> </el-select>
</el-select>
<div class="searchInput"> <div class="searchInput">
<el-input type="text" placeholder="输入关键词查询"></el-input> <el-input type="text" placeholder="输入关键词查询" v-model="searchParam.companyName"></el-input>
<div class="btn">搜索</div> <div class="btn" @click="handleCurrentChange(1)">搜索</div>
</div> </div>
<div class="btn btn_primary h32 b3" @click="opennew"><div class="img img1"></div>添加相关企业</div> <div class="btn btn_primary h32 b3" @click="opennew"><div class="img img1"></div>添加相关企业</div>
</div> </div>
<div class="document"> <div class="document tables">
<el-table <el-table
:data="tableData" :data="tableData.rows"
style="width: 100%" style="width: 100%"
> >
<template slot="empty"> <template slot="empty">
...@@ -29,26 +27,26 @@ ...@@ -29,26 +27,26 @@
</div> </div>
</template> </template>
<el-table-column <el-table-column
prop="date" prop="companyName"
label="企业名称" label="企业名称"
> >
<template slot-scope="scope"> <template slot-scope="scope">
<div class="wordprimary">集团投标常用资料</div> <div class="wordprimary">{{scope.row.companyName}}</div>
</template> </template>
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="name" prop="depth"
label="对接深度" label="对接深度/竞争力度"
> >
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="name" prop="companyRole"
label="企业角色" label="企业角色"
sortable sortable
width=""> width="">
</el-table-column> </el-table-column>
<el-table-column <el-table-column
prop="name" prop="responsiblePerson"
label="负责人" label="负责人"
width=""> width="">
</el-table-column> </el-table-column>
...@@ -59,21 +57,27 @@ ...@@ -59,21 +57,27 @@
width=""> width="">
<template slot-scope="scope"> <template slot-scope="scope">
<div class="hoverbtn"> <div class="hoverbtn">
<div class="sc">删除</div> <div class="sc" @click="ondel = scope.row.id">删除</div>
</div> </div>
</template> </template>
</el-table-column> </el-table-column>
</el-table> </el-table>
<div class="delform" v-if="ondel != -1">
<div class="tables"> <div class="words">是否将企业删除</div>
<div class="bottems"> <div>
<div class="btnsmall btn_primary h28" @click="delQY()">确定</div>
<div class="btnsmall btn_cancel h28" @click="ondel = -1">取消</div>
</div>
</div>
<div class="tables" v-if="tableData.total > searchParam.pageSize">
<div class="bottems" v-if="ondel != -1">
<el-pagination <el-pagination
background background
:page-size="20" :page-size="searchParam.pageSize"
:current-page="1" :current-page="searchParam.pageNum"
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
layout="prev, pager, next" layout="prev, pager, next"
:total="1000"> :total="tableData.total">
</el-pagination> </el-pagination>
</div> </div>
</div> </div>
...@@ -87,12 +91,12 @@ ...@@ -87,12 +91,12 @@
<span>新建相关企业</span> <span>新建相关企业</span>
</div> </div>
<div class="types"> <div class="types">
<div v-for="(item,index) in companytype" :class="{'on':types==item.dictValue}" @click="types=item.dictLabel"><i></i>{{item.dictLabel}}</div> <div v-for="(item,index) in companytype" :class="{'on':types==item.dictValue}" @click="totype(item.dictValue)"><i></i>{{item.dictLabel}}</div>
</div> </div>
<div class="popform"> <div class="popform">
<div class="popbot" style="padding-right: 0"> <div class="popbot" style="padding-right: 0">
<div class="btn btn_cancel h32" @click="cancel">返回</div> <div class="btn btn_cancel h32" @click="cancel(0)">返回</div>
<div class="btn btn_primary h32" @click="hzhbVisible=true">下一步</div> <div class="btn btn_primary h32" @click="gettype">下一步</div>
</div> </div>
</div> </div>
</el-dialog> </el-dialog>
...@@ -105,29 +109,23 @@ ...@@ -105,29 +109,23 @@
<span>新建相关企业-{{types}}</span> <span>新建相关企业-{{types}}</span>
</div> </div>
<el-form class="popform i" label-width="85px" :rules="rules" ref="ruleForm" > <el-form class="popform i" label-width="85px" :rules="rules" ref="ruleForm" >
<el-form-item label="企业名称:" prop="projectName" class="row"> <el-form-item label="企业名称:" prop="companyName" class="row">
<el-input type="text" placeholder="请输入"></el-input> <el-input type="text" v-model="queryParam.companyName" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item v-if="types == companytype[0].dictValue" label="对接深度:" class="row">
<el-input type="text" placeholder="请输入"></el-input>
</el-form-item> </el-form-item>
<el-form-item v-if="types == companytype[1].dictValue" label="合作阶段:" class="row"> <el-form-item :label="typename" class="row">
<el-input type="text" placeholder="请输入"></el-input> <el-input type="text" v-model="queryParam.depth" placeholder="请输入"></el-input>
</el-form-item>
<el-form-item v-if="types == companytype[2].dictValue" label="竞争力度:" class="row">
<el-input type="text" placeholder="请输入"></el-input>
</el-form-item> </el-form-item>
<el-form-item label="企业角色:" class="row"> <el-form-item label="企业角色:" class="row">
<el-select placeholder="请选择"> <el-select placeholder="请选择" v-model="queryParam.companyRole">
<el-option v-for="(item,index) in companyrole" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option> <el-option v-for="(item,index) in companyrole" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option>
</el-select> </el-select>
</el-form-item> </el-form-item>
<el-form-item label="负责人:" class="row"> <el-form-item label="负责人:" class="row">
<el-input type="text" placeholder="请输入"></el-input> <el-input type="text" v-model="queryParam.responsiblePerson" placeholder="请输入"></el-input>
</el-form-item> </el-form-item>
<div class="popbot"> <div class="popbot">
<div class="btn btn_cancel h32" @click="cancel">返回</div> <div class="btn btn_cancel h32" @click="cancel(1)">返回</div>
<div class="btn btn_primary h32">添加</div> <div class="btn btn_primary h32" @click="addqy">添加</div>
</div> </div>
</el-form> </el-form>
</el-dialog> </el-dialog>
...@@ -137,7 +135,7 @@ ...@@ -137,7 +135,7 @@
<script> <script>
import "@/assets/styles/project.scss" import "@/assets/styles/project.scss"
import {getXGQY,addXGQY} from '@/api/project/project' import {getXGQY,addXGQY,delXGQY} from '@/api/project/project'
import {getDictType} from '@/api/main' import {getDictType} from '@/api/main'
export default { export default {
name: 'xgqy', name: 'xgqy',
...@@ -169,12 +167,30 @@ ...@@ -169,12 +167,30 @@
address: '上海市普陀区金沙江路 1516 弄' address: '上海市普陀区金沙江路 1516 弄'
} }
], ],
typelist:['对接深度:','合作阶段:','竞争力度:'],
typename:"",
rules:{ rules:{
projectName:[{ required: true, message: '请输入非空格字符!', trigger: 'blur' },], companyName:[{ required: true, message: '请输入非空格字符!', trigger: 'blur' },],
}, },
companytype:[], companytype:[],
companyrole:[], companyrole:[],
queryParam:{
businessId:this.$route.query.id,
companyId:'',
companyName:'',
companyRole:'',
companyType:'',
responsiblePerson:'',
depth:'',
},
searchParam:{
pageSize:20,
pageNum:1,
businessId:this.$route.query.id,
companyType:"",
companyName:'',
},
ondel:-1,
} }
}, },
created(){ created(){
...@@ -187,18 +203,70 @@ ...@@ -187,18 +203,70 @@
getDictType('company_role').then(result=>{ getDictType('company_role').then(result=>{
this.companyrole = result.code == 200 ? result.data:[] this.companyrole = result.code == 200 ? result.data:[]
}) })
this.getlist()
}, },
methods:{ methods:{
delQY(){
let id = this.ondel
delXGQY(id).then(res=>{
if(res.code == 200){
this.$message.success('删除成功')
this.ondel = -1
this.getlist()
}
})
},
addqy(){
addXGQY(this.queryParam).then(res=>{
if(res.code == 200){
this.$message.success('添加成功!')
this.getlist()
}else {
this.$message.error(res.msg)
}
})
},
getlist(){
getXGQY(this.searchParam).then(result=>{
console.log(result)
this.tableData = result
})
},
//翻页 //翻页
handleCurrentChange(val) { handleCurrentChange(val) {
console.log(`当前页: ${val}`); this.searchParam.pageNum = val
this.getlist()
}, },
cancel(){ cancel(type){
if(type == 0)
this.dialogVisible = false this.dialogVisible = false
else
this.hzhbVisible = false
},
totype(value){
this.types = value
},
gettype(){
this.queryParam.companyType = this.types
this.companytype.forEach((item,index)=>{
if(item.dictValue == this.types){
this.typename = this.typelist[index]
}
})
this.hzhbVisible=true
}, },
//打开新建窗口 //打开新建窗口
opennew(){ opennew(){
this.dialogVisible = true this.dialogVisible = true
this.queryParam={
businessId:this.$route.query.id,
companyId:'',
companyName:'',
companyRole:'',
companyType:'',
responsiblePerson:'',
depth:'',
}
}, },
} }
} }
...@@ -220,4 +288,8 @@ ...@@ -220,4 +288,8 @@
.box-card{ .box-card{
position: relative; position: relative;
} }
.delform{
position: fixed; left:50%; top:50%; transform:translate(-50%,-50%)
}
</style> </style>
...@@ -26,7 +26,7 @@ ...@@ -26,7 +26,7 @@
{{xmjd}} {{xmjd}}
<i class="el-icon-caret-bottom"></i> <i class="el-icon-caret-bottom"></i>
</span> </span>
<el-select v-model="xmjd" class="select-multiple" placeholder="请选择" @click="editXMSL({projectStage:xmjd})"> <el-select v-model="xmjd" class="select-multiple" placeholder="请选择" @change="editXMSL({projectStage:xmjd})">
<el-option v-for="(item,index) in projectStage" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option> <el-option v-for="(item,index) in projectStage" :key="index" :label="item.dictLabel" :value="item.dictValue"></el-option>
</el-select> </el-select>
</div> </div>
......
...@@ -197,16 +197,22 @@ ...@@ -197,16 +197,22 @@
this.thisindex = result.data.projectStage this.thisindex = result.data.projectStage
let list = [] let list = []
let txt = '' let txt = ''
if(result.data.provinceId){ if(result.data.provinceId != ""){
list.push(result.data.provinceId) list.push(result.data.provinceId)
txt += result.data.provinceName
} }
if(result.data.cityId){ if(result.data.cityId){
list.push(result.data.cityId) list.push(result.data.cityId)
txt += '/'+result.data.cityName
} }
if(result.data.districtId){ if(result.data.districtId){
list.push(result.data.districtId) list.push(result.data.districtId)
}
if(result.data.provinceName){
txt += result.data.provinceName
}
if(result.data.cityName){
txt += '/'+result.data.cityName
}
if(result.data.districtName){
txt += '/'+result.data.districtName txt += '/'+result.data.districtName
} }
this.address = list.length>0?list:"待添加" this.address = list.length>0?list:"待添加"
...@@ -279,6 +285,14 @@ ...@@ -279,6 +285,14 @@
handleChange(value) { handleChange(value) {
var labelString = this.$refs.myCascader.getCheckedNodes()[0].pathLabels; var labelString = this.$refs.myCascader.getCheckedNodes()[0].pathLabels;
let param = {
provinceId:null,
provinceName:null,
cityId:null,
cityName:null,
districtId:null,
districtName:null,
}
let txt = '' let txt = ''
labelString.forEach((item,index)=>{ labelString.forEach((item,index)=>{
let str = '' let str = ''
...@@ -286,13 +300,17 @@ ...@@ -286,13 +300,17 @@
str = '/' str = '/'
} }
txt += str + item txt += str + item
if(index == 0){
param.provinceName = item
}
if(index == 1){
param.cityName = item
}
if(index == 2){
param.districtName = item
}
}) })
this.addresstxt = txt this.addresstxt = txt
let param = {
provinceId:null,
cityId:null,
districtId:null
}
value.forEach((item,index)=>{ value.forEach((item,index)=>{
if(index == 0){ if(index == 0){
param.provinceId = parseInt(item) param.provinceId = parseInt(item)
......
...@@ -113,7 +113,7 @@ ...@@ -113,7 +113,7 @@
</div> </div>
<div class="datalist"> <div class="datalist">
<div class="datali" v-for="(item,index) in datalist"> <div class="datali" v-for="(item,index) in datalist">
<div class="det-title" @click="toDetail(item.id)">{{item.projectName}}<span v-if="activeName!='first'" class="people"><i>A</i>四川-李丽 <font color="#FA8A00" v-if="activeName!='first'">正在跟进</font></span></div> <div class="det-title" @click="toDetail(item.id)">{{item.projectName}}<span v-if="activeName!='first'" class="people"><i>{{item.nickName1}}</i>{{item.nickName}} <font color="#FA8A00" v-if="activeName!='first'">正在跟进</font></span></div>
<div class="det-tips"><span class="tips tip1" v-if="item.label">{{item.label}}</span><span v-if="item.address" class="tips tip2">{{item.address}}</span></div> <div class="det-tips"><span class="tips tip1" v-if="item.label">{{item.label}}</span><span v-if="item.address" class="tips tip2">{{item.address}}</span></div>
<div class="det-contets"> <div class="det-contets">
<div class="det-con"> <div class="det-con">
...@@ -133,7 +133,7 @@ ...@@ -133,7 +133,7 @@
<span class="wordprimary">{{item.ownerCompany}}</span> <span class="wordprimary">{{item.ownerCompany}}</span>
</div> </div>
</div> </div>
<el-divider></el-divider> <el-divider v-if="index != datalist.length-1"></el-divider>
<div class="operates" v-if="activeName=='first'"> <div class="operates" v-if="activeName=='first'">
<div class="i1"><img src="@/assets/images/follow.png">跟进</div> <div class="i1"><img src="@/assets/images/follow.png">跟进</div>
<div class="i2"><img src="@/assets/images/edit.png">编辑</div> <div class="i2"><img src="@/assets/images/edit.png">编辑</div>
...@@ -294,6 +294,7 @@ export default { ...@@ -294,6 +294,7 @@ export default {
if(item.districtName != ""&& item.districtName != null) if(item.districtName != ""&& item.districtName != null)
str += '-' +item.districtName str += '-' +item.districtName
item.address = str item.address = str
item.nickName1 = item.nickName?item.nickName.slice(0,1):''
}) })
} }
}) })
......
...@@ -35,6 +35,8 @@ module.exports = { ...@@ -35,6 +35,8 @@ module.exports = {
// detail: https://cli.vuejs.org/config/#devserver-proxy // detail: https://cli.vuejs.org/config/#devserver-proxy
[process.env.VUE_APP_BASE_API]: { [process.env.VUE_APP_BASE_API]: {
target: `http://122.9.160.122:9011`, target: `http://122.9.160.122:9011`,
// target: `http://192.168.60.126:9011`,
// target: `http://192.168.60.27:8766`,
changeOrigin: true, changeOrigin: true,
pathRewrite: { pathRewrite: {
['^' + process.env.VUE_APP_BASE_API]: '' ['^' + process.env.VUE_APP_BASE_API]: ''
......
...@@ -19,4 +19,9 @@ public class BusinessIdDto { ...@@ -19,4 +19,9 @@ public class BusinessIdDto {
* 项目标签名称 * 项目标签名称
*/ */
private String label; private String label;
/**
* 文件路径
*/
private String folderPath;
} }
...@@ -120,15 +120,11 @@ public class EnterpriseProjectService { ...@@ -120,15 +120,11 @@ public class EnterpriseProjectService {
return BeanUtil.toBean(map, R.class); return BeanUtil.toBean(map, R.class);
} }
// HashMap<String, Object> contentParam = new HashMap<>(); HashMap<String, Object> contentParam = new HashMap<>();
// contentParam.put("data_type", "bid_plan"); contentParam.put("data_type", "bid_plan");
// contentParam.put("filter_type", 2); contentParam.put("filter_type", 2);
// contentParam.put("strategy_id", contentId); contentParam.put("strategy_id", contentId);
HashMap<String, Object> param = new HashMap<>(); Map<String, Object> contentMap = dskOpenApiUtil.requestBody("/mongocontent/v1/cjb/mongo_content", BeanUtil.beanToMap(contentParam, false, false));
param.put("data_type", "kaibiao");
param.put("filter_type", 2);
param.put("strategy_id", "647477d52ba0e4cb1410c7f6");
Map<String, Object> contentMap = dskOpenApiUtil.requestBody("/mongocontent/v1/cjb/mongo_content", BeanUtil.beanToMap(param, false, false));
Map contentData = MapUtils.getMap(contentMap, "data", null); Map contentData = MapUtils.getMap(contentMap, "data", null);
......
...@@ -169,6 +169,7 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService { ...@@ -169,6 +169,7 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService {
//新增项目主信息 //新增项目主信息
BusinessInfo businessInfo = new BusinessInfo(); BusinessInfo businessInfo = new BusinessInfo();
BeanUtil.copyProperties(dto, businessInfo); BeanUtil.copyProperties(dto, businessInfo);
businessInfo.setConstructionUnit(dto.getOwnerCompany());
int addBusiness = businessInfoMapper.insertBusinessInfo(businessInfo); int addBusiness = businessInfoMapper.insertBusinessInfo(businessInfo);
if (addBusiness > 0) { if (addBusiness > 0) {
//获取登陆用户的部门id //获取登陆用户的部门id
...@@ -176,9 +177,7 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService { ...@@ -176,9 +177,7 @@ public class BusinessInfoServiceImpl implements IBusinessInfoService {
// Long deptId = 100l; // Long deptId = 100l;
//新增用户-项目关系信息 //新增用户-项目关系信息
int addbusinessUser = businessUserMapper.insertBusinessUser(new BusinessUser(businessInfo.getId(), deptId.intValue(), dto.getUserId(), 1)); int addbusinessUser = businessUserMapper.insertBusinessUser(new BusinessUser(businessInfo.getId(), deptId.intValue(), dto.getUserId(), 1));
//新增项目-关联企业信息 return addbusinessUser > 0 ? AjaxResult.success() : AjaxResult.error();
int addRelateCompany = businessRelateCompanyMapper.insertBusinessRelateCompany(new BusinessRelateCompany(businessInfo.getId(), dto.getCompanyId(), dto.getOwnerCompany(), "业主"));
return addbusinessUser > 0 && addRelateCompany > 0 ? AjaxResult.success() : AjaxResult.error();
} }
return AjaxResult.error(); return AjaxResult.error();
......
...@@ -15,6 +15,7 @@ ...@@ -15,6 +15,7 @@
<result property="createTime" column="create_time"/> <result property="createTime" column="create_time"/>
<result property="updateTime" column="update_time"/> <result property="updateTime" column="update_time"/>
<result property="depth" column="depth"/> <result property="depth" column="depth"/>
<result property="companyType" column="company_type"/>
</resultMap> </resultMap>
<sql id="selectBusinessRelateCompanyVo"> <sql id="selectBusinessRelateCompanyVo">
...@@ -27,7 +28,8 @@ ...@@ -27,7 +28,8 @@
phone, phone,
depth, depth,
create_time, create_time,
update_time update_time,
company_type
from business_relate_company from business_relate_company
</sql> </sql>
...@@ -46,6 +48,7 @@ ...@@ -46,6 +48,7 @@
#{responsiblePerson} #{responsiblePerson}
</if> </if>
<if test="phone != null and phone != ''">and phone = #{phone}</if> <if test="phone != null and phone != ''">and phone = #{phone}</if>
<if test="companyType != null and companyType != ''">and company_type = #{companyType}</if>
</where> </where>
</select> </select>
...@@ -67,6 +70,7 @@ ...@@ -67,6 +70,7 @@
<if test="phone != null">phone,</if> <if test="phone != null">phone,</if>
<if test="createTime != null">create_time,</if> <if test="createTime != null">create_time,</if>
<if test="updateTime != null">update_time,</if> <if test="updateTime != null">update_time,</if>
<if test="companyType != null">company_type,</if>
</trim> </trim>
<trim prefix="values (" suffix=")" suffixOverrides=","> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="businessId != null">#{businessId},</if> <if test="businessId != null">#{businessId},</if>
...@@ -78,6 +82,7 @@ ...@@ -78,6 +82,7 @@
<if test="phone != null">#{phone},</if> <if test="phone != null">#{phone},</if>
<if test="createTime != null">#{createTime},</if> <if test="createTime != null">#{createTime},</if>
<if test="updateTime != null">#{updateTime},</if> <if test="updateTime != null">#{updateTime},</if>
<if test="companyType != null">#{companyType},</if>
</trim> </trim>
</insert> </insert>
...@@ -93,6 +98,7 @@ ...@@ -93,6 +98,7 @@
<if test="phone != null">phone = #{phone},</if> <if test="phone != null">phone = #{phone},</if>
<if test="createTime != null">create_time = #{createTime},</if> <if test="createTime != null">create_time = #{createTime},</if>
<if test="updateTime != null">update_time = #{updateTime},</if> <if test="updateTime != null">update_time = #{updateTime},</if>
<if test="companyType != null">company_type = #{companyType},</if>
</trim> </trim>
where id = #{id} where id = #{id}
</update> </update>
......
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