123456789101112131415161718 |
- <?php
- namespace App\Models;
- use Illuminate\Database\Eloquent\Model;
- class UserZ extends Model
- {
- protected $connection = 'mysql_z';
- protected $table='user';
- protected $fillable = ['openid','unionid','phone','name','nickname','wechat','avatar','integral','level_name','up_phone','last_time',
- 'status','bonus','up_name','rank','rank_end','integral_send','total','money','war_names','province','city','area','township',
- 'challenge_num','accept_num'];
- public function user(){
- return $this->hasOne(User::class,'mobile','phone');
- }
- }
|