remove unnessary timezone convertion
This commit is contained in:
@@ -77,7 +77,7 @@
|
||||
//Reset the form to pervious values
|
||||
<% if params[:shift_name].to_i > 0%>
|
||||
shift_id = '<%= params[:shift_name] %>'
|
||||
local_date = '<%= @shift.shift_started_at.utc.getlocal.strftime("%e %b %I:%M%p")%> -<%= @shift.shift_closed_at ? @shift.shift_closed_at.utc.getlocal.strftime("%e %b %I:%M%p") : "-" %>'
|
||||
local_date = '<%= @shift.shift_started_at.strftime("%e %b %I:%M%p")%> -<%= @shift.shift_closed_at ? @shift.shift_closed_at.strftime("%e %b %I:%M%p") : "-" %>'
|
||||
var shift = $('#shift_name');
|
||||
str = '<option value="'+ shift_id +'" '+ 'selected = "selected"' +'>' + local_date + '</option>';
|
||||
shift.append(str);
|
||||
|
||||
@@ -33,8 +33,8 @@
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="7"> <%= t("views.right_panel.detail.from_date") %> : <%= @from.utc.getlocal.strftime("%Y-%b-%d") rescue '-' %>
|
||||
- <%= t("views.right_panel.detail.to_date") %> : <%= @to.utc.getlocal.strftime("%Y-%b-%d") rescue '-'%>
|
||||
<th colspan="7"> <%= t("views.right_panel.detail.from_date") %> : <%= @from.strftime("%Y-%b-%d") rescue '-' %>
|
||||
- <%= t("views.right_panel.detail.to_date") %> : <%= @to.strftime("%Y-%b-%d") rescue '-'%>
|
||||
|
||||
</th>
|
||||
</tr>
|
||||
|
||||
@@ -17,8 +17,8 @@
|
||||
<table class="table table-striped">
|
||||
<thead>
|
||||
<tr>
|
||||
<th colspan="7"> <%= t("views.right_panel.detail.from_date") %> : <%= @from.utc.getlocal.strftime("%Y-%b-%d") rescue '-' %>
|
||||
- <%= t("views.right_panel.detail.to_date") %> : <%= @to.utc.getlocal.strftime("%Y-%b-%d") rescue '-'%>
|
||||
<th colspan="7"> <%= t("views.right_panel.detail.from_date") %> : <%= @from.strftime("%Y-%b-%d") rescue '-' %>
|
||||
- <%= t("views.right_panel.detail.to_date") %> : <%= @to.strftime("%Y-%b-%d") rescue '-'%>
|
||||
|
||||
</th>
|
||||
</tr>
|
||||
|
||||
Reference in New Issue
Block a user