issue with UUIDs in Administrate gem
I went through the process of converting Jumpstart to utilize UUID's. I updated all the dashboard id's to Field::String in ATTRIBUTE_TYPES, but for some reason, Plans and Pay Subscriptions seem to completely ignore the directive and give the following error:
invalid value for Integer(): "db7b60d3-4a39-4d0a-a80e-7e9adf8ff7db"
Even more confounding, if I delete all the attributes altogether, which should remove any fields at all, the error remains. I can't seem to figure out whether there is something external to the dashboard being called or what.
Does anyone have some ideas?
Chris Oliver
any insight?
Thanks!
Does anyone have some ideas?
Thanks!
The error actually seems to occur when generating a polymorphic path:
14:24:43 web.1 | Pay::Subscription Load (0.6ms) SELECT "pay_subscriptions".* FROM "pay_subscriptions" ORDER BY pay_subscriptions.created_at desc LIMIT $1 OFFSET $2 [["LIMIT", 20], ["OFFSET", 0]]
14:24:43 web.1 | ↳ app/views/admin/pay/subscriptions/_collection.html.erb:56
14:24:43 web.1 | Pay::Customer Load (0.8ms) SELECT "pay_customers".* FROM "pay_customers" WHERE "pay_customers"."id" = $1 [["id", "02fe9c31-b1ae-4fb6-a0d3-6d4d68f50dde"]]
14:24:43 web.1 | ↳ app/views/admin/pay/subscriptions/_collection.html.erb:56
14:24:43 web.1 | Rendered admin/pay/subscriptions/_collection.html.erb (Duration: 15.7ms | Allocations: 6379)
14:24:43 web.1 | Rendered admin/pay/subscriptions/index.html.erb within layouts/admin/application (Duration: 22.3ms | Allocations: 10869)
14:24:43 web.1 | Rendered layout layouts/admin/application.html.erb (Duration: 22.7ms | Allocations: 10957)
14:24:43 web.1 | Completed 500 Internal Server Error in 25ms (ActiveRecord: 1.5ms | Allocations: 11740)
14:24:43 web.1 |
14:24:43 web.1 |
14:24:43 web.1 |
14:24:43 web.1 | ActionView::Template::Error (invalid value for Integer(): "b7379253-236e-46a4-aa5c-e41f25252ea7"):
14:24:43 web.1 | 57: <tr class="js-table-row"
14:24:43 web.1 | 58: tabindex="0"
14:24:43 web.1 | 59: <% if valid_action? :show, collection_presenter.resource_name %>
14:24:43 web.1 | 60: <%= %(role=link data-url=#{polymorphic_path([namespace, resource])}) %>
14:24:43 web.1 | 61: <% end %>
14:24:43 web.1 | 62: >
14:24:43 web.1 | 63: <% collection_presenter.attributes_for(resource).each do |attribute| %>
14:24:43 web.1 |
14:24:43 web.1 | app/views/admin/pay/subscriptions/_collection.html.erb:60
14:24:43 web.1 | app/views/admin/pay/subscriptions/_collection.html.erb:56
14:24:43 web.1 | app/views/admin/pay/subscriptions/index.html.erb:56
14:24:43 web.1 | app/controllers/administrate/application_controller.rb:16:in `index'
14:24:43 web.1 | app/controllers/admin/application_controller.rb:39:in `block in without_tenant'
14:24:43 web.1 | app/controllers/admin/application_controller.rb:38:in `without_tenant'
I'm seeing the same issue with some other administrate dashbords including: plans index and account show.
Notifications
You’re not receiving notifications from this thread.