Propuesta - Issue #129
This commit is contained in:
commit
06430aa922
|
@ -2240,6 +2240,7 @@ class Productos(BaseModel):
|
|||
rows = (Productos
|
||||
.select(
|
||||
Productos.id,
|
||||
Productos.es_activo,
|
||||
Productos.clave_sat,
|
||||
Productos.clave,
|
||||
Productos.descripcion,
|
||||
|
@ -2283,6 +2284,7 @@ class Productos(BaseModel):
|
|||
obj.impuestos = obj_taxes
|
||||
row = {
|
||||
'id': obj.id,
|
||||
'es_activo': obj.es_activo,
|
||||
'clave': obj.clave,
|
||||
'clave_sat': obj.clave_sat,
|
||||
'descripcion': obj.descripcion,
|
||||
|
@ -2311,6 +2313,7 @@ class Productos(BaseModel):
|
|||
obj.impuestos = obj_taxes
|
||||
row = {
|
||||
'id': obj.id,
|
||||
'es_activo': obj.es_activo,
|
||||
'clave': obj.clave,
|
||||
'clave_sat': obj.clave_sat,
|
||||
'descripcion': obj.descripcion,
|
||||
|
|
|
@ -159,6 +159,7 @@ function update_grid_products(values){
|
|||
msg = 'Producto actualizado correctamente'
|
||||
$$("grid_products").updateItem(values.row['id'], values.row)
|
||||
}
|
||||
$$('grid_products').refresh()
|
||||
$$('multi_products').setValue('products_home')
|
||||
msg_ok(msg)
|
||||
}
|
||||
|
|
|
@ -12,6 +12,7 @@ var toolbar_products = [
|
|||
|
||||
var grid_products_cols = [
|
||||
{ id: "id", header: "ID", width: 75, hidden: true},
|
||||
{ id: 'es_activo', header: 'Activo', hidden: true},
|
||||
{ id: "clave_sat", header: ["Clave SAT"], width: 100,},
|
||||
{ id: "clave", header: ["Clave", {content: "textFilter"}], width: 100,
|
||||
sort: 'string', footer: {content: 'countRows', css: 'right'}},
|
||||
|
@ -25,14 +26,21 @@ var grid_products_cols = [
|
|||
|
||||
|
||||
var grid_products = {
|
||||
view: "datatable",
|
||||
id: "grid_products",
|
||||
select: "row",
|
||||
view: 'datatable',
|
||||
id: 'grid_products',
|
||||
select: 'row',
|
||||
adjust: true,
|
||||
footer: true,
|
||||
resizeColumn: true,
|
||||
headermenu: true,
|
||||
columns: grid_products_cols,
|
||||
scheme:{
|
||||
$change:function(item){
|
||||
if(!item.es_activo){
|
||||
item.$css = 'cancel'
|
||||
}
|
||||
}
|
||||
},
|
||||
}
|
||||
|
||||
|
||||
|
|
Loading…
Reference in New Issue