diff --git a/app/assets/javascripts/order_reservation.js b/app/assets/javascripts/order_reservation.js index 990e4a74..07eab9e1 100644 --- a/app/assets/javascripts/order_reservation.js +++ b/app/assets/javascripts/order_reservation.js @@ -282,8 +282,8 @@ function callback_url(callback,ref_no,order_id,status,time,exptime){ function timeFormat(date){ var isPM = date.getHours() >= 12; var isMidday = date.getHours() == 12; - var time = [date.getHours() - (isPM && !isMidday ? 12 : 0), - date.getMinutes() || '00'].join(':') + + var time = [(date.getHours()>10? date.getHours() : '0'+date.getHours()) - (isPM && !isMidday ? 12 : 0), + (date.getMinutes()>10? date.getMinutes() : '0'+date.getMinutes()) || '00'].join(':') + (isPM ? ' PM' : ' AM'); return time; } diff --git a/app/views/origami/order_reservation/index.html.erb b/app/views/origami/order_reservation/index.html.erb index 89c4b4e9..34664428 100644 --- a/app/views/origami/order_reservation/index.html.erb +++ b/app/views/origami/order_reservation/index.html.erb @@ -378,7 +378,7 @@ - +
@@ -411,4 +411,6 @@ - \ No newline at end of file + + +