Subversion Repositories SmartDukaan

Rev

Rev 23319 | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
19248 kshitij.so 1
<html>
2
<head>
3
<script src="/Support/js/jquery-1.5.1.min.js"></script>
4
<script type="text/javascript" src="/Support/js/jquery.alerts.js"></script>
5
<script type="text/javascript">
6
  $(function(){	
7
	$(".add-update-vendor-pricing").live('click', function() {
8
		loadVendorPricing("content");
9
    });
10
 
19988 kshitij.so 11
	$(".download-virtual").live('click', function() {
12
		loadDownloadVirtual("content");
13
    });
23319 amit.gupta 14
	$(".upload-tax-rate").live('click', function() {
15
		loadTaxRateDiv("content");
16
    });
19988 kshitij.so 17
 
19248 kshitij.so 18
	$(".add-update-catalog").live('click', function() {
19
		loadCatalogDiv("content");
20
    });
21
 
22
	$(".add-update-virtual").live('click', function() {
23
		loadVirtualDiv("content");
24
    });
25
 
26
	$(".add-items-dtr").live('click', function() {
27
		loadDtrDiv("content");
28
    });
29
 
30
	$("#uploadVendorPricing").live('submit', function(){
31
    var formData = new FormData($(this)[0]);
32
 
33
    jQuery.ajax({
34
        url: "/Support/bulk-add!addVendorItemPricing",
35
        type: 'POST',
36
        data: formData,
37
        async: false,
38
        success: function (data) {
39
			alert(data);
19251 kshitij.so 40
			$('#uploadVendorPricing')[0].reset();
19248 kshitij.so 41
        },
42
		 error : function() {
43
		 	jAlert("OOPS!!!Failed to do changes.Try Again.",'ERROR');
44
		 },
45
        cache: false,
46
        contentType: false,
47
        processData: false
48
    });
49
    return false;
50
	});
51
 
52
	$("#uploadItemPricing").live('submit', function(){
53
    var formData = new FormData($(this)[0]);
54
 
55
    jQuery.ajax({
56
        url: "/Support/bulk-add!updateItemPricing",
57
        type: 'POST',
58
        data: formData,
59
        async: false,
60
        success: function (data) {
61
			alert(data);
19251 kshitij.so 62
			$('#uploadItemPricing')[0].reset();
19248 kshitij.so 63
        },
64
		 error : function() {
65
		 	jAlert("OOPS!!!Failed to do changes.Try Again.",'ERROR');
66
		 },
67
        cache: false,
68
        contentType: false,
69
        processData: false
70
    });
71
    return false;
72
	});
73
 
74
 
75
	$("#uploadVirtualInventory").live('submit', function(){
76
    var formData = new FormData($(this)[0]);
77
 
78
    jQuery.ajax({
79
        url: "/Support/bulk-add!updateVirtualInventory",
80
        type: 'POST',
81
        data: formData,
82
        async: false,
83
        success: function (data) {
19251 kshitij.so 84
			$('#uploadVirtualInventory')[0].reset();
19248 kshitij.so 85
			alert(data);
86
        },
87
		 error : function() {
88
		 	jAlert("OOPS!!!Failed to do changes.Try Again.",'ERROR');
89
		 },
90
        cache: false,
91
        contentType: false,
92
        processData: false
93
    });
94
    return false;
95
	});
96
 
97
	$("#uploadProfitmandi").live('submit', function(){
98
    var formData = new FormData($(this)[0]);
99
 
100
    jQuery.ajax({
101
        url: "/Support/bulk-add!uploadItemsDtr",
102
        type: 'POST',
103
        data: formData,
104
        async: false,
105
        success: function (data) {
19251 kshitij.so 106
			$('#uploadProfitmandi')[0].reset();
19248 kshitij.so 107
			alert(data);
108
        },
109
		 error : function() {
110
		 	jAlert("OOPS!!!Failed to do changes.Try Again.",'ERROR');
111
		 },
112
        cache: false,
113
        contentType: false,
114
        processData: false
115
    });
116
    return false;
117
	});
118
 
119
});  
120
</script>
121
<script type="text/javascript">
122
function loadVendorPricing(domId){
123
jQuery.ajax({
124
        type : "GET",
125
        url : "/Support/bulk-add!loadVendorDiv",
126
        success : function(response) {
127
            $('#' + domId).html(response);
128
        }
129
    });  
130
}
131
function loadCatalogDiv(domId){
132
jQuery.ajax({
133
        type : "GET",
134
        url : "/Support/bulk-add!loadCatalogDiv",
135
        success : function(response) {
136
            $('#' + domId).html(response);
137
        }
138
    });  
139
}
140
function loadVirtualDiv(domId){
141
jQuery.ajax({
142
        type : "GET",
143
        url : "/Support/bulk-add!loadVirtualDiv",
144
        success : function(response) {
145
            $('#' + domId).html(response);
146
        }
147
    });  
148
}
149
function loadDtrDiv(domId){
150
jQuery.ajax({
151
        type : "GET",
152
        url : "/Support/bulk-add!loadDtrDiv",
153
        success : function(response) {
154
            $('#' + domId).html(response);
155
        }
156
    });  
157
}
19988 kshitij.so 158
function loadDownloadVirtual(domId){
159
jQuery.ajax({
160
        type : "GET",
161
        url : "/Support/bulk-add!loadDownloadVirtualDiv",
162
        success : function(response) {
163
            $('#' + domId).html(response);
164
        }
165
    });  
166
}
23313 amit.gupta 167
function loadTaxRateDiv(domId){
23318 amit.gupta 168
let response = '<p style="font-size: 14px;">Upload Tax Rate:</p>\
23324 amit.gupta 169
		<form id="uploadTaxSheet" name="fileUpload" action="/Support/bulk-add!uploadTaxRateSheet" enctype="multipart/form-data" method="post">\
23313 amit.gupta 170
			<label for="filePath" style="font-size: 14px;">Path : </label>\
171
			<input type="file" name="file" id="file">\
172
			<input type="submit" value="Upload" name="upload">\
23318 amit.gupta 173
        </form>\
23313 amit.gupta 174
<hr/>'
175
$('#' + domId).html(response);
176
}
19248 kshitij.so 177
</script>
178
<style>
179
	#content{
180
	margin-top:20px;
181
	}
182
</style>
183
<link href="/Support/css/jquery.alerts.css" type="text/css" rel="stylesheet">
184
</head>
185
<body>
186
<span><a href="/Support/reports">Back</a></span>	
187
<div style="margin: 5px;">&nbsp;</div>
188
<h4>Inventory /Catalog /Dtr Bulk Add</h4>
189
<div class="options">
190
<hr>
191
<a target="_blank" href="http://173.255.253.139/vendor-item-pricing.xls">Download Vendor Item Pricing Template</a>
192
<br>
193
<br>
194
<a href="/Support/bulk-add!downloadVendors">Download Vendors</a>
195
<br>
196
<br>
197
<a href="#" class="add-update-vendor-pricing">Add or Update Vendor Item Pricing</a>
198
<hr>
199
<br>
200
<a target="_blank" href="http://173.255.253.139/item-pricing.xls">Download Item Pricing Template</a>
201
<br>
202
<br>
203
<a href="#" class="add-update-catalog">Update Item / Private Deals</a>
204
<br>
205
<br>
206
<hr>
207
<br>
208
<a target="_blank" href="http://173.255.253.139/virtual-inventory.xls">Download Virtual Inventory Template</a>
209
<br>
210
<br>
211
<a href="/Support/bulk-add!downloadWarehouses">Download Warehouses</a>
212
<br>
213
<br>
214
<a href="#" class="add-update-virtual">Update Virtual Inventory</a>
215
<br>
216
<br>
19988 kshitij.so 217
<a href="#" class="download-virtual">Download Virtual Inventory</a>
218
<br>
219
<br>
19248 kshitij.so 220
<hr>
221
<a target="_blank" href="http://173.255.253.139/profitmandi-template.xls">Download Profitmandi Template</a>
222
<br>
223
<br>
224
<a href="#" class="add-items-dtr">Add items to profitmandi</a>
225
<hr>
23313 amit.gupta 226
<a target="_blank" href="http://173.255.253.139/bulk-tax-add-template.xls">Download Tax Rate Template</a>
227
<br>
228
<br>
229
<a href="#" class="upload-tax-rate">Upload Tax Rate</a>
230
<hr>
19248 kshitij.so 231
</div>
232
<div id="content">
233
</div>
234
</body>
235
</html>