This commit is contained in:
2024-05-23 22:27:42 -07:00
14 changed files with 1467 additions and 869 deletions

View File

@@ -5918,7 +5918,7 @@
} }
function chkAnt(t, txt, importe, TotalSaldoCompra, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal, TCCompra) { function chkAnt(t, txt, importe, TotalSaldoCompra, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal, TCCompra, txtComision) {
var Total = ToDouble($get('TxtTotal').value); var Total = ToDouble($get('TxtTotal').value);
debugger; debugger;
var txtvalue = ToDouble(txt.value); var txtvalue = ToDouble(txt.value);
@@ -5937,7 +5937,9 @@
} }
} }
else { TCC = 1; } else { TCC = 1; }
var DifSaldo = (TotalSaldoCompra - FnSumaValoresAnt()).toFixed(2); // le agrego lo del valor actual para validarlo var DifSaldo = (TotalSaldoCompra - FnSumaValoresAnt());//.toFixed(2); // le agrego lo del valor actual para validarlo
if (t.checked) if (t.checked)
{ {
@@ -5946,6 +5948,16 @@
} else { } else {
txt.value = toFixed(ToDouble(DifSaldo * TCC), 2); txt.value = toFixed(ToDouble(DifSaldo * TCC), 2);
} }
if (txtComision !== undefined && txtComision !== null) {
let difFinal = (DifSaldo - importevalue) * TCC;
if (difFinal > 0 && difFinal < 1) {
txtComision.value = toFixed(roundToTwo(difFinal), 2);
}
}
} else { } else {
txt.value = ""; txt.value = "";
} }
@@ -5958,6 +5970,10 @@
} }
function roundToTwo(num) {
return Math.round(num * 100) / 100;
}
function FnCambiaAnt(chk, txt, saldo, TotalSaldo, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal, txtComision) { function FnCambiaAnt(chk, txt, saldo, TotalSaldo, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal, txtComision) {
var Total = ToDouble($get('TxtTotal').value); var Total = ToDouble($get('TxtTotal').value);

View File

@@ -3549,10 +3549,21 @@ Partial Class Compras_Compras
ViewState("CveProveedor") = ObjProveedor.CveProveedor ViewState("CveProveedor") = ObjProveedor.CveProveedor
HdnCveProveedor.Value = ObjProveedor.CveProveedor.ToString HdnCveProveedor.Value = ObjProveedor.CveProveedor.ToString
TxtFechaPago.Text = (TxtFecha.Text.ToDate.AddDays(LblDiasCredito.Text.ToEntero)).ToShortDateString TxtFechaPago.Text = (TxtFecha.Text.ToDate.AddDays(LblDiasCredito.Text.ToEntero)).ToShortDateString
RFCProveedor = ObjProveedor.RFC 'comentado RMF.2024.05.21. en anticipos parciales, está bloquenado
'If MetodoPagoOC = 0 AndAlso RBLPago.SelectedValue.ToEntero <> 2 Then
CveRegimenFiscalProveedor = ObjProveedor.CveRegimenFiscal ' Dim ImporteAnticipoComision As Decimal = 0
If CveFactura > 0 Then ' If ArrAnticipos.Count > 0 Then
' For Each Ant As Compras_Compras.Anticipos In ArrAnticipos
' ImporteAnticipoComision += Ant.ImporteComision
' Next
' End If
' If (LblSaldoFactura.Text.ToDecimal - ImporteAnticipoComision) > 0 Then
' Alert("La orden de compra se definió de contado, favor de especificar la compra de contado.", TipoMensaje.MsgAdvertencia)
' Exit Sub
' End If
'End If
If RetIVAOriginal > 0 Then If RetIVAOriginal > 0 Then
Dim CalRetIVAPor As Decimal = (RetIVAOriginal * 1 / SubTotal2Original).RoundAD(6).ToDecimal Dim CalRetIVAPor As Decimal = (RetIVAOriginal * 1 / SubTotal2Original).RoundAD(6).ToDecimal
@@ -4193,21 +4204,10 @@ Partial Class Compras_Compras
'------------------ INICIA VALIDACIONES ------------------ '------------------ INICIA VALIDACIONES ------------------
'comentado RMF.2024.05.21. en anticipos parciales, está bloquenado If MetodoPagoOC = 0 AndAlso RBLPago.SelectedValue.ToEntero <> 2 AndAlso LblSaldoFactura.Text.ToDecimal > 0 Then
'If MetodoPagoOC = 0 AndAlso RBLPago.SelectedValue.ToEntero <> 2 Then Alert("La orden de compra se definió de contado, favor de especificar la compra de contado.", TipoMensaje.MsgAdvertencia)
Exit Sub
' Dim ImporteAnticipoComision As Decimal = 0 End If
' If ArrAnticipos.Count > 0 Then
' For Each Ant As Compras_Compras.Anticipos In ArrAnticipos
' ImporteAnticipoComision += Ant.ImporteComision
' Next
' End If
' If (LblSaldoFactura.Text.ToDecimal - ImporteAnticipoComision) > 0 Then
' Alert("La orden de compra se definió de contado, favor de especificar la compra de contado.", TipoMensaje.MsgAdvertencia)
' Exit Sub
' End If
'End If
Dim CveSubProyectoPrincipal As Integer = AsignarSubProyectoPrincipal() Dim CveSubProyectoPrincipal As Integer = AsignarSubProyectoPrincipal()
@@ -7251,20 +7251,22 @@ Partial Class Compras_Compras
ErrorPrepoliza = True ErrorPrepoliza = True
End If End If
Else Else
Dim ImporteAntMNComision As Decimal = (ImporteAnt + ImporComisionAnticipo) * TipoCambioAnt 'Dim ImporteAntMNComision As Decimal = (ImporteAnt + ImporComisionAnticipo) * TipoCambioAnt
Dim ImporteAntMNComision As Decimal = (ImporteAnt) * TipoCambioAnt
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, (ImporteAnt + ImporComisionAnticipo), ImporteAntMNComision, ConceptoContableAnticipo, Referencia, Concepto, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedorLocal, CveIE:=Ant.CveIE, ImporteME:=If(tipoCambioActual = 1, 0, (ImporteAnt + ImporComisionAnticipo)), TipoCambio:=TipoCambioAnt, Contabilizable:=SeContabiliza) Then 'If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, (ImporteAnt + ImporComisionAnticipo), ImporteAntMNComision, ConceptoContableAnticipo, Referencia, Concepto, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedorLocal, CveIE:=Ant.CveIE, ImporteME:=If(tipoCambioActual = 1, 0, (ImporteAnt + ImporComisionAnticipo)), TipoCambio:=TipoCambioAnt, Contabilizable:=SeContabiliza) Then
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, TipoMovimiento, (ImporteAnt), ImporteAntMNComision, ConceptoContableAnticipo, Referencia, Concepto, CveCompra:=CveCompraNC, CveCompraAmortizacion:=CveCompra, CveProveedor:=CveProveedorLocal, CveIE:=Ant.CveIE, ImporteME:=If(tipoCambioActual = 1, 0, (ImporteAnt)), TipoCambio:=TipoCambioAnt, Contabilizable:=SeContabiliza) Then
ErrorPrepoliza = True ErrorPrepoliza = True
End If End If
End If End If
If TxtTotal.Text.ToDouble > 0 AndAlso TieneAnticiposXML = False Then If TxtTotal.Text.ToDouble > 0 AndAlso TieneAnticiposXML = False Then
Dim Pago As New CompraPago Dim Pago As New CompraPago
Pago.ImportePago = importeMovimiento Pago.ImportePago = importeMovimiento + ImporComisionAnticipo
Pago.CveIE = Ant.CveIE Pago.CveIE = Ant.CveIE
Pago.TCPago = Ant.TCCompra Pago.TCPago = Ant.TCCompra
Pago.CveMonedaPago = If(Ant.TCCompra > 1, 2, 1) Pago.CveMonedaPago = If(Ant.TCCompra > 1, 2, 1)
Pago.OtroGastoIngreso = ImporComisionAnticipo Pago.OtroGastoIngreso = -ImporComisionAnticipo
ErrorPrepoliza = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta) ErrorPrepoliza = AplicaPrePolizaPagoCompra(CompraActual, Pago, CvePrePoliza, ObjConta)
End If End If
@@ -8491,7 +8493,8 @@ Partial Class Compras_Compras
Dim ImporteAnticipo As Decimal = 0 Dim ImporteAnticipo As Decimal = 0
If ArrAnticipos.Count > 0 Then If ArrAnticipos.Count > 0 Then
For Each Ant As Compras_Compras.Anticipos In ArrAnticipos For Each Ant As Compras_Compras.Anticipos In ArrAnticipos
ImporteAnticipo += Ant.Importe 'ImporteAnticipo += (Ant.Importe + Ant.ImporteComision)
ImporteAnticipo += (Ant.Importe)
Next Next
End If End If
@@ -9773,22 +9776,30 @@ Partial Class Compras_Compras
Dim tTCFecha As Double = If(Not e.Row.DBCampo("TCCompra").ToDouble > 1, GlobalTipoCambio(e.Row.DBCampo("Fecha").ToDate), e.Row.DBCampo("TCCompra").ToDouble) Dim tTCFecha As Double = If(Not e.Row.DBCampo("TCCompra").ToDouble > 1, GlobalTipoCambio(e.Row.DBCampo("Fecha").ToDate), e.Row.DBCampo("TCCompra").ToDouble)
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("chkAnt(this,{0},{1},{2},{3},{4},{5},{6});",
If UsuarioActual.Empresa.CveEmpresa.Contiene(13, 83) Then
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("chkAnt(this,{0},{1},{2},{3},{4},{5},{6},{7});",
e.Row.FCTextBox("TxtAnticipo").ClientID, e.Row.FCTextBox("TxtAnticipo").ClientID,
e.Row.DBCampo("Saldo"), e.Row.DBCampo("Saldo"),
If(CveCompra > 0, CompraSaldo, ImporteAmortizacion), If(CveCompra > 0, CompraSaldo, ImporteAmortizacion),
e.Row.DBCampo("CveMoneda"), e.Row.DBCampo("CveMoneda"),
e.Row.DBCampo("TCCompra").ToDouble, e.Row.DBCampo("TCCompra").ToDouble,
DdlMoneda.SelectedValue, DdlMoneda.SelectedValue,
IIf(DdlMoneda.SelectedValue = "1", 1, TxtTC.Text))) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO IIf(DdlMoneda.SelectedValue = "1", 1, TxtTC.Text),
e.Row.FCTextBox("TxtComision").ClientID
)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO
If UsuarioActual.Empresa.CveEmpresa.Contiene(13, 83) Then
e.Row.FCTextBox("TxtAnticipo").Attributes.Add("onKeyUp", String.Format("FnCambiaAnt({0},this,{1},{2},{3},{4},{5},{6});", e.Row.FCTextBox("TxtAnticipo").Attributes.Add("onKeyUp", String.Format("FnCambiaAnt({0},this,{1},{2},{3},{4},{5},{6});",
e.Row.FCCheckBox("Chk").ClientID, e.Row.FCCheckBox("Chk").ClientID,
e.Row.DBCampo("Saldo"), e.Row.DBCampo("Saldo"),
If(CveCompra > 0, CompraSaldo, ImporteAmortizacion), e.Row.DBCampo("CveMoneda").ToEntero, If(CveCompra > 0, CompraSaldo, ImporteAmortizacion),
e.Row.DBCampo("CveMoneda").ToEntero,
tTCFecha, tTCFecha,
DdlMoneda.SelectedValue.ToEntero, DdlMoneda.SelectedValue.ToEntero,
e.Row.FCTextBox("TxtComision").ClientID)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO e.Row.FCTextBox("TxtComision").ClientID)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO
@@ -9802,6 +9813,17 @@ Partial Class Compras_Compras
DdlMoneda.SelectedValue.ToEntero, DdlMoneda.SelectedValue.ToEntero,
e.Row.FCTextBox("TxtAnticipo").ClientID)) e.Row.FCTextBox("TxtAnticipo").ClientID))
Else Else
e.Row.FCCheckBox("Chk").Attributes.Add("onclick", String.Format("chkAnt(this,{0},{1},{2},{3},{4},{5},{6});",
e.Row.FCTextBox("TxtAnticipo").ClientID,
e.Row.DBCampo("Saldo"),
If(CveCompra > 0, CompraSaldo, ImporteAmortizacion),
e.Row.DBCampo("CveMoneda"),
e.Row.DBCampo("TCCompra").ToDouble,
DdlMoneda.SelectedValue,
IIf(DdlMoneda.SelectedValue = "1", 1, TxtTC.Text)
)) 'SI ES UNA COMPRA NUEVA SE PONE EL TOTAL, SI NO EL SALDO
e.Row.FCTextBox("TxtAnticipo").Attributes.Add("onKeyUp", String.Format("FnCambiaAnt({0},this,{1},{2},{3},{4},{5});", e.Row.FCTextBox("TxtAnticipo").Attributes.Add("onKeyUp", String.Format("FnCambiaAnt({0},this,{1},{2},{3},{4},{5});",
e.Row.FCCheckBox("Chk").ClientID, e.Row.FCCheckBox("Chk").ClientID,
e.Row.DBCampo("Saldo"), e.Row.DBCampo("Saldo"),

View File

@@ -10,6 +10,17 @@
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server"> <asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
</asp:Content> </asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server"> <asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<asp:UpdatePanel runat="server" ID="UpAcciones" UpdateMode="Conditional">
<ContentTemplate>
<li>
<asp:LinkButton runat="server" ID="LnkAccionesAgregarClasificacion" data-toggle="tooltip" Visible ="false" OnClick="LnkAccionesAgregarClasificacion_Click"
data-placement="left" title="Agregar Clasificación" Text="<i class='fa fa-plus'></i> Agregar Clasificación"></asp:LinkButton>
</li>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Content> </asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server"> <asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
</asp:Content> </asp:Content>
@@ -98,7 +109,7 @@
</div> </div>
</div> </div>
<div class="portlet-body"> <div class="portlet-body">
<div class="rowpadding"> <div class="rowpadding" id="content" >
<asp:UpdatePanel ID="UpGvClasificaciones" runat="server" UpdateMode="Conditional"> <asp:UpdatePanel ID="UpGvClasificaciones" runat="server" UpdateMode="Conditional">
<ContentTemplate> <ContentTemplate>
<asp:GridView ID="GvPresupuestos" runat="server" ShowFooter="true" GridLines="None" EmptyDataText="No se encontraron presupuestos" CssClass="table table-hover table-striped Widthall ScrollAD" AutoGenerateColumns="False" data-heighterror="600" <asp:GridView ID="GvPresupuestos" runat="server" ShowFooter="true" GridLines="None" EmptyDataText="No se encontraron presupuestos" CssClass="table table-hover table-striped Widthall ScrollAD" AutoGenerateColumns="False" data-heighterror="600"
@@ -168,6 +179,44 @@
</div> </div>
</ContentTemplate> </ContentTemplate>
</asp:UpdatePanel> </asp:UpdatePanel>
<div id="DVModalAgregarClasificacion" class="modal ADS fade" role="dialog">
<div class="modal-dialog" style="width: 450px;">
<asp:UpdatePanel runat="server" class="modal-content" ID="UpModalAgregarClasicicacion" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-header ">
<button type="button" class="close" data-dismiss="modal">×</button>
<h4 class="modal-title">
<asp:Literal ID="LtlTituloModalAgregarClasificacion" runat="server">Agregar Clasificación</asp:Literal></h4>
</div>
<div class="modal-body">
<div class="form-group form-md-line-input input-iconright">
<asp:DropDownList ID="DdlModalClasificacion" CssClass="form-control select2me" runat="server" DataTextField="Clasificacion" DataValueField="CveClasificacion" Width="100%" >
<asp:ListItem Value="-1">Seleccione Una</asp:ListItem>
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RfvDdlModalClasificacion" InitialValue="-1" runat="server" ControlToValidate="DdlModalClasificacion" CssClass="help-block errorimput"
ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Clasificación''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardarMedico"></asp:RequiredFieldValidator>
<label for="<%= DdlModalClasificacion.ClientID.ToString()%>">Clasificación:</label>
<i></i>
</div>
</div>
<div class="modal-footer">
<asp:Button ID="LnkModalAgregarClasificacion" runat="server" class="btn btn-success" Text="Agregar" ValidationGroup="GrpAgregarClasificacion" OnClick="LnkModalAgregarClasificacion_Click" />
<button id="BtnModalCancelarAgregarClasificacion" runat="server" type="button" class="btn default" data-dismiss="modal">Cancelar</button>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</div>
</asp:Content> </asp:Content>
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server"> <asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
<script type="text/javascript"> <script type="text/javascript">
@@ -292,6 +341,23 @@
return numero; return numero;
} }
//function scrollToTableCell(text) {
// const table = document.getElementById('ADSH-C_GvPresupuestos');
// const rows = table.getElementsByTagName('tr');
// for (let row of rows) {
// const cells = row.getElementsByTagName('td');
// for (let cell of cells) {
// if (cell.textContent.includes(text)) {
// cell.scrollIntoView({ behavior: 'smooth' });
// cell.classList.add('highlight');
// return;
// }
// }
// }
//}
</script> </script>
</asp:Content> </asp:Content>

View File

@@ -88,11 +88,13 @@ Partial Class Contratos_ModificarPresupuesto
#Region "C A R G A - D A T O S" #Region "C A R G A - D A T O S"
Private Sub CargaDatos() Private Sub CargaDatos()
Dim CvePresupuesto = DdlPresupuesto.SelectedValue.ToEntero Dim CvePresupuesto = DdlPresupuesto.SelectedValue.ToEntero
Dim Nombre = "-1" Dim Nombre = "-1"
Dim CveSubProyecto = -1 Dim CveSubProyecto = -1
Dim CveUsuario = -1 Dim CveUsuario = -1
Dim Agrupador = 1 'CLASIFICACION Dim Agrupador = 1 'CLASIFICACION
If CvePresupuesto > 0 Then If CvePresupuesto > 0 Then
TxtFecha.Text = NowADS().ToString("dd/MM/yyyy") TxtFecha.Text = NowADS().ToString("dd/MM/yyyy")
Dim DrPresupuesto = DtPresupuestos.FiltroPrimero($"CvePresupuesto = {CvePresupuesto}") Dim DrPresupuesto = DtPresupuestos.FiltroPrimero($"CvePresupuesto = {CvePresupuesto}")
@@ -131,10 +133,22 @@ Partial Class Contratos_ModificarPresupuesto
GvPresupuestos.Columns(3).Visible = True GvPresupuestos.Columns(3).Visible = True
GvPresupuestos.Columns(4).Visible = True GvPresupuestos.Columns(4).Visible = True
End Select End Select
Else
DtClasificaciones = New DataTable
GvPresupuestos.DataSource = DtClasificaciones
GvPresupuestos.DataBind()
End If End If
ValidaAcciones()
End Sub End Sub
Protected Sub GvPresupuestos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvPresupuestos.RowDataBound Protected Sub GvPresupuestos_RowDataBound(sender As Object, e As GridViewRowEventArgs) Handles GvPresupuestos.RowDataBound
If e.Row.RowType = DataControlRowType.DataRow Then If e.Row.RowType = DataControlRowType.DataRow Then
Dim StrTipo = DdlTipo.SelectedValue Dim StrTipo = DdlTipo.SelectedValue
@@ -286,4 +300,74 @@ Partial Class Contratos_ModificarPresupuesto
End If End If
End Sub End Sub
Private Sub ValidaAcciones()
LnkAccionesAgregarClasificacion.Visible = False
If DtClasificaciones IsNot Nothing AndAlso DtClasificaciones.Rows.Count > 0 Then
LnkAccionesAgregarClasificacion.Visible = True
End If
UpAcciones.Update()
End Sub
Protected Sub LnkAccionesAgregarClasificacion_Click(sender As Object, e As EventArgs)
CargaAccionesDdlclasificaciones()
RegistraScript("$('#DVModalAgregarClasificacion').modal();")
End Sub
Private Sub CargaAccionesDdlclasificaciones()
Dim dtClasificaciones As DataTable = Me.DtClasificaciones.Copy
Dim globalDtClasificacionesn As DataTable = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltraParametros("Tipo = 1 AND Estado = 1 ").Copy
Dim filteredRecords = From globalRow In globalDtClasificacionesn.AsEnumerable()
Where Not dtClasificaciones.AsEnumerable().Any(Function(dtRow) dtRow.Field(Of Integer)("CveClasificacion") = globalRow.Field(Of Integer)("CveClasificacion"))
Select globalRow
Dim resultTable As DataTable = globalDtClasificacionesn.Clone()
For Each row In filteredRecords
resultTable.ImportRow(row)
Next
DdlModalClasificacion.DataSource = resultTable
DdlModalClasificacion.DataBind()
DdlModalClasificacion.Items.Insert(0, New ListItem("Seleccione Una", "-1"))
UpModalAgregarClasicicacion.Update()
End Sub
Protected Sub LnkModalAgregarClasificacion_Click(sender As Object, e As EventArgs)
Dim CvePresupuesto = DdlPresupuesto.SelectedValue.ToEntero
Dim CveClasificacion As Integer = DdlModalClasificacion.SelectedValue.ToEntero
If CveClasificacion > 0 Then
Dim ObjCont As New ClsContratos
Dim TieneError As Boolean = False
If Not ObjCont.AddPresupuestosDetalle(CvePresupuesto, CveClasificacion, -1, 0, "") Then
TieneError = True
End If
ObjCont.Dispose()
If Not TieneError Then
RegistraScript($"$('#DVModalAgregarClasificacion').modal('hide');")
Alert($"Clasificación {DdlModalClasificacion.SelectedItem.Text} agregada correctamente.")
CargaDatos()
UpGvClasificaciones.Update()
End If
End If
End Sub
End Class End Class

View File

@@ -402,6 +402,7 @@
<Value>=Fields!SerieFolio.Value</Value> <Value>=Fields!SerieFolio.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -415,6 +416,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -434,6 +436,7 @@
<Value>=Fields!NombreComercial.Value</Value> <Value>=Fields!NombreComercial.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -447,6 +450,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -468,6 +472,7 @@
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Format>#,0.00</Format> <Format>#,0.00</Format>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -481,6 +486,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -501,6 +507,7 @@
<Value>=Fields!MetodoPago.Value</Value> <Value>=Fields!MetodoPago.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -514,6 +521,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -1668,6 +1676,10 @@
<CommandText>/* Local Query */</CommandText> <CommandText>/* Local Query */</CommandText>
</Query> </Query>
<Fields> <Fields>
<Field Name="CveVenta">
<DataField>CveVenta</DataField>
<rd:TypeName>System.Integer</rd:TypeName>
</Field>
<Field Name="SerieFolio"> <Field Name="SerieFolio">
<DataField>SerieFolio</DataField> <DataField>SerieFolio</DataField>
<rd:TypeName>System.String</rd:TypeName> <rd:TypeName>System.String</rd:TypeName>

View File

@@ -182,6 +182,7 @@
<Value>=Fields!SerieFolio.Value</Value> <Value>=Fields!SerieFolio.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -195,6 +196,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -214,6 +216,7 @@
<Value>=Fields!NombreComercial.Value</Value> <Value>=Fields!NombreComercial.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -227,6 +230,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -248,6 +252,7 @@
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Format>#,0.00</Format> <Format>#,0.00</Format>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -261,6 +266,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -281,6 +287,7 @@
<Value>=Fields!MetodoPago.Value</Value> <Value>=Fields!MetodoPago.Value</Value>
<Style> <Style>
<FontSize>8pt</FontSize> <FontSize>8pt</FontSize>
<Color>=IIF(Fields!CveVenta.Value = nothing,"White","Black")</Color>
</Style> </Style>
</TextRun> </TextRun>
</TextRuns> </TextRuns>
@@ -294,6 +301,7 @@
<Border> <Border>
<Style>None</Style> <Style>None</Style>
</Border> </Border>
<BackgroundColor>=IIF(Fields!CveVenta.Value = nothing,IIF(Fields!MetodoPago.Value = "","#5E738B","#578EBE"),"White")</BackgroundColor>
<PaddingLeft>2pt</PaddingLeft> <PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight> <PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop> <PaddingTop>2pt</PaddingTop>
@@ -2577,6 +2585,10 @@
<CommandText>/* Local Query */</CommandText> <CommandText>/* Local Query */</CommandText>
</Query> </Query>
<Fields> <Fields>
<Field Name="CveVenta">
<DataField>CveVenta</DataField>
<rd:TypeName>System.Integer</rd:TypeName>
</Field>
<Field Name="SerieFolio"> <Field Name="SerieFolio">
<DataField>SerieFolio</DataField> <DataField>SerieFolio</DataField>
<rd:TypeName>System.String</rd:TypeName> <rd:TypeName>System.String</rd:TypeName>

View File

@@ -717,6 +717,11 @@ Partial Class Inventarios_EntregaAlmacen
LbObservacionesAlmacen.Text = drE("ObservacionesAlmacen").ToString() LbObservacionesAlmacen.Text = drE("ObservacionesAlmacen").ToString()
CveVentaSurtir = CveVenta CveVentaSurtir = CveVenta
CveOSSurtir = CveOS CveOSSurtir = CveOS
If TipoDocto = "Ped" And CveOSSurtir <= 0 Then
CveOSSurtir = drE("CveOS").ToString().ToEntero
End If
CveTipoVenta = drE("CveTipoVenta").ToString().ToEntero CveTipoVenta = drE("CveTipoVenta").ToString().ToEntero
CveAlmacenTraspasoDestino = drE(If(EsDevolucionVenta = 1 And TipoDocto <> "Rem" And TipoDocto <> "Ped", "CveAlmacenTraspasoOrigen", "CveAlmacenTraspasoDestino")).ToString().ToEntero() CveAlmacenTraspasoDestino = drE(If(EsDevolucionVenta = 1 And TipoDocto <> "Rem" And TipoDocto <> "Ped", "CveAlmacenTraspasoOrigen", "CveAlmacenTraspasoDestino")).ToString().ToEntero()
CveAlmacenTraspasoOrigen = drE(If(EsDevolucionVenta = 1 And TipoDocto <> "Rem" And TipoDocto <> "Ped", "CveAlmacenTraspasoDestino", "CveAlmacenTraspasoOrigen")).ToString().ToEntero() CveAlmacenTraspasoOrigen = drE(If(EsDevolucionVenta = 1 And TipoDocto <> "Rem" And TipoDocto <> "Ped", "CveAlmacenTraspasoDestino", "CveAlmacenTraspasoOrigen")).ToString().ToEntero()
@@ -1063,6 +1068,7 @@ Partial Class Inventarios_EntregaAlmacen
If CargaBitacora Then If CargaBitacora Then
CargaBitacoraSerie() CargaBitacoraSerie()
End If End If
Else
End If End If
End If End If
@@ -4352,8 +4358,14 @@ Partial Class Inventarios_EntregaAlmacen
Private Sub RecargaporAlmacenes() Private Sub RecargaporAlmacenes()
If DdlAlmacen.SelectedValue <> "-1" Then If DdlAlmacen.SelectedValue <> "-1" Then
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
CargaGvDatos(False)
Else
CargaGvDatos() CargaGvDatos()
End If End If
End If
End Sub End Sub
Protected Sub BtnImprimirSugerencias_Click(sender As Object, e As EventArgs) Protected Sub BtnImprimirSugerencias_Click(sender As Object, e As EventArgs)

View File

@@ -2646,6 +2646,10 @@ Partial Class OC_OC
End Function End Function
Protected Sub BtnGuardar_Click(sender As Object, e As EventArgs) Handles BtnGuardar.Click Protected Sub BtnGuardar_Click(sender As Object, e As EventArgs) Handles BtnGuardar.Click
If Not ValidaTotales() Then
Exit Sub
End If
'VALIDACIONES PARA GUARDAR 'VALIDACIONES PARA GUARDAR
If ValidaGuardar() Then Exit Sub If ValidaGuardar() Then Exit Sub
@@ -2653,6 +2657,8 @@ Partial Class OC_OC
Exit Sub Exit Sub
End If End If
Dim MsgError As String = "Hubo un error al registrar" Dim MsgError As String = "Hubo un error al registrar"
'VARIABLES 'VARIABLES
Dim CveProveedorSucursal As Integer = -1 Dim CveProveedorSucursal As Integer = -1
@@ -3348,6 +3354,30 @@ Partial Class OC_OC
End Sub End Sub
Private Function ValidaTotales() As Boolean
Dim Subtotal As Decimal = DtDetalle.SUMD("Total", "Total > 0") + DtDetalle.SUMD("Descuento")
Dim Descuento As Decimal = DtDetalle.SUMD("Descuento").RoundSQL
Dim SubTotalIEPSIVA As Decimal = DtDetalle.SUMD("IEPSPSIVA")
Dim IVA As Decimal = DtDetalle.SUMD("IVA") + SubTotalIEPSIVA
Dim SubTotalIEPS As Decimal = DtDetalle.SUMD("IEPSPS")
Dim SubTotalRetIVA As Decimal = DtDetalle.SUMD("RetIVA")
Dim SubTotalRetISR As Decimal = DtDetalle.SUMD("RetISR")
Dim Total As Decimal = (Subtotal - Descuento + IVA + SubTotalIEPS - SubTotalRetIVA - SubTotalRetISR)
Dim Diferencia As Decimal = (Total - LblTotal.Text.ToDecimal).RoundSQL(2)
If Math.Abs(Diferencia) > 0 Then
Alert($"Existe una diferencia de {Diferencia.ToString("###,###,###.00")} entre el Total y las Partidas.", TipoMensaje.MsgAdvertencia)
Return False
Else
Return True
End If
End Function
Protected Function GeneraOrdenes(ByRef objOrdenCompra As ClsOC, Conta As ClsContPAQi, ByRef ObjInventarios As ClsInventarios) As Boolean Protected Function GeneraOrdenes(ByRef objOrdenCompra As ClsOC, Conta As ClsContPAQi, ByRef ObjInventarios As ClsInventarios) As Boolean
'If Ddlcliente.txtValue.Value.ToEntero > 0 And DdlVendedor.SelectedValue.ToEntero <= 0 Then 'If Ddlcliente.txtValue.Value.ToEntero > 0 And DdlVendedor.SelectedValue.ToEntero <= 0 Then

View File

@@ -227,7 +227,7 @@ Partial Class UserControl_AddMedico
TxtFechaIng.Text = "" TxtFechaIng.Text = ""
TxtUsuario.Text = "" TxtUsuario.Text = ""
DdlVendedor.SelectedValueExist(-1) DdlVendedor.SelectedValueExist(UsuarioActual.CveVendedor)
CargaGVMedicoClienteSucursal(-1, UsuarioActual.CveEmpresa) CargaGVMedicoClienteSucursal(-1, UsuarioActual.CveEmpresa)

View File

@@ -186,33 +186,31 @@ Partial Class Ventas_CatClasificaciones2
Protected Sub LbAgregarS_Click(sender As Object, e As EventArgs) Handles LbAgregarS.Click Protected Sub LbAgregarS_Click(sender As Object, e As EventArgs) Handles LbAgregarS.Click
Dim ObjClasificaciones As New ClsClasificaciones Dim ObjClasificaciones As New ClsClasificaciones
'If ObjClasificaciones.AddClasificaciones(TxtClasificacionS.Text.Trim, "", If ObjClasificaciones.AddClasificaciones(TxtClasificacionS.Text.Trim, "", DdlCategoriaS.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, RequiereAFCompra:=False, RequiereAFInsumo:=False, RequierePersonal:=False) Then
' -1, "", -1, "", -1, "",
' DdlCategoriaS.SelectedValue.ToEntero, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, RequiereAFCompra:=False, RequiereAFInsumo:=False, RequierePersonal:=False) Then
' 'DdlCuentaGastoS.SelectedValue.ToEntero, DdlCuentaGastoS.SelectedItem.Text, 'DdlCuentaGastoS.SelectedValue.ToEntero, DdlCuentaGastoS.SelectedItem.Text,
' 'DdlCuentaAnticipoS.SelectedValue.ToEntero, DdlCuentaAnticipoS.SelectedItem.Text, 'DdlCuentaAnticipoS.SelectedValue.ToEntero, DdlCuentaAnticipoS.SelectedItem.Text,
' 'DdlCuentaInventarioS.SelectedValue.ToEntero, DdlCuentaInventarioS.SelectedItem.Text, 'DdlCuentaInventarioS.SelectedValue.ToEntero, DdlCuentaInventarioS.SelectedItem.Text,
' TxtClasificacionS.Text = "" TxtClasificacionS.Text = ""
' Alert("La nueva Clasificación se guardó correctamente.", TipoMensaje.MsgInformacion) Alert("La nueva Clasificación se guardó correctamente.", TipoMensaje.MsgInformacion)
' UpTitulosS.Update() UpTitulosS.Update()
' If ObjClasificaciones.GetClasificaciones(-1, 4) Then If ObjClasificaciones.GetClasificaciones(-1, 4) Then
' GlobalDTClasificaciones2(UsuarioActual.CveEmpresa) = Nothing GlobalDTClasificaciones2(UsuarioActual.CveEmpresa) = Nothing
' ViewState("DTClasificacion2") = ObjClasificaciones.DtResultados.FiltraParametros(String.Format("CveEmpresa = {0}", UsuarioActual.CveEmpresa)) ViewState("DTClasificacion2") = ObjClasificaciones.DtResultados.FiltraParametros(String.Format("CveEmpresa = {0}", UsuarioActual.CveEmpresa))
' GlobalDTClasificaciones2(UsuarioActual.CveEmpresa) = ObjClasificaciones.DtResultados.FiltraParametros(String.Format("CveEmpresa = {0}", UsuarioActual.CveEmpresa)) GlobalDTClasificaciones2(UsuarioActual.CveEmpresa) = ObjClasificaciones.DtResultados.FiltraParametros(String.Format("CveEmpresa = {0}", UsuarioActual.CveEmpresa))
' End If End If
' 'DdlCuentaGastoS.SelectedValue = "-1" 'DdlCuentaGastoS.SelectedValue = "-1"
' 'DdlCuentaAnticipoS.SelectedValue = "-1" 'DdlCuentaAnticipoS.SelectedValue = "-1"
' 'DdlCuentaInventarioS.SelectedValue = "-1" 'DdlCuentaInventarioS.SelectedValue = "-1"
' If ViewState("Orden2").ToString() <> String.Empty Then If ViewState("Orden2").ToString() <> String.Empty Then
' CargaGridS(ViewState("Orden2").ToString()) CargaGridS(ViewState("Orden2").ToString())
' Else Else
' CargaGridS("") CargaGridS("")
' End If End If
'End If End If
ObjClasificaciones.Dispose() ObjClasificaciones.Dispose()
End Sub End Sub

View File

@@ -17,9 +17,7 @@
<li> <li>
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivPersonalizar" ID="ImgPersonalizar" runat="server"> <i class="fa fa-pencil"></i> Personalizar</asp:HyperLink> <asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivPersonalizar" ID="ImgPersonalizar" runat="server"> <i class="fa fa-pencil"></i> Personalizar</asp:HyperLink>
</li> </li>
<%--<li>
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivCorporativo" ID="HyperLink1" runat="server"> <i class="fa fa-building"></i> Agregar Corporativo</asp:HyperLink>
</li>--%>
<li> <li>
<asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivUnificarCliente" ID="ImgUnificar" runat="server" Visible="false"> <i class="fa fa-pencil"></i> Unificar Clientes</asp:HyperLink> <asp:HyperLink NavigateUrl="#" data-toggle="modal" data-target="#DivUnificarCliente" ID="ImgUnificar" runat="server" Visible="false"> <i class="fa fa-pencil"></i> Unificar Clientes</asp:HyperLink>
</li> </li>
@@ -35,28 +33,27 @@
<ContentTemplate> <ContentTemplate>
<div class="portlet solid grey-cascade portlet-filter"> <div class="portlet solid grey-cascade portlet-filter">
<div class="portlet-title portlet-filterT portletfiltrostitlee"> <div class="portlet-title portlet-filterT smalltitle">
<div class="tools"> <div class="tools">
<asp:Button ID="LbFiltrar" runat="server" CausesValidation="true" CssClass=" btn btn-primary " Text="Consultar" ValidationGroup="GrpFiltrar"></asp:Button> <asp:Button ID="LbFiltrar" runat="server" CausesValidation="true" CssClass=" btn btn-primary " Text="Consultar" ValidationGroup="GrpFiltrar"></asp:Button>
<a href="javascript;" data-idchekbox="<%= chkexpand.ClientID%>" class=" <%= IIf(chkexpand.Checked = True, "collapse", "expand")%>"></a> <a href="javascript;" data-idchekbox="<%= chkexpand.ClientID%>" class=" <%= IIf(chkexpand.Checked = True, "collapse", "expand")%>"></a>
<asp:CheckBox ID="chkexpand" CssClass="hidden" runat="server" /> <asp:CheckBox ID="chkexpand" CssClass="hidden" runat="server" />
</div> </div>
<div class="titlefiltros caption "> <div class="titlefiltros caption ">
<div class="row"> <div class="row" style="height: 32px;">
<div class="col-md-1" style="font-size: medium; max-width: 100px!important">Nombre:</div>
<div class="col-md-2 " style="max-width: 283px!important"> <div class="col-md-1 truncate" >Nombre:</div>
<div class="col-md-2 truncate" style="max-width: 283px!important">
<asp:TextBox ID="TxtNombre" runat="server" Style="display: inline-block;" CssClass=" form-control input-sm select2me" CausesValidation="true" MaxLength="30" ValidationGroup="GrpFiltrar" Width="100%"></asp:TextBox> <asp:TextBox ID="TxtNombre" runat="server" Style="display: inline-block;" CssClass=" form-control input-sm select2me" CausesValidation="true" MaxLength="30" ValidationGroup="GrpFiltrar" Width="100%"></asp:TextBox>
</div> </div>
<div class="col-md-1 " style="font-size: medium; max-width: 100px!important">RFC:</div> <div class="col-md-1 truncate" >RFC:</div>
<div class=" col-md-2 " style="max-width: 283px!important"> <div class=" col-md-2 truncate" style="max-width: 283px!important">
<asp:TextBox ID="TxtRFC" runat="server" Style="display: inline-block;" CssClass=" form-control input-sm select2me" CausesValidation="true" MaxLength="40" ValidationGroup="GrpFiltrar" Width="100%"></asp:TextBox> <asp:TextBox ID="TxtRFC" runat="server" Style="display: inline-block;" CssClass=" form-control input-sm select2me" CausesValidation="true" MaxLength="40" ValidationGroup="GrpFiltrar" Width="100%"></asp:TextBox>
</div> </div>
<div class="col-md-1 " style="font-size: medium; max-width: 100px!important">Estatus:</div> <div class="col-md-1 truncate" >Estatus:</div>
<div class=" col-md-2 " style="max-width: 283px!important"> <div class=" col-md-1 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlEstatus" runat="server" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%"> <asp:DropDownList ID="DdlEstatus" runat="server" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%">
<asp:ListItem Value="-1">Todos</asp:ListItem> <asp:ListItem Value="-1">Todos</asp:ListItem>
<asp:ListItem Selected="True" Value="1">Activo</asp:ListItem> <asp:ListItem Selected="True" Value="1">Activo</asp:ListItem>
@@ -64,8 +61,19 @@
</asp:DropDownList> </asp:DropDownList>
</div> </div>
<div class="col-md-1"> <%--<div class="col-md-1">
<asp:CheckBox runat="server" ID ="ChkPermiteCredito" CssClass="md-checksd" Text="Permite Crédito" /> <asp:CheckBox runat="server" ID ="ChkPermiteCredito" CssClass="md-checksd" Text="Permite Crédito" />
</div>--%>
<div class="col-md-1 truncate">
Permite Crédito:
</div>
<div class="col-md-1 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlPermiteCredito" runat="server" CssClass=" form-control input-sm select2me" Width="100%">
<asp:ListItem Selected="True" Value="-1">Todos</asp:ListItem>
<asp:ListItem Value="1">Si</asp:ListItem>
<asp:ListItem Value="0">No</asp:ListItem>
</asp:DropDownList>
</div> </div>
</div> </div>
@@ -75,18 +83,18 @@
<div class="portlet-body" <%= IIf(chkexpand.Checked = True, "", "style=""display:none;""")%>> <div class="portlet-body" <%= IIf(chkexpand.Checked = True, "", "style=""display:none;""")%>>
<div class="row"> <div class="row">
<div class="col-md-1 " style="font-size: medium; max-width: 100px!important">Sucursal:</div> <div class="col-md-1 truncate" >Sucursal:</div>
<div class=" col-md-2 " style="max-width: 283px!important"> <div class=" col-md-2 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlSubProyecto" runat="server" DataValueField="CveSubProyecto" DataTextField="SubProyecto" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%"> <asp:DropDownList ID="DdlSubProyecto" runat="server" DataValueField="CveSubProyecto" DataTextField="SubProyecto" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%">
</asp:DropDownList> </asp:DropDownList>
</div> </div>
<div class="col-md-1 " style="font-size: medium; max-width: 100px!important">Clasif:</div> <div class="col-md-1 truncate" >Clasificación:</div>
<div class=" col-md-2 " style="max-width: 283px!important"> <div class=" col-md-2 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlClasificaciones" runat="server" DataValueField="CveClienteClasificacion" DataTextField="ClienteClasificacion" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%"> <asp:DropDownList ID="DdlClasificaciones" runat="server" DataValueField="CveClienteClasificacion" DataTextField="ClienteClasificacion" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%">
</asp:DropDownList> </asp:DropDownList>
</div> </div>
<div class="col-md-1 " style="font-size: medium; max-width: 100px!important">Tipo:</div> <div class="col-md-1 truncate" >Tipo:</div>
<div class=" col-md-2 " style="max-width: 283px!important"> <div class=" col-md-1 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlTipoCliente" runat="server" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%"> <asp:DropDownList ID="DdlTipoCliente" runat="server" CssClass=" form-control input-sm select2me" ValidationGroup="GrpFiltrar" Width="100%">
<asp:ListItem Value="-1">Todos</asp:ListItem> <asp:ListItem Value="-1">Todos</asp:ListItem>
<asp:ListItem Selected="True" Value="1">Frecuente</asp:ListItem> <asp:ListItem Selected="True" Value="1">Frecuente</asp:ListItem>
@@ -94,10 +102,10 @@
</asp:DropDownList> </asp:DropDownList>
</div> </div>
<div class="col-md-1 truncate" style="font-size: medium; max-width: 100px!important"> <div class="col-md-1 truncate" >
Vendedor: Vendedor:
</div> </div>
<div class="col-md-2 " style="max-width: 283px!important"> <div class="col-md-2 truncate" style="max-width: 283px!important">
<asp:DropDownList ID="DdlVendedor" runat="server" DataTextField="Vendedor" DataValueField="CveVendedor" ValidationGroup="GrpFiltrar" CssClass=" form-control input-sm select2me" Width="100%"> <asp:DropDownList ID="DdlVendedor" runat="server" DataTextField="Vendedor" DataValueField="CveVendedor" ValidationGroup="GrpFiltrar" CssClass=" form-control input-sm select2me" Width="100%">
</asp:DropDownList> </asp:DropDownList>
</div> </div>
@@ -105,6 +113,7 @@
</div> </div>
</div> </div>
</div> </div>
@@ -121,8 +130,9 @@
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional"> <asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate> <ContentTemplate>
<div class="portlet-body">
<table class="table table-striped" style="border: 1px solid #D3D3D3; min-width: 985px; width: 100%; display: none;">
<%-- <table class="table table-striped" style="border: 1px solid #D3D3D3; min-width: 985px; width: 100%; display: none;">
<thead> <thead>
<tr class="Titulos"> <tr class="Titulos">
<th width="100px"> <th width="100px">
@@ -175,12 +185,13 @@
</th> </th>
</tr> </tr>
</thead> </thead>
</table> </table>--%>
<div style=""> <div class="row">
<div class="col-md-12">
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontraron Clientes registrados" ShowHeader="true" <asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" EmptyDataText="No se encontraron Clientes registrados" ShowHeader="true"
DataKeyNames="FechaLimiteCredito" DataKeyNames="FechaLimiteCredito"
CssClass="table table-striped table-advance table-hover Widthall ScrollAD" data-sort="true" BorderWidth="1" BorderColor="#D3D3D3" GridLines="None"> CssClass="table table-striped table-advance table-hover Widthall ScrollAD mysmallbtn" data-sort="true" BorderWidth="1" BorderColor="#D3D3D3" GridLines="None">
<Columns> <Columns>
<asp:TemplateField Visible="true" ItemStyle-Width="100" HeaderText="Código"> <asp:TemplateField Visible="true" ItemStyle-Width="100" HeaderText="Código">
<ItemTemplate> <ItemTemplate>
@@ -319,13 +330,6 @@
<ItemStyle HorizontalAlign="Right" /> <ItemStyle HorizontalAlign="Right" />
</asp:TemplateField> </asp:TemplateField>
<%--<asp:TemplateField Visible="false">
<HeaderTemplate>CIE</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlCIE" runat="server" Text='<%# Eval("ConvenioCIE") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>--%>
<asp:TemplateField Visible="false" ItemStyle-HorizontalAlign="Left"> <asp:TemplateField Visible="false" ItemStyle-HorizontalAlign="Left">
<HeaderTemplate>Calle</HeaderTemplate> <HeaderTemplate>Calle</HeaderTemplate>
<ItemTemplate> <ItemTemplate>
@@ -350,22 +354,31 @@
<asp:Literal ID="LtlOtroTelefono" runat="server" Text='<%# Eval("TelefonoOtros") %>'></asp:Literal> <asp:Literal ID="LtlOtroTelefono" runat="server" Text='<%# Eval("TelefonoOtros") %>'></asp:Literal>
</ItemTemplate> </ItemTemplate>
</asp:TemplateField> </asp:TemplateField>
<asp:TemplateField Visible="true" ItemStyle-HorizontalAlign="center" ItemStyle-Width="100px">
<HeaderTemplate>Permite Crédito</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlPermiteCredito" runat="server" Text='<%# Eval("PermiteCreditoStr") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField Visible="true" ItemStyle-HorizontalAlign="center" ItemStyle-Width="100px"> <asp:TemplateField Visible="true" ItemStyle-HorizontalAlign="center" ItemStyle-Width="100px">
<HeaderTemplate>F Limite Crédito</HeaderTemplate> <HeaderTemplate>F Limite Crédito</HeaderTemplate>
<ItemTemplate> <ItemTemplate>
<asp:Literal ID="LtlFechaLimiteCredito" runat="server"></asp:Literal> <asp:Literal ID="LtlFechaLimiteCredito" runat="server"></asp:Literal>
</ItemTemplate> </ItemTemplate>
</asp:TemplateField> </asp:TemplateField>
</Columns> </Columns>
<RowStyle CssClass="Texto" />
<AlternatingRowStyle CssClass="TextoAlterno" />
<HeaderStyle CssClass="Titulos" />
</asp:GridView> </asp:GridView>
</div> </div>
</div>
<asp:UpdatePanel ID="UPPersonalizar" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div id="DivPersonalizar" class="modal fade" role="dialog"> <div id="DivPersonalizar" class="modal fade" role="dialog">
<div class="modal-dialog"> <div class="modal-dialog">
@@ -454,28 +467,43 @@
<asp:CheckBox ID="ChkOtroTelefono" runat="server" Text="Otro Telefono" /></td> <asp:CheckBox ID="ChkOtroTelefono" runat="server" Text="Otro Telefono" /></td>
</tr> </tr>
<tr> <tr>
<td style="text-align: left">
<asp:CheckBox ID="ChkPermiteCredito" runat="server" Checked="true" Text="Permite Crédito" /></td>
<td style="text-align: left"> <td style="text-align: left">
<asp:CheckBox ID="chkFechaLimiteCredito" runat="server" Checked="true" Text="Fecha Limite Crédito" /></td> <asp:CheckBox ID="chkFechaLimiteCredito" runat="server" Checked="true" Text="Fecha Limite Crédito" /></td>
<td style="text-align: left">
</td> <td style="text-align: left"></td>
<td style="text-align: left"> <td style="text-align: left"></td>
</td>
<td style="text-align: left">
</td>
</tr> </tr>
</thead> </thead>
</table> </table>
</div> </div>
<div class="modal-footer"> <div class="modal-footer">
<div class="row">
<div class="col-md-6" style="text-align: left">
<asp:CheckBox ID="ChkGuardarPersonalizacion" runat="server" Text=" Guarda Personalización" TextAlign="Right" />
</div>
<div class="col-md-6">
<%--<button type="button" class="btn btn-success" data-dismiss="modal" onclick="$('#BtnPersonalizar').click();">Personalizar</button>
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>--%>
<asp:Button ID="BtnPersonalizar" runat="server" Text="Personalizar" class="btn btn-success" /> <asp:Button ID="BtnPersonalizar" runat="server" Text="Personalizar" class="btn btn-success" />
<button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button> <button type="button" class="btn btn-default" data-dismiss="modal">Cancelar</button>
</div> </div>
</div> </div>
</div> </div>
</div> </div>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
<div id="DivUnificarCliente" class="modal ADS fade" role="dialog"> <div id="DivUnificarCliente" class="modal ADS fade" role="dialog">
<div class="modal-dialog"> <div class="modal-dialog">
<asp:UpdatePanel ID="UpUnificar" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional"> <asp:UpdatePanel ID="UpUnificar" class="modal-content rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
@@ -553,7 +581,7 @@
</asp:Panel> </asp:Panel>
<%-- FIN OC X SURTIR --%>
</asp:Content> </asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server"> <asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
</asp:Content> </asp:Content>

View File

@@ -41,6 +41,10 @@ Partial Class CatClientes
Me.Form.DefaultButton = LbFiltrar.UniqueID Me.Form.DefaultButton = LbFiltrar.UniqueID
CargaPersonalizacion()
End If End If
End Sub End Sub
@@ -55,7 +59,10 @@ Partial Class CatClientes
If TxtRFC.Text.Trim <> String.Empty Then RFC = TxtRFC.Text.Trim If TxtRFC.Text.Trim <> String.Empty Then RFC = TxtRFC.Text.Trim
If ObjClientes.GetClientes(-1, Nombre, "-1", "-1", RFC, "-1", "-1", DdlSubProyecto.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, Estatus:=DdlEstatus.SelectedValue.ToEntero, CveClienteClasificacion:=DdlClasificaciones.SelectedValue.ToEntero, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CveVendedor:=DdlVendedor.SelectedValue.ToEntero, PermiteCreditoFiltro:=If(ChkPermiteCredito.Checked, 1, -1)) Then 'If ObjClientes.GetClientes(-1, Nombre, "-1", "-1", RFC, "-1", "-1", DdlSubProyecto.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, Estatus:=DdlEstatus.SelectedValue.ToEntero, CveClienteClasificacion:=DdlClasificaciones.SelectedValue.ToEntero, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CveVendedor:=DdlVendedor.SelectedValue.ToEntero, PermiteCreditoFiltro:=If(ChkPermiteCredito.Checked, 1, -1)) Then
If ObjClientes.GetClientes(-1, Nombre, "-1", "-1", RFC, "-1", "-1", DdlSubProyecto.SelectedValue.ToEntero, UsuarioActual.CveEmpresa, Estatus:=DdlEstatus.SelectedValue.ToEntero, CveClienteClasificacion:=DdlClasificaciones.SelectedValue.ToEntero, TipoCliente:=DdlTipoCliente.SelectedValue.ToEntero, CveVendedor:=DdlVendedor.SelectedValue.ToEntero, PermiteCreditoFiltro:=DdlPermiteCredito.SelectedValue.ToEntero) Then
If ObjClientes.DtResultados.Rows.Count > 0 Then If ObjClientes.DtResultados.Rows.Count > 0 Then
DTDatos = ObjClientes.DtResultados DTDatos = ObjClientes.DtResultados
Else Else
@@ -124,48 +131,7 @@ Partial Class CatClientes
End Sub End Sub
Protected Sub BtnPersonalizar_Click(sender As Object, e As System.EventArgs) Handles BtnPersonalizar.Click
GvDatos.Columns(0).Visible = ChkCodigo.Checked
GvDatos.Columns(1).Visible = ChkNombre.Checked
GvDatos.Columns(2).Visible = ChkRFC.Checked
GvDatos.Columns(3).Visible = ChkSucursal.Checked
GvDatos.Columns(4).Visible = ChkTelefono.Checked
GvDatos.Columns(5).Visible = ChkVendedor.Checked
GvDatos.Columns(6).Visible = ChkEstadoSis.Checked
GvDatos.Columns(7).Visible = ChkFechaIng.Checked
GvDatos.Columns(8).Visible = ChkUsuario.Checked
GvDatos.Columns(9).Visible = ChkNombreCorto.Checked
' GvDatos.Columns(10).Visible = ChkVendedor.Checked
GvDatos.Columns(10).Visible = ChkNoExt.Checked
GvDatos.Columns(11).Visible = ChkNoInt.Checked
GvDatos.Columns(12).Visible = ChkColonia.Checked
GvDatos.Columns(13).Visible = ChkCiudad.Checked
GvDatos.Columns(14).Visible = ChkEstado.Checked
GvDatos.Columns(15).Visible = ChkPais.Checked
GvDatos.Columns(16).Visible = ChkCP.Checked
GvDatos.Columns(17).Visible = ChkContacto.Checked
GvDatos.Columns(18).Visible = ChkMail.Checked
GvDatos.Columns(19).Visible = ChkRecepcionFacturas.Checked
GvDatos.Columns(20).Visible = ChkRetIVA.Checked
GvDatos.Columns(21).Visible = ChkRetISR.Checked
GvDatos.Columns(22).Visible = ChkPlazoCobranza.Checked
GvDatos.Columns(23).Visible = ChkLimiteCredito.Checked
'GvDatos.Columns(24).Visible = ChkCIE.Checked
GvDatos.Columns(24).Visible = ChkCalle.Checked
GvDatos.Columns(25).Visible = ChkCelular.Checked
GvDatos.Columns(26).Visible = ChkCorreoCotizacion.Checked
GvDatos.Columns(27).Visible = ChkOtroTelefono.Checked
GvDatos.Columns(28).Visible = chkFechaLimiteCredito.Checked
CargaDatos()
UPDatos.Update()
End Sub
Protected Sub ImgExcel_Click(sender As Object, e As EventArgs) Handles ImgExcel.Click Protected Sub ImgExcel_Click(sender As Object, e As EventArgs) Handles ImgExcel.Click
@@ -302,7 +268,359 @@ Partial Class CatClientes
#Region "P E R S O N A L I Z A R"
Protected Sub BtnPersonalizar_Click(sender As Object, e As System.EventArgs) Handles BtnPersonalizar.Click
If ChkGuardarPersonalizacion.Checked Then
GuardaPersonalizacion()
End If
Personaliza()
End Sub
Private Sub GuardaPersonalizacion()
Dim objUsuario As New ClsSisUsuarios
Dim ListPersonalizada As New List(Of String)
If ChkCodigo.Checked Then
ListPersonalizada.Add("Codigo")
End If
If ChkNombre.Checked Then
ListPersonalizada.Add("Nombre")
End If
If ChkRFC.Checked Then
ListPersonalizada.Add("RFC")
End If
If ChkSucursal.Checked Then
ListPersonalizada.Add("Sucursal")
End If
If ChkTelefono.Checked Then
ListPersonalizada.Add("Telefono")
End If
If ChkVendedor.Checked Then
ListPersonalizada.Add("Vendedor")
End If
If ChkEstadoSis.Checked Then
ListPersonalizada.Add("EstadoSis")
End If
If ChkFechaIng.Checked Then
ListPersonalizada.Add("FechaIng")
End If
If ChkUsuario.Checked Then
ListPersonalizada.Add("Usuario")
End If
If ChkNombreCorto.Checked Then
ListPersonalizada.Add("NombreCorto")
End If
If ChkNoExt.Checked Then
ListPersonalizada.Add("NoExt")
End If
If ChkNoInt.Checked Then
ListPersonalizada.Add("NoInt")
End If
If ChkColonia.Checked Then
ListPersonalizada.Add("Colonia")
End If
If ChkCiudad.Checked Then
ListPersonalizada.Add("Ciudad")
End If
If ChkEstado.Checked Then
ListPersonalizada.Add("Estado")
End If
If ChkPais.Checked Then
ListPersonalizada.Add("Pais")
End If
If ChkCP.Checked Then
ListPersonalizada.Add("CP")
End If
If ChkContacto.Checked Then
ListPersonalizada.Add("Contacto")
End If
If ChkMail.Checked Then
ListPersonalizada.Add("Mail")
End If
If ChkRecepcionFacturas.Checked Then
ListPersonalizada.Add("RecepcionFacturas")
End If
If ChkRetIVA.Checked Then
ListPersonalizada.Add("RetIVA")
End If
If ChkRetISR.Checked Then
ListPersonalizada.Add("RetISR")
End If
If ChkPlazoCobranza.Checked Then
ListPersonalizada.Add("PlazoCobranza")
End If
If ChkLimiteCredito.Checked Then
ListPersonalizada.Add("LimiteCredito")
End If
'If ChkCIE.Checked Then
' ListPersonalizada.Add("CIE")
'End If
If ChkCalle.Checked Then
ListPersonalizada.Add("Calle")
End If
If ChkCelular.Checked Then
ListPersonalizada.Add("Celular")
End If
If ChkCorreoCotizacion.Checked Then
ListPersonalizada.Add("CorreoCotizacion")
End If
If ChkOtroTelefono.Checked Then
ListPersonalizada.Add("OtroTelefono")
End If
If ChkPermiteCredito.Checked Then
ListPersonalizada.Add("PermiteCredito")
End If
If chkFechaLimiteCredito.Checked Then
ListPersonalizada.Add("FechaLimiteCredito")
End If
If objUsuario.AddUsuariosPersonalizaciones(UsuarioActual, "CatClientes.aspx", String.Join("|", ListPersonalizada)) Then
'Alert("Personalizacion guardada")
End If
objUsuario.Dispose()
End Sub
Private Sub CargaPersonalizacion()
Dim strBasePersonalizacion As String = UsuarioActual.Personalizaciones("CatClientes.aspx")
If strBasePersonalizacion.Trim.Length > 0 Then
ChkCodigo.Checked = False
ChkNombre.Checked = False
ChkRFC.Checked = False
ChkSucursal.Checked = False
ChkTelefono.Checked = False
ChkVendedor.Checked = False
ChkEstadoSis.Checked = False
ChkFechaIng.Checked = False
ChkUsuario.Checked = False
ChkNombreCorto.Checked = False
ChkVendedor.Checked = False
ChkNoExt.Checked = False
ChkNoInt.Checked = False
ChkColonia.Checked = False
ChkCiudad.Checked = False
ChkEstado.Checked = False
ChkPais.Checked = False
ChkCP.Checked = False
ChkContacto.Checked = False
ChkMail.Checked = False
ChkRecepcionFacturas.Checked = False
ChkRetIVA.Checked = False
ChkRetISR.Checked = False
ChkPlazoCobranza.Checked = False
ChkLimiteCredito.Checked = False
ChkCalle.Checked = False
ChkCelular.Checked = False
ChkCorreoCotizacion.Checked = False
ChkOtroTelefono.Checked = False
ChkPermiteCredito.Checked = False
chkFechaLimiteCredito.Checked = False
Dim Personalizaciones As String() = strBasePersonalizacion.Split("|"c)
For Each personalizacion As String In Personalizaciones
Select Case personalizacion
Case "Codigo"
ChkCodigo.Checked = True
Exit Select
Case "Nombre"
ChkNombre.Checked = True
Exit Select
Case "RFC"
ChkRFC.Checked = True
Exit Select
Case "Sucursal"
ChkSucursal.Checked = True
Exit Select
Case "Telefono"
ChkTelefono.Checked = True
Exit Select
Case "Vendedor"
ChkVendedor.Checked = True
Exit Select
Case "EstadoSis"
ChkEstadoSis.Checked = True
Exit Select
Case "FechaIng"
ChkFechaIng.Checked = True
Exit Select
Case "Usuario"
ChkUsuario.Checked = True
Exit Select
Case "NombreCorto"
ChkNombreCorto.Checked = True
Exit Select
Case "NoExt"
ChkNoExt.Checked = True
Exit Select
Case "NoInt"
ChkNoInt.Checked = True
Exit Select
Case "Colonia"
ChkColonia.Checked = True
Exit Select
Case "Ciudad"
ChkCiudad.Checked = True
Exit Select
Case "Estado"
ChkEstado.Checked = True
Exit Select
Case "Pais"
ChkPais.Checked = True
Exit Select
Case "CP"
ChkCP.Checked = True
Exit Select
Case "Contacto"
ChkContacto.Checked = True
Exit Select
Case "Mail"
ChkMail.Checked = True
Exit Select
Case "RecepcionFacturas"
ChkRecepcionFacturas.Checked = True
Exit Select
Case "RetIVA"
ChkRetIVA.Checked = True
Exit Select
Case "RetISR"
ChkRetISR.Checked = True
Exit Select
Case "PlazoCobranza"
ChkPlazoCobranza.Checked = True
Exit Select
Case "LimiteCredito"
ChkLimiteCredito.Checked = True
Exit Select
'Case "CIE"
' ChkCIE.Checked = True
' Exit Select
Case "Calle"
ChkCalle.Checked = True
Exit Select
Case "Celular"
ChkCelular.Checked = True
Exit Select
Case "CorreoCotizacion"
ChkCorreoCotizacion.Checked = True
Exit Select
Case "OtroTelefono"
ChkOtroTelefono.Checked = True
Exit Select
Case "PermiteCredito"
ChkPermiteCredito.Checked = True
Exit Select
Case "FechaLimiteCredito"
chkFechaLimiteCredito.Checked = True
Exit Select
Case Else
Exit Select
End Select
Next
Personaliza()
Else
PersonalizaDefault()
End If
UPPersonalizar.Update()
End Sub
Private Sub PersonalizaDefault()
End Sub
Private Sub Personaliza()
GvDatos.Columns(0).Visible = ChkCodigo.Checked
GvDatos.Columns(1).Visible = ChkNombre.Checked
GvDatos.Columns(2).Visible = ChkRFC.Checked
GvDatos.Columns(3).Visible = ChkSucursal.Checked
GvDatos.Columns(4).Visible = ChkTelefono.Checked
GvDatos.Columns(5).Visible = ChkVendedor.Checked
GvDatos.Columns(6).Visible = ChkEstadoSis.Checked
GvDatos.Columns(7).Visible = ChkFechaIng.Checked
GvDatos.Columns(8).Visible = ChkUsuario.Checked
GvDatos.Columns(9).Visible = ChkNombreCorto.Checked
' GvDatos.Columns(10).Visible = ChkVendedor.Checked
GvDatos.Columns(10).Visible = ChkNoExt.Checked
GvDatos.Columns(11).Visible = ChkNoInt.Checked
GvDatos.Columns(12).Visible = ChkColonia.Checked
GvDatos.Columns(13).Visible = ChkCiudad.Checked
GvDatos.Columns(14).Visible = ChkEstado.Checked
GvDatos.Columns(15).Visible = ChkPais.Checked
GvDatos.Columns(16).Visible = ChkCP.Checked
GvDatos.Columns(17).Visible = ChkContacto.Checked
GvDatos.Columns(18).Visible = ChkMail.Checked
GvDatos.Columns(19).Visible = ChkRecepcionFacturas.Checked
GvDatos.Columns(20).Visible = ChkRetIVA.Checked
GvDatos.Columns(21).Visible = ChkRetISR.Checked
GvDatos.Columns(22).Visible = ChkPlazoCobranza.Checked
GvDatos.Columns(23).Visible = ChkLimiteCredito.Checked
'GvDatos.Columns(24).Visible = ChkCIE.Checked
GvDatos.Columns(24).Visible = ChkCalle.Checked
GvDatos.Columns(25).Visible = ChkCelular.Checked
GvDatos.Columns(26).Visible = ChkCorreoCotizacion.Checked
GvDatos.Columns(27).Visible = ChkOtroTelefono.Checked
GvDatos.Columns(28).Visible = ChkPermiteCredito.Checked
GvDatos.Columns(29).Visible = chkFechaLimiteCredito.Checked
CargaDatos()
UPDatos.Update()
End Sub
#End Region
End Class End Class

View File

@@ -431,7 +431,7 @@ Partial Class Ventas_PVCobranza
Try Try
'FACTURAR LA REMISION PARA HACER EL PAGO 'FACTURAR LA REMISION PARA HACER EL PAGO
If UsuarioActual.CveEmpresa = 193 AndAlso VentaActual.TipoDocto = "Rem" Then If UsuarioActual.CveEmpresa = 189 AndAlso VentaActual.TipoDocto = "Rem" Then
respFactura = GenerarFactura(VentaActual, ObjVentas2, ObjClientes) respFactura = GenerarFactura(VentaActual, ObjVentas2, ObjClientes)
If respFactura Is Nothing Then If respFactura Is Nothing Then

View File

@@ -5073,7 +5073,7 @@ Partial Class Ventas
'End If 'End If
'si utiliza cortes, y cajas, no permitir cancelar de días anteriores 'si utiliza cortes, y cajas, no permitir cancelar de días anteriores
If UsuarioActual.CveRol <> 1 AndAlso UsuarioActual.Empresa.Funcionalidad(109) = "1" AndAlso DbRowVenta("Fecha").ToString.ToDate.ToShortDateString.ToDate < Now.ToShortDateString.ToDate Then If UsuarioActual.CveRol <> 1 AndAlso UsuarioActual.Empresa.Funcionalidad(109) = "1" AndAlso DbRowVenta("Fecha").ToString.ToDate.ToShortDateString.ToDate < Now.ToShortDateString.ToDate Then
LbCancelarDocumento.Visible = False LbCancelarDocumento.Visible = UsuarioActual.TienePermisoProceso(378)
End If End If
End If End If
@@ -8766,7 +8766,7 @@ Partial Class Ventas
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = False GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = False
If DdlTipoComprobante.SelectedValue = "Cot" Or RBLTipoVenta.SelectedValue.ToEntero = 1 Then If DdlTipoComprobante.SelectedValue = "Cot" Or RBLTipoVenta.SelectedValue.ToEntero = 2 Then
GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = True GvPS.Rows(e.NewEditIndex).FCTextBox("TxtPrecio").Enabled = True
End If End If
@@ -17681,7 +17681,7 @@ Partial Class Ventas
If EsVentaMedica Then If EsVentaMedica Then
TxtPrecio.Enabled = False TxtPrecio.Enabled = False
If UsuarioActual.CveUsuario = 3986 Or RBLTipoVenta.SelectedValue.ToEntero = 1 Then If UsuarioActual.CveUsuario = 3986 Or RBLTipoVenta.SelectedValue.ToEntero = 2 Then
TxtPrecio.Enabled = True TxtPrecio.Enabled = True
End If End If
@@ -23479,7 +23479,7 @@ Partial Class Ventas
' DdlCuentaTarjetaDebito.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND (CveTipoCuenta <> 1 OR TieneTerminal = 1)", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero()))) ' DdlCuentaTarjetaDebito.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND (CveTipoCuenta <> 1 OR TieneTerminal = 1)", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero())))
'End If 'End If
If UsuarioActual.Empresa.Funcionalidad(109) = "1" OrElse UsuarioActual.CveEmpresa = 195 Then If UsuarioActual.Empresa.Funcionalidad(109) = "1" OrElse UsuarioActual.CveEmpresa.Contiene(195, 197) Then
DdlCuentaTransferencia.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND CveTipoCuenta = 1", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero()))) DdlCuentaTransferencia.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND CveTipoCuenta = 1", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero())))
Else Else
DdlCuentaTransferencia.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND CveTipoCuenta <> 1", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero()))) DdlCuentaTransferencia.DataSource = DtCC.FiltraParametros(String.Format("CveMoneda = {0} AND CveTipoCuenta <> 1", If(DdlMoneda.SelectedValue.ToEntero() <= 0, 1, DdlMoneda.SelectedValue.ToEntero())))