Commit a87eae83 authored by 鲁鑫's avatar 鲁鑫

预付款页面优化;数据字典模糊查询

parent 657d3d27
...@@ -212,7 +212,7 @@ var tableArray = [ ...@@ -212,7 +212,7 @@ var tableArray = [
{ {
display: "原因代码", name: "rstgrName", width: 120, minwidth: 120, type: "string", align: "left", display: "原因代码", name: "rstgrName", width: 120, minwidth: 120, type: "string", align: "left",
editor: { editor: {
required: true, type: "select", required: false, type: "select",
data: { data: {
type: 'system', type: 'system',
name: "dictionary", name: "dictionary",
...@@ -299,7 +299,7 @@ var tableArray = [ ...@@ -299,7 +299,7 @@ var tableArray = [
}, },
{ {
display: "直联付款标识", name: "zepBank", width: 120, minwidth: 120, type: "string", align: "left", display: "直联付款标识", name: "zepBank", width: 120, minwidth: 120, type: "string", align: "left",
/*editor: { editor: {
required: true, type: "select", required: true, type: "select",
data: { data: {
type: 'system', type: 'system',
...@@ -311,10 +311,6 @@ var tableArray = [ ...@@ -311,10 +311,6 @@ var tableArray = [
ZEP_BANK: "zepBank", ZEP_BANK: "zepBank",
} }
}, },
}*/
editor: {
type: 'text'
} }
}, },
] ]
......
...@@ -33,17 +33,9 @@ var tableArray = [ ...@@ -33,17 +33,9 @@ var tableArray = [
}, },
{ {
display: "BP标识", name: "zepBptype", width: 120, minwidth: 120, type: "string", align: "left", display: "BP标识", name: "zepBptype", width: 120, minwidth: 120, type: "string", align: "left",
editor: {
type: 'text'
}
}, },
{ {
display: "BP标识描述", name: "zepBptypename", width: 120, minwidth: 120, type: "string", align: "left", display: "BP标识描述", name: "zepBptypename", width: 120, minwidth: 120, type: "string", align: "left",
editor: {
type: 'text'
}
}, },
{ {
display: "BP(合作伙伴)", name: "partner", width: 120, minwidth: 120, type: "string", align: "left", display: "BP(合作伙伴)", name: "partner", width: 120, minwidth: 120, type: "string", align: "left",
...@@ -205,24 +197,28 @@ var tableArray = [ ...@@ -205,24 +197,28 @@ var tableArray = [
columns: [ columns: [
{display: "EP流程子序号", name: "zepItemno", width: 80, minwidth: 80, type: "string", align: "left"}, {display: "EP流程子序号", name: "zepItemno", width: 80, minwidth: 80, type: "string", align: "left"},
{ {
display: "原因代码", name: "rstgr", width: 120, minwidth: 120, type: "string", align: "left", display: "原因代码", name: "rstgrName", width: 120, minwidth: 120, type: "string", align: "left",
/*editor: { editor: {
required: true, type: "select", required: true, type: "select",
data: { data: {
type: 'system', type: 'system',
name: "dictionary", name: "dictionary",
getParam: function (item) { getParam: function (item) {
return {fieldName: "RSTGR"} return {
fieldName: "RSTGR",
filterValue:$("#bukrs").val()
}
}, },
back: { back: {
RSTGR: "rstgr", RSTGR: "rstgr",
TXT40: "rstgrName",
} }
}, },
}*/
editor: {
type: 'text'
} }
// editor: {
//
// type: 'text'
// }
}, },
{ {
display: "含税金额(审批)", display: "含税金额(审批)",
...@@ -403,7 +399,7 @@ function loadGrid(obj) { ...@@ -403,7 +399,7 @@ function loadGrid(obj) {
//财务审核 //财务审核
if ("financeNode" === subProcUnitId){ if ("financeNode" === subProcUnitId){
if (obj.node==="financialAuditGrid"){ if (obj.node==="financialAuditGrid"){
canEdit = true; canEdit = false;
}else if (obj.node==="capitalPostGrid"){ }else if (obj.node==="capitalPostGrid"){
canDelay = true; canDelay = true;
} }
...@@ -631,14 +627,14 @@ function nodeController(){ ...@@ -631,14 +627,14 @@ function nodeController(){
var subProcUnitId = getSubProcUnitId(); var subProcUnitId = getSubProcUnitId();
//财务审核 //财务审核
if ("financeNode" === subProcUnitId){ if ("financeNode" === subProcUnitId){
$("#financialAudit_sapReturn").hide(); //$("#financialAudit_sapReturn").hide();
$("#capitalPost").hide(); $("#capitalPost").hide();
$("#paymentAccomplish_sapReturn").hide(); $("#paymentAccomplish_sapReturn").hide();
} }
//资金岗 //资金岗
if ("fundNode" === subProcUnitId){ if ("fundNode" === subProcUnitId){
$("#financialAudit_sapReturn").hide(); //$("#financialAudit_sapReturn").hide();
$("#paymentAccomplish_sapReturn").hide(); $("#paymentAccomplish_sapReturn").hide();
} }
} }
......
...@@ -9,6 +9,7 @@ $(document).ready(function () { ...@@ -9,6 +9,7 @@ $(document).ready(function () {
loadSuppliersPayListGrid(); loadSuppliersPayListGrid();
loadSuppliersBuyerListGrid(); loadSuppliersBuyerListGrid();
loadSuppliersBankListGrid(); loadSuppliersBankListGrid();
bindEvent();
}); });
function initialize(){ function initialize(){
UICtrl.layout("#layout", {leftWidth: 3}); UICtrl.layout("#layout", {leftWidth: 3});
...@@ -497,3 +498,52 @@ function disableForm(formId,isDisabled) { ...@@ -497,3 +498,52 @@ function disableForm(formId,isDisabled) {
} }
}); });
} }
function bindEvent(){
$('#land1').searchbox({
type: "system", name: "dictionary",
getParam: function (item) {
return {
fieldName: "LAND1",
}
},
onChange: function (value, data) {
$('#land1').val(data.LAND1);
$('#land1Name').val(data.LANDX);
}
});
$('#region').searchbox({
type: "system", name: "getArea",
getParam: function (item) {
if (Public.isBlank($('#land1').val())){
Public.tip("请先选择国家")
return false;
}
return {
LAND1: $('#land1').val(),
}
},
onChange: function (value, data) {
$('#region').val(data.BLAND);
$('#regionName').val(data.BEZEI);
}
});
$('#city1').searchbox({
type: "system", name: "getArea",
getParam: function (item) {
if (Public.isBlank($('#land1').val())){
Public.tip("请先选择国家")
return false;
}
return {
LAND1: $('#land1').val(),
}
},
onChange: function (value, data) {
$('#city1').val(data.BLAND);
$('#city1Name').val(data.BEZEI);
}
});
}
\ No newline at end of file
...@@ -61,9 +61,12 @@ ...@@ -61,9 +61,12 @@
<%--<x:inputC name="strSuppl1" label="街道2" labelCol="1" fieldCol="2"/> <%--<x:inputC name="strSuppl1" label="街道2" labelCol="1" fieldCol="2"/>
<x:inputC name="strSuppl2" label="街道3" labelCol="1" fieldCol="2"/> <x:inputC name="strSuppl2" label="街道3" labelCol="1" fieldCol="2"/>
<x:inputC name="strSuppl3" label="街道4" labelCol="1" fieldCol="2"/>--%> <x:inputC name="strSuppl3" label="街道4" labelCol="1" fieldCol="2"/>--%>
<x:inputC name="land1" label="国家" labelCol="1" fieldCol="2" required="true"/> <x:inputC name="land1Name" label="国家" labelCol="1" fieldCol="2" required="true" wrapper="select"/>
<x:inputC name="region" label="地区" labelCol="1" fieldCol="2" required="true"/> <x:hidden name="land1"/>
<x:inputC name="city1" label="城市" labelCol="1" fieldCol="2" required="true"/> <x:inputC name="regionName" label="地区" labelCol="1" fieldCol="2" required="true" wrapper="select"/>
<x:hidden name="region"/>
<x:inputC name="city1Name" label="城市" labelCol="1" fieldCol="2" required="true" wrapper="select"/>
<x:hidden name="city1"/>
<x:inputC name="street" label="街道地址" labelCol="1" fieldCol="2"/> <x:inputC name="street" label="街道地址" labelCol="1" fieldCol="2"/>
<x:inputC name="langu" label="语言关键字" labelCol="1" fieldCol="2"/> <x:inputC name="langu" label="语言关键字" labelCol="1" fieldCol="2"/>
<x:inputC name="smtpAddr" label="电子邮件地址" labelCol="1" fieldCol="2"/> <x:inputC name="smtpAddr" label="电子邮件地址" labelCol="1" fieldCol="2"/>
......
...@@ -60,10 +60,10 @@ function loadSuppliersDataListGrid() { ...@@ -60,10 +60,10 @@ function loadSuppliersDataListGrid() {
// {display: "通用品名", name: "genericName", width: 140, minWidth: 60, type: "string", align: "left"}, // {display: "通用品名", name: "genericName", width: 140, minWidth: 60, type: "string", align: "left"},
// {display: "适用标准", name: "applicableStandard", width: 140, minWidth: 60, type: "string", align: "left"}, // {display: "适用标准", name: "applicableStandard", width: 140, minWidth: 60, type: "string", align: "left"},
//{display: "基本计量单位", name: "baseUnitTextView", width: 140, minWidth: 60, type: "string", align: "left"}, //{display: "基本计量单位", name: "baseUnitTextView", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "地区", name: "region", width: 140, minWidth: 60, type: "string", align: "left"}, {display: "国家", name: "land1Name", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "国家", name: "land1", width: 140, minWidth: 60, type: "string", align: "left"}, {display: "地区", name: "regionName", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "城市", name: "city1Name", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "街道", name: "street", width: 140, minWidth: 60, type: "string", align: "left"}, {display: "街道", name: "street", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "城市", name: "city1", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "邮编", name: "postCode1", width: 140, minWidth: 60, type: "string", align: "left"}, {display: "邮编", name: "postCode1", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "税收编号", name: "stenr", width: 140, minWidth: 60, type: "string", align: "left"}, {display: "税收编号", name: "stenr", width: 140, minWidth: 60, type: "string", align: "left"},
{display: "申请人", name: "personMemberName", width: 120, minWidth: 60, type: "string", align: "left"}, {display: "申请人", name: "personMemberName", width: 120, minWidth: 60, type: "string", align: "left"},
......
package com.huigou.topsun.sap.costCenter.application.impl;
import com.alibaba.fastjson.JSONArray;
import com.huigou.util.DateUtil;
import com.huigou.util.JSONUtil;
import java.math.BigDecimal;
import java.util.*;
import java.util.stream.Collectors;
/**
* @Auther: xin.lu
* @Date: 2024/02/27/14:12
* @Description:
*/
public class main {
public static void main(String[] args) {
String json ="[{\"WERKS\":\"1000\",\"NAME1\":\"广州市宝绅科技有限公司\",\"MATNR\":\"000000000001000144\",\"MAKTX\":\"高压料2426K(LDPE)\",\"LGFSB\":\"1002\",\"LGOBE\":\"原料二库\",\"MATKL\":\"11001\",\"WGBEZ\":\"RFID Inlay\",\"MEINS\":\"KG\",\"MSEHL\":\"千克\",\"EKGRP\":\"001\",\"EKNAM\":\"广州量产用生产类原辅材料采购组\",\"PEINH\":1 }," +
"{\"WERKS\":\"1000\",\"NAME1\":\"广州市宝绅科技有限公司\",\"MATNR\":\"000000000005000024\",\"MAKTX\":\"BSN N42x-F(42*16mm)pitch21.59mm width57m\",\"LGFSB\":\"\",\"LGOBE\":\"\",\"MATKL\":\"18001\",\"WGBEZ\":\"扣子\",\"MEINS\":\"ST\",\"MSEHL\":\"片\",\"EKGRP\":\"\",\"EKNAM\":\"\",\"PEINH\":1 }]";
List<Map<String,String>> mapList = (List<Map<String,String>>) JSONArray.parse(json);
mapList = mapList
.stream()
.filter(map2 -> map2.values().stream().anyMatch(value-> value.contains("144")))
.collect(Collectors.toList());
System.out.println("过滤出数据:"+mapList);
}
}
package com.huigou.topsun.sap.sapApplication.application;
import java.io.IOException;
import java.util.List;
import java.util.Map;
/**
* @Auther: xin.lu
* @Date: 2024/03/20/10:47
* @Description:
*/
public interface SapAreaApplication {
/**
* 根据国家查询地区
* @param LAND1
* @return
*/
List<Map<String,String>> getAreas(String LAND1) throws IOException;
}
...@@ -16,7 +16,7 @@ public interface SapPaymentApplication { ...@@ -16,7 +16,7 @@ public interface SapPaymentApplication {
* @param ZEP_BPTYPE * @param ZEP_BPTYPE
* @return * @return
*/ */
List<Map<String,Object>> getCusAndSuppliers(String BUKRS,String ZEP_BPTYPE) throws IOException; List<Map<String,String>> getCusAndSuppliers(String BUKRS,String ZEP_BPTYPE) throws IOException;
/** /**
* 根据公司代码和BP标识查询客户、供应商银行 * 根据公司代码和BP标识查询客户、供应商银行
...@@ -25,7 +25,7 @@ public interface SapPaymentApplication { ...@@ -25,7 +25,7 @@ public interface SapPaymentApplication {
* @return * @return
* @throws IOException * @throws IOException
*/ */
List<Map<String,Object>> getCusAndBanks(String PARTNER,String ZEP_BPTYPE) throws IOException; List<Map<String,String>> getCusAndBanks(String PARTNER,String ZEP_BPTYPE) throws IOException;
/** /**
* 根据公司代码查询银行账号 * 根据公司代码查询银行账号
...@@ -33,7 +33,7 @@ public interface SapPaymentApplication { ...@@ -33,7 +33,7 @@ public interface SapPaymentApplication {
* @return * @return
* @throws IOException * @throws IOException
*/ */
List<Map<String,Object>> getCompanyAndBankInfos(String BUKRS) throws IOException; List<Map<String,String>> getCompanyAndBankInfos(String BUKRS) throws IOException;
/** /**
* 根据公司代码查询公司内部订单 * 根据公司代码查询公司内部订单
...@@ -41,7 +41,7 @@ public interface SapPaymentApplication { ...@@ -41,7 +41,7 @@ public interface SapPaymentApplication {
* @return * @return
* @throws IOException * @throws IOException
*/ */
List<Map<String,Object>> getCompanyOrders(String BUKRS) throws IOException; List<Map<String,String>> getCompanyOrders(String BUKRS) throws IOException;
/** /**
* 根据公司代码、BP(合作伙伴)、付款申请类别查询订单 * 根据公司代码、BP(合作伙伴)、付款申请类别查询订单
...@@ -51,7 +51,7 @@ public interface SapPaymentApplication { ...@@ -51,7 +51,7 @@ public interface SapPaymentApplication {
* @return * @return
* @throws IOException * @throws IOException
*/ */
List<Map<String,Object>> getPurchaseOrders(String BUKRS,String PARTNER,String ZEP_FTYPE) throws IOException; List<Map<String,String>> getPurchaseOrders(String BUKRS,String PARTNER,String ZEP_FTYPE) throws IOException;
/** /**
* 根据公司代码、BP(合作伙伴)、付款申请类别查询发票 * 根据公司代码、BP(合作伙伴)、付款申请类别查询发票
...@@ -61,5 +61,5 @@ public interface SapPaymentApplication { ...@@ -61,5 +61,5 @@ public interface SapPaymentApplication {
* @param ZYL03 * @param ZYL03
* @return * @return
*/ */
List<Map<String, Object>> getPartnerInvs(String BUKRS,String PARTNER,String ZEP_FTYPE, String ZYL03); List<Map<String, String>> getPartnerInvs(String BUKRS,String PARTNER,String ZEP_FTYPE, String ZYL03);
} }
package com.huigou.topsun.sap.sapApplication.application.impl;
import cn.hutool.json.JSONUtil;
import com.alibaba.fastjson.JSONObject;
import com.fasterxml.jackson.core.type.TypeReference;
import com.fasterxml.jackson.databind.ObjectMapper;
import com.huigou.topsun.sap.common.HttpClient;
import com.huigou.topsun.sap.common.domain.SapResult;
import com.huigou.topsun.sap.sapApplication.application.SapAreaApplication;
import com.huigou.topsun.util.SAPUtils;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import java.io.IOException;
import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;
/**
* @Auther: xin.lu
* @Date: 2024/03/20/10:47
* @Description:
*/
@Service("sapAreaApplication")
public class SapAreaApplicationImpl implements SapAreaApplication {
@Autowired
private HttpClient httpClient;
@Override
public List<Map<String, String>> getAreas(String LAND1) throws IOException {
Map<String,Object> param = new HashMap<>();
param.put("LAND1",LAND1);
String execute = null;
List<Map<String,String>> mapList = new ArrayList<>();
try {
execute = httpClient.execute(param, "search/sch_bland");
Map<String, String> map = JSONObject.parseObject(execute, Map.class);
List<SapResult> sapResultList = JSONObject.parseArray(JSONUtil.toJsonStr(map.get("MSG")), SapResult.class);
if ("S".equals(sapResultList.get(0).getTYPE())) {
ObjectMapper objectMapper = SAPUtils.objectMapper();
mapList = objectMapper.readValue(com.huigou.util.JSONUtil.toString(map.get("FDATA")), new TypeReference<List<Map<String, String>>>() {});
}
} catch (IOException e) {
throw new RuntimeException("根据国家查询地区出错。");
}
return mapList;
}
}
...@@ -124,10 +124,22 @@ public class SuppliersInfo extends FlowBillAbstractEntity { ...@@ -124,10 +124,22 @@ public class SuppliersInfo extends FlowBillAbstractEntity {
/** /**
* 国家/地区代码 * 国家/地区代码
*/ */
@Column(name = "land1_name")
private String land1Name;
/**
* 地区代码
*/
@Column(name = "region") @Column(name = "region")
@JsonProperty("REGION") @JsonProperty("REGION")
private String region; private String region;
/**
* 地区代码
*/
@Column(name = "region_name")
private String regionName;
/** /**
* 语言关键字 * 语言关键字
*/ */
...@@ -136,12 +148,18 @@ public class SuppliersInfo extends FlowBillAbstractEntity { ...@@ -136,12 +148,18 @@ public class SuppliersInfo extends FlowBillAbstractEntity {
private String langu; private String langu;
/** /**
* 语言关键字 * 城市
*/ */
@Column(name = "city1") @Column(name = "city1")
@JsonProperty("CITY1") @JsonProperty("CITY1")
private String city1; private String city1;
/**
* 城市
*/
@Column(name = "city1_name")
private String city1Name;
/** /**
* 城市邮政编码 * 城市邮政编码
*/ */
......
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