This commit is contained in:
2023-12-19 18:31:13 -07:00
7 changed files with 63 additions and 26 deletions

View File

@@ -160,6 +160,7 @@ Public Class ClsClientes
Public Property CodigoRegimenFiscal As String
Public Property RegimenFiscal As String
Public Property RepresentanteLegal As String
Public Property CveAlmacenAsignado As Integer
Public Property UsaProductoAlterno As Boolean = False
Public Property CveAlmacenAsignado As Integer = -1
@@ -408,6 +409,7 @@ Public Class ClsClientes
_RegimenFiscal = Data(0)("RegimenFiscal").ToString
_CodigoRegimenFiscal = Data(0)("CodigoRegimenFiscal").ToString
_RepresentanteLegal = Data(0)("RepresentanteLegal").ToString
_CveAlmacenAsignado = Data(0)("CveAlmacenAsignado").ToString.ToEntero
_UsaProductoAlterno = CBool(Data(0)("UsaProductoAlterno"))
Me.CveAlmacenAsignado = Data(0)("CveAlmacenAsignado").ToString.ToEntero

View File

@@ -6472,7 +6472,7 @@ Public Class ClsVentas
SqlAdapter.Fill(Data)
Retorno = True
Catch ex As Exception
OnError("Ocurrió un error al obtener el reporte de ultilidades.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
OnError("Ocurrió un error al obtener el reporte de utilidades.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
End Try
Return Retorno

View File

@@ -2483,6 +2483,8 @@ Partial Class Inventarios_EntradasSalidas
divSerie.Visible = False
divLote.Visible = False
divSeccionAlmacen.Visible = False
divCaducidad.Visible = False
EscondeColumnasGVM(DtMovimientos.FiltraParametros("Estatus <> 'E' "))
@@ -5410,8 +5412,9 @@ Partial Class Inventarios_EntradasSalidas
If ObjInventario.GetMovimientosDetalle(CveMovimientoVirtual, UsuarioActual.CveEmpresa) Then
dttCosto = ObjInventario.DtResultados
End If
If ContabilizaMovimientoAlmacen(ObjConta, TxtFecha.Text.Replace(",", "").ToDate, "Virtual", "ES/GV", CveMovimientoVirtual, -1, DtPSVirtual.SUM("TotalCargo"), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, True, dttCosto, tCveSubProyecto) > 0 Then
Dim tCveMovtoEntrada As Integer = If(tOrigen > 0, CveMovimientoVirtual, -1)
Dim tCveMovtoSalida As Integer = If(tOrigen > 0, -1, CveMovimientoVirtual)
If ContabilizaMovimientoAlmacen(ObjConta, TxtFecha.Text.Replace(",", "").ToDate, "Virtual", "ES/GV", tCveMovtoSalida, tCveMovtoEntrada, DtPSVirtual.SUM("TotalCargo"), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, True, dttCosto, tCveSubProyecto) > 0 Then
ErrorMovInv = True
End If
End If

View File

@@ -18,6 +18,8 @@
<asp:UpdatePanel ID="UPFiltros" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:Panel ID="Pnl" runat="server" DefaultButton="BtnBuscar">
<table style="width: 750px;">
<tr>
<td class="Titulos" colspan="4">Filtros para búsqueda</td>
@@ -99,6 +101,7 @@
<td></td>
</tr>
</table>
</asp:Panel>
</ContentTemplate>
</asp:UpdatePanel>
@@ -121,11 +124,12 @@
</div>
<div class="row" style="max-width: 780px;">
<div class="col-md-12" style="display: flex; justify-content: flex-end">
<table>
<tr>
<td class="text-right" style="text-align: right;">Lista de precio: </td>
<td class="text-right" style="text-align: right;" runat="server" id="DivListasPrecios2" visible="false">Lista: </td>
<td id="DivListasPrecios" visible="false" runat="server">
<asp:DropDownList runat="server" ID="DdlPrecioLista" CssClass="form-control input-sm select2me" Width="150px" DataTextField="PrecioLista" DataValueField="CvePrecioLista" AutoPostBack="true" OnSelectedIndexChanged="DdlPrecioLista_SelectedIndexChanged"></asp:DropDownList>
<asp:DropDownList runat="server" ID="DdlPrecioLista" CssClass="form-control input-sm select2me" Width="125px" DataTextField="PrecioLista" DataValueField="CvePrecioLista" AutoPostBack="true" OnSelectedIndexChanged="DdlPrecioLista_SelectedIndexChanged"></asp:DropDownList>
</td>
<td style="text-align: right;">
<asp:Literal ID="LtPrecioPS" Text="" runat="server" Visible="false" />

View File

@@ -50,6 +50,7 @@ Partial Class Inventarios_Default
LtPrecioPS.Visible = True
DivListasPrecios.Visible = True
DivListasPreciosRow2.Visible = True
DivListasPrecios2.Visible = True
End If
If UsuarioActual.CveRol = 1 Then
@@ -182,7 +183,7 @@ Partial Class Inventarios_Default
If CvePrecioLista = -1 Then CvePrecioLista = ObjVta.DtResultados.Rows(0)("CvePrecioLista").ToString.ToEntero
If objPS.GetPSPreciosLista(UsuarioActual.CveEmpresa, CvePrecioLista, -1, DDlPS.SelectedValue.ToEntero) Then
If objPS.DtResultados.Rows.Count > 0 Then
LtPrecioPS.Text = $"Precio de venta: <b>$: {objPS.DtResultados.Rows(0)("PrecioLista").ToString.FormatoNumero} {dr("Abreviatura").ToString}</b>"
LtPrecioPS.Text = $"Precio: <b>$: {objPS.DtResultados.Rows(0)("PrecioLista").ToString.FormatoNumero} {dr("Abreviatura").ToString}</b>"
End If
End If
End If

View File

@@ -584,13 +584,13 @@
<b>Requiere Técnico:</b>
</td>
<td runat="server" id="TdRequiereTecnico2" visible="false">
<asp:CheckBox ID="ChkRequiereTecnico" runat="server" data-size="small" CssClass="make-switchsd" OnCheckedChanged="ChkRequiereTecnico_CheckedChanged" AutoPostBack="true" />
<asp:CheckBox ID="ChkRequiereTecnico" runat="server" CssClass="chksino" OnCheckedChanged="ChkRequiereTecnico_CheckedChanged" AutoPostBack="true" Text="Requiere Técnico:" />
</td>
<td runat="server" id="TdFechaOS1" visible ="false">
<b>Fecha de Cirugia:</b>
</td>
<td runat="server" id="TdFechaOS2" visible ="false">
<asp:TextBox ID="TxtFechaOS" type="datetime-local" runat="server" data-size="small" CssClass="make-switchsd" CausesValidation="true" Style="width: 130px" step="1"></asp:TextBox>
<asp:TextBox ID="TxtFechaOS" type="datetime-local" runat="server" CssClass="make-switchsd" CausesValidation="true" Style="width: 130px" step="1"></asp:TextBox>
</td>
</tr>
@@ -4361,7 +4361,7 @@
Concepto:
</div>
<div class="col-md-8">
<asp:DropDownList ID="DdlNCPSAnt" runat="server" AppendDataBoundItems="true" DataTextField="PSCodigo" DataValueField="CvePS" Width="250px" CssClass="select2me"></asp:DropDownList>
<asp:DropDownList ID="DdlNCPSAnt" runat="server" DataTextField="PSCodigo" DataValueField="CvePS" Width="250px" CssClass="select2me"></asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVNCPSAnt" runat="server" InitialValue="-1" ControlToValidate="DdlNCPSAnt" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Concepto''</b> es necesario, por favor ingréselo." ValidationGroup="VGAnticiposClientes"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCERFVNCPSAnt" runat="server" HighlightCssClass="vco" TargetControlID="RFVNCPSAnt" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
@@ -6914,7 +6914,7 @@
Concepto:
</div>
<div class="col-md-4">
<asp:DropDownList ID="DdlNCPS" runat="server" AppendDataBoundItems="true" DataTextField="PSCodigo" DataValueField="CvePS" Width="100%" CssClass="select2me"></asp:DropDownList>
<asp:DropDownList ID="DdlNCPS" runat="server" DataTextField="PSCodigo" DataValueField="CvePS" Width="100%" CssClass="select2me"></asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVNCPS" runat="server" InitialValue="-1" ControlToValidate="DdlNCPS" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Concepto''</b> es necesario, por favor ingréselo." ValidationGroup="GrpModalAplicarNC"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCENCPS" runat="server" HighlightCssClass="vco" TargetControlID="RFVNCPS" Width="350px"></ajax:ValidatorCalloutExtender>
</div>
@@ -7014,17 +7014,17 @@
<asp:Literal ID="LtlIVA" runat="server" Text='<%# Eval("IVA", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="IEPS" ItemStyle-HorizontalAlign="Right">
<asp:TemplateField HeaderText="IEPS" ItemStyle-HorizontalAlign="Right" visible="false">
<ItemTemplate>
<asp:Literal ID="LtlIEPS" runat="server" Text='<%# Eval("IEPS", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="RetIVA" ItemStyle-HorizontalAlign="Right">
<asp:TemplateField HeaderText="RetIVA" ItemStyle-HorizontalAlign="Right" visible="false">
<ItemTemplate>
<asp:Literal ID="LtlRetIVA" runat="server" Text='<%# Eval("RetIVA", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="RetISR" ItemStyle-HorizontalAlign="Right">
<asp:TemplateField HeaderText="RetISR" ItemStyle-HorizontalAlign="Right" visible="false">
<ItemTemplate>
<asp:Literal ID="LtlRetISR" runat="server" Text='<%# Eval("RetISR", "{0:N2}") %>'></asp:Literal>
</ItemTemplate>
@@ -8465,16 +8465,16 @@
<div class="row">
<div class="form-group col-md-6 form-md-line-input input-iconright ">
<asp:Label runat="server" Style="width: 90%; color: #888888;" AssociatedControlID="DdlMedicoModal">Requiere Técnico:</asp:Label>
<asp:CheckBox ID="ChkRequiereTecnicoModal" data-size="small" CssClass="make-switchsd" runat="server" OnCheckedChanged="ChkRequiereTecnicoModal_CheckedChanged" AutoPostBack="true" />
<asp:CheckBox ID="ChkRequiereTecnicoModal" CssClass="chksino" runat="server" OnCheckedChanged="ChkRequiereTecnicoModal_CheckedChanged" AutoPostBack="true" Text="Requiere Técnico" />
</div>
<div class="form-group col-md-6 form-md-line-input input-iconright " runat="server" id="DvModalRequiereOSFecha" visible="false">
<asp:Label runat="server" Style="width: 90%; color: #888888;" AssociatedControlID="TxtFechaModal">Fecha De Orden:</asp:Label>
<asp:Label runat="server" Style="width: 90%; color: #888888;" AssociatedControlID="TxtFechaModal">Fecha de Cirugia:</asp:Label>
<asp:TextBox ID="TxtFechaModal" type="datetime-local" runat="server" CssClass="form-control" CausesValidation="true" Style="width: 100%" step="1"></asp:TextBox>
</div>
</div>
</div>
<div class="row">
<div class="row" runat="server" id="DVGvProductosProcedimiento" visible="false">
<div class="col-md-12">
Productos utilizados en el procedimiento
<asp:GridView ID="GvProductosProcedimiento" runat="server" CssClass="table table-hover table-striped ScrollAD mysmallbtn" data-sort="true" AutoGenerateColumns="False" Width="100%"
@@ -10261,7 +10261,7 @@
function CalculaPorcentajeNC() {
var ImporteReferencia = (($('#C_DdlNCNivelImporte').val() == "1") ? ToDouble($get('TxtTotal').value) : ToDouble($get('TxtSubTotal').value));
//var ImporteReferencia = ToDouble($get('TxtTotal').value);
$get('TxtNCPorcentaje').value = FormatoNumero((ToDouble($get('TxtNCImporte').value) * 100) / ImporteReferencia, 4);
$get('TxtNCPorcentaje').value = FormatoNumero(ToDouble($get('TxtNCImporte').value * 100.00) / ImporteReferencia,4) ;
}
function CambioTipoMoneda(chk, saldo, txt, tipocambio, CveMoneda) {

View File

@@ -2599,9 +2599,13 @@ Partial Class Ventas
CargaCuentasTerminal()
'CargaDdlNCPS()
CargarCamiones()
CargaMedicos()
CargaProcedimientos()
CargaDdlClientes()
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
CargaMedicos()
CargaProcedimientos()
CargaDdlClientes()
End If
@@ -5829,6 +5833,23 @@ Partial Class Ventas
UpEstatus.Update()
Retorno = True
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
If DbRowVenta("CveMedico").ToString.ToEntero > 0 Then
TrObsMedico1.Visible = True
TrObsMedico2.Visible = True
TrObsProcedimiento1.Visible = True
TrObsProcedimiento2.Visible = True
DdlMedicoObservaciones.SelectedValueExist(DbRowVenta("CveMedico").ToString)
DdlProcedimientoObservaciones.SelectedValueExist(DbRowVenta("CveProcedimiento").ToString)
End If
End If
End If
Return Retorno
End Function
@@ -7785,6 +7806,10 @@ Partial Class Ventas
DdlProcedimientoModal.DataSource = GlobalDTProcedimientos(UsuarioActual.CveEmpresa).FiltraParametros("Estatus = 'True' ")
DdlProcedimientoModal.DataBind()
DdlProcedimientoObservaciones.DataSource = GlobalDTProcedimientos(UsuarioActual.CveEmpresa)
DdlProcedimientoObservaciones.DataBind()
End Sub
Private Sub CargaMedicos()
@@ -7794,6 +7819,9 @@ Partial Class Ventas
DdlMedicoModal.DataSource = GlobalDTMedicos(UsuarioActual.CveEmpresa).FiltraParametros("Estatus = 'True' ")
DdlMedicoModal.DataBind()
DdlMedicoObservaciones.DataSource = GlobalDTMedicos(UsuarioActual.CveEmpresa)
DdlMedicoObservaciones.DataBind()
End Sub
Private Sub CargaDdlClientes()
@@ -26963,6 +26991,7 @@ Partial Class Ventas
Dim DtTemporal As DataTable = ObjMovtos.DtResultados.FiltraParametros("TipoDocto NOT IN ('RNC','Rem') AND Tipo = 'Act' AND CveVenta > 0", "Moneda, OrdenVencimiento, FechaVencimiento")
GvCxC.DataSource = DtTemporal
End If
If UsuarioActual.Empresa.Funcionalidad(713) <> "" Then GvCxC.Columns(6).Visible = True 'columna de IEPS
ObjMovtos.Dispose()
GvCxC.DataBind()
UpAplicarNC.Update()
@@ -30070,7 +30099,7 @@ Partial Class Ventas
If DdlTipoAmortizacionAnticipo.SelectedValue = "2" Then
'debo de cambiar la columna que se tomaria como total, por si tiene impuestos, la NC estaria abarcandolos
CargaDdlNCPS()
DivConceptoNC.Visible = True
Else
DivConceptoNC.Visible = False
@@ -36029,6 +36058,7 @@ Partial Class Ventas
GvProductosProcedimiento.DataSource = Nothing
GvProductosProcedimiento.DataBind()
DVGvProductosProcedimiento.Visible = False
UpDvModalTipoVenta.Update()
@@ -36153,6 +36183,7 @@ Partial Class Ventas
End If
GvProductosProcedimiento.DataBind()
DVGvProductosProcedimiento.Visible = True
UpDvModalTipoVenta.Update()
@@ -36236,11 +36267,7 @@ Partial Class Ventas
' End If
' End If
' End If
' End If
'End Sub
Protected Sub LBNotaCredito_Click(sender As Object, e As EventArgs)