2019-08-14 14:22
AdminJsonPropertyContract 我给一下我的给你代码你参考一下:
public class AdminJsonPropertyContract extends BaseVo {
private static final long serialVersionUID = -3852159614796521206L;
private PropertyContractObj propertycontract;
public class PropertyContractObj extends PropertyContract {
private List contractPositions = new ArrayList<>();
private List contractExtcosts = new ArrayList<>();
public List getContractPositions() {
return contractPositions;
}
public void setContractPositions(List contractPositions) {
this.contractPositions = contractPositions;
}
public List getContractExtcosts() {
return contractExtcosts;
}
public void setContractExtcosts(List contractExtcosts) {
this.contractExtcosts = contractExtcosts;
}
}
public PropertyContractObj getPropertycontract() {
return propertycontract;
}
public void setPropertycontract(PropertyContractObj propertycontract) {
this.propertycontract = propertycontract;
}
}
2019-08-14 14:21
巧了。我最近也在遇到这种数据的场景。
前端提交的数据用这个处理
https://stackoverflow.com/questions/1184624/convert-form-data-to-javascript-object-with-jquery/8407771#8407771
后台用下面的方法获取到前端提交过来的json字符串
String rawData = getRawData();
然后
AdminJsonPropertyContract jsonObj = JSON.parseObject(rawData, AdminJsonPropertyContract.class);
2019-07-24 11:37
@杜福忠 看了你的话,想到把lay模板的语句封装成方法或许看起看没有那么糟心
#define laytplStart(str)
#[[{{#]]# #(str??) }}
#end
#define laytplEnd(str)
#[[{{#]]# #(str??) }}
#end
2019-07-24 10:59
@杜福忠 https://www.layui.com/doc/modules/laytpl.html#delimiters
冲突的是#号符,而不是{{ }}
2019-07-24 10:57
@happyboy
#[[{{#]]# function(xxx){ }}
......
#[[{{#]]# }; }}
2019-07-23 18:07
@琴海森林 问题是layui模板体内有可能要用到enjoy的一些处理,比如放动态参数等等