action_tabler 0.1 → 0.1.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -232,10 +232,11 @@ module ActionTabler
|
|
232
232
|
|
233
233
|
# Determine if we have a relation
|
234
234
|
if name.include?(".")
|
235
|
+
names = name.split(".")
|
235
236
|
# Discover relation model name
|
236
|
-
reflection = model.reflect_on_association(
|
237
|
+
reflection = model.reflect_on_association(names[0].to_sym)
|
237
238
|
# Recurse with realtion model and name
|
238
|
-
|
239
|
+
action_tabler_column_type_for(name.gsub("#{names[0]}.", ""), reflection.klass)
|
239
240
|
else
|
240
241
|
# Look up and return the Datatables column type
|
241
242
|
ActionTabler::JqueryDatatables.column_type_for(model.columns_hash[name].class)
|
metadata
CHANGED