Spaces:
Running
Running
Update script.js
Browse files
script.js
CHANGED
@@ -184,7 +184,8 @@ document.addEventListener('DOMContentLoaded', function () {
|
|
184 |
name: product.name,
|
185 |
salePrice: product.salePrice,
|
186 |
purchasePrice: product.purchasePrice,
|
187 |
-
quantity: quantity
|
|
|
188 |
});
|
189 |
}
|
190 |
|
@@ -225,7 +226,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|
225 |
name: item.name,
|
226 |
quantity: item.quantity,
|
227 |
salePrice: item.salePrice,
|
228 |
-
itemsPerPack: item.itemsPerPack
|
229 |
})),
|
230 |
discount: discount
|
231 |
};
|
@@ -250,7 +251,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|
250 |
row.innerHTML = `
|
251 |
<td>${item.name}</td>
|
252 |
<td>${item.quantity}</td>
|
253 |
-
<td>${item.itemsPerPack}</td>
|
254 |
<td>${item.salePrice}</td>
|
255 |
<td>${item.quantity * item.salePrice}</td>
|
256 |
`;
|
@@ -343,7 +344,7 @@ document.addEventListener('DOMContentLoaded', function () {
|
|
343 |
row.innerHTML = `
|
344 |
<td>${item.name}</td>
|
345 |
<td>${item.quantity}</td>
|
346 |
-
<td>${item.itemsPerPack}</td>
|
347 |
<td>${item.salePrice}</td>
|
348 |
<td>${item.quantity * item.salePrice}</td>
|
349 |
`;
|
|
|
184 |
name: product.name,
|
185 |
salePrice: product.salePrice,
|
186 |
purchasePrice: product.purchasePrice,
|
187 |
+
quantity: quantity,
|
188 |
+
itemsPerPack: product.itemsPerPack // Добавляем количество штук в пачке
|
189 |
});
|
190 |
}
|
191 |
|
|
|
226 |
name: item.name,
|
227 |
quantity: item.quantity,
|
228 |
salePrice: item.salePrice,
|
229 |
+
itemsPerPack: item.itemsPerPack // Добавляем количество штук в пачке
|
230 |
})),
|
231 |
discount: discount
|
232 |
};
|
|
|
251 |
row.innerHTML = `
|
252 |
<td>${item.name}</td>
|
253 |
<td>${item.quantity}</td>
|
254 |
+
<td>${item.itemsPerPack}</td> <!-- Добавляем количество штук в пачке -->
|
255 |
<td>${item.salePrice}</td>
|
256 |
<td>${item.quantity * item.salePrice}</td>
|
257 |
`;
|
|
|
344 |
row.innerHTML = `
|
345 |
<td>${item.name}</td>
|
346 |
<td>${item.quantity}</td>
|
347 |
+
<td>${item.itemsPerPack}</td> <!-- Добавляем количество штук в пачке -->
|
348 |
<td>${item.salePrice}</td>
|
349 |
<td>${item.quantity * item.salePrice}</td>
|
350 |
`;
|