Subversion Repositories SmartDukaan

Rev

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

Rev 23884 Rev 23886
Line 278... Line 278...
278
	var amount = $('#amount').val();
278
	var amount = $('#amount').val();
279
	if(amount == "" || parseFloat(amount) <= 0){
279
	if(amount == "" || parseFloat(amount) <= 0){
280
		alert("Invalid amount");
280
		alert("Invalid amount");
281
		return;
281
		return;
282
	}
282
	}
283
	var receiveDateTimeString = $('#receiveDateTime').val();
283
	var receiveDateTime = startDate;
284
	if(moment(receiveDateTimeString,"DD/MM/YYYY") > new Date()){
-
 
285
		alert("Receive Date Time can not be greater than current date");
-
 
286
		return;
-
 
287
	}
-
 
288
	var providerName = $('#rechargeProvider option:selected').text();
284
	var providerName = $('#rechargeProvider option:selected').text();
289
	if(confirm("Are you sure you want to add money to "+providerName+" wallet!") == true){
285
	if(confirm("Are you sure you want to add money to "+providerName+" wallet!") == true){
290
		doPostAjaxRequestHandler(context+"/addMoneyToRechargeProviderWallet?providerId="+providerId+"&amount="+amount+"&receiveDateTime="+receiveDateTimeString, function(response){
286
		doPostAjaxRequestHandler(context+"/addMoneyToRechargeProviderWallet?providerId="+providerId+"&amount="+amount+"&receiveDateTime="+startDate, function(response){
291
			$('#main-content').html(response);
287
			$('#main-content').html(response);
292
		});
288
		});
293
	}
289
	}
294
}
290
}
295
291