thelia / group-order-module
Installs: 6
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 8
Forks: 1
Open Issues: 0
Type:thelia-module
Requires
- thelia/installer: ~1.1
This package is auto-updated.
Last update: 2024-10-30 01:31:57 UTC
README
This Module allow you to create group orders
Installation
Manually
- Copy the module into
<thelia_root>/local/modules/
directory and be sure that the name of the module is GroupOrder. - Activate it in your thelia administration panel
Composer
Add it in your main thelia composer.json file
composer require thelia/group-order-module:~0.0.1
Usage
During register or in back office you have the possibility to create Main Customers. A main customer can create sub-customers and can fill the cart of the sub-customer.
A sub-customer can connect via the login and password set by the main customer, they have restricted right, they can add items to their cart and once they decide to validate their cart, the cart is sent to the cart of the main-customer.
Hook
Front
register.form-bottom
is used to add the main customer checkbox on the register pageaccount.additional
andaccount.javascript-initialization
is used to add the new panel allowing a main customer to create sub customersmain.footer-bottom
,main.stylesheet
andmain.javascript-initialization
is used to display the sticky window for main customerslogin.main-bottom
is used to add the login form for sub customers connections
Back
customer.edit-js
is used to add the main customer checkbox on the customer edit page
Loop
[group_order_sub_customer]
Input arguments
Output arguments
Exemple
<ul>
{loop type="group_order_sub_customer" name="my_group_order_sub_customer_loop" main_customer=$mainCustomerId}
<li>{$FIRSTNAME} {$LASTNAME}</li>
{/loop}
</ul>
[group_order_main_customer]
Input arguments
Output arguments
Exemple
{loop type="group_order_main_customer" name="main_customer_loop" customer_id=$customer_id active=true}
{assign "isMainCustomer" 1}
{/loop}
[group_order_sub_order]
Input arguments
Output arguments
Example
Add a complete exemple of your loop