mirror of
https://github.com/Karaka-Management/phpOMS.git
synced 2026-01-11 17:58:41 +00:00
fix mapper formats
This commit is contained in:
parent
9511d3209c
commit
cd58375f02
|
|
@ -34,13 +34,13 @@ class CityMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'city_id' => ['name' => 'city_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'city_city' => ['name' => 'city_city', 'type' => 'string', 'internal' => 'name'],
|
||||
'city_id' => ['name' => 'city_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'city_city' => ['name' => 'city_city', 'type' => 'string', 'internal' => 'name'],
|
||||
'city_country' => ['name' => 'city_country', 'type' => 'string', 'internal' => 'countryCode'],
|
||||
'city_state' => ['name' => 'city_state', 'type' => 'string', 'internal' => 'state'],
|
||||
'city_postal' => ['name' => 'city_postal', 'type' => 'int', 'internal' => 'postal'],
|
||||
'city_lat' => ['name' => 'city_lat', 'type' => 'float', 'internal' => 'lat'],
|
||||
'city_long' => ['name' => 'city_long', 'type' => 'float', 'internal' => 'long'],
|
||||
'city_state' => ['name' => 'city_state', 'type' => 'string', 'internal' => 'state'],
|
||||
'city_postal' => ['name' => 'city_postal', 'type' => 'int', 'internal' => 'postal'],
|
||||
'city_lat' => ['name' => 'city_lat', 'type' => 'float', 'internal' => 'lat'],
|
||||
'city_long' => ['name' => 'city_long', 'type' => 'float', 'internal' => 'long'],
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -34,11 +34,11 @@ class CountryMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'country_id' => ['name' => 'country_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'country_name' => ['name' => 'country_name', 'type' => 'string', 'internal' => 'name'],
|
||||
'country_code2' => ['name' => 'country_code2', 'type' => 'string', 'internal' => 'code2'],
|
||||
'country_code3' => ['name' => 'country_code3', 'type' => 'string', 'internal' => 'code3'],
|
||||
'country_numeric' => ['name' => 'country_numeric', 'type' => 'int', 'internal' => 'numeric'],
|
||||
'country_id' => ['name' => 'country_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'country_name' => ['name' => 'country_name', 'type' => 'string', 'internal' => 'name'],
|
||||
'country_code2' => ['name' => 'country_code2', 'type' => 'string', 'internal' => 'code2'],
|
||||
'country_code3' => ['name' => 'country_code3', 'type' => 'string', 'internal' => 'code3'],
|
||||
'country_numeric' => ['name' => 'country_numeric', 'type' => 'int', 'internal' => 'numeric'],
|
||||
'country_subdevision' => ['name' => 'country_subdevision', 'type' => 'string', 'internal' => 'subdevision'],
|
||||
];
|
||||
|
||||
|
|
|
|||
|
|
@ -34,11 +34,11 @@ class CurrencyMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'currency_id' => ['name' => 'currency_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'currency_name' => ['name' => 'currency_name', 'type' => 'string', 'internal' => 'name'],
|
||||
'currency_code' => ['name' => 'currency_code', 'type' => 'string', 'internal' => 'code'],
|
||||
'currency_number' => ['name' => 'currency_number', 'type' => 'int', 'internal' => 'number'],
|
||||
'currency_decimal' => ['name' => 'currency_decimal', 'type' => 'int', 'internal' => 'decimals'],
|
||||
'currency_id' => ['name' => 'currency_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'currency_name' => ['name' => 'currency_name', 'type' => 'string', 'internal' => 'name'],
|
||||
'currency_code' => ['name' => 'currency_code', 'type' => 'string', 'internal' => 'code'],
|
||||
'currency_number' => ['name' => 'currency_number', 'type' => 'int', 'internal' => 'number'],
|
||||
'currency_decimal' => ['name' => 'currency_decimal', 'type' => 'int', 'internal' => 'decimals'],
|
||||
'currency_countries' => ['name' => 'currency_countries', 'type' => 'string', 'internal' => 'countries'],
|
||||
];
|
||||
|
||||
|
|
|
|||
|
|
@ -34,11 +34,11 @@ class IbanMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'iban_id' => ['name' => 'iban_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'iban_id' => ['name' => 'iban_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'iban_country' => ['name' => 'iban_country', 'type' => 'string', 'internal' => 'country'],
|
||||
'iban_chars' => ['name' => 'iban_chars', 'type' => 'int', 'internal' => 'chars'],
|
||||
'iban_bban' => ['name' => 'iban_bban', 'type' => 'string', 'internal' => 'bban'],
|
||||
'iban_fields' => ['name' => 'iban_fields', 'type' => 'string', 'internal' => 'fields'],
|
||||
'iban_chars' => ['name' => 'iban_chars', 'type' => 'int', 'internal' => 'chars'],
|
||||
'iban_bban' => ['name' => 'iban_bban', 'type' => 'string', 'internal' => 'bban'],
|
||||
'iban_fields' => ['name' => 'iban_fields', 'type' => 'string', 'internal' => 'fields'],
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -34,12 +34,12 @@ class LanguageMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'language_id' => ['name' => 'language_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'language_id' => ['name' => 'language_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'language_native' => ['name' => 'language_native', 'type' => 'string', 'internal' => 'name'],
|
||||
'language_639_1' => ['name' => 'language_639_1', 'type' => 'string', 'internal' => 'native'],
|
||||
'language_639_1' => ['name' => 'language_639_1', 'type' => 'string', 'internal' => 'native'],
|
||||
'language_639_2T' => ['name' => 'language_639_2T', 'type' => 'string', 'internal' => 'code2'],
|
||||
'language_639_2B' => ['name' => 'language_639_2B', 'type' => 'string', 'internal' => 'code3Native'],
|
||||
'language_639_3' => ['name' => 'language_639_3', 'type' => 'string', 'internal' => 'code3'],
|
||||
'language_639_3' => ['name' => 'language_639_3', 'type' => 'string', 'internal' => 'code3'],
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -25,18 +25,18 @@ class BaseModelMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'test_base_id' => ['name' => 'test_base_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_base_string' => ['name' => 'test_base_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_base_int' => ['name' => 'test_base_int', 'type' => 'int', 'internal' => 'int'],
|
||||
'test_base_bool' => ['name' => 'test_base_bool', 'type' => 'bool', 'internal' => 'bool'],
|
||||
'test_base_null' => ['name' => 'test_base_null', 'type' => 'int', 'internal' => 'null'],
|
||||
'test_base_float' => ['name' => 'test_base_float', 'type' => 'float', 'internal' => 'float'],
|
||||
'test_base_json' => ['name' => 'test_base_json', 'type' => 'Json', 'internal' => 'json'],
|
||||
'test_base_json_serializable' => ['name' => 'test_base_json_serializable', 'type' => 'Json', 'internal' => 'jsonSerializable'],
|
||||
'test_base_datetime' => ['name' => 'test_base_datetime', 'type' => 'DateTime', 'internal' => 'datetime'],
|
||||
'test_base_datetime_null' => ['name' => 'test_base_datetime_null', 'type' => 'DateTime', 'internal' => 'datetime_null'],
|
||||
'test_base_owns_one_self' => ['name' => 'test_base_owns_one_self', 'type' => 'int', 'internal' => 'ownsOneSelf'],
|
||||
'test_base_belongs_to_one' => ['name' => 'test_base_belongs_to_one', 'type' => 'int', 'internal' => 'belongsToOne'],
|
||||
'test_base_id' => ['name' => 'test_base_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_base_string' => ['name' => 'test_base_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_base_int' => ['name' => 'test_base_int', 'type' => 'int', 'internal' => 'int'],
|
||||
'test_base_bool' => ['name' => 'test_base_bool', 'type' => 'bool', 'internal' => 'bool'],
|
||||
'test_base_null' => ['name' => 'test_base_null', 'type' => 'int', 'internal' => 'null'],
|
||||
'test_base_float' => ['name' => 'test_base_float', 'type' => 'float', 'internal' => 'float'],
|
||||
'test_base_json' => ['name' => 'test_base_json', 'type' => 'Json', 'internal' => 'json'],
|
||||
'test_base_json_serializable' => ['name' => 'test_base_json_serializable', 'type' => 'Json', 'internal' => 'jsonSerializable'],
|
||||
'test_base_datetime' => ['name' => 'test_base_datetime', 'type' => 'DateTime', 'internal' => 'datetime'],
|
||||
'test_base_datetime_null' => ['name' => 'test_base_datetime_null', 'type' => 'DateTime', 'internal' => 'datetime_null'],
|
||||
'test_base_owns_one_self' => ['name' => 'test_base_owns_one_self', 'type' => 'int', 'internal' => 'ownsOneSelf'],
|
||||
'test_base_belongs_to_one' => ['name' => 'test_base_belongs_to_one', 'type' => 'int', 'internal' => 'belongsToOne'],
|
||||
];
|
||||
|
||||
/**
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@ class BelongsToModelMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'test_belongs_to_one_id' => ['name' => 'test_belongs_to_one_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_belongs_to_one_string' => ['name' => 'test_belongs_to_one_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_belongs_to_one_id' => ['name' => 'test_belongs_to_one_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_belongs_to_one_string' => ['name' => 'test_belongs_to_one_string', 'type' => 'string', 'internal' => 'string'],
|
||||
];
|
||||
|
||||
protected static string $table = 'test_belongs_to_one';
|
||||
|
|
|
|||
|
|
@ -25,9 +25,9 @@ class ManyToManyDirectModelMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'test_has_many_direct_id' => ['name' => 'test_has_many_direct_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_has_many_direct_string' => ['name' => 'test_has_many_direct_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_has_many_direct_to' => ['name' => 'test_has_many_direct_to', 'type' => 'int', 'internal' => 'to'],
|
||||
'test_has_many_direct_id' => ['name' => 'test_has_many_direct_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_has_many_direct_string' => ['name' => 'test_has_many_direct_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_has_many_direct_to' => ['name' => 'test_has_many_direct_to', 'type' => 'int', 'internal' => 'to'],
|
||||
];
|
||||
|
||||
protected static string $table = 'test_has_many_direct';
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@ class ManyToManyRelModelMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'test_has_many_rel_id' => ['name' => 'test_has_many_rel_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_has_many_rel_string' => ['name' => 'test_has_many_rel_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_has_many_rel_id' => ['name' => 'test_has_many_rel_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_has_many_rel_string' => ['name' => 'test_has_many_rel_string', 'type' => 'string', 'internal' => 'string'],
|
||||
];
|
||||
|
||||
protected static string $table = 'test_has_many_rel';
|
||||
|
|
|
|||
|
|
@ -25,8 +25,8 @@ class OwnsOneModelMapper extends DataMapperAbstract
|
|||
* @since 1.0.0
|
||||
*/
|
||||
protected static array $columns = [
|
||||
'test_owns_one_id' => ['name' => 'test_owns_one_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_owns_one_string' => ['name' => 'test_owns_one_string', 'type' => 'string', 'internal' => 'string'],
|
||||
'test_owns_one_id' => ['name' => 'test_owns_one_id', 'type' => 'int', 'internal' => 'id'],
|
||||
'test_owns_one_string' => ['name' => 'test_owns_one_string', 'type' => 'string', 'internal' => 'string'],
|
||||
];
|
||||
|
||||
protected static string $table = 'test_owns_one';
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user