fix:处理了一些问题

dev_1.0.2
jiangpeng 2026-06-10 17:51:20 +08:00
parent a5b4446202
commit c440cb0357
8 changed files with 146 additions and 6 deletions

View File

@ -0,0 +1,10 @@
import request from '@/utils/request'
// 按SN码查询库存数据
export function listInventoryInfoByProductSn(query) {
return request({
url: '/sip/dataProcess/inventoryInfoByProductSn',
method: 'get',
params: query
})
}

View File

@ -0,0 +1,76 @@
<template>
<div class="app-container">
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="80px">
<el-form-item label="SN码" prop="productSn">
<el-input
v-model="queryParams.productSn"
placeholder="请输入SN码"
clearable
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item>
<el-button type="primary" icon="el-icon-search" size="mini" @click="handleQuery"></el-button>
<el-button icon="el-icon-refresh" size="mini" @click="resetQuery"></el-button>
</el-form-item>
</el-form>
<el-row :gutter="10" class="mb8">
<right-toolbar :showSearch.sync="showSearch" @queryTable="getList"></right-toolbar>
</el-row>
<el-table v-loading="loading" :data="inventoryInfoList">
<el-table-column label="SN码" align="center" prop="productSn" />
<el-table-column label="入库单号" align="center" prop="innerCode" />
<el-table-column label="出库单号" align="center" prop="outerCode" />
<el-table-column label="订单编号" align="center" prop="orderCode" />
</el-table>
<pagination
v-show="total>0"
:total="total"
:page.sync="queryParams.pageNum"
:limit.sync="queryParams.pageSize"
@pagination="getList"
/>
</div>
</template>
<script>
import { listInventoryInfoByProductSn } from '@/api/dataProcess/inventoryInfo'
export default {
name: 'DataProcessInventoryInfo',
data() {
return {
loading: false,
showSearch: true,
total: 0,
inventoryInfoList: [],
queryParams: {
pageNum: 1,
pageSize: 10,
productSn: null
}
}
},
methods: {
getList() {
this.loading = true
listInventoryInfoByProductSn(this.queryParams).then(response => {
this.inventoryInfoList = response.rows
this.total = response.total
this.loading = false
})
},
handleQuery() {
this.queryParams.pageNum = 1
this.getList()
},
resetQuery() {
this.resetForm('queryForm')
this.handleQuery()
}
}
}
</script>

View File

@ -25,6 +25,14 @@
@keyup.enter.native="handleQuery"
/>
</el-form-item>
<el-form-item label="备货状态" prop="orderStockingStatus">
<el-select v-model="queryParams.orderStockingStatus" placeholder="请选择备货状态" clearable>
<el-option label="配货中" value="PHZ" />
<el-option label="已配货" value="YPH" />
<el-option label="部分备货" value="BFBH" />
<el-option label="备货完成" value="BHWC" />
</el-select>
</el-form-item>
<el-form-item label="出库状态" prop="outerStatus">
<el-select v-model="queryParams.outerStatus" placeholder="请选择出库状态" clearable>
<el-option
@ -544,6 +552,7 @@ export default {
projectCode: null,
orderCode: null,
projectName: null,
orderStockingStatus: null,
outerStatus: null,
deliveryStatus: null,
productCode: null,

View File

@ -43,7 +43,7 @@ public class SysLoginController extends BaseController
private static final String RESET_PWD_EMAIL_CODE_TIME_KEY = "RESET_PWD_EMAIL_CODE_TIME_";
private static final long RESET_PWD_EMAIL_CODE_EXPIRE_TIME = 5 * 60 * 1000L;
private static final long RESET_PWD_EMAIL_CODE_EXPIRE_TIME = 10 * 60 * 1000L;
/**
*
@ -137,7 +137,7 @@ public class SysLoginController extends BaseController
Mail.create()
.setTos(user.getEmail())
.setTitle("OMS系统修改密码邮箱验证码")
.setContent("您的修改密码邮箱验证码为:" + code + ",有效期5分钟。如非本人操作,请忽略本邮件。")
.setContent("您的修改密码邮箱验证码为:" + code + ",有效期10分钟。如非本人操作,请忽略本邮件。")
.setHtml(false)
.send();
ServletUtils.getRequest().getSession().setAttribute(RESET_PWD_EMAIL_CODE_KEY + username, code);

View File

@ -56,8 +56,11 @@ public class OnlineSessionFilter extends AccessControlFilter
{
onlineSession.setUserId(user.getUserId());
onlineSession.setLoginName(user.getLoginName());
onlineSession.setAvatar(user.getAvatar());
onlineSession.setDeptName(user.getDept().getDeptName());
onlineSession.setAvatar(user.getAvatar());
if (user.getDept() != null)
{
onlineSession.setDeptName(user.getDept().getDeptName());
}
onlineSession.markAttributeChanged();
}
}

View File

@ -1,24 +1,33 @@
package com.ruoyi.sip.controller;
import com.ruoyi.common.annotation.Anonymous;
import com.ruoyi.common.core.controller.BaseController;
import com.ruoyi.common.core.domain.AjaxResult;
import com.ruoyi.common.core.page.TableDataInfo;
import com.ruoyi.common.utils.StringUtils;
import com.ruoyi.sip.domain.InventoryInfo;
import com.ruoyi.sip.dto.ProjectTransferRequest;
import com.ruoyi.sip.service.IDataProcessService;
import com.ruoyi.sip.service.IInventoryInfoService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.*;
import javax.servlet.http.HttpServletRequest;
import java.util.Collections;
/**
*
*/
@RestController
@RequestMapping("/sip/dataProcess")
public class DataProcessController {
public class DataProcessController extends BaseController {
@Autowired
private IDataProcessService dataProcessService;
@Autowired
private IInventoryInfoService inventoryInfoService;
//入库单生成应付单
@Anonymous
@GetMapping("/inventoryInnerGeneratePayableBill")
@ -53,4 +62,16 @@ public class DataProcessController {
dataProcessService.generateVirtualPurchase(type);
}
//查询库存SN数据
@GetMapping("/inventoryInfoByProductSn")
public TableDataInfo inventoryInfoByProductSn(@RequestParam(value = "productSn", required = false) String productSn) {
if (StringUtils.isEmpty(productSn)) {
return getDataTable(Collections.emptyList());
}
startPage();
InventoryInfo inventoryInfo = new InventoryInfo();
inventoryInfo.setProductSn(productSn);
return getDataTable(inventoryInfoService.selectInventoryInfoList(inventoryInfo));
}
}

View File

@ -23,6 +23,14 @@ public class OpportunityUpdateRequestDto {
*
*/
private BigDecimal amount;
/**
*
*/
private BigDecimal actualSignedAmount;
/**
* POC
*/
private Boolean isPoc;
/**
* YYYY-MM-DD
*/

View File

@ -371,6 +371,14 @@ public class ProjectInfoServiceImpl implements IProjectInfoService {
requestDto.setOpportunityName(projectInfo.getProjectName());
requestDto.setOperatorName(projectInfo.getOperateInstitution());
requestDto.setAmount(projectInfo.getEstimatedAmount());
requestDto.setIsPoc(StringUtils.equals("1", projectInfo.getPoc()));
List<ProjectOrderInfo> projectOrderInfos = null;
if (projectInfo.getId() != null) {
projectOrderInfos = orderInfoService.selectProjectOrderInfoByProjectId(Collections.singletonList(projectInfo.getId()));
if (CollUtil.isNotEmpty(projectOrderInfos)) {
requestDto.setActualSignedAmount(projectOrderInfos.get(0).getShipmentAmount());
}
}
requestDto.setExpectedCloseDate(formatterDate(projectInfo.getEstimatedOrderTime(), DateUtils.YYYY_MM_DD));
requestDto.setConfidencePct(projectInfo.getProjectGraspDegree());
requestDto.setStage(projectInfo.getProjectStage());
@ -380,7 +388,10 @@ public class ProjectInfoServiceImpl implements IProjectInfoService {
requestDto.setCompetitorName(projectInfo.getCompetitor());
Boolean canGenerate = projectInfo.getCanGenerate();
if (canGenerate == null && projectInfo.getId() != null) {
canGenerate = CollUtil.isNotEmpty(orderInfoService.selectProjectOrderInfoByProjectId(Collections.singletonList(projectInfo.getId())));
if (projectOrderInfos == null) {
projectOrderInfos = orderInfoService.selectProjectOrderInfoByProjectId(Collections.singletonList(projectInfo.getId()));
}
canGenerate = CollUtil.isNotEmpty(projectOrderInfos);
}
requestDto.setArchived(canGenerate);
return hasOpportunityUpdateField(requestDto) ? requestDto : null;
@ -390,6 +401,8 @@ public class ProjectInfoServiceImpl implements IProjectInfoService {
return StringUtils.isNotEmpty(requestDto.getOpportunityName())
|| StringUtils.isNotEmpty(requestDto.getOperatorName())
|| requestDto.getAmount() != null
|| requestDto.getActualSignedAmount() != null
|| requestDto.getIsPoc() != null
|| StringUtils.isNotEmpty(requestDto.getExpectedCloseDate())
|| StringUtils.isNotEmpty(requestDto.getConfidencePct())
|| StringUtils.isNotEmpty(requestDto.getStage())