Company field not showing in frontend

Questions around the TYPO3 integration and plugins
Forum rules
Always add your TYPO3, Aimeos and PHP version as well as your environment (Linux/Mac/Win)
Spam and unrelated posts will be removed immediately!
promptnet
Posts: 61
Joined: 24 Jul 2019, 12:22

Company field not showing in frontend

Post by promptnet » 13 Jan 2021, 08:52

Hi,
I tried to add two additional fields to the address form in checkout.
Telephone is ok, but company is not displayed.
Here's my TypoScript code:

Code: Select all

plugin.tx_aimeos.settings.client.html.checkout.standard.address {
    billing.mandatory {
        0 = order.base.address.salutation
        1 = order.base.address.firstname
        2 = order.base.address.lastname
        3 = order.base.address.address1
        4 = order.base.address.postal
        5 = order.base.address.city
        6 = order.base.address.email
    }
    delivery.mandatory < .billing.mandatory
}
plugin.tx_aimeos.settings.client.html.checkout.standard.address {
    billing.optional {
        0 = order.base.address.company
        1 = order.base.address.telephone
    }
    delivery.optional < .billing.optional
}
How can I make the company field showing up?
And, how can I change the placeholder for phone? The format is for Germany, but not for Switzerland...

TYPO3: 10.4.11 (Composer)
Aimeos: 20.10.4
PHP: 7.4.13

User avatar
aimeos
Administrator
Posts: 7873
Joined: 01 Jan 1970, 00:00

Re: Company field not showing in frontend

Post by aimeos » 13 Jan 2021, 10:41

The company field is only shown if "Company" is selected in the salutation. This is a Javascript thing.
Professional support and custom implementation are available at Aimeos.com
If you like Aimeos, Image give us a star

promptnet
Posts: 61
Joined: 24 Jul 2019, 12:22

Re: Company field not showing in frontend

Post by promptnet » 13 Jan 2021, 12:41

Ok, thanks, that helps.
But what about the field USt-Id: How can I turn this off? We don't need that.
And, how can I change the placeholder text of the phone field?

promptnet
Posts: 61
Joined: 24 Jul 2019, 12:22

Re: Company field not showing in frontend

Post by promptnet » 14 Jan 2021, 07:54

Placeholder for phone: I managed it on my own by searching for the placeholder string in files. There I found the string "+1 123 456 7890" which can be converted via TypoScript easily.
Because the UST-Id is optional, we keep. It's not necessary to hide it.

rowild

Re: Company field not showing in frontend

Post by rowild » 15 Jan 2021, 14:36

To deactivate VAT assign it to the "hidden" option of your TypoScript configuration:

For example:

Code: Select all

plugin.tx_aimeos.settings {
    checkout {
      standard.address {
        billing {
          mandatory {
            0 = order.base.address.salutation
            [...]
          }
          hidden {
            0 = order.base.address.company
            1 = order.base.address.vatid
          }

Post Reply