...
|
...
|
@@ -102,24 +102,6 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin |
|
|
$('.vip_price').hide();
|
|
|
}
|
|
|
});
|
|
|
$("#c-category_two_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_one_id").val()?$("#c-category_one_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_one_id").on('change',function(){
|
|
|
$("#c-category_two_id").val('');
|
|
|
$("#c-category_two_id_text").val('');
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
});
|
|
|
$("#c-category_three_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_two_id").val()?$("#c-category_two_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_two_id").on('change',function(){
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
});
|
|
|
},
|
|
|
edit: function () {
|
|
|
Controller.api.bindevent();
|
...
|
...
|
@@ -139,38 +121,44 @@ define(['jquery', 'bootstrap', 'backend', 'table', 'form'], function ($, undefin |
|
|
$('.group').hide();
|
|
|
}
|
|
|
});
|
|
|
|
|
|
$('#c-is_vip_price').change(function () {
|
|
|
var val = $('#c-is_vip_price').val();
|
|
|
if(val == 1){
|
|
|
$('.vip_price').show();
|
|
|
}else {
|
|
|
$('.vip_price').hide();
|
|
|
}
|
|
|
});
|
|
|
|
|
|
$("#c-category_two_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_one_id").val()?$("#c-category_one_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_one_id").on('change',function(){
|
|
|
$("#c-category_two_id").val('');
|
|
|
$("#c-category_two_id_text").val('');
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
});
|
|
|
$("#c-category_three_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_two_id").val()?$("#c-category_two_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_two_id").on('change',function(){
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
});
|
|
|
},
|
|
|
api: {
|
|
|
bindevent: function () {
|
|
|
Form.api.bindevent($("form[role=form]"));
|
|
|
$('#c-is_vip_price').change(function () {
|
|
|
var val = $('#c-is_vip_price').val();
|
|
|
if(val == 1){
|
|
|
$('.vip_price').show();
|
|
|
}else {
|
|
|
$('.vip_price').hide();
|
|
|
}
|
|
|
});
|
|
|
|
|
|
$("#c-category_two_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_one_id").val()?$("#c-category_one_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_one_id").change(function () {
|
|
|
$("#c-category_two_id").val('');
|
|
|
$("#c-category_two_id_text").val('');
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
$(".category_two .selected_tag").remove();
|
|
|
$(".category_three .selected_tag").remove();
|
|
|
})
|
|
|
// $("#c-category_one_id").on('change',function(){
|
|
|
//
|
|
|
// });
|
|
|
$("#c-category_three_id").data("params", function (obj) {
|
|
|
var id = $("#c-category_two_id").val()?$("#c-category_two_id").val():-1;
|
|
|
return {wherein: {pid: id}};
|
|
|
});
|
|
|
$("#c-category_two_id").on('change',function(){
|
|
|
$("#c-category_three_id").val('');
|
|
|
$("#c-category_three_id_text").val('');
|
|
|
$(".category_three .selected_tag").remove();
|
|
|
console.log(123);
|
|
|
});
|
|
|
}
|
|
|
}
|
|
|
};
|
...
|
...
|
|