Creating an order template with products already added?

Hello 🙂
the situation looks like this:

Now
Users can add their packages to the shopping cart manually.

eg this user added three products to his shopping cart:
- BDF Lizenz
- CIP Lizenz
- SEO Take-Off Package

random9_2-1697730110432.png

 

Goal
Users can select from several full shopping carts (templates) and can add, customize and delete products from this shopping cart to save time.

eg  the user should be able to choose a certain template that adds these three products to his cart instantly, without having to manually add each one of those packages to the cart

 

How
Is it possible to create a drop down of orders that you can use as templates, and when you choose one, a order for you will be created and can be edited by you

Maybe a copy button would be nice, that copies all the data of two tables and just changes the ID.

Any idea on how this would be achievable in an optimal manner?

Solved Solved
0 4 274
1 ACCEPTED SOLUTION


@random9 wrote:

How many custom actions would I need to create to achieve this? A trigger and a add function?


This depends on your data structure.  When you create the Order Detail rows from the templates you would also need to assign the Order ID/# to each row.  Which means you need to create the Order row first.  There will need to be "transition" actions to switch datasources the action is operating on. So, there will likely need to be several actions.


@random9 wrote:

Hmm, I'm not sure if I would save it like you suggested or like this:


Yes, your approach might make sense from action processing perspective.  With what I suggested you would need to loop over the list to create the rows - i.e. more actions.  In your approach, no specific looping would be needed. 

 

 

View solution in original post

4 REPLIES 4


@random9 wrote:

Is it possible to create a drop down of orders that you can use as templates, and when you choose one, a order for you will be created and can be edited by you


Yes, its possible.  It requires a separate set of tables to store your pre-determined templates into.  When a template is chosen, the app triggers a set of actions that uses the template details to insert the necessary rows into your Order table(s).

How you achieve the creation of the Order based on a template depends what details are needed...and your preference.  For example, it seems to me that your template only requires the list of items and maybe a few other item selected details.  It might be prudent for the template to be saved as just a single row item with a column capturing your list of items with details combined together.  Maybe like this:

Name Template Items
Template 1 BDF Lizenz - S, CIP Lizenz - S, SEO Take-Off Package - M
Template 2  etc

Your Template Items are then split in order to grab the specific details to be used in creating the Order Detail row.

Of course, another option is one you have mentioned.  Basically have a complete copy of the Order Details rows in a template table.  When a template is chosen, copy the rows and update the Order ID info.  You would have to build the copy action.  

I hope this helps!


When a template is chosen, the app triggers a set of actions that uses the template details to insert the necessary rows into your Order table(s).


How many custom actions would I need to create to achieve this? A trigger and a add function?

NameTemplate Items
Template 1BDF Lizenz - S, CIP Lizenz - S, SEO Take-Off Package - M
Template 2 etc

Hmm, I'm not sure if I would save it like you suggested or like this:

NameTemplate Items
Template 1BDF Lizenz - S
Template 1 CIP Lizenz - S 
Template 1SEO Take-Off Package - M

I'd need to think about it a little bit, but thanks for your reply!


@random9 wrote:

How many custom actions would I need to create to achieve this? A trigger and a add function?


This depends on your data structure.  When you create the Order Detail rows from the templates you would also need to assign the Order ID/# to each row.  Which means you need to create the Order row first.  There will need to be "transition" actions to switch datasources the action is operating on. So, there will likely need to be several actions.


@random9 wrote:

Hmm, I'm not sure if I would save it like you suggested or like this:


Yes, your approach might make sense from action processing perspective.  With what I suggested you would need to loop over the list to create the rows - i.e. more actions.  In your approach, no specific looping would be needed. 

 

 

I'm having trouble implementing the actions.

NameTemplate Items
Template 1BDF Lizenz - S
Template 1 CIP Lizenz - S 
Template 1SEO Take-Off Package - M

How can I add multiple rows simultaneously with only one action click? I know I can copy  the first row of my template and add the action in a new row, but how do I create multiple rows?

Top Labels in this Space