addtime.php
3.63 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
92
93
94
95
96
97
98
99
100
101
102
103
104
<?php $this->load->view('common/header'); ?>
<body>
<form action="" id="form1">
<input type="text" name="id" value="<?=$ret->id?>">
<div class="panel panel-default mb-20">
<div class="panel-body cl">
<div class="row cl">
<div class="form-group col-sm-3 col-md-1">
<label>确认时间</label>
<input name="realRepaymentDate" type="text" class="form-control input-text Wdate" value="" onfocus="WdatePicker()">
</div>
</div>
<!-- <div class="row cl">-->
<!-- <div class="form-group col-sm-3 col-md-1">-->
<!-- <label>是否拨通</label>-->
<!-- <span class="form-control select-box">-->
<!-- <select class="select" size="1" name="hasPutThrough">-->
<!-- <option value="1">是</option>-->
<!-- <option value="0">否</option>-->
<!-- </select>-->
<!-- </span>-->
<!-- </div>-->
<!-- </div>-->
<!-- <div class="row cl">-->
<!-- <div class="form-group col-sm-12 col-md-12">-->
<!-- <label>备注</label>-->
<!-- <textarea class="textarea" name="remark"></textarea>-->
<!-- </div>-->
<!-- </div>-->
</div>
</div>
</form>
<div class="row cl col-sm-12">
<div class="col-sm-2">
<button class="btn btn-primary btn-block" onclick="pass();">保存</button>
</div>
</div>
<?php $this->load->view('common/footer'); ?>
</body>
<script>
function pass() {
var data = $("#form1").serializeJson();
$.ajax({
type: 'patch',
// url: apiBaseUrl + 'manage/financial/confirm/' + id + '?realRepaymentDate=' + Date.now(),
url: apiBaseUrl + 'manage/financial/confirm/' + id,
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.msg('通过');
}
if(!data.code){
setTimeout(function () {
layer_close();
}, 500)
}
},
error: function () {
layer.alert("操作失败")
}
});
// $.ajax({
// type: 'post',
// url: apiBaseUrl + 'audit/phoneAudit/record',
// cache: false,
// data: JSON.stringify(data),
// dataType: 'json',
// 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('操作成功');
// }
// if(!data.code){
// setTimeout(function () {
// layer_close();
// }, 500)
// }
// },
// error: function () {
// layer.alert("操作失败")
// }
//
// })
}
</script>
</html>