Community Add-Ons
| Maintainers: | studio6000 |
Easy Populate & QTpro
for osCommerce Online Merchant v2.2
This contribution combines Easy Populate 2.76 and QTPro by allowing the user to populate all fields in the products_stock table.
It will insert:
Product ID
Quantity
Attributes
Item Weight
Item Number
Item Code
You’ll have to edit the second spreadsheet manually.
Please Note: The column headers for the original spreadsheet of EP have been altered.
MUST HAVE QTPro and Easy Populate already installed in order to work.
In my case when I tried to add a new stock-tracked attribute I would get an error regarding the # of fields in the products_stock table. This is due to the modifications to the table that the original instructions ask you to do.
In order to resolve this you need to do a search for the word "insert" in the file /admin/stock.php
Once you find it replace
tep_db_query("insert into " . TABLE_PRODUCTS_STOCK . " values (0," . (int)$VARS['product_id'] . ",'$val'," . (int)$VARS['quantity'] . ")");
WITH:
tep_db_query("insert into " . TABLE_PRODUCTS_STOCK . " (
`products_stock_id` ,
`products_id` ,
`products_stock_attributes` ,
`products_stock_quantity` ,
`st_item_number`
)values (0," . (int)$VARS['product_id'] . ",'$val'," . (int)$VARS['quantity'] . "," . (int)$VARS['product_id'] . ")");
}
