<% if @started_time_entry %> contextMenuHide(); window.stopwatch.timerStarted( <%= raw Stopwatch::Timer.new(User.current).to_json %> ); <% else %> $('#ajax-modal').html('<%= j render partial: 'new' %>'); showModal('ajax-modal', '700px'); <% end %>