forked from elmau/empresa-libre
44 lines
787 B
JavaScript
44 lines
787 B
JavaScript
|
|
|
|
function cmd_new_product_click(id, e, node){
|
|
|
|
$$("multi_products").setValue("product_new")
|
|
|
|
};
|
|
|
|
|
|
function cmd_edit_product_click(id, e, node){
|
|
|
|
$$("multi_products").setValue("product_new")
|
|
|
|
};
|
|
|
|
|
|
function cmd_delete_product_click(id, e, node){
|
|
|
|
webix.message({type:"success", text: "OK Delete"});
|
|
|
|
};
|
|
|
|
|
|
function cmd_save_product_click(id, e, node){
|
|
var form = this.getFormView();
|
|
|
|
if (!form.validate()) {
|
|
webix.message({ type:"error", text:"Valores inválidos" });
|
|
return
|
|
}
|
|
|
|
$$('form_product').clear();
|
|
$$("multi_products").setValue("products_home")
|
|
webix.message({type:"success", text: "Producto guardado correctamente"});
|
|
|
|
};
|
|
|
|
|
|
function cmd_cancel_product_click(id, e, node){
|
|
|
|
$$("multi_products").setValue("products_home")
|
|
|
|
};
|