X-Git-Url: https://git.llucax.com/mecon/samurai.git/blobdiff_plain/d0ae155a8be2168110755cce58865068b34bfe91..3c702b40a1806798e475c48abb456e5a9c2dac72:/lib/SAMURAI/Sistema/consultas.ini diff --git a/lib/SAMURAI/Sistema/consultas.ini b/lib/SAMURAI/Sistema/consultas.ini index c7825f1..6ebc013 100644 --- a/lib/SAMURAI/Sistema/consultas.ini +++ b/lib/SAMURAI/Sistema/consultas.ini @@ -1,13 +1,16 @@ ; ConfiguraciĆ³n de la base de datos. ; $Id$ -obtener_datos_sistema = " SELECT id_sistema, nombre_sistema, desc_sistema, fecha_inicio, fecha_fin, fecha_implementacion, contacto,responsable FROM samurai.sistema " -obtener_datos_sistema2 = " WHERE id_sistema = ? " -obtener_datos_sistema3 = " WHERE estado = 1" -obtener_permisos = " SELECT id_permiso, observaciones FROM samurai.perm_sist WHERE id_sistema = ?" -obtener_permisos2 = " ORDER BY id_permiso" -obtener_permisos3 = " AND id_permiso = ?" -obtener_permisos4 = " AND observaciones = ?" + + + +obtener_datos_sistema = " SELECT s.id_sistema as id_sistema, s.nombre_sistema as nombre_sistema, s.desc_sistema as desc_sistema, s.fecha_inicio as fecha_inicio, s.fecha_fin as fecha_fin, s.fecha_implementacion as fecha_implementacion, s.contacto as contacto, s.responsable as responsable FROM samurai.sistema as s " +obtener_datos_sistema2 = " WHERE s.id_sistema = ? " +obtener_datos_sistema3 = " WHERE s.estado = 1" +obtener_permisos = " SELECT ps.id_permiso, ps.observaciones, p.desc_permiso FROM samurai.perm_sist as ps, samurai.permiso as p WHERE ps.id_sistema = ? AND ps.id_permiso = p.id_permiso" +obtener_permisos2 = " ORDER BY p.id_permiso" +obtener_permisos3 = " AND ps.id_permiso = ?" +obtener_permisos4 = " AND ps.observaciones = ?" obtener_max_id_sistemas = " SELECT IFNULL(max(id_sistema), 1) as id_sistema FROM samurai.sistema" borrar_permisos = " DELETE FROM samurai.perm_sist WHERE id_sistema = ? " borrar_permisos2 = " AND observaciones = ?"