Commit 339ef2e3 authored by 刘学辉's avatar 刘学辉

废品销售单修改

parent cbb87e72
......@@ -61,7 +61,7 @@ function loadGrid() {
function getGridColumns(){
var columns=[];
columns.push({
display: "序号", name: "sequence", width: 100, minWidth: 60, type: "string", align: "left",
display: "序号", name: "sequence", width: 60, minWidth: 60, type: "string", align: "left",
},)
columns.push({
display: "品类", name: "wasteTypeTextView", width: 200, minWidth: 60, type: "string", align: "left",
......@@ -83,13 +83,13 @@ function getGridColumns(){
}
},)
columns.push({
display: "数量", name: "quantity", width: 200, minWidth: 60, type: "string", align: "left",
display: "数量", name: "quantity", width: 100, minWidth: 60, type: "string", align: "left",
editor: {
required: true, type: "text",mask: '9999999.99'
}
},)
columns.push({
display: "计量单位", name: "unitName", width: 200, minWidth: 60, type: "string", align: "left",
display: "计量单位", name: "unitName", width: 160, minWidth: 60, type: "string", align: "left",
editor: {
required: true, type: "select",
data: {
......@@ -105,45 +105,61 @@ function getGridColumns(){
},
}
},)
columns.push({
display: "毛重", name: "grossWeight", width: 120, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
}
},)
columns.push({
display: "车辆皮重", name: "carWeight", width: 120, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
}
},)
var subProcUnitId = getSubProcUnitId();
var statusId = $("#statusId").val();
if (subProcUnitId === "purchase" || statusId > 0){
//采购部专员录入回收单价,自动计算出总价,补充收款账户
columns.push({
display: "单价", name: "price", width: 200, minWidth: 60, type: "string", align: "left",
display: "扣减重量", name: "deductWeight", width: 120, minWidth: 60, type: "string", align: "left",
editor: {
required: true, type: "text",mask: '9999999.99'
required: false, type: "text",mask: '9999999.99'
},
render: function (item) {
if (Public.isNotBlank(item.deductWeight)) {
var amount = MathUtil.sub(item.grossWeight, item.carWeight);
var amount1 = MathUtil.sub(amount, item.deductWeight);
item.quantity=amount1;
return item.deductWeight;
}
},)
columns.push({
display: "总价", name: "amount", width: 140, minWidth: 60, type: "string", align: "left",
render: function (item){
if (Public.isNotBlank(item.quantity) && Public.isNotBlank(item.price)){
var amount = MathUtil.mul(item.quantity,item.price)
if (Public.isNotBlank(item.quantity) && Public.isNotBlank(item.price)) {
var amount = MathUtil.mul(item.quantity, item.price)
countTotalMoney();
return item.amount = amount
}
}
},)
columns.push({
display: "车辆皮重", name: "carWeight", width: 150, minWidth: 60, type: "string", align: "left",
display: "单价", name: "price", width: 120, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
required: true, type: "text",mask: '9999999.99'
}
},)
columns.push({
display: "毛重", name: "grossWeight", width: 150, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
display: "总价", name: "amount", width: 120, minWidth: 60, type: "string", align: "left",
render: function (item){
if (Public.isNotBlank(item.quantity) && Public.isNotBlank(item.price)){
var amount = MathUtil.mul(item.quantity,item.price)
countTotalMoney();
return item.amount = amount
}
},)
columns.push({
display: "扣减重量", name: "deductWeight", width: 150, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
}
},)
columns.push({
/*columns.push({
display: "净重", name: "netWeight", width: 150, minWidth: 60, type: "string", align: "left",
editor: {
required: false, type: "text",mask: '9999999.99'
......@@ -154,7 +170,7 @@ function getGridColumns(){
editor: {
required: false, type: "text"
}
},)
},)*/
}
return columns;
}
......
......@@ -16,15 +16,16 @@ function loadGrid() {
columns: [
{display: "单据编号", name: "billCode", width: 150, minWidth: 60, type: "string", align: "left"},
{display: "创建日期", name: "fillinDate", width: 120, minWidth: 60, type: "string", align: "left"},
{display: "申请状态", name: "statusTextView", width: 60, minWidth: 60, type: "string", align: "left"},
{display: "申请人", name: "personMemberName", width: 120, minWidth: 60, type: "string", align: "left"},
{display: "申请部门", name: "deptName", width: 120, minWidth: 60, type: "string", align: "left"},
{display: "公司代码", name: "burks", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "公司代码", name: "burks", width: 100, minWidth: 60, type: "string", align: "left"},
{display: "回收商", name: "bktxt", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "回收日期", name: "budat", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "回收日期", name: "budat", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "收款方式", name: "paymentMethodTextView", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "合计", name: "totalMoney", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "车牌号", name: "carNo", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "备注", name: "remark", width: 300, minWidth: 60, type: "string", align: "left"},
{display: "合计金额", name: "totalMoney", width: 120, minWidth: 60, type: "number", align: "right"},
{display: "车牌号", name: "carNo", width: 160, minWidth: 60, type: "string", align: "left"},
{display: "备注", name: "remark", width: 200, minWidth: 60, type: "string", align: "left"},
{display: "消息类型", name: "type", width: 100, minWidth: 60, type: "string", align: "left"},
{display: "会计凭证编号", name: "messageV1", width: 200, minWidth: 60, type: "string", align: "left"},
],
......
......@@ -27,6 +27,7 @@ public class SapPermitItemVo {
*/
private String unit;
private String unitName;
/**
* 备注
......
......@@ -2,6 +2,7 @@ package com.huigou.topsun.sap.wasteSale.application.impl;
import cn.hutool.core.bean.BeanUtil;
import com.alibaba.fastjson.JSONObject;
import com.huigou.cache.DictUtil;
import com.huigou.data.domain.model.CommonDomainConstants;
import com.huigou.data.query.model.QueryDescriptor;
import com.huigou.data.query.model.QueryModel;
......@@ -76,6 +77,8 @@ public class WasteSaleApplicationImpl extends FlowBroker implements WasteSaleApp
public Map<String, Object> slicedWasteSaleList(WasteSaleQueryRequest queryRequest) {
QueryDescriptor queryDescriptor = this.sqlExecutorDao.getQuery(QUERY_XML_FILE_PATH, "wasteSale");
QueryModel queryModel = this.sqlExecutorDao.getQueryModel(queryDescriptor, queryRequest);
queryModel.putDictionary("status", DictUtil.getDictionary("bizBillStatus"));
queryModel.addCriteria(" order by bill_code desc ");
Map<String, Object> map = this.sqlExecutorDao.executeSlicedQuery(queryModel);
return map;
}
......@@ -153,7 +156,12 @@ public class WasteSaleApplicationImpl extends FlowBroker implements WasteSaleApp
SapPermitItemVo sapPermitItemVo = new SapPermitItemVo();
sapPermitItemVo.setBelongings(wasteSaleItem.getSaleGoods());
sapPermitItemVo.setUnit(wasteSaleItem.getUnit());
String remark="车辆皮重:"+wasteSaleItem.getCarWeight()+" 毛重:"+wasteSaleItem.getGrossWeight()+" 扣减重量:"+wasteSaleItem.getDeductWeight();//+"净重:"+wasteSaleItem.getNetWeight();
sapPermitItemVo.setRemark(remark);
sapPermitItemVo.setQuantity(wasteSaleItem.getQuantity());
sapPermitItemVo.setUnit(wasteSaleItem.getUnit());
sapPermitItemVo.setUnitName(wasteSaleItem.getUnitName());
sapPermitItemVos.add(sapPermitItemVo);
}
sapPermitVo.setItemVos(sapPermitItemVos);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment