|
@ -1,46 +1,80 @@
|
1
|
1
|
// JavaScript Document
|
2
|
2
|
|
3
|
3
|
$(function(){
|
4
|
|
|
|
4
|
//alert("sciresouser");
|
|
5
|
|
5
|
6
|
var userid = $.cookie("userid");
|
6
|
7
|
var name = $.cookie("userName");
|
7
|
8
|
var flag;
|
8
|
9
|
|
9
|
10
|
////发布资源发布及修改
|
10
|
11
|
var resourceNamePass = true;
|
11
|
|
var professorPass=true;
|
|
12
|
//var professorPass=true;
|
12
|
13
|
var supportedServicesPass=true;
|
|
14
|
|
|
15
|
function resourceName()
|
|
16
|
{
|
|
17
|
var code = $("#resourceName").val();
|
|
18
|
if(code.length==0||code==" ")
|
|
19
|
{
|
|
20
|
$(".workmsg1").text("发布资源名称不能为空");
|
|
21
|
resourceNamePass = false;
|
|
22
|
}
|
|
23
|
else
|
|
24
|
{
|
|
25
|
$(".workmsg1").text("");
|
|
26
|
resourceNamePass= true;
|
|
27
|
}
|
|
28
|
}
|
|
29
|
$("#resourceName").blur(function(){
|
|
30
|
resourceName();
|
|
31
|
});
|
|
32
|
|
|
33
|
//验证可提供服务
|
|
34
|
function supportedServices()
|
|
35
|
{
|
|
36
|
var code = $("#supportedServices").val();
|
|
37
|
if(code.length==0||code==" ")
|
|
38
|
{
|
|
39
|
$(".workmsg3").text("可提供服务不能为空");
|
|
40
|
supportedServicesPass= false;
|
|
41
|
}
|
|
42
|
else
|
|
43
|
{
|
|
44
|
$(".workmsg3").text("");
|
|
45
|
supportedServicesPass= true;
|
|
46
|
}
|
|
47
|
}
|
|
48
|
$("#supportedServices").blur(function(){
|
|
49
|
supportedServices();
|
|
50
|
});
|
|
51
|
|
|
52
|
|
13
|
53
|
//我的资源的删除,修改
|
14
|
54
|
$("#workmysrc").on("click",".resoumag",function()
|
15
|
|
{
|
16
|
|
|
17
|
|
var indexNum=$(this).parent().parent().parent().parent().parent().parent().index();
|
18
|
|
//console.log(indexNum);
|
|
55
|
{
|
19
|
56
|
ResourceInfo();
|
20
|
57
|
$(".respublisher").css("display","none");
|
21
|
58
|
$(".stateinfor span").text("资源发布中");
|
22
|
59
|
var resourceID=$(this).attr("resourceId");
|
23
|
|
//console.log(resourceID);
|
|
60
|
function delet(){
|
|
61
|
$.ajax({
|
|
62
|
"url" : "/ajax/resource/"+resourceID,
|
|
63
|
"type" : "DELETE",
|
|
64
|
"success" : function($data) {
|
|
65
|
if ($data.success) {
|
|
66
|
$(".blackcover").remove();
|
|
67
|
$("body").css("overflow-y","auto");
|
|
68
|
getDataResource();
|
|
69
|
} else {
|
|
70
|
$.MsgBox.Alert('message',$data.msg);
|
|
71
|
}
|
|
72
|
}
|
|
73
|
})
|
|
74
|
}
|
24
|
75
|
if(resourceID){
|
25
|
76
|
$("#deletedResource").on("click",function(){
|
26
|
|
//$.MsgBox.Confirm("消息", "执行删除后资源信息将无法恢复,确定继续吗?",
|
27
|
|
$.ajax({
|
28
|
|
"url" : "/ajax/resource/"+resourceID,
|
29
|
|
"type" : "DELETE",
|
30
|
|
"success" : function($data) {
|
31
|
|
if ($data.success) {
|
32
|
|
oLength=oLength-1;
|
33
|
|
$(".blackcover").remove();
|
34
|
|
$("body").css("overflow-y","auto");
|
35
|
|
$(".maintab").eq(indexNum).remove();
|
36
|
|
|
37
|
|
//location.reload(true);
|
38
|
|
} else {
|
39
|
|
$.MsgBox.Alert('message',$data.msg);
|
40
|
|
}
|
41
|
|
}
|
42
|
|
})
|
43
|
|
//);
|
|
77
|
$.MsgBox.Confirm("消息", "执行删除后资源信息将无法恢复,确定继续吗?",delet)
|
44
|
78
|
})
|
45
|
79
|
$.ajax({
|
46
|
80
|
"url":"/ajax/resource/"+resourceID,
|
|
@ -67,6 +101,8 @@ $(function(){
|
67
|
101
|
"error":function(){$.MsgBox.Alert('message','failed')}
|
68
|
102
|
});
|
69
|
103
|
}
|
|
104
|
|
|
105
|
|
70
|
106
|
$("#inputb").on("click",function()
|
71
|
107
|
{ var $data = {};
|
72
|
108
|
$data.resourceName = $("#resourceName").val();
|
|
@ -82,24 +118,25 @@ $(function(){
|
82
|
118
|
$data.resourceId = resourceID;
|
83
|
119
|
}
|
84
|
120
|
//console.log($data);
|
85
|
|
// resourceName();
|
|
121
|
resourceName();
|
86
|
122
|
// professor();
|
87
|
|
// supportedServices();
|
88
|
|
if(resourceNamePass && professorPass && supportedServicesPass)
|
|
123
|
supportedServices();
|
|
124
|
if(resourceNamePass && supportedServicesPass)
|
89
|
125
|
{
|
90
|
126
|
$.ajax({"url" : "/ajax/resource",
|
91
|
127
|
"type" : resourceID ? "PUT" : "POST",
|
92
|
128
|
"success" : function(rdata) {
|
93
|
129
|
if (rdata.success) {
|
94
|
|
if (resourceID) {
|
95
|
|
getDataResource1(indexNum);
|
|
130
|
if (resourceID) {
|
96
|
131
|
$(".blackcover").remove();
|
97
|
|
$("body").css("overflow-y","auto");
|
|
132
|
$("body").css("overflow-y","auto");
|
|
133
|
$.MsgBox.Confirm("消息", "确定修改吗?",getDataResource);
|
98
|
134
|
|
99
|
135
|
} else {
|
100
|
136
|
$(".blackcover").remove();
|
101
|
137
|
$("body").css("overflow-y","auto");
|
102
|
|
getConresource();
|
|
138
|
getDataResource();
|
|
139
|
$.MsgBox.Alert("消息","资源发布成功");
|
103
|
140
|
}
|
104
|
141
|
} else {
|
105
|
142
|
$.MsgBox.Alert("消息","资源发布失败");
|
|
@ -113,219 +150,8 @@ $(function(){
|
113
|
150
|
}
|
114
|
151
|
});
|
115
|
152
|
});
|
116
|
|
//查询当前用户的资源
|
117
|
|
function getDataResource1(mm1){
|
118
|
|
$.ajax({
|
119
|
|
"url":"/ajax/resource/qapro",
|
120
|
|
"type":"get",
|
121
|
|
"async": true,
|
122
|
|
"data":{"professorId":userid},
|
123
|
|
"success":function(data){
|
124
|
|
if(data.success)
|
125
|
|
{ // console.log(data);
|
126
|
|
// console.log(mm1);
|
127
|
|
if(data.data[mm1].subject==undefined){
|
128
|
|
$(".li1").eq(mm1).css({"display":"none"});
|
129
|
|
}else{
|
130
|
|
$(".li1").eq(mm1).text("应用行业:"+ data.data[mm1].subject);
|
131
|
|
}
|
132
|
|
/*if(data.data[mm1].industry==undefined){
|
133
|
|
$(".li2").eq(mm1).css({"display":"none"});
|
134
|
|
}else{
|
135
|
|
$(".li2").eq(mm1).text("可提供服务:"+data.data[mm1].industry);
|
136
|
|
}
|
137
|
|
if(data.data[mm1].hopePayMethod==undefined){
|
138
|
|
$(".li3").eq(mm1).css({"display":"none"});
|
139
|
|
}else{
|
140
|
|
$(".li3").eq(mm1).text("期望付款方式:" +data.data[mm1].hopePayMethod);
|
141
|
|
}
|
142
|
|
if(data.data[mm1].descp==undefined){
|
143
|
|
$(".li4").eq(mm1).css({"display":"none"});
|
144
|
|
}else{
|
145
|
|
$(".li4").eq(mm1).text("详细描述:" +data.data[mm1].descp)
|
146
|
|
}
|
147
|
|
if(data.data[mm1].cooperationNotes==undefined){
|
148
|
|
$(".li5").eq(mm1).css({"display":"none"});
|
149
|
|
}else{
|
150
|
|
$(".li5").eq(mm1).text("备注:" +data.data[mm1].cooperationNotes)
|
151
|
|
//alert(data.data[mm1].cooperationNotes);
|
152
|
|
} */
|
153
|
|
}
|
154
|
|
else
|
155
|
|
{
|
156
|
|
$.MsgBox.Alert('message',"系统异常!");
|
157
|
|
}
|
158
|
|
},
|
159
|
|
"error":function(){$.MsgBox.Alert('message','failed')}
|
160
|
|
});
|
161
|
|
}
|
162
|
|
var oLength;
|
163
|
|
function getConresource(){
|
164
|
|
$.ajax({
|
165
|
|
"url":"/ajax/resource/qapro",
|
166
|
|
"type":"get",
|
167
|
|
"async": true,
|
168
|
|
"data":{"professorId":userid},
|
169
|
|
"success":function(data){
|
170
|
|
if(data.success)
|
171
|
|
{
|
172
|
|
var add='';
|
173
|
|
var k=0;
|
174
|
|
console.log(oLength);
|
175
|
|
for(var i=oLength;i<data.data.length;i++)
|
176
|
|
{
|
177
|
|
var add='<div class="maintab"><div class="lefttab fl"><table class="resoubrief"><tr><td><img width="100%" height="140" src=""></td>'
|
178
|
|
add+='</tr><tr><td><ul><li>'+data.data[i].resourceName+'</li><li>'+data.data[i].supportedServices+'</li> '
|
179
|
|
add+='<li class="li1">'+data.data[i].subject+'</li> '
|
180
|
|
add+='</ul></td></tr><tr>'
|
181
|
|
add+='<td><span class="resoumag"">资源管理</span></td></tr></table></div>'
|
182
|
|
add+='<div class="righttab fr"><table width="100%" class="worktab tablecon">'
|
183
|
|
add+='<tr class="worktabtit"><th width="12%" height="40">申请时间</th><th width="12%">需求方</th>'
|
184
|
|
add+='<th width="12%">联系人</th><th width="12%">交付时间</th><th width="12%">成交金额</th><th width="12%">付款方式</th>'
|
185
|
|
add+='<th width="14%">付款进程</th><th width="14%">状态/操作</th></tr></table></div></div>';
|
186
|
|
$("#consd").append(add);
|
187
|
|
if(data.data[i].subject==undefined){
|
188
|
|
$(".li1").eq(i).css({"display":"none"});
|
189
|
|
}
|
190
|
|
/*if(data.data[i].industry==undefined){
|
191
|
|
$(".li2").eq(i).css({"display":"none"});
|
192
|
|
}
|
193
|
|
if(data.data[i].hopePayMethod==undefined){
|
194
|
|
$(".li3").eq(i).css({"display":"none"});
|
195
|
|
}
|
196
|
|
if(data.data[i].descp==undefined){
|
197
|
|
$(".li4").eq(i).css({"display":"none"});
|
198
|
|
}
|
199
|
|
if(data.data[i].cooperationNotes==undefined){
|
200
|
|
$(".li5").eq(i).css({"display":"none"});
|
201
|
|
}*/
|
202
|
|
$('.resoumag').eq(i+1).attr("resourceId",data.data[i].resourceId);
|
203
|
|
(function(i){
|
204
|
|
$.ajax({
|
205
|
|
"url":"/ajax/operation/pqres",
|
206
|
|
"type":"get",
|
207
|
|
"async": true,
|
208
|
|
"data":{"resourceId":$('.resoumag').eq(i+1).attr("resourceId")},
|
209
|
|
"success":function(data){
|
210
|
|
//alert("资源id");
|
211
|
|
|
212
|
|
if(data.success)
|
213
|
|
{//console.log(data);
|
214
|
|
for(var j=0;j<data.data.length;j++){
|
215
|
|
if(data.data.data[j].dealPrice==undefined)
|
216
|
|
{
|
217
|
|
data.data.data[j].dealPrice=0;
|
218
|
|
}
|
219
|
|
if(data.data.data[j].payMethod==undefined){
|
220
|
|
data.data.data[j].payMethod="";
|
221
|
|
}
|
222
|
|
var inquiry=inquiryGetPaidMoney(data.data.data[j].operationId);
|
223
|
|
var addString='<tr class="workitem">'
|
224
|
|
addString+='<td>'+data.data.data[j].dealTime+'</td>'
|
225
|
|
addString+='<td class="workitemsrc">'+data.data.data[j].applysquare+'</td>'
|
226
|
|
addString+='<td> <a class="worktel" href="">'+data.data.data[j].professor.name+'<span class="worktelbtn"></span></a></td>'
|
227
|
|
addString+='<td>'+data.data.data[j].deliverTime+'</td>'
|
228
|
|
addString+='<td class="price1">'+data.data.data[j].dealPrice+'</td>'
|
229
|
|
addString+='<td>'+data.data.data[j].payMethod+'</td>'
|
230
|
|
addString+='<td><span>'+inquiry+'</span>/<span>'+data.data.data[j].dealPrice+'</span><br></td>'
|
231
|
|
addString+='<td><div class="modification"></div></td> </tr>'
|
232
|
|
$(".tablecon").eq(i).append(addString);
|
233
|
|
if($(".price1").eq(k).text()==0){
|
234
|
|
$(".price1").eq(k).text("");
|
235
|
|
}
|
236
|
|
switch(data.data.data[j].operationStatus)
|
237
|
|
{
|
238
|
|
case 1:
|
239
|
|
var string='<span>新的申请</span><br/>'
|
240
|
|
string+='<a class="operatebtn">'
|
241
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>回复申请</span><br />'
|
242
|
|
string+='</a>'
|
243
|
|
$(".modification").eq(k).html(string)
|
244
|
|
break;
|
245
|
|
case 2:
|
246
|
|
var string='<span>发送报价待对方确认</span><br/>'
|
247
|
|
string+='<a class="operatebtn">'
|
248
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus="2" operationId='+data.data.data[j].operationId+'>修改报价</span><br />'
|
249
|
|
string+='</a>'
|
250
|
|
$(".modification").eq(k).html(string);
|
251
|
|
break;
|
252
|
|
case 3:
|
253
|
|
var string='<span>对方发来报价合作进行中</span><br/>'
|
254
|
|
string+='<a class="operatebtn">'
|
255
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>查看详情</span><br />'
|
256
|
|
string+='<span class="drawback"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>退款</span><br />'
|
257
|
|
string+='<span resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>投诉</span>'
|
258
|
|
string+='</a>'
|
259
|
|
$(".modification").eq(k).html(string);
|
260
|
|
break;
|
261
|
|
case 4:
|
262
|
|
var string='<span>对方拒绝报价,合作结束</span><br/>'
|
263
|
|
string+='<a class="operatebtn">'
|
264
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>查看详情</span><br />'
|
265
|
|
string+='</a>'
|
266
|
|
$(".modification").eq(k).html(string);
|
267
|
|
break;
|
268
|
|
case 5:
|
269
|
|
var string='<span>本人拒绝合作</span><br/>'
|
270
|
|
string+='<a class="operatebtn">'
|
271
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>查看详情</span><br />'
|
272
|
|
string+='</a>'
|
273
|
|
$(".modification").eq(k).html(string);
|
274
|
|
break;
|
275
|
|
case 6:
|
276
|
|
var string='<span>对方中止合作合作结束</span><br/>'
|
277
|
|
string+='<a class="operatebtn">'
|
278
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>查看详情</span><br />'
|
279
|
|
//string+='<span class="discuss" dataStatus="1"resourceId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>评价</span><br />'
|
280
|
|
string+='<span class="drawback"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>退款</span><br />'
|
281
|
|
string+='<span class="complain"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>投诉</span>'
|
282
|
|
string+='</a>'
|
283
|
|
$(".modification").eq(k).html(string);
|
284
|
|
break;
|
285
|
|
case 7:
|
286
|
|
var string='<span>合作进行中</span><br/>'
|
287
|
|
string+='<a class="operatebtn">'
|
288
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>查看详情</span><br />'
|
289
|
|
string+='<span class="acknowledgement"resourceId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>确认完成</span><br />'
|
290
|
|
string+='<span class="complain"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>投诉</span>'
|
291
|
|
string+='</a>'
|
292
|
|
$(".modification").eq(k).html(string);
|
293
|
|
break;
|
294
|
|
case 8:
|
295
|
|
var string='<span>完成</span><br/>'
|
296
|
|
string+='<a class="operatebtn">'
|
297
|
|
string+='<span class="detailmess"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+' dealPrice='+data.data.data[j].dealPrice+'>查看详情</span><br />'
|
298
|
|
//string+='<span class="discuss" dataStatus="1"resourceId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>评价</span><br />'
|
299
|
|
string+='<span class="complain"resourId='+data.data.data[j].resource.resourceId+' operationStatus='+data.data.data[j].operationStatus+' operationId='+data.data.data[j].operationId+'>投诉</span>'
|
300
|
|
string+='</a>'
|
301
|
|
$(".modification").eq(k).html(string);
|
302
|
|
break;
|
303
|
|
default:
|
304
|
|
|
305
|
|
}
|
306
|
|
k++;
|
307
|
|
addString="";
|
308
|
|
}
|
309
|
|
|
310
|
|
}
|
311
|
|
else
|
312
|
|
{
|
313
|
|
$.MsgBox.Alert("消息","系统异常!");
|
314
|
|
}
|
315
|
|
},
|
316
|
|
"error":function(){$.MsgBox.Alert('message','failed')}
|
317
|
|
});
|
318
|
|
|
319
|
|
})(i);
|
320
|
|
add="";
|
321
|
|
}
|
322
|
|
}
|
323
|
|
oLength=data.data.length;
|
324
|
|
}
|
325
|
|
})
|
326
|
|
}
|
|
153
|
|
327
|
154
|
getDataResource();
|
328
|
|
var t=0;
|
329
|
155
|
function getDataResource(){
|
330
|
156
|
$.ajax({
|
331
|
157
|
"url":"/ajax/resource/qapro",
|
|
@ -334,10 +160,10 @@ $(function(){
|
334
|
160
|
"data":{"professorId":userid},
|
335
|
161
|
"success":function(data){
|
336
|
162
|
if(data.success)
|
337
|
|
{var add='';
|
|
163
|
{
|
|
164
|
var add='';
|
338
|
165
|
var k=0;
|
339
|
|
|
340
|
|
oLength=data.data.length;
|
|
166
|
$("#consd").html("");
|
341
|
167
|
for(var i=0;i<data.data.length;i++)
|
342
|
168
|
{
|
343
|
169
|
var add='<div class="maintab"><div class="lefttab fl"><table class="resoubrief"><tr><td><img width="100%" height="140" src=""></td>'
|
|
@ -346,26 +172,13 @@ $(function(){
|
346
|
172
|
add+='</ul></td></tr><tr>'
|
347
|
173
|
add+='<td><span class="resoumag"">资源管理</span></td></tr></table></div>'
|
348
|
174
|
add+='<div class="righttab fr"><table width="100%" class="worktab tablecon">'
|
349
|
|
add+='<tr class="worktabtit"><th width="12%" height="40">申请时间</th><th width="12%">需求方</th>'
|
350
|
|
add+='<th width="12%">联系人</th><th width="12%">交付时间</th><th width="12%">成交金额</th><th width="12%">付款方式</th>'
|
351
|
|
add+='<th width="14%">付款进程</th><th width="14%">状态/操作</th></tr></table><div class="tcdPageCode tcdPageCod'+i+'"></div></div>';
|
|
175
|
add+='<tr class="worktabtit"><th width="20%" height="40">申请时间</th><th width="20%">需求方</th>'
|
|
176
|
add+='<th width="12%">联系人</th><th width="14%">交付时间</th>'
|
|
177
|
add+='<th width="20%">付款进程</th><th width="14%">状态/操作</th></tr></table><div class="tcdPageCode tcdPageCod'+i+'"></div></div>';
|
352
|
178
|
$("#consd").append(add);
|
353
|
179
|
if(data.data[i].subject==undefined){
|
354
|
180
|
$(".li1").eq(i).css({"display":"none"});
|
355
|
|
}
|
356
|
|
/*if(data.data[i].industry==undefined){
|
357
|
|
$(".li2").eq(i).css({"display":"none"});
|
358
|
|
}
|
359
|
|
if(data.data[i].hopePayMethod==undefined){
|
360
|
|
$(".li3").eq(i).css({"display":"none"});
|
361
|
|
}
|
362
|
|
if(data.data[i].descp==undefined){
|
363
|
|
$(".li4").eq(i).css({"display":"none"});
|
364
|
|
}
|
365
|
|
if(data.data[i].cooperationNotes==undefined){
|
366
|
|
$(".li5").eq(i).css({"display":"none"});
|
367
|
|
}*/
|
368
|
|
|
|
181
|
}
|
369
|
182
|
$('.resoumag').eq(i+1).attr("resourceId",data.data[i].resourceId);
|
370
|
183
|
//console.log($('.resoumag').eq(i+1).attr("resourceId"));
|
371
|
184
|
//资源所对应的记录
|
|
@ -388,7 +201,7 @@ $(function(){
|
388
|
201
|
}
|
389
|
202
|
function getPageResource(pageSize,pageNo,isbind,e,f)
|
390
|
203
|
{
|
391
|
|
$(".maintab").eq(f).find(".workitem").remove();
|
|
204
|
|
392
|
205
|
$.ajax({
|
393
|
206
|
"url":"/ajax/operation/pqres",
|
394
|
207
|
"type":"get",
|
|
@ -396,8 +209,11 @@ $(function(){
|
396
|
209
|
"data":{"resourceId":$('.resoumag').eq(e+1).attr("resourceId"),"pageSize":pageSize,"pageNo":pageNo},
|
397
|
210
|
"success":function(data){
|
398
|
211
|
if(data.success)
|
399
|
|
{ console.log(data);
|
400
|
|
for(var j=0;j<data.data.data.length;j++){
|
|
212
|
{
|
|
213
|
$(".maintab").eq(f).find(".workitem").remove();
|
|
214
|
|
|
215
|
for(var j=0;j<data.data.data.length;j++)
|
|
216
|
{
|
401
|
217
|
if(data.data.data[j].dealPrice==undefined)
|
402
|
218
|
{
|
403
|
219
|
data.data.data[j].dealPrice=0;
|
|
@ -416,8 +232,8 @@ $(function(){
|
416
|
232
|
addString+='<td class="workitemsrc">'+data.data.data[j].applysquare+'</td>'
|
417
|
233
|
addString+='<td> <a class="worktel" href="">'+data.data.data[j].professor.name+'<span class="worktelbtn"></span></a></td>'
|
418
|
234
|
addString+='<td>'+data.data.data[j].deliverTime+'</td>'
|
419
|
|
addString+='<td class="price1'+e+'">'+data.data.data[j].dealPrice+'</td>'
|
420
|
|
addString+='<td>'+data.data.data[j].payMethod+'</td>'
|
|
235
|
//addString+='<td class="price1'+e+'">'+data.data.data[j].dealPrice+'</td>'
|
|
236
|
//addString+='<td>'+data.data.data[j].payMethod+'</td>'
|
421
|
237
|
addString+='<td><span>'+inquiry+'</span>/<span>'+data.data.data[j].dealPrice+'</span><br></td>'
|
422
|
238
|
addString+='<td><div class="modification'+e+'"></div></td> </tr>'
|
423
|
239
|
$(".tablecon").eq(e).append(addString);
|
|
@ -496,16 +312,21 @@ $(function(){
|
496
|
312
|
}
|
497
|
313
|
addString="";
|
498
|
314
|
}
|
499
|
|
if(isbind == true)
|
500
|
|
{
|
501
|
|
$(".tcdPageCod"+e+"").createPage({
|
502
|
|
pageCount:Math.ceil(data.data.total/pageSize),
|
503
|
|
current:data.data.pageNo,
|
504
|
|
backFn:function(p){
|
505
|
|
getPageResource(3,p,false,e,f);
|
506
|
|
}
|
507
|
|
});
|
508
|
|
}
|
|
315
|
|
|
316
|
if(data.data.total == 0){
|
|
317
|
|
|
318
|
}else{
|
|
319
|
if(isbind == true)
|
|
320
|
{
|
|
321
|
$(".tcdPageCod"+e+"").createPage({
|
|
322
|
pageCount:Math.ceil(data.data.total/pageSize),
|
|
323
|
current:data.data.pageNo,
|
|
324
|
backFn:function(p){
|
|
325
|
getPageResource(3,p,false,e,f);
|
|
326
|
}
|
|
327
|
});
|
|
328
|
}
|
|
329
|
}
|
509
|
330
|
}
|
510
|
331
|
else
|
511
|
332
|
{
|
|
@ -708,7 +529,7 @@ function getPageData(pageSize,pageNo,isbind){
|
708
|
529
|
{
|
709
|
530
|
$(".worktabb").html("");
|
710
|
531
|
var stringTitle="";
|
711
|
|
stringTitle +='<tr class="worktabtit"><th width="12%" height="40">申请时间</th><th width="12%">需求资源</th><th width="12%">资源发布者</th><th width="12%">交付时间</th><th width="12%">成交金额</th><th width="12%">付款方式</th><th width="12%">付款进程</th><th width="14%">状态/操作</th></tr>';
|
|
532
|
stringTitle +='<tr class="worktabtit"><th width="20%" height="40">申请时间</th><th width="20%">需求资源</th><th width="12%">发布者</th><th width="14%">交付时间</th><th width="20%">付款进程</th><th width="14%">状态/操作</th></tr>';
|
712
|
533
|
$(".worktabb").append( stringTitle);
|
713
|
534
|
|
714
|
535
|
//console.log(data);
|
|
@ -733,8 +554,8 @@ function getPageData(pageSize,pageNo,isbind){
|
733
|
554
|
stringContent +='<td class="workitemsrc">'+data.data.data[i].resource.resourceName+'</td>'
|
734
|
555
|
stringContent +='<td> <a class="worktel" href="">'+data.data.data[i].resource.professor.name+'<span class="worktelbtn"></span></a></td>'
|
735
|
556
|
stringContent +='<td>'+data.data.data[i].deliverTime+'</td>'
|
736
|
|
stringContent +='<td class="price2">'+data.data.data[i].dealPrice+'</td>'
|
737
|
|
stringContent +='<td>'+data.data.data[i].payMethod+'</td>'
|
|
557
|
//stringContent +='<td class="price2">'+data.data.data[i].dealPrice+'</td>'
|
|
558
|
//stringContent +='<td>'+data.data.data[i].payMethod+'</td>'
|
738
|
559
|
stringContent +='<td><span>'+inq+'</span>/<span>'+data.data.data[i].dealPrice+'</span><br></td>'
|
739
|
560
|
stringContent +='<td><div class="loginStatus"></div></td></tr>'
|
740
|
561
|
$(".worktabb").append( stringContent);
|