资格预审功能开发
This commit is contained in:
parent
e0fbba9ebd
commit
bbcace7422
|
@ -1,5 +1,5 @@
|
|||
#for tests only !
|
||||
#Mon Jul 22 13:35:56 CST 2024
|
||||
#Mon Jul 22 15:09:50 CST 2024
|
||||
jco.destination.pool_capacity=10
|
||||
jco.client.lang=ZH
|
||||
jco.client.ashost=172.19.0.125
|
||||
|
@ -7,5 +7,5 @@ jco.client.saprouter=
|
|||
jco.client.user=RFC
|
||||
jco.client.sysnr=00
|
||||
jco.destination.peak_limit=10
|
||||
jco.client.passwd=d5-l}25LC/syTMZBj},zzcOyD{}`D$_}M#F{]EU?5=[as!f`
|
||||
jco.client.passwd=654321
|
||||
jco.client.client=800
|
||||
|
|
|
@ -348,6 +348,16 @@ public class BidController extends BaseController
|
|||
@DeleteMapping("/{bidIds}")
|
||||
public AjaxResult remove(@PathVariable String[] bidIds)
|
||||
{
|
||||
for(String bidId:bidIds){
|
||||
Bid bid = bidService.selectBidByBidId(bidId);
|
||||
if("1".equals(bid.getBidApprovalStatus())){
|
||||
return error("投标信息:"+bid.getBidCode()+" 已提交,无法删除");
|
||||
}else if("2".equals(bid.getBidApprovalStatus())){
|
||||
return error("投标信息:"+bid.getBidCode()+" 已完成,无法删除");
|
||||
}else if("3".equals(bid.getBidApprovalStatus())){
|
||||
return error("投标信息:"+bid.getBidCode()+" 已被驳回,无法删除");
|
||||
}
|
||||
}
|
||||
return toAjax(bidService.deleteBidByBidIds(bidIds));
|
||||
}
|
||||
|
||||
|
|
|
@ -869,6 +869,18 @@ public class QuotController extends BaseController
|
|||
return success();
|
||||
}
|
||||
|
||||
/**
|
||||
* 报价组提交反馈
|
||||
*/
|
||||
@Log(title = "报价组-保存反馈说明", businessType = BusinessType.OTHER)
|
||||
@PostMapping("/saveQuotFeedbackExplanation")
|
||||
public AjaxResult saveQuotFeedbackExplanation(@RequestBody Quot quot)
|
||||
{
|
||||
quotService.updateQuot(quot);
|
||||
return success();
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 生成报价单-PC
|
||||
* @param quot
|
||||
|
|
|
@ -3,18 +3,18 @@ package com.ruoyi.web.controller.zgys;
|
|||
import java.util.List;
|
||||
import javax.servlet.http.HttpServletResponse;
|
||||
|
||||
import com.ruoyi.bid.domain.Bid;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.common.utils.StringUtils;
|
||||
import com.ruoyi.common.utils.file.FileUploadUtils;
|
||||
import com.ruoyi.common.utils.file.MinioUtil;
|
||||
import com.ruoyi.common.utils.uuid.UUID;
|
||||
import com.ruoyi.framework.changeRecord.ChangeRecordLog;
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
import com.ruoyi.zgys.service.IZgysFileService;
|
||||
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 org.springframework.web.bind.annotation.*;
|
||||
import com.ruoyi.common.annotation.Log;
|
||||
import com.ruoyi.common.core.controller.BaseController;
|
||||
import com.ruoyi.common.core.domain.AjaxResult;
|
||||
|
@ -23,6 +23,7 @@ import com.ruoyi.zgys.domain.Zgys;
|
|||
import com.ruoyi.zgys.service.IZgysService;
|
||||
import com.ruoyi.common.utils.poi.ExcelUtil;
|
||||
import com.ruoyi.common.core.page.TableDataInfo;
|
||||
import org.springframework.web.multipart.MultipartFile;
|
||||
|
||||
/**
|
||||
* 资格预审Controller
|
||||
|
@ -37,6 +38,8 @@ public class ZgysController extends BaseController
|
|||
@Autowired
|
||||
private IZgysService zgysService;
|
||||
|
||||
@Autowired
|
||||
private IZgysFileService zgysFileService;
|
||||
/**
|
||||
* 查询资格预审列表
|
||||
*/
|
||||
|
@ -81,8 +84,8 @@ public class ZgysController extends BaseController
|
|||
public AjaxResult add(@RequestBody Zgys zgys)
|
||||
{
|
||||
zgys.setPqId(UUID.fastUUID().toString());
|
||||
String bidCode = zgysService.getCode("TBXX");
|
||||
zgys.setPqCode(bidCode);
|
||||
String zgysCode = zgysService.getCode("ZGYS");
|
||||
zgys.setPqCode(zgysCode);
|
||||
zgys.setCreateBy(getUsername());
|
||||
zgys.setUpdateBy(getUsername());
|
||||
zgysService.insertZgys(zgys);
|
||||
|
@ -112,6 +115,87 @@ public class ZgysController extends BaseController
|
|||
@DeleteMapping("/{pqIds}")
|
||||
public AjaxResult remove(@PathVariable String[] pqIds)
|
||||
{
|
||||
for(String pqId:pqIds){
|
||||
Zgys zgys = zgysService.selectZgysByPqId(pqId);
|
||||
if("1".equals(zgys.getPqApprovalStatus())){
|
||||
return error("资格预审单:"+zgys.getPqCode()+" 已提交,无法删除");
|
||||
}else if("2".equals(zgys.getPqApprovalStatus())){
|
||||
return error("资格预审单:"+zgys.getPqCode()+" 已完成,无法删除");
|
||||
}else if("3".equals(zgys.getPqApprovalStatus())){
|
||||
return error("资格预审单:"+zgys.getPqCode()+" 已被驳回,无法删除");
|
||||
}
|
||||
}
|
||||
return toAjax(zgysService.deleteZgysByPqIds(pqIds));
|
||||
}
|
||||
|
||||
/**
|
||||
* 查询附件列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasAnyPermi('zgys:zgys:list')")
|
||||
@GetMapping("/zgysFileList")
|
||||
public TableDataInfo zgysFileList(ZgysFile zgysFile)
|
||||
{
|
||||
startPage();
|
||||
List<ZgysFile> list = zgysFileService.selectZgysFileList(zgysFile);
|
||||
return getDataTable(list);
|
||||
}
|
||||
|
||||
/**
|
||||
* 上传投标附件
|
||||
* @param file 文件对象
|
||||
* @param relation_id 关联业务表Id
|
||||
* @param file_type 文件类别
|
||||
* @return
|
||||
* @throws Exception
|
||||
*/
|
||||
@PreAuthorize("@ss.hasAnyPermi('zgys:zgys:zgysYwyFile')")
|
||||
@Log(title = "上传资格预审附件", businessType = BusinessType.INSERT)
|
||||
@PostMapping("/zgysFile")
|
||||
public AjaxResult zgysFile(@RequestParam("zgysFile") MultipartFile file, @RequestParam("relation_id") String relation_id, @RequestParam("file_type") String file_type) throws Exception
|
||||
{
|
||||
if(!StringUtils.isEmpty(relation_id)){
|
||||
if (!file.isEmpty())
|
||||
{
|
||||
ZgysFile zgysFile= new ZgysFile();
|
||||
zgysFile.setFileId(UUID.fastUUID().toString());
|
||||
|
||||
String url = FileUploadUtils.uploadMinio(file,"zgys-manage", "zgys/"+relation_id);
|
||||
int index = url.lastIndexOf("/")+1;
|
||||
String fileName = url.substring(index);//获取文件名
|
||||
|
||||
int index2 = url.indexOf("/zgys/");
|
||||
String fileBucketName = url.substring(index2);//获取文件对应文件服务器中地址-供后面删除功能用
|
||||
|
||||
zgysFile.setFileName(fileName);
|
||||
zgysFile.setFileBucketName(fileBucketName);
|
||||
zgysFile.setFileUrl(url);
|
||||
zgysFile.setFileSize(file.getSize());
|
||||
zgysFile.setFileTime(DateUtils.getTime());
|
||||
zgysFile.setFileType(file_type);
|
||||
zgysFile.setRelationId(relation_id);
|
||||
zgysFileService.insertZgysFile(zgysFile);
|
||||
}
|
||||
}else{
|
||||
return error("系统异常,投标单号为空!");
|
||||
}
|
||||
return success("上传成功!");
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除附件列表
|
||||
*/
|
||||
@PreAuthorize("@ss.hasAnyPermi('zgys:zgys:zgysYwyFile')")
|
||||
@Log(title = "删除资格预审附件列表", businessType = BusinessType.DELETE)
|
||||
@PostMapping("/zgysFileDelete")
|
||||
public AjaxResult zgysFileDelete(ZgysFile zgysFile) {
|
||||
String fileId = zgysFile.getFileId();
|
||||
try {
|
||||
ZgysFile zgysfile = zgysFileService.selectZgysFileByFileId(fileId);
|
||||
zgysFileService.deleteZgysFileByFileId(fileId);//删除文件记录
|
||||
MinioUtil.removeObject("zgys-manage", zgysfile.getFileBucketName());//删除文件服务器对应文件
|
||||
}catch(Exception e){
|
||||
return error("系统异常!");
|
||||
}
|
||||
return success();
|
||||
}
|
||||
}
|
||||
|
|
|
@ -13,33 +13,33 @@ public interface IBidFileService
|
|||
{
|
||||
|
||||
/**
|
||||
* 查询报价单-文件
|
||||
* 查询投标单-文件
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @return 报价单-文件
|
||||
* @param fileId 投标单-文件主键
|
||||
* @return 投标单-文件
|
||||
*/
|
||||
public BidFile selectBidFileByFileId(String fileId);
|
||||
|
||||
/**
|
||||
* 查询报价单-文件列表
|
||||
* 查询投标单-文件列表
|
||||
*
|
||||
* @param bidFile 报价单-文件
|
||||
* @return 报价单-文件集合
|
||||
* @param bidFile 投标单-文件
|
||||
* @return 投标单-文件集合
|
||||
*/
|
||||
public List<BidFile> selectBidFileList(BidFile bidFile);
|
||||
|
||||
/**
|
||||
* 新增报价单-文件
|
||||
* 新增投标单-文件
|
||||
*
|
||||
* @param bidFile 报价单-文件
|
||||
* @param bidFile 投标单-文件
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertBidFile(BidFile bidFile);
|
||||
|
||||
/**
|
||||
* 删除报价单-文件信息
|
||||
* 删除投标单-文件信息
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @param fileId 投标单-文件主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteBidFileByFileId(String fileId);
|
||||
|
|
|
@ -23,10 +23,10 @@ public class BidFileServiceImpl implements IBidFileService
|
|||
private BidFileMapper bidFileMapper;
|
||||
|
||||
/**
|
||||
* 查询报价单-文件
|
||||
* 查询投标单-文件
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @return 报价单-文件
|
||||
* @param fileId 投标单-文件主键
|
||||
* @return 投标单-文件
|
||||
*/
|
||||
@Override
|
||||
public BidFile selectBidFileByFileId(String fileId)
|
||||
|
@ -36,10 +36,10 @@ public class BidFileServiceImpl implements IBidFileService
|
|||
|
||||
|
||||
/**
|
||||
* 查询报价单-文件列表
|
||||
* 查询投标单-文件列表
|
||||
*
|
||||
* @param bidFile 报价单-文件
|
||||
* @return 报价单-文件
|
||||
* @param bidFile 投标单-文件
|
||||
* @return 投标单-文件
|
||||
*/
|
||||
@Override
|
||||
public List<BidFile> selectBidFileList(BidFile bidFile)
|
||||
|
@ -48,9 +48,9 @@ public class BidFileServiceImpl implements IBidFileService
|
|||
}
|
||||
|
||||
/**
|
||||
* 新增报价单-文件
|
||||
* 新增投标单-文件
|
||||
*
|
||||
* @param bidFile 报价单-文件
|
||||
* @param bidFile 投标单-文件
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
|
@ -61,9 +61,9 @@ public class BidFileServiceImpl implements IBidFileService
|
|||
}
|
||||
|
||||
/**
|
||||
* 删除报价单-文件信息
|
||||
* 删除投标单-文件信息
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @param fileId 投标单-文件主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
|
|
|
@ -0,0 +1,113 @@
|
|||
package com.ruoyi.zgys.domain;
|
||||
|
||||
import com.ruoyi.common.core.domain.BaseEntity;
|
||||
import org.apache.commons.lang3.builder.ToStringBuilder;
|
||||
import org.apache.commons.lang3.builder.ToStringStyle;
|
||||
|
||||
/**
|
||||
* 投标信息-文件对象 bid_file
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2024-04-01
|
||||
*/
|
||||
public class ZgysFile extends BaseEntity
|
||||
{
|
||||
private static final long serialVersionUID = 1L;
|
||||
|
||||
/** */
|
||||
private String fileId;
|
||||
|
||||
/** 文件名称 */
|
||||
private String fileName;
|
||||
|
||||
/** MINIO文件名称 */
|
||||
private String fileBucketName;
|
||||
|
||||
/** 文件地址 */
|
||||
private String fileUrl;
|
||||
|
||||
/** 文件大小 */
|
||||
private Long fileSize;
|
||||
|
||||
/** 上传时间 */
|
||||
private String fileTime;
|
||||
|
||||
/** 类别 */
|
||||
private String fileType;
|
||||
|
||||
/** */
|
||||
private String relationId;
|
||||
|
||||
public void setFileId(String fileId)
|
||||
{
|
||||
this.fileId = fileId;
|
||||
}
|
||||
|
||||
public String getFileId()
|
||||
{
|
||||
return fileId;
|
||||
}
|
||||
public void setFileName(String fileName)
|
||||
{
|
||||
this.fileName = fileName;
|
||||
}
|
||||
|
||||
public String getFileName()
|
||||
{
|
||||
return fileName;
|
||||
}
|
||||
public String getFileBucketName() {return fileBucketName;}
|
||||
|
||||
public void setFileBucketName(String fileBucketName) {this.fileBucketName = fileBucketName;}
|
||||
public void setFileUrl(String fileUrl)
|
||||
{
|
||||
this.fileUrl = fileUrl;
|
||||
}
|
||||
|
||||
public String getFileUrl()
|
||||
{
|
||||
return fileUrl;
|
||||
}
|
||||
public void setFileSize(Long fileSize)
|
||||
{
|
||||
this.fileSize = fileSize;
|
||||
}
|
||||
|
||||
public Long getFileSize()
|
||||
{
|
||||
return fileSize;
|
||||
}
|
||||
public void setFileTime(String fileTime)
|
||||
{
|
||||
this.fileTime = fileTime;
|
||||
}
|
||||
|
||||
public String getFileTime()
|
||||
{
|
||||
return fileTime;
|
||||
}
|
||||
public String getFileType() {return fileType;}
|
||||
|
||||
public void setFileType(String fileType) {this.fileType = fileType;}
|
||||
public void setRelationId(String relationId)
|
||||
{
|
||||
this.relationId = relationId;
|
||||
}
|
||||
|
||||
public String getRelationId()
|
||||
{
|
||||
return relationId;
|
||||
}
|
||||
|
||||
@Override
|
||||
public String toString() {
|
||||
return new ToStringBuilder(this,ToStringStyle.MULTI_LINE_STYLE)
|
||||
.append("fileId", getFileId())
|
||||
.append("fileName", getFileName())
|
||||
.append("fileUrl", getFileUrl())
|
||||
.append("fileSize", getFileSize())
|
||||
.append("fileTime", getFileTime())
|
||||
.append("relationId", getRelationId())
|
||||
.toString();
|
||||
}
|
||||
}
|
|
@ -0,0 +1,46 @@
|
|||
package com.ruoyi.zgys.mapper;
|
||||
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 资格预审信息-文件Mapper接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2024-04-01
|
||||
*/
|
||||
public interface ZgysFileMapper
|
||||
{
|
||||
/**
|
||||
* 查询资格预审信息-文件
|
||||
*
|
||||
* @param fileId 资格预审信息-文件主键
|
||||
* @return 资格预审信息-文件
|
||||
*/
|
||||
public ZgysFile selectZgysFileByFileId(String fileId);
|
||||
|
||||
/**
|
||||
* 查询资格预审信息-文件列表
|
||||
*
|
||||
* @param zgysFile 资格预审信息-文件
|
||||
* @return 资格预审信息-文件集合
|
||||
*/
|
||||
public List<ZgysFile> selectZgysFileList(ZgysFile zgysFile);
|
||||
|
||||
/**
|
||||
* 新增资格预审信息-文件
|
||||
*
|
||||
* @param zgysFile 资格预审信息-文件
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertZgysFile(ZgysFile zgysFile);
|
||||
|
||||
/**
|
||||
* 删除资格预审信息-文件
|
||||
*
|
||||
* @param fileId 资格预审信息-文件主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteZgysFileByFileId(String fileId);
|
||||
}
|
|
@ -0,0 +1,48 @@
|
|||
package com.ruoyi.zgys.service;
|
||||
|
||||
import com.ruoyi.bid.domain.BidFile;
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 资格预审投标信息-文件Service接口
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2024-04-01
|
||||
*/
|
||||
public interface IZgysFileService
|
||||
{
|
||||
|
||||
/**
|
||||
* 查询资格预审投标单-文件
|
||||
*
|
||||
* @param fileId 资格预审投标单-文件主键
|
||||
* @return 资格预审投标单-文件
|
||||
*/
|
||||
public ZgysFile selectZgysFileByFileId(String fileId);
|
||||
|
||||
/**
|
||||
* 查询资格预审投标单-文件列表
|
||||
*
|
||||
* @param bidFile 资格预审投标单-文件
|
||||
* @return 资格预审投标单-文件集合
|
||||
*/
|
||||
public List<ZgysFile> selectZgysFileList(ZgysFile bidFile);
|
||||
|
||||
/**
|
||||
* 新增资格预审投标单-文件
|
||||
*
|
||||
* @param zgysFile 资格预审投标单-文件
|
||||
* @return 结果
|
||||
*/
|
||||
public int insertZgysFile(ZgysFile zgysFile);
|
||||
|
||||
/**
|
||||
* 删除资格预审投标单-文件信息
|
||||
*
|
||||
* @param fileId 资格预审投标单-文件主键
|
||||
* @return 结果
|
||||
*/
|
||||
public int deleteZgysFileByFileId(String fileId);
|
||||
}
|
|
@ -2,6 +2,7 @@ package com.ruoyi.zgys.service;
|
|||
|
||||
import java.util.List;
|
||||
import com.ruoyi.zgys.domain.Zgys;
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
|
||||
/**
|
||||
* 资格预审Service接口
|
||||
|
|
|
@ -0,0 +1,74 @@
|
|||
package com.ruoyi.zgys.service.impl;
|
||||
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
import com.ruoyi.zgys.mapper.ZgysFileMapper;
|
||||
import com.ruoyi.zgys.service.IZgysFileService;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import org.springframework.transaction.annotation.Transactional;
|
||||
|
||||
import java.util.List;
|
||||
|
||||
/**
|
||||
* 资格预审信息-文件Service业务层处理
|
||||
*
|
||||
* @author ruoyi
|
||||
* @date 2024-04-01
|
||||
*/
|
||||
@Service
|
||||
public class ZgysFileServiceImpl implements IZgysFileService
|
||||
{
|
||||
@Autowired
|
||||
private ZgysFileMapper zgysFileMapper;
|
||||
|
||||
/**
|
||||
* 查询报价单-文件
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @return 报价单-文件
|
||||
*/
|
||||
@Override
|
||||
public ZgysFile selectZgysFileByFileId(String fileId)
|
||||
{
|
||||
return zgysFileMapper.selectZgysFileByFileId(fileId);
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* 查询报价单-文件列表
|
||||
*
|
||||
* @param zgysFile 报价单-文件
|
||||
* @return 报价单-文件
|
||||
*/
|
||||
@Override
|
||||
public List<ZgysFile> selectZgysFileList(ZgysFile zgysFile)
|
||||
{
|
||||
return zgysFileMapper.selectZgysFileList(zgysFile);
|
||||
}
|
||||
|
||||
/**
|
||||
* 新增报价单-文件
|
||||
*
|
||||
* @param zgysFile 报价单-文件
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int insertZgysFile(ZgysFile zgysFile)
|
||||
{
|
||||
return zgysFileMapper.insertZgysFile(zgysFile);
|
||||
}
|
||||
|
||||
/**
|
||||
* 删除报价单-文件信息
|
||||
*
|
||||
* @param fileId 报价单-文件主键
|
||||
* @return 结果
|
||||
*/
|
||||
@Override
|
||||
@Transactional
|
||||
public int deleteZgysFileByFileId(String fileId)
|
||||
{
|
||||
return zgysFileMapper.deleteZgysFileByFileId(fileId);
|
||||
}
|
||||
}
|
|
@ -4,6 +4,7 @@ import java.util.List;
|
|||
|
||||
import com.ruoyi.common.annotation.DataScope;
|
||||
import com.ruoyi.common.utils.DateUtils;
|
||||
import com.ruoyi.zgys.domain.ZgysFile;
|
||||
import org.springframework.beans.factory.annotation.Autowired;
|
||||
import org.springframework.stereotype.Service;
|
||||
import com.ruoyi.zgys.mapper.ZgysMapper;
|
||||
|
|
|
@ -0,0 +1,63 @@
|
|||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.zgys.mapper.ZgysFileMapper">
|
||||
|
||||
<resultMap type="ZgysFile" id="ZgysFileResult">
|
||||
<result property="fileId" column="file_id" />
|
||||
<result property="fileName" column="file_name" />
|
||||
<result property="fileBucketName" column="file_bucket_name" />
|
||||
<result property="fileUrl" column="file_url" />
|
||||
<result property="fileSize" column="file_size" />
|
||||
<result property="fileTime" column="file_time" />
|
||||
<result property="fileType" column="file_type" />
|
||||
<result property="relationId" column="relation_id" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectZgysFileVo">
|
||||
select file_id, file_name, file_bucket_name, file_url, file_size, file_time, file_type, relation_id from zgys_file
|
||||
</sql>
|
||||
|
||||
<select id="selectZgysFileList" parameterType="ZgysFile" resultMap="ZgysFileResult">
|
||||
<include refid="selectZgysFileVo"/>
|
||||
<where>
|
||||
and relation_id = #{relationId}
|
||||
and file_type = #{fileType}
|
||||
</where>
|
||||
order by file_time desc
|
||||
</select>
|
||||
|
||||
<select id="selectZgysFileByFileId" parameterType="String" resultMap="ZgysFileResult">
|
||||
<include refid="selectZgysFileVo"/>
|
||||
where file_id = #{fileId}
|
||||
</select>
|
||||
|
||||
<insert id="insertZgysFile" parameterType="ZgysFile">
|
||||
insert into zgys_file
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="fileId != null">file_id,</if>
|
||||
<if test="fileName != null">file_name,</if>
|
||||
<if test="fileBucketName != null">file_bucket_name,</if>
|
||||
<if test="fileUrl != null">file_url,</if>
|
||||
<if test="fileSize != null">file_size,</if>
|
||||
<if test="fileTime != null">file_time,</if>
|
||||
<if test="fileType != null">file_type,</if>
|
||||
<if test="relationId != null">relation_id,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="fileId != null">#{fileId},</if>
|
||||
<if test="fileName != null">#{fileName},</if>
|
||||
<if test="fileBucketName != null">#{fileBucketName},</if>
|
||||
<if test="fileUrl != null">#{fileUrl},</if>
|
||||
<if test="fileSize != null">#{fileSize},</if>
|
||||
<if test="fileTime != null">#{fileTime},</if>
|
||||
<if test="fileType != null">#{fileType},</if>
|
||||
<if test="relationId != null">#{relationId},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<delete id="deleteZgysFileByFileId" parameterType="String">
|
||||
delete from zgys_file where file_id = #{fileId}
|
||||
</delete>
|
||||
</mapper>
|
|
@ -154,6 +154,15 @@ export function feedbackQuot(data) {
|
|||
})
|
||||
}
|
||||
|
||||
//保存反馈说明
|
||||
export function saveQuotFeedbackExplanation(data) {
|
||||
return request({
|
||||
url: '/quot/quot/saveQuotFeedbackExplanation',
|
||||
method: 'post',
|
||||
data: data
|
||||
})
|
||||
}
|
||||
|
||||
//生成报价单-PC
|
||||
export function madeQuot(data) {
|
||||
return request({
|
||||
|
|
|
@ -42,3 +42,21 @@ export function delZgys(pqId) {
|
|||
method: 'delete'
|
||||
})
|
||||
}
|
||||
|
||||
// 查询附件列表
|
||||
export function zgysFileList(query) {
|
||||
return request({
|
||||
url: '/zgys/zgys/zgysFileList',
|
||||
method: 'get',
|
||||
params: query
|
||||
})
|
||||
}
|
||||
|
||||
//删除附件
|
||||
export function zgysFileDelete(fileId) {
|
||||
return request({
|
||||
url: '/zgys/zgys/zgysFileDelete',
|
||||
method: 'post',
|
||||
params: {fileId:fileId}
|
||||
})
|
||||
}
|
||||
|
|
|
@ -248,7 +248,7 @@
|
|||
</el-col>
|
||||
<el-col :span="10">
|
||||
<el-form-item label="原报名编号" prop="bidRegistrationNumber">
|
||||
<el-input v-model="form.bidRegistrationNumber" :disabled="true">
|
||||
<el-input v-model="form.bidRegistrationNumber" placeholder="请输入原报名编号" :disabled="true">
|
||||
<el-button slot="append" icon="el-icon-search" @click="openZgys" v-if="this.form.bidApprovalStatus == '0' || this.form.bidApprovalStatus == null"/>
|
||||
</el-input>
|
||||
</el-form-item>
|
||||
|
@ -863,7 +863,15 @@
|
|||
<!-- 资格预审单列表对话框-->
|
||||
<el-dialog :title="zgysTitle" :visible.sync="zgysOpen" width="1000px" append-to-body>
|
||||
<el-form :model="zgysQueryParams" ref="queryQccForm" size="small" :inline="true" label-width="100px" @submit.native.prevent>
|
||||
<el-form-item label="招标单位" prop="Name">
|
||||
<el-form-item label="资格预审编号" prop="pqCode">
|
||||
<el-input
|
||||
v-model="zgysQueryParams.pqCode"
|
||||
placeholder="请输入资格预审编号"
|
||||
@keyup.enter.native="getZgysList"
|
||||
clearable
|
||||
/>
|
||||
</el-form-item>
|
||||
<el-form-item label="招标单位" prop="pqCustomerName">
|
||||
<el-input
|
||||
v-model="zgysQueryParams.pqCustomerName"
|
||||
placeholder="请输入招标单位"
|
||||
|
@ -1011,9 +1019,9 @@ export default {
|
|||
// 开标日期时间范围
|
||||
daterangeBidOpeningDate: [],
|
||||
|
||||
//报价单-询价附件上传地址
|
||||
//投标信息-投标附件上传地址
|
||||
uploadUrl: process.env.VUE_APP_BASE_API + "/bid/bid/bidFile",
|
||||
//报价单-询价附件请求头
|
||||
//投标信息-投标附件请求头
|
||||
headers: {Authorization: "Bearer " + getToken()},
|
||||
|
||||
// 投标信息-业务员附件列表数据
|
||||
|
@ -1638,6 +1646,7 @@ export default {
|
|||
resetZgysQuery() {
|
||||
this.zgysList = [];
|
||||
this.zgysQueryParams = {
|
||||
pqCode: "",
|
||||
pqCustomerName: "",
|
||||
pqProject: "",
|
||||
pqApprovalStatus: '2'
|
||||
|
|
|
@ -429,7 +429,8 @@
|
|||
<el-row :gutter="8" v-if="checkRole(['QUOT','PRICE_VERIFICATION','SALES_MAN','HTB_QUOT'])">
|
||||
<el-col :span="14" v-if="this.form.quotApprovalStatus != '0' && this.form.quotApprovalStatus != null">
|
||||
<el-form-item label="反馈说明" prop="quotFeedbackExplanation">
|
||||
<el-input type="textarea" autosize v-model="form.quotFeedbackExplanation" placeholder="报价组填写" :disabled="this.form.quotApprovalStatus == 2 || this.form.quotApprovalStatus == 3"/>
|
||||
<el-input type="textarea" style="width:80%" autosize v-model="form.quotFeedbackExplanation" placeholder="报价组填写" :disabled="this.form.quotApprovalStatus == 2 || this.form.quotApprovalStatus == 3"/>
|
||||
<el-button type="primary" icon="el-icon-folder" style="margin-left: 10px" @click="saveQuotFeedbackExplanation" size="mini" v-if="checkRole(['QUOT','PRICE_VERIFICATION'])"></el-button>
|
||||
</el-form-item>
|
||||
</el-col>
|
||||
<el-col :span="10" v-if="this.form.quotOAApprovalStatus == '2' || this.form.quotOAApprovalStatus == '3'">
|
||||
|
@ -1075,7 +1076,7 @@
|
|||
import { NumberAdd } from '@/utils/number';// 数值计算
|
||||
import { toDecimal,versionList } from "@/api/redBook/redBook";
|
||||
|
||||
import { changQuotPrintStatus,listQuot, getQuot, getReturnUpdateQuot,getAllPass,getAllReject, delQuot, addQuot, updateQuot, quotFileList, quotFileDelete, commitQuot, commitJsQuot, commitHjQuot, commitJswQuot, commitOAQuot, feedbackQuot, madeQuot, rejectQuot, setHandle } from "@/api/quot/quot";
|
||||
import { changQuotPrintStatus,listQuot, getQuot, getReturnUpdateQuot,getAllPass,getAllReject, delQuot, addQuot, updateQuot, quotFileList, quotFileDelete, commitQuot, commitJsQuot, commitHjQuot, commitJswQuot, commitOAQuot, feedbackQuot, madeQuot, rejectQuot, setHandle,saveQuotFeedbackExplanation } from "@/api/quot/quot";
|
||||
import { getToken } from "@/utils/auth";
|
||||
import { checkPermi,checkRole } from '@/utils/permission';// 权限判断函数
|
||||
import { getDicts } from "@/api/system/dict/data";
|
||||
|
@ -1629,6 +1630,14 @@ export default {
|
|||
});
|
||||
},
|
||||
|
||||
// 保存反馈说明
|
||||
saveQuotFeedbackExplanation(){
|
||||
const param = {'quotId':this.form.quotId,'quotFeedbackExplanation':this.form.quotFeedbackExplanation}
|
||||
saveQuotFeedbackExplanation(param).then(response => {
|
||||
this.$modal.msgSuccess("保存成功");
|
||||
});
|
||||
},
|
||||
|
||||
/** 报价组生成报价单按钮 */
|
||||
madeQuot(){
|
||||
const roles = this.$store.state.user.roles;
|
||||
|
|
|
@ -307,6 +307,43 @@
|
|||
</el-form-item>
|
||||
</el-col>
|
||||
</el-row>
|
||||
|
||||
<el-divider content-position="left" class="customer_divider_text">业务员附件(先保存再上传)</el-divider>
|
||||
<div v-hasPermi="['zgys:zgys:zgysYwyFile']">
|
||||
<el-upload class="upload-demo"
|
||||
ref="zgysYwyFileUpload"
|
||||
name="zgysFile"
|
||||
:action="uploadUrl"
|
||||
:headers="headers"
|
||||
:data="{ relation_id: this.form.pqId,file_type: 'zgysYwyFile' }"
|
||||
:before-upload="beforeAvatarUploadZgysYwyFile"
|
||||
:on-success="handleAvatarSuccess"
|
||||
:show-file-list="false"
|
||||
:limit="1"
|
||||
v-if="this.form.pqApprovalStatus == '0'">
|
||||
<el-button size="mini" type="primary" @click="uploadFile('zgysYwyFile')">上传文件</el-button>
|
||||
</el-upload>
|
||||
</div>
|
||||
<el-table class="down" v-loading="zgysYwyFileLoading" :data="zgysYwyFileList" border stripe style="width: 100%;margin-top: 10px;" height="200px">
|
||||
<el-table-column prop="fileName" label="文件名称" ></el-table-column>
|
||||
<el-table-column prop="fileSize" label="文件大小" width="150px">
|
||||
<template slot-scope="scope">
|
||||
<span v-if="scope.row.fileSize / 1024 / 1024 < 1">{{(scope.row.fileSize / 1024).toFixed(2) + 'KB'}}</span>
|
||||
<span v-else>{{(scope.row.fileSize / 1024 / 1024).toFixed(2) + 'MB'}}</span>
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="fileTime" label="上传时间" width="200px"></el-table-column>
|
||||
<el-table-column width="150px" label="操作">
|
||||
<template slot-scope="scope">
|
||||
<el-button :key="Math.random()" size="small" type="text">
|
||||
<a @click="downloadFile(scope.row.fileUrl)">下载</a>
|
||||
</el-button>
|
||||
<el-button :key="Math.random()" size="small" type="text" v-if="form.pqApprovalStatus == '0'">
|
||||
<a @click="deleteFile(scope.row.fileId,'zgysYwyFile')">删除</a>
|
||||
</el-button>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
</el-form>
|
||||
<div slot="footer" class="dialog-footer">
|
||||
<el-button type="primary" @click="submitForm">确 定</el-button>
|
||||
|
@ -335,7 +372,8 @@
|
|||
}
|
||||
</style>
|
||||
<script>
|
||||
import { listZgys, getZgys, delZgys, addZgys, updateZgys } from "@/api/zgys/zgys";
|
||||
import { getToken } from "@/utils/auth";
|
||||
import { listZgys, getZgys, delZgys, addZgys, updateZgys, zgysFileList, zgysFileDelete } from "@/api/zgys/zgys";
|
||||
/** 导入客户选择组件 */
|
||||
import CustomerSelect from "@/views/components/Tools/CustomerSelect/index.vue";
|
||||
export default {
|
||||
|
@ -407,7 +445,16 @@ export default {
|
|||
pqPhone: [
|
||||
{ required: true, message: "联系电话不能为空", trigger: "blur" }
|
||||
],
|
||||
}
|
||||
},
|
||||
|
||||
// 资格预审-附件上传地址
|
||||
uploadUrl: process.env.VUE_APP_BASE_API + "/zgys/zgys/zgysFile",
|
||||
// 资格预审-附件请求头
|
||||
headers: {Authorization: "Bearer " + getToken()},
|
||||
// 资格预审-业务员附件列表数据
|
||||
activeName: '',
|
||||
zgysYwyFileLoading: false,
|
||||
zgysYwyFileList: [],
|
||||
};
|
||||
},
|
||||
created() {
|
||||
|
@ -459,6 +506,7 @@ export default {
|
|||
updateBy: null,
|
||||
updateTime: null
|
||||
};
|
||||
this.zgysYwyFileList = [],
|
||||
this.resetForm("form");
|
||||
},
|
||||
/** 搜索按钮操作 */
|
||||
|
@ -497,6 +545,9 @@ export default {
|
|||
this.form = response.data;
|
||||
this.open = true;
|
||||
this.title = "修改资格预审";
|
||||
|
||||
//获取资格预审信息-附件列表
|
||||
this.getZgysYwyFileList();
|
||||
});
|
||||
},
|
||||
/** 提交按钮 */
|
||||
|
@ -546,6 +597,62 @@ export default {
|
|||
this.form.pqCustomerName = customer.label;
|
||||
this.customerOpen=false;
|
||||
},
|
||||
|
||||
|
||||
//点击上传附件按钮触发事件
|
||||
uploadFile(activeName){
|
||||
this.activeName = activeName
|
||||
},
|
||||
//上传前校验-业务员附件
|
||||
beforeAvatarUploadZgysYwyFile(file){
|
||||
this.zgysYwyFileLoading = true;
|
||||
const maxSize = 100 * 1024 * 1024; // 100MB,根据你的需求设置最大文件大小
|
||||
if (file.size > maxSize) {
|
||||
this.$modal.msgError("文件大小超过了"+maxSize / (1024 * 1024)+"MB的限制");
|
||||
this.zgysYwyFileLoading = false;
|
||||
return false;
|
||||
}
|
||||
},
|
||||
//成功回调
|
||||
handleAvatarSuccess(res) {
|
||||
let activeName = this.activeName;
|
||||
// 如果上传成功
|
||||
if (res.code == 200) {
|
||||
this.$modal.msgSuccess(res.msg);
|
||||
if(activeName=='zgysYwyFile'){
|
||||
this.getZgysYwyFileList();
|
||||
this.zgysYwyFileLoading = false;
|
||||
this.$refs.zgysYwyFileUpload.clearFiles(); //上传成功之后清除历史记录**加粗样式**
|
||||
}
|
||||
}else {
|
||||
this.$modal.msgError(res.msg);
|
||||
if(activeName=='zgysYwyFile'){
|
||||
this.zgysYwyFileLoading = false;
|
||||
this.$refs.zgysYwyFileUpload.clearFiles(); //上传成功之后清除历史记录**加粗样式**
|
||||
}
|
||||
}
|
||||
},
|
||||
//获取资格预审-业务员附件列表
|
||||
getZgysYwyFileList(){
|
||||
const param = {relationId:this.form.pqId,fileType:'zgysYwyFile'}
|
||||
zgysFileList(param).then(response => {
|
||||
this.zgysYwyFileList = response.rows;
|
||||
});
|
||||
},
|
||||
//下载附件
|
||||
downloadFile(fileUrl){
|
||||
window.open(fileUrl, "_blank");
|
||||
},
|
||||
//删除附件
|
||||
deleteFile(fileId,activeName){
|
||||
if(activeName=='zgysYwyFile'){
|
||||
this.zgysYwyFileLoading = true;
|
||||
zgysFileDelete(fileId).then(response => {
|
||||
this.getZgysYwyFileList();
|
||||
this.zgysYwyFileLoading = false;
|
||||
})
|
||||
}
|
||||
},
|
||||
}
|
||||
};
|
||||
</script>
|
||||
|
|
Loading…
Reference in New Issue