diff --git a/lib/widget/controls/delete.rb b/lib/widget/controls/delete.rb index b26f3fc3e5..a06951aad3 100644 --- a/lib/widget/controls/delete.rb +++ b/lib/widget/controls/delete.rb @@ -1,4 +1,6 @@ class Widget::Controls::Delete < Widget::Base + dont_cache! + def render return "" if @query.new_record? or !@options[:can_delete] button = link_to content_tag(:span, content_tag(:em, l(:button_delete), :class => "button-icon icon-delete")), "#", diff --git a/lib/widget/controls/save.rb b/lib/widget/controls/save.rb index 3f54451805..b41a75c1b0 100644 --- a/lib/widget/controls/save.rb +++ b/lib/widget/controls/save.rb @@ -1,4 +1,6 @@ class Widget::Controls::Save < Widget::Base + dont_cache! + def render return "" if @query.new_record? or !@options[:can_save] write link_to content_tag(:span, content_tag(:em, l(:button_save)), :class => "button-icon icon-save"), {}, diff --git a/lib/widget/controls/save_as.rb b/lib/widget/controls/save_as.rb index 25e3c46616..c6784bb1d8 100644 --- a/lib/widget/controls/save_as.rb +++ b/lib/widget/controls/save_as.rb @@ -1,4 +1,6 @@ class Widget::Controls::SaveAs < Widget::Base + dont_cache! + def render if @query.new_record? link_name = l(:button_save)