| ||||||||||
Shopping cart software Solutions for online shops and malls | ||||||||||
|
X-Cart Home | FAQ | Forum rules | Calendar | User manuals | Login |
Display & Update Weights in Product Search List - v4.3.0 | |||
|
|
Thread Tools | Search this Thread |
#1
|
|||||||||
|
|||||||||
Display & Update Weights in Product Search List - v4.3.0
I needed a way to display and modify the product weights in the product search page results so that I could quickly go through and update multiple product weights page by page instead of having to open every product to change its weight.
I modified the steps to do this that I found in the mod for v4.0.17 to make it work in v4.3.0. find your skin1/main/products.tpl (NOT product.tpl) first right after <TD nowrap>{if $search_prefilled.sort_field eq "price"}{include file="buttons/sort_pointer.tpl" dir=$search_prefilled.sort_direction}{/if}{$lng.lbl_price} ({$config.General.currency_symbol})</TD> add this <td>Weight</td> then find <TD><INPUT type="text" size="9" maxlength="15" name="posted_data[{$products[prod].productid}][price]" value="{$products[prod].price}"{if $products[prod].is_variant eq 'Y'} readonly{/if}></TD> add <TD><INPUT type="text" size="9" maxlength="15" name="posted_data[{$products[prod].productid}][weight]" value="{$products[prod].weight}"></td> then find in your include/process_product.php # Perform SQL query to update products if (!empty($update)) db_query("UPDATE $sql_tbl[products] SET ".implode(",", $update)." WHERE productid='$k'");[/code] right after that paste # Modify weight if (isset($v["weight"])) {db_query("UPDATE $sql_tbl[products] SET weight='".doubleval($v["weight"])."'WHERE productid='$k'");} That's it, do a multiple product search and you'll see the weight column displayed on the right. Change any weights you want, click on update and it's done. Really saves time!
__________________
Gary M. Twing Eagle Mountain Outfitters eaglemtnoutfitters.com Version 4.3.0 Gold 4.4.4 in operibus |
|||||||||
#2
|
|||||||
|
|||||||
Re: Display & Update Weights in Product Search List - v4.3.0
Thanks for this. I have 4.3.1 and in the product search options trying to search for products with zero weight is not working. While I cannot update the weight from the weight column created by this addition at lease I can check the categories and see if any products have slipped in with zero weight.
__________________
4.6.4 |
|||||||
|
|||
X-Cart forums © 2001-2020
|