update addorder for product

This commit is contained in:
Aung Myo
2018-06-13 11:18:16 +06:30
parent b949263979
commit 676ec4d611
2 changed files with 10 additions and 4 deletions

View File

@@ -6,8 +6,8 @@ $(function() {
//click menu sidebar menu category //click menu sidebar menu category
$(".product").on("click", function(){ $(".product").on("click", function(){
// /var url = $(this).attr('data-ref'); var url = $(this).attr('data-ref');
// /show_product_list(url); show_product_list(url);
}); });
//show menu item list when click menu category //show menu item list when click menu category
function show_product_list(url_item){ function show_product_list(url_item){
@@ -43,7 +43,7 @@ $(function() {
options = []; options = [];
item_attributes = []; item_attributes = [];
if (product[field].image_path) { if (product[field].image_path.url) {
if (type != -1 && modify_order != -1) { if (type != -1 && modify_order != -1) {
image_path = '../../'+product[field].image_path.url; image_path = '../../'+product[field].image_path.url;
} }
@@ -74,7 +74,7 @@ $(function() {
+'</div>' +'</div>'
+'</div>' +'</div>'
+"<div class='add_icon' data-item-code='" +"<div class='add_icon p-t-65' data-item-code='"
+ product[field].item_code +"' data-name='" + product[field].item_code +"' data-name='"
+ product[field].name +"' data-qty = '"+ qty +"' data-price = '" + product[field].name +"' data-qty = '"+ qty +"' data-price = '"
+ product[field].unit_price +"' data-instance-code = '"+ product[field].item_code +"' data-instance = '" + product[field].unit_price +"' data-instance-code = '"+ product[field].item_code +"' data-instance = '"

View File

@@ -668,6 +668,12 @@
menu_cat.empty(); menu_cat.empty();
$(".main_menu").text(name); $(".main_menu").text(name);
// row = ' <li class="nav-item product" data-ref="<%= origami_get_all_product_path %>">'
// +'<a class="nav-link" data-toggle="tab" href="" role="tab">Products</a>'
// +'</li>';
// $(".category_cache_list").append(row);
for(var i in menus) { for(var i in menus) {
if (menu_id == menus[i]["id"] && menus[i]["is_active"] == true) { if (menu_id == menus[i]["id"] && menus[i]["is_active"] == true) {