Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

some function to bypass validation #12

Open
vheins opened this issue Oct 11, 2023 · 2 comments
Open

some function to bypass validation #12

vheins opened this issue Oct 11, 2023 · 2 comments

Comments

@vheins
Copy link

vheins commented Oct 11, 2023

Is your feature request related to a problem? Please describe.
I need to define validation rule on every model but some time i need to by pass that

Describe the solution you'd like
Maybe you can add some chaining function to skip validation and use like this

//this is current usage with validation rule enabled
MyModel::create(['name'=>'jhon doe');

//code if validation ignored / skip
MyModel::skipValidation()->create(['name'=>'jhon doe');

Describe alternatives you've considered
A clear and concise description of any alternative solutions or features you've considered.

Additional context
i try to make pull request but my knowledge its limited caus its using boot() on model i dont know to parsing variable to boot() method

@theriddleofenigma
Copy link
Owner

Thanks for raising @vheins. It would be a good addition to the package if possible. I will have a look.

@vheins
Copy link
Author

vheins commented Oct 11, 2023

thank you @theriddleofenigma hope you can help this

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants