Subversion Repositories SmartDukaan

Rev

Rev 29515 | Rev 31568 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 29515 Rev 31447
Line 202... Line 202...
202
	webListingTitle = $("#web-listing-title").val();
202
	webListingTitle = $("#web-listing-title").val();
203
	webListingUrl = $("#web-listing-url").val();
203
	webListingUrl = $("#web-listing-url").val();
204
	webListingRank = $("#web-listing-rank").val();
204
	webListingRank = $("#web-listing-rank").val();
205
	webListingBannerUrl = $("#web-listing-bannerurl").val();
205
	webListingBannerUrl = $("#web-listing-bannerurl").val();
206
 
206
 
-
 
207
	webListingSource = $("#listingSource").val();
-
 
208
 
207
	webListingHeaderUrl = $("#web-listing-headerurl").val();
209
	webListingHeaderUrl = $("#web-listing-headerurl").val();
208
 
210
 
209
	if (webListingTitle === "") {
211
	if (webListingTitle === "") {
210
		alert("Title is required!");
212
		alert("Title is required!");
211
		return false;
213
		return false;
Line 220... Line 222...
220
		alert("Rank  is required!");
222
		alert("Rank  is required!");
221
		return false;
223
		return false;
222
	}
224
	}
223
 
225
 
224
 
226
 
-
 
227
	if (webListingSource === "") {
-
 
228
		alert("Rank  is required!");
-
 
229
		return false;
-
 
230
	}
-
 
231
 
-
 
232
 
225
	json = { title: webListingTitle, url: webListingUrl, rank: webListingRank, bannerUrl: webListingBannerUrl, headerUrl: webListingHeaderUrl };
233
	json = { title: webListingTitle, url: webListingUrl, rank: webListingRank, bannerUrl: webListingBannerUrl, headerUrl: webListingHeaderUrl, targetSource: webListingSource };
-
 
234
	
-
 
235
	console.log(json)
226
	doPostAjaxRequestWithJsonHandler(context + "/web-listing/add", JSON.stringify(json), function(response) {
236
	doPostAjaxRequestWithJsonHandler(context + "/web-listing/add", JSON.stringify(json), function(response) {
227
		$('#main-content').html(response);
237
		$('#main-content').html(response);
228
	});
238
	});
229
}
239
}
230
 
240