× This forum has been locked. Please submit new Feature Requests on GitHub: github.com/Jensen-Technologies/component-creator-issues/issues

modify JFormFieldForeignKey

9 Jahre 3 Monate her #616 von Francesco Reitano
modify JFormFieldForeignKey wurde erstellt von Francesco Reitano
Hi, I modified the file foreignkey.php, adding the ability to sort the field.
First add to JFormFieldForeignKey  class and getInput function this:
$this->order_field = $this->getAttribute('order_field');
 and modified the query:
$query
                ->select(
                        array(
                            $this->key_field,
                            $this->value_field
                        )
                )
                ->from($this->table)
                ->order($this->order_field);

and in form xml filed generated add:
order_field="activity"

Maybe you can modify the component creator to add this feature :)

best regards
Francesco Reitano

Bitte Anmelden oder Registrieren um der Konversation beizutreten.

Ladezeit der Seite: 0.115 Sekunden
Powered by Kunena Forum

Wir verwenden eigene Cookies und Cookies von Drittanbietern, um Ihr Nutzererlebnis zu verbessern und Ihnen einen optimalen Service zu bieten. Wenn Sie die Website weiter nutzen, gehen wir davon aus, dass Sie mit unserer Cookie-Politik einverstanden sind.