membership register
This commit is contained in:
parent
3711fcc8d0
commit
37cb2b06c7
38 changed files with 1261 additions and 463 deletions
14
app/User.php
14
app/User.php
|
|
@ -129,11 +129,21 @@ class User extends Authenticatable
|
|||
|
||||
}
|
||||
|
||||
public function payment_order(){
|
||||
return $this->belongsTo('App\Models\Product', 'payment_order_id');
|
||||
}
|
||||
|
||||
public function files(){
|
||||
return $this->hasMany('App\Models\File', 'user_id', '');
|
||||
|
||||
}
|
||||
|
||||
public function shopping_orders(){
|
||||
return $this->hasMany('App\Models\ShoppingOrder', 'auth_user_id', '');
|
||||
|
||||
}
|
||||
|
||||
|
||||
public function shop()
|
||||
{
|
||||
return $this->hasOne('App\Models\UserShop', 'user_id', 'id');
|
||||
|
|
@ -141,7 +151,6 @@ class User extends Authenticatable
|
|||
|
||||
|
||||
|
||||
|
||||
public function user_update_email()
|
||||
{
|
||||
return $this->hasMany('App\Models\UserUpdateEmail', 'user_id', 'id');
|
||||
|
|
@ -228,7 +237,6 @@ class User extends Authenticatable
|
|||
}
|
||||
|
||||
public function daysHumansActiveAccount(){
|
||||
Carbon::setLocale(\App::getLocale());
|
||||
return Carbon::now()->diffForHumans(Carbon::parse($this->payment_account));
|
||||
}
|
||||
|
||||
|
|
@ -241,11 +249,9 @@ class User extends Authenticatable
|
|||
}
|
||||
|
||||
public function daysHumansActiveShop(){
|
||||
Carbon::setLocale(\App::getLocale());
|
||||
return Carbon::now()->diffForHumans(Carbon::parse($this->payment_shop));
|
||||
}
|
||||
|
||||
|
||||
/**
|
||||
* @return string
|
||||
*/
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue