Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
164
AF/CatAF.aspx
164
AF/CatAF.aspx
@@ -36,7 +36,54 @@
|
|||||||
padding-right: 4px !important;
|
padding-right: 4px !important;
|
||||||
padding-left: 4px !important;
|
padding-left: 4px !important;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
img.cbp-img-ajustada {
|
||||||
|
max-width: 150px;
|
||||||
|
max-height: 150px;
|
||||||
|
height: auto;
|
||||||
|
width: auto;
|
||||||
|
object-fit: contain;
|
||||||
|
display: block;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
</style>
|
</style>
|
||||||
|
<style>
|
||||||
|
.img-modal {
|
||||||
|
display: none;
|
||||||
|
position: fixed;
|
||||||
|
z-index: 9999;
|
||||||
|
padding-top: 50px;
|
||||||
|
left: 0;
|
||||||
|
top: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 100%;
|
||||||
|
background-color: rgba(0,0,0,0.85);
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-modal-content {
|
||||||
|
margin: auto;
|
||||||
|
display: block;
|
||||||
|
max-width: 90%;
|
||||||
|
max-height: 80%;
|
||||||
|
border-radius: 4px;
|
||||||
|
box-shadow: 0 0 20px #000;
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-modal-close {
|
||||||
|
position: absolute;
|
||||||
|
top: 20px;
|
||||||
|
right: 35px;
|
||||||
|
color: #fff;
|
||||||
|
font-size: 35px;
|
||||||
|
font-weight: bold;
|
||||||
|
cursor: pointer;
|
||||||
|
}
|
||||||
|
|
||||||
|
.img-modal-close:hover {
|
||||||
|
color: #ccc;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
<asp:Content ID="Content3" ContentPlaceHolderID="HB" runat="Server">
|
||||||
<asp:UpdatePanel runat="server" UpdateMode="Conditional" ChildrenAsTriggers="true">
|
<asp:UpdatePanel runat="server" UpdateMode="Conditional" ChildrenAsTriggers="true">
|
||||||
@@ -370,6 +417,39 @@
|
|||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<%-- 20 --%>
|
||||||
|
<asp:TemplateField HeaderText="Última Imagen">
|
||||||
|
<ItemStyle Width="150px" />
|
||||||
|
<ItemTemplate>
|
||||||
|
|
||||||
|
<div class="portfolio-content portfolio-1">
|
||||||
|
<div id="js-filters-juicy-projects" class="cbp-l-filters-button">
|
||||||
|
</div>
|
||||||
|
<div id="js-grid-juicy-projects" class="cbp">
|
||||||
|
|
||||||
|
<div class="cbp-item graphic">
|
||||||
|
<div class="cbp-caption">
|
||||||
|
<div class="cbp-caption-defaultWrap">
|
||||||
|
<img class="cbp-img-ajustada" src='<%# String.Format("/ashx/SIGWeb.ashx?Metodo=GetImg&r={0}", Extensiones.Encripta(Eval("RutaUltimaImagen").ToString)) %>'
|
||||||
|
onerror="this.style.display='none';"
|
||||||
|
onclick="abrirModal(this.src)">
|
||||||
|
<%--<img class="cbp-img-ajustada lazy-img" data-src='<%# String.Format("/ashx/SIGWeb.ashx?Metodo=GetImg&r={0}", Extensiones.Encripta(Eval("RutaUltimaImagen").ToString)) %>' onerror="this.style.display='none';" alt="">--%>
|
||||||
|
</div>
|
||||||
|
<div class="cbp-caption-activeWrap">
|
||||||
|
<div class="cbp-l-caption-alignCenter">
|
||||||
|
<div class="cbp-l-caption-body">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
|
||||||
</Columns>
|
</Columns>
|
||||||
</asp:GridView>
|
</asp:GridView>
|
||||||
|
|
||||||
@@ -436,30 +516,18 @@
|
|||||||
<td style="text-align: left;">
|
<td style="text-align: left;">
|
||||||
<asp:CheckBox ID="ChkFechaBaja" runat="server" Text=" Fecha Baja" /></td>
|
<asp:CheckBox ID="ChkFechaBaja" runat="server" Text=" Fecha Baja" /></td>
|
||||||
<td style="text-align: left;">
|
<td style="text-align: left;">
|
||||||
<asp:CheckBox ID="CheckBox1" runat="server" Text=" No Serie" /></td>
|
<asp:CheckBox ID="ChkProyecto" runat="server" Text=" Proyecto" /></td>
|
||||||
<td style="text-align: left;">
|
<td style="text-align: left;">
|
||||||
<asp:CheckBox ID="CheckBox2" runat="server" Text=" Estado Activo Fijo" /></td>
|
<asp:CheckBox ID="ChkNombreCliente" runat="server" Text=" Nombre Cliente" /></td>
|
||||||
<td style="text-align: left;">
|
<td style="text-align: left;">
|
||||||
<asp:CheckBox ID="CheckBox3" runat="server" Text=" Responsable" /></td>
|
<asp:CheckBox ID="ChkObservaciones" runat="server" Text=" Observaciones" /></td>
|
||||||
|
|
||||||
</tr>
|
</tr>
|
||||||
<tr>
|
<tr>
|
||||||
<td style="text-align: left;">
|
<td style="text-align: left;">
|
||||||
<asp:CheckBox ID="ChkProyecto" runat="server" Text=" Proyecto" /></td>
|
<asp:CheckBox ID="ChkUltimaImagen" runat="server" Text=" Última Imagen" /></td>
|
||||||
<td style="text-align: left;">
|
|
||||||
<asp:CheckBox ID="CheckBox4" runat="server" Text=" Sub Proyecto" /></td>
|
|
||||||
<td style="text-align: left;">
|
|
||||||
<asp:CheckBox ID="ChkNombreCliente" runat="server" Text=" Nombre Cliente" /></td>
|
|
||||||
<td style="text-align: left;">
|
|
||||||
<asp:CheckBox ID="ChkObservaciones" runat="server" Text=" Observaciones" /></td>
|
|
||||||
</tr>
|
</tr>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</tbody>
|
</tbody>
|
||||||
</table>
|
</table>
|
||||||
|
|
||||||
@@ -496,7 +564,10 @@
|
|||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<div id="imgModal" class="img-modal">
|
||||||
|
<span class="img-modal-close" onclick="cerrarModal()">×</span>
|
||||||
|
<img class="img-modal-content" id="imgModalContent" alt="Vista ampliada">
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
@@ -516,4 +587,57 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
</script>--%>
|
</script>--%>
|
||||||
|
|
||||||
|
<%--<script>
|
||||||
|
document.addEventListener("DOMContentLoaded", function () {
|
||||||
|
const lazyImages = document.querySelectorAll("img.lazy-img");
|
||||||
|
|
||||||
|
const observer = new IntersectionObserver(function (entries, observer) {
|
||||||
|
entries.forEach(function (entry) {
|
||||||
|
if (entry.isIntersecting) {
|
||||||
|
const img = entry.target;
|
||||||
|
const src = img.getAttribute("data-src");
|
||||||
|
if (src) {
|
||||||
|
img.src = src;
|
||||||
|
img.removeAttribute("data-src");
|
||||||
|
}
|
||||||
|
observer.unobserve(img);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}, {
|
||||||
|
rootMargin: "100px", // anticipa un poco la carga
|
||||||
|
threshold: 0.01
|
||||||
|
});
|
||||||
|
|
||||||
|
lazyImages.forEach(function (img) {
|
||||||
|
observer.observe(img);
|
||||||
|
});
|
||||||
|
});
|
||||||
|
</script>--%>
|
||||||
|
<script>
|
||||||
|
function verEnPantallaCompleta(imgElement) {
|
||||||
|
if (imgElement.requestFullscreen) {
|
||||||
|
imgElement.requestFullscreen();
|
||||||
|
} else if (imgElement.webkitRequestFullscreen) { /* Safari */
|
||||||
|
imgElement.webkitRequestFullscreen();
|
||||||
|
} else if (imgElement.msRequestFullscreen) { /* IE11 */
|
||||||
|
imgElement.msRequestFullscreen();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
function abrirModal(src) {
|
||||||
|
var modal = document.getElementById("imgModal");
|
||||||
|
var modalImg = document.getElementById("imgModalContent");
|
||||||
|
modalImg.src = src;
|
||||||
|
modal.style.display = "block";
|
||||||
|
}
|
||||||
|
|
||||||
|
function cerrarModal() {
|
||||||
|
document.getElementById("imgModal").style.display = "none";
|
||||||
|
}
|
||||||
|
</script>
|
||||||
|
|
||||||
|
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
|
|||||||
@@ -53,6 +53,14 @@ Partial Class AF_CatAF
|
|||||||
CargaCombos()
|
CargaCombos()
|
||||||
CargaCaracteristicas()
|
CargaCaracteristicas()
|
||||||
|
|
||||||
|
If UsuarioActual.CveEmpresa = 13 Then
|
||||||
|
ChkUltimaImagen.Checked = True
|
||||||
|
ChkMarcaActivoFijo.Checked = True
|
||||||
|
ChkModeloActivoFijo.Checked = True
|
||||||
|
ChkNoSerie.Checked = True
|
||||||
|
ChkObservaciones.Checked = True
|
||||||
|
End If
|
||||||
|
|
||||||
If (Request("GPO") IsNot Nothing AndAlso Request("GPO").ToEntero() > 0) Then
|
If (Request("GPO") IsNot Nothing AndAlso Request("GPO").ToEntero() > 0) Then
|
||||||
CargaParametrosInicial()
|
CargaParametrosInicial()
|
||||||
Else
|
Else
|
||||||
@@ -62,6 +70,7 @@ Partial Class AF_CatAF
|
|||||||
CargaPersonalizacion()
|
CargaPersonalizacion()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
@@ -598,6 +607,8 @@ Partial Class AF_CatAF
|
|||||||
|
|
||||||
If ChkObservaciones.Checked Then ListPersonalizada.Add("Observaciones")
|
If ChkObservaciones.Checked Then ListPersonalizada.Add("Observaciones")
|
||||||
|
|
||||||
|
If ChkUltimaImagen.Checked Then ListPersonalizada.Add("UltimaImagen")
|
||||||
|
|
||||||
|
|
||||||
If objUsuario.AddUsuariosPersonalizaciones(UsuarioActual, "CatAF.aspx", String.Join("|", ListPersonalizada)) Then
|
If objUsuario.AddUsuariosPersonalizaciones(UsuarioActual, "CatAF.aspx", String.Join("|", ListPersonalizada)) Then
|
||||||
'Alert("Personalizacion guardada")
|
'Alert("Personalizacion guardada")
|
||||||
@@ -638,6 +649,15 @@ Partial Class AF_CatAF
|
|||||||
'ChkSubProyecto.Checked = False
|
'ChkSubProyecto.Checked = False
|
||||||
ChkNombreCliente.Checked = False
|
ChkNombreCliente.Checked = False
|
||||||
ChkObservaciones.Checked = False
|
ChkObservaciones.Checked = False
|
||||||
|
ChkUltimaImagen.Checked = False
|
||||||
|
|
||||||
|
If UsuarioActual.CveEmpresa = 13 Then
|
||||||
|
ChkUltimaImagen.Checked = True
|
||||||
|
ChkMarcaActivoFijo.Checked = True
|
||||||
|
ChkModeloActivoFijo.Checked = True
|
||||||
|
ChkNoSerie.Checked = True
|
||||||
|
ChkObservaciones.Checked = True
|
||||||
|
End If
|
||||||
|
|
||||||
Dim Personalizaciones As String() = strBasePersonalizacion.Split("|"c)
|
Dim Personalizaciones As String() = strBasePersonalizacion.Split("|"c)
|
||||||
|
|
||||||
@@ -703,6 +723,9 @@ Partial Class AF_CatAF
|
|||||||
Case "Observaciones"
|
Case "Observaciones"
|
||||||
ChkObservaciones.Checked = True
|
ChkObservaciones.Checked = True
|
||||||
Exit Select
|
Exit Select
|
||||||
|
Case "UltimaImagen"
|
||||||
|
ChkUltimaImagen.Checked = True
|
||||||
|
Exit Select
|
||||||
Case Else
|
Case Else
|
||||||
Exit Select
|
Exit Select
|
||||||
End Select
|
End Select
|
||||||
@@ -762,6 +785,7 @@ Partial Class AF_CatAF
|
|||||||
'GvDatos.Columns(18).Visible = ChkSubProyecto.Checked
|
'GvDatos.Columns(18).Visible = ChkSubProyecto.Checked
|
||||||
GvDatos.Columns(18).Visible = ChkNombreCliente.Checked
|
GvDatos.Columns(18).Visible = ChkNombreCliente.Checked
|
||||||
GvDatos.Columns(19).Visible = ChkObservaciones.Checked
|
GvDatos.Columns(19).Visible = ChkObservaciones.Checked
|
||||||
|
GvDatos.Columns(20).Visible = ChkUltimaImagen.Checked
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1593,7 +1593,14 @@ Public Class ClsBancos
|
|||||||
' Me.OnError("Ocurrió un error al guardar los cambios en el Banco", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
' Me.OnError("Ocurrió un error al guardar los cambios en el Banco", Ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
' End If
|
' End If
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
OnError("Ocurrió un error al guardar los cambios en el Banco IE Conciliar.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
|
||||||
|
If ex.Message.Contains("Número: 2601;") Then
|
||||||
|
Alert("Ya existe un movimiento bancario con el mismo Folio: <b>" & Folio & "</b>.", TipoMensaje.MsgAdvertencia)
|
||||||
|
Me.OnError("Ocurrió un error al Guardar el Movimiento. Ya existe un movimiento bancario con el mismo Folio: <b>" & Folio & "</b>.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
|
Else
|
||||||
|
OnError("Ocurrió un error al guardar los cambios en el Banco IE Conciliar.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
|
End If
|
||||||
|
|
||||||
End Try
|
End Try
|
||||||
|
|
||||||
Return Retorno
|
Return Retorno
|
||||||
|
|||||||
@@ -5741,6 +5741,8 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="modal-body">
|
<div class="modal-body">
|
||||||
|
|
||||||
|
|
||||||
<asp:UpdatePanel runat="server" ID="UpModalProrrateoGasolina" UpdateMode="Conditional">
|
<asp:UpdatePanel runat="server" ID="UpModalProrrateoGasolina" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
|
|
||||||
@@ -5753,6 +5755,11 @@
|
|||||||
<label>
|
<label>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<div class="col-md-6" style="text-align:right!important">
|
||||||
|
<asp:LinkButton ID="LnkProrrateoPlantilla" runat="server" CssClass="btn btn-success" OnClick="LnkProrrateoPlantilla_Click">
|
||||||
|
<i class="fa fa-upload" aria-hidden="true"></i> Cargar Plantilla
|
||||||
|
</asp:LinkButton>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row" style="margin-top:10px">
|
<div class="row" style="margin-top:10px">
|
||||||
@@ -5830,6 +5837,10 @@
|
|||||||
|
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<asp:UpdatePanel runat="server">
|
<asp:UpdatePanel runat="server">
|
||||||
@@ -5846,6 +5857,63 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
<%--CARGA PRORRATEO PLANTILLA--%>
|
||||||
|
<div id="DVModalProrrateoPlantilla" class="modal ADS fade" role="dialog">
|
||||||
|
<div class="modal-dialog">
|
||||||
|
<div class="modal-content">
|
||||||
|
<div class="modal-header ">
|
||||||
|
<button type="button" class="close" data-dismiss="modal">×</button>
|
||||||
|
<h4 class="modal-title">Carga Plantilla Prorrateo</h4>
|
||||||
|
</div>
|
||||||
|
<div class="modal-body">
|
||||||
|
|
||||||
|
<asp:UpdatePanel ID="UpDropZoneProrrateoPlantilla" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-11" style="margin-left: 30px; margin-right: 30px;">
|
||||||
|
<asp:TextBox ID="TxtExcelProrrateo" CssClass="ADSdropzone hidden" Text="" data-maxFile="1" runat="server"></asp:TextBox>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="modal-footer">
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
<asp:UpdatePanel ID="UpDescargarProrrateoPlantilla" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
|
||||||
|
<div class="row">
|
||||||
|
<div class="col-md-2" style="text-align: left">
|
||||||
|
<asp:LinkButton ID="LnkDescargaPlatillaProrrateo" runat="server" CssClass="btn btn-warning" OnClick="LnkDescargaPlatillaProrrateo_Click">
|
||||||
|
<i class="fa fa-download" aria-hidden="true"></i> Descargar Plantilla
|
||||||
|
</asp:LinkButton>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-10" style="text-align: right">
|
||||||
|
<asp:Button ID="BtnAddProrrateoPlantilla" runat="server" CssClass="btn btn-success" Text="Aceptar" OnClick="BtnAddProrrateoPlantilla_Click"></asp:Button>
|
||||||
|
<button type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
</ContentTemplate>
|
||||||
|
<Triggers>
|
||||||
|
<asp:PostBackTrigger ControlID="LnkDescargaPlatillaProrrateo" />
|
||||||
|
</Triggers>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
<div style="display:none">
|
<div style="display:none">
|
||||||
<asp:UpdatePanel runat="server">
|
<asp:UpdatePanel runat="server">
|
||||||
|
|||||||
@@ -13,6 +13,8 @@ Imports MoreLinq
|
|||||||
Imports System.Data.SqlClient
|
Imports System.Data.SqlClient
|
||||||
Imports ClsPaginas
|
Imports ClsPaginas
|
||||||
Imports Microsoft.Reporting.WebForms
|
Imports Microsoft.Reporting.WebForms
|
||||||
|
Imports Microsoft.Owin.Security.Provider
|
||||||
|
|
||||||
|
|
||||||
Partial Class Compras_Compras
|
Partial Class Compras_Compras
|
||||||
Inherits ClsPaginas
|
Inherits ClsPaginas
|
||||||
@@ -8028,66 +8030,66 @@ Partial Class Compras_Compras
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ErrorPrepoliza AndAlso Not ObjConta.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual, Opcion:=OpValidacion, AutoConta:=AutoConta) Then
|
If Not ErrorPrepoliza AndAlso Not ObjConta.ValidacionesPrePoliza(CvePrePoliza, UsuarioActual, Opcion:=OpValidacion, AutoConta:=AutoConta) Then
|
||||||
|
TieneError = True
|
||||||
|
If ObjConta.ValorPolizaDescuadre > 0 Then
|
||||||
|
Alert($"{ObjConta.MensajePolizaDescuadre} Diferencia{ObjConta.ValorDiferencia}", TipoMensaje.MsgError)
|
||||||
|
ErrorPrepolizaDescuadre = True
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
If UsuarioActual.Empresa.Funcionalidad(574) = "1" AndAlso (ImporteRNC > 0 OrElse ImporteRNCProntoPago > 0) Then
|
||||||
|
|
||||||
|
If ImporteRNC > 0 AndAlso Not GeneraRNC(ObjCompras.IniciaTransacSQL, CveCompra, CompraActual, ObjConta, CvePrePoliza, DdlProveedor.SelectedValue.ToEntero, DdlProveedor.SelectedItem.Text, TxtFecha.Text.ToDate, $"Remisión Nota de Crédito {TxtDescripcion.Text}", ImporteRNC, DdlMoneda.SelectedValue.ToEntero, TxtTC.Text.ToDecimal,
|
||||||
|
TxtSerie.Text, TxtFolio.Text) Then
|
||||||
TieneError = True
|
TieneError = True
|
||||||
If ObjConta.ValorPolizaDescuadre > 0 Then
|
|
||||||
Alert($"{ObjConta.MensajePolizaDescuadre} Diferencia{ObjConta.ValorDiferencia}", TipoMensaje.MsgError)
|
|
||||||
ErrorPrepolizaDescuadre = True
|
|
||||||
End If
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If UsuarioActual.Empresa.Funcionalidad(574) = "1" AndAlso (ImporteRNC > 0 OrElse ImporteRNCProntoPago > 0) Then
|
If ImporteRNCProntoPago > 0 AndAlso Not GeneraRNC(ObjCompras.IniciaTransacSQL, CveCompra, CompraActual, ObjConta, CvePrePoliza, DdlProveedor.SelectedValue.ToEntero, DdlProveedor.SelectedItem.Text, TxtFecha.Text.ToDate, $"Remisión Nota de Crédito {TxtDescripcion.Text}", ImporteRNCProntoPago, DdlMoneda.SelectedValue.ToEntero, TxtTC.Text.ToDecimal,
|
||||||
|
TxtSerie.Text, TxtFolio.Text, PrefijoSerie:="PP") Then
|
||||||
If ImporteRNC > 0 AndAlso Not GeneraRNC(ObjCompras.IniciaTransacSQL, CveCompra, CompraActual, ObjConta, CvePrePoliza, DdlProveedor.SelectedValue.ToEntero, DdlProveedor.SelectedItem.Text, TxtFecha.Text.ToDate, $"Remisión Nota de Crédito {TxtDescripcion.Text}", ImporteRNC, DdlMoneda.SelectedValue.ToEntero, TxtTC.Text.ToDecimal,
|
TieneError = True
|
||||||
TxtSerie.Text, TxtFolio.Text) Then
|
|
||||||
TieneError = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
If ImporteRNCProntoPago > 0 AndAlso Not GeneraRNC(ObjCompras.IniciaTransacSQL, CveCompra, CompraActual, ObjConta, CvePrePoliza, DdlProveedor.SelectedValue.ToEntero, DdlProveedor.SelectedItem.Text, TxtFecha.Text.ToDate, $"Remisión Nota de Crédito {TxtDescripcion.Text}", ImporteRNCProntoPago, DdlMoneda.SelectedValue.ToEntero, TxtTC.Text.ToDecimal,
|
|
||||||
TxtSerie.Text, TxtFolio.Text, PrefijoSerie:="PP") Then
|
|
||||||
TieneError = True
|
|
||||||
End If
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not TieneError Then
|
|
||||||
ObjCompras.Commit()
|
|
||||||
If ObjContaAC IsNot Nothing Then ObjContaAC.Commit()
|
|
||||||
|
|
||||||
Dim CveEvaluacionProveedor As Integer = -1
|
|
||||||
|
|
||||||
If Me.RequiereEvaluacion Then
|
|
||||||
Dim ObjPro As New ClsCompProveedores()
|
|
||||||
CveEvaluacionProveedor = ObjPro.AddEvaluacionProveedor(CveProveedor, CveCompra, NowADS(), "", Me.CveUsuarioEvaluador, "", "", UsuarioActual.CveEmpresa)
|
|
||||||
ObjPro.Dispose()
|
|
||||||
End If
|
|
||||||
|
|
||||||
'ENVIO DE CORREO NOTIFICACION A VENDEDORES DE OC
|
|
||||||
MandaCorreoOCVendedores(CveCompra)
|
|
||||||
If Not ErrorMovInv Then
|
|
||||||
For Each intMovimientoAlmacen As Integer In ListaMovimientosAlmacen
|
|
||||||
MandaCorreoOCVendedoresRecepcionAlmacen(CveCompra, intMovimientoAlmacen)
|
|
||||||
Next
|
|
||||||
End If
|
|
||||||
|
|
||||||
If CveEvaluacionProveedor > 0 Then
|
|
||||||
Msg.Append("<br/><br/>El proveedor tiene evaluaciones pendientes<br/>")
|
|
||||||
Msg.Append("¿Desea realizar una evaluación al proveedor?")
|
|
||||||
Msg.AppendFormat($"</br><a class=""Texto"" target='_blank' href=""/Compras/EvaluacionProveedor.aspx?CveEvaluacionProveedor={CveEvaluacionProveedor}"">Evaluar Proveedor.</a>")
|
|
||||||
End If
|
|
||||||
|
|
||||||
BtnGuardar.Enabled = False
|
|
||||||
UpFacturar.Update()
|
|
||||||
|
|
||||||
Alert(Msg.ToString, TipoMensaje.MsgInformacion, MsgAccionAceptar)
|
|
||||||
Else
|
|
||||||
ObjCompras.RollBack()
|
|
||||||
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
|
||||||
' Alert("Ocurrio un error al guardar la compra. Por favor intente nuevamente.", TipoMensaje.MsgError)
|
|
||||||
End If
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If Not TieneError Then
|
||||||
|
ObjCompras.Commit()
|
||||||
|
If ObjContaAC IsNot Nothing Then ObjContaAC.Commit()
|
||||||
|
|
||||||
|
Dim CveEvaluacionProveedor As Integer = -1
|
||||||
|
|
||||||
|
If Me.RequiereEvaluacion Then
|
||||||
|
Dim ObjPro As New ClsCompProveedores()
|
||||||
|
CveEvaluacionProveedor = ObjPro.AddEvaluacionProveedor(CveProveedor, CveCompra, NowADS(), "", Me.CveUsuarioEvaluador, "", "", UsuarioActual.CveEmpresa)
|
||||||
|
ObjPro.Dispose()
|
||||||
|
End If
|
||||||
|
|
||||||
|
'ENVIO DE CORREO NOTIFICACION A VENDEDORES DE OC
|
||||||
|
MandaCorreoOCVendedores(CveCompra)
|
||||||
|
If Not ErrorMovInv Then
|
||||||
|
For Each intMovimientoAlmacen As Integer In ListaMovimientosAlmacen
|
||||||
|
MandaCorreoOCVendedoresRecepcionAlmacen(CveCompra, intMovimientoAlmacen)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
If CveEvaluacionProveedor > 0 Then
|
||||||
|
Msg.Append("<br/><br/>El proveedor tiene evaluaciones pendientes<br/>")
|
||||||
|
Msg.Append("¿Desea realizar una evaluación al proveedor?")
|
||||||
|
Msg.AppendFormat($"</br><a class=""Texto"" target='_blank' href=""/Compras/EvaluacionProveedor.aspx?CveEvaluacionProveedor={CveEvaluacionProveedor}"">Evaluar Proveedor.</a>")
|
||||||
|
End If
|
||||||
|
|
||||||
|
BtnGuardar.Enabled = False
|
||||||
|
UpFacturar.Update()
|
||||||
|
|
||||||
|
Alert(Msg.ToString, TipoMensaje.MsgInformacion, MsgAccionAceptar)
|
||||||
Else
|
Else
|
||||||
|
ObjCompras.RollBack()
|
||||||
|
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
||||||
|
Alert("Ocurrio un error al guardar la compra. Por favor intente nuevamente.", TipoMensaje.MsgError)
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
Else
|
||||||
ObjCompras.RollBack()
|
ObjCompras.RollBack()
|
||||||
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
If ObjContaAC IsNot Nothing Then ObjContaAC.RollBack()
|
||||||
Alert("Ocurrio un error al guardar la compra. Por favor intente nuevamente..", TipoMensaje.MsgError)
|
Alert("Ocurrio un error al guardar la compra. Por favor intente nuevamente..", TipoMensaje.MsgError)
|
||||||
@@ -22946,7 +22948,7 @@ Partial Class Compras_Compras
|
|||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
Private Sub AgregarProrrateoGasolina(CveSubProyecto As Integer, SubProyecto As String, CvePS As Integer, CveUM As Integer, UM As String, CveClasificacion As Integer, Clasificacion As String)
|
Private Sub AgregarProrrateoGasolina(CveSubProyecto As Integer, SubProyecto As String, CvePS As Integer, CveUM As Integer, UM As String, CveClasificacion As Integer, Clasificacion As String, Optional PrecioProrrateo As Decimal = 0)
|
||||||
|
|
||||||
Dim SubTotalOriginal As Decimal = TxtSubTotal.Text.ToDecimal
|
Dim SubTotalOriginal As Decimal = TxtSubTotal.Text.ToDecimal
|
||||||
Dim IVAOriginal As Decimal = TxtIVA.Text.ToDecimal
|
Dim IVAOriginal As Decimal = TxtIVA.Text.ToDecimal
|
||||||
@@ -22956,6 +22958,10 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
Dim totalParcialDeseado As Decimal = TxtPrecioProrrateoGasolina.Text.ToDecimal
|
Dim totalParcialDeseado As Decimal = TxtPrecioProrrateoGasolina.Text.ToDecimal
|
||||||
|
|
||||||
|
If PrecioProrrateo > 0 Then
|
||||||
|
totalParcialDeseado = PrecioProrrateo
|
||||||
|
End If
|
||||||
|
|
||||||
Dim PorcentajeCalculado As Decimal = totalParcialDeseado / TotalOriginal
|
Dim PorcentajeCalculado As Decimal = totalParcialDeseado / TotalOriginal
|
||||||
|
|
||||||
Dim subtotalParcial As Decimal = SubTotalOriginal * PorcentajeCalculado
|
Dim subtotalParcial As Decimal = SubTotalOriginal * PorcentajeCalculado
|
||||||
@@ -23070,15 +23076,180 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Protected Sub LnkProrrateoPlantilla_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
|
If DdlPSProrrateoGasolina.SelectedValue.ToEntero > 0 And TxtTotal.Text.ToDecimal > 0 Then
|
||||||
|
TxtExcelProrrateo.Text = "[]"
|
||||||
|
UpDropZoneProrrateoPlantilla.Update()
|
||||||
|
RegistraScript("$('#DVModalProrrateoPlantilla').modal('show');")
|
||||||
|
Else
|
||||||
|
|
||||||
|
If Not DdlPSProrrateoGasolina.SelectedValue.ToEntero > 0 Then
|
||||||
|
Alert("Debe seleccionar un producto.", TipoMensaje.MsgAdvertencia)
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not TxtTotal.Text.ToDecimal > 0 Then
|
||||||
|
Alert("El total de la compra debe de ser mayor a 0.", TipoMensaje.MsgAdvertencia)
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
|
||||||
|
Protected Sub LnkDescargaPlatillaProrrateo_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
|
|
||||||
|
Dim RutaPlantilla As String = ""
|
||||||
|
|
||||||
|
RutaPlantilla = ModExtensiones.DirectorioBaseEmpresas & "Empresas\Grales\PlantillaProrrateo.xlsx"
|
||||||
|
|
||||||
|
If Not (RutaPlantilla = "") Then
|
||||||
|
Dim Archivo As New IO.FileInfo(RutaPlantilla)
|
||||||
|
If Archivo.Exists Then
|
||||||
|
Response.Clear()
|
||||||
|
Response.ClearHeaders()
|
||||||
|
Response.ClearContent()
|
||||||
|
Response.AddHeader("Content-Disposition", "attachment; filename=" + Archivo.Name)
|
||||||
|
Response.AddHeader("Content-Length", Archivo.Length.ToString())
|
||||||
|
Response.ContentType = "text/plain"
|
||||||
|
Response.Flush()
|
||||||
|
Response.TransmitFile(Archivo.FullName)
|
||||||
|
Response.End()
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Protected Sub BtnAddProrrateoPlantilla_Click(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
|
Dim ErrorPrceos As Boolean = False
|
||||||
|
|
||||||
|
If TxtExcelProrrateo.getfiles().Archivos.Count > 0 Then
|
||||||
|
Dim file As Archivo = TxtExcelProrrateo.getfiles().Archivos(0)
|
||||||
|
Dim Directorio As String = AppDomain.CurrentDomain.BaseDirectory & file.path
|
||||||
|
Try
|
||||||
|
If Not CargarPlantillaProrrateo(Directorio, file.filename) Then
|
||||||
|
ErrorPrceos = True
|
||||||
|
End If
|
||||||
|
Catch ex As Exception
|
||||||
|
OnError("Ocurrio un error al leer el archivo <br/>" & ex.Message, ex)
|
||||||
|
End Try
|
||||||
|
|
||||||
|
Else
|
||||||
|
Alert("No existe el archivo. Favor de subir un archivo excel a la plataforma.", TipoMensaje.MsgError)
|
||||||
|
ErrorPrceos = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not ErrorPrceos Then
|
||||||
|
If Not ErrorPrceos Then
|
||||||
|
RegistraScript("$('#DVModalProrrateoPlantilla').modal('hide');")
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
End Sub
|
||||||
|
|
||||||
|
Private Function CargarPlantillaProrrateo(directorio As String, filename As String) As Boolean
|
||||||
|
|
||||||
|
Dim DT As New DataTable
|
||||||
|
Dim ErrorProceso As Boolean = False
|
||||||
|
|
||||||
|
|
||||||
|
Try
|
||||||
|
DT = ReadExcelFile(directorio + filename, True)
|
||||||
|
Catch ex As Exception
|
||||||
|
ErrorProceso = True
|
||||||
|
OnError("Ocurrio un error al leer el archivo <br/>" & ex.Message, ex)
|
||||||
|
End Try
|
||||||
|
|
||||||
|
If Not ErrorProceso Then
|
||||||
|
|
||||||
|
Dim ContadorRow As Integer = 1
|
||||||
|
Dim SBErrores As New StringBuilder
|
||||||
|
|
||||||
|
For Each row As DataRow In DT.Rows
|
||||||
|
|
||||||
|
If row("SubProyecto").ToString.Length > 0 Then
|
||||||
|
|
||||||
|
Dim CveSubProyecto As Integer = GlobalDTSubProyectos(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $" SubProyecto = '{row("SubProyecto").ToString}' ").ToEntero
|
||||||
|
Dim Importe As Decimal = row("Importe").ToString.ToDecimal
|
||||||
|
|
||||||
|
If Not CveSubProyecto > 0 Then
|
||||||
|
SBErrores.Append($"Fila: {ContadorRow} SubProyecto: <b>'{row("SubProyecto").ToString}'</b> no encontrado.<br/>")
|
||||||
|
ErrorProceso = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not Importe > 0 Then
|
||||||
|
SBErrores.Append($"Fila: {ContadorRow} Importe Invalido: { Importe } debe ser mayor a 0.<br/>")
|
||||||
|
ErrorProceso = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
ContadorRow = ContadorRow + 1
|
||||||
|
|
||||||
|
Next
|
||||||
|
|
||||||
|
If Not ErrorProceso Then
|
||||||
|
|
||||||
|
DTProrrateoGasolina.Rows.Clear()
|
||||||
|
|
||||||
|
Dim CvePs As Integer = DdlPSProrrateoGasolina.SelectedValue.ToEntero
|
||||||
|
|
||||||
|
If Not CvePs > 0 Then
|
||||||
|
Alert("Debe seleccionar un producto", TipoMensaje.MsgAdvertencia)
|
||||||
|
ErrorProceso = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim PsRow As DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePs).FiltroPrimero("")
|
||||||
|
|
||||||
|
If PsRow Is Nothing Then
|
||||||
|
Alert("No se encontro el producto", TipoMensaje.MsgAdvertencia)
|
||||||
|
ErrorProceso = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not ErrorProceso Then
|
||||||
|
Dim CveUM As Integer = PsRow("CveUM").ToString.ToEntero
|
||||||
|
Dim UM As String = GlobalDTUnidadesMedida(UsuarioActual.CveEmpresa).FiltroPrimeroValor("UnidadMedida", $" CveUnidadMedida = {CveUM} ")
|
||||||
|
|
||||||
|
Dim CveClasificacion As Integer = PsRow("CveClasificacion").ToString.ToEntero
|
||||||
|
Dim Clasificacion As String = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("Clasificacion", $" CveClasificacion = {CveClasificacion} ")
|
||||||
|
|
||||||
|
For Each row As DataRow In DT.Rows
|
||||||
|
Dim CveSubProyecto As Integer = GlobalDTSubProyectos(UsuarioActual.CveEmpresa).FiltroPrimeroValor("CveSubProyecto", $" SubProyecto = '{row("SubProyecto").ToString}' ").ToEntero
|
||||||
|
Dim Importe As Decimal = row("Importe").ToString.ToDecimal
|
||||||
|
AgregarProrrateoGasolina(CveSubProyecto, row("SubProyecto").ToString, CvePs, CveUM, UM, CveClasificacion, Clasificacion, PrecioProrrateo:=Importe)
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
|
||||||
|
Else
|
||||||
|
Alert(SBErrores.ToString, TipoMensaje.MsgAdvertencia)
|
||||||
|
End If
|
||||||
|
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
If Not ErrorProceso Then
|
||||||
|
TxtPrecioProrrateoGasolina.Text = ""
|
||||||
|
DdlSubProyectoProrrateoGasolina.SelectedValueExist(-1)
|
||||||
|
UpModalProrrateoGasolina.Update()
|
||||||
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
Return If(ErrorProceso, False, True)
|
||||||
|
|
||||||
|
End Function
|
||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -3538,7 +3538,12 @@ Partial Class PopUpVerFactura
|
|||||||
params.Add(New ReportParameter("Almacen", Almacen))
|
params.Add(New ReportParameter("Almacen", Almacen))
|
||||||
params.Add(New ReportParameter("Fecha", Fecha))
|
params.Add(New ReportParameter("Fecha", Fecha))
|
||||||
params.Add(New ReportParameter("FacturaProveedor", FolioVenta))
|
params.Add(New ReportParameter("FacturaProveedor", FolioVenta))
|
||||||
params.Add(New ReportParameter("FacturadoA", If(DtMovimientos(0)("Nombre").ToString <> "", DtMovimientos(0)("Nombre").ToString, NombreCliente)))
|
If NombreCliente = "" Then
|
||||||
|
params.Add(New ReportParameter("FacturadoA", Recibio))
|
||||||
|
Else
|
||||||
|
params.Add(New ReportParameter("FacturadoA", If(DtMovimientos(0)("Nombre").ToString <> "", DtMovimientos(0)("Nombre").ToString, NombreCliente)))
|
||||||
|
End If
|
||||||
|
|
||||||
params.Add(New ReportParameter("Observaciones", Observaciones))
|
params.Add(New ReportParameter("Observaciones", Observaciones))
|
||||||
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
params.Add(New ReportParameter("FechaImpresion", NowADS().ToString("dd/MM/yyyy")))
|
||||||
params.Add(New ReportParameter("Folio", Folio))
|
params.Add(New ReportParameter("Folio", Folio))
|
||||||
|
|||||||
@@ -345,7 +345,7 @@
|
|||||||
<Value>=Fields!Cantidad.Value</Value>
|
<Value>=Fields!Cantidad.Value</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontSize>7.5pt</FontSize>
|
<FontSize>7.5pt</FontSize>
|
||||||
<Format>0.000000;(0.000000)</Format>
|
<Format>#,0.######</Format>
|
||||||
</Style>
|
</Style>
|
||||||
</TextRun>
|
</TextRun>
|
||||||
</TextRuns>
|
</TextRuns>
|
||||||
@@ -1104,7 +1104,7 @@
|
|||||||
<Top>0.79361cm</Top>
|
<Top>0.79361cm</Top>
|
||||||
<Left>11.65255cm</Left>
|
<Left>11.65255cm</Left>
|
||||||
<Height>0.6cm</Height>
|
<Height>0.6cm</Height>
|
||||||
<Width>9.5262cm</Width>
|
<Width>9.15694cm</Width>
|
||||||
<ZIndex>4</ZIndex>
|
<ZIndex>4</ZIndex>
|
||||||
<Style>
|
<Style>
|
||||||
<Border>
|
<Border>
|
||||||
|
|||||||
@@ -826,13 +826,13 @@
|
|||||||
</Style>
|
</Style>
|
||||||
</Tablix>
|
</Tablix>
|
||||||
</ReportItems>
|
</ReportItems>
|
||||||
<Height>0.68252in</Height>
|
<Height>0.62002in</Height>
|
||||||
<Style />
|
<Style />
|
||||||
</Body>
|
</Body>
|
||||||
<Width>7.70923in</Width>
|
<Width>7.70923in</Width>
|
||||||
<Page>
|
<Page>
|
||||||
<PageHeader>
|
<PageHeader>
|
||||||
<Height>3.84568cm</Height>
|
<Height>4.16318cm</Height>
|
||||||
<PrintOnFirstPage>true</PrintOnFirstPage>
|
<PrintOnFirstPage>true</PrintOnFirstPage>
|
||||||
<PrintOnLastPage>true</PrintOnLastPage>
|
<PrintOnLastPage>true</PrintOnLastPage>
|
||||||
<ReportItems>
|
<ReportItems>
|
||||||
@@ -1011,7 +1011,7 @@
|
|||||||
<Value>=iif(Parameters!CveConcepto.Value = 8, "AVISO", "RECEPCIÓN") & " DE TRASLADO"</Value>
|
<Value>=iif(Parameters!CveConcepto.Value = 8, "AVISO", "RECEPCIÓN") & " DE TRASLADO"</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontFamily>Myriad Pro</FontFamily>
|
<FontFamily>Myriad Pro</FontFamily>
|
||||||
<FontSize>12pt</FontSize>
|
<FontSize>11pt</FontSize>
|
||||||
<FontWeight>Bold</FontWeight>
|
<FontWeight>Bold</FontWeight>
|
||||||
</Style>
|
</Style>
|
||||||
</TextRun>
|
</TextRun>
|
||||||
@@ -1045,7 +1045,7 @@
|
|||||||
<Value>=Parameters!SubProyecto.Value</Value>
|
<Value>=Parameters!SubProyecto.Value</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontFamily>Myriad Pro</FontFamily>
|
<FontFamily>Myriad Pro</FontFamily>
|
||||||
<FontSize>12pt</FontSize>
|
<FontSize>11pt</FontSize>
|
||||||
<FontWeight>Bold</FontWeight>
|
<FontWeight>Bold</FontWeight>
|
||||||
</Style>
|
</Style>
|
||||||
</TextRun>
|
</TextRun>
|
||||||
@@ -1057,7 +1057,7 @@
|
|||||||
<Top>3.24566cm</Top>
|
<Top>3.24566cm</Top>
|
||||||
<Left>0.00711cm</Left>
|
<Left>0.00711cm</Left>
|
||||||
<Height>0.6cm</Height>
|
<Height>0.6cm</Height>
|
||||||
<Width>14.27979cm</Width>
|
<Width>16.54562cm</Width>
|
||||||
<ZIndex>6</ZIndex>
|
<ZIndex>6</ZIndex>
|
||||||
<Style>
|
<Style>
|
||||||
<Border>
|
<Border>
|
||||||
|
|||||||
@@ -259,13 +259,14 @@
|
|||||||
<div class="col-md-2">
|
<div class="col-md-2">
|
||||||
<asp:TextBox ID="TxtGuia" runat="server" MaxLength="20" Width="100%"></asp:TextBox>
|
<asp:TextBox ID="TxtGuia" runat="server" MaxLength="20" Width="100%"></asp:TextBox>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-6" runat="server" id="TrResponsable">
|
|
||||||
<label class="col-md-1" style="width: 110px">Recibe:</label>
|
</div>
|
||||||
<div class="col-md-3">
|
<div class="row" id="TrResponsable" runat="server" visible="false" >
|
||||||
<asp:TextBox runat="server" Text="" ID="TxtResponsable" Width="100%" />
|
|
||||||
<%--<asp:DropDownList ID="DdlResponsable" runat="server" DataTextField="Nombre" DataValueField="CveUsuario" CssClass="form-control input-sm" Style="width: 200px !important;"></asp:DropDownList>--%>
|
<label class="col-md-1" style="width: 110px">Recibe:</label>
|
||||||
</div>
|
<div class="col-md-5">
|
||||||
</div>
|
<asp:TextBox runat="server" Text="" ID="TxtResponsable" Width="100%" ssClass="form-control input-sm" />
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|||||||
@@ -722,6 +722,8 @@ Partial Class Inventarios_EntradasSalidas
|
|||||||
DdlConcepto.DataSource = GlobalDTInvConceptos.FiltraParametros(IIf(UsuarioActual.CveEmpresa.Contiene(72, 80, 1), "CveConcepto NOT IN (4,5,10)", "CveConcepto NOT IN (1,2,4,5,8,9,10,12,26,27,29)").ToString)
|
DdlConcepto.DataSource = GlobalDTInvConceptos.FiltraParametros(IIf(UsuarioActual.CveEmpresa.Contiene(72, 80, 1), "CveConcepto NOT IN (4,5,10)", "CveConcepto NOT IN (1,2,4,5,8,9,10,12,26,27,29)").ToString)
|
||||||
DdlConcepto.DataBind()
|
DdlConcepto.DataBind()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
'Llenar el dropdownlist de almacén
|
'Llenar el dropdownlist de almacén
|
||||||
If Not IfNull(Request("CI"), -1).ToString.ToEntero > 0 AndAlso Not IfNull(Request("CveEntregaAlmacen"), -1).ToString.ToEntero > 0 Then
|
If Not IfNull(Request("CI"), -1).ToString.ToEntero > 0 AndAlso Not IfNull(Request("CveEntregaAlmacen"), -1).ToString.ToEntero > 0 Then
|
||||||
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1).FiltraParametros("CveTipoAlmacen NOT IN (9,11)") 'GlobalDTAlmacen(UsuarioActual.CveEmpresa)
|
DdlAlmacen.DataSource = GlobalDTAlmacenUsuarios(UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1).FiltraParametros("CveTipoAlmacen NOT IN (9,11)") 'GlobalDTAlmacen(UsuarioActual.CveEmpresa)
|
||||||
@@ -2589,6 +2591,9 @@ Partial Class Inventarios_EntradasSalidas
|
|||||||
|
|
||||||
|
|
||||||
If CveMovimiento > 0 And Not EsNuevoMov Then
|
If CveMovimiento > 0 And Not EsNuevoMov Then
|
||||||
|
If Not DdlConcepto.SelectedValue.Contiene("10", "28") Then
|
||||||
|
TrResponsable.Visible = True
|
||||||
|
End If
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -3693,7 +3693,7 @@ Partial Class OC_OC
|
|||||||
HuboError = True
|
HuboError = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim CveSubProyecto As Integer = UsuarioActual.CveSubProyecto
|
Dim CveSubProyecto As Integer = -1
|
||||||
|
|
||||||
If ModalidadSubProyectoGeneral Then
|
If ModalidadSubProyectoGeneral Then
|
||||||
CveSubProyecto = DdlSubProyectoGral.SelectedValue.ToEntero
|
CveSubProyecto = DdlSubProyectoGral.SelectedValue.ToEntero
|
||||||
@@ -3708,7 +3708,7 @@ Partial Class OC_OC
|
|||||||
PorcentajeIVA:=PorIVA, IVA:=IVACot, RetIVA:=RetIVA.ToString.ToDecimal, RetISR:=RetISR.ToString.ToDecimal, IDPoliza:=IdPoliza, CveCotizacion:=CveCotizacion, FolioAdicional:=TxtFolioAdicional.Text,
|
PorcentajeIVA:=PorIVA, IVA:=IVACot, RetIVA:=RetIVA.ToString.ToDecimal, RetISR:=RetISR.ToString.ToDecimal, IDPoliza:=IdPoliza, CveCotizacion:=CveCotizacion, FolioAdicional:=TxtFolioAdicional.Text,
|
||||||
EntregaDirecta:=If(ChkEntregaDirecta.Checked, 1, -1), CveDireccionEnvio:=If(DdlDireccionEnvio.Visible, DdlDireccionEnvio.SelectedValue.ToEntero, -1), IEPS:=TxtIEPS.Text.ToDecimal,
|
EntregaDirecta:=If(ChkEntregaDirecta.Checked, 1, -1), CveDireccionEnvio:=If(DdlDireccionEnvio.Visible, DdlDireccionEnvio.SelectedValue.ToEntero, -1), IEPS:=TxtIEPS.Text.ToDecimal,
|
||||||
CveIEAnticipo:=CveIEAnticipo, ImporteAnticipo:=ImporteAnticipos, Promocion:=Promocion, UsoCFDI:=DdlUsoCFDI.SelectedValue.ToEntero, NumRemision:=TxtNumRemision.Text.Trim, MetodoPago:=DdlMetodoPago.SelectedValue.ToEntero(),
|
CveIEAnticipo:=CveIEAnticipo, ImporteAnticipo:=ImporteAnticipos, Promocion:=Promocion, UsoCFDI:=DdlUsoCFDI.SelectedValue.ToEntero, NumRemision:=TxtNumRemision.Text.Trim, MetodoPago:=DdlMetodoPago.SelectedValue.ToEntero(),
|
||||||
CveSubProyectoEntrega:=DdlSubProyectoEntrega.SelectedValue.ToEntero, PorcentajeProntoPago:=PorcentajeProntoPago, DiasCreditoOC:=TxtDiasCreditoOC.Text.Toentero) Then
|
CveSubProyectoEntrega:=DdlSubProyectoEntrega.SelectedValue.ToEntero, PorcentajeProntoPago:=PorcentajeProntoPago, DiasCreditoOC:=TxtDiasCreditoOC.Text.ToEntero) Then
|
||||||
|
|
||||||
'CREA POLIZA POR CADA PROVEEDOR
|
'CREA POLIZA POR CADA PROVEEDOR
|
||||||
|
|
||||||
@@ -3777,7 +3777,7 @@ Partial Class OC_OC
|
|||||||
HuboError = True
|
HuboError = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim tCveSubProyecto As Integer = UsuarioActual.CveSubProyecto
|
Dim tCveSubProyecto As Integer = -1
|
||||||
If ModalidadSubProyectoGeneral Then tCveSubProyecto = DdlSubProyectoGral.SelectedValue.ToEntero
|
If ModalidadSubProyectoGeneral Then tCveSubProyecto = DdlSubProyectoGral.SelectedValue.ToEntero
|
||||||
If tCveSubProyecto <= 0 Then
|
If tCveSubProyecto <= 0 Then
|
||||||
tCveSubProyecto = GetCveSubProyectoDetalles()
|
tCveSubProyecto = GetCveSubProyectoDetalles()
|
||||||
|
|||||||
@@ -67,11 +67,9 @@
|
|||||||
<asp:ListItem Text="GlobalDTAC" Value="GlobalDTAC"></asp:ListItem>
|
<asp:ListItem Text="GlobalDTAC" Value="GlobalDTAC"></asp:ListItem>
|
||||||
<asp:ListItem Text="GlobalDTSATUsosCFDI" Value="GlobalDTSATUsosCFDI"></asp:ListItem>
|
<asp:ListItem Text="GlobalDTSATUsosCFDI" Value="GlobalDTSATUsosCFDI"></asp:ListItem>
|
||||||
<asp:ListItem Text="GlobalDTVtaCondicionesEntrega" Value="GlobalDTVtaCondicionesEntrega"></asp:ListItem>
|
<asp:ListItem Text="GlobalDTVtaCondicionesEntrega" Value="GlobalDTVtaCondicionesEntrega"></asp:ListItem>
|
||||||
<<<<<<< HEAD
|
<asp:ListItem Text="GlobalDTTipoVenta" Value="GlobalDTTipoVenta"></asp:ListItem>
|
||||||
<asp:ListItem Text="GlobalDTTipoVenta" Value="GlobalDTTipoVenta"></asp:ListItem>
|
|
||||||
=======
|
|
||||||
<asp:ListItem Text="GlobalDTDIOTTipoOperacion" Value="GlobalDTDIOTTipoOperacion"></asp:ListItem>
|
<asp:ListItem Text="GlobalDTDIOTTipoOperacion" Value="GlobalDTDIOTTipoOperacion"></asp:ListItem>
|
||||||
>>>>>>> 5f99bce007430083b8e29bf39512f4aa4b51efae
|
|
||||||
|
|
||||||
|
|
||||||
</asp:DropDownList>
|
</asp:DropDownList>
|
||||||
|
|||||||
@@ -111,13 +111,10 @@ Partial Class Sistemas_CatSesiones
|
|||||||
CargaUsosCFDI()
|
CargaUsosCFDI()
|
||||||
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTVtaCondicionesEntrega" Then
|
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTVtaCondicionesEntrega" Then
|
||||||
CargaCondicionesEntrega()
|
CargaCondicionesEntrega()
|
||||||
<<<<<<< HEAD
|
|
||||||
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTTipoVenta" Then
|
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTTipoVenta" Then
|
||||||
CargaTipoVenta()
|
CargaTipoVenta()
|
||||||
=======
|
|
||||||
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTDIOTTipoOperacion" Then
|
ElseIf DdlVariable.SelectedItem.Value = "GlobalDTDIOTTipoOperacion" Then
|
||||||
CargaDIOTTipoOperacion()
|
CargaDIOTTipoOperacion()
|
||||||
>>>>>>> 5f99bce007430083b8e29bf39512f4aa4b51efae
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -368,7 +368,7 @@
|
|||||||
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" Width="100%"
|
<asp:GridView ID="GvDatos" runat="server" AutoGenerateColumns="False" Width="100%"
|
||||||
EmptyDataText="No se encontraron Ventas con los filtros especificados" data-sort="true" ToolTip="Listado de Ventas"
|
EmptyDataText="No se encontraron Ventas con los filtros especificados" data-sort="true" ToolTip="Listado de Ventas"
|
||||||
CssClass="ScrollAD table table-striped table-hover Widthall mysmallbtn" data-heighterror="320" data-freezecols="0" data-freezerows="0" GridLines="None"
|
CssClass="ScrollAD table table-striped table-hover Widthall mysmallbtn" data-heighterror="320" data-freezecols="0" data-freezerows="0" GridLines="None"
|
||||||
DataKeyNames="CveVenta,CveCliente,TipoDocto,Saldo,AtencionA,CveFormaPago33,SerieFolio,CondicionesPago,PlazoCobranza">
|
DataKeyNames="CveVenta,CveCliente,TipoDocto,Saldo,AtencionA,CveFormaPago33,SerieFolio,CondicionesPago,PlazoCobranza,CveMoneda,Moneda">
|
||||||
<Columns>
|
<Columns>
|
||||||
<%--<asp:BoundField HeaderText="Atención" DataField="AtencionA" />--%>
|
<%--<asp:BoundField HeaderText="Atención" DataField="AtencionA" />--%>
|
||||||
<asp:TemplateField HeaderText="Atención/Cliente" ItemStyle-HorizontalAlign="Left" ItemStyle-Width="25%">
|
<asp:TemplateField HeaderText="Atención/Cliente" ItemStyle-HorizontalAlign="Left" ItemStyle-Width="25%">
|
||||||
@@ -481,36 +481,29 @@
|
|||||||
<div class="col-md-7">
|
<div class="col-md-7">
|
||||||
<asp:Panel runat="server" ID="PnlContado" DefaultButton="BtnPagar" Visible="false">
|
<asp:Panel runat="server" ID="PnlContado" DefaultButton="BtnPagar" Visible="false">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
|
|
||||||
<div class="note note-success">
|
<div class="note note-success">
|
||||||
<div class="row">
|
<div class="row" style="display: flex;">
|
||||||
<div class="col-md-2">
|
<div class="col-md-1"><b>Nombre:</b></div>
|
||||||
<b>Nombre:</b>
|
|
||||||
</div>
|
|
||||||
<div class="col-md-4"> <label><asp:Literal ID="LtlNombre" runat="server"></asp:Literal></label> </div>
|
<div class="col-md-4"> <label><asp:Literal ID="LtlNombre" runat="server"></asp:Literal></label> </div>
|
||||||
|
<div class="col-md-2"><b>Folio:</b> <label><asp:Literal ID="LtlFolio" runat="server"></asp:Literal></label> </div>
|
||||||
<div class="col-md-1"><b>Folio:</b></div>
|
<div class="col-md-4">
|
||||||
<div class="col-md-2"> <label><asp:Literal ID="LtlFolio" runat="server"></asp:Literal></label> </div>
|
|
||||||
|
|
||||||
<div class="col-md-1">
|
|
||||||
<b>
|
<b>
|
||||||
<asp:Literal ID="LtLTipoSaldo" runat="server" Text="Total:"></asp:Literal></b>
|
<asp:Literal ID="LtLTipoSaldo" runat="server" Text="Total:"></asp:Literal>
|
||||||
</div>
|
</b>
|
||||||
<div class="col-md-1">
|
|
||||||
<b>
|
<asp:Literal ID="LtlSaldo" runat="server" Text=""></asp:Literal>
|
||||||
<asp:TextBox ID="LtlSaldo" runat="server" Enabled="true" CssClass="TextBoxAsLabel" BorderStyle="None" BackColor="Transparent" ForeColor="#3c763d" Style="text-align: left"></asp:TextBox>
|
|
||||||
</b>
|
<b>
|
||||||
|
<asp:Literal ID="LtlMoneda" runat="server"></asp:Literal></b>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-1" style="text-align: right;">
|
<div class="col-md-1" style="text-align: right;">
|
||||||
<asp:LinkButton ID="LnkLiberar" runat="server" CssClass="btn btn-xs btn-success" Text="Liberar" OnClick="LnkLiberar_Click" />
|
<asp:LinkButton ID="LnkLiberar" runat="server" CssClass="btn btn-xs btn-success" Text="Liberar" OnClick="LnkLiberar_Click" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div>
|
<div>
|
||||||
|
|
||||||
<div runat="server" id="DivContadoBancos" class="row" visible="True">
|
<div runat="server" id="DivContadoBancos" class="row" visible="True">
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<div class="chequesie1">
|
<div class="chequesie1">
|
||||||
@@ -682,7 +675,7 @@
|
|||||||
<div class="chequesie2">
|
<div class="chequesie2">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-4" style="display: flex; align-items: center;">
|
<div class="col-md-4" style="display: flex; align-items: center;">
|
||||||
<label style="font-weight: bold; font-size: medium;">Total:</label>
|
<label style="font-weight: bold; font-size: 13px;width: 90px;">Total:</label>
|
||||||
<div class="input-icon">
|
<div class="input-icon">
|
||||||
<i style="margin: 0px;">$</i>
|
<i style="margin: 0px;">$</i>
|
||||||
<asp:TextBox ID="TxtImporteContado" CssClass="form-control input-sm " runat="server" MaxLength="12" Width="100%" ReadOnly="true" ClientIDMode="Static" Style="text-align: right; font-size: 14px;"></asp:TextBox>
|
<asp:TextBox ID="TxtImporteContado" CssClass="form-control input-sm " runat="server" MaxLength="12" Width="100%" ReadOnly="true" ClientIDMode="Static" Style="text-align: right; font-size: 14px;"></asp:TextBox>
|
||||||
@@ -692,7 +685,7 @@
|
|||||||
<div class="col-md-8">
|
<div class="col-md-8">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-5" style="display: flex; align-items: center;">
|
<div class="col-md-5" style="display: flex; align-items: center;">
|
||||||
<label id="lblCambio" runat="server" style="font-weight: bold; font-size: medium;">Cambio:</label>
|
<label id="lblCambio" runat="server" style="font-weight: bold; font-size: 13px;width: 60px;">Cambio:</label>
|
||||||
<div class="input-icon">
|
<div class="input-icon">
|
||||||
<i style="margin: 0px;">$</i>
|
<i style="margin: 0px;">$</i>
|
||||||
<asp:HiddenField ID="HdnSobranteFaltante" Value="0" ClientIDMode="Static" runat="server" />
|
<asp:HiddenField ID="HdnSobranteFaltante" Value="0" ClientIDMode="Static" runat="server" />
|
||||||
@@ -701,7 +694,7 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="col-md-7" style="display: flex; align-items: center;">
|
<div class="col-md-7" style="display: flex; align-items: center;">
|
||||||
<label style="font-weight: bold; font-size: medium;">Sob/falt:</label>
|
<label style="font-weight: bold; font-size: 13px;">Sob/falt:</label>
|
||||||
|
|
||||||
<asp:CheckBox ID="ChkSobFaltante" runat="server" ClientIDMode="Static" />
|
<asp:CheckBox ID="ChkSobFaltante" runat="server" ClientIDMode="Static" />
|
||||||
<div class="input-icon" style="margin-left: 20px;">
|
<div class="input-icon" style="margin-left: 20px;">
|
||||||
@@ -713,6 +706,25 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
<br />
|
||||||
|
<div id="DivUSD" runat="server" class="row" visible="false">
|
||||||
|
<div class="col-md-4" style="display: flex; align-items: center;">
|
||||||
|
<label style="font-weight: bold; font-size: 13px;width: 90px;">Total (MXN):</label>
|
||||||
|
<div class="input-icon">
|
||||||
|
<i style="margin: 0px;">$</i>
|
||||||
|
<asp:TextBox ID="TxtTotalMXN" CssClass="form-control input-sm " runat="server" MaxLength="12" Width="100%" ReadOnly="true" ClientIDMode="Static" Style="text-align: right; font-size: 14px;"></asp:TextBox>
|
||||||
|
<ajax:FilteredTextBoxExtender ID="FTETotalMXN" runat="server" TargetControlID="TxtTotalMXN" FilterType="Custom, Numbers" ValidChars=".," />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-4" style="display: flex; align-items: center;">
|
||||||
|
<label style="font-weight: bold; font-size: 13px; width: 60px;">TC:</label>
|
||||||
|
<div class="input-icon">
|
||||||
|
<i style="margin: 0px;">$</i>
|
||||||
|
<asp:TextBox ID="TxtTC" CssClass="form-control input-sm " runat="server" MaxLength="12" Width="100px" ReadOnly="false" ClientIDMode="Static" Style="text-align: right; font-size: 14px;"></asp:TextBox>
|
||||||
|
<ajax:FilteredTextBoxExtender ID="FTETC" runat="server" TargetControlID="TxtTC" FilterType="Custom, Numbers" ValidChars=".," />
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
@@ -727,6 +739,7 @@
|
|||||||
<asp:HiddenField ID="HdnVentaCondicionesPago" runat="server" />
|
<asp:HiddenField ID="HdnVentaCondicionesPago" runat="server" />
|
||||||
<asp:HiddenField ID="HdnCveIE" runat="server" />
|
<asp:HiddenField ID="HdnCveIE" runat="server" />
|
||||||
<asp:HiddenField ID="HdnTotal" runat="server" ClientIDMode="Static" />
|
<asp:HiddenField ID="HdnTotal" runat="server" ClientIDMode="Static" />
|
||||||
|
<asp:HiddenField ID="HdnMoneda" runat="server" ClientIDMode="Static" Value="1" />
|
||||||
<asp:Button ID="BtnPagar" CssClass="btn btn-large btn-success e-big-btn" runat="server" Text="Pagar" />
|
<asp:Button ID="BtnPagar" CssClass="btn btn-large btn-success e-big-btn" runat="server" Text="Pagar" />
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
@@ -1609,6 +1622,12 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
$get("TxtImporteContado").value = FormatoNumero(total, 2);
|
$get("TxtImporteContado").value = FormatoNumero(total, 2);
|
||||||
|
|
||||||
|
//DOLARES
|
||||||
|
if ($get("HdnMoneda").value == "2") {
|
||||||
|
$get("TxtTotalMXN").value = FormatoNumero(ToDouble($get('TxtImporteContado').value) * ToDouble($get('TxtTC').value), 2);
|
||||||
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
function CalculaDiferencia() {
|
function CalculaDiferencia() {
|
||||||
|
|||||||
@@ -517,6 +517,17 @@ Partial Class Ventas_PVCobranza
|
|||||||
LtlNombre.Text = GvRow.DataKey("AtencionA")
|
LtlNombre.Text = GvRow.DataKey("AtencionA")
|
||||||
LtlFolio.Text = GvRow.DataKey("SerieFolio")
|
LtlFolio.Text = GvRow.DataKey("SerieFolio")
|
||||||
LtlSaldo.Text = GvRow.DataKey("Saldo").ToDecimal.FormatoNumero
|
LtlSaldo.Text = GvRow.DataKey("Saldo").ToDecimal.FormatoNumero
|
||||||
|
LtlMoneda.Text = GvRow.DataKey("Moneda")
|
||||||
|
|
||||||
|
Dim CveMoneda As Integer = GvRow.DataKey("CveMoneda").ToEntero()
|
||||||
|
|
||||||
|
HdnMoneda.Value = CveMoneda.ToString()
|
||||||
|
If CveMoneda = 2 Then
|
||||||
|
DivUSD.Visible = True
|
||||||
|
TxtTC.Text = GlobalTipoCambio(Now).ToString()
|
||||||
|
TxtTotalMXN.Text = (TxtImporteContado.Text.ToDecimal() * TxtTC.Text.ToDecimal()).FormatoNumero()
|
||||||
|
End If
|
||||||
|
|
||||||
HdnVentaCondicionesPago.Value = GvRow.DataKey("CondicionesPago")
|
HdnVentaCondicionesPago.Value = GvRow.DataKey("CondicionesPago")
|
||||||
HdnPlazoCobranza.Value = GvRow.DataKey("PlazoCobranza")
|
HdnPlazoCobranza.Value = GvRow.DataKey("PlazoCobranza")
|
||||||
|
|
||||||
@@ -1262,6 +1273,11 @@ Partial Class Ventas_PVCobranza
|
|||||||
LtlTipoAnticipo.Text = ""
|
LtlTipoAnticipo.Text = ""
|
||||||
TxtFaltante.Text = ""
|
TxtFaltante.Text = ""
|
||||||
ChkSobFaltante.Checked = False
|
ChkSobFaltante.Checked = False
|
||||||
|
LtlMoneda.Text = ""
|
||||||
|
TxtTC.Text = ""
|
||||||
|
TxtTotalMXN.Text = ""
|
||||||
|
DivUSD.Visible = False
|
||||||
|
HdnMoneda.Value = "1"
|
||||||
'HdnTipoAmortizacion.Value = ""
|
'HdnTipoAmortizacion.Value = ""
|
||||||
CveCliente = -1
|
CveCliente = -1
|
||||||
CveVendedor = -1
|
CveVendedor = -1
|
||||||
@@ -1318,7 +1334,7 @@ Partial Class Ventas_PVCobranza
|
|||||||
ObjFactura.CveMoneda = VentaRemision.CveMoneda
|
ObjFactura.CveMoneda = VentaRemision.CveMoneda
|
||||||
|
|
||||||
If ObjFactura.CveMoneda = 2 Then
|
If ObjFactura.CveMoneda = 2 Then
|
||||||
ObjFactura.TipoCambio = GlobalTipoCambio(Now).ToString().ToDecimal()
|
ObjFactura.TipoCambio = TxtTC.Text.ToDecimal()
|
||||||
Else
|
Else
|
||||||
ObjFactura.TipoCambio = 1
|
ObjFactura.TipoCambio = 1
|
||||||
End If
|
End If
|
||||||
@@ -1699,6 +1715,9 @@ Partial Class Ventas_PVCobranza
|
|||||||
Dim CveIEPago As Integer = 0
|
Dim CveIEPago As Integer = 0
|
||||||
Dim ErrorConta As Boolean
|
Dim ErrorConta As Boolean
|
||||||
|
|
||||||
|
Dim CveMonedaVenta As Integer = VentaActual.CveMoneda
|
||||||
|
Dim CveMonedaPago As Integer = CveMonedaVenta
|
||||||
|
|
||||||
If String.IsNullOrEmpty(Obs) Then
|
If String.IsNullOrEmpty(Obs) Then
|
||||||
Obs = $"Folio: {VentaActual.SerieFolio}"
|
Obs = $"Folio: {VentaActual.SerieFolio}"
|
||||||
Else
|
Else
|
||||||
@@ -1750,7 +1769,7 @@ Partial Class Ventas_PVCobranza
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
If String.IsNullOrEmpty(Retorno) Then
|
If String.IsNullOrEmpty(Retorno) Then
|
||||||
CveIEPago = ObjIE.AddBancos_IE(CveBancoCuenta, Metodo, Fecha, "-1", VentaActual.ClienteNombre, ImporteIE, 1, 1, Obs, "", False, True, 0, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCorte:=tCveCorte, CveAutorizacion:=CveAutorizacion, CveSubProyecto:=CveSubProyecto)
|
CveIEPago = ObjIE.AddBancos_IE(CveBancoCuenta, Metodo, Fecha, "-1", VentaActual.ClienteNombre, ImporteIE, CveMonedaPago, If(CveMonedaVenta = 1, 1, TxtTC.Text.ToDecimal()), Obs, "", False, True, 0, CvePrePoliza, "", UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, CveCorte:=tCveCorte, CveAutorizacion:=CveAutorizacion, CveSubProyecto:=CveSubProyecto, Modulo:="PVCob")
|
||||||
If CveIEPago > 0 Then
|
If CveIEPago > 0 Then
|
||||||
Dim tImportePago As Decimal = If(ImporteBancos > ImporteAbonoVenta, ImporteAbonoVenta, ImporteBancos) 'toma el importe menor para la factura
|
Dim tImportePago As Decimal = If(ImporteBancos > ImporteAbonoVenta, ImporteAbonoVenta, ImporteBancos) 'toma el importe menor para la factura
|
||||||
|
|
||||||
@@ -1759,10 +1778,10 @@ Partial Class Ventas_PVCobranza
|
|||||||
Pago.ImportePagoVenta = tImportePago
|
Pago.ImportePagoVenta = tImportePago
|
||||||
Pago.ImportePago = ImporteIE
|
Pago.ImportePago = ImporteIE
|
||||||
Pago.CveIE = CveIEPago
|
Pago.CveIE = CveIEPago
|
||||||
Pago.CveMonedaPago = VentaActual.CveMoneda
|
Pago.CveMonedaPago = CveMonedaPago ' EL PAGO SIEMRE DEBE SER EN PESOS
|
||||||
Pago.Fecha = NowADS()
|
Pago.Fecha = NowADS()
|
||||||
Pago.Referencia = VentaActual.SerieFolio
|
Pago.Referencia = VentaActual.SerieFolio
|
||||||
If Pago.CveMonedaPago > 1 Then Pago.TCPago = GlobalTipoCambio(Now).ToDecimal
|
Pago.TCPago = If(CveMonedaVenta = 1, 1, TxtTC.Text.ToDecimal())
|
||||||
|
|
||||||
ErrorConta = AplicaPrePolizaPagoVenta(VentaActual, Pago, CvePrePoliza, ObjConta)
|
ErrorConta = AplicaPrePolizaPagoVenta(VentaActual, Pago, CvePrePoliza, ObjConta)
|
||||||
End If
|
End If
|
||||||
@@ -3092,6 +3111,9 @@ Partial Class Ventas_PVCobranza
|
|||||||
Next
|
Next
|
||||||
TxtCxCAplicado.Text = (SaldoCxC).FormatoNumero
|
TxtCxCAplicado.Text = (SaldoCxC).FormatoNumero
|
||||||
TxtImporteContado.Text = (LtlSaldo.Text.ToDecimal + SaldoCxC).FormatoNumero
|
TxtImporteContado.Text = (LtlSaldo.Text.ToDecimal + SaldoCxC).FormatoNumero
|
||||||
|
If DivUSD.Visible Then
|
||||||
|
TxtTotalMXN.Text = (TxtImporteContado.Text.ToDecimal() * TxtTC.Text.ToDecimal()).FormatoNumero()
|
||||||
|
End If
|
||||||
RegistraScript("$('#divCxC').hide();", "AE21")
|
RegistraScript("$('#divCxC').hide();", "AE21")
|
||||||
UPPCobranza.Update()
|
UPPCobranza.Update()
|
||||||
UPPTotalesContado.Update()
|
UPPTotalesContado.Update()
|
||||||
|
|||||||
@@ -301,9 +301,6 @@ Partial Class Ventas_RepVentas
|
|||||||
Dim Vendedores As String = If(DdlVendedor.GetSelectedValuesM = "", "-1", DdlVendedor.GetSelectedValuesM)
|
Dim Vendedores As String = If(DdlVendedor.GetSelectedValuesM = "", "-1", DdlVendedor.GetSelectedValuesM)
|
||||||
Dim CveCliente As Integer = If(DdlClientes.SelectedValue = "", -1, DdlClientes.SelectedValue.ToEntero)
|
Dim CveCliente As Integer = If(DdlClientes.SelectedValue = "", -1, DdlClientes.SelectedValue.ToEntero)
|
||||||
|
|
||||||
If TipoComprobante.Contiene("Rem") And Not Estatus.Contiene("11") Then
|
|
||||||
Estatus = Estatus & ",11"
|
|
||||||
End If
|
|
||||||
|
|
||||||
If RblTipoCambio.SelectedValue.ToEntero = 3 And TxtEspecifico.Text <> "" Then
|
If RblTipoCambio.SelectedValue.ToEntero = 3 And TxtEspecifico.Text <> "" Then
|
||||||
TCEspecifico = TxtEspecifico.Text.ToDecimal
|
TCEspecifico = TxtEspecifico.Text.ToDecimal
|
||||||
|
|||||||
@@ -459,10 +459,6 @@ Partial Class RepVentasDetalle
|
|||||||
FechaIEjec = If(IsDate(TxtFechaIEjec.Text.Trim()), TxtFechaIEjec.Text.Trim.ToDate, MinFecha)
|
FechaIEjec = If(IsDate(TxtFechaIEjec.Text.Trim()), TxtFechaIEjec.Text.Trim.ToDate, MinFecha)
|
||||||
FechaFEjec = If(IsDate(TxtFechaFEjec.Text.Trim()), TxtFechaFEjec.Text.Trim.ToDate, MaxFecha)
|
FechaFEjec = If(IsDate(TxtFechaFEjec.Text.Trim()), TxtFechaFEjec.Text.Trim.ToDate, MaxFecha)
|
||||||
|
|
||||||
If TipoComprobante.Contiene("Rem") And Not Estatus.Contiene("11") Then
|
|
||||||
Estatus = Estatus & ",11"
|
|
||||||
End If
|
|
||||||
|
|
||||||
Dim ModalidadContable As Boolean = CBool(If(Request("ModalidadContable") IsNot Nothing, Request("ModalidadContable").ToEntero(), 0))
|
Dim ModalidadContable As Boolean = CBool(If(Request("ModalidadContable") IsNot Nothing, Request("ModalidadContable").ToEntero(), 0))
|
||||||
|
|
||||||
ChkLecturaAdmin.Checked = Not ModalidadContable
|
ChkLecturaAdmin.Checked = Not ModalidadContable
|
||||||
|
|||||||
@@ -10670,6 +10670,10 @@ Partial Class Ventas
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If Not ValidaPSSoloCotizacion() Then
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
|
||||||
'CREA UNA COPIA DE SEGURIDAD PARA LOS DATOS DEL TMPDT
|
'CREA UNA COPIA DE SEGURIDAD PARA LOS DATOS DEL TMPDT
|
||||||
If TmpDTError Is Nothing OrElse TmpDTError.Rows.Count = 0 Then
|
If TmpDTError Is Nothing OrElse TmpDTError.Rows.Count = 0 Then
|
||||||
TmpDTError = TmpDT.Copy()
|
TmpDTError = TmpDT.Copy()
|
||||||
@@ -19914,6 +19918,36 @@ Partial Class Ventas
|
|||||||
Protected Sub LbAgregar_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles LbAgregar.Click
|
Protected Sub LbAgregar_Click(ByVal sender As Object, ByVal e As System.EventArgs) Handles LbAgregar.Click
|
||||||
AgregarPS()
|
AgregarPS()
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Private Function ValidaPSSoloCotizacion() As Boolean
|
||||||
|
Dim Returno As Boolean = True
|
||||||
|
If UsuarioActual.Empresa.Funcionalidad(720) <> "" AndAlso DdlTipoComprobante.SelectedValue <> "Cot" Then
|
||||||
|
Dim ProductosSoloCotizacion As List(Of String) = UsuarioActual.Empresa.Funcionalidad(720).Split(","c).ToList()
|
||||||
|
|
||||||
|
If ProductosSoloCotizacion IsNot Nothing AndAlso ProductosSoloCotizacion.Count > 0 Then
|
||||||
|
|
||||||
|
For Each GvRow As GridViewRow In GvPS.Rows
|
||||||
|
If GvRow.RowType = DataControlRowType.DataRow Then
|
||||||
|
Dim CvePS As String = GvRow.DataKey("CvePS")
|
||||||
|
If ProductosSoloCotizacion.Any(Function(CvePSCot) CvePSCot.Trim() = CvePS) Then
|
||||||
|
Dim PSCot As String = ""
|
||||||
|
Dim DrPSCot As DataRow = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CvePS:=CvePS.ToEntero()).Rows(0)
|
||||||
|
If DrPSCot IsNot Nothing Then
|
||||||
|
PSCot = DrPSCot("PSCodigo").ToString
|
||||||
|
End If
|
||||||
|
|
||||||
|
Alert($"El producto y/o servicio '{PSCot}' está disponible únicamente para cotizaciones.", TipoMensaje.MsgAdvertencia)
|
||||||
|
Returno = False
|
||||||
|
Exit For
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
Next
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return Returno
|
||||||
|
End Function
|
||||||
|
|
||||||
Private Function ValidaAgregarPS(Cantidad As Decimal, CvePS As Integer, CveUM As Integer, PU As Double, CveTipoPS As Integer, CveClasificacion As Integer, CveSubProyecto As Integer, ObjDescuento As Modelos.VentaDescuentos, Optional CantidadModal As Decimal = 0D, Optional PSValidarModal As String = "", Optional CantidadOriginal As Decimal = 0D, Optional EsEdicion As Boolean = False) As Boolean 'NO TOCAR - IPP
|
Private Function ValidaAgregarPS(Cantidad As Decimal, CvePS As Integer, CveUM As Integer, PU As Double, CveTipoPS As Integer, CveClasificacion As Integer, CveSubProyecto As Integer, ObjDescuento As Modelos.VentaDescuentos, Optional CantidadModal As Decimal = 0D, Optional PSValidarModal As String = "", Optional CantidadOriginal As Decimal = 0D, Optional EsEdicion As Boolean = False) As Boolean 'NO TOCAR - IPP
|
||||||
|
|
||||||
'VALIDA PARAMETROS
|
'VALIDA PARAMETROS
|
||||||
@@ -19922,6 +19956,23 @@ Partial Class Ventas
|
|||||||
Return False
|
Return False
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
'VALIDA PS DE COTIZACION
|
||||||
|
If UsuarioActual.Empresa.Funcionalidad(720) <> "" Then
|
||||||
|
Dim ProductosSoloCotizacion As List(Of String) = UsuarioActual.Empresa.Funcionalidad(720).Split(","c).ToList()
|
||||||
|
If ProductosSoloCotizacion IsNot Nothing AndAlso ProductosSoloCotizacion.Count > 0 Then
|
||||||
|
If DdlTipoComprobante.SelectedValue <> "Cot" AndAlso ProductosSoloCotizacion.Any(Function(CvePSCot) CvePSCot.Trim() = CvePS.ToString()) Then
|
||||||
|
Dim PSCot As String = ""
|
||||||
|
Dim DrPSCot As DataRow = GlobalDTPSSimplificado(UsuarioActual.CveEmpresa, CvePS:=CvePS).Rows(0)
|
||||||
|
If DrPSCot IsNot Nothing Then
|
||||||
|
PSCot = DrPSCot("PSCodigo").ToString
|
||||||
|
End If
|
||||||
|
|
||||||
|
Alert($"El producto y/o servicio '{PSCot}' está disponible únicamente para cotizaciones.", TipoMensaje.MsgAdvertencia)
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
If PSValidarModal.Trim.Length > 0 Then
|
If PSValidarModal.Trim.Length > 0 Then
|
||||||
HdnPS.Value = PSValidarModal
|
HdnPS.Value = PSValidarModal
|
||||||
End If
|
End If
|
||||||
|
|||||||
Reference in New Issue
Block a user