mirror of
https://github.com/rickbarrette/stopwatch.git
synced 2026-04-02 09:51:57 -04:00
initial commit
This commit is contained in:
11
app/views/stopwatch_timers/_edit.html.erb
Normal file
11
app/views/stopwatch_timers/_edit.html.erb
Normal file
@@ -0,0 +1,11 @@
|
||||
<h3 class="title"><%= l(:label_spent_time) %></h3>
|
||||
|
||||
<%= labelled_form_for @time_entry, url: stopwatch_path, remote: true do |f| %>
|
||||
<% @time_entry.hours ||= 0 %>
|
||||
<%= render partial: 'timelog/form', locals: { f: f } %>
|
||||
|
||||
<p class="buttons">
|
||||
<%= submit_tag l(:button_create) %>
|
||||
<%= submit_tag l(:button_cancel), name: nil, onclick: "hideModal(this);", type: 'button' %>
|
||||
</p>
|
||||
<% end %>
|
||||
12
app/views/stopwatch_timers/_new.html.erb
Normal file
12
app/views/stopwatch_timers/_new.html.erb
Normal file
@@ -0,0 +1,12 @@
|
||||
<h3 class="title"><%= l(:button_log_time) %></h3>
|
||||
|
||||
<%= labelled_form_for @time_entry, url: stopwatch_timer_path, method: :post, remote: true do |f| %>
|
||||
<% @time_entry.hours ||= 0 %>
|
||||
<%= render partial: 'timelog/form', locals: { f: f } %>
|
||||
|
||||
<p class="buttons">
|
||||
<%= submit_tag l(:button_create) %>
|
||||
<%= submit_tag l(:button_cancel), name: nil, onclick: "hideModal(this);", type: 'button' %>
|
||||
</p>
|
||||
<% end %>
|
||||
|
||||
2
app/views/stopwatch_timers/new.js.erb
Normal file
2
app/views/stopwatch_timers/new.js.erb
Normal file
@@ -0,0 +1,2 @@
|
||||
$('#ajax-modal').html('<%= j render partial: 'stopwatch_timers/new' %>');
|
||||
showModal('ajax-modal', '600px');
|
||||
Reference in New Issue
Block a user