| 9242 |
kshitij.so |
1 |
<style>
|
|
|
2 |
* { font-family: Verdana; font-size: 96%; }
|
|
|
3 |
label {
|
|
|
4 |
float: left;
|
|
|
5 |
}
|
|
|
6 |
|
|
|
7 |
#upload > table {
|
|
|
8 |
color: #747474;
|
|
|
9 |
width: 100%;
|
|
|
10 |
}
|
|
|
11 |
|
|
|
12 |
|
|
|
13 |
#upload tbody {
|
|
|
14 |
background: url("/Support/images/center-bcg.png") repeat-y scroll right top #F6F6F6;
|
|
|
15 |
font-weight: bold;
|
|
|
16 |
}
|
|
|
17 |
|
|
|
18 |
.detail {
|
|
|
19 |
background: url("/Support/images/center-blue.png") repeat-y scroll left top #E4EBF8;
|
|
|
20 |
border-bottom: 1px solid #B3C1DB;
|
|
|
21 |
border-right: 1px solid #CED9EC;
|
|
|
22 |
color: #1F3D71;
|
|
|
23 |
height: 25px;
|
|
|
24 |
padding: 10px 0 0 24px;
|
|
|
25 |
}
|
|
|
26 |
|
|
|
27 |
.value {
|
|
|
28 |
border-bottom: 1px solid #B3C1DB;
|
|
|
29 |
border-right: 1px solid #CED9EC;
|
|
|
30 |
height: 24px;
|
|
|
31 |
text-align: center;
|
|
|
32 |
color: #747474;
|
|
|
33 |
}
|
|
|
34 |
|
|
|
35 |
select {
|
|
|
36 |
padding-top: 2px;
|
|
|
37 |
vertical-align: middle;
|
|
|
38 |
direction: ltr;
|
|
|
39 |
font-weight: bold;
|
|
|
40 |
width: 50%;
|
|
|
41 |
height: 22px;
|
|
|
42 |
}
|
|
|
43 |
|
|
|
44 |
input {
|
|
|
45 |
font-size: 12px;
|
|
|
46 |
text-align: center;
|
|
|
47 |
width: 50%;
|
|
|
48 |
font-weight: bold;
|
|
|
49 |
}
|
| 9725 |
kshitij.so |
50 |
.top-header {
|
|
|
51 |
background-color: #2789C1;
|
|
|
52 |
display: block;
|
|
|
53 |
height: 20px;
|
|
|
54 |
width: 100%;
|
|
|
55 |
}
|
|
|
56 |
|
|
|
57 |
input[type="text"][readonly] {
|
|
|
58 |
background-color: #D1D1D1;
|
|
|
59 |
}
|
|
|
60 |
|
|
|
61 |
input[type="text"][disabled] {
|
|
|
62 |
background-color: #D1D1D1;
|
|
|
63 |
}
|
| 9734 |
kshitij.so |
64 |
.border-highlight{
|
|
|
65 |
border : 3px solid #00BFFF;
|
|
|
66 |
}
|
| 9923 |
kshitij.so |
67 |
|
|
|
68 |
.border-highlight-green{
|
|
|
69 |
border : 3px solid green;
|
|
|
70 |
}
|
|
|
71 |
|
|
|
72 |
.border-highlight-red{
|
|
|
73 |
border : 3px solid red;
|
|
|
74 |
}
|
| 9242 |
kshitij.so |
75 |
</style>
|
|
|
76 |
<link href="/Support/css/jquery.alerts.css" type="text/css" rel="stylesheet">
|
|
|
77 |
<script type="text/javascript" src="/Support/js/jquery-1.4.2.js"></script>
|
|
|
78 |
<script type="text/javascript" src="/Support/js/jquery.alerts.js"></script>
|
|
|
79 |
<script type="text/javascript">
|
|
|
80 |
$(document).ready(function() {
|
|
|
81 |
$('#cancelbutton').click(function(e) {
|
|
|
82 |
window.location.href = '/Support/snapdeal-list';
|
|
|
83 |
});
|
|
|
84 |
});
|
|
|
85 |
</script>
|
|
|
86 |
<script type="text/javascript">
|
| 9923 |
kshitij.so |
87 |
$('select').change(function(){
|
|
|
88 |
var optionValue = $(this).val();
|
|
|
89 |
var selectType = parseInt($(this).attr('selectType'));
|
|
|
90 |
switch(selectType)
|
|
|
91 |
{
|
|
|
92 |
case 1:
|
|
|
93 |
if (optionValue=='True'){
|
|
|
94 |
$(this).removeClass().addClass('border-highlight-red');
|
|
|
95 |
}
|
|
|
96 |
else{
|
|
|
97 |
$(this).removeClass();
|
|
|
98 |
}
|
|
|
99 |
break;
|
|
|
100 |
case 2:
|
|
|
101 |
if (optionValue=='False'){
|
|
|
102 |
$(this).removeClass().addClass('border-highlight-red');
|
|
|
103 |
}
|
|
|
104 |
else{
|
|
|
105 |
$(this).removeClass();
|
|
|
106 |
}
|
|
|
107 |
break;
|
|
|
108 |
case 3:
|
|
|
109 |
if (optionValue=='True'){
|
|
|
110 |
$(this).removeClass().addClass('border-highlight-green');
|
|
|
111 |
}
|
|
|
112 |
else{
|
|
|
113 |
$(this).removeClass();
|
|
|
114 |
}
|
|
|
115 |
break;
|
|
|
116 |
}
|
|
|
117 |
});
|
|
|
118 |
</script>
|
|
|
119 |
<script type="text/javascript">
|
| 9242 |
kshitij.so |
120 |
function calculateStuff()
|
|
|
121 |
{
|
| 9734 |
kshitij.so |
122 |
$('input#minPosTp').removeClass("border-highlight");
|
|
|
123 |
$('input#minPosSp').removeClass("border-highlight");
|
|
|
124 |
$('input#transferPrice').removeClass("border-highlight");
|
|
|
125 |
$('input#serviceTax').removeClass("border-highlight");
|
|
|
126 |
$('input#commission').removeClass("border-highlight");
|
| 9923 |
kshitij.so |
127 |
$('input#margin').removeClass();
|
|
|
128 |
$('input#marginPer').removeClass();
|
| 9725 |
kshitij.so |
129 |
var itemWeight=$('#itemWeight').val();
|
| 9734 |
kshitij.so |
130 |
itemWeight = +itemWeight+.05;
|
|
|
131 |
console.log(itemWeight);
|
| 12133 |
kshitij.so |
132 |
var packagingCost=$('#packagingCost').val();
|
| 9242 |
kshitij.so |
133 |
if (itemWeight==0){
|
|
|
134 |
var courierCost =45;
|
|
|
135 |
}
|
|
|
136 |
else{
|
|
|
137 |
var slabs = parseInt((parseFloat(itemWeight)-.001)/.5)
|
|
|
138 |
var courierCost = 45;
|
|
|
139 |
for (var i=0;i<slabs;i++)
|
|
|
140 |
{
|
|
|
141 |
courierCost = courierCost + 35;
|
|
|
142 |
}
|
|
|
143 |
}
|
| 9734 |
kshitij.so |
144 |
console.log(courierCost);
|
| 9725 |
kshitij.so |
145 |
//courierCost = ((courierCost+0)*1.1236).toFixed(2);
|
| 11095 |
kshitij.so |
146 |
var courierCostSnapdeal=$('#courierCostMarketplace').val();
|
| 9725 |
kshitij.so |
147 |
var sellingPrice=$('#sellingPrice').val();
|
|
|
148 |
var nlc=$('#maxNlc').val();
|
|
|
149 |
var otherCost=$('#otherCost').val();
|
|
|
150 |
var othCost=parseFloat(otherCost);
|
| 12133 |
kshitij.so |
151 |
var pc=parseFloat(packagingCost);
|
| 9725 |
kshitij.so |
152 |
if ( sellingPrice==null || sellingPrice=="" || isNaN(sellingPrice) || nlc==null || nlc=="" || isNaN(nlc)){
|
| 9242 |
kshitij.so |
153 |
$('input#courierCost').val('0.00');
|
|
|
154 |
$('input#commission').val('0.00');
|
|
|
155 |
$('input#serviceTax').val('0.00');
|
| 9725 |
kshitij.so |
156 |
$('input#').val('0.00');
|
|
|
157 |
}
|
|
|
158 |
else{
|
| 9780 |
kshitij.so |
159 |
var serviceTaxRate=$('#serviceTaxRate').val();
|
|
|
160 |
console.log(serviceTaxRate)
|
|
|
161 |
var stRate = serviceTaxRate/100;
|
| 10287 |
kshitij.so |
162 |
var com=$('#commissionRate').val();
|
|
|
163 |
var comRate=(com/100);
|
|
|
164 |
console.log(comRate);
|
|
|
165 |
var pgVal=$('#pgFee').val();
|
|
|
166 |
var pgFeeRate=pgVal/100;
|
|
|
167 |
console.log(pgVal);
|
| 9780 |
kshitij.so |
168 |
var emiFeeRate=$('#emiFee').val();
|
|
|
169 |
console.log(emiFeeRate);
|
|
|
170 |
var emiFee=emiFeeRate/100;
|
|
|
171 |
var closingFee=parseFloat($('#closingFee').val());
|
|
|
172 |
var returnProvision=parseFloat($('#returnProvision').val());
|
|
|
173 |
console.log(returnProvision);
|
|
|
174 |
console.log(closingFee);
|
| 10287 |
kshitij.so |
175 |
console.log(pgFeeRate);
|
| 9725 |
kshitij.so |
176 |
var margin=$('#margin').val();
|
|
|
177 |
var vatRate=$('#vat').val();
|
|
|
178 |
if ( vatRate==null || vatRate=="" || isNaN(vatRate)){
|
|
|
179 |
jAlert('Please enter VAT Rate for item','ERROR');
|
| 9780 |
kshitij.so |
180 |
$('input#sellingPrice').val('0.00');
|
| 9242 |
kshitij.so |
181 |
return false;
|
|
|
182 |
}
|
| 9725 |
kshitij.so |
183 |
var vat=vatRate/100;
|
| 10287 |
kshitij.so |
184 |
if (pgFeeRate*parseFloat(sellingPrice)>=20){
|
|
|
185 |
var commisionPrice=((comRate+pgFeeRate)*parseFloat(sellingPrice)).toFixed(2);
|
|
|
186 |
}
|
|
|
187 |
else{
|
|
|
188 |
var commisionPrice=(comRate*parseFloat(sellingPrice)+20).toFixed(2);
|
|
|
189 |
console.log("Default pg fee block");
|
|
|
190 |
}
|
| 11095 |
kshitij.so |
191 |
console.log(+courierCostSnapdeal);
|
|
|
192 |
var ourTp=(parseFloat(sellingPrice)-parseFloat(sellingPrice)*(1+stRate)*((comRate)+emiFee)-((+courierCostSnapdeal+closingFee)*(1+stRate))-(Math.max(20,pgFeeRate*parseFloat(sellingPrice))*(1+stRate)));
|
| 9725 |
kshitij.so |
193 |
var vatValue=(((sellingPrice/(1+vat))-(nlc/(1+vat)))*vat).toFixed(2);
|
| 12133 |
kshitij.so |
194 |
var inHouseCost=(+vatValue+pc+((returnProvision/100)*sellingPrice)+othCost);
|
| 9725 |
kshitij.so |
195 |
var lowestTp=(+nlc+inHouseCost).toFixed(2);
|
| 10287 |
kshitij.so |
196 |
if (pgFeeRate*parseFloat(sellingPrice)>=20){
|
| 12133 |
kshitij.so |
197 |
var lowestSp=(+nlc+(+courierCostSnapdeal+closingFee)*(1+stRate)*(1+vat)+(pc+othCost)*(1+vat))/(1-(comRate+emiFee+pgFeeRate)*(1+stRate)*(1+vat)-(returnProvision/100)*(1+vat));
|
| 10287 |
kshitij.so |
198 |
}
|
|
|
199 |
else{
|
| 12133 |
kshitij.so |
200 |
var lowestSp=(+nlc+(+courierCostSnapdeal+closingFee+20)*(1+stRate)*(1+vat)+(pc+othCost)*(1+vat))/(1-(comRate+emiFee)*(1+stRate)*(1+vat)-(returnProvision/100)*(1+vat));
|
| 10287 |
kshitij.so |
201 |
}
|
| 9725 |
kshitij.so |
202 |
ourTp = (parseFloat(ourTp)).toFixed(2);
|
|
|
203 |
$('input#minPosTp').val(lowestTp);
|
| 9734 |
kshitij.so |
204 |
$('input#minPosSp').val(parseFloat(lowestSp).toFixed(2));
|
| 9725 |
kshitij.so |
205 |
$('input#transferPrice').val(ourTp);
|
| 11095 |
kshitij.so |
206 |
var serviceTax=(stRate*(+commisionPrice+(+courierCostSnapdeal))).toFixed(2);
|
| 9725 |
kshitij.so |
207 |
lowest_possible_tp=parseFloat(lowestTp);
|
|
|
208 |
newMargin=(ourTp-lowest_possible_tp).toFixed(2);
|
|
|
209 |
marginPercentage=(((ourTp-lowest_possible_tp)/sellingPrice)*100).toFixed(2);
|
|
|
210 |
$('input#marginPer').val(marginPercentage);
|
|
|
211 |
$('input#margin').val(newMargin);
|
| 9242 |
kshitij.so |
212 |
$('input#sellingPrice').val(sellingPrice);
|
|
|
213 |
$('input#courierCost').val(courierCost);
|
|
|
214 |
$('input#commission').val(commisionPrice);
|
|
|
215 |
$('input#serviceTax').val(serviceTax);
|
| 9734 |
kshitij.so |
216 |
$('input#minPosTp').addClass("border-highlight");
|
|
|
217 |
$('input#minPosSp').addClass("border-highlight");
|
|
|
218 |
$('input#transferPrice').addClass("border-highlight");
|
|
|
219 |
$('input#serviceTax').addClass("border-highlight");
|
|
|
220 |
$('input#commission').addClass("border-highlight");
|
|
|
221 |
$('input#margin').addClass("border-highlight");
|
|
|
222 |
$('input#marginPer').addClass("border-highlight");
|
| 9923 |
kshitij.so |
223 |
if (ourTp-lowest_possible_tp < 0){
|
|
|
224 |
$('input#margin').removeClass().addClass("border-highlight-red");
|
|
|
225 |
$('input#marginPer').addClass("border-highlight-red");
|
| 9242 |
kshitij.so |
226 |
}
|
| 9725 |
kshitij.so |
227 |
}
|
| 14780 |
manish.sha |
228 |
calculateStuffVOI();
|
| 9923 |
kshitij.so |
229 |
}
|
| 9242 |
kshitij.so |
230 |
</script>
|
| 14780 |
manish.sha |
231 |
|
| 9242 |
kshitij.so |
232 |
<script type="text/javascript">
|
| 14780 |
manish.sha |
233 |
function calculateStuffVOI()
|
|
|
234 |
{
|
|
|
235 |
$('input#minPosTpVoi').removeClass("border-highlight");
|
|
|
236 |
$('input#minPosSpVoi').removeClass("border-highlight");
|
|
|
237 |
$('input#transferPriceVOI').removeClass("border-highlight");
|
|
|
238 |
$('input#serviceTaxVOI').removeClass("border-highlight");
|
|
|
239 |
$('input#commissionVoi').removeClass("border-highlight");
|
|
|
240 |
$('input#marginVOI').removeClass();
|
|
|
241 |
$('input#marginPerVOI').removeClass();
|
|
|
242 |
var itemWeight=$('#itemWeight').val();
|
|
|
243 |
itemWeight = +itemWeight+.05;
|
|
|
244 |
console.log(itemWeight);
|
|
|
245 |
var packagingCost=$('#packagingCost').val();
|
|
|
246 |
if (itemWeight==0){
|
|
|
247 |
var courierCost =40;
|
|
|
248 |
}
|
|
|
249 |
else{
|
|
|
250 |
var slabs = parseInt((parseFloat(itemWeight)-.001)/.5)
|
|
|
251 |
var courierCost = 40;
|
|
|
252 |
for (var i=0;i<slabs;i++)
|
|
|
253 |
{
|
|
|
254 |
courierCost = courierCost + 30;
|
|
|
255 |
}
|
|
|
256 |
}
|
|
|
257 |
console.log(courierCost);
|
|
|
258 |
//courierCost = ((courierCost+0)*1.1236).toFixed(2);
|
|
|
259 |
var voiSellingPrice=$('#voiSellingPrice').val();
|
|
|
260 |
var nlc=$('#maxNlc').val();
|
|
|
261 |
var otherCost=$('#otherCost').val();
|
|
|
262 |
var othCost=parseFloat(otherCost);
|
|
|
263 |
var pc=parseFloat(packagingCost);
|
|
|
264 |
if ( voiSellingPrice==null || voiSellingPrice=="" || isNaN(voiSellingPrice) || nlc==null || nlc=="" || isNaN(nlc)){
|
|
|
265 |
$('input#courierCostVoi').val('0.00');
|
|
|
266 |
$('input#serviceTaxVoi').val('0.00');
|
|
|
267 |
$('input#commissionVoi').val('0.00');
|
|
|
268 |
}
|
|
|
269 |
else{
|
|
|
270 |
var serviceTaxRate=$('#serviceTaxRate').val();
|
|
|
271 |
console.log(serviceTaxRate)
|
|
|
272 |
var stRate = serviceTaxRate/100;
|
|
|
273 |
var com=$('#commissionRate').val();
|
|
|
274 |
var comRate=(com/100);
|
|
|
275 |
console.log(comRate);
|
|
|
276 |
var pgVal=$('#pgFee').val();
|
|
|
277 |
var pgFeeRate=pgVal/100;
|
|
|
278 |
console.log(pgVal);
|
|
|
279 |
var emiFeeRate=$('#emiFee').val();
|
|
|
280 |
console.log(emiFeeRate);
|
|
|
281 |
var emiFee=emiFeeRate/100;
|
|
|
282 |
var closingFee=parseFloat($('#closingFee').val());
|
|
|
283 |
var returnProvision=parseFloat($('#returnProvision').val());
|
|
|
284 |
console.log(returnProvision);
|
|
|
285 |
console.log(closingFee);
|
|
|
286 |
console.log(pgFeeRate);
|
|
|
287 |
var margin=$('#margin').val();
|
|
|
288 |
var vatRate=$('#vat').val();
|
|
|
289 |
if ( vatRate==null || vatRate=="" || isNaN(vatRate)){
|
|
|
290 |
jAlert('Please enter VAT Rate for item','ERROR');
|
|
|
291 |
$('input#voiSellingPrice').val('0.00');
|
|
|
292 |
return false;
|
|
|
293 |
}
|
|
|
294 |
var vat=vatRate/100;
|
|
|
295 |
if (pgFeeRate*parseFloat(voiSellingPrice)>=20){
|
|
|
296 |
var commisionPrice=((comRate+pgFeeRate)*parseFloat(voiSellingPrice)).toFixed(2);
|
|
|
297 |
}
|
|
|
298 |
else{
|
|
|
299 |
var commisionPrice=(comRate*parseFloat(voiSellingPrice)+20).toFixed(2);
|
|
|
300 |
console.log("Default pg fee block");
|
|
|
301 |
}
|
|
|
302 |
console.log(+courierCost);
|
|
|
303 |
var ourTp=(parseFloat(voiSellingPrice)-parseFloat(voiSellingPrice)*(1+stRate)*((comRate)+emiFee)-((+courierCost+closingFee)*(1+stRate))-(Math.max(20,pgFeeRate*parseFloat(voiSellingPrice))*(1+stRate)));
|
|
|
304 |
var vatValue=(((voiSellingPrice/(1+vat))-(nlc/(1+vat)))*vat).toFixed(2);
|
|
|
305 |
var inHouseCost=(+vatValue+pc+((returnProvision/100)*voiSellingPrice)+othCost);
|
|
|
306 |
var lowestTp=(+nlc+inHouseCost).toFixed(2);
|
|
|
307 |
if (pgFeeRate*parseFloat(voiSellingPrice)>=20){
|
|
|
308 |
var lowestSp=(+nlc+(+courierCost+closingFee)*(1+stRate)*(1+vat)+(pc+othCost)*(1+vat))/(1-(comRate+emiFee+pgFeeRate)*(1+stRate)*(1+vat)-(returnProvision/100)*(1+vat));
|
|
|
309 |
}
|
|
|
310 |
else{
|
|
|
311 |
var lowestSp=(+nlc+(+courierCost+closingFee+20)*(1+stRate)*(1+vat)+(pc+othCost)*(1+vat))/(1-(comRate+emiFee)*(1+stRate)*(1+vat)-(returnProvision/100)*(1+vat));
|
|
|
312 |
}
|
|
|
313 |
ourTp = (parseFloat(ourTp)).toFixed(2);
|
|
|
314 |
$('input#minPosTpVoi').val(lowestTp);
|
|
|
315 |
$('input#minPosSpVoi').val(parseFloat(lowestSp).toFixed(2));
|
|
|
316 |
$('input#transferPriceVOI').val(ourTp);
|
|
|
317 |
var serviceTax=(stRate*(+commisionPrice+(+courierCost))).toFixed(2);
|
|
|
318 |
lowest_possible_tp=parseFloat(lowestTp);
|
|
|
319 |
newMargin=(ourTp-lowest_possible_tp).toFixed(2);
|
|
|
320 |
marginPercentage=(((ourTp-lowest_possible_tp)/voiSellingPrice)*100).toFixed(2);
|
|
|
321 |
$('input#marginPerVOI').val(marginPercentage);
|
|
|
322 |
$('input#marginVOI').val(newMargin);
|
|
|
323 |
$('input#voiSellingPrice').val(voiSellingPrice);
|
|
|
324 |
$('input#courierCostVoi').val(courierCost);
|
|
|
325 |
$('input#commissionVoi').val(commisionPrice);
|
|
|
326 |
$('input#serviceTaxVOI').val(serviceTax);
|
|
|
327 |
$('input#minPosTpVoi').addClass("border-highlight");
|
|
|
328 |
$('input#minPosSpVoi').addClass("border-highlight");
|
|
|
329 |
$('input#transferPriceVOI').addClass("border-highlight");
|
|
|
330 |
$('input#serviceTaxVOI').addClass("border-highlight");
|
|
|
331 |
$('input#commissionVoi').addClass("border-highlight");
|
|
|
332 |
$('input#marginVOI').addClass("border-highlight");
|
|
|
333 |
$('input#marginPerVOI').addClass("border-highlight");
|
|
|
334 |
if (ourTp-lowest_possible_tp < 0){
|
|
|
335 |
$('input#marginVOI').removeClass().addClass("border-highlight-red");
|
|
|
336 |
$('input#marginPerVOI').addClass("border-highlight-red");
|
|
|
337 |
}
|
|
|
338 |
}
|
|
|
339 |
}
|
|
|
340 |
</script>
|
|
|
341 |
<script type="text/javascript">
|
| 9242 |
kshitij.so |
342 |
$('#populateStuff').live('click', function(){
|
| 9725 |
kshitij.so |
343 |
var itemId=$('#itemId').val();
|
|
|
344 |
var whId=$('#warehouseId').val();
|
| 9825 |
kshitij.so |
345 |
var sellingPrice=$('#sellingPrice').val();
|
| 9725 |
kshitij.so |
346 |
if ( whId==null || whId=="" || isNaN(whId)){
|
| 9478 |
kshitij.so |
347 |
jAlert('Please enter valid warehouse id', 'ERROR');
|
|
|
348 |
return false;
|
|
|
349 |
}
|
| 9825 |
kshitij.so |
350 |
if (sellingPrice==0 || sellingPrice=="" || isNaN(sellingPrice)){
|
|
|
351 |
jAlert('Illegal Entry In Selling Price', 'ERROR');
|
|
|
352 |
return false;
|
|
|
353 |
}
|
| 9242 |
kshitij.so |
354 |
jQuery.ajax({
|
|
|
355 |
type : "GET",
|
| 9825 |
kshitij.so |
356 |
url : "/Support/snapdeal-list!getItemDetailsInJson?itemId="+itemId+"&warehouseId="+whId+"&sellingPrice="+sellingPrice,
|
| 9242 |
kshitij.so |
357 |
beforeSend: function(){
|
|
|
358 |
$('#ajax-spinner').show();
|
|
|
359 |
$('#add-new-item')[0].reset();
|
|
|
360 |
},
|
|
|
361 |
complete: function(){
|
|
|
362 |
$('#ajax-spinner').hide();
|
|
|
363 |
},
|
|
|
364 |
success : function(json){
|
|
|
365 |
var parsedData = JSON.parse(json);
|
|
|
366 |
$('input#itemId').val(parsedData.ItemId);
|
|
|
367 |
$('input#brand').val(parsedData.Brand);
|
|
|
368 |
$('input#modelNumber').val(parsedData.ModelNumber);
|
|
|
369 |
$('input#modelName').val(parsedData.ModelName);
|
|
|
370 |
$('input#color').val(parsedData.Color);
|
|
|
371 |
$('input#itemWeight').val(parsedData.Weight);
|
|
|
372 |
$('input#risky').val(parsedData.Risky);
|
|
|
373 |
$('input#status').val(parsedData.Status);
|
|
|
374 |
$('input#webisteMrp').val(parsedData.MRP);
|
|
|
375 |
$('input#webisteSellingPrice').val(parsedData.SellingPrice);
|
| 9923 |
kshitij.so |
376 |
$('input#maxSp').val(0);
|
| 9780 |
kshitij.so |
377 |
$('input#commissionRate').val(parsedData.CommissionRate);
|
|
|
378 |
$('input#returnProvision').val(parsedData.ReturnProvision);
|
|
|
379 |
$('input#emiFee').val(parsedData.EmiFee);
|
|
|
380 |
$('input#closingFee').val(parsedData.ClosingFee);
|
|
|
381 |
$('input#serviceTaxRate').val(parsedData.ServiceTaxRate);
|
| 9825 |
kshitij.so |
382 |
$('input#sellingPrice').val(sellingPrice);
|
| 14780 |
manish.sha |
383 |
$('input#voiSellingPrice').val(sellingPrice);
|
| 9242 |
kshitij.so |
384 |
$('input#transferPrice').val('0.0');
|
| 14780 |
manish.sha |
385 |
$('input#transferPriceVOI').val('0.0');
|
| 9242 |
kshitij.so |
386 |
$('input#exceptionPrice').val('0.0');
|
|
|
387 |
$('input#commission').val('0.0');
|
|
|
388 |
$('input#serviceTax').val('0.0');
|
| 14780 |
manish.sha |
389 |
$('input#serviceTaxVOI').val('0.0');
|
| 9242 |
kshitij.so |
390 |
$('input#courierCost').val('0.0');
|
| 14780 |
manish.sha |
391 |
$('input#courierCostVoi').val('0.0');
|
| 9478 |
kshitij.so |
392 |
$('input#maxNlc').val(parsedData.MaxNlc);
|
| 9725 |
kshitij.so |
393 |
$('input#warehouseId').val(whId);
|
| 9825 |
kshitij.so |
394 |
$('input#vat').val(parsedData.VatRate);
|
| 10287 |
kshitij.so |
395 |
$('input#pgFee').val(parsedData.PgFee);
|
| 12133 |
kshitij.so |
396 |
$('input#packagingCost').val(parsedData.PackagingCost);
|
| 9825 |
kshitij.so |
397 |
calculateStuff();
|
| 9242 |
kshitij.so |
398 |
},
|
|
|
399 |
error : function() {
|
| 9478 |
kshitij.so |
400 |
alert("Either item id is already present in snapdeal item or not a valid item Id");
|
| 9242 |
kshitij.so |
401 |
},
|
|
|
402 |
});
|
|
|
403 |
return false;
|
|
|
404 |
});
|
|
|
405 |
</script>
|
| 9725 |
kshitij.so |
406 |
<div class="top-header">
|
|
|
407 |
<span style="float: left; padding-left: 10px; padding-top: 2px; font-size: 14px; font-weight: bolder; color: white;">
|
|
|
408 |
ADD NEW PRODUCT
|
|
|
409 |
</span>
|
|
|
410 |
</div>
|
| 9242 |
kshitij.so |
411 |
<form id="add-new-item" action="/Support/snapdeal-list!addNewItem" enctype="multipart/form-data" method="post">
|
|
|
412 |
<div class="left" style="float: left; width: 48%;">
|
|
|
413 |
<table id="upload" style="text-align: center;width: 100%;height:200px;">
|
|
|
414 |
<thead>
|
|
|
415 |
</thead>
|
|
|
416 |
<tbody>
|
|
|
417 |
<tr>
|
|
|
418 |
<td class="detail">Item Id</td>
|
|
|
419 |
<td class="value">
|
|
|
420 |
<input id="itemId" name="itemId" value=''type="text" style="width:25%;">
|
|
|
421 |
<input type="button" id="populateStuff" value="Populate" style="width:25%;">
|
|
|
422 |
</td>
|
|
|
423 |
</tr>
|
|
|
424 |
<tr>
|
|
|
425 |
<td class="detail">Brand</td>
|
|
|
426 |
<td class="value"><input id="brand" name="brand" value='' type="text" readonly/></td>
|
|
|
427 |
</tr>
|
|
|
428 |
<tr>
|
|
|
429 |
<td class="detail">Model Number</td>
|
| 9725 |
kshitij.so |
430 |
<td class="value"><input id="modelNumber" name="modelNumber" value='' type="text" disabled/></td>
|
| 9242 |
kshitij.so |
431 |
</tr>
|
|
|
432 |
<tr>
|
|
|
433 |
<td class="detail">Model Name</td>
|
| 9725 |
kshitij.so |
434 |
<td class="value"><input id="modelName" name="modelName" value='' type="text" disabled/></td>
|
| 9242 |
kshitij.so |
435 |
</tr>
|
|
|
436 |
<tr>
|
|
|
437 |
<td class="detail">Color</td>
|
| 9725 |
kshitij.so |
438 |
<td class="value"><input id="color" name="color" value='' type="text" disabled/></td>
|
| 9242 |
kshitij.so |
439 |
</tr>
|
| 9568 |
kshitij.so |
440 |
<tr class="detail"></td>
|
|
|
441 |
<td class="detail">Weight</td>
|
| 9725 |
kshitij.so |
442 |
<td class="value"><input id="itemWeight" name="itemWeight" value='0' type="text" disabled/></td>
|
| 9568 |
kshitij.so |
443 |
</tr>
|
| 9242 |
kshitij.so |
444 |
<tr>
|
|
|
445 |
<td class="detail">Risky</td>
|
|
|
446 |
<td class="value">
|
| 9725 |
kshitij.so |
447 |
<input id="risky" name="risky" value='' type="text" disabled style="text-transform: uppercase;"/></td>
|
| 9242 |
kshitij.so |
448 |
</td>
|
|
|
449 |
</tr>
|
|
|
450 |
<tr>
|
|
|
451 |
<td class="detail">Status</td>
|
| 9725 |
kshitij.so |
452 |
<td class="value"><input id="status" name="status" value='' type="text" disabled/></td>
|
| 9242 |
kshitij.so |
453 |
</tr>
|
|
|
454 |
<tr>
|
|
|
455 |
<td class="detail">Warehouse Id</td>
|
|
|
456 |
<td class="value">
|
|
|
457 |
<input id="warehouseId" name="warehouseId" value='' type="text"/></td>
|
|
|
458 |
</tr>
|
|
|
459 |
<tr>
|
| 9780 |
kshitij.so |
460 |
<td class="detail">Max NLC</td>
|
|
|
461 |
<td class="value"><input id="maxNlc" name="maxNlc" value=''type="text" readonly/></td>
|
|
|
462 |
</tr>
|
|
|
463 |
<tr>
|
| 9242 |
kshitij.so |
464 |
<td class="detail">Snapdeal Selling Price</td>
|
|
|
465 |
<td class="value">
|
| 9725 |
kshitij.so |
466 |
<input id="sellingPrice" name="sellingPrice" value='' type="text" onkeyup="calculateStuff()"></td>
|
| 9242 |
kshitij.so |
467 |
</tr>
|
|
|
468 |
<tr>
|
| 14780 |
manish.sha |
469 |
<td class="detail">Snapdeal VOI Selling Price</td>
|
|
|
470 |
<td class="value">
|
|
|
471 |
<input id="voiSellingPrice" name="voiSellingPrice" value='' type="text" onkeyup="calculateStuff()"></td>
|
|
|
472 |
</tr>
|
|
|
473 |
<tr>
|
| 9725 |
kshitij.so |
474 |
<td class="detail">Transfer Price</td>
|
|
|
475 |
<td class="value"><input id="transferPrice" name="transferPrice" value='' type="text" readonly/></td>
|
|
|
476 |
</tr>
|
|
|
477 |
<tr>
|
| 14780 |
manish.sha |
478 |
<td class="detail">Transfer Price VOI</td>
|
|
|
479 |
<td class="value"><input id="transferPriceVOI" name="transferPriceVOI" value='' type="text" readonly/></td>
|
|
|
480 |
</tr>
|
|
|
481 |
<tr>
|
| 9725 |
kshitij.so |
482 |
<td class="detail">Other Cost</td>
|
| 12133 |
kshitij.so |
483 |
<td class="value">
|
|
|
484 |
<input id="otherCost" name="otherCost" value='0.0' type="text" onkeyup="calculateStuff()" style="width:20%;" />
|
|
|
485 |
<span style="font-weight:bold;color:black;">Packaging Cost</span>
|
|
|
486 |
<input id="packagingCost" name="packagingCost" value='0.0' type="text" style="width:20%;" readonly/>
|
|
|
487 |
</td>
|
| 9725 |
kshitij.so |
488 |
</tr>
|
|
|
489 |
<tr>
|
|
|
490 |
<td class="detail">Minimum Possible SP (Calculated)</td>
|
| 9780 |
kshitij.so |
491 |
<td class="value"><input id="minPosSp" name="minPosSp" value='' type="text" readonly/></td><!--Inventory details end-->
|
| 9725 |
kshitij.so |
492 |
</tr>
|
|
|
493 |
<tr>
|
|
|
494 |
<td class="detail">Minimum Possible TP (Calculated)</td>
|
| 9242 |
kshitij.so |
495 |
<td class="value">
|
| 9725 |
kshitij.so |
496 |
<input id="minPosTp" name="minPosTp" value='' type="text" readonly/>
|
| 9242 |
kshitij.so |
497 |
</td>
|
|
|
498 |
</tr>
|
| 9478 |
kshitij.so |
499 |
<tr>
|
| 14780 |
manish.sha |
500 |
<td class="detail">Minimum Possible SP VOI(Calculated)</td>
|
|
|
501 |
<td class="value"><input id="minPosSpVoi" name="minPosSpVoi" value='' type="text" readonly/></td><!--Inventory details end-->
|
|
|
502 |
</tr>
|
|
|
503 |
<tr>
|
|
|
504 |
<td class="detail">Minimum Possible TP VOI(Calculated)</td>
|
|
|
505 |
<td class="value">
|
|
|
506 |
<input id="minPosTpVoi" name="minPosTpVoi" value='' type="text" readonly/>
|
|
|
507 |
</td>
|
|
|
508 |
</tr>
|
|
|
509 |
<tr>
|
| 9725 |
kshitij.so |
510 |
<td class="detail">Website MRP</td>
|
|
|
511 |
<td class="value"><input id="webisteMrp" name="webisteMrp" value='' type="text" disabled/></td>
|
|
|
512 |
</tr>
|
|
|
513 |
<tr>
|
|
|
514 |
<td class="detail">Website Selling Price</td>
|
|
|
515 |
<td class="value"><input id="webisteSellingPrice" name="webisteSellingPrice" value='' type="text" disabled/></td>
|
|
|
516 |
</tr>
|
| 14780 |
manish.sha |
517 |
<tr>
|
|
|
518 |
<td class="detail">SUPC Code</td>
|
|
|
519 |
<td class="value"><input id="supc" name="supc" value='' type="text"></td>
|
|
|
520 |
</tr>
|
|
|
521 |
<tr>
|
|
|
522 |
<td class="detail"></td>
|
|
|
523 |
<td class="value"></td>
|
|
|
524 |
</tr>
|
| 9242 |
kshitij.so |
525 |
</tbody>
|
|
|
526 |
</table>
|
|
|
527 |
</div>
|
|
|
528 |
<div class="left" style="float: right; width: 48%;">
|
|
|
529 |
<table id="upload" style="text-align: center;width: 100%;height:200px;">
|
|
|
530 |
<thead>
|
|
|
531 |
</thead>
|
|
|
532 |
<tbody>
|
|
|
533 |
<tr>
|
| 9725 |
kshitij.so |
534 |
<td class="detail">Margin</td>
|
| 9923 |
kshitij.so |
535 |
<td class="value"><input id="margin" name="margin" value=''type="text" style="width:20%;" disabled/>
|
|
|
536 |
<span style="font-weight:bold;color:black;">Margin %</span><input id="marginPer" name="marginPer" value='' type="text" style="width:20%;" disabled/></td>
|
|
|
537 |
</td>
|
| 9725 |
kshitij.so |
538 |
</tr>
|
|
|
539 |
<tr>
|
| 14780 |
manish.sha |
540 |
<td class="detail">Margin VOI</td>
|
|
|
541 |
<td class="value"><input id="marginVOI" name="marginVOI" value=''type="text" style="width:20%;" disabled/>
|
|
|
542 |
<span style="font-weight:bold;color:black;">Margin %</span><input id="marginPerVOI" name="marginPerVOI" value='' type="text" style="width:20%;" disabled/></td>
|
|
|
543 |
</td>
|
|
|
544 |
</tr>
|
|
|
545 |
<tr>
|
| 9923 |
kshitij.so |
546 |
<td class="detail">Maximum Selling Price</td>
|
|
|
547 |
<td class="value"><input id="maxSp" name="maxSp" value='' type="text"></td>
|
| 9725 |
kshitij.so |
548 |
</tr>
|
|
|
549 |
<tr>
|
| 9242 |
kshitij.so |
550 |
<td class="detail">Suppress Inventory Feed</td>
|
|
|
551 |
<td class="value">
|
| 9923 |
kshitij.so |
552 |
<select name="isSuppressInventoryFeed" selectType="1"><option value="True">Active</option><option selected="selected" value="False">InActive</option></select>
|
| 9242 |
kshitij.so |
553 |
</td>
|
|
|
554 |
</tr>
|
|
|
555 |
<tr>
|
| 9725 |
kshitij.so |
556 |
<td class="detail">Suppress Price Feed</td>
|
|
|
557 |
<td class="value">
|
| 9923 |
kshitij.so |
558 |
<select name="isSuppressPriceFeed" selectType="1"><option selected="selected" value="True">Active</option><option selected="selected" value="False">InActive</option></select>
|
| 9725 |
kshitij.so |
559 |
</td>
|
| 9242 |
kshitij.so |
560 |
</tr>
|
|
|
561 |
<tr>
|
| 14780 |
manish.sha |
562 |
<td class="detail">Suppress VOI Pricing Feed</td>
|
|
|
563 |
<td class="value">
|
|
|
564 |
<select name="isSuppressVoiPriceFeed" selectType="1" class="border-highlight-red"><option selected="selected" value="True">Active</option><option value="False">InActive</option></select>
|
|
|
565 |
</td>
|
|
|
566 |
</tr>
|
|
|
567 |
<tr>
|
| 9725 |
kshitij.so |
568 |
<td class="detail">Snapdeal Listed</td>
|
|
|
569 |
<td class="value">
|
| 9923 |
kshitij.so |
570 |
<select name="isListedOnSnapdeal" selectType="2"><option selected="selected" value="True">Active</option><option value="False">InActive</option></select>
|
| 9725 |
kshitij.so |
571 |
</td>
|
| 9242 |
kshitij.so |
572 |
</tr>
|
|
|
573 |
<tr>
|
| 14780 |
manish.sha |
574 |
<td class="detail">Snapdeal VOI Listed</td>
|
|
|
575 |
<td class="value">
|
|
|
576 |
<select name="isVoiListedOnSnapdeal" selectType="2"><option selected="selected" value="True">Active</option><option value="False">InActive</option></select>
|
|
|
577 |
</td>
|
|
|
578 |
</tr>
|
|
|
579 |
<tr>
|
| 9725 |
kshitij.so |
580 |
<td class="detail">Manual Favourite</td>
|
|
|
581 |
<td class="value">
|
| 9923 |
kshitij.so |
582 |
<select name="isManualFavourite" selectType="3"><option value="True">Active</option><option selected="selected" value="False">InActive</option></select>
|
| 9725 |
kshitij.so |
583 |
</td>
|
| 9242 |
kshitij.so |
584 |
</tr>
|
|
|
585 |
<tr>
|
| 9725 |
kshitij.so |
586 |
<td class="detail">Auto Increment</td>
|
| 9242 |
kshitij.so |
587 |
<td class="value">
|
| 9923 |
kshitij.so |
588 |
<select name="isAutoIncrement" selectType="3"><option value="True">Active</option><option selected="selected" value="False">InActive</option></select>
|
| 9242 |
kshitij.so |
589 |
</td>
|
|
|
590 |
</tr>
|
|
|
591 |
<tr>
|
| 9725 |
kshitij.so |
592 |
<td class="detail">Auto Decrement</td>
|
|
|
593 |
<td class="value">
|
| 9923 |
kshitij.so |
594 |
<select name="isAutoDecrement" selectType="3"><option value="True">Active</option><option selected="selected" value="False">InActive</option></select>
|
| 9725 |
kshitij.so |
595 |
</td>
|
|
|
596 |
</tr>
|
|
|
597 |
<tr>
|
| 9242 |
kshitij.so |
598 |
<td class="detail">Exception Price</td>
|
|
|
599 |
<td class="value"><input id="exceptionPrice" name="exceptionPrice" value='' type="text"/></td>
|
|
|
600 |
</tr>
|
|
|
601 |
<tr>
|
| 9725 |
kshitij.so |
602 |
<td class="detail">Commission %</td>
|
| 9780 |
kshitij.so |
603 |
<td class="value"><input id="commissionRate" name="commissionRate" value=''type="text" disabled/></td>
|
| 9725 |
kshitij.so |
604 |
</tr>
|
|
|
605 |
<tr>
|
| 9242 |
kshitij.so |
606 |
<td class="detail">Commission</td>
|
|
|
607 |
<td class="value"><input id="commission" name="commission" value='' type="text" readonly/></td>
|
|
|
608 |
</tr>
|
|
|
609 |
<tr>
|
| 14780 |
manish.sha |
610 |
<td class="detail">Commission VOI</td>
|
|
|
611 |
<td class="value"><input id="commissionVoi" name="commissionVoi" value='' type="text" readonly/></td>
|
|
|
612 |
</tr>
|
|
|
613 |
<tr>
|
| 9725 |
kshitij.so |
614 |
<td class="detail">VAT %</td>
|
| 9780 |
kshitij.so |
615 |
<td class="value"><input id="vat" name="vat" value='' type="text" onkeyup="calculateStuff()"></td>
|
| 9725 |
kshitij.so |
616 |
</tr>
|
|
|
617 |
<tr>
|
| 9242 |
kshitij.so |
618 |
<td class="detail">Service Tax</td>
|
|
|
619 |
<td class="value"><input id="serviceTax" name="serviceTax" value='' type="text" readonly/></td>
|
|
|
620 |
</tr>
|
|
|
621 |
<tr>
|
| 14780 |
manish.sha |
622 |
<td class="detail">Service Tax VOI</td>
|
|
|
623 |
<td class="value"><input id="serviceTaxVOI" name="serviceTaxVOI" value='' type="text" readonly/></td>
|
|
|
624 |
</tr>
|
|
|
625 |
<tr>
|
| 9242 |
kshitij.so |
626 |
<td class="detail">Courier Cost</td>
|
| 11095 |
kshitij.so |
627 |
<td class="value"><input id="courierCost" name="courierCost" value='' type="text" style="width:20%;" readonly/>
|
|
|
628 |
<span style="font-weight:bold;color:black;">Snapdeal</span>
|
|
|
629 |
<input id="courierCostMarketplace" name="courierCostMarketplace" value='' type="text" style="width:20%;" onkeyup="calculateStuff()">
|
|
|
630 |
</td>
|
| 9242 |
kshitij.so |
631 |
</tr>
|
|
|
632 |
<tr>
|
| 14780 |
manish.sha |
633 |
<td class="detail">Courier Cost VOI</td>
|
|
|
634 |
<td>
|
|
|
635 |
<input id="courierCostVoi" name="courierCostVoi" value='' type="text" style="width:20%;" readonly/>
|
|
|
636 |
</td>
|
|
|
637 |
</tr>
|
|
|
638 |
<tr>
|
| 9478 |
kshitij.so |
639 |
<td class="detail">Item Id @ Snapdeal</td>
|
| 11095 |
kshitij.so |
640 |
<td class="value"><input id="sdItemCode" name="sdItemCode" value='' type="text">
|
|
|
641 |
</td>
|
| 9478 |
kshitij.so |
642 |
</tr>
|
|
|
643 |
<tr>
|
| 14780 |
manish.sha |
644 |
<td class="detail">Item Id @ Snapdeal VOI</td>
|
|
|
645 |
<td class="value"><input id="sdVoiItemCode" name="sdVoiItemCode" value='' type="text"></td>
|
| 9568 |
kshitij.so |
646 |
</tr>
|
|
|
647 |
<tr>
|
| 9242 |
kshitij.so |
648 |
<td class="detail">Action</td>
|
|
|
649 |
<td class="value"><input type="submit" value="Update" name="upload" style="width: 25%;">
|
|
|
650 |
<input type="button" style="padding-left: 5px; margin-left: 10px;width: 25%;" id="cancelbutton" name="cancel" value="Cancel">
|
|
|
651 |
</td>
|
|
|
652 |
</tr>
|
| 9780 |
kshitij.so |
653 |
<tr class="detail" style="display:none;"></td>
|
|
|
654 |
<td>
|
|
|
655 |
<input id="returnProvision" name="returnProvision" value='' type="text" disabled/>
|
|
|
656 |
</td>
|
|
|
657 |
</tr>
|
|
|
658 |
<tr class="detail" style="display:none;"></td>
|
|
|
659 |
<td>
|
|
|
660 |
<input id="emiFee" name="emiFee" value='' type="text" disabled/>
|
|
|
661 |
</td>
|
|
|
662 |
</tr>
|
|
|
663 |
<tr class="detail" style="display:none;"></td>
|
|
|
664 |
<td>
|
|
|
665 |
<input id="closingFee" name="closingFee" value='' type="text" disabled/>
|
|
|
666 |
</td>
|
|
|
667 |
</tr>
|
|
|
668 |
<tr class="detail" style="display:none;"></td>
|
|
|
669 |
<td>
|
|
|
670 |
<input id="serviceTaxRate" name="serviceTaxRate" value='' type="text" disabled/>
|
| 10287 |
kshitij.so |
671 |
<input id="pgFee" name="pgFee" value='' type="text" disabled/>
|
| 9780 |
kshitij.so |
672 |
</td>
|
|
|
673 |
</tr>
|
| 9242 |
kshitij.so |
674 |
</tbody>
|
|
|
675 |
</table>
|
|
|
676 |
</div>
|
|
|
677 |
</form>
|