Merge branch 'adminbsb_ui_changes' of bitbucket.org:code2lab/sxrestaurant
This commit is contained in:
@@ -8,6 +8,9 @@ $(function() {
|
||||
$(".tbl_customer").hide();
|
||||
$(".order_close_cashier").hide();
|
||||
$(".order_payment_type").hide();
|
||||
$(".accepted_time").hide();
|
||||
$(".kitchen_time").hide();
|
||||
$(".ready_time").hide();
|
||||
$(function() {
|
||||
$('.first-1').click();
|
||||
});
|
||||
@@ -290,7 +293,36 @@ function show_order_detail(url,sr_no){
|
||||
var delivery = data["delivery"];
|
||||
var items = data["order_items"];
|
||||
var item_list = $('.summary-items');
|
||||
var action_times = "";
|
||||
$("#accepted_time").html("");
|
||||
$("#send_kitchen_time").html("");
|
||||
$("#ready_delivery_time").html("");
|
||||
if((data["action_times"]!=undefined) && (data["action_times"]!=null)){
|
||||
action_times = JSON.parse(data["action_times"]);
|
||||
if((action_times.accepted_time!=undefined) && (action_times.accepted_time!="")){
|
||||
$(".accepted_time").show();
|
||||
var acceptedDate = new Date(action_times.accepted_time);
|
||||
var acceptedTime = timeFormat(acceptedDate);
|
||||
var accepted_time = getOrderMonth(acceptedDate.getMonth()) +' '+ (acceptedDate.getDate() >= 10? acceptedDate.getDate() : '0' + acceptedDate.getDate()) +', '+acceptedDate.getFullYear()+'('+getOrderDay(acceptedDate.getDay())+')'+' '+acceptedTime;
|
||||
$("#accepted_time").html(accepted_time);
|
||||
}
|
||||
if((action_times.kitchen_time!=undefined) && (action_times.kitchen_time!="")){
|
||||
$(".kitchen_time").show();
|
||||
var kitchenDate = new Date(action_times.kitchen_time);
|
||||
var kitchenTime = timeFormat(kitchenDate);
|
||||
var kitchen_time = getOrderMonth(kitchenDate.getMonth()) +' '+ (kitchenDate.getDate() >= 10? kitchenDate.getDate() : '0' + kitchenDate.getDate()) +', '+kitchenDate.getFullYear()+'('+getOrderDay(kitchenDate.getDay())+')'+' '+kitchenTime;
|
||||
$("#send_kitchen_time").html(kitchen_time);
|
||||
}
|
||||
|
||||
if((action_times.ready_time!=undefined) && (action_times.ready_time!="")){
|
||||
$(".ready_time").show();
|
||||
var readyDate = new Date(action_times.ready_time);
|
||||
var readyTime = timeFormat(readyDate);
|
||||
var ready_time = getOrderMonth(readyDate.getMonth()) +' '+ (readyDate.getDate() >= 10? readyDate.getDate() : '0' + readyDate.getDate()) +', '+readyDate.getFullYear()+'('+getOrderDay(readyDate.getDay())+')'+' '+readyTime;
|
||||
$("#ready_delivery_time").html(ready_time);
|
||||
}
|
||||
}
|
||||
|
||||
var newDate = new Date(data.requested_time);
|
||||
var time = timeFormat(newDate);
|
||||
// var requested_date = newDate.getFullYear() + '-' + (newDate.getMonth() >= 10? newDate.getMonth() : '0' + (newDate.getMonth() + 1)) +'-'+ (newDate.getDate() >= 10? newDate.getDate() : '0' + newDate.getDate()) +' '+time;
|
||||
|
||||
Reference in New Issue
Block a user