616 lines
24 KiB
VB.net
616 lines
24 KiB
VB.net
Option Strict On
|
|
Imports Extensiones
|
|
Imports System.Data
|
|
|
|
|
|
Partial Class RH_CatChecadorHorarios
|
|
Inherits ClsPaginas
|
|
|
|
Private Property CveChecadorHorario As Integer
|
|
Get
|
|
If ViewState("CveChecadorHorario") Is Nothing Then
|
|
Return -1
|
|
Else
|
|
Return DirectCast(ViewState("CveChecadorHorario"), Integer)
|
|
End If
|
|
End Get
|
|
Set(value As Integer)
|
|
ViewState("CveChecadorHorario") = value
|
|
End Set
|
|
End Property
|
|
|
|
Private Property Actulizar As Boolean
|
|
Get
|
|
If ViewState("Actulizar") Is Nothing Then
|
|
Return True
|
|
Else
|
|
Return Boolean.Parse(ViewState("Actulizar").ToString)
|
|
End If
|
|
End Get
|
|
Set(value As Boolean)
|
|
ViewState("Actulizar") = value
|
|
End Set
|
|
End Property
|
|
|
|
Private Sub RH_CatChecadorHorarios_Load(sender As Object, e As EventArgs) Handles Me.Load
|
|
If Not Page.IsPostBack Then
|
|
CargaDatos()
|
|
End If
|
|
End Sub
|
|
|
|
Private Sub CargaDatos()
|
|
|
|
Dim objRH As New ClsRH
|
|
|
|
If objRH.ChecadorHorariosGet(-1, -1, UsuarioActual.CveEmpresa) Then
|
|
GvHorarios.DataSource = objRH.DtResultados
|
|
Else
|
|
GvHorarios.DataSource = Nothing
|
|
End If
|
|
|
|
objRH.Dispose()
|
|
GvHorarios.DataBind()
|
|
|
|
UPGvHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub BtnAgregarSucursalModal_Click(sender As Object, e As EventArgs) Handles BtnAgregarSucursalModal.Click
|
|
LtlAsistenciaHorariosModal.Text = "Agregar Horario"
|
|
BtnHorarioModal.Text = "Agregar"
|
|
|
|
ResetControles()
|
|
CamposFechas()
|
|
RegistraScript("$('#divHorarios').modal({ backdrop: 'static', keyboard: false});")
|
|
|
|
End Sub
|
|
|
|
Private Sub ResetControles()
|
|
|
|
TxtHorario.Text = ""
|
|
ChkLunes.Checked = True
|
|
ChkMartes.Checked = True
|
|
ChkMiercoles.Checked = True
|
|
ChkJueves.Checked = True
|
|
ChkViernes.Checked = True
|
|
ChkSabado.Checked = True
|
|
ChkDomingo.Checked = False
|
|
|
|
TxtLunesEntrada.Text = ""
|
|
TxtLunesSalidaComida.Text = ""
|
|
TxtLunesEntradaComida.Text = ""
|
|
TxtLunesSalida.Text = ""
|
|
|
|
TxtMartesEntrada.Text = ""
|
|
TxtMartesSalidaComida.Text = ""
|
|
TxtMartesEntradaComida.Text = ""
|
|
TxtMartesSalida.Text = ""
|
|
|
|
TxtMiercolesEntrada.Text = ""
|
|
TxtMiercolesSalidaComida.Text = ""
|
|
TxtMiercolesEntradaComida.Text = ""
|
|
TxtMiercolesSalida.Text = ""
|
|
|
|
TxtJuevesEntrada.Text = ""
|
|
TxtJuevesSalidaComida.Text = ""
|
|
TxtJuevesEntradaComida.Text = ""
|
|
TxtJuevesSalida.Text = ""
|
|
|
|
TxtViernesEntrada.Text = ""
|
|
TxtViernesSalidaComida.Text = ""
|
|
TxtViernesEntradaComida.Text = ""
|
|
TxtViernesSalida.Text = ""
|
|
|
|
TxtSabadoEntrada.Text = ""
|
|
TxtSabadoSalidaComida.Text = ""
|
|
TxtSabadoEntradaComida.Text = ""
|
|
TxtSabadoSalida.Text = ""
|
|
|
|
TxtDomingoEntrada.Text = ""
|
|
TxtDomingoSalidaComida.Text = ""
|
|
TxtDomingoEntradaComida.Text = ""
|
|
TxtDomingoSalida.Text = ""
|
|
UpHorarios.Update()
|
|
|
|
TxtTolRetAcumulados.Text = ""
|
|
TxtTolRetEntradaMin.Text = ""
|
|
TxtTolFalEntradaMin.Text = ""
|
|
ChkRetardoSalidaAntes.Checked = False
|
|
TxtTolSalidaAntes.Text = "0"
|
|
|
|
ChkActivo.Checked = True
|
|
TxtHorario.Text = ""
|
|
|
|
Actulizar = False
|
|
CveChecadorHorario = -1
|
|
|
|
End Sub
|
|
|
|
Public Sub Edit_ClickCursos(sender As Object, e As EventArgs)
|
|
|
|
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
|
|
Dim objRH As New ClsRH
|
|
|
|
LtlAsistenciaHorariosModal.Text = "Actualizar Horario"
|
|
BtnHorarioModal.Text = "Actualizar"
|
|
|
|
ChkActivo.Checked = Boolean.Parse(GvRow.DataKey("Estatus"))
|
|
TxtHorario.Text = GvRow.DataKey("ChecadorHorario")
|
|
|
|
ChkLunes.Checked = Boolean.Parse(GvRow.DataKey("Lunes"))
|
|
TxtLunesEntrada.Text = GvRow.DataKey("LunesEntrada")
|
|
TxtLunesSalidaComida.Text = GvRow.DataKey("LunesSalidaComida")
|
|
TxtLunesEntradaComida.Text = GvRow.DataKey("LunesEntradaComida")
|
|
TxtLunesSalida.Text = GvRow.DataKey("LunesSalida")
|
|
|
|
ChkMartes.Checked = Boolean.Parse(GvRow.DataKey("Martes"))
|
|
TxtMartesEntrada.Text = GvRow.DataKey("MartesEntrada")
|
|
TxtMartesSalidaComida.Text = GvRow.DataKey("MartesSalidaComida")
|
|
TxtMartesEntradaComida.Text = GvRow.DataKey("MartesEntradaComida")
|
|
TxtMartesSalida.Text = GvRow.DataKey("MartesSalida")
|
|
|
|
|
|
ChkMiercoles.Checked = Boolean.Parse(GvRow.DataKey("Miercoles"))
|
|
TxtMiercolesEntrada.Text = GvRow.DataKey("MiercolesEntrada")
|
|
TxtMiercolesSalidaComida.Text = GvRow.DataKey("MiercolesSalidaComida")
|
|
TxtMiercolesEntradaComida.Text = GvRow.DataKey("MiercolesEntradaComida")
|
|
TxtMiercolesSalida.Text = GvRow.DataKey("MiercolesSalida")
|
|
|
|
ChkJueves.Checked = Boolean.Parse(GvRow.DataKey("Jueves"))
|
|
TxtJuevesEntrada.Text = GvRow.DataKey("JuevesEntrada")
|
|
TxtJuevesSalidaComida.Text = GvRow.DataKey("JuevesSalidaComida")
|
|
TxtJuevesEntradaComida.Text = GvRow.DataKey("JuevesEntradaComida")
|
|
TxtJuevesSalida.Text = GvRow.DataKey("JuevesSalida")
|
|
|
|
ChkViernes.Checked = Boolean.Parse(GvRow.DataKey("Viernes"))
|
|
TxtViernesEntrada.Text = GvRow.DataKey("ViernesEntrada")
|
|
TxtViernesSalidaComida.Text = GvRow.DataKey("ViernesSalidaComida")
|
|
TxtViernesEntradaComida.Text = GvRow.DataKey("ViernesEntradaComida")
|
|
TxtViernesSalida.Text = GvRow.DataKey("ViernesSalida")
|
|
|
|
ChkSabado.Checked = Boolean.Parse(GvRow.DataKey("Sabado"))
|
|
TxtSabadoEntrada.Text = GvRow.DataKey("SabadoEntrada")
|
|
TxtSabadoSalidaComida.Text = GvRow.DataKey("SabadoSalidaComida")
|
|
TxtSabadoEntradaComida.Text = GvRow.DataKey("SabadoEntradaComida")
|
|
TxtSabadoSalida.Text = GvRow.DataKey("SabadoSalida")
|
|
|
|
ChkDomingo.Checked = Boolean.Parse(GvRow.DataKey("Domingo"))
|
|
TxtDomingoEntrada.Text = GvRow.DataKey("DomingoEntrada")
|
|
TxtDomingoSalidaComida.Text = GvRow.DataKey("DomingoSalidaComida")
|
|
TxtDomingoEntradaComida.Text = GvRow.DataKey("DomingoEntradaComida")
|
|
TxtDomingoSalida.Text = GvRow.DataKey("DomingoSalida")
|
|
|
|
CveChecadorHorario = GvRow.DataKey("CveChecadorHorario").ToEntero
|
|
Actulizar = True
|
|
'TolRetAcumulados,TolRetEntradaMin,TolFalEntradaMin,RetSalidaAntes,TolSalidaAntes"
|
|
TxtTolRetAcumulados.Text = GvRow.DataKey("TolRetAcumulados").ToString
|
|
'TxtTolSalidaAntes.Text = GvRow.DataKey("TolSalidaAntesMin.").ToString
|
|
TxtTolRetEntradaMin.Text = GvRow.DataKey("TolRetEntradaMin").ToString
|
|
TxtTolFalEntradaMin.Text = GvRow.DataKey("TolFalEntradaMin").ToString
|
|
|
|
ChkRetardoSalidaAntes.Checked = Boolean.Parse(GvRow.DataKey("RetSalidaAntes").ToString)
|
|
|
|
If ChkRetardoSalidaAntes.Checked Then
|
|
TxtTolSalidaAntes.Enabled = True
|
|
Else
|
|
TxtTolSalidaAntes.Enabled = False
|
|
End If
|
|
TxtTolSalidaAntes.Text = GvRow.DataKey("TolSalidaAntesMin").ToString
|
|
|
|
UpHorarios.Update()
|
|
CamposFechas()
|
|
RegistraScript("$('#divHorarios').modal({ backdrop: 'static', keyboard: false});")
|
|
|
|
End Sub
|
|
|
|
|
|
Protected Sub BtnHorarioModal_Click(sender As Object, e As EventArgs) Handles BtnHorarioModal.Click
|
|
|
|
Dim objRH As New ClsRH
|
|
Dim _Lunes, _Martes, _Miercoles, _Jueves, _Viernes, _Sabado, _Domingo, _Estatus, _RetSalidaAntes As Integer
|
|
|
|
If ChkLunes.Checked Then _Lunes = 1 Else _Lunes = 0
|
|
If ChkMartes.Checked Then _Martes = 1 Else _Martes = 0
|
|
If ChkMiercoles.Checked Then _Miercoles = 1 Else _Miercoles = 0
|
|
If ChkJueves.Checked Then _Jueves = 1 Else _Jueves = 0
|
|
If ChkViernes.Checked Then _Viernes = 1 Else _Viernes = 0
|
|
If ChkSabado.Checked Then _Sabado = 1 Else _Sabado = 0
|
|
If ChkDomingo.Checked Then _Domingo = 1 Else _Domingo = 0
|
|
|
|
If ChkRetardoSalidaAntes.Checked Then _RetSalidaAntes = 1 Else _RetSalidaAntes = 0
|
|
|
|
If ChkActivo.Checked Then _Estatus = 1 Else _Estatus = 0
|
|
|
|
If CveChecadorHorario = -1 And Actulizar = False Then
|
|
|
|
If objRH.ChecadorHorariosAddUpdate(-1, TxtHorario.Text.Trim,
|
|
_Lunes, TxtLunesEntrada.Text, TxtLunesSalidaComida.Text, TxtLunesEntradaComida.Text, TxtLunesSalida.Text,
|
|
_Martes, TxtMartesEntrada.Text, TxtMartesSalidaComida.Text, TxtMartesEntradaComida.Text, TxtMartesSalida.Text,
|
|
_Miercoles, TxtMiercolesEntrada.Text, TxtMiercolesSalidaComida.Text, TxtMiercolesEntradaComida.Text, TxtMiercolesSalida.Text,
|
|
_Jueves, TxtJuevesEntrada.Text, TxtJuevesSalidaComida.Text, TxtJuevesEntradaComida.Text, TxtJuevesSalida.Text,
|
|
_Viernes, TxtViernesEntrada.Text, TxtViernesSalidaComida.Text, TxtViernesEntradaComida.Text, TxtViernesSalida.Text,
|
|
_Sabado, TxtSabadoEntrada.Text, TxtSabadoSalidaComida.Text, TxtSabadoEntradaComida.Text, TxtSabadoSalida.Text,
|
|
_Domingo, TxtDomingoEntrada.Text, TxtDomingoSalidaComida.Text, TxtDomingoEntradaComida.Text, TxtDomingoSalida.Text,
|
|
TxtTolRetAcumulados.Text.ToEntero, TxtTolRetEntradaMin.Text.ToEntero, TxtTolFalEntradaMin.Text.ToEntero, _RetSalidaAntes, TxtTolSalidaAntes.Text.ToEntero,
|
|
_Estatus, UsuarioActual.CveUsuario, UsuarioActual.Empresa.CveEmpresa) Then
|
|
Alert("Horario agregado correctamente.")
|
|
CargaDatos()
|
|
End If
|
|
|
|
Else
|
|
|
|
If objRH.ChecadorHorariosAddUpdate(CveChecadorHorario, TxtHorario.Text.Trim,
|
|
_Lunes, TxtLunesEntrada.Text, TxtLunesSalidaComida.Text, TxtLunesEntradaComida.Text, TxtLunesSalida.Text,
|
|
_Martes, TxtMartesEntrada.Text, TxtMartesSalidaComida.Text, TxtMartesEntradaComida.Text, TxtMartesSalida.Text,
|
|
_Miercoles, TxtMiercolesEntrada.Text, TxtMiercolesSalidaComida.Text, TxtMiercolesEntradaComida.Text, TxtMiercolesSalida.Text,
|
|
_Jueves, TxtJuevesEntrada.Text, TxtJuevesSalidaComida.Text, TxtJuevesEntradaComida.Text, TxtJuevesSalida.Text,
|
|
_Viernes, TxtViernesEntrada.Text, TxtViernesSalidaComida.Text, TxtViernesEntradaComida.Text, TxtViernesSalida.Text,
|
|
_Sabado, TxtSabadoEntrada.Text, TxtSabadoSalidaComida.Text, TxtSabadoEntradaComida.Text, TxtSabadoSalida.Text,
|
|
_Domingo, TxtDomingoEntrada.Text, TxtDomingoSalidaComida.Text, TxtDomingoEntradaComida.Text, TxtDomingoSalida.Text,
|
|
TxtTolRetAcumulados.Text.ToEntero, TxtTolRetEntradaMin.Text.ToEntero, TxtTolFalEntradaMin.Text.ToEntero, _RetSalidaAntes, TxtTolSalidaAntes.Text.ToEntero,
|
|
_Estatus, UsuarioActual.CveUsuario, UsuarioActual.Empresa.CveEmpresa) Then
|
|
|
|
|
|
Alert("Horario actualizado correctamente.")
|
|
CargaDatos()
|
|
End If
|
|
|
|
End If
|
|
|
|
CveChecadorHorario = -1
|
|
Actulizar = False
|
|
|
|
RegistraScript("$('#divHorarios').modal('hide');")
|
|
|
|
End Sub
|
|
|
|
Public Sub Remove_ClickHorario(sender As Object, e As EventArgs)
|
|
Dim objRH As New ClsRH
|
|
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
|
|
|
|
Dim _CveChecadorHorario As Integer = GvRow.DataKey("CveChecadorHorario").ToEntero
|
|
|
|
If objRH.ChecadorHorariosRemove(_CveChecadorHorario, UsuarioActual.Empresa.CveEmpresa) Then
|
|
|
|
CargaDatos()
|
|
Alert("Horario elimino correctamente ", TipoMensaje.MsgInformacion)
|
|
Else
|
|
Alert("Ocurrio un error al eliminar el horario.", TipoMensaje.MsgError)
|
|
End If
|
|
objRH.Dispose()
|
|
End Sub
|
|
|
|
Protected Sub ChkLunes_CheckedChanged(sender As Object, e As EventArgs) Handles ChkLunes.CheckedChanged
|
|
|
|
|
|
If ChkLunes.Checked = False Then
|
|
TxtLunesEntrada.Text = "00:00:00"
|
|
TxtLunesSalidaComida.Text = "00:00:00"
|
|
TxtLunesEntradaComida.Text = "00:00:00"
|
|
TxtLunesSalida.Text = "00:00:00"
|
|
|
|
TxtLunesEntrada.Enabled = False
|
|
TxtLunesSalidaComida.Enabled = False
|
|
TxtLunesEntradaComida.Enabled = False
|
|
TxtLunesSalida.Enabled = False
|
|
Else
|
|
TxtLunesEntrada.Text = ""
|
|
TxtLunesSalidaComida.Text = ""
|
|
TxtLunesEntradaComida.Text = ""
|
|
TxtLunesSalida.Text = ""
|
|
|
|
TxtLunesEntrada.Enabled = True
|
|
TxtLunesSalidaComida.Enabled = True
|
|
TxtLunesEntradaComida.Enabled = True
|
|
TxtLunesSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkMartes_CheckedChanged(sender As Object, e As EventArgs) Handles ChkMartes.CheckedChanged
|
|
|
|
|
|
If ChkMartes.Checked = False Then
|
|
TxtMartesEntrada.Text = "00:00:00"
|
|
TxtMartesSalidaComida.Text = "00:00:00"
|
|
TxtMartesEntradaComida.Text = "00:00:00"
|
|
TxtMartesSalida.Text = "00:00:00"
|
|
|
|
TxtMartesEntrada.Enabled = False
|
|
TxtMartesSalidaComida.Enabled = False
|
|
TxtMartesEntradaComida.Enabled = False
|
|
TxtMartesSalida.Enabled = False
|
|
Else
|
|
TxtMartesEntrada.Text = ""
|
|
TxtMartesSalidaComida.Text = ""
|
|
TxtMartesEntradaComida.Text = ""
|
|
TxtMartesSalida.Text = ""
|
|
|
|
TxtMartesEntrada.Enabled = True
|
|
TxtMartesSalidaComida.Enabled = True
|
|
TxtMartesEntradaComida.Enabled = True
|
|
TxtMartesSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkMiercoles_CheckedChanged(sender As Object, e As EventArgs) Handles ChkMiercoles.CheckedChanged
|
|
|
|
|
|
If ChkMiercoles.Checked = False Then
|
|
TxtMiercolesEntrada.Text = "00:00:00"
|
|
TxtMiercolesSalidaComida.Text = "00:00:00"
|
|
TxtMiercolesEntradaComida.Text = "00:00:00"
|
|
TxtMiercolesSalida.Text = "00:00:00"
|
|
|
|
TxtMiercolesEntrada.Enabled = False
|
|
TxtMiercolesSalidaComida.Enabled = False
|
|
TxtMiercolesEntradaComida.Enabled = False
|
|
TxtMiercolesSalida.Enabled = False
|
|
Else
|
|
TxtMiercolesEntrada.Text = ""
|
|
TxtMiercolesSalidaComida.Text = ""
|
|
TxtMiercolesEntradaComida.Text = ""
|
|
TxtMiercolesSalida.Text = ""
|
|
|
|
TxtMiercolesEntrada.Enabled = True
|
|
TxtMiercolesSalidaComida.Enabled = True
|
|
TxtMiercolesEntradaComida.Enabled = True
|
|
TxtMiercolesSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkJueves_CheckedChanged(sender As Object, e As EventArgs) Handles ChkJueves.CheckedChanged
|
|
|
|
|
|
If ChkJueves.Checked = False Then
|
|
TxtJuevesEntrada.Text = "00:00:00"
|
|
TxtJuevesSalidaComida.Text = "00:00:00"
|
|
TxtJuevesEntradaComida.Text = "00:00:00"
|
|
TxtJuevesSalida.Text = "00:00:00"
|
|
|
|
TxtJuevesEntrada.Enabled = False
|
|
TxtJuevesSalidaComida.Enabled = False
|
|
TxtJuevesEntradaComida.Enabled = False
|
|
TxtJuevesSalida.Enabled = False
|
|
Else
|
|
TxtJuevesEntrada.Text = ""
|
|
TxtJuevesSalidaComida.Text = ""
|
|
TxtJuevesEntradaComida.Text = ""
|
|
TxtJuevesSalida.Text = ""
|
|
|
|
TxtJuevesEntrada.Enabled = True
|
|
TxtJuevesSalidaComida.Enabled = True
|
|
TxtJuevesEntradaComida.Enabled = True
|
|
TxtJuevesSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkViernes_CheckedChanged(sender As Object, e As EventArgs) Handles ChkViernes.CheckedChanged
|
|
|
|
|
|
If ChkViernes.Checked = False Then
|
|
TxtViernesEntrada.Text = "00:00:00"
|
|
TxtViernesSalidaComida.Text = "00:00:00"
|
|
TxtViernesEntradaComida.Text = "00:00:00"
|
|
TxtViernesSalida.Text = "00:00:00"
|
|
|
|
TxtViernesEntrada.Enabled = False
|
|
TxtViernesSalidaComida.Enabled = False
|
|
TxtViernesEntradaComida.Enabled = False
|
|
TxtViernesSalida.Enabled = False
|
|
Else
|
|
TxtViernesEntrada.Text = ""
|
|
TxtViernesSalidaComida.Text = ""
|
|
TxtViernesEntradaComida.Text = ""
|
|
TxtViernesSalida.Text = ""
|
|
|
|
TxtViernesEntrada.Enabled = True
|
|
TxtViernesSalidaComida.Enabled = True
|
|
TxtViernesEntradaComida.Enabled = True
|
|
TxtViernesSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkSabado_CheckedChanged(sender As Object, e As EventArgs) Handles ChkSabado.CheckedChanged
|
|
|
|
|
|
If ChkSabado.Checked = False Then
|
|
TxtSabadoEntrada.Text = "00:00:00"
|
|
TxtSabadoSalidaComida.Text = "00:00:00"
|
|
TxtSabadoEntradaComida.Text = "00:00:00"
|
|
TxtSabadoSalida.Text = "00:00:00"
|
|
|
|
TxtSabadoEntrada.Enabled = False
|
|
TxtSabadoSalidaComida.Enabled = False
|
|
TxtSabadoEntradaComida.Enabled = False
|
|
TxtSabadoSalida.Enabled = False
|
|
Else
|
|
TxtSabadoEntrada.Text = ""
|
|
TxtSabadoSalidaComida.Text = ""
|
|
TxtSabadoEntradaComida.Text = ""
|
|
TxtSabadoSalida.Text = ""
|
|
|
|
TxtSabadoEntrada.Enabled = True
|
|
TxtSabadoSalidaComida.Enabled = True
|
|
TxtSabadoEntradaComida.Enabled = True
|
|
TxtSabadoSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
Protected Sub ChkDomingo_CheckedChanged(sender As Object, e As EventArgs) Handles ChkDomingo.CheckedChanged
|
|
|
|
|
|
If ChkDomingo.Checked = False Then
|
|
TxtDomingoEntrada.Text = "00:00:00"
|
|
TxtDomingoSalidaComida.Text = "00:00:00"
|
|
TxtDomingoEntradaComida.Text = "00:00:00"
|
|
TxtDomingoSalida.Text = "00:00:00"
|
|
|
|
TxtDomingoEntrada.Enabled = False
|
|
TxtDomingoSalidaComida.Enabled = False
|
|
TxtDomingoEntradaComida.Enabled = False
|
|
TxtDomingoSalida.Enabled = False
|
|
Else
|
|
TxtDomingoEntrada.Text = ""
|
|
TxtDomingoSalidaComida.Text = ""
|
|
TxtDomingoEntradaComida.Text = ""
|
|
TxtDomingoSalida.Text = ""
|
|
|
|
TxtDomingoEntrada.Enabled = True
|
|
TxtDomingoSalidaComida.Enabled = True
|
|
TxtDomingoEntradaComida.Enabled = True
|
|
TxtDomingoSalida.Enabled = True
|
|
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
|
|
|
|
Private Sub CamposFechas()
|
|
If ChkLunes.Checked = False Then
|
|
TxtLunesEntrada.Text = "00:00:00"
|
|
TxtLunesSalidaComida.Text = "00:00:00"
|
|
TxtLunesEntradaComida.Text = "00:00:00"
|
|
TxtLunesSalida.Text = "00:00:00"
|
|
|
|
TxtLunesEntrada.Enabled = False
|
|
TxtLunesSalidaComida.Enabled = False
|
|
TxtLunesEntradaComida.Enabled = False
|
|
TxtLunesSalida.Enabled = False
|
|
Else
|
|
TxtLunesEntrada.Enabled = True
|
|
TxtLunesSalidaComida.Enabled = True
|
|
TxtLunesEntradaComida.Enabled = True
|
|
TxtLunesSalida.Enabled = True
|
|
End If
|
|
|
|
If ChkMartes.Checked = False Then
|
|
TxtMartesEntrada.Text = "00:00:00"
|
|
TxtMartesSalidaComida.Text = "00:00:00"
|
|
TxtMartesEntradaComida.Text = "00:00:00"
|
|
TxtMartesSalida.Text = "00:00:00"
|
|
|
|
TxtMartesEntrada.Enabled = False
|
|
TxtMartesSalidaComida.Enabled = False
|
|
TxtMartesEntradaComida.Enabled = False
|
|
TxtMartesSalida.Enabled = False
|
|
Else
|
|
TxtMartesEntrada.Enabled = True
|
|
TxtMartesSalidaComida.Enabled = True
|
|
TxtMartesEntradaComida.Enabled = True
|
|
TxtMartesSalida.Enabled = True
|
|
End If
|
|
|
|
If ChkMiercoles.Checked = False Then
|
|
TxtMiercolesEntrada.Text = "00:00:00"
|
|
TxtMiercolesSalidaComida.Text = "00:00:00"
|
|
TxtMiercolesEntradaComida.Text = "00:00:00"
|
|
TxtMiercolesSalida.Text = "00:00:00"
|
|
|
|
TxtMiercolesEntrada.Enabled = False
|
|
TxtMiercolesSalidaComida.Enabled = False
|
|
TxtMiercolesEntradaComida.Enabled = False
|
|
TxtMiercolesSalida.Enabled = False
|
|
Else
|
|
TxtMiercolesEntrada.Enabled = True
|
|
TxtMiercolesSalidaComida.Enabled = True
|
|
TxtMiercolesEntradaComida.Enabled = True
|
|
TxtMiercolesSalida.Enabled = True
|
|
End If
|
|
|
|
If ChkJueves.Checked = False Then
|
|
TxtJuevesEntrada.Text = "00:00:00"
|
|
TxtJuevesSalidaComida.Text = "00:00:00"
|
|
TxtJuevesEntradaComida.Text = "00:00:00"
|
|
TxtJuevesSalida.Text = "00:00:00"
|
|
|
|
TxtJuevesEntrada.Enabled = False
|
|
TxtJuevesSalidaComida.Enabled = False
|
|
TxtJuevesEntradaComida.Enabled = False
|
|
TxtJuevesSalida.Enabled = False
|
|
Else
|
|
TxtJuevesEntrada.Enabled = True
|
|
TxtJuevesSalidaComida.Enabled = True
|
|
TxtJuevesEntradaComida.Enabled = True
|
|
TxtJuevesSalida.Enabled = True
|
|
End If
|
|
|
|
If ChkViernes.Checked = False Then
|
|
TxtViernesEntrada.Text = "00:00:00"
|
|
TxtViernesSalidaComida.Text = "00:00:00"
|
|
TxtViernesEntradaComida.Text = "00:00:00"
|
|
TxtViernesSalida.Text = "00:00:00"
|
|
|
|
TxtViernesEntrada.Enabled = False
|
|
TxtViernesSalidaComida.Enabled = False
|
|
TxtViernesEntradaComida.Enabled = False
|
|
TxtViernesSalida.Enabled = False
|
|
Else
|
|
TxtViernesEntrada.Enabled = True
|
|
TxtViernesSalidaComida.Enabled = True
|
|
TxtViernesEntradaComida.Enabled = True
|
|
TxtViernesSalida.Enabled = True
|
|
End If
|
|
|
|
If ChkSabado.Checked = False Then
|
|
TxtSabadoEntrada.Text = "00:00:00"
|
|
TxtSabadoSalidaComida.Text = "00:00:00"
|
|
TxtSabadoEntradaComida.Text = "00:00:00"
|
|
TxtSabadoSalida.Text = "00:00:00"
|
|
|
|
TxtSabadoEntrada.Enabled = False
|
|
TxtSabadoSalidaComida.Enabled = False
|
|
TxtSabadoEntradaComida.Enabled = False
|
|
TxtSabadoSalida.Enabled = False
|
|
Else
|
|
TxtSabadoEntrada.Enabled = True
|
|
TxtSabadoSalidaComida.Enabled = True
|
|
TxtSabadoEntradaComida.Enabled = True
|
|
TxtSabadoSalida.Enabled = True
|
|
End If
|
|
|
|
|
|
If ChkDomingo.Checked = False Then
|
|
TxtDomingoEntrada.Text = "00:00:00"
|
|
TxtDomingoSalidaComida.Text = "00:00:00"
|
|
TxtDomingoEntradaComida.Text = "00:00:00"
|
|
TxtDomingoSalida.Text = "00:00:00"
|
|
|
|
TxtDomingoEntrada.Enabled = False
|
|
TxtDomingoSalidaComida.Enabled = False
|
|
TxtDomingoEntradaComida.Enabled = False
|
|
TxtDomingoSalida.Enabled = False
|
|
Else
|
|
TxtDomingoEntrada.Enabled = True
|
|
TxtDomingoSalidaComida.Enabled = True
|
|
TxtDomingoEntradaComida.Enabled = True
|
|
TxtDomingoSalida.Enabled = True
|
|
End If
|
|
|
|
|
|
End Sub
|
|
|
|
Private Sub ChkRetardoSalidaAntes_CheckedChanged(sender As Object, e As EventArgs) Handles ChkRetardoSalidaAntes.CheckedChanged
|
|
|
|
If ChkRetardoSalidaAntes.Checked Then
|
|
TxtTolSalidaAntes.Enabled = True
|
|
rfvTxtTolSalidaAntes.Enabled = True
|
|
Else
|
|
TxtTolSalidaAntes.Enabled = False
|
|
TxtTolSalidaAntes.Text = "0"
|
|
rfvTxtTolSalidaAntes.Enabled = False
|
|
End If
|
|
UpHorarios.Update()
|
|
End Sub
|
|
End Class
|