Page 1 of 1

Add input to delivery option

Posted: 14 Dec 2015, 15:30
by obayesshelton
Hey,

I am trying to add a input field to all delivery option so that the user can input a delivery contact number etc, I have added it as a text attribute to the delivery service however it won't show on the delivery page.

Could you explain how to do this please...

Re: Add input to delivery option

Posted: 14 Dec 2015, 15:57
by aimeos
obayesshelton wrote: I am trying to add a input field to all delivery option so that the user can input a delivery contact number etc, I have added it as a text attribute to the delivery service however it won't show on the delivery page.
Why don't you use the telephone field from the billing and delivery address?
https://aimeos.org/docs/Configuration/C ... g/optional
https://aimeos.org/docs/Configuration/C ... y/optional

Re: Add input to delivery option

Posted: 14 Dec 2015, 16:07
by obayesshelton
Sorry I meant time not number, basically I need an input which I can put an extra bit of info in and possibly in the future a delivery provider account number

Re: Add input to delivery option

Posted: 14 Dec 2015, 16:39
by obayesshelton
I can see how to do it for a product but not for a delivery, the code shows a switch on the service attribute type but nothing shows...

Re: Add input to delivery option

Posted: 14 Dec 2015, 17:40
by aimeos
In that case, write a service provider decorator which adds an input field to the delivery option.

Documentation and examples for this are a bit distributed but here's were to look:
- Decorator examples: https://github.com/aimeos/aimeos-core/t ... /Decorator
- Add a new input field (FE config): https://github.com/aimeos/aimeos-core/b ... tDebit.php
- How to define the configuration: https://aimeos.org/docs/Developers/Libr ... figuration
- Admin interface configuration: https://aimeos.org/docs/User_Manual/Adm ... decorators