update addorder
This commit is contained in:
@@ -166,20 +166,19 @@ $(function(){
|
|||||||
max_qty = $(this).data('max-qty');
|
max_qty = $(this).data('max-qty');
|
||||||
code = $(this).data('code');
|
code = $(this).data('code');
|
||||||
|
|
||||||
for(var field in item_options) {
|
if ($('.selected-instance').length+1 <= max_qty) {
|
||||||
value = item_options[field]["values"];
|
for(var field in item_options) {
|
||||||
type = item_options[field]["type"];
|
value = item_options[field]["values"];
|
||||||
row = "<p style='font-size:16px;margin-bottom:3px'>"+type+"</p>"
|
type = item_options[field]["type"];
|
||||||
$(value).each(function(i){
|
row = "<p style='font-size:16px;margin-bottom:3px'>"+type+"</p>"
|
||||||
row +="<button class='btn btn-default btn-sm option_btn "+ type +"' data-type='"
|
$(value).each(function(i){
|
||||||
+type+"' data-value='"+value[i]+"' data-code='"+code+"' data-group='set_menu'>"
|
row +="<button class='btn btn-default btn-sm option_btn "+ type +"' data-type='"
|
||||||
+value[i]+"</button>";
|
+type+"' data-value='"+value[i]+"' data-code='"+code+"' data-group='set_menu'>"
|
||||||
});
|
+value[i]+"</button>";
|
||||||
$(".options-list").append(row);
|
});
|
||||||
|
$(".options-list").append(row);
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
console.log($('.selected-instance').length)
|
|
||||||
|
|
||||||
if($(this).hasClass('selected-instance') == true){
|
if($(this).hasClass('selected-instance') == true){
|
||||||
sub_total = $('#set_total_price').text();
|
sub_total = $('#set_total_price').text();
|
||||||
name = $(this).data('name');
|
name = $(this).data('name');
|
||||||
|
|||||||
Reference in New Issue
Block a user