Jump to content
Sign in to follow this  
Blesta Addons

All Registrar Modules, getAdminAddFields()

Recommended Posts

when we add domain from admin side, and when extension has a custom fields, the custom fields are not shown, they only shown if the validation return a error and the page reloaded again .

from the code it appear the tld is only determinate when the post is submited, is not determinate on the fly by keypress .

Share this post


Link to post
Share on other sites

Not a perfect solution, but a while ago we added the option to include a refresh_fields field which would allow you to submit and refresh the fields without receiving errors.  Could look something like this:

                $label = $module_fields->label('Refresh Fields', 'refresh_fields');
                $refresh_fields = $module_fields->fieldCheckbox(
                    'refresh_fields',
                    'true',
                    (isset($vars->refresh_fields) ? $vars->refresh_fields : 'false') == 'true',
                    ['id' => 'refresh_fields']
                );
                $label->attach($refresh_fields);
                $module_fields->setField($label);

 

Share this post


Link to post
Share on other sites

Another option is to use the field in the same way that VPS.net does, watching for a field to change and then submitting the form via JS with this field set to 'true'.

Share this post


Link to post
Share on other sites

i think you have misunderstand me, let make a simple example with logicboxes module, create a package for a tld that need a custom fileds like .le or .asia .

from admin side in client profile page, got to add service, then select the package for that TLD, then only the standard fields will be shown, the custom fields will not be listed .

Share this post


Link to post
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
Sign in to follow this  

×
×
  • Create New...