-
-
Notifications
You must be signed in to change notification settings - Fork 226
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Hide product from cart until available date.. #2720
Hide product from cart until available date.. #2720
Commits on Aug 9, 2019
-
Hide product from cart until available date..
This additional/removable code offers an opportunity for a product to be fully defined in the store, but not shown as available, upcoming, new, etc (because it is disabled) until the product available date at which point it appears in the store as an enabled product ready for the customer to see and/or purchase.
Configuration menu - View commit details
-
Copy full SHA for f649880 - Browse repository at this point
Copy the full SHA f649880View commit details
Commits on Jan 17, 2020
-
Configuration menu - View commit details
-
Copy full SHA for 5fefa7e - Browse repository at this point
Copy the full SHA 5fefa7eView commit details -
Delete separate functions file
These functions were moved into products_functions by discussion/request in zencart#2720.
Configuration menu - View commit details
-
Copy full SHA for 413f69c - Browse repository at this point
Copy the full SHA 413f69cView commit details -
Incorporate functions_products and enabling disabled product
Ensures loading of `functions_products.php` and enables disabled product that were marked as having a future products_available_date where the current date is equal or beyond the date it was to become available.
Configuration menu - View commit details
-
Copy full SHA for f2ab47e - Browse repository at this point
Copy the full SHA f2ab47eView commit details -
Replaced load of code by alternate incorporation
As requested in zencart#2720, the call to the functions to enable disabled product was moved into: `includes/init_includes/init_special_funcs.php` which eliminated the need for loading `includes/init_includes/init_special_funcs_disabled_upcoming.php` and therefore eliminated the need for this separate config file.
Configuration menu - View commit details
-
Copy full SHA for 7833f89 - Browse repository at this point
Copy the full SHA 7833f89View commit details -
Complete the removal of the additional files
This functionality was moved into `includes/init_includes/init_special_funcs.php` as discussed in zencart#2720.
Configuration menu - View commit details
-
Copy full SHA for 763ec19 - Browse repository at this point
Copy the full SHA 763ec19View commit details -
Add control if admin switch present and enabled
Allow the enablement of product that have a historical product_available_date if the constant is defined and set to support enablement of this feature. Consideration was given for testing/checking against `!= '0'`; however, seems that such an option would only be necessary to support some sort of third, fourth, etc... condition which is not clear what it may be and therefore likely would require modification of this area of the code if generated. By the check specifically against `== '1'`, whatever defines it (file or database) if it is equal to 1 then this area of code will execute. Alternatively, for those that do mass installations, if they choose not to include the option in the database or choose to remove it, then code will continue to operate without execution of this feature.
Configuration menu - View commit details
-
Copy full SHA for 059856a - Browse repository at this point
Copy the full SHA 059856aView commit details -
Configuration menu - View commit details
-
Copy full SHA for 1c83de7 - Browse repository at this point
Copy the full SHA 1c83de7View commit details -
Made spacing of 4 spaces and removed parentheses around require/require_once calls. Also corrected an issue with the earlier incorporation of `functions_products` where the closing parenthesis was omitted.
Configuration menu - View commit details
-
Copy full SHA for bb53a3e - Browse repository at this point
Copy the full SHA bb53a3eView commit details -
Add enabled disabled date available configuration to update path
Adds the admin control for enabling the feature to enable product that are in the disabled status and has a `products_available_date` in the database that has come to be or has passed. Default set to `0` to allow store owners to enable this feature potentially after a review of the database/product. This is to prevent the sudden appearance of disabled product that happened to have a date entered in the `products_available_date` field.
Configuration menu - View commit details
-
Copy full SHA for 5a40a93 - Browse repository at this point
Copy the full SHA 5a40a93View commit details -
Add Admin enable disabled upcoming product switch to install
Associated with zencart#2720.
Configuration menu - View commit details
-
Copy full SHA for 0bb4855 - Browse repository at this point
Copy the full SHA 0bb4855View commit details -
Remove unnecessary parentheses in query
Although original code had been adapted from other similar (but more complex) queries, the additional parentheses are unnecessary and I believe this was pointed out in earlier code review.
Configuration menu - View commit details
-
Copy full SHA for 3035242 - Browse repository at this point
Copy the full SHA 3035242View commit details -
Use foreach for record traversal
Use `foreach` instead of the older combination of `while (!$variable->EOF)` with `$variable->MoveNext()` This also eliminated the need to check for the number of records returned.
Configuration menu - View commit details
-
Copy full SHA for 5352a55 - Browse repository at this point
Copy the full SHA 5352a55View commit details
Commits on Jan 21, 2020
-
Update configuration_title and configuration_description
As requested in the PR discussion, updated the `configuration_title` and `configuration_description` to try to provide an improved explanation of what this feature does. Note, that as a result of working through this explanation, identified that enablement occurs without consideration of stock quantity or any other potential reason one may wish the product to remain disabled. This is a further reason why the default is for this feature to be off upon install/upgrade so that consideration may be given to data modification and/or the desire to turn it on.
Configuration menu - View commit details
-
Copy full SHA for 5c248b1 - Browse repository at this point
Copy the full SHA 5c248b1View commit details -
Update configuration_title and configuration_description
As requested in the PR discussion, updated the `configuration_title` and `configuration_description` to try to provide an improved explanation of what this feature does. Note, that as a result of working through this explanation, identified that enablement occurs without consideration of stock quantity or any other potential reason one may wish the product to remain disabled. This is a further reason why the default is for this feature to be off upon install/upgrade so that consideration may be given to data modification and/or the desire to turn it on.
Configuration menu - View commit details
-
Copy full SHA for 79d9fe2 - Browse repository at this point
Copy the full SHA 79d9fe2View commit details
Commits on Apr 27, 2020
-
Default/Restore date to NULL and ignore if is NULL
In preparation for future updates to the date/time processing to use NULL instead of the historical default of `'0001-01-01 00:00:00'` choosing to use NULL instead which is supported by the field. This reduces one change to the overall system. Check for whether to process the record still compares against `'0001-01-01'` in the event other "systems" clear the field to be appear as empty.
Configuration menu - View commit details
-
Copy full SHA for 88770fd - Browse repository at this point
Copy the full SHA 88770fdView commit details -
Configuration menu - View commit details
-
Copy full SHA for fbc7954 - Browse repository at this point
Copy the full SHA fbc7954View commit details -
Update the installation and upgrade scripts for Automatic and Manual
For new installation (not using a previous database), set this to automatic to enable product that are disabled and have a future date. For upgrades left this as Manual so that a database update will not automatically enable product that were disabled but had a future date. Previous operation without this additional feature would have left the product disabled from viewing on the store until the product were enabled.
Configuration menu - View commit details
-
Copy full SHA for 3fecb58 - Browse repository at this point
Copy the full SHA 3fecb58View commit details
Commits on May 7, 2020
-
Configuration menu - View commit details
-
Copy full SHA for 0fd163c - Browse repository at this point
Copy the full SHA 0fd163cView commit details