16263: Assigns nil to select attributes when receiving empty values.
authorLucas Di Pentima <lucas@di-pentima.com.ar>
Thu, 19 Mar 2020 21:15:52 +0000 (18:15 -0300)
committerPeter Amstutz <peter.amstutz@curii.com>
Mon, 13 Apr 2020 15:25:53 +0000 (11:25 -0400)
commit4fbb5b4751488d9751710f03ebf99406d4c55410
treef1fe6116d175d9f1a633496f9572a0c75d7e6df1
parentda84332fc7b4a549e08e0be87d4b52ffe2eeddd9
16263: Assigns nil to select attributes when receiving empty values.

Controller may translate NULL values to "" on certain object string fields.
The same with integers, NULLs are converted to 0.
When controller retrieves objects from railsAPI and uses the data to create
or update objects, some of those fields should get converted back to NULL.

Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <lucas@di-pentima.com.ar>
services/api/app/controllers/application_controller.rb
services/api/app/controllers/arvados/v1/users_controller.rb
services/api/test/functional/arvados/v1/users_controller_test.rb