Cambios varios

This commit is contained in:
2019-09-10 18:12:36 -07:00
12 changed files with 144 additions and 156 deletions

View File

@@ -27,7 +27,7 @@
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvChofer.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" /> <input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvChofer.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvChofer.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a> <a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvChofer.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div> </div>
<asp:GridView ID="GvChofer" runat="server" GridLines="None" data-sort="true" DataKeyNames="CveChofer,Chofer,Estatus,FechaIng,CveUsuario,CveEmpresa,Usuario,CveTransportista" CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" CellSpacing="0" Width="100%" AutoGenerateColumns="False" EmptyDataText="No se encontraron registros" ToolTip="Listado de Choferes"> <asp:GridView ID="GvChofer" runat="server" GridLines="None" data-sort="true" DataKeyNames="CveChofer,Chofer,Estatus,FechaIng,CveUsuario,CveEmpresa,Usuario,CveTransportista,Identificacion,Domicilio,Telefono,Ciudad,Licencia" CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" CellSpacing="0" Width="100%" AutoGenerateColumns="False" EmptyDataText="No se encontraron registros" ToolTip="Listado de Choferes">
<Columns> <Columns>
<asp:BoundField DataField="Chofer" HeaderText="Chofer" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField DataField="Chofer" HeaderText="Chofer" ItemStyle-HorizontalAlign="Left" />
<asp:BoundField DataField="Transportista" HeaderText="Transportista" ItemStyle-HorizontalAlign="Left" /> <asp:BoundField DataField="Transportista" HeaderText="Transportista" ItemStyle-HorizontalAlign="Left" />
@@ -69,10 +69,43 @@
<asp:RequiredFieldValidator ID="RFVChofer" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtChofer" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator> <asp:RequiredFieldValidator ID="RFVChofer" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtChofer" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>
<label for="<%= TxtChofer.ClientID.ToString()%>">Chofer:</label> <label for="<%= TxtChofer.ClientID.ToString()%>">Chofer:</label>
</div> </div>
<br />
<div class="form-group form-md-line-input input-iconright"> <div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlTransportista" DataValueField="CveTransportista" DataTextField="Transportista" runat="server" CssClass="form-control select2me" AppendDataBoundItems="true" Width="200px"></asp:DropDownList> <asp:DropDownList ID="DdlTransportista" DataValueField="CveTransportista" DataTextField="Transportista" runat="server" CssClass="form-control select2me" AppendDataBoundItems="true" Width="200px"></asp:DropDownList>
<label for="<%= DdlTransportista.ClientID.ToString()%>">Transportista:</label> <label for="<%= DdlTransportista.ClientID.ToString()%>">Transportista:</label>
</div> </div>
<br />
<div class="form-group form-md-line-input input-iconright" style="width:150px;">
<asp:TextBox ID="TxtIdentificacion" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="50"></asp:TextBox>
<%--<asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtIdentificacion" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Identificación''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
<label for="<%= TxtIdentificacion.ClientID.ToString()%>">Identificación:</label>
</div>
<br />
<div class="form-group form-md-line-input input-iconright">
<asp:TextBox ID="TxtDomicilio" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="50"></asp:TextBox>
<%--<asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtDomicilio" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Domicilio''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
<label for="<%= TxtDomicilio.ClientID.ToString()%>">Domicilio:</label>
</div>
<br />
<div class="form-group form-md-line-input input-iconright" style="width:150px;">
<asp:TextBox ID="TxtTelefono" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="10"></asp:TextBox>
<ajax:FilteredTextBoxExtender ID="FTETelefono" runat="server" TargetControlID="TxtTelefono" FilterType="Custom, Numbers" />
<%--<asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtTelefono" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Teléfono''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
<label for="<%= TxtTelefono.ClientID.ToString()%>">Teléfono:</label>
</div>
<br />
<div class="form-group form-md-line-input input-iconright" style="width:150px;">
<asp:TextBox ID="TxtCiudad" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="50"></asp:TextBox>
<%--<asp:RequiredFieldValidator ID="RequiredFieldValidator4" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtCiudad" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Ciudad''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
<label for="<%= TxtCiudad.ClientID.ToString()%>">Ciudad:</label>
</div>
<br />
<div class="form-group form-md-line-input input-iconright" style="width:150px;">
<asp:TextBox ID="TxtLicencia" runat="server" CssClass="form-control" CausesValidation="true" MaxLength="50"></asp:TextBox>
<%--<asp:RequiredFieldValidator ID="RequiredFieldValidator5" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtLicencia" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Licencia''</b> es necesario, por favor ingréselo." ValidationGroup="GrpObligatorio"></asp:RequiredFieldValidator>--%>
<label for="<%= TxtLicencia.ClientID.ToString()%>">Licencia:</label>
</div>
<br />
<div class="form-group form-md-line-input input-iconright" id="divEstatus" runat="server"> <div class="form-group form-md-line-input input-iconright" id="divEstatus" runat="server">
<asp:CheckBox ID="ChkEstatus" runat="server" CssClass="form-control" /> <asp:CheckBox ID="ChkEstatus" runat="server" CssClass="form-control" />
<label for="<%= ChkEstatus.ClientID.ToString()%>">Estatus:</label> <label for="<%= ChkEstatus.ClientID.ToString()%>">Estatus:</label>

View File

@@ -47,12 +47,12 @@ Partial Class Acarreos_CatChoferes
Dim Estatus = 0 Dim Estatus = 0
If ChkEstatus.Checked Then Estatus = 1 If ChkEstatus.Checked Then Estatus = 1
If HdnModalidad.Value = "A" Then If HdnModalidad.Value = "A" Then
If ObjAcar.AddChofer(TxtChofer.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlTransportista.SelectedValue) Then If ObjAcar.AddChofer(TxtChofer.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlTransportista.SelectedValue, TxtIdentificacion.Text.Trim, TxtDomicilio.Text.Trim, TxtTelefono.Text.Trim, TxtCiudad.Text.Trim, TxtLicencia.Text.Trim) Then
CargaDatos() CargaDatos()
Alert("Agregado Correctamente.", TipoMensaje.MsgInformacion) Alert("Agregado Correctamente.", TipoMensaje.MsgInformacion)
End If End If
ElseIf HdnModalidad.Value = "U" Then ElseIf HdnModalidad.Value = "U" Then
If ObjAcar.UpdateChofer(HdnID.Value, TxtChofer.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, Estatus, DdlTransportista.SelectedValue) Then If ObjAcar.UpdateChofer(HdnID.Value, TxtChofer.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, Estatus, DdlTransportista.SelectedValue, TxtIdentificacion.Text.Trim, TxtDomicilio.Text.Trim, TxtTelefono.Text.Trim, TxtCiudad.Text.Trim, TxtLicencia.Text.Trim) Then
CargaDatos() CargaDatos()
Alert("Actualizado Correctamente.", TipoMensaje.MsgInformacion) Alert("Actualizado Correctamente.", TipoMensaje.MsgInformacion)
End If End If
@@ -71,6 +71,11 @@ Partial Class Acarreos_CatChoferes
BtnAgregarChofer.Text = "Actualizar" BtnAgregarChofer.Text = "Actualizar"
myModalLabel.InnerText = "Actualizar Chofer" myModalLabel.InnerText = "Actualizar Chofer"
TxtChofer.Text = GvRow.DataKey("Chofer") TxtChofer.Text = GvRow.DataKey("Chofer")
TxtIdentificacion.Text = GvRow.DataKey("Identificacion")
TxtDomicilio.Text = GvRow.DataKey("Domicilio")
TxtTelefono.Text = GvRow.DataKey("Telefono")
TxtCiudad.Text = GvRow.DataKey("Ciudad")
TxtLicencia.Text = GvRow.DataKey("Licencia")
DdlTransportista.SelectedValueExist(GvRow.DataKey("CveTransportista")) DdlTransportista.SelectedValueExist(GvRow.DataKey("CveTransportista"))
divEstatus.Visible = True divEstatus.Visible = True
ChkEstatus.Checked = CBool(GvRow.DataKey("Estatus")) ChkEstatus.Checked = CBool(GvRow.DataKey("Estatus"))
@@ -84,6 +89,11 @@ Partial Class Acarreos_CatChoferes
BtnAgregarChofer.Text = "Agregar" BtnAgregarChofer.Text = "Agregar"
myModalLabel.InnerText = "Agregar Chofer" myModalLabel.InnerText = "Agregar Chofer"
TxtChofer.Text = "" TxtChofer.Text = ""
TxtIdentificacion.Text = ""
TxtDomicilio.Text = ""
TxtTelefono.Text = ""
TxtCiudad.Text = ""
TxtLicencia.Text = ""
ChkEstatus.Checked = True ChkEstatus.Checked = True
divEstatus.Visible = False divEstatus.Visible = False
UpAddChofer.Update() UpAddChofer.Update()

View File

@@ -109,7 +109,7 @@ Public Class ClsAcarreos
#Region "Choferes" #Region "Choferes"
Public Function AddChofer(Chofer As String, CveUsuario As Integer, CveEmpresa As Integer, CveTransportista As Integer) As Boolean Public Function AddChofer(Chofer As String, CveUsuario As Integer, CveEmpresa As Integer, CveTransportista As Integer, Identificacion As String, Domicilio As String, Telefono As String, Ciudad As String, Licencia As String) As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Acar_ChoferesAdd") DataAdapter("PA_Acar_ChoferesAdd")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
@@ -117,6 +117,11 @@ Public Class ClsAcarreos
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario .Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveTransportista", SqlDbType.Int).Value = CveTransportista .Add("@CveTransportista", SqlDbType.Int).Value = CveTransportista
.Add("@Identificacion", SqlDbType.VarChar).Value = Identificacion
.Add("@Domicilio", SqlDbType.VarChar).Value = Domicilio
.Add("@Telefono", SqlDbType.VarChar).Value = Telefono
.Add("@Ciudad", SqlDbType.VarChar).Value = Ciudad
.Add("@Licencia", SqlDbType.VarChar).Value = Licencia
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)
@@ -128,7 +133,7 @@ Public Class ClsAcarreos
Return Retorno Return Retorno
End Function End Function
Public Function UpdateChofer(CveChofer As Integer, Chofer As String, CveUsuario As Integer, CveEmpresa As Integer, Estatus As Integer, CveTransportista As Integer) As Boolean Public Function UpdateChofer(CveChofer As Integer, Chofer As String, CveUsuario As Integer, CveEmpresa As Integer, Estatus As Integer, CveTransportista As Integer, Identificacion As String, Domicilio As String, Telefono As String, Ciudad As String, Licencia As String) As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_Acar_ChoferesUpdate") DataAdapter("PA_Acar_ChoferesUpdate")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
@@ -138,7 +143,11 @@ Public Class ClsAcarreos
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa .Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@Estatus", SqlDbType.Int).Value = Estatus .Add("@Estatus", SqlDbType.Int).Value = Estatus
.Add("@CveTransportista", SqlDbType.Int).Value = CveTransportista .Add("@CveTransportista", SqlDbType.Int).Value = CveTransportista
.Add("@Identificacion", SqlDbType.VarChar).Value = Identificacion
.Add("@Domicilio", SqlDbType.VarChar).Value = Domicilio
.Add("@Telefono", SqlDbType.VarChar).Value = Telefono
.Add("@Ciudad", SqlDbType.VarChar).Value = Ciudad
.Add("@Licencia", SqlDbType.VarChar).Value = Licencia
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)

View File

@@ -1574,16 +1574,16 @@ Public Class ClsOS
Return Retorno Return Retorno
End Function End Function
Public Function RemoveEstatusUsuarios(CveEstatusUsuarios As Integer) As Boolean Public Function RemoveEstatusUsuarios(CveEstatus As Integer, CveUsuario As Integer) As Boolean
Dim Retorno As Boolean = False Dim Retorno As Boolean = False
DataAdapter("PA_OS_EstatusUsuariosRemove") DataAdapter("PA_OS_EstatusUsuariosRemove")
With SqlAdapter.SelectCommand.Parameters With SqlAdapter.SelectCommand.Parameters
SqlAdapter.SelectCommand.Parameters.Add("@CveEstatusUsuario", SqlDbType.Int).Value = CveEstatusUsuarios .Add("@CveEstatusOrdenServicio", SqlDbType.Int).Value = CveEstatus
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
End With End With
Try Try
SqlAdapter.Fill(Data) SqlAdapter.Fill(Data)
Retorno = True Retorno = True

View File

@@ -7951,7 +7951,7 @@ Partial Class Compras_Compras
ImporteMovimiento = 0 ImporteMovimiento = 0
IdCtaContable = 0 IdCtaContable = 0
CveCuenta = 0 CveCuenta = 0
Dim Concepto As String = "" Dim Concepto As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
Dim importeMN As Decimal = 0 Dim importeMN As Decimal = 0
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1) Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
Dim PorcentajeImpuesto As Decimal = 0 Dim PorcentajeImpuesto As Decimal = 0
@@ -13440,7 +13440,7 @@ Partial Class Compras_Compras
Protected Sub BtnRefacturacionVer_Click(sender As Object, e As EventArgs) Handles BtnRefacturacionVer.Click Protected Sub BtnRefacturacionVer_Click(sender As Object, e As EventArgs) Handles BtnRefacturacionVer.Click
Dim Opcion As Integer = 1 Dim Opcion As Integer = 1
If UsuarioActual.CveEmpresa = 119 Then Opcion = 2 If UsuarioActual.CveEmpresa.Contiene(119, 72) Then Opcion = 2
Dim ObjCompras As New ClsCompras Dim ObjCompras As New ClsCompras
@@ -14553,7 +14553,7 @@ Partial Class Compras_Compras
End If End If
End If End If
If Math.Abs(HdnIEPSModificadoOC.Value.ToDecimal - LbIEPSOC2.Text.ToDecimal) > 0.05 Then If Math.Abs(HdnIEPSModificadoOC.Value.ToDecimal - LbIEPSOC2.Text.ToDecimal) > 0.05 AndAlso UsuarioActual.CveEmpresa.Contiene(119) Then
Alert($"Hay una diferencia de IEPS entre la factura y la OC. Dif: {HdnIEPSModificadoOC.Value.ToDecimal - LbIEPSOC2.Text.ToDecimal}", TipoMensaje.MsgAdvertencia) Alert($"Hay una diferencia de IEPS entre la factura y la OC. Dif: {HdnIEPSModificadoOC.Value.ToDecimal - LbIEPSOC2.Text.ToDecimal}", TipoMensaje.MsgAdvertencia)
Exit Sub Exit Sub
End If End If

View File

@@ -2111,7 +2111,17 @@ Partial Class Inventarios_RecepcionAlmacen
'ENTREGA DIRECTA 'ENTREGA DIRECTA
If EntregaDirecta Then If EntregaDirecta Then
If Not ErrorMovInv Then If Not ErrorMovInv Then
CveMovtoSalidaDirecta = ObjInventario.AddMovimiento(DdlAlmacen.SelectedValue.ToEntero, 3, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, TipoCambio:=If(DdlMonedaTC.SelectedValue.ToEntero = 1, -1, TipoCambio), MovimientoFijo:=True, CveMovimientoRelacionado:=CveMovimiento, Remision:=TxtRemision.Text, CveVendedor:=CveVendedor, CveCliente:=CveCliente) Dim CveVenta As Integer = 0
Dim Dt As DataTable
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then
If ObjInventario.DtResultados.Rows.Count > 0 Then
Dt = ObjInventario.DtResultados
CveVenta = ObjInventario.DtResultados.Rows(0)("CveVenta").ToString.ToEntero
End If
End If
CveMovtoSalidaDirecta = ObjInventario.AddMovimiento(DdlAlmacen.SelectedValue.ToEntero, 3, 1, TxtFecha.Text.ToDate, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, CveVenta, -1, -1, Observaciones:=TxtObservaciones.Text.Trim, TipoCambio:=If(DdlMonedaTC.SelectedValue.ToEntero = 1, -1, TipoCambio), MovimientoFijo:=True, CveMovimientoRelacionado:=CveMovimiento, Remision:=TxtRemision.Text, CveVendedor:=CveVendedor, CveCliente:=CveCliente)
FolioSalidaDirecta = ObjInventario.Folio FolioSalidaDirecta = ObjInventario.Folio
If Not CveMovtoSalidaDirecta > 0 Then If Not CveMovtoSalidaDirecta > 0 Then
@@ -2119,14 +2129,12 @@ Partial Class Inventarios_RecepcionAlmacen
End If End If
If Not ErrorMovInv Then If Not ErrorMovInv Then
If ObjInventario.GetMovimientosDetalle(CveMovimiento, UsuarioActual.CveEmpresa) Then For Each Dr As DataRow In Dt.Rows
For Each Dr As DataRow In ObjInventario.DtResultados.Rows If Not ObjInventario.AddMovimientoDetalle(CveMovtoSalidaDirecta, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDouble, Dr("CveAF").ToString.ToEntero, Dr("CveSeccionAlmacen").ToString.ToEntero, Dr("SerieLote").ToString, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, CveMovimientoDetalleEntrada:=Dr("CveMovimientoDetalle").ToString.ToEntero, CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero, CveUsuarioModifico:=UsuarioActual.CveUsuario) Then
If Not ObjInventario.AddMovimientoDetalle(CveMovtoSalidaDirecta, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDouble, Dr("CveAF").ToString.ToEntero, Dr("CveSeccionAlmacen").ToString.ToEntero, Dr("SerieLote").ToString, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, CveMovimientoDetalleEntrada:=Dr("CveMovimientoDetalle").ToString.ToEntero, CveVentaDetalle:=Dr("CveVentaDetalle").ToString.ToEntero, CveUsuarioModifico:=UsuarioActual.CveUsuario) Then ErrorMovInv = True
ErrorMovInv = True Exit For
Exit For End If
End If Next
Next
End If
End If End If
If Not ErrorMovInv Then If Not ErrorMovInv Then

View File

@@ -172,14 +172,14 @@
<div class="col-md-2"> <div class="col-md-2">
<asp:TextBox runat="server" Text="" ID="TxtGastoIndirecto" Width="100px" /> <asp:TextBox runat="server" Text="" ID="TxtGastoIndirecto" Width="100px" />
</div> </div>
<label class="col-md-1">Chofer:</label>
<div class="col-md-2">
<asp:DropDownList ID="DldChofer" runat="server" DataTextField="Chofer" DataValueField="CveChofer" CssClass="form-control input-sm select2me" Style="width: 150px !important;"></asp:DropDownList>
</div>
<label class="col-md-1">Placa:</label> <label class="col-md-1">Placa:</label>
<div class="col-md-2"> <div class="col-md-2">
<asp:TextBox runat="server" Text="" ID="TxtPlaca" Width="100px" /> <asp:TextBox runat="server" Text="" ID="TxtPlaca" Width="100px" />
</div> </div>
<label class="col-md-1">Chofer:</label>
<div class="col-md-2">
<asp:DropDownList ID="DldChofer" runat="server" DataTextField="Chofer" DataValueField="CveChofer" OnSelectedIndexChanged="DldChofer_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm select2me" Style="width: 150px !important;"></asp:DropDownList>
</div>
</div> </div>
<div class="row"> <div class="row">
<label class="col-md-2">Fecha Entrega:</label> <label class="col-md-2">Fecha Entrega:</label>
@@ -256,7 +256,8 @@
<div class="row"> <div class="row">
<label class="col-md-5">Teléfono:</label> <label class="col-md-5">Teléfono:</label>
<div class="col-md-4"> <div class="col-md-4">
<asp:TextBox runat="server" Text="" ID="TxtTelefono" Width="150px" /> <asp:TextBox runat="server" Text="" ID="TxtTelefono" Width="150px" MaxLength="10" />
<ajax:FilteredTextBoxExtender ID="FTETelefono" runat="server" TargetControlID="TxtTelefono" FilterType="Custom, Numbers" />
</div> </div>
</div> </div>
<div class="row"> <div class="row">

View File

@@ -377,7 +377,7 @@ Partial Class Inventarios_TraspasoAlmacen
'Llena Choferes 'Llena Choferes
Dim ObjAcar As New ClsAcarreos() Dim ObjAcar As New ClsAcarreos()
If ObjAcar.GetChofer(-1, UsuarioActual.CveEmpresa, -1, -1) Then If ObjAcar.GetChofer(-1, UsuarioActual.CveEmpresa, 1, -1) Then
DldChofer.DataSource = ObjAcar.DtResultados DldChofer.DataSource = ObjAcar.DtResultados
DldChofer.DataBind() DldChofer.DataBind()
End If End If
@@ -2408,5 +2408,19 @@ Partial Class Inventarios_TraspasoAlmacen
#End Region #End Region
Protected Sub DldChofer_SelectedIndexChanged(sender As Object, e As EventArgs)
Dim ObjAcar As New ClsAcarreos()
If ObjAcar.GetChofer(DldChofer.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, 1, -1) Then
Dim dr As DataRow = ObjAcar.DtResultados.Rows(0)
If dr IsNot Nothing Then
TxtIdentificacion.Text = dr("Identificacion").ToString
TxtDomicilio.Text = dr("Domicilio").ToString
TxtTelefono.Text = dr("Telefono").ToString
TxtCiudad.Text = dr("Ciudad").ToString
TxtLicencia.Text = dr("Licencia").ToString
End If
End If
ObjAcar.Dispose()
End Sub
End Class End Class

View File

@@ -4,4 +4,4 @@
28/08/2019:05:48 p. m. No se especifico a remitente - SIG - Se Genero una Recepción de Usados con el folio: 80 28/08/2019:05:48 p. m. No se especifico a remitente - SIG - Se Genero una Recepción de Usados con el folio: 80
02/09/2019:11:00 a. m. From:'signotificaciones@adssistemas.mx' - Para:'x@x.com' - Asunto:'Entrega de Factura SUCURSAL NARANJO SN-22' - CCP: '' - Adjuntos: 1 02/09/2019:11:00 a. m. From:'signotificaciones@adssistemas.mx' - Para:'x@x.com' - Asunto:'Entrega de Factura SUCURSAL NARANJO SN-22' - CCP: '' - Adjuntos: 1

View File

@@ -119,7 +119,7 @@
<asp:UpdatePanel ID="UPPEmp" runat="server" UpdateMode="Conditional"> <asp:UpdatePanel ID="UPPEmp" runat="server" UpdateMode="Conditional">
<ContentTemplate> <ContentTemplate>
<asp:GridView ID="GvEstatusUsuariosREQ" GridLines="None" CssClass="table table-striped table-advance table-hover" Width="100%" runat="server" AutoGenerateColumns="False" DataKeyNames="CveUsuario" EmptyDataText="No se encontraron Usuarios Registrados" ToolTip="Listado de Usuarios"> <asp:GridView ID="GvEstatusUsuarios" GridLines="None" CssClass="table table-striped table-advance table-hover" Width="100%" runat="server" AutoGenerateColumns="False" DataKeyNames="CveUsuario" EmptyDataText="No se encontraron Usuarios Registrados" ToolTip="Listado de Usuarios">
<HeaderStyle VerticalAlign="Middle" /> <HeaderStyle VerticalAlign="Middle" />
<Columns> <Columns>
<asp:TemplateField> <asp:TemplateField>
@@ -302,70 +302,6 @@
</ContentTemplate> </ContentTemplate>
</asp:UpdatePanel> </asp:UpdatePanel>
<asp:UpdatePanel runat="server" ID="UPSuperior" UpdateMode="Conditional">
<ContentTemplate>
<asp:HiddenField runat="server" ID="IDhdnCveEstatusUsuarios" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="IDCellYellow" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="IDimg" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="hdnCveEstatusUsuarios" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="hdnCveSuperior" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="hdnCveEstatusSiguiente" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="HiddenField1" ClientIDMode="Static" />
<asp:HiddenField runat="server" ID="hdnCveUsuario" ClientIDMode="Static" />
<div id="DivSuperior" style="width: 200px; background-color: White; border: solid 1px black; color: Black; display: none; position: absolute;">
<table border="0" style="width: 200px" cellpadding="0" cellspacing="0">
<tr class="Titulos">
<td style="width: 400px">Opciones&nbsp;</td>
<td style="padding-right: 4px; padding-top: 4px" valign="top">
<img alt="" src="/Imagenes/close.gif" style="cursor: pointer;" onclick="$('#DivSuperior').hide(1000);" /></td>
</tr>
<tr align="center">
<td colspan="2">
<table style="height: 80px; width: 100%">
<tr>
<td style="vertical-align: top; text-align: left; width: 100%">
<asp:CheckBox ID="chkMostrarLimites" Font-Bold="true" Style="display: none" ClientIDMode="Static" Text="Usar Limites" runat="server" /><br />
<div id="DivLimites" style="display: none;">
<table>
<tr>
<td>Inferior</td>
<td>
<asp:TextBox ID="txtLimiteInferior" Width="80px" runat="server" ClientIDMode="Static"></asp:TextBox></td>
</tr>
<tr>
<td>Superior</td>
<td>
<asp:TextBox ID="txtLimiteSuperior" Width="80px" runat="server" ClientIDMode="Static"></asp:TextBox></td>
</tr>
</table>
</div>
<table style="text-align: center" runat="server" id="tblSuperior">
<tr>
<td style="font-weight: bold">Superior</td>
</tr>
<tr>
<td>
<asp:DropDownList ID="ddlSuperior" Width="170px" ClientIDMode="Static" runat="server" DataValueField="CveUsuario" DataTextField="Nombre"></asp:DropDownList></td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr style="height: 25px">
<td align="center" colspan="2">
<asp:Button ID="BtnGuardarSuperior" runat="server" ClientIDMode="Static" OnClientClick="$('#DivSuperior').hide(1000);" Text="Guardar" />
<input id="BtnCancelarObs" type="button" value="Cancelar" onclick="$('#DivSuperior').hide(1000);" />
</td>
</tr>
</table>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</ContentTemplate> </ContentTemplate>
</ajax:TabPanel> </ajax:TabPanel>
</ajax:TabContainer> </ajax:TabContainer>

View File

@@ -30,7 +30,7 @@ Partial Class OS_CatEstatusOrdenServicio
Get Get
Return CType(ViewState("DTEstatusUsuarios"), DataTable) Return CType(ViewState("DTEstatusUsuarios"), DataTable)
End Get End Get
Set(value As DataTable) Set(value As Data.DataTable)
ViewState("DTEstatusUsuarios") = value ViewState("DTEstatusUsuarios") = value
End Set End Set
End Property End Property
@@ -39,17 +39,12 @@ Partial Class OS_CatEstatusOrdenServicio
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not Page.IsPostBack Then If Not Page.IsPostBack Then
CargaDatos()
CreaGrid("Req") CreaGrid("Req")
CreaGrid("OC")
CargaGridEstatusUsuarios() CargaGridEstatusUsuarios()
ViewState("Orden") = "" ViewState("Orden") = ""
'ViewState("TipoSeleccionado") = DdlTipo.SelectedValue
CveEstatuOS = -1 CveEstatuOS = -1
CargaDatos()
'CargaProyectos()
CargaUsuarios()
End If End If
End Sub End Sub
@@ -66,6 +61,12 @@ Partial Class OS_CatEstatusOrdenServicio
Else Else
Me.GvDatos.DataSource = Nothing Me.GvDatos.DataSource = Nothing
End If End If
If ObjEstatusOrdenServicios.GetEstatusUsuarios(-1, -1) Then
DTEstatusUsuarios = ObjEstatusOrdenServicios.DtResultados
Dim PermisosDeUsuario As DataTable = DTEstatusUsuarios
End If
OrdenaDatos() OrdenaDatos()
ObjEstatusOrdenServicios.Dispose() ObjEstatusOrdenServicios.Dispose()
GvDatos.DataBind() GvDatos.DataBind()
@@ -148,16 +149,8 @@ Partial Class OS_CatEstatusOrdenServicio
Dim Estado As Boolean = GvDatos.Rows(e.RowIndex).FCCheckBox("ChkEstado").Checked Dim Estado As Boolean = GvDatos.Rows(e.RowIndex).FCCheckBox("ChkEstado").Checked
Dim CveEstatusOrdenServicio As Integer = GvDatos.DataKeys(e.RowIndex).Value.ToString.ToEntero Dim CveEstatusOrdenServicio As Integer = GvDatos.DataKeys(e.RowIndex).Value.ToString.ToEntero
'If ObjEstatusOrdenServicios.UpdateEstatusOrdenServicio(EstatusOrdenServicio, Estado, CveEstatusOrdenServicio) Then
' GvDatos.EditIndex = -1
' ViewState("DTEstatusOrdenServicios") = ObjEstatusOrdenServicios.DtResultados '.FiltraParametros("CveEmpresa = " & UsuarioActual.CveEmpresa)
' GlobalDTEstatusOrdenServicios = ObjEstatusOrdenServicios.DtResultados
' Alert("Los cambios se guardaron correctamente.", TipoMensaje.MsgInformacion)
'End If
ObjEstatusOrdenServicios.Dispose() ObjEstatusOrdenServicios.Dispose()
End Sub End Sub
#End Region #End Region
@@ -173,85 +166,50 @@ Partial Class OS_CatEstatusOrdenServicio
#End Region #End Region
#Region "Configuracion" #Region "Configuracion"
Protected Sub ibOpciones1_Click(sender As Object, e As ImageClickEventArgs)
Dim imgBtn As ImageButton = DirectCast(sender, System.Web.UI.WebControls.ImageButton)
ddlSuperior.Items.Clear()
If imgBtn.CommandArgument <> "" Then
'chkMostrarLimites.Visible = If(GlobalDTOCEstatus.FiltraParametros("CveEstatusSiguiente = " + imgBtn.CommandArgument)(0)("TipoTermino").ToString.ToEntero = 3, False, True)
chkMostrarLimites.Style("display") = If(GlobalDTOCEstatus(UsuarioActual.CveEmpresa).FiltraParametros("CveEstatusSiguiente = " + imgBtn.CommandArgument)(0)("TipoTermino").ToString.ToEntero = 3, "none", "inline")
'ddlSuperior.DataSource = DTEstatusUsuarios.FiltraParametros(String.Format("CveEstatus = {0}", imgBtn.CommandArgument), "Nombre DESC")
ddlSuperior.DataBind()
ddlSuperior.Items.Insert(0, New ListItem("Todos los Superiores", "-1"))
Try
ddlSuperior.SelectedValue = hdnCveSuperior.Value
Catch ex As Exception
End Try
tblSuperior.Visible = True
Else
tblSuperior.Visible = False
End If
UPSuperior.Update()
UPPEmp.Update()
RegistraScript("$('#DivSuperior').show(1000); PosicionaObjeto('" + imgBtn.ClientID + "','DivSuperior'); chkMostrarLimitesCambio();")
End Sub
Private Sub CreaGrid(Tipo As String) Private Sub CreaGrid(Tipo As String)
Dim i As Integer = 1 Dim i As Integer = 1
For Each Row As DataRow In GlobalDTEstatusOrdenServicios(UsuarioActual.CveEmpresa).Rows For Each Row As DataRow In GlobalDTEstatusOrdenServicios(UsuarioActual.CveEmpresa).Rows
GvEstatusUsuariosREQ.Columns(i).HeaderText = Row("EstatusOrdenServicio").ToString.ToUpper GvEstatusUsuarios.Columns(i).HeaderText = Row("EstatusOrdenServicio").ToString.ToUpper
GvEstatusUsuariosREQ.Columns(i).FooterText = Row("CveEstatusOrdenServicio").ToString GvEstatusUsuarios.Columns(i).FooterText = Row("CveEstatusOrdenServicio").ToString
i += 1 i += 1
Next Next
While i <= 10 While i <= 10
GvEstatusUsuariosREQ.Columns(i).Visible = False GvEstatusUsuarios.Columns(i).Visible = False
i += 1 i += 1
End While End While
End Sub End Sub
Protected Sub CargaGridEstatusUsuarios() Protected Sub CargaGridEstatusUsuarios()
GvEstatusUsuariosREQ.DataSource = GlobalDTUsuarios(CveEmpresa:=UsuarioActual.CveEmpresa) GvEstatusUsuarios.DataSource = GlobalDTUsuarios(CveEmpresa:=UsuarioActual.CveEmpresa)
GvEstatusUsuariosREQ.DataBind() GvEstatusUsuarios.DataBind()
UPPEmp.Update() UPPEmp.Update()
End Sub End Sub
Public Sub CargaUsuarios()
ddlSuperior.DataSource = GlobalDTUsuarios(-1, UsuarioActual.CveEmpresa)
ddlSuperior.DataBind()
End Sub
Protected Sub btnGuardarEstatusUsuariosREQ_Click(sender As Object, e As EventArgs) Handles btnGuardarEstatusUsuariosREQ.Click Protected Sub btnGuardarEstatusUsuariosREQ_Click(sender As Object, e As EventArgs) Handles btnGuardarEstatusUsuariosREQ.Click
Dim objEstatusOC As New ClsOS Dim objEstatusOC As New ClsOS
objEstatusOC.IniciaTransacSQL() objEstatusOC.IniciaTransacSQL()
Dim HuboErrores As Boolean = False Dim HuboErrores As Boolean = False
Dim CveSubProyecto = 59 Dim CveSubProyecto = 59
For Each Row As GridViewRow In GvEstatusUsuarios.Rows
For Each Row As GridViewRow In GvEstatusUsuariosREQ.Rows
Dim aux As String = Row.DataKey("CveUsuario").ToString
Dim r As Integer = 1 Dim r As Integer = 1
For i = 0 To Row.Cells.Count - 1 For i = 0 To Row.Cells.Count - 1
Dim CveEstatus As Integer = If(IsNumeric(GvEstatusUsuariosREQ.Columns(i).FooterText), GvEstatusUsuariosREQ.Columns(i).FooterText.ToEntero, 0) Dim CveEstatus As Integer = If(IsNumeric(GvEstatusUsuarios.Columns(i).FooterText), GvEstatusUsuarios.Columns(i).FooterText.ToEntero, 0)
If CveEstatus > 0 Then If CveEstatus > 0 Then
If Row.FCCheckBox("chkEstatus" + r.ToString).Checked = False And Row.FCHiddenField("hdnCveEstatusUsuarios" + r.ToString).Value.ToEntero > 0 Then If Row.FCCheckBox("chkEstatus" + r.ToString).Checked = False Then
'Eliminar el registro existente 'Eliminar el registro existente
If Not objEstatusOC.RemoveEstatusUsuarios(Row.FCHiddenField("hdnCveEstatusUsuarios" + r.ToString).Value.ToEntero) Then If Not objEstatusOC.RemoveEstatusUsuarios(CveEstatus, Row.DataKey("CveUsuario").ToString.ToEntero) Then
HuboErrores = True HuboErrores = True
Exit For Exit For
End If End If
ElseIf Row.FCCheckBox("chkEstatus" + r.ToString).Checked = True Then ElseIf Row.FCCheckBox("chkEstatus" + r.ToString).Checked = True Then
'And Row.FCHiddenField("hdnCveEstatusUsuarios" + r.ToString).Value.ToEntero = -1
'Guardado masivo cuando sea SubProyecto "Todos" 'Guardado masivo cuando sea SubProyecto "Todos"
If CveSubProyecto = -2 Then If CveSubProyecto = -2 Then
For Each dr As DataRow In GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa).Rows For Each dr As DataRow In GlobalDTSubProyectos(-1, -1, UsuarioActual.CveEmpresa).Rows
@@ -292,7 +250,25 @@ Partial Class OS_CatEstatusOrdenServicio
End If End If
objEstatusOC.Dispose() objEstatusOC.Dispose()
CargaDatos()
CargaGridEstatusUsuarios() CargaGridEstatusUsuarios()
End Sub End Sub
Protected Sub GvEstatusUsuarios_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvEstatusUsuarios.RowDataBound
If e.Row.RowType = DataControlRowType.DataRow Then
Dim PermisosDeUsuario As DataTable = DTEstatusUsuarios.FiltraParametros(String.Format("CveUsuario = {0}", e.Row.DBCampo("CveUsuario").ToString))
Dim CveUsuario As String = e.Row.DBCampo("CveUsuario").ToString
For i As Integer = 1 To 10
Dim CveEstatus As Integer = GvEstatusUsuarios.Columns(i).FooterText.ToEntero
If CveEstatus > 0 Then
Dim auxiliarBandera As DataRow = PermisosDeUsuario.FiltroPrimero(String.Format("CveEstatusOrdenServicio = {0}", CveEstatus.ToString))
If auxiliarBandera IsNot Nothing Then
Dim chkEstatus As CheckBox = e.Row.FCCheckBox(String.Format("chkEstatus{0}", i))
chkEstatus.Checked = True
End If
End If
Next
End If
End Sub
#End Region #End Region
End Class End Class

View File

@@ -9370,8 +9370,8 @@ Partial Class Ventas
Importe91 = Dr("Importe").ToString.ToDecimal Importe91 = Dr("Importe").ToString.ToDecimal
ImporteMN91 = Dr("Importe").ToString.ToDecimal * TipoCambioNC ImporteMN91 = Dr("Importe").ToString.ToDecimal * TipoCambioNC
ElseIf DdlMoneda.SelectedValue.ToEntero = 1 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then ElseIf DdlMoneda.SelectedValue.ToEntero = 1 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then
Importe251 = Dr("Importe").ToString.ToDecimal
Importe91 = Dr("Importe").ToString.ToDecimal Importe91 = Dr("Importe").ToString.ToDecimal / TipoCambioNC
ImporteMN91 = Dr("Importe").ToString.ToDecimal ImporteMN91 = Dr("Importe").ToString.ToDecimal
End If End If
@@ -9385,7 +9385,8 @@ Partial Class Ventas
ElseIf DdlMoneda.SelectedValue.ToEntero = 2 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then ElseIf DdlMoneda.SelectedValue.ToEntero = 2 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then
ImporteMN251 = Dr("Importe").ToString.ToDecimal * TCFluctuacion ImporteMN251 = Dr("Importe").ToString.ToDecimal * TCFluctuacion
ElseIf DdlMoneda.SelectedValue.ToEntero = 1 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then ElseIf DdlMoneda.SelectedValue.ToEntero = 1 AndAlso Dr("TCCambioValuacion").ToString.ToDecimal > 1 Then
ImporteMN251 = Dr("Importe").ToString.ToDecimal / TipoCambioNC Importe251 = Dr("Importe").ToString.ToDecimal / TCFluctuacion
ImporteMN251 = Dr("Importe").ToString.ToDecimal
Else Else
ImporteMN251 = Dr("Importe").ToString.ToDecimal ImporteMN251 = Dr("Importe").ToString.ToDecimal
End If End If
@@ -19934,7 +19935,7 @@ Partial Class Ventas
Private Sub CargaCxC() Private Sub CargaCxC()
Dim ObjMovtos As New ClsMovimientos() Dim ObjMovtos As New ClsMovimientos()
If ObjMovtos.GetCxCClienteDetalle(ViewState("CveCliente").ToString.ToEntero, "-1", "-1", DdlMoneda.SelectedValue.ToEntero, -1, UsuarioActual.CveEmpresa, DdlSucursalCliente.SelectedValue.ToEntero) Then If ObjMovtos.GetCxCClienteDetalle(ViewState("CveCliente").ToString.ToEntero, "-1", "-1", -1, -1, UsuarioActual.CveEmpresa, DdlSucursalCliente.SelectedValue.ToEntero) Then
Dim DtTemporal As DataTable = ObjMovtos.DtResultados.FiltraParametros("Tipo = 'Act' AND CveVenta > 0", "Moneda, OrdenVencimiento, FechaVencimiento") Dim DtTemporal As DataTable = ObjMovtos.DtResultados.FiltraParametros("Tipo = 'Act' AND CveVenta > 0", "Moneda, OrdenVencimiento, FechaVencimiento")
GvCxC.DataSource = DtTemporal GvCxC.DataSource = DtTemporal
End If End If