index.php
2.88 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
<?php $this->load->view('common/header'); ?>
<body>
<div id="tab" class="HuiTab">
<div class="tabBar clearfix" style="background-color:#e8e8e8">
<span>尽调报告</span>
<span>资料清单</span>
</div>
<form action="" id="form1">
<div class="tabCon">
<?php
if($clientUnitOutputVO->jobType == 1){ //打工类
$this->load->view('work/尽调报告/打工');
} else { // 经营类
$this->load->view('work/尽调报告/法人');
}
?>
</div>
</form>
<div class="tabCon">
<?php $this->load->view('work/图片上传'); ?>
</div>
</div>
<div class="row cl pb-20 col-sm-12">
<div class="col-sm-offset-3 col-sm-2">
<button class="btn btn-warning btn-block">退回订单</button>
</div>
<div class="col-sm-2">
<button class="btn btn-primary btn-block" onclick="submit()">提交尽调</button>
</div>
</div>
<?php $this->load->view('common/footer'); ?>
<script>
function getQueryString(name) {
var reg = new RegExp("(^|&)" + name + "=([^&]*)(&|$)", "i");
var r = window.location.search.substr(1).match(reg);
if (r != null) return unescape(r[2]); return null;
}
var index = getQueryString('tab');
$("#tab").Huitab({index: index});
uploadList();
function submit() {
layer.confirm('确认要提交尽调?', {
btn: ['是', '否'],
title: '确认',
icon: 3
}, function () {
var targetUrl = 'dueDiligence';
var data = $("form1").serializeJson();
$.ajax({
type: 'post',
url: apiBaseUrl + targetUrl,
cache: false,
dataType: 'json',
data: JSON.stringify(data),
contentType: "application/json; charset=UTF-8",
success: function (data) {
if (data.msg) {
layer.alert(data.msg);
} else if (data.code != 0) {
layer.alert('操作失败');
} else {
layer.alert('操作成功');
}
setTimeout(function () {
if (!data.code) {
table.fnDraw();
layer_close();
}
}, 500);
},
error: function () {
layer.alert("操作失败")
}
})
})
}
</script>
</body>
</html>