Subversion Repositories SmartDukaan

Rev

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

Rev 1623 Rev 1761
Line 9... Line 9...
9
 
9
 
10
	$("#zipcode").val($("#defaultpincode").val());
10
	$("#zipcode").val($("#defaultpincode").val());
11
 
11
 
12
    updateEstimate();
12
    updateEstimate();
13
    
13
    
14
    if(!($.cookie("uid"))){
-
 
15
    	if($.Storage.get("historyitems")){
-
 
16
    		var prodid = $("#product_id").val();
14
    var prodid = $("#product_id").val();
17
    		var hisitems = $.Storage.get("historyitems");
-
 
18
    		if (hisitems.indexOf(prodid) < 0){
-
 
19
    			//alert("prodid is" + prodid);
-
 
20
    			$.Storage.set("historyitems",  hisitems + "-" + prodid);
-
 
21
    		}
-
 
22
    		
15
    
23
    	}else{
-
 
24
    		$.Storage.set("historyitems",  $("#product_id").val());
16
	add_to_storage_set("histitems", prodid);
25
    	}
-
 
26
    }
-
 
27
	
-
 
28
    load_history_widget();
-
 
29
    
17
    
-
 
18
    load_history_widget();
-
 
19
 
30
	$("#addcart").click(function(){
20
    $("#addcart").click(function(){
31
		jQuery.ajax({
21
		jQuery.ajax({
32
			type: "POST",
22
			type: "POST",
33
			url: "/addtocart",
23
			url: "/addtocart",
34
			data: "productid=" + $("#item_id").val(),
24
			data: "productid=" + $("#item_id").val(),
35
			success: function(msg)	{
25
			success: function(msg)	{