59 lines
1.3 KiB
PHP
Executable File
59 lines
1.3 KiB
PHP
Executable File
<?php
|
|
|
|
namespace common\models;
|
|
|
|
use Yii;
|
|
|
|
/**
|
|
* This is the model class for table "gis_amphoe".
|
|
*
|
|
* @property int $id
|
|
* @property string|null $geom
|
|
* @property string|null $ap_code รหัสอำเภอ
|
|
* @property string|null $pv_code จังหวัด
|
|
* @property string|null $ap_name_t อำเภอ
|
|
* @property string|null $ap_name_e District
|
|
*/
|
|
class GisAmphoe extends \yii\db\ActiveRecord
|
|
{
|
|
|
|
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public static function tableName()
|
|
{
|
|
return 'gis_amphoe';
|
|
}
|
|
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public function rules()
|
|
{
|
|
return [
|
|
[['geom', 'ap_code', 'pv_code', 'ap_name_t', 'ap_name_e'], 'default', 'value' => null],
|
|
[['geom'], 'string'],
|
|
[['ap_code'], 'string', 'max' => 10],
|
|
[['pv_code'], 'string', 'max' => 2],
|
|
[['ap_name_t', 'ap_name_e'], 'string', 'max' => 300],
|
|
];
|
|
}
|
|
|
|
/**
|
|
* {@inheritdoc}
|
|
*/
|
|
public function attributeLabels()
|
|
{
|
|
return [
|
|
'id' => 'ID',
|
|
'geom' => 'Geom',
|
|
'ap_code' => 'รหัสอำเภอ',
|
|
'pv_code' => 'จังหวัด',
|
|
'ap_name_t' => 'อำเภอ',
|
|
'ap_name_e' => 'District',
|
|
];
|
|
}
|
|
|
|
}
|