* [task#119971,done,0.3h] product selection cannot be repeated.
This commit is contained in:
@@ -175,9 +175,8 @@ window.updateItems = function()
|
||||
{
|
||||
const $product = $(this).zui('picker');
|
||||
const productID = $(this).val();
|
||||
if(productID == 0) return true;
|
||||
let currentProductItems = allItems.map(obj => ({ ...obj }));
|
||||
currentProductItems[productItems[productID].i].disabled = false;
|
||||
let currentProductItems = JSON.parse(JSON.stringify(allItems));
|
||||
if(productID != 0) currentProductItems[productItems[productID].i].disabled = false;
|
||||
|
||||
$product.render({items: currentProductItems});
|
||||
});
|
||||
|
||||
Reference in New Issue
Block a user