+24
-3
@@ -918,6 +918,19 @@ public class WeiXinEvaluationController {
|
||||
return jsonMmodel;
|
||||
}
|
||||
|
||||
public Object saveBhLoanAction(EvaluationModel model){
|
||||
JsonModel jsonMmodel = new JsonModel();
|
||||
if(StringUtils.isNotBlank(model.getEvaluationId())){
|
||||
FjtEvaluation fjtEvaluation = fjtEvaluationService.findEvaluationById(Long.valueOf(model.getEvaluationId()));
|
||||
if(fjtEvaluation != null && fjtEvaluation.getLoan()!=model.getLoan()){
|
||||
fjtEvaluation.setLoan(model.getLoan());
|
||||
fjtEvaluation.setLastUpdated(new Date());
|
||||
fjtEvaluationService.updateEvaluation(fjtEvaluation);
|
||||
}
|
||||
}
|
||||
return jsonMmodel;
|
||||
}
|
||||
|
||||
//刷新审核价
|
||||
public Object refreshAuditPriceAction(EvaluationModel model){
|
||||
JsonModel jsonMmodel = new JsonModel();
|
||||
@@ -1106,9 +1119,15 @@ public class WeiXinEvaluationController {
|
||||
public Object checkImageAction(EvaluationModel model){
|
||||
JsonModel jsonModel = new JsonModel();
|
||||
if (StringUtils.isNotBlank(model.getEvaluationId())){
|
||||
List<ReportFileAttach> datas = reportFileAttachService.findHouseImage(Integer.valueOf(model.getEvaluationId()), 3);
|
||||
List<ReportFileAttach> datas3 = reportFileAttachService.findHouseImage(Integer.valueOf(model.getEvaluationId()), 3);
|
||||
Map<String, Integer> data = new HashMap<String, Integer>();
|
||||
data.put("count", datas.size());
|
||||
data.put("count_3", datas3.size());
|
||||
|
||||
FjtEvaluation evaluation = fjtEvaluationService.findEvaluationById(Long.valueOf(model.getEvaluationId()));
|
||||
if(evaluation!=null && evaluation.getLoan()!=null && evaluation.getLoan()==1){
|
||||
List<ReportFileAttach> datas5 = reportFileAttachService.findHouseImage(Integer.valueOf(model.getEvaluationId()), 5);
|
||||
data.put("count_5", datas5.size());
|
||||
}
|
||||
jsonModel.setJsonModel(data);
|
||||
}
|
||||
return jsonModel;
|
||||
@@ -1287,7 +1306,7 @@ public class WeiXinEvaluationController {
|
||||
FjtUsers fjtUser = fjtUsersService.findById(Long.valueOf(userId));
|
||||
UsersDetail usersDetail = usersDetailService.findById(fjtUser.getId());
|
||||
try {
|
||||
String id = new ObjectId().toString();
|
||||
|
||||
List<File> uploadfiles = new ArrayList<File>();
|
||||
for (CommonsMultipartFile file : files) {
|
||||
if (file.getSize() == 0 ) {
|
||||
@@ -1319,6 +1338,8 @@ public class WeiXinEvaluationController {
|
||||
} catch (IOException e) {
|
||||
//处理异常信息
|
||||
}
|
||||
String id = new ObjectId().toString();
|
||||
|
||||
reportFileAttach = new ReportFileAttach();
|
||||
reportFileAttach.setEvaluationId(Integer.valueOf(model.getEvaluationId()));
|
||||
reportFileAttach.setQueryId(model.getQueryId());
|
||||
|
||||
@@ -45,6 +45,7 @@ public class EvaluationModel extends BaseModel{
|
||||
private Map<String, Object> loanInfoMap;
|
||||
private Integer hopePrice;
|
||||
private String remark;
|
||||
private Integer loan;
|
||||
// private String preCode;//眾漆諉諳--瞼攫晤鎢
|
||||
// private String preName;//眾漆諉諳--瞼攫靡備
|
||||
// private String countryCode;//眾漆諉諳--Е郖晤鎢
|
||||
@@ -317,4 +318,12 @@ public class EvaluationModel extends BaseModel{
|
||||
public void setAddress(String address) {
|
||||
this.address = address;
|
||||
}
|
||||
|
||||
public Integer getLoan() {
|
||||
return loan;
|
||||
}
|
||||
|
||||
public void setLoan(Integer loan) {
|
||||
this.loan = loan;
|
||||
}
|
||||
}
|
||||
|
||||
@@ -190,6 +190,36 @@ $('#submitRemark').on('click', function () {
|
||||
}
|
||||
});
|
||||
|
||||
$('#submitLoan').on('click', function () {
|
||||
var opt = $("#submitLoan").text();
|
||||
if(opt == "修改"){
|
||||
$(this).parent().find("span").eq(1).hide()
|
||||
$("input[name=loan]").removeClass("dn");
|
||||
$("#submitLoan").text("保存");
|
||||
}else{
|
||||
var loan = $("input[name=loan]").val();
|
||||
if(loan == ""){
|
||||
$.toast("请输入是否续贷");
|
||||
}else{
|
||||
$.ajax({
|
||||
url:"saveBhLoan",
|
||||
data:{
|
||||
evaluationId:eId,
|
||||
loan:loan
|
||||
},
|
||||
dataType:"json",
|
||||
success:function(data){
|
||||
$("#submitLoan").remove();
|
||||
$("input[name=loan]").remove();
|
||||
$("#refreshPrice0").show();
|
||||
location.href ="bhreport?evaluationId="+eId;
|
||||
}
|
||||
})
|
||||
}
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
$('#refreshPrice,#refreshPrice0').on('click', function () {
|
||||
$.ajax({
|
||||
url:"refreshAuditPrice",
|
||||
@@ -308,10 +338,20 @@ $('.formal_btn').on('click', function () {
|
||||
},
|
||||
dataType:"json",
|
||||
success:function(data){
|
||||
if(data && data.count>0){
|
||||
clickFormalReport()
|
||||
if(isLoan && isLoan==1){
|
||||
if(data.count_5==0){
|
||||
$.alert('请上传产调报告或权籍!');
|
||||
}else if(data.count_3==0){
|
||||
$.alert('请上传房屋照片!');
|
||||
}else{
|
||||
clickFormalReport()
|
||||
}
|
||||
}else{
|
||||
$.alert('请上传房屋照片!');
|
||||
if(data.count_3==0){
|
||||
$.alert('请上传房屋照片!');
|
||||
}else{
|
||||
clickFormalReport()
|
||||
}
|
||||
}
|
||||
}
|
||||
})
|
||||
|
||||
@@ -134,7 +134,7 @@ input::-webkit-input-placeholder{
|
||||
.inputTopic01{margin-bottom:-1px;}
|
||||
.inputTopic01 .topicTitle,.inputTopic02 .topicTitle{margin-right:0;border:none;line-height:2.5rem;}
|
||||
.inputTopic01 .topicTitle .input_price{width:20%;padding-left:5px;}
|
||||
.inputTopic02 .topicTitle .input_lender{width:40%;padding-left:5px;}
|
||||
.inputTopic02 .topicTitle .input_lender{width:39%;padding-left:5px;line-height: 28px;}
|
||||
.inputTopic02 .topicTitle .input_cardId{width:35%;padding-left:5px;}
|
||||
.submit_btn{width:90px;border-left:solid 1px #e7e7e7;float:right;padding-right:0;text-align:center;cursor:pointer;}
|
||||
.left01{float:left;margin-right:8%;}
|
||||
|
||||
@@ -132,6 +132,18 @@
|
||||
</div>
|
||||
</#if>
|
||||
|
||||
<div class="topic inputTopic02" id="inputTopic02b" style="border-bottom:none;margin-bottom:0;">
|
||||
<div class="topicTitle topicTitle01">
|
||||
<span>是否续贷:</span>
|
||||
<input class="input_lender" name="loan" id="loan" type="hidden" required/>
|
||||
<p class="di"><a href="#" class="create-actions01"><#if fjtEvaluation.loan?? && fjtEvaluation.loan==1>是<#elseif fjtEvaluation.loan?? && fjtEvaluation.loan==0>否<#else>请选择</#if></a></p>
|
||||
<a class="submit_btn" id="submitLoan" style="border-left: none;"><#if fjtEvaluation.loan??>修改<#else>提交</#if></a>
|
||||
</div>
|
||||
<div class="topicTitle topicTitle01" style="color: #F4A460;font-size: 12px;line-height: 20px;margin-top: -5px;">
|
||||
注:如出具正式报告时,需上传产调报告或权籍
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<form id="fileForm" enctype="multipart/form-data" method="post" name="fileForm">
|
||||
<input type="hidden" name="evaluationId" value="${fjtEvaluation.id}">
|
||||
<input type="hidden" name="queryId" value="<#if bohaiEvaluationAudit??>${bohaiEvaluationAudit.queryId}</#if>">
|
||||
@@ -139,7 +151,7 @@
|
||||
<#if reportFileMap??>
|
||||
<div class="topicTitle topicTitle01 ">
|
||||
<span>已上传文件:</span>
|
||||
<#if reportFileMap["1"]??><span>询价单(${reportFileMap["1"]?size})</span></#if>
|
||||
<#if reportFileMap["5"]??><span>产调报告或权籍(${reportFileMap["5"]?size})</span></#if>
|
||||
<#if reportFileMap["2"]??><label style="margin-left: 10px;">产证(${reportFileMap["2"]?size})</label></#if>
|
||||
<#if reportFileMap["3"]??><label style="margin-left: 10px;">房屋照片(${reportFileMap["3"]?size})</label></#if>
|
||||
<#if reportFileMap["4"]??><label style="margin-left: 10px;">其它附件(${reportFileMap["4"]?size})</label></#if>
|
||||
@@ -456,6 +468,10 @@
|
||||
<script type="text/javascript">
|
||||
var eId = '${fjtEvaluation.id!}';
|
||||
var role = ${role}
|
||||
var isLoan = null
|
||||
<#if fjtEvaluation?? && fjtEvaluation.loan??>
|
||||
isLoan = ${fjtEvaluation.loan}
|
||||
</#if>
|
||||
showOtherSource(eId);
|
||||
//showTradeReference(eId);
|
||||
showHouseReference(eId);
|
||||
@@ -522,11 +538,11 @@
|
||||
label: true
|
||||
},
|
||||
{
|
||||
text: '询价单',
|
||||
text: '产调报告或权籍',
|
||||
bold: true,
|
||||
onClick: function () {
|
||||
$("a.create-actions08").empty().text(this.text).addClass("selected")
|
||||
$("#fileClass").val("1")
|
||||
$("#fileClass").val("5")
|
||||
$("input[name=reportFiles]").attr("accept","image/*")
|
||||
}
|
||||
},
|
||||
@@ -576,6 +592,41 @@ function changeFile(d){
|
||||
// }
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
$(document).on('click', '.create-actions01', function () {
|
||||
var buttons1 = [
|
||||
{
|
||||
text: '请选择是否续贷',
|
||||
label: true
|
||||
},
|
||||
{
|
||||
text: '是',
|
||||
bold: true,
|
||||
onClick: function () {
|
||||
$("#loan").empty().text(this.text).addClass("selected")
|
||||
$(".create-actions01").text(this.text)
|
||||
$("#loan").val("1")
|
||||
}
|
||||
},
|
||||
{
|
||||
text: '否',
|
||||
onClick: function () {
|
||||
$("#loan").empty().text(this.text).addClass("selected")
|
||||
$(".create-actions01").text(this.text)
|
||||
$("#loan").val("0")
|
||||
}
|
||||
}
|
||||
];
|
||||
var buttons2 = [
|
||||
{
|
||||
text: '取消',
|
||||
bg: 'gray'
|
||||
}
|
||||
];
|
||||
var groups = [buttons1, buttons2];
|
||||
$.actions(groups);
|
||||
});
|
||||
</script>
|
||||
</body>
|
||||
</html>
|
||||
|
||||
Reference in New Issue
Block a user