Skip to content

Commit

Permalink
Merge pull request #70 from StemboltHQ/fix_date_conversion_problem_wh…
Browse files Browse the repository at this point in the history
…en_creating_bet

Fix date conversion problem when creating bet
  • Loading branch information
LeonTenko authored Apr 12, 2017
2 parents b036263 + 9f24d6a commit 8129e77
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 2 deletions.
3 changes: 2 additions & 1 deletion app/assets/javascripts/lib/date_picker.js
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
$(document).on("turbolinks:load", function(){
$(".jquery-datepicker").datetimepicker({
minDate: "0"
minDate: "0",
format: "Y-m-d G:i:s P"
});
});
2 changes: 1 addition & 1 deletion app/views/shared/_bet_display.html.erb
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
</div>

<div class="card-footer text-danger">
Expires on: <%= bet.expires_at.strftime('%A, %B %d %Y, %l:%M %P') %>
Expires on: <%= bet.expires_at.localtime.strftime('%A, %B %d %Y, %l:%M %P') %>
</div>
</div>
</div>
Expand Down
1 change: 1 addition & 0 deletions config/application.rb
Original file line number Diff line number Diff line change
Expand Up @@ -11,5 +11,6 @@ class Application < Rails::Application
# Settings in config/environments/* take precedence over those specified here.
# Application configuration should go into files in config/initializers
# -- all .rb files in that directory are automatically loaded.
config.time_zone = 'Pacific Time (US & Canada)'
end
end

0 comments on commit 8129e77

Please sign in to comment.