liuxiaoxu
1 month ago
3 changed files with 0 additions and 585 deletions
@ -1,184 +0,0 @@ |
|||
<!DOCTYPE html> |
|||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > |
|||
<head> |
|||
<th:block th:include="include :: header('新增qualitySupplierDeduction')" /> |
|||
<th:block th:include="include :: datetimepicker-css" /> |
|||
<link th:href="@{/ajax/libs/select2/select2.css}" rel="stylesheet"> |
|||
<link th:href="@{/ajax/libs/select2/select2-bootstrap.css}" rel="stylesheet"> |
|||
<th:block th:include="include :: bootstrap-editable-css"/> |
|||
<style> |
|||
.other-container { |
|||
width: 90%; |
|||
height: 200px; |
|||
margin: auto; |
|||
} |
|||
.other { |
|||
margin-top: 20px; |
|||
} |
|||
h4 { |
|||
display: inline-block; |
|||
margin-right: 20px; |
|||
} |
|||
.modal-body{ |
|||
height: 550px; |
|||
} |
|||
iframe{ |
|||
width: 100%; |
|||
height: 500px; |
|||
frameborder: 0; |
|||
border: 0; |
|||
display: inline-block; |
|||
} |
|||
</style> |
|||
</head> |
|||
<body class="white-bg"> |
|||
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> |
|||
<form class="form-horizontal m" id="form-qualitySupplierDeduction-add"> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">供应商代码:</label> |
|||
<div class="col-sm-8"> |
|||
<select name="supplierCode" class="form-control m-b"> |
|||
<option value="">所有</option> |
|||
</select> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">送达方式:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="modeOfService" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">受理部门:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="acceptanceDepartment" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">受理人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="acceptancePerson" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">联络方式:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="contactNumber" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">返工工时费:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="reworkLaborCost" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">客户扣款:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="customerDeduction" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">惩罚性罚款:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="punitiveDamage" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">物料报废费用:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="materialScrapCost" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">交通/运输费:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="transportationExpenses" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">其他名字:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="otherName" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">其他金额:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="othersCost" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">合计金额:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="totalAmount" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">提出人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="proposePerson" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">审核人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="reviewedPerson" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">复核人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="approvalPerson" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">索赔扣款详细原因:</label> |
|||
<div class="col-sm-8"> |
|||
<textarea name="reason" class="form-control"></textarea> |
|||
</div> |
|||
</div> |
|||
</form> |
|||
</div> |
|||
<th:block th:include="include :: footer" /> |
|||
<th:block th:include="include :: datetimepicker-js" /> |
|||
<th:block th:include="include :: select2-js"/> |
|||
<th:block th:include="include :: bootstrap-table-editable-js"/> |
|||
<script th:inline="javascript"> |
|||
var prefix = ctx + "quality/qualitySupplierDeduction" |
|||
var prefixSupplier = ctx + "system/supplier" |
|||
|
|||
$("#form-qualitySupplierDeduction-add").validate({ |
|||
focusCleanup: true |
|||
}); |
|||
|
|||
function submitHandler() { |
|||
if ($.validate.form()) { |
|||
$.operate.save(prefix + "/add", $('#form-qualitySupplierDeduction-add').serialize()); |
|||
} |
|||
} |
|||
|
|||
//获取供应商代码 |
|||
$.ajax({ |
|||
url: prefixSupplier + "/list", |
|||
type: "post", |
|||
dateType: "json", |
|||
success: function (res) { |
|||
console.log(res) |
|||
if (res.rows.length > 0) { |
|||
var orderData = res.rows; |
|||
for (let i in orderData) { |
|||
$("#form-qualitySupplierDeduction-add select[name='supplierCode']").append("<option value='" + orderData[i].supplierCode + "'>" + orderData[i].supplierCode + "</option>"); |
|||
} |
|||
} else { |
|||
$.modal.msgError(res.msg); |
|||
} |
|||
}, |
|||
error: function () { |
|||
$.modal.msgError("后台出错啦!"); |
|||
} |
|||
}); |
|||
|
|||
</script> |
|||
</body> |
|||
</html> |
@ -1,184 +0,0 @@ |
|||
<!DOCTYPE html> |
|||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" > |
|||
<head> |
|||
<th:block th:include="include :: header('修改qualitySupplierDeduction')" /> |
|||
<th:block th:include="include :: datetimepicker-css" /> |
|||
<link th:href="@{/ajax/libs/select2/select2.css}" rel="stylesheet"> |
|||
<link th:href="@{/ajax/libs/select2/select2-bootstrap.css}" rel="stylesheet"> |
|||
<th:block th:include="include :: bootstrap-editable-css"/> |
|||
<style> |
|||
.other-container { |
|||
width: 90%; |
|||
height: 200px; |
|||
margin: auto; |
|||
} |
|||
.other { |
|||
margin-top: 20px; |
|||
} |
|||
h4 { |
|||
display: inline-block; |
|||
margin-right: 20px; |
|||
} |
|||
.modal-body{ |
|||
height: 550px; |
|||
} |
|||
iframe{ |
|||
width: 100%; |
|||
height: 500px; |
|||
frameborder: 0; |
|||
border: 0; |
|||
display: inline-block; |
|||
} |
|||
</style> |
|||
</head> |
|||
<body class="white-bg"> |
|||
<div class="wrapper wrapper-content animated fadeInRight ibox-content"> |
|||
<form class="form-horizontal m" id="form-qualitySupplierDeduction-edit" th:object="${qualitySupplierDeduction}"> |
|||
<input name="supplierDeductionId" th:field="*{supplierDeductionId}" type="hidden"> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">供应商代码:</label> |
|||
<div class="col-sm-8"> |
|||
<select name="supplierCode" class="form-control m-b" th:field="*{supplierCode}"> |
|||
<option value=""></option> |
|||
</select> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">送达方式:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="modeOfService" th:field="*{modeOfService}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">受理部门:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="acceptanceDepartment" th:field="*{acceptanceDepartment}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">受理人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="acceptancePerson" th:field="*{acceptancePerson}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">联络方式:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="contactNumber" th:field="*{contactNumber}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">返工工时费:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="reworkLaborCost" th:field="*{reworkLaborCost}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">客户扣款:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="customerDeduction" th:field="*{customerDeduction}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">惩罚性罚款:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="punitiveDamage" th:field="*{punitiveDamage}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">物料报废费用:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="materialScrapCost" th:field="*{materialScrapCost}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">交通/运输费:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="transportationExpenses" th:field="*{transportationExpenses}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">其他名字:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="otherName" th:field="*{otherName}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">其他金额:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="othersCost" th:field="*{othersCost}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">合计金额:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="totalAmount" th:field="*{totalAmount}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">提出人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="proposePerson" th:field="*{proposePerson}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">审核人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="reviewedPerson" th:field="*{reviewedPerson}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">复核人:</label> |
|||
<div class="col-sm-8"> |
|||
<input name="approvalPerson" th:field="*{approvalPerson}" class="form-control" type="text"> |
|||
</div> |
|||
</div> |
|||
<div class="form-group"> |
|||
<label class="col-sm-3 control-label">索赔扣款详细原因:</label> |
|||
<div class="col-sm-8"> |
|||
<textarea name="reason" class="form-control">[[*{reason}]]</textarea> |
|||
</div> |
|||
</div> |
|||
</form> |
|||
</div> |
|||
<th:block th:include="include :: footer" /> |
|||
<th:block th:include="include :: datetimepicker-js" /> |
|||
<th:block th:include="include :: select2-js"/> |
|||
<th:block th:include="include :: bootstrap-table-editable-js"/> |
|||
<script th:inline="javascript"> |
|||
var prefix = ctx + "quality/qualitySupplierDeduction"; |
|||
var prefixSupplier = ctx + "system/supplier" |
|||
$("#form-qualitySupplierDeduction-edit").validate({ |
|||
focusCleanup: true |
|||
}); |
|||
|
|||
function submitHandler() { |
|||
if ($.validate.form()) { |
|||
$.operate.save(prefix + "/edit", $('#form-qualitySupplierDeduction-edit').serialize()); |
|||
} |
|||
} |
|||
|
|||
//获取供应商代码 |
|||
$.ajax({ |
|||
url: prefixSupplier + "/list", |
|||
type: "post", |
|||
dateType: "json", |
|||
success: function (res) { |
|||
if (res.rows.length > 0) { |
|||
var orderData = res.rows; |
|||
for(let i in orderData){ |
|||
$("#form-qualitySupplierDeduction-edit select[name='supplierCode']").append("<option value='" + orderData[i].supplierCode + "'>" + orderData[i].supplierCode + "</option>"); |
|||
} |
|||
$("#form-qualitySupplierDeduction-edit select[name='supplierCode']").val(getData.supplierCode).trigger("supplierCode") |
|||
} else { |
|||
$.modal.msgError(res.msg); |
|||
} |
|||
}, |
|||
error: function () { |
|||
$.modal.msgError("后台出错啦!"); |
|||
} |
|||
}); |
|||
|
|||
</script> |
|||
</body> |
|||
</html> |
@ -1,217 +0,0 @@ |
|||
<!DOCTYPE html> |
|||
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro"> |
|||
<head> |
|||
<th:block th:include="include :: header('qualitySupplierDeduction列表')" /> |
|||
<script type="text/javascript" th:src="@{/js/axios.min.js}"></script> |
|||
</head> |
|||
<body class="gray-bg"> |
|||
<div class="container-div"> |
|||
<div class="row"> |
|||
<div class="col-sm-12 search-collapse"> |
|||
<form id="formId"> |
|||
<div class="select-list"> |
|||
<ul> |
|||
<li> |
|||
<label>供应商代码:</label> |
|||
<select name="supplierCode"> |
|||
<option value="">所有</option> |
|||
</select> |
|||
</li> |
|||
<li> |
|||
<label>受理部门:</label> |
|||
<input type="text" name="acceptanceDepartment"/> |
|||
</li> |
|||
<li> |
|||
<label>受理人:</label> |
|||
<input type="text" name="acceptancePerson"/> |
|||
</li> |
|||
<li> |
|||
<a class="btn btn-primary btn-rounded btn-sm" onclick="$.table.search()"><i class="fa fa-search"></i> 搜索</a> |
|||
<a class="btn btn-warning btn-rounded btn-sm" onclick="$.form.reset()"><i class="fa fa-refresh"></i> 重置</a> |
|||
</li> |
|||
</ul> |
|||
</div> |
|||
</form> |
|||
</div> |
|||
|
|||
<div class="btn-group-sm" id="toolbar" role="group"> |
|||
<a class="btn btn-success" onclick="$.operate.add()" shiro:hasPermission="quality:qualitySupplierDeduction:add"> |
|||
<i class="fa fa-plus"></i> 添加 |
|||
</a> |
|||
<a class="btn btn-primary single disabled" onclick="$.operate.edit()" shiro:hasPermission="quality:qualitySupplierDeduction:edit"> |
|||
<i class="fa fa-edit"></i> 修改 |
|||
</a> |
|||
<a class="btn btn-danger multiple disabled" onclick="$.operate.removeAll()" shiro:hasPermission="quality:qualitySupplierDeduction:remove"> |
|||
<i class="fa fa-remove"></i> 删除 |
|||
</a> |
|||
<a class="btn btn-warning" onclick="exportSelectedRaw()" shiro:hasPermission="quality:qualitySupplierDeduction:export"> |
|||
<i class="fa fa-download"></i> 导出 |
|||
</a> |
|||
</div> |
|||
<div class="col-sm-12 select-table table-striped"> |
|||
<table id="bootstrap-table" style="white-space: nowrap"></table> |
|||
</div> |
|||
</div> |
|||
</div> |
|||
<th:block th:include="include :: footer" /> |
|||
<script th:inline="javascript"> |
|||
var editFlag = [[${@permission.hasPermi('quality:qualitySupplierDeduction:edit')}]]; |
|||
var removeFlag = [[${@permission.hasPermi('quality:qualitySupplierDeduction:remove')}]]; |
|||
var prefix = ctx + "quality/qualitySupplierDeduction"; |
|||
var prefixSupplier = ctx + "system/supplier" |
|||
|
|||
$(function() { |
|||
var options = { |
|||
url: prefix + "/list", |
|||
createUrl: prefix + "/add", |
|||
updateUrl: prefix + "/edit/{id}", |
|||
removeUrl: prefix + "/remove", |
|||
exportUrl: prefix + "/export", |
|||
modalName: "qualitySupplierDeduction", |
|||
columns: [{ |
|||
checkbox: true |
|||
}, |
|||
{ |
|||
field: 'supplierDeductionId', |
|||
title: '', |
|||
visible: false |
|||
}, |
|||
{ |
|||
field: 'supplierCode', |
|||
title: '供应商代码' |
|||
}, |
|||
{ |
|||
field: 'modeOfService', |
|||
title: '送达方式' |
|||
}, |
|||
{ |
|||
field: 'acceptanceDepartment', |
|||
title: '受理部门' |
|||
}, |
|||
{ |
|||
field: 'acceptancePerson', |
|||
title: '受理人' |
|||
}, |
|||
{ |
|||
field: 'contactNumber', |
|||
title: '联络方式' |
|||
}, |
|||
{ |
|||
field: 'reason', |
|||
title: '索赔扣款详细原因' |
|||
}, |
|||
{ |
|||
field: 'reworkLaborCost', |
|||
title: '返工工时费' |
|||
}, |
|||
{ |
|||
field: 'customerDeduction', |
|||
title: '客户扣款' |
|||
}, |
|||
{ |
|||
field: 'punitiveDamage', |
|||
title: '惩罚性罚款' |
|||
}, |
|||
{ |
|||
field: 'materialScrapCost', |
|||
title: '物料报废费用' |
|||
}, |
|||
{ |
|||
field: 'transportationExpenses', |
|||
title: '交通/运输费' |
|||
}, |
|||
{ |
|||
field: 'otherName', |
|||
title: '其他名字' |
|||
}, |
|||
{ |
|||
field: 'othersCost', |
|||
title: '其他金额' |
|||
}, |
|||
{ |
|||
field: 'totalAmount', |
|||
title: '合计金额' |
|||
}, |
|||
{ |
|||
field: 'proposePerson', |
|||
title: '提出人' |
|||
}, |
|||
{ |
|||
field: 'reviewedPerson', |
|||
title: '审核人' |
|||
}, |
|||
{ |
|||
field: 'approvalPerson', |
|||
title: '复核人' |
|||
}, |
|||
{ |
|||
title: '操作', |
|||
align: 'center', |
|||
formatter: function(value, row, index) { |
|||
var actions = []; |
|||
actions.push('<a class="btn btn-success btn-xs ' + editFlag + '" href="javascript:void(0)" onclick="$.operate.edit(\'' + row.supplierDeductionId + '\')"><i class="fa fa-edit"></i>编辑</a> '); |
|||
actions.push('<a class="btn btn-danger btn-xs ' + removeFlag + '" href="javascript:void(0)" onclick="$.operate.remove(\'' + row.supplierDeductionId + '\')"><i class="fa fa-remove"></i>删除</a>'); |
|||
return actions.join(''); |
|||
} |
|||
}] |
|||
}; |
|||
$.table.init(options); |
|||
}); |
|||
|
|||
//获取供应商代码 |
|||
$.ajax({ |
|||
url: prefixSupplier + "/list", |
|||
type: "post", |
|||
dateType: "json", |
|||
success: function (res) { |
|||
console.log(res) |
|||
if (res.rows.length > 0) { |
|||
var orderData = res.rows; |
|||
for (let i in orderData) { |
|||
$("#formId select[name='supplierCode']").append("<option value='" + orderData[i].supplierCode + "'>" + orderData[i].supplierCode + "</option>"); |
|||
} |
|||
} else { |
|||
$.modal.msgError(res.msg); |
|||
} |
|||
}, |
|||
error: function () { |
|||
$.modal.msgError("后台出错啦!"); |
|||
} |
|||
}); |
|||
|
|||
//导出 |
|||
function exportSelectedRaw() { |
|||
var rows = $.common.isEmpty(table.options.uniqueId) ? $.table.selectFirstColumns() : $.table.selectColumns(table.options.uniqueId); |
|||
var data = $("#bootstrap-table").bootstrapTable("getSelections") |
|||
if (rows.length !== 1) { |
|||
$.modal.alert("请选择一条记录"); |
|||
return; |
|||
} else { |
|||
$.modal.confirm("是否确认要导出本条供应商索赔扣款单?", function (){ |
|||
axios({ |
|||
url: prefix + '/export/'+data[0].supplierDeductionId, |
|||
method: 'POST', |
|||
responseType: 'blob' |
|||
}).then(response => { |
|||
// console.log(response) |
|||
const URL = window.URL.createObjectURL(response.data) |
|||
// 创建隐藏<a>标签进行下载 |
|||
const tempLink = document.createElement('a') |
|||
tempLink.style.display = 'none' |
|||
tempLink.href = URL |
|||
let time = new Date().toLocaleString() |
|||
tempLink.setAttribute('download', time + "供应商索赔扣款单.xlsx") |
|||
if (typeof tempLink.download === 'undefined') { |
|||
tempLink.setAttribute('target', '_blank') |
|||
} |
|||
document.body.appendChild(tempLink) |
|||
tempLink.click() |
|||
document.body.removeChild(tempLink)// 移除dom元素 |
|||
window.URL.revokeObjectURL(URL)//释放内存 |
|||
}) |
|||
}); |
|||
} |
|||
} |
|||
</script> |
|||
</body> |
|||
</html> |
Loading…
Reference in new issue