427df46b by yangjianbin

init

1 parent f063006e
...@@ -55,8 +55,8 @@ ...@@ -55,8 +55,8 @@
55 return '<span class="dropDown dropDown_hover">\ 55 return '<span class="dropDown dropDown_hover">\
56 <button class="btn radius size-M">请选择 <i class="Hui-iconfont">&#xe6d5;</i></button>\ 56 <button class="btn radius size-M">请选择 <i class="Hui-iconfont">&#xe6d5;</i></button>\
57 <ul class="dropDown-menu menu radius box-shadow">\ 57 <ul class="dropDown-menu menu radius box-shadow">\
58 <li><a href="javascript:;" onclick="pass(1)">通过</a></li>\ 58 <li><a href="javascript:;" onclick="pass('+data+')">通过</a></li>\
59 <li><a href="javascript:;" onclick="refuse(1)">拒绝</a></li>\ 59 <li><a href="javascript:;" onclick="refuse('+data+')">拒绝</a></li>\
60 </ul>\ 60 </ul>\
61 </span>'; 61 </span>';
62 } 62 }
...@@ -84,17 +84,79 @@ ...@@ -84,17 +84,79 @@
84 title: '确认通过预审', 84 title: '确认通过预审',
85 icon: 3 85 icon: 3
86 }, function(){ 86 }, function(){
87 layer.msg('通过'); 87 var targetUrl = 'flow/confirm2NextStatus/' + id;
88 var data = {
89 "destOrderStatus": 2,
90 "opinion": "string",
91 "orderStatus": 1
92 }
93 $.ajax({
94 type: 'put',
95 url: apiBaseUrl + targetUrl,
96 cache: false,
97 dataType: 'json',
98 data: JSON.stringify(data),
99 contentType: "application/json; charset=UTF-8",
100 success: function (data) {
101 if (data.msg) {
102 layer.alert(data.msg);
103 } else if (data.code != 0) {
104 layer.alert('请求失败');
105 } else {
106 layer.alert('请求成功');
107 }
108 setTimeout(function () {
109 if(!data.code) {
110 table.fnDraw();
111 layer_close();
112 }
113 },500);
114 },
115 error: function () {
116 layer.alert("请求失败")
117 }
118 })
88 }); 119 });
89 } 120 }
90 121
91 function refuse(id) { 122 function refuse(id) {
92 layer.confirm('一旦驳回, 该笔借款将作废, 进入【审批拒绝】列表!', { 123 layer.confirm('一旦拒绝, 该笔借款将作废, 进入【审批拒绝】列表!', {
93 btn: ['确认拒绝', '取消'], 124 btn: ['确认拒绝', '取消'],
94 title: '确认拒绝', 125 title: '确认拒绝',
95 icon: 3 126 icon: 3
96 }, function(){ 127 }, function(){
97 layer.msg('拒绝'); 128 var targetUrl = 'flow/confirm2NextStatus/' + id;
129 var data = {
130 "destOrderStatus": 0,
131 "opinion": "string",
132 "orderStatus": 1
133 }
134 $.ajax({
135 type: 'put',
136 url: apiBaseUrl + targetUrl,
137 cache: false,
138 dataType: 'json',
139 data: JSON.stringify(data),
140 contentType: "application/json; charset=UTF-8",
141 success: function (data) {
142 if (data.msg) {
143 layer.alert(data.msg);
144 } else if (data.code != 0) {
145 layer.alert('请求失败');
146 } else {
147 layer.alert('请求成功');
148 }
149 setTimeout(function () {
150 if(!data.code) {
151 table.fnDraw();
152 layer_close();
153 }
154 },500);
155 },
156 error: function () {
157 layer.alert("请求失败")
158 }
159 })
98 }); 160 });
99 } 161 }
100 </script> 162 </script>
......
Styling with Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!