Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

I have updated my database and uploaded the package. Can't find the discount table in admin!


Recommended Posts

I have updated my database and uploaded the package. Can't find the discount table in admin!!!

 

I can see the: 'Discount Categories' and 'Products to Discount Categories' pages.

 

Where is the discount table?

 

Please help, I have spend so much time with QPBPP

Link to comment
Share on other sites

Where is the discount table?

In your admin/categories.php page, when you edit a product (provided you modified that page according to the instructions given).

 

Please help, I have spend so much time with QPBPP

Strange that you didn't notice the topic thread for that contribution then.

Link to comment
Share on other sites

In your admin/categories.php page, when you edit a product (provided you modified that page according to the instructions given).

 

 

Strange that you didn't notice the topic thread for that contribution then.

 

I can't find the 'Discount table page' in admin where is it?

Can you explain me better?

Link to comment
Share on other sites

I can't find the 'Discount table page' in admin where is it?

Can you explain me better?

I don't understand what you mean with Discount table page, but if you mean the table with entry fields for prices breaks as shown in screenshots/admin.jpg than that is the table in which you enter the price breaks. This is found on admin/categories.php as mentioned above.

Link to comment
Share on other sites

I don't understand what you mean with Discount table page, but if you mean the table with entry fields for prices breaks as shown in screenshots/admin.jpg than that is the table in which you enter the price breaks. This is found on admin/categories.php as mentioned above.

 

When I'am in admin/categories.php that table doesn't load, I only can see: Discount category and Quantity Blocks.

 

Do I need to change the code of admin/categories.php to see the discount table shown in screenshots/admin.jpg ?

 

Or am I missing otherthing?

Link to comment
Share on other sites

I don't understand what you mean with Discount table page, but if you mean the table with entry fields for prices breaks as shown in screenshots/admin.jpg than that is the table in which you enter the price breaks. This is found on admin/categories.php as mentioned above.

 

I have uploaded the files of QPBPP_v1_3_4 and updated the database, its running well, but I can't se the discounts table.

It seams that I don't know how to mannage the contribution. Do you have any sugestion in terms of another way to install volume discounts?

 

Regards

Filipe

Link to comment
Share on other sites

Do I need to change the code of admin/categories.php to see the discount table shown in screenshots/admin.jpg ?

Yes. The install.html shows the needed changes as the fourth file that needs changing. There a lot of changes needed so perhaps something went wrong when you added the changes.

 

If you don't have any other contributions added to that page you can use the included file in the package. If you only added a few contributions to that page it might be an idea to use the categories.php from the package and install those contributions using that file instead of trying to add QPBPP to your changed admin/categories.php file.

Link to comment
Share on other sites

Yes. The install.html shows the needed changes as the fourth file that needs changing. There a lot of changes needed so perhaps something went wrong when you added the changes.

 

If you don't have any other contributions added to that page you can use the included file in the package. If you only added a few contributions to that page it might be an idea to use the categories.php from the package and install those contributions using that file instead of trying to add QPBPP to your changed admin/categories.php file.

 

I have re-uploaded the package and I still cannot see the discount table. Am I so dummie that cannot mannage this package.

Please see for your self at http://planetlanyard.com/catalog/admin

 

username: user

password: admin

 

Feel free to test.

 

Regards

Filipe.

Link to comment
Share on other sites

I have re-uploaded the package and I still cannot see the discount table. Am I so dummie that cannot mannage this package.

Please see for your self at http://planetlanyard.com/catalog/admin

 

username: user

password: admin

 

Feel free to test.

 

Regards

Filipe.

 

I have changed the username and password, I can send you by email.

Link to comment
Share on other sites

I can't see the discounts table.

I notice from the url you gave you have been able to insert other things, so part of that table is apparently not showing. I suppose then you only see:

 

Discount category (with a dropdown menu)
Quantity Blocks:	  (can only order in blocks of X quantity)

But not Price level 1 to 10.

 

If that is so I suspect something went wrong with the sql when it was supposed to execute these two commands (perhaps 73 was already taken by some other contribution?):

 

INSERT INTO configuration_group (configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible)
VALUES ('73', 'Price breaks', 'Configuration options for price breaks', 73, 1);
INSERT into configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function)
VALUES ('Maximum number of price break levels', 'PRICE_BREAK_NOF_LEVELS', '10', 'Configures the number of price break levels that can be entered on admin side. Levels that are left empty will not be shown to the customer', '73', '1', now(), now(), NULL, NULL);

You can also check that (instead of searching your table configuration for an entry with configuration_key PRICE_BREAK_NOF_LEVELS by hard coding the number in admin/categories.php. Change (around line 16):

// BOF qpbpp
 // include the price formatter for the price breaks contribution
 require(DIR_WS_CLASSES . 'PriceFormatter.php');
 $pf = new PriceFormatter;
// EOF qpbpp

To:

// BOF qpbpp
 // include the price formatter for the price breaks contribution
 require(DIR_WS_CLASSES . 'PriceFormatter.php');
 $pf = new PriceFormatter;
 // hard coded number of iterations for PRICE_BREAK_NOF_LEVELS
 define('PRICE_BREAK_NOF_LEVELS', '5'); // or whatever number you like
// EOF qpbpp

 

Note: you should change the name of the admin directory. This is the place where all would-be hackers are trying. Needs only two changes in name_of_your_admin_directory/includes/configure.php.

Edited by Jan Zonjee
Link to comment
Share on other sites

I notice from the url you gave you have been able to insert other things, so part of that table is apparently not showing. I suppose then you only see:

 

Discount category (with a dropdown menu)
Quantity Blocks:	  (can only order in blocks of X quantity)

But not Price level 1 to 10.

 

If that is so I suspect something went wrong with the sql when it was supposed to execute these two commands (perhaps 73 was already taken by some other contribution?):

 

INSERT INTO configuration_group (configuration_group_id, configuration_group_title, configuration_group_description, sort_order, visible)
VALUES ('73', 'Price breaks', 'Configuration options for price breaks', 73, 1);
INSERT into configuration (configuration_title, configuration_key, configuration_value, configuration_description, configuration_group_id, sort_order, last_modified, date_added, use_function, set_function)
VALUES ('Maximum number of price break levels', 'PRICE_BREAK_NOF_LEVELS', '10', 'Configures the number of price break levels that can be entered on admin side. Levels that are left empty will not be shown to the customer', '73', '1', now(), now(), NULL, NULL);

You can also check that (instead of searching your table configuration for an entry with configuration_key PRICE_BREAK_NOF_LEVELS by hard coding the number in admin/categories.php. Change (around line 16):

// BOF qpbpp
 // include the price formatter for the price breaks contribution
 require(DIR_WS_CLASSES . 'PriceFormatter.php');
 $pf = new PriceFormatter;
// EOF qpbpp

To:

// BOF qpbpp
 // include the price formatter for the price breaks contribution
 require(DIR_WS_CLASSES . 'PriceFormatter.php');
 $pf = new PriceFormatter;
 // hard coded number of iterations for PRICE_BREAK_NOF_LEVELS
 define('PRICE_BREAK_NOF_LEVELS', '5'); // or whatever number you like
// EOF qpbpp

 

Note: you should change the name of the admin directory. This is the place where all would-be hackers are trying. Needs only two changes in name_of_your_admin_directory/includes/configure.php.

:rolleyes: When updated my database I forgot to include the above lines. Now its working properly. Thank you Jan Zonjee, you are a master.

 

I dont want to use the block quantity,(block quantity add multiple quantity, when you set greather value) just want to set a min. order, to set this I have comment out two lines in catalog/includes/PriceFormatter.php (aprox. line 115)

 

/* if (($qty % $qtyBlocks) != 0)

$qty += ($qtyBlocks - ($qty % $qtyBlocks)); */

 

But I see no effect, for example with min. order 300, when I add 500 to my cart, apears 600!

 

What to I have to change to set a min. order and not use quantity blocks?

 

Regards

Filipe

Link to comment
Share on other sites

I dont want to use the block quantity,(block quantity add multiple quantity, when you set greather value) just want to set a min. order, to set this I have comment out two lines in catalog/includes/PriceFormatter.php (aprox. line 115)

 

/* if (($qty % $qtyBlocks) != 0)

$qty += ($qtyBlocks - ($qty % $qtyBlocks)); */

 

But I see no effect, for example with min. order 300, when I add 500 to my cart, apears 600!

 

What to I have to change to set a min. order and not use quantity blocks?

The change is in the function adjustQty in catalog/includes/classes/PriceFormatter.php around line 175 now. Works fine for me. Sure you uploaded the changed version of that file?

Link to comment
Share on other sites

The change is in the function adjustQty in catalog/includes/classes/PriceFormatter.php around line 175 now. Works fine for me. Sure you uploaded the changed version of that file?

 

:rolleyes I have the latest version: QPBPP_v1_3_4 , I have made the folowing changes, its working!

 

Thank you for your attention.

Have a nice day.

Regards.

Filipe.

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Unfortunately, your content contains terms that we do not allow. Please edit your content to remove the highlighted words below.
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...