Exemplo n.º 1
0
 /**
  * 获取地址对象
  */
 public function getAddress()
 {
     if ($this->getIsNewRecord()) {
         return [];
     }
     $data = Address::findOne($this->getAttribute('addid'));
     return $data;
 }
Exemplo n.º 2
0
 public function show()
 {
     return Address::find()->asArray()->all();
 }