| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
| |
With #31615 `type_for_attribute` accepts either
a symbol as well as a string. `has_attribute?` and `attribute_alias`
also accept either. Since these methods call `to_s` on the argument,
we no longer need to do that at the call site.
|
|
|
|
|
| |
This suppresses `Timeout::Error` exceptions.
Ref: https://travis-ci.org/rails/rails/jobs/334622442#L1089-L1110
|
|
|
|
|
|
|
|
|
| |
This example was added in abdf546ad6d02ecb95766e73cd3c645a48c954de
but was inconsistent with `composed_of :balance` definition in the
'Customer'.
[Ryuta Kamizono & bogdanvlviv]
[ci skip]
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This reverts commit 755f7b58953c25790eea0574ff8928033ded2d88, reversing
changes made to 35db4603095e8ccc0a92d925a42d4b3d9462580f.
Originally `mapping: %w(balance amount)` is correct mapping example.
Closes #31346.
[Ryuta Kamizono & bogdanvlviv]
[ci skip]
|
| |
|
|\
| |
| | |
Allow type_for_attribute(:symbol)
|
| |
| |
| |
| | |
Closes #31611.
|
|\ \
| | |
| | | |
Added tests for ActiveStorage::Blob#image? and ActiveStorage::Blob#video?
|
| | | |
|
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | |
| | | |
Follow up of #31724.
If `composed_of` objects have multiple mappings, array predicate handler
can not correctly handle the expanded condition.
We need to handle it like polymorphic association objects.
|
|\ \ \
| | | |
| | | | |
Remove joke in security guide [ci skip]
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
I think this is a joke, although not a great one.
It's mildly unprofessional, so I think we
should get rid of it.
|
|\ \ \ \
| | | | |
| | | | |
| | | | | |
Fix not expanded problem when passing an Array object as argument to the where method using composed_of column.
|
| | | | | |
|
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | |
| | | | | |
where method using composed_of column.
Fixes #31723
```
david_balance = customers(:david).balance
Customer.where(balance: [david_balance]).to_sql
# Before: WHERE `customers`.`balance` = NULL
# After : WHERE `customers`.`balance` = 50
```
|
|\ \ \ \ \
| | | | | |
| | | | | |
| | | | | |
| | | | | | |
yahonda/supports_foreign_tables_in_abstract_adapter
Define `supports_foreign_tables?` in AbstractAdapter
|
| | | | | | |
|
|\ \ \ \ \ \
| |/ / / / /
|/| | | | | |
Remove out-of-date references to jQuery [ci skip]
|
| | |/ / /
| |/| | |
| | | | |
| | | | | |
Fixes #31703
|
| |_|/ /
|/| | |
| | | |
| | | | |
This was changed with 5d7b70f and 428939b.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Because we use `credentials` in an example of configuration files, but
`credentials` can not be used unless it is 1.8.0 or later.
Ref: 9d65ac3
|
| | | | |
|
|\ \ \ \
| | | | |
| | | | | |
Relax minitest versions
|
| |/ / /
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
We locked Minitest to 5.11.1 in #31799
because 5.11.2 included a breaking change.
The change was fixed in 5.11.3, so we no
longer need to lock in the version.
|
|/ / / |
|
|\ \ \
| | | |
| | | | |
Fix infinite loop when unloading autoloaded modules
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
error occured during the load.
|
|\ \ \ \
| | | | |
| | | | | |
Fix example migrations in Associations guide
|
| | | | | |
|
|\ \ \ \ \
| |/ / / /
|/| | | | |
Use respond_to test helpers
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
| | | | | |
|
|/ / / / |
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
Since #29504, mysql2 adapter lost ability to insert zero value on
primary key due to enforce `NO_AUTO_VALUE_ON_ZERO` disabled.
That is for using `DEFAULT` on auto increment column, but we can use
`NULL` instead in that case.
|
|\ \ \ \
| |_|/ /
|/| | | |
Lock Minitest 5.11.1
|
|/ / /
| | |
| | |
| | |
| | | |
To workaround `undefined method `error?' for` reported
at https://travis-ci.org/rails/rails/jobs/333456146
|
|\ \ \
| | | |
| | | | |
Update note on MySQL index order support [ci skip]
|
|/ / /
| | |
| | |
| | |
| | | |
MySQL supports descending indexes from 8.0.1 onwards:
https://dev.mysql.com/doc/relnotes/mysql/8.0/en/news-8-0-1.html
|
|\ \ \
| | | |
| | | | |
Clarify autoload_paths and eager_load in guides per current usage.
|
| | | | |
|
| | | |
| | | |
| | | |
| | | | |
Since #31422, `insert_fixtures` is deprecated.
|
| | | |
| | | |
| | | |
| | | | |
It was unused since 9e4c41c903e8e58721f2c41776a8c60ddba7a0a9.
|
|\ \ \ \
| | | | |
| | | | | |
Fix typo in API document FormHelper#fields
|
|/ / / /
| | | |
| | | |
| | | |
| | | | |
- Fix typo
- Adjust output example to other example's format
|
| | | |
| | | |
| | | |
| | | | |
It is useless since 90c8be76a7d00475be5ff4db2eeedde5cc936c2d.
|
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | |
| | | | |
driving table
This is a regression caused by 6beb4de.
In PostgreSQL, ORDER BY expressions must appear in SELECT list when
using DISTINCT.
When using `count(:all)` with eager loading, Active Record enforces
DISTINCT to count the driving table records only. 6beb4de was caused the
regression because `count(:all)` with DISTINCT path no longer removes
ORDER BY.
We need to ignore ORDER BY when DISTINCT is enforced, otherwise not
always generated valid SQL for PostgreSQL.
Fixes #31783.
|