Page 1 of 1

Order form with all products

Posted: 10 Nov 2016, 10:58
by Nils
Hi :)

I'm looking for a way to create something like what is shown in the image I attached: All products in a tabular view, columns for text/information (text of selected types associated with product?) that belong to a product and the possibilty to enter the quantity per product.

I thought of a list view, where the basket is enabled. But then, how could I generate the table headers with the labels of the text types that I want to output? That would be a configuration that belongs to a list plugin. Can that be done? And could I specify the text types I want to output per plugin?

The next idea was to build a form manually with all the necessary fields that posts to the basket. But in the case of some products having no quantities you would get some error messages in the basket (no valid quantity). Yes, I could probably do some Javascript validation and modification of the fields that are posted, but that wouldn't be the proper place of doing validation. Ok, building a form manually isn't so proper either.

What would be a clean approach to solve the problem? Or what is the best next or similar thing I could do in a clean way?

Re: Order form with all products

Posted: 11 Nov 2016, 00:24
by aimeos
You can change the catalog list item template to use tables instead of list elements:
https://github.com/aimeos/ai-client-htm ... efault.php

If you want to display only one order button, you should change the catalog stock template to disable the product lines that have no stock:
https://github.com/aimeos/ai-client-htm ... t.php#L148

Re: Order form with all products

Posted: 14 Nov 2016, 10:19
by Nils
Ok, thank you. I'll work with that.