Extract to help method to fill in the data for the suggestions

This commit is contained in:
taitus
2021-03-31 15:20:06 +02:00
parent 5f642f9ecb
commit 56d3840c40
4 changed files with 12 additions and 9 deletions

View File

@@ -0,0 +1,9 @@
module SuggestionsHelper
def suggest_data(record)
{
js_suggest_result: "js_suggest_result",
js_suggest: ".js-suggest",
js_url: polymorphic_path(record.class, action: :suggest)
}
end
end