Why do you calling employee relation from Employee model?

|
I just want peace please 2021-05-23 12:12:37
https://www.youtube.com/watch?v=5SZFY3jwfP0&t=1s

Laravel 8 Tema Parçalama Actions Part 2 Phpstorm Layout Blade #laravel #laravel8YouTube
Sosyal Medya Hesaplarım
cyber-warrior : http://www.cyber-warrior.org/106851/
r10 : http://www.r10.net/profil/144977-turkmvc.html/
instagram : http://www.instagram.com/turkmvc/
twitter : http://twitter.com/TurkMvc
linkedin : http://www.linkedin.com/in/turkmvc/
reddit : http://www.reddit.com/user/laraveltr
tumblr : http://turkmvc.tumblr.com/
facebook : http://www.facebook.com/laravelturkey
pinterest : http://www.pinterest.com/turkmvc/
blogger : http://turkmvc.blogspot.com/

Laravel 8 Tema Parçalama İşlemleri Actions Part 2 Phpstorm Template Code Ekleme Layout Blade dosyaları tanımlama
laravel ile stok takip blog eticaret multi theme multi language rest api restfull api soap api gibi işlemleri ögrenecegiz ileride

#laravel
#laravel8
#laravelinstallation
#laravelwindows
#laravel7
#laravelroute
#route

Ajay_yadav_05 2021-05-23 13:07:20
Ajay:
Is there any way to add github auth data into the database in auth-nuxtjs??.

Actually I’m unable to get any blog posts on this topic

Ajay_yadav_05 2021-05-23 13:07:48
I’m using laravel for backend and nuxtjs for front-end…
Shri 2021-05-23 13:24:31
laravel_discuss-82257.jpg
I am facing this error
.
Shweta 2021-05-23 13:51:06
Hi
I need to fetch json data from database
Can anyone help please?
Shweta 2021-05-23 13:52:33
I’m trying to fetch this data in a pdf file
Lalit Rana 2021-05-23 14:21:14
Shweta 2021-05-23 13:51:06
Hi
I need to fetch json data from database
Can anyone help please?

You can do it in back-end

DonAdol 2021-05-23 14:23:28
Hi, im trying to validate that one user only book once per day.
Im not sure if the issue is related to the validator or the model.
DonAdol 2021-05-23 14:23:38
laravel_discuss-82271.jpg
model
DonAdol 2021-05-23 14:23:51
laravel_discuss-82272.jpg
bookingController validation
DonAdol 2021-05-23 14:24:27
laravel_discuss-82273.jpg
and the validator AKA BookingPersonLimit()
natghi2010 2021-05-23 15:36:45
DonAdol 2021-05-23 14:24:27
and the validator AKA BookingPersonLimit()

There is a method called when

natghi2010 2021-05-23 15:36:57
Please refer
sobirjonovs 2021-05-23 16:35:04
are you bot
sobirjonovs 2021-05-23 16:36:48
😁 You seem like a bot, every day the message is the same except the links )
sobirjonovs 2021-05-23 16:39:09
yeah, I used it. Thank you )
Zubidev 2021-05-23 16:39:38
Hi
Kindly share your resume I just want to compare my resume
DonAdol 2021-05-23 17:14:14
natghi2010 2021-05-23 15:36:57
Please refer

laravel_discuss-82283.jpg
This is the validation rule called on the bookingController:

DonAdol 2021-05-23 17:27:33
but it’s like user_id never went inside this validation. Any input i gave, validation is true.
Itech_programmer 2021-05-23 19:37:11
hey guys🤟
Itech_programmer 2021-05-23 19:38:17
who can help i have a little problem with my model
Itech_programmer 2021-05-23 19:39:19
User Model
Itech_programmer 2021-05-23 19:39:30
public function employee(){
return $this->belongsTo(‘AppModelsemployeesEmployees’, ‘id’, ‘user_id’);
}
Itech_programmer 2021-05-23 19:39:43
<td>{{ $employee->employee->date_of_birth}}</td> display
Itech_programmer 2021-05-23 19:39:59
$employees = User::where(‘role_id’, ‘<=’, 4)->where(‘school_id’, Auth::user()->school_id)->get(); controller
Itech_programmer 2021-05-23 19:40:16
error Trying to get property ‘date_of_birth’ of non-object (View:
j3w1sh 2021-05-23 19:41:46
Itech_programmer 2021-05-23 19:39:43
<td>{{ $employee->employee->date_of_birth}}</td> display

is $employee instance of User model? Or you’re calling employee relation of Employee model

Itech_programmer 2021-05-23 19:42:50
relation
Itech_programmer 2021-05-23 19:43:17
public function employee(){
return $this->belongsTo(‘AppModelsemployeesEmployees’, ‘id’, ‘user_id’);
} this
j3w1sh 2021-05-23 19:44:22
Itech_programmer 2021-05-23 19:39:43
<td>{{ $employee->employee->date_of_birth}}</td> display

is $employee variable an object of Employee class or User class?

Itech_programmer 2021-05-23 19:45:08
object of Employee
j3w1sh 2021-05-23 19:45:33
why do you calling employee relation from Employee model??
Itech_programmer 2021-05-23 19:46:19
j3w1sh 2021-05-23 19:45:33
why do you calling employee relation from Employee model??

just for date of birth and for photo

j3w1sh 2021-05-23 19:46:42
Itech_programmer 2021-05-23 19:39:43
<td>{{ $employee->employee->date_of_birth}}</td> display

$user->employee – because your User model has employee relation, not an Employee has employee 🙄

Itech_programmer 2021-05-23 19:47:27
laravel_discuss-82301.jpg

|