mirror of
https://github.com/rickbarrette/stopwatch.git
synced 2026-04-02 09:51:57 -04:00
updating entries from overlay
This commit is contained in:
@@ -2,9 +2,9 @@
|
||||
<% time_entry = @time_entries.first %>
|
||||
<li>
|
||||
<% if User.current.is_running_timer? time_entry %>
|
||||
<%= context_menu_link l(:label_stopwatch_stop), stop_stopwatch_timer_path(time_entry, context: '1'), class: 'icon-time', remote: true, method: :put %>
|
||||
<%= context_menu_link l(:label_stopwatch_stop), stop_stopwatch_timer_path(time_entry, context: '1'), class: 'icon icon-time', remote: true, method: :put %>
|
||||
<% else %>
|
||||
<%= context_menu_link l(:label_stopwatch_start), start_stopwatch_timer_path(time_entry, context: '1'), class: 'icon-time', remote: true, method: :put %>
|
||||
<%= context_menu_link l(:label_stopwatch_start), start_stopwatch_timer_path(time_entry, context: '1'), class: 'icon icon-time', remote: true, method: :put %>
|
||||
<% end %>
|
||||
</li>
|
||||
<% end %>
|
||||
|
||||
@@ -1 +1,4 @@
|
||||
hideModal();
|
||||
window.stopwatch.highlightRunningTimer(
|
||||
<%= raw Stopwatch::Timer.new(User.current).to_json %>
|
||||
);
|
||||
|
||||
@@ -1,5 +1,9 @@
|
||||
hideModal();
|
||||
<% if @success %>
|
||||
hideModal();
|
||||
<% else %>
|
||||
$('#ajax-modal').html('<%= j render partial: 'stopwatch_timers/edit' %>');
|
||||
<% end %>
|
||||
<% if params[:continue] %>
|
||||
$('#ajax-modal').html('<%= j render partial: 'stopwatch_timers/new' %>');
|
||||
showModal('ajax-modal', '600px');
|
||||
showModal('ajax-modal', '700px');
|
||||
<% end %>
|
||||
|
||||
Reference in New Issue
Block a user