5327bd0a by yangjianbin

init

1 parent 14524e18
1 <?php $this->load->view('common/header'); ?> 1 <?php $this->load->view('common/header'); ?>
2 2
3 <body> 3 <body>
4 <div class="page-container"> 4 <div class="page-container">
5 <form class="" onreset="resetHandler()"> 5 <form class="" onreset="resetHandler()">
6 <div class="date mb-20"> 6 <div class="date mb-20">
7 <input type="text" 7 <input type="text"
...@@ -24,9 +24,9 @@ ...@@ -24,9 +24,9 @@
24 <span class="select-box"> 24 <span class="select-box">
25 <select class="select table_search" name="departmentId" size="1" column="6"> 25 <select class="select table_search" name="departmentId" size="1" column="6">
26 <option value="" selected>网点</option> 26 <option value="" selected>网点</option>
27 <?php foreach ($this->session->departments as $k=>$v):?> 27 <?php foreach ($this->session->departments as $k => $v): ?>
28 <option value="<?=$v->id?>"><?=$v->name?></option> 28 <option value="<?= $v->id ?>"><?= $v->name ?></option>
29 <?php endforeach;?> 29 <?php endforeach; ?>
30 </select> 30 </select>
31 </span> 31 </span>
32 </div> 32 </div>
...@@ -85,10 +85,10 @@ ...@@ -85,10 +85,10 @@
85 </tbody> 85 </tbody>
86 </table> 86 </table>
87 </div> 87 </div>
88 </div> 88 </div>
89 <?php $this->load->view('common/footer'); ?> 89 <?php $this->load->view('common/footer'); ?>
90 90
91 <script> 91 <script>
92 var table = $('#table').dataTable({ 92 var table = $('#table').dataTable({
93 aaSorting: [[1, "desc"]], 93 aaSorting: [[1, "desc"]],
94 serverSide: true, 94 serverSide: true,
...@@ -103,7 +103,7 @@ ...@@ -103,7 +103,7 @@
103 var ret = {}, json = jQuery.parseJSON(json); 103 var ret = {}, json = jQuery.parseJSON(json);
104 ret.data = json.data; 104 ret.data = json.data;
105 var draw = getUrlParam('draw'); 105 var draw = getUrlParam('draw');
106 if(draw) { 106 if (draw) {
107 ret.draw = draw; 107 ret.draw = draw;
108 } 108 }
109 ret.recordsTotal = 0; 109 ret.recordsTotal = 0;
...@@ -126,7 +126,7 @@ ...@@ -126,7 +126,7 @@
126 return '<span class="dropDown dropDown_hover">\ 126 return '<span class="dropDown dropDown_hover">\
127 <button class="btn radius size-M">请选择 <i class="Hui-iconfont">&#xe6d5;</i></button>\ 127 <button class="btn radius size-M">请选择 <i class="Hui-iconfont">&#xe6d5;</i></button>\
128 <ul class="dropDown-menu menu radius box-shadow">\ 128 <ul class="dropDown-menu menu radius box-shadow">\
129 <li><a href="javascript:;pass('+data+')">确认到款</a></li>\ 129 <li><a href="javascript:;pass(' + data + ')">确认到款</a></li>\
130 </ul></span>'; 130 </ul></span>';
131 } 131 }
132 }, 132 },
...@@ -181,36 +181,36 @@ ...@@ -181,36 +181,36 @@
181 181
182 function pass(id) { 182 function pass(id) {
183 layer.confirm('通过之后, 账单同步更新到收款明细列表', { 183 layer.confirm('通过之后, 账单同步更新到收款明细列表', {
184 btn: ['通过','取消'], 184 btn: ['通过', '取消'],
185 title: '确认到账', 185 title: '确认到账',
186 icon: 3 186 icon: 3
187 }, function(){ 187 }, function () {
188 var data = { 188 var data = {
189 realRepaymentDate:getNowFormatDate() 189 realRepaymentDate: getNowFormatDate()
190 }; 190 };
191 $.ajax({ 191 $.ajax({
192 type:'patch', 192 type: 'patch',
193 url:apiBaseUrl + 'manage/financial/confirm/' + id, 193 url: apiBaseUrl + 'manage/financial/confirm/' + id + '?realRepaymentDate=' + Date.now(),
194 cache: false, 194 cache: false,
195 dataType:'json', 195 dataType: 'json',
196 data:JSON.stringify(data), 196 data: JSON.stringify(data),
197 contentType: "application/json; charset=UTF-8", 197 contentType: "application/json; charset=UTF-8",
198 success:function(data){ 198 success: function (data) {
199 if(data.msg){ 199 if (data.msg) {
200 layer.alert(data.msg); 200 layer.alert(data.msg);
201 } else if(data.code != 0){ 201 } else if (data.code != 0) {
202 layer.alert('请求失败'); 202 layer.alert('请求失败');
203 } else { 203 } else {
204 layer.msg('通过'); 204 layer.msg('通过');
205 } 205 }
206 }, 206 },
207 error:function(){ 207 error: function () {
208 layer.alert("请求失败") 208 layer.alert("请求失败")
209 } 209 }
210 }) 210 })
211 211
212 }); 212 });
213 } 213 }
214 </script> 214 </script>
215 </body> 215 </body>
216 <html> 216 <html>
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!