Fixes on models
This commit is contained in:
parent
9174969b84
commit
f75ac6d78d
18 changed files with 18 additions and 17 deletions
|
|
@ -24,7 +24,7 @@ class BooleanField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=1;
|
$this->size=1;
|
||||||
$this->form='CoreForms::SelectForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::SelectForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -31,7 +31,7 @@ class CharField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::TextForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ class ChoiceField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::SelectForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::SelectForm';
|
||||||
$this->type=$type;
|
$this->type=$type;
|
||||||
$this->arr_values=$arr_values;
|
$this->arr_values=$arr_values;
|
||||||
$this->default_value=$default_value;
|
$this->default_value=$default_value;
|
||||||
|
|
|
||||||
|
|
@ -23,7 +23,7 @@ class DateField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::DateForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::DateForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,7 @@ class DoubleField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::TextForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ class EmailField extends PhangoField {
|
||||||
public $size=200;
|
public $size=200;
|
||||||
public $value="";
|
public $value="";
|
||||||
public $label="";
|
public $label="";
|
||||||
public $form="CoreForms::TextForm";
|
public $form="PhangoApp\PhaModels\CoreForms::TextForm";
|
||||||
public $class="";
|
public $class="";
|
||||||
public $required=0;
|
public $required=0;
|
||||||
public $quot_open='\'';
|
public $quot_open='\'';
|
||||||
|
|
|
||||||
|
|
@ -12,7 +12,7 @@ class FileField extends PhangoField {
|
||||||
public $value="";
|
public $value="";
|
||||||
public $label="";
|
public $label="";
|
||||||
public $required=0;
|
public $required=0;
|
||||||
public $form="CoreForms::FileForm";
|
public $form="PhangoApp\PhaModels\CoreForms::FileForm";
|
||||||
public $name_file="";
|
public $name_file="";
|
||||||
public $path="";
|
public $path="";
|
||||||
public $url_path="";
|
public $url_path="";
|
||||||
|
|
|
||||||
|
|
@ -29,7 +29,7 @@ class ForeignKeyField extends IntegerField{
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::SelectForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::SelectForm';
|
||||||
$this->related_model=&$related_model;
|
$this->related_model=&$related_model;
|
||||||
$this->container_model=$this->related_model->name;
|
$this->container_model=$this->related_model->name;
|
||||||
//Fields obtained from related_model if you make a query...
|
//Fields obtained from related_model if you make a query...
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@ class ImageField extends PhangoField {
|
||||||
public $value="";
|
public $value="";
|
||||||
public $label="";
|
public $label="";
|
||||||
public $required=0;
|
public $required=0;
|
||||||
public $form="CoreForms::ImageForm";
|
public $form="PhangoApp\PhaModels\CoreForms::ImageForm";
|
||||||
public $name_file="";
|
public $name_file="";
|
||||||
public $path="";
|
public $path="";
|
||||||
public $url_path="";
|
public $url_path="";
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,7 @@ class IntegerField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::TextForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextForm';
|
||||||
$this->only_positive=$only_positive;
|
$this->only_positive=$only_positive;
|
||||||
$this->min_num=$min_num;
|
$this->min_num=$min_num;
|
||||||
$this->max_num=$max_num;
|
$this->max_num=$max_num;
|
||||||
|
|
|
||||||
|
|
@ -26,7 +26,7 @@ class KeyField extends PhangoField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::TextForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -17,7 +17,7 @@ class ParentField extends IntegerField{
|
||||||
|
|
||||||
$this->parent_model=&$parent_model;
|
$this->parent_model=&$parent_model;
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::SelectForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::SelectForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -18,7 +18,7 @@ class PasswordField extends CharField {
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->size=$size;
|
$this->size=$size;
|
||||||
$this->form='CoreForms::PasswordForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::PasswordForm';
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -87,7 +87,7 @@ class PhangoField {
|
||||||
* Form define the function for use in forms...
|
* Form define the function for use in forms...
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public $form="CoreForms::TextForm";
|
public $form="PhangoApp\PhaModels\CoreForms::TextForm";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Array for create initial parameters for form..
|
* Array for create initial parameters for form..
|
||||||
|
|
|
||||||
|
|
@ -33,7 +33,7 @@ class PrimaryField extends PhangoField {
|
||||||
* By default, the form used for this field is HiddenForm.
|
* By default, the form used for this field is HiddenForm.
|
||||||
*/
|
*/
|
||||||
|
|
||||||
public $form="CoreForms::HiddenForm";
|
public $form="PhangoApp\PhaModels\CoreForms::HiddenForm";
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Check function that convert the value on a PrimaryField value.
|
* Check function that convert the value on a PrimaryField value.
|
||||||
|
|
|
||||||
|
|
@ -22,7 +22,7 @@ class TextField extends PhangoField {
|
||||||
function __construct($multilang=0)
|
function __construct($multilang=0)
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->form='CoreForms::TextAreaForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextAreaForm';
|
||||||
$this->multilang=$multilang;
|
$this->multilang=$multilang;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
||||||
|
|
@ -25,7 +25,7 @@ class TextHTMLField extends PhangoField {
|
||||||
function __construct($multilang=0)
|
function __construct($multilang=0)
|
||||||
{
|
{
|
||||||
|
|
||||||
$this->form='CoreForms::TextAreaForm';
|
$this->form='PhangoApp\PhaModels\CoreForms::TextAreaForm';
|
||||||
$this->multilang=$multilang;
|
$this->multilang=$multilang;
|
||||||
$this->set_safe_html_tags();
|
$this->set_safe_html_tags();
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -13,6 +13,7 @@ namespace PhangoApp\PhaModels\ExtraModels;
|
||||||
|
|
||||||
use PhangoApp\Phai18n\I18n;
|
use PhangoApp\Phai18n\I18n;
|
||||||
use PhangoApp\PhaModels\Webmodel;
|
use PhangoApp\PhaModels\Webmodel;
|
||||||
|
use PhangoApp\PhaUtils\Utils;
|
||||||
|
|
||||||
I18n::load_lang('users');
|
I18n::load_lang('users');
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue