From 51ae946b79170e17d10363430aceeead5f268bc5 Mon Sep 17 00:00:00 2001 From: Mauricio Baeza Date: Sun, 14 Jan 2018 00:39:28 -0600 Subject: [PATCH] Usos del CFDI ordenar por nombre --- source/app/models/main.py | 2 +- source/static/js/ui/admin.js | 4 ++-- 2 files changed, 3 insertions(+), 3 deletions(-) diff --git a/source/app/models/main.py b/source/app/models/main.py index fdec255..db6f987 100644 --- a/source/app/models/main.py +++ b/source/app/models/main.py @@ -1710,7 +1710,7 @@ class SATUsoCfdi(BaseModel): moral = BooleanField(default=False) class Meta: - order_by = ('-default', 'name',) + order_by = ('name',) indexes = ( (('key', 'name'), True), ) diff --git a/source/static/js/ui/admin.js b/source/static/js/ui/admin.js index 22440dc..f04218c 100644 --- a/source/static/js/ui/admin.js +++ b/source/static/js/ui/admin.js @@ -733,14 +733,14 @@ function format_bool_moral(obj){ var grid_admin_usos_cfdi_cols = [ {id: 'id', header: 'ID', hidden: true}, - {id: 'key', header: 'Clave'}, + {id: 'key', header: 'Clave', adjust: 'header'}, {id: 'name', header: 'Nombre', width: 500}, {id: 'fisica', header: 'FĂ­sicas', adjust: 'header', template: format_bool_fisica}, {id: 'moral', header: 'Morales', adjust: 'header', template: format_bool_moral}, {id: 'activo', header: 'Activa', template: '{common.checkbox()}', - editor: 'checkbox'}, + editor: 'checkbox', adjust: 'header'}, ]