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

modify JFormFieldForeignKey

9 года 9 мес. назад #616 от Francesco Reitano
Francesco Reitano создал тему: modify JFormFieldForeignKey
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

Пожалуйста Войти или Регистрация, чтобы присоединиться к беседе.

Время создания страницы: 0.046 секунд
Работает на Kunena форум

We use cookies so that you can place orders and we can provide a better service. You can control the use of cookies at the individual browser level. If you reject cookies, you may still use our website, but your ability to use some features or areas of our website may be limited.