X-Cart: shopping cart software

X-Cart forums (https://forum.x-cart.com/index.php)
-   Third Party Add-Ons for X-Cart 4 (https://forum.x-cart.com/forumdisplay.php?f=45)
-   -   global_product_options (https://forum.x-cart.com/showthread.php?t=70532)

sinobest 11-14-2014 08:27 PM

global_product_options
 
6. In include/product_modify.php, add: if ($section == 'options') @include $xcart_dir."/include/global_product_options.php"; #BCSE Added
After: if ( file_exists($xcart_dir.'/modules/Product_Options/product_options.php') && is_readable($xcart_dir.'/modules/Product_Options/product_options.php') ) { include $xcart_dir.'/modules/Product_Options/product_options.php'; }

did not find:
Code:

if (            file_exists($xcart_dir.'/modules/Product_Options/product_options.php')            && is_readable($xcart_dir.'/modules/Product_Options/product_options.php')        ) {            include $xcart_dir.'/modules/Product_Options/product_options.php';        }

x-cart v4.6.5 gold


8. In include/func/func.product.php, in func_delete_product(), add: #BCSE Begin if(!empty($classes)){ $global_classids = func_query_column("SELECT classid FROM $sql_tbl[classes] WHERE classid IN ('".implode("','", $classes)."') and global = 'Y'"); if(!empty($global_classids)) foreach($global_classids as $cid){ $class_name = func_query_first_cell("select class from $sql_tbl[classes] where classid = '$cid'"); db_query("update $sql_tbl[classes] set global = 'Y' where class = '".addslashes($class_name)."' and global = 'C' limit 1"); } } #BCSE End
Before: db_query("DELETE FROM $sql_tbl[classes] where productid='$productid'");
did not find:
Code:

func_delete_product()


Do this step only if the line <li>Custom Modules doesn't exist
2a. In skin/common_files/single/menu_box.tpl and skin/common_files/admin/menu_box.tpl, add: <li>Custom Modules <div> </div> </li>
After: {include file="admin/help.tpl"}
did not find:
Code:

{include file="admin/help.tpl"}

2b. In skin/common_files/single/menu_box.tpl and skin/common_files/admin/menu_box.tpl, add: <a href="{$catalogs.admin}/add_global_options.php">{$lng.lbl_global_product_o ptions}</a>{*BCSE Added*}
After: <li>Custom Modules <div>
did not find:
Code:

<li>Custom Modules <div>

sinobest 11-14-2014 09:10 PM

Re: global_product_options
 
i have test x-cart gold plus, v4.6.5, same issues.

totaltec 11-15-2014 06:53 AM

Re: global_product_options
 
Just insert the <li>Custom Modules</li> if it does not exist.

Put it at the bottom, after the other <li> elements but before the closing </ul>

BCSE 11-15-2014 07:16 AM

Re: global_product_options
 
Please reserve critical tickets to site down issues. Gary will help you when he's in next. He works weekends sometimes.

Thank you,

Carrie

sinobest 11-20-2014 08:21 PM

Re: global_product_options
 
have installed successfully.
found another issue. how to let the same option_name has the same optionid?

i have checked xcart_product_options_lng from phpmyadmin. found as we add products, even we choose global product options, optionid still increase.

our aim is to let the same option name has the same optionid. how to global_product_options meets this please?

if global_product_options can let the same option_name has the same optionid, we plan to let the common option group written in hard code in an html page; in current situration, we can not do so, because optionid is increasing as we add new products.

tks.

BCSE 11-23-2014 03:37 PM

Re: global_product_options
 
You will have to test on option_name or some other field. Optionid will increase always.

Carrie


All times are GMT -8. The time now is 12:56 AM.

Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.