-
Notifications
You must be signed in to change notification settings - Fork 1.9k
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
Model #2923
Comments
Change the value of
|
Thank you very much for your answer. There are created at and updated at and deleted at in the database table, and $usetimestamps is also set to true, but you still don't get the desired result. For now, you can only use this method instead: $this - > confmodel - > where ('deleted at! = ', 0) - > get() - > getresultarray(); and $this - > confmodel - > where ('deleted at', 0)->get()->getResultArray(); |
CI4是通过 deleted_at 是不是 NULL 来判断的, CI4 use |
你的数据库相应字 默认应该设置为NULL |
好的,谢谢,我设置为 int 是为了存时间戳,可能是我把哪里设置错误了,框架执行的时候存储成为2020了 好的,谢谢,我设置为 int 是为了存时间戳,可能是我把哪里设置错误了,框架执行的时候存储成为2020了 |
谢谢 按照你说的设置就可以了 |
Direction
We use github issues to track bugs, not for support.
If you have a support question, or a feature request, raise these as threads on our
forum.
Describe the bug
Why does the model findall() return null, onlydeleted() - > findall() return all data instead of soft deleted data
CodeIgniter 4 version
Which version 4.03.
Affected module(s)
Which package or class is the bug in, if known.
Expected behavior, and steps to reproduce if appropriate
{"method":"CLI","route":"conf/getConfDeleted","handler":"\App\Controllers\Conf::getConfDeleted"},{"method":"CLI","route":"conf/delConf","handler":"\App\Controllers\Conf::delConf"}
Context
The text was updated successfully, but these errors were encountered: