Code/PHP 22

phpstorm의 Laravel모델에서도 인텔리전스를 하고 싶을 때.

Laravel모델에서 자동입력을 할려고 하면 잘 안된다. query()->를 붙이고 하면 되긴 된다. 그러나, 다른 유튜브를 보면 되는 것이다. 그래서 찾아봤다. github.com/barryvdh/laravel-ide-helper barryvdh/laravel-ide-helper Laravel IDE Helper. Contribute to barryvdh/laravel-ide-helper development by creating an account on GitHub. github.com 위쪽 깃에 들어가서 설치하면 된다. 해당 프로젝트디렉토리에서 터미널을 열고 composer require --dev barryvdh/laravel-ide-helper 치면 설치한 뒤 php artisan ide-hel..

Code/PHP 2021.02.26

Laravel Tips ) 레코드 존재 확인 용으로 find함수와 if함수의 조합 비추천

Laravel Daily Tips, tutorials, and demo-projects based on Laravel framework and technology around it. Host: Povilas Korop www.youtube.com 레코드 존재를 확인하기 위한 용도로 if문과 find함수의 조합를 쓰지 말라.findOrFail() 혹은 optional을 쓰자. yt3.ggpht.com/d7WPOrvEaFbXc2Y06b1y3RZhfEPOtnLfsTQkqttAY8YpPlr0ebVbF_I_P19B-c46xtFAu4pkL-YZ3g=s640-c-fcrop64=1,00200000ffdfffff-nd

Code/PHP 2021.02.23

PHPStorm에서 처리되지 않는 \Exception가 보기 싫을 때

www.debugcn.com/ko/article/25193111.html PhpStorm : 전제 조건이 충족 될 때 처리되지 않은 예외로 수행 할 작업 - Javaer101 PhpStorm : 전제 조건이 충족 될 때 처리되지 않은 예외로 수행 할 작업 --> blacktemplar 에 게시 Dev 블랙 템플러 저는 PhpStorm 검사 도구를 정말 좋아합니다. 더 나은 코드를 작성하는 데 많은 도움이됩 www.debugcn.com 파일(F)->설정->언어 및 프레임워크 -> PHP -> Analysis -> + -> \Exception을 추가함

Code/PHP 2021.02.22

Laravel Tips) 날짜 / 시간 관련 메소드

github.com/LaravelDaily/laravel-tips LaravelDaily/laravel-tips Awesome tips for Laravel. Contribute to LaravelDaily/laravel-tips development by creating an account on GitHub. github.com 한글로 번역해봅시당. Eloquent where 날짜/시간 관련 메소드 Eloquent에선 함수 whereDay(), whereMonth(). whereYear(), whereDate(), whereTime()을 가지고 날짜 체크합시다. carbon.now.sh/ Carbon Carbon is the easiest way to create and share beautiful i..

Code/PHP 2021.02.21