Browse Source

[fix]

品质管理 退换货单
修改添加退换货单页面,修改表格定义,修改回调函数,新增插入表格新行函数,修改页面提交函数;
修改入库后退货确认供应商页面,新增是否退货供应商下拉框,修改提交函数,修改表格定义,添加供应商ID和名称下拉框初始化、监听函数;
修改入库前、后退换货品质报告显示效果;
修改入库前退换货确认供应商页面,新增下拉框,修改表格初始化方法及定义,供应商信息在子表中显示;
修改物料选择页面,去除单选限制,新增搜索栏;
修改新增退换货品质报告页面,去除行内编辑样式;
修改入库前、后退换货详情页面,修改表格字段;
修改退换货列表页面,添加列居中样式;
dev
王晓迪 2 months ago
parent
commit
7ff1af2c44
  1. 115
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/add.html
  2. 260
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterNoConfirmSupplier.html
  3. 20
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html
  4. 146
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/beforeHasConfirmSupplier.html
  5. 88
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/beforeQualityReportDetail.html
  6. 35
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/materialSelect.html
  7. 10
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/qualityOrderReport.html
  8. 14
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/refundsExchanges.html
  9. 11
      ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html
  10. 51
      ruoyi-admin/src/main/resources/templates/warehouse/warehouseOutOrder/refundsExchangesOutWarehouse.html

115
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/add.html

@ -3,6 +3,7 @@
<head> <head>
<th:block th:include="include :: header('新增品质管理退换货单')" /> <th:block th:include="include :: header('新增品质管理退换货单')" />
<th:block th:include="include :: datetimepicker-css" /> <th:block th:include="include :: datetimepicker-css" />
<th:block th:include="include :: bootstrap-editable-css" />
</head> </head>
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
@ -85,15 +86,32 @@
// ...其他字段 // ...其他字段
}; };
}); });
var hasNull = false;
var hasReportNull = false;
materialDataList.forEach(function (material){ materialDataList.forEach(function (material){
var key = 'unqualifiedDataList' + material.materialNo; var key = 'unqualifiedDataList' + material.materialNo;
var dataString = sessionStorage.getItem(key); var dataString = sessionStorage.getItem(key);
if(dataString === ''|| dataString === null || dataString === undefined){
hasReportNull = true;
}
if(dataString){ if(dataString){
var refundsExchangesUnqualifieds = JSON.parse(dataString); var refundsExchangesUnqualifieds = JSON.parse(dataString);
material.refundsExchangesUnqualifieds = refundsExchangesUnqualifieds; material.refundsExchangesUnqualifieds = refundsExchangesUnqualifieds;
};
if(material.refundsExchangesNum === ''||material.refundsExchangesNum === null
|| material.refundsExchangesNum === undefined){
hasNull = true;
} }
}) });
if(hasReportNull){
$.modal.msgError("存在品质报告为空,请检查!");
return;
}
if(hasNull){
$.modal.msgError("退换货数不能为空!");
return;
}
// 将全局变量 refundsExchangesCode 添加到要提交的数据中 // 将全局变量 refundsExchangesCode 添加到要提交的数据中
const combinedData = Object.assign({}, refundsExchangesData, { const combinedData = Object.assign({}, refundsExchangesData, {
refundsExchangesDetails: materialDataList, refundsExchangesDetails: materialDataList,
@ -125,9 +143,7 @@
showToggle: false, showToggle: false,
showColumns: false, showColumns: false,
pagination: false, // 设置不分页 pagination: false, // 设置不分页
columns: [{ columns: [
checkbox: true
},
{ {
title: '退换货单号', title: '退换货单号',
field: 'refundsExchangesCode', field: 'refundsExchangesCode',
@ -137,9 +153,11 @@
{ {
title: '料号', title: '料号',
field: 'materialNo', field: 'materialNo',
align: 'center',
}, },
{ {
title: '图片', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.imageView(value); return $.table.imageView(value);
@ -147,29 +165,41 @@
}, },
{ {
title: '物料名称', title: '物料名称',
align: 'center',
field: 'materialName', field: 'materialName',
}, },
{ {
title: '物料类型', title: '物料类型',
align: 'center',
field: 'materialType', field: 'materialType',
visible: false,
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value); return $.table.selectCategoryLabel(materialTypeDatas, value);
} }
}, },
{
title: '型号',
align: 'center',
field: 'materialModel',
},
{ {
title: '描述', title: '描述',
align: 'center',
field: 'materialDescribe', field: 'materialDescribe',
}, },
{ {
title: '品牌', title: '品牌',
align: 'center',
field: 'materialBrand', field: 'materialBrand',
}, },
{ {
title: '单位', title: '单位',
align: 'center',
field: 'materialUnit', field: 'materialUnit',
}, },
{ {
title: '物料加工方式', title: '加工方式',
align: 'center',
field: 'materialProcessMethod', field: 'materialProcessMethod',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value); return $.table.selectDictLabel(processMethodDatas, value);
@ -187,7 +217,23 @@
}, },
{ {
title: '退换数', title: '退换数',
align: 'center',
field: 'refundsExchangesNum', field: 'refundsExchangesNum',
formatter: function(value, row, index) {
if(value == null || value == undefined){
return '';
}
return value;
},
editable: {
type: 'text',
validate: function (v,row) {
if (!v) return '数量不能为空';
if (isNaN(v)) return '数量必须是数字';
var actualOutOrderSum = parseInt(v);
if (actualOutOrderSum <= 0) return '数量必须是正整数';
}
}
}, },
{ {
title: '是否含品质报告数据', title: '是否含品质报告数据',
@ -221,29 +267,46 @@
function doSubmit(index, layero,uniqueId){ function doSubmit(index, layero,uniqueId){
console.log(uniqueId);
var iframeWin = window[layero.find('iframe')[0]['name']]; var iframeWin = window[layero.find('iframe')[0]['name']];
var rowData = iframeWin.$('#bootstrap-materialSelect-table').bootstrapTable('getSelections')[0]; var rowData = iframeWin.$('#bootstrap-materialSelect-table').bootstrapTable('getSelections');
console.log("rowData: "+rowData); //判断是否重复
$("#bootstrap-table").bootstrapTable('insertRow', { var data = $("#bootstrap-table").bootstrapTable('getData');
index:1, var rows = data.length;
row: { if(rows>0){
materialNo:rowData.materialNo, for(var i=0;i<rows;i++){
materialPhotourl:rowData.materialPhotourl, for(var j=0;j<rowData.length;j++){
materialName: rowData.materialName, if(data[i].materialNo===rowData[j].materialNo){
materialType: rowData.materialType, $.modal.alertError("不能选择已添加过的相同物料");
materialDescribe: rowData.describe, rowData.split(j,1);
materialBrand: rowData.brand, break;
materialUnit: rowData.unit, }
materialProcessMethod: rowData.processMethod, }
makeTotal:rowData.makeTotal, };
refundsExchangesNum: '', }
hasQualifiedReport: 0, for(i=0;i<rowData.length;i++){
} insertTable(rowData[i]);
}) }
layer.close(index); layer.close(index);
} }
function insertTable(rowData){
var newRow = {
materialNo:rowData.materialNo,
materialPhotourl:rowData.materialPhotourl,
materialName: rowData.materialName,
materialType: rowData.materialType,
materialModel: rowData.materialModel,
materialDescribe: rowData.describe,
materialBrand: rowData.brand,
materialUnit: rowData.unit,
materialProcessMethod: rowData.processMethod,
makeTotal:rowData.makeTotal,
refundsExchangesNum: '',
hasQualifiedReport: 0,
};
$("#bootstrap-table").bootstrapTable('append', newRow);
}
// 逻辑删除前端的一行数据 // 逻辑删除前端的一行数据
function removeRow(materialNo){ function removeRow(materialNo){
$("#bootstrap-table").bootstrapTable('remove', { $("#bootstrap-table").bootstrapTable('remove', {
@ -317,7 +380,7 @@
refundsExchangesNum: refundsExchangesNum, refundsExchangesNum: refundsExchangesNum,
hasQualifiedReport: '1' hasQualifiedReport: '1'
}; };
updateRowByMaterialNo(materialNo,newData); // updateRowByMaterialNo(materialNo,newData);
layer.close(index); layer.close(index);
} }

260
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterNoConfirmSupplier.html

@ -11,7 +11,7 @@
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">退换货单号:</label> <label class="col-sm-3 control-label">退换货单号:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="refundsExchangesCode" th:field="*{refundsExchangesCode}" class="form-control" type="text" disabled> <input name="refundsExchangesCode" th:field="*{refundsExchangesCode}" class="form-control" type="text" readonly>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -25,7 +25,15 @@
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">品质备注:</label> <label class="col-sm-3 control-label">品质备注:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="qualityRemark" th:field="*{qualityRemark}" class="form-control" type="text" disabled> <input name="qualityRemark" th:field="*{qualityRemark}" class="form-control" type="text" readonly>
</div>
</div>
<div class="form-group">
<label class="col-sm-3 control-label is-required">是否退回供应商:</label>
<div class="col-sm-8">
<select name="isReturnedToSupplier" id="isReturnedToSupplier" class="form-control m-b" th:with="type=${@dict.getType('yes_or_no')}" required>
<option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div> </div>
</div> </div>
</form> </form>
@ -48,6 +56,8 @@
var materialTypeDatas = [[${@category.getChildByCode('materialType')}]]; var materialTypeDatas = [[${@category.getChildByCode('materialType')}]];
var supplier = []; var supplier = [];
var supplierCodeList = [];
var supplierNameList = [];
var $table = $("#bootstrap-table"); var $table = $("#bootstrap-table");
var prefix = ctx + "quality/refundsExchanges"; var prefix = ctx + "quality/refundsExchanges";
@ -58,17 +68,17 @@
// 新增提交 // 新增提交
function submitHandler() { function submitHandler() {
$("input[name='refundsExchangesCode']").removeAttr("disabled"); var isReturnedToSupplier = $("#isReturnedToSupplier").val();
$("input[name='qualityRemark']").removeAttr("disabled"); if(isReturnedToSupplier === ''||isReturnedToSupplier === null||isReturnedToSupplier === undefined){
$.modal.msgError("请选择是否退回供应商");
return;
}
const afterNoConfirmSupplierData = $("#form-afterNoConfirmSupplier-edit").serializeArray().reduce((obj, item) => { const afterNoConfirmSupplierData = $("#form-afterNoConfirmSupplier-edit").serializeArray().reduce((obj, item) => {
obj[item.name] = item.value; obj[item.name] = item.value;
return obj; return obj;
}, {}); }, {});
// 获取bootstrap-table的数据,这里假设你使用bootstrap-table的API获取所有数据
var table = $('#bootstrap-table').bootstrapTable('getData'); var table = $('#bootstrap-table').bootstrapTable('getData');
// 将表数据转换成与afterNoConfirmSupplierData格式一致的数组
var materialDataList = table.map(function(item) { var materialDataList = table.map(function(item) {
// 根据实际字段名调整 // 根据实际字段名调整
return { return {
@ -79,6 +89,8 @@
"materialType": item.materialType, "materialType": item.materialType,
"materialUnit": item.materialUnit, "materialUnit": item.materialUnit,
"materialBrand": item.materialBrand, "materialBrand": item.materialBrand,
"materialModel": item.materialModel,
"materialProcessMethod": item.materialProcessMethod,
"materialDescribe": item.materialDescribe, "materialDescribe": item.materialDescribe,
"makeTotal":item.makeTotal, "makeTotal":item.makeTotal,
"qualityHasqualifiedNum":item.qualityHasqualifiedNum, "qualityHasqualifiedNum":item.qualityHasqualifiedNum,
@ -93,8 +105,18 @@
}; };
}); });
// 合并表单数据和表格数据 if(isReturnedToSupplier === "1"){
//const combinedData = Object.assign({}, ...afterNoConfirmSupplierData.map(item => ({ [item.name]: item.value })), ...materialData); var supplierNull = false;
materialDataList.forEach(function (data){
if(data.supplierCode === ''|| data.supplierCode === null ||data.supplierCode === undefined){
supplierNull = true;
}
});
if(supplierNull){
$.modal.msgError("存在供应商信息为空,请选择");
return;
}
}
const combinedData = Object.assign({}, afterNoConfirmSupplierData, { refundsExchangesDetails: materialDataList }); const combinedData = Object.assign({}, afterNoConfirmSupplierData, { refundsExchangesDetails: materialDataList });
console.log(combinedData) console.log(combinedData)
@ -116,9 +138,7 @@
pagination: false, // 设置不分页 pagination: false, // 设置不分页
queryParams: queryParams, queryParams: queryParams,
modalName: "选择物料", modalName: "选择物料",
columns: [{ columns: [
checkbox: true
},
{ {
title: '退换货详情Id', title: '退换货详情Id',
field: 'refundsExchangesDetailId', field: 'refundsExchangesDetailId',
@ -131,10 +151,12 @@
}, },
{ {
title: '料号', title: '料号',
field: 'materialNo' field: 'materialNo',
align: 'center',
}, },
{ {
title: '图片', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.imageView(value); return $.table.imageView(value);
@ -142,49 +164,45 @@
}, },
{ {
title: '物料名称', title: '物料名称',
align: 'center',
field: 'materialName' field: 'materialName'
}, },
// {
// title: '物料类型',
// align: 'center',
// field: 'materialType',
// formatter: function(value, row, index) {
// return $.table.selectCategoryLabel(materialTypeDatas, value);
// }
// },
{ {
title: '物料类型', title: '描述',
field: 'materialType', align: 'center',
formatter: function(value, row, index) { field: 'materialDescribe',
return $.table.selectCategoryLabel(materialTypeDatas, value);
}
}, },
{ {
title: '物料描述', title: '型号',
field: 'materialDescribe', align: 'center',
field: 'materialModel',
}, },
{ {
title: '品牌', title: '品牌',
align: 'center',
field: 'materialBrand', field: 'materialBrand',
}, },
{ {
title: '单位', title: '单位',
align: 'center',
field: 'materialUnit', field: 'materialUnit',
}, },
{ {
title: '加工方式', title: '加工方式',
align: 'center',
field: 'materialProcessMethod', field: 'materialProcessMethod',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value); return $.table.selectDictLabel(processMethodDatas, value);
} }
}, },
{
title: '订单数',
field: 'makeTotal',
visible: false
},
{
title: '品质已合格数',
field: 'qualityHasqualifiedNum',
visible: false
},
{
title: '本次到货数',
field: 'thisArrivedNum',
visible: false
},
{ {
title: '品质报告', title: '品质报告',
align: 'center', align: 'center',
@ -196,33 +214,40 @@
}, },
{ {
title: '品质不合格数', title: '品质不合格数',
align: 'center',
field: 'qualityUnqualifiedNum', field: 'qualityUnqualifiedNum',
}, },
{title: '选择供应商ID',field: 'supplierCode', {
title: '供应商ID',field: 'supplierCode',
align: 'center',
formatter:function (value, row, index) { formatter:function (value, row, index) {
return supplierCodeAsyncFormatter(value,row,index); return supplierCodeFormatter(value,row,index);
} }
}, },
{title: '选择供应商名称',field: 'supplierName', {title: '供应商名称',field: 'supplierName',
formatter:function(value, row, index){ formatter:function(value, row, index){
return getSupplierNameType(value,row,index) return supplierNameFormatter(value,row,index);
} }
}, },
{ {
title: '退货联系人', title: '退货联系人',
field: 'customerContact', field: 'customerContact',
align: 'center',
}, },
{ {
title: '联系人电话', title: '联系人电话',
field: 'contactNumber', field: 'contactNumber',
align: 'center',
}, },
{ {
title: '退货地址', title: '退货地址',
field: 'supplierAddress', field: 'supplierAddress',
align: 'center',
} }
] ]
}; };
$.table.init(options); $.table.init(options);
loadSupplierCodes();
}) })
function queryParams(params) { function queryParams(params) {
@ -235,93 +260,110 @@
} }
// 自定义供应商代码列的格式化函数,异步获取供应商代码
function supplierCodeAsyncFormatter(value, row, index) {
var selectHtml = '<select class="form-control supplier-code" onchange="supplierCodeChange(this, ' + index + ')">';
// 先不填充,等待ajax获取数据
selectHtml += '</select>';
loadSupplierCodes(selectHtml, index); // 异步加载供应商代码
return selectHtml;
}
// 加载供应商代码的函数 // 加载供应商代码的函数
function loadSupplierCodes(selectHtml, index) { function loadSupplierCodes() {
$.ajax({ $.ajax({
url: ctx + 'system/supplier/getSupplierCodes', // 获取所有供应商代码 url: ctx + 'system/supplier/matchSupplierList', // 获取所有供应商代码
type: 'POST', type: 'POST',
dataType: 'json', dataType: 'json',
success: function (codes) { success: function (result) {
var selectElement = $('.supplier-code:eq(' + index + ')'); var supplierList = result.data;
codes.forEach(function (code) { supplierList.forEach(function (data){
selectElement.append('<option value="' + code.supplierCode + '">' + code.supplierCode + '</option>'); supplierCodeList.push(data.supplierCode);
supplierNameList.push(data.supplierName);
}); });
supplier = codes;
// 设置默认值(如果存在)
var rowData = $table.bootstrapTable('getData')[index];
if (rowData && rowData.supplierCode) {
selectElement.val(rowData.supplierCode);
}
} }
}); });
} }
//自定义供应商编号的初始化函数
// 列中获取成本类型的下拉改变数据 function supplierCodeFormatter(value, row, index){
function supplierCodeChange(selectElement, rowIndex) { var selectHtml = `<select class="form-control" style="width: 120px;" onchange="onSupplierCodeChange(this, ${index})">`;
var newSupplierCode = $(selectElement).val(); selectHtml += '<option value=""' + (value === undefined || value === '' ? ' selected' : '') + '>所有</option>';
var tableData = $table.bootstrapTable('getData'); supplierCodeList.forEach(function (child) {
var newRow = tableData[rowIndex]; selectHtml += '<option value="' + child + '"' + (value === child ? ' selected' : '') + '>' + child + '</option>';
newRow.supplierCode = newSupplierCode;
supplier.forEach(function (index){
if(index.supplierCode === newSupplierCode){
newRow.supplierName = index.supplierName;
newRow.customerContact = index.customerContact;
newRow.contactNumber = index.contactNumber;
newRow.supplierAddress = index.customerAddress;
}
}); });
// getSupplierNameType(newRow.supplierCode,newRow,rowIndex); selectHtml += '</select>';
$table.bootstrapTable('updateRow', {index: rowIndex, row: newRow}); return selectHtml;
} }
function getSupplierNameType(value, row, index) { function onSupplierCodeChange(selectElement, rowIndex) {
var selectHtml = '<select class="form-control" onchange="onSupplierNameChange(this, ' + index + ')">'; var supplierCodeValue = $(selectElement).val();
// 假设此函数根据供应商ID返回设备列表 if (supplierCodeValue) {
var supplierNames = []; $.ajax({
$.ajax({ url: ctx + 'system/supplier/getSelectSupplier',
url: ctx + 'system/supplier/getSupplierName', method: 'GET',
type: 'post', dataType: 'json',
data: {supplierCode: row.supplierCode}, data:{supplierCode: supplierCodeValue},
async: false, success: function(response) {
success: function (result) { if (response.data) {
console.log(result); var newData = response.data;
supplierNames = result; var newRowData = {
} supplierCode : supplierCodeValue,
}); supplierName : newData.supplierName,
if (supplierNames) { customerContact : newData.customerContact,
supplierNames.forEach(function (child) { contactNumber : newData.contactNumber,
selectHtml += '<option value="' + child.supplierCode + '"' + (value === child.supplierCode ? ' selected' : '') + '>' + child.supplierName + '</option>'; supplierAddress : newData.customerAddress,
};
$('#bootstrap-table').bootstrapTable('updateRow', {
index: rowIndex, // 使用传递进来的索引
row: newRowData
});
} else {
console.error('后端请求数据为空');
}
},
error: function(xhr, status, error) {
console.error('请求出错:', status, ", ", error);
}
}); });
selectHtml += '</select>';
return selectHtml;
} }
} }
// 供应商名称改变时的处理函数
function onSupplierNameChange(selectElement, rowIndex) { //自定义供应商名称的初始化函数
var newSupplierName = $(selectElement).val(); function supplierNameFormatter(value, row, index){
var tableData = $table.bootstrapTable('getData'); var selectHtml = `<select class="form-control" style="width: 120px;" onchange="onSupplierNameChange(this, ${index})">`;
var newRow = tableData[rowIndex]; // 获取当前行数据 selectHtml += '<option value=""' + (value === undefined || value === '' ? ' selected' : '') + '>所有</option>';
newRow.supplierName = newSupplierName; supplierNameList.forEach(function (child) {
supplier.forEach(function (index){ selectHtml += '<option value="' + child + '"' + (value === child ? ' selected' : '') + '>' + child + '</option>';
if(index.supplierName === newSupplierName){
newRow.customerContact = index.customerContact;
newRow.contactNumber = index.contactNumber;
newRow.supplierAddress = index.customerAddress;
}
}); });
// 更新行数据 selectHtml += '</select>';
$table.bootstrapTable('updateRow', {index: rowIndex, row: newRow}); return selectHtml;
}
function onSupplierNameChange(selectElement, rowIndex) {
var supplierNameValue = $(selectElement).val();
console.log(supplierNameValue);
if (supplierNameValue) {
$.ajax({
url: ctx + 'system/supplier/getSelectSupplier',
method: 'GET',
dataType: 'json',
data:{supplierName: supplierNameValue},
success: function(response) {
console.log(response);
if (response.data) {
var newData = response.data;
var newRowData = {
supplierName : supplierNameValue,
supplierCode : newData.supplierCode,
customerContact : newData.customerContact,
contactNumber : newData.contactNumber,
supplierAddress : newData.customerAddress,
};
$('#bootstrap-table').bootstrapTable('updateRow', {
index: rowIndex, // 使用传递进来的索引
row: newRowData
});
} else {
console.error('后端请求数据为空');
}
},
error: function(xhr, status, error) {
console.error('请求出错:', status, ", ", error);
}
});
}
} }
function qualityReport(materialNo, refundsExchangesCode) { function qualityReport(materialNo, refundsExchangesCode) {

20
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/afterQualityReportDetail.html

@ -1,7 +1,7 @@
<!DOCTYPE html> <!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: header('修改品质管理退换货报告')" /> <th:block th:include="include :: header('品质管理退换货报告')" />
<th:block th:include="include :: datetimepicker-css" /> <th:block th:include="include :: datetimepicker-css" />
</head> </head>
<body class="white-bg"> <body class="white-bg">
@ -26,8 +26,8 @@
</div> </div>
<!--其他字段--> <!--其他字段-->
<div class="form-group"> <div class="form-group" style="padding-top: 20px;">
<label class="col-sm-3 control-label">交付质检时间:</label> <label class="col-sm-3 control-label">验完成时间:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<div class="input-group date"> <div class="input-group date">
<input name="inspectionTime" th:value="${#dates.format(qualityRefundsExchangesDetail.inspectionTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text"> <input name="inspectionTime" th:value="${#dates.format(qualityRefundsExchangesDetail.inspectionTime, 'yyyy-MM-dd')}" class="form-control" placeholder="yyyy-MM-dd" type="text">
@ -35,10 +35,10 @@
</div> </div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group" style="padding-top: 20px;">
<label class="col-sm-3 control-label">备注:</label> <label class="col-sm-3 control-label">备注:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="remark" th:field="*{remark}" class="form-control" type="text"> <textarea name="remark" th:text="*{remark}" class="form-control" type="text"></textarea>
</div> </div>
</div> </div>
</form> </form>
@ -115,11 +115,11 @@
title: '报告', title: '报告',
field: 'unqualifiedReportUrl', field: 'unqualifiedReportUrl',
align: 'center', align: 'center',
formatter: function(value, row, index) { // formatter: function(value, row, index) {
var actions = []; // var actions = [];
actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" >报告</a> '); // actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" >报告</a> ');
return actions.join(''); // return actions.join('');
} // }
}, },
] ]
}; };

146
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/beforeHasConfirmSupplier.html

@ -3,22 +3,7 @@
<head> <head>
<th:block th:include="include :: header('入库前退货-采购-确认供应商-已有供应商')" /> <th:block th:include="include :: header('入库前退货-采购-确认供应商-已有供应商')" />
<th:block th:include="include :: datetimepicker-css" /> <th:block th:include="include :: datetimepicker-css" />
<style> <th:block th:include="include :: bootstrap-editable-css" />
.supplier-value {
display: flex;
align-items: center;
justify-content: space-between;
}
.supplier-value span {
margin-right: 10px;
}
.info-separator::after {
content: "-";
margin: 0 5px;
}
</style>
</head> </head>
<body class="white-bg"> <body class="white-bg">
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> <div class="wrapper wrapper-content animated fadeInRight ibox-content">
@ -27,7 +12,7 @@
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">退换货单号:</label> <label class="col-sm-3 control-label">退换货单号:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="refundsExchangesCode" th:field="*{refundsExchangesCode}" class="form-control" type="text" disabled> <input name="refundsExchangesCode" id="refundsExchangesCode" th:field="*{refundsExchangesCode}" class="form-control" type="text" disabled>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -44,12 +29,20 @@
</select> </select>
</div> </div>
</div> </div>
<div class="container">
<!--物料相关--> <div class="form-group">
<div class="row"> <label class="col-sm-3 control-label is-required">是否退回供应商:</label>
<div class="col-sm-12" id="tablesContainer"> <div class="col-sm-8">
<!-- 表格将在这里动态生成 --> <select name="isReturnedToSupplier" id="isReturnedToSupplier" class="form-control m-b" th:with="type=${@dict.getType('yes_or_no')}" required>
</div> <option th:each="dict : ${type}" th:text="${dict.dictLabel}" th:value="${dict.dictValue}"></option>
</select>
</div>
</div>
<!--物料信息-->
<div class="row" style="padding-left: 40px;">
<div class="col-sm-12 select-table table-striped">
<table id="bootstrap-table"></table>
</div> </div>
</div> </div>
</form> </form>
@ -75,6 +68,12 @@
var refundsExchangesId = $("input[name='refundsExchangesId']").val(); var refundsExchangesId = $("input[name='refundsExchangesId']").val();
var qualityRefundsExchanges = { var qualityRefundsExchanges = {
refundsExchangesId: refundsExchangesId, refundsExchangesId: refundsExchangesId,
isReturnedToSupplier: $("#isReturnedToSupplier").val(),
}
if(qualityRefundsExchanges.isReturnedToSupplier === '' || qualityRefundsExchanges.isReturnedToSupplier === null
|| qualityRefundsExchanges.isReturnedToSupplier === undefined){
$.modal.msgError("请选择是否退回给供应商");
return;
} }
$.operate.saveJson(prefix + "/beforeHasConfirmSupplier",JSON.stringify(qualityRefundsExchanges)); $.operate.saveJson(prefix + "/beforeHasConfirmSupplier",JSON.stringify(qualityRefundsExchanges));
} }
@ -82,50 +81,26 @@
$(function() { $(function() {
// 假设refundsExchangesCode已经定义或者可以通过某种方式获取到 var options = {
var refundsExchangesCode = [[${qualityRefundsExchanges.refundsExchangesCode}]]; // 这里需要实际赋值,比如从前端某个地方读取 modalName: "物料信息",
url: prefix + "/getMaterialListByRefundsExchangesCode",
$.getJSON(prefix + "/detailListGroupedBySupplier?refundsExchangesCode=" + refundsExchangesCode, function(data) { queryParams:
for (var supplierCode in data) {
if (data.hasOwnProperty(supplierCode)) {
var supplierData = data[supplierCode];
createTableForSupplier(supplierCode, supplierData);
}
}
});
});
function createTableForSupplier(supplierCode, supplierData) {
var tableId = 'bootstrap-table-' + supplierCode.replace(/[^a-z0-9]/gi, '_').toLowerCase();
var $tableWrapper = $('<div class="table-responsive mt-3"></div>');
// 确保supplierData至少有一条记录,并从中提取供应商详细信息
var supplierInfo = supplierData.length > 0 ? supplierData[0] : {}; // 默认为空对象,以防数据不存在
// 构建含有额外供应商信息的标题字符串
var headerTitle ='供应商'+'</br>'+supplierCode + ' - ' + (supplierInfo.supplierName || 'N/A') +
' </br> ' + (supplierInfo.customerContact || 'N/A') +
' - ' + (supplierInfo.contactNumber || 'N/A') +
' - ' + (supplierInfo.supplierAddress || 'N/A');
var $header = $('<h4>' + headerTitle + '</h4>');
var $table = $('<table id="' + tableId + '" class="table table-striped table-bordered"></table>');
$table.bootstrapTable({
data: supplierData,
columns: [{
checkbox: true
},
{ {
title: '供应商ID', refundsExchangesCode: $("#refundsExchangesCode").val(),
field: 'supplierCode',
visible: false
}, },
showSearch: false,
showRefresh: false,
showToggle: false,
showColumns: false,
pagination: false, // 设置不分页
columns: [
{ {
title: '料号', title: '料号',
align: 'center',
field: 'materialNo' field: 'materialNo'
}, { }, {
title: '物料名称', title: '物料名称',
align: 'center',
field: 'materialName' field: 'materialName'
}, },
{ {
@ -137,23 +112,27 @@
} }
}, },
{ {
title: '物料图片地址', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
}, },
{ {
title: '物料描述', title: '描述',
align: 'center',
field: 'materialDescribe', field: 'materialDescribe',
}, },
{ {
title: '物料品牌', title: '品牌',
align: 'center',
field: 'materialBrand', field: 'materialBrand',
}, },
{ {
title: '物料单位', title: '单位',
align: 'center',
field: 'materialUnit', field: 'materialUnit',
}, },
{ {
title: '物料加工方式', title: '加工方式',
field: 'materialProcessMethod', field: 'materialProcessMethod',
align: 'center', align: 'center',
formatter: function(value, row, index) { formatter: function(value, row, index) {
@ -172,13 +151,38 @@
}, },
{ {
title: '品质不合格数', title: '品质不合格数',
align: 'center',
field: 'qualityUnqualifiedNum', field: 'qualityUnqualifiedNum',
}] },
}); {
title: '供应商ID',
$tableWrapper.append($header).append($table); align: 'center',
$('#tablesContainer').append($tableWrapper); field: 'supplierCode',
} },
{
title: '供应商名称',
align: 'center',
field: 'supplierName',
},
{
title: '联系人',
align: 'center',
field: 'customerContact',
},
{
title: '联系人电话',
align: 'center',
field: 'contactNumber',
},
{
title: '联系人地址',
align: 'center',
field: 'supplierAddress',
},
],
};
$.table.init(options);
});
/*品质报告*/ /*品质报告*/

88
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/beforeQualityReportDetail.html

@ -26,47 +26,47 @@
<input name="materialName" th:field="*{materialName}" class="form-control" type="text" disabled> <input name="materialName" th:field="*{materialName}" class="form-control" type="text" disabled>
</div> </div>
</div> </div>
<div class="form-group"> <!-- <div class="form-group">-->
<label class="col-sm-3 control-label">订单数:</label> <!-- <label class="col-sm-3 control-label">订单数:</label>-->
<div class="col-sm-6"> <!-- <div class="col-sm-6">-->
<input name="makeTotal" th:field="*{makeTotal}" class="form-control" type="text" disabled> <!-- <input name="makeTotal" th:field="*{makeTotal}" class="form-control" type="text" disabled>-->
</div> <!-- </div>-->
</div> <!-- </div>-->
<div class="form-group"> <!-- <div class="form-group">-->
<label class="col-sm-3 control-label">品质已合格数:</label> <!-- <label class="col-sm-3 control-label">品质已合格数:</label>-->
<div class="col-sm-6"> <!-- <div class="col-sm-6">-->
<input name="qualityHasqualifiedNum" th:field="*{qualityHasqualifiedNum}" class="form-control" type="text" disabled> <!-- <input name="qualityHasqualifiedNum" th:field="*{qualityHasqualifiedNum}" class="form-control" type="text" disabled>-->
</div> <!-- </div>-->
</div> <!-- </div>-->
<div class="container"> <div class="container">
<!--合格数--> <!--合格数-->
<div class="col-sm-12"> <!-- <div class="col-sm-12">-->
<h3>合格数</h3> <!-- <h3>合格数</h3>-->
<div class="row"> <!-- <div class="row">-->
<div class="form-group col-sm-6"> <!-- <div class="form-group col-sm-6">-->
<label class="control-label">ok允收数:</label> <!-- <label class="control-label">ok允收数:</label>-->
<input name="okAcceptedNum" th:field="*{okAcceptedNum}" class="form-control" type="text" disabled> <!-- <input name="okAcceptedNum" th:field="*{okAcceptedNum}" class="form-control" type="text" disabled>-->
</div> <!-- </div>-->
<div class="form-group col-sm-6 d-flex flex-column align-items-start"> <!-- <div class="form-group col-sm-6 d-flex flex-column align-items-start">-->
<label class="control-label">ok报告:</label> <!-- <label class="control-label">ok报告:</label>-->
<input name="okReportUrl" th:field="*{okReportUrl}" class="form-control" type="text" disabled> <!-- <input name="okReportUrl" th:field="*{okReportUrl}" class="form-control" type="text" disabled>-->
<!-- <a class= 'btn btn-success btn-xs' href='javascript:void(0)' >报告</a>--> <!--&lt;!&ndash; <a class= 'btn btn-success btn-xs' href='javascript:void(0)' >报告</a>&ndash;&gt;-->
</div> <!-- </div>-->
</div> <!-- </div>-->
<div class="row"> <!-- <div class="row">-->
<div class="form-group col-sm-6"> <!-- <div class="form-group col-sm-6">-->
<label class="control-label">特采/让步数</label> <!-- <label class="control-label">特采/让步数</label>-->
<input name="specialConcessionsNum" th:field="*{specialConcessionsNum}" class="form-control" type="text" disabled> <!-- <input name="specialConcessionsNum" th:field="*{specialConcessionsNum}" class="form-control" type="text" disabled>-->
</div> <!-- </div>-->
<div class="form-group col-sm-6"> <!-- <div class="form-group col-sm-6">-->
<label class="control-label">特采报告:</label> <!-- <label class="control-label">特采报告:</label>-->
<input name="specialReportUrl" th:field="*{specialReportUrl}" class="form-control" type="text" disabled> <!-- <input name="specialReportUrl" th:field="*{specialReportUrl}" class="form-control" type="text" disabled>-->
<!-- <a class= 'btn btn-success btn-xs' href='javascript:void(0)' >报告</a>--> <!--&lt;!&ndash; <a class= 'btn btn-success btn-xs' href='javascript:void(0)' >报告</a>&ndash;&gt;-->
</div> <!-- </div>-->
</div> <!-- </div>-->
</div> <!-- </div>-->
<!--不合格数--> <!--不合格数-->
<div class="col-sm-12"> <div class="col-sm-12">
<div class="row"> <div class="row">
@ -84,7 +84,7 @@
</div> </div>
<!--其他字段--> <!--其他字段-->
<div class="form-group"> <div class="form-group" style="padding-top: 20px;">
<label class="col-sm-4 control-label">检验完成时间:</label> <label class="col-sm-4 control-label">检验完成时间:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<div class="input-group date"> <div class="input-group date">
@ -93,7 +93,7 @@
</div> </div>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group" style="padding-top: 20px;">
<label class="col-sm-4 control-label">备注:</label> <label class="col-sm-4 control-label">备注:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<textarea name="remark" th:field="*{remark}" class="form-control" type="text"></textarea> <textarea name="remark" th:field="*{remark}" class="form-control" type="text"></textarea>
@ -165,11 +165,11 @@
title: '报告', title: '报告',
field: 'unqualifiedReportUrl', field: 'unqualifiedReportUrl',
align: 'center', align: 'center',
formatter: function(value, row, index) { // formatter: function(value, row, index) {
var actions = []; // var actions = [];
actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" >报告</a> '); // actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" >报告</a> ');
return actions.join(''); // return actions.join('');
} // }
}, },
] ]
}; };

35
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/materialSelect.html

@ -6,6 +6,27 @@
<body class="gray-bg"> <body class="gray-bg">
<div class="container-div"> <div class="container-div">
<div class="row"> <div class="row">
<div class="col-sm-12 search-collapse">
<form id="formId">
<div class="select-list">
<ul>
<li>
<label>料号:</label>
<input type="text" name="materialNo"/>
</li>
<li>
<label>物料名称:</label>
<input type="text" name="materialName"/>
</li>
<li>
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i>&nbsp;搜索</a>
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i>&nbsp;重置</a>
</li>
</ul>
</div>
</form>
</div>
<div class="col-sm-12 select-table table-striped"> <div class="col-sm-12 select-table table-striped">
<table id="bootstrap-materialSelect-table"></table> <table id="bootstrap-materialSelect-table"></table>
</div> </div>
@ -25,7 +46,6 @@
var options = { var options = {
id: 'bootstrap-materialSelect-table', id: 'bootstrap-materialSelect-table',
clickToSelect: true, // 点击选中行 clickToSelect: true, // 点击选中行
singleSelect: true, // 单选
showSearch: false, showSearch: false,
showRefresh: false, showRefresh: false,
showToggle: false, showToggle: false,
@ -39,9 +59,11 @@
{ {
title: '料号', title: '料号',
field: 'materialNo', field: 'materialNo',
align: 'center',
}, },
{ {
title: '图片', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.imageView(value); return $.table.imageView(value);
@ -50,28 +72,39 @@
}, },
{ {
title: '物料名称', title: '物料名称',
align: 'center',
field: 'materialName', field: 'materialName',
}, },
{ {
title: '类型', title: '类型',
align: 'center',
field: 'materialType', field: 'materialType',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value); return $.table.selectCategoryLabel(materialTypeDatas, value);
} }
}, },
{
title: '型号',
align: 'center',
field: 'materialModel',
},
{ {
title: '描述', title: '描述',
align: 'center',
field: 'describe', field: 'describe',
}, },
{ {
title: '品牌', title: '品牌',
align: 'center',
field: 'brand', field: 'brand',
}, },
{ {
title: '单位', title: '单位',
align: 'center',
field: 'unit', field: 'unit',
}, },
{ title: '加工方式', { title: '加工方式',
align: 'center',
field: 'processMethod', field: 'processMethod',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value); return $.table.selectDictLabel(processMethodDatas, value);

10
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/qualityOrderReport.html

@ -2,6 +2,7 @@
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > <html lang="zh" xmlns:th="http://www.thymeleaf.org" >
<head> <head>
<th:block th:include="include :: header('修改品质管理退换货报告')" /> <th:block th:include="include :: header('修改品质管理退换货报告')" />
<th:block th:include="include :: bootstrap-editable-css" />
<th:block th:include="include :: datetimepicker-css" /> <th:block th:include="include :: datetimepicker-css" />
</head> </head>
<body class="white-bg"> <body class="white-bg">
@ -170,7 +171,6 @@
align: 'center', align: 'center',
editable:{ editable:{
type: 'text', type: 'text',
mode:'inline',
validate: function (v) { validate: function (v) {
if (!v) return '数量不能为空'; if (!v) return '数量不能为空';
if (isNaN(v)) return '数量必须是数字'; if (isNaN(v)) return '数量必须是数字';
@ -183,11 +183,9 @@
title: '报告', title: '报告',
field: 'unqualifiedReportUrl', field: 'unqualifiedReportUrl',
align: 'center', align: 'center',
formatter: function(value, row, index) { editable: {
var actions = []; type: 'text', // 表示该列可以被编辑为文本
actions.push('<a class="btn btn-success btn-xs" href="javascript:void(0)" ><i class="fa fa-plus"></i>上传</a> '); },
return actions.join('');
}
}, },
{ {
title: '操作', title: '操作',

14
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/refundsExchanges.html

@ -117,9 +117,11 @@
{ {
title: '退换货单号', title: '退换货单号',
field: 'refundsExchangesCode', field: 'refundsExchangesCode',
align: 'center',
}, },
{ {
title: '退换货状态', title: '退换货状态',
align: 'center',
field: 'refundsExchangesStatus', field: 'refundsExchangesStatus',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(refundsExchangesStatusDatas, value); return $.table.selectDictLabel(refundsExchangesStatusDatas, value);
@ -127,6 +129,7 @@
}, },
{ {
title: '仓库状态', title: '仓库状态',
align: 'center',
field: 'qualityWarehouseStatus', field: 'qualityWarehouseStatus',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(qualityWarehouseStatusDatas, value); return $.table.selectDictLabel(qualityWarehouseStatusDatas, value);
@ -134,6 +137,7 @@
}, },
{ {
title: '采购状态', title: '采购状态',
align: 'center',
field: 'qualityPurchaseStatus', field: 'qualityPurchaseStatus',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(qualityPurchaseStatusDatas, value); return $.table.selectDictLabel(qualityPurchaseStatusDatas, value);
@ -141,10 +145,12 @@
}, },
{ {
title: '关联单号', title: '关联单号',
align: 'center',
field: 'relatedOrderCode', field: 'relatedOrderCode',
}, },
{ {
title: '退货节点', title: '退货节点',
align: 'center',
field: 'qualityReturnNode', field: 'qualityReturnNode',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(qualityReturnNodeDatas, value); return $.table.selectDictLabel(qualityReturnNodeDatas, value);
@ -152,6 +158,7 @@
}, },
{ {
title: '物料合计', title: '物料合计',
align: 'center',
field: 'materialTotal', field: 'materialTotal',
footerFormatter: function (value) { footerFormatter: function (value) {
var sum = 0; var sum = 0;
@ -163,6 +170,7 @@
}, },
{ {
title: '数量合计', title: '数量合计',
align: 'center',
field: 'numTotal', field: 'numTotal',
footerFormatter: function (value) { footerFormatter: function (value) {
var sum = 0; var sum = 0;
@ -179,18 +187,22 @@
}, },
{ {
title: '录入人', title: '录入人',
align: 'center',
field: 'createBy', field: 'createBy',
}, },
{ {
title: '录入时间', title: '录入时间',
align: 'center',
field: 'createTime', field: 'createTime',
}, },
{ {
title: '更新人', title: '更新人',
align: 'center',
field: 'updateBy', field: 'updateBy',
}, },
{ {
title: '上次更新时间', title: '上次更新时间',
align: 'center',
field: 'updateTime', field: 'updateTime',
}, },
{ {
@ -211,7 +223,7 @@
actions.push('<a class=" ' + returnAfterStorageDetailFlag + '" href="javascript:void(0)" onclick="returnAfterStorageDetail(\'' + row.refundsExchangesId + '\')"><i class="fa fa-edit"></i>详情</a> '); actions.push('<a class=" ' + returnAfterStorageDetailFlag + '" href="javascript:void(0)" onclick="returnAfterStorageDetail(\'' + row.refundsExchangesId + '\')"><i class="fa fa-edit"></i>详情</a> ');
} }
/*入库前退换货-确认供应商-已有供应商*/ /*入库前退换货-确认供应商-已有供应商*/
if (row.qualityReturnNode == 0 && row.qualityPurchaseStatus == 0 && row.qualityWarehouseStatus == 1){ if (row.qualityReturnNode == 0 && row.qualityPurchaseStatus == 0 ){
actions.push('<a class=" ' + beforeHasConfirmSupplierFlag + '" href="javascript:void(0)" onclick="beforeHasConfirmSupplier(\'' + row.refundsExchangesId + '\')"><i class="fa fa-edit"></i>确认供应商</a> '); actions.push('<a class=" ' + beforeHasConfirmSupplierFlag + '" href="javascript:void(0)" onclick="beforeHasConfirmSupplier(\'' + row.refundsExchangesId + '\')"><i class="fa fa-edit"></i>确认供应商</a> ');
} }
/*入库前退换货-确认收货-已有供应商*/ /*入库前退换货-确认收货-已有供应商*/

11
ruoyi-admin/src/main/resources/templates/quality/refundsExchanges/returnAfterStorageDetail.html

@ -119,9 +119,7 @@
showToggle: false, showToggle: false,
showColumns: false, showColumns: false,
pagination: false, // 设置不分页 pagination: false, // 设置不分页
columns: [{ columns: [
checkbox: true
},
{ {
title: '退换货单号', title: '退换货单号',
field: 'refundsExchangesCode', field: 'refundsExchangesCode',
@ -130,10 +128,12 @@
{ {
title: '料号', title: '料号',
align: 'center',
field: 'materialNo', field: 'materialNo',
}, },
{ {
title: '图片', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
}, },
{ {
@ -149,6 +149,11 @@
return $.table.selectCategoryLabel(materialTypeDatas, value); return $.table.selectCategoryLabel(materialTypeDatas, value);
} }
}, },
{
title: '物料型号',
field: 'materialModel',
align: 'center',
},
{ {
title: '描述', title: '描述',
field: 'materialDescribe', field: 'materialDescribe',

51
ruoyi-admin/src/main/resources/templates/warehouse/warehouseOutOrder/refundsExchangesOutWarehouse.html

@ -3,12 +3,11 @@
<head> <head>
<th:block th:include="include :: header('退换货-出库')" /> <th:block th:include="include :: header('退换货-出库')" />
<th:block th:include="include :: datetimepicker-css" /> <th:block th:include="include :: datetimepicker-css" />
<th:block th:include="include :: bootstrap-editable-css" />
<style> <style>
.supplier-value span { .supplier-value span {
margin-right: 10px; margin-right: 10px;
} }
</style> </style>
</head> </head>
<body class="white-bg"> <body class="white-bg">
@ -18,7 +17,7 @@
<div class="form-group"> <div class="form-group">
<label class="col-sm-3 control-label">出库单号:</label> <label class="col-sm-3 control-label">出库单号:</label>
<div class="col-sm-8"> <div class="col-sm-8">
<input name="outOrderCode" th:field="*{outOrderCode}" class="form-control" type="text" disabled> <input name="outOrderCode" th:field="*{outOrderCode}" class="form-control" type="text" readonly>
</div> </div>
</div> </div>
<div class="form-group"> <div class="form-group">
@ -142,9 +141,7 @@
$table.bootstrapTable({ $table.bootstrapTable({
data: supplierData, data: supplierData,
columns: [{ columns: [
checkbox: true
},
{ {
title: '出库单详情ID', title: '出库单详情ID',
field: 'outOrderDetailId', field: 'outOrderDetailId',
@ -159,58 +156,88 @@
{ {
title: '料号', title: '料号',
field: 'materialNo', field: 'materialNo',
align: 'center',
}, },
{ {
title: '图片', title: '图片',
align: 'center',
field: 'materialPhotourl', field: 'materialPhotourl',
}, },
{ {
title: '物料名称', title: '物料名称',
align: 'center',
field: 'materialName', field: 'materialName',
}, },
{ {
title: '物料类型', title: '物料类型',
align: 'center',
field: 'materialType', field: 'materialType',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectCategoryLabel(materialTypeDatas, value); return $.table.selectCategoryLabel(materialTypeDatas, value);
} }
}, },
{
title: '型号',
align: 'center',
field: 'materialModel',
},
{ {
title: '描述', title: '描述',
align: 'center',
field: 'materialDescribe', field: 'materialDescribe',
}, },
{ {
title: '品牌', title: '品牌',
align: 'center',
field: 'materialBrand', field: 'materialBrand',
}, },
{ {
title: '单位', title: '单位',
align: 'center',
field: 'materialUnit', field: 'materialUnit',
}, },
{ {
title: '加工方式', title: '加工方式',
align: 'center',
field: 'materialProcessMethod', field: 'materialProcessMethod',
formatter: function(value, row, index) { formatter: function(value, row, index) {
return $.table.selectDictLabel(processMethodDatas, value); return $.table.selectDictLabel(processMethodDatas, value);
} }
}, },
{ // {
title: '订单数量', // title: '订单数量',
field: 'makeNum', // field: 'makeNum',
}, // },
{ {
title: '已出库数', title: '已出库数',
align: 'center',
field: 'hasOutOrderSum', field: 'hasOutOrderSum',
}, },
{ {
title: '申请出库数', title: '申请出库数',
align: 'center',
field: 'applyOutOrderSum', field: 'applyOutOrderSum',
}, },
{ {
title: '实际出库数', title: '实际出库数',
align: 'center',
field: 'actualOutOrderSum', field: 'actualOutOrderSum',
editable:true formatter: function(value, row, index) {
} if(value == null || value == undefined){
return '';
}
return value;
},
editable: {
type: 'text',
validate: function (v,row) {
if (!v) return '数量不能为空';
if (isNaN(v)) return '数量必须是数字';
var actualOutOrderSum = parseInt(v);
if (actualOutOrderSum < 0) return '数量必须是正整数';
}
}
},
] ]
}); });

Loading…
Cancel
Save