Merge branch 'master' of http://oirigoyen@192.168.10.111:8383/SIG.git
This commit is contained in:
@@ -67,6 +67,42 @@
|
|||||||
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
||||||
</asp:Content>
|
</asp:Content>
|
||||||
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
|
<asp:Content ID="Content7" ContentPlaceHolderID="C" runat="Server">
|
||||||
|
<asp:UpdatePanel runat="server" ID="UpFiltros" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<asp:Panel ID="Panel1" runat="server" DefaultButton="BtnConsultar">
|
||||||
|
<div class="portlet solid grey-cascade portlet-filter">
|
||||||
|
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 49px;">
|
||||||
|
<div class="tools">
|
||||||
|
<asp:Button Text="Consultar" ID="BtnConsultar" CssClass="btn btn-primary" OnClick="BtnConsultar_Click" runat="server" />
|
||||||
|
</div>
|
||||||
|
<div class="titlefiltros caption ">
|
||||||
|
<div class="row" style="padding-top: 10px;">
|
||||||
|
<label class="col-md-1 truncate">Tipo Folio:</label>
|
||||||
|
<div class="col-md-2 ">
|
||||||
|
<%-- <asp:DropDownList ID="DdlSucursal" runat="server" CssClass="select2me" DataTextField="Sucursal" DataValueField="CveSucursal" Width="200px" ValidationGroup="GrpGuardar"></asp:DropDownList>--%>
|
||||||
|
<asp:DropDownList ID="DdlTipoFolio" runat="server" CssClass="select2me" Width="100px" ValidationGroup="GrpGuardar">
|
||||||
|
<asp:ListItem Text="Todos" Value="-1" Selected="True"></asp:ListItem>
|
||||||
|
<asp:ListItem Value="general" >general</asp:ListItem>
|
||||||
|
<asp:ListItem Value="optima">optima</asp:ListItem>
|
||||||
|
<asp:ListItem Value="motobateria">motobateria</asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
<label class="col-md-1 truncate">Estatus:</label>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<asp:DropDownList ID="DdlEstatus" runat="server" CssClass="select2me" Width="100px" ValidationGroup="GrpGuardar">
|
||||||
|
<asp:ListItem Text="Todos" Value="-1" Selected="True"></asp:ListItem>
|
||||||
|
<asp:ListItem Text="Activo" Value="1"></asp:ListItem>
|
||||||
|
<asp:ListItem Text="Inactivo" Value="0"></asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</asp:Panel>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
<br />
|
||||||
<asp:UpdatePanel ID="UpGral" runat="server" UpdateMode="Conditional">
|
<asp:UpdatePanel ID="UpGral" runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
|
|
||||||
@@ -77,12 +113,12 @@
|
|||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="row" style="margin:5px">
|
<div class="row" style="margin: 5px">
|
||||||
<asp:UpdatePanel ID="UPGvFolioGarantia" runat="server" UpdateMode="Conditional">
|
<asp:UpdatePanel ID="UPGvFolioGarantia" runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
|
|
||||||
<asp:GridView ID="GvFolioGarantia" runat="server" AutoGenerateColumns="False"
|
<asp:GridView ID="GvFolioGarantia" runat="server" AutoGenerateColumns="False"
|
||||||
DataKeyNames="CveFolioGarantia,FolioGarantia,Estatus,CveUsuario,Usuario,FechaIng,SubProyecto,CveSubProyecto"
|
DataKeyNames="CveFolioGarantia,FolioGarantia,Estatus,CveUsuario,Usuario,FechaIng,SubProyecto,CveSubProyecto,tipoFolio,Limite"
|
||||||
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
|
EmptyDataText="No se encontraron registros" ToolTip="Listado de Temas"
|
||||||
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
|
CssClass="table table-striped table-advance table-hover Widthall ScrollAD"
|
||||||
data-sort="true"
|
data-sort="true"
|
||||||
@@ -94,7 +130,16 @@
|
|||||||
<asp:Literal ID="LblFolioGarantia" runat="server" Text='<%# Eval("FolioGarantia") %>'></asp:Literal>
|
<asp:Literal ID="LblFolioGarantia" runat="server" Text='<%# Eval("FolioGarantia") %>'></asp:Literal>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Tipo Folio">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Literal ID="LblTipoFolio" runat="server" Text='<%# Eval("tipoFolio") %>'></asp:Literal>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Limite">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Literal ID="LblLimite" runat="server" Text='<%# Eval("Limite") %>'></asp:Literal>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="SubProyecto" ItemStyle-Width="150px">
|
<asp:TemplateField HeaderText="SubProyecto" ItemStyle-Width="150px">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:Literal ID="LblSubProyecto" runat="server" Text='<%# Eval("SubProyecto")%>'></asp:Literal>
|
<asp:Literal ID="LblSubProyecto" runat="server" Text='<%# Eval("SubProyecto")%>'></asp:Literal>
|
||||||
@@ -216,10 +261,27 @@
|
|||||||
|
|
||||||
<div class="form-group form-md-line-input input-iconright">
|
<div class="form-group form-md-line-input input-iconright">
|
||||||
<label for="<%= ChkEstatus.ClientID.ToString()%>">Activo:</label>
|
<label for="<%= ChkEstatus.ClientID.ToString()%>">Activo:</label>
|
||||||
|
|
||||||
<asp:CheckBox ID="ChkEstatus" runat="server" CssClass="make-switchsd" data-size="small" Text=" " Checked="true" />
|
<asp:CheckBox ID="ChkEstatus" runat="server" CssClass="make-switchsd" data-size="small" Text=" " Checked="true" />
|
||||||
<i></i>
|
<i></i>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<div class="form-group form-md-line-input input-iconright">
|
||||||
|
<label for="<%= DdlTipoFolioModal.ClientID.ToString()%>">Tipo Folio:</label>
|
||||||
|
<asp:DropDownList ID="DdlTipoFolioModal" runat="server" CssClass="select2me" Width="100px" ValidationGroup="GrpGuardar">
|
||||||
|
<asp:ListItem Value="general" Selected ="True">general</asp:ListItem>
|
||||||
|
<asp:ListItem Value="optima">optima</asp:ListItem>
|
||||||
|
<asp:ListItem Value="motobateria">motobateria</asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
<i></i>
|
||||||
|
</div>
|
||||||
|
<br />
|
||||||
|
<div class="form-group form-md-line-input input-iconright">
|
||||||
|
<asp:TextBox ID="TxtLimite" CssClass="form-control " runat="server" MaxLength="70" CausesValidation="true"></asp:TextBox>
|
||||||
|
<asp:RequiredFieldValidator ID="RfvLimite" runat="server" ControlToValidate="TxtLimite" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Folio''</b> es necesario, por favor ingréselo." ValidationGroup="GrpFolioGarantia"></asp:RequiredFieldValidator>
|
||||||
|
<label for="<%= TxtLimite.ClientID.ToString()%>">Limite:</label>
|
||||||
|
<i></i>
|
||||||
|
</div>
|
||||||
<%-- <div class="form-group form-md-line-input input-iconright" style="width: 170px!important">
|
<%-- <div class="form-group form-md-line-input input-iconright" style="width: 170px!important">
|
||||||
<asp:TextBox ID="TxtCargo" CssClass="form-control " Width="150px" runat="server" MaxLength="10" CausesValidation="true" Style="text-align: right!important; margin-right: 10px!important" OnKeyup="FormatoMoneda(this);"></asp:TextBox>
|
<asp:TextBox ID="TxtCargo" CssClass="form-control " Width="150px" runat="server" MaxLength="10" CausesValidation="true" Style="text-align: right!important; margin-right: 10px!important" OnKeyup="FormatoMoneda(this);"></asp:TextBox>
|
||||||
<asp:RequiredFieldValidator ID="RFVTxtCargo" runat="server" ControlToValidate="TxtCargo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cargo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTamanio"></asp:RequiredFieldValidator>
|
<asp:RequiredFieldValidator ID="RFVTxtCargo" runat="server" ControlToValidate="TxtCargo" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cargo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpTamanio"></asp:RequiredFieldValidator>
|
||||||
|
|||||||
@@ -38,7 +38,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
|
|
||||||
If Not Page.IsPostBack Then
|
If Not Page.IsPostBack Then
|
||||||
CargaSubProyectos()
|
CargaSubProyectos()
|
||||||
CargadatosGvFolioGarantia()
|
CargadatosGvFolioGarantia(-1, "-1")
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -53,11 +53,11 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
DdlSubProyectos.Items.Insert(0, New ListItem("Todos", "-1"))
|
DdlSubProyectos.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
Private Sub CargadatosGvFolioGarantia()
|
Private Sub CargadatosGvFolioGarantia(EstatusValor As Integer, tipoFolioValor As String)
|
||||||
|
|
||||||
Dim objAcum As New ClsAcumuladores
|
Dim objAcum As New ClsAcumuladores
|
||||||
|
|
||||||
If objAcum.FoliosGarantiaGet(-1, UsuarioActual.Empresa.CveEmpresa) Then
|
If objAcum.FoliosGarantiaGet(-1, UsuarioActual.Empresa.CveEmpresa, Estatus:=EstatusValor, TipoFolio:=tipoFolioValor) Then
|
||||||
GvFolioGarantia.DataSource = objAcum.DtResultados
|
GvFolioGarantia.DataSource = objAcum.DtResultados
|
||||||
Else
|
Else
|
||||||
GvFolioGarantia.DataSource = Nothing
|
GvFolioGarantia.DataSource = Nothing
|
||||||
@@ -116,7 +116,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
|
|
||||||
|
|
||||||
If Not Actualizar Then
|
If Not Actualizar Then
|
||||||
If ObjAcum.FoliosGarantiaAdd(TxtFolioGarantia.Text, If(ChkEstatus.Checked = True, 1, 0), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlSubProyectos.SelectedValue.ToEntero) Then
|
If ObjAcum.FoliosGarantiaAdd(TxtFolioGarantia.Text, If(ChkEstatus.Checked = True, 1, 0), UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, DdlSubProyectos.SelectedValue.ToEntero, DdlTipoFolioModal.SelectedValue, TxtLimite.Text.ToEntero) Then
|
||||||
|
|
||||||
TxtFolioGarantia.Text = ""
|
TxtFolioGarantia.Text = ""
|
||||||
ChkEstatus.Checked = True
|
ChkEstatus.Checked = True
|
||||||
@@ -125,7 +125,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
'TxtCompra.Text = ""
|
'TxtCompra.Text = ""
|
||||||
'TxtPuntos.Text = ""
|
'TxtPuntos.Text = ""
|
||||||
|
|
||||||
CargadatosGvFolioGarantia()
|
CargadatosGvFolioGarantia(-1, "-1")
|
||||||
|
|
||||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarFolioGarantia"), "jsHideModalFolioGarantia")
|
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarFolioGarantia"), "jsHideModalFolioGarantia")
|
||||||
UpGral.Update()
|
UpGral.Update()
|
||||||
@@ -135,7 +135,8 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
Alert("Ocurrió un error al guardar el Folio de Garantía", TipoMensaje.MsgError)
|
Alert("Ocurrió un error al guardar el Folio de Garantía", TipoMensaje.MsgError)
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
If ObjAcum.FoliosGarantiaUpdate(CveFolioGarantia, TxtFolioGarantia.Text, If(ChkEstatus.Checked = True, 1, 0), UsuarioActual.CveUsuario, DdlSubProyectos.SelectedValue.ToEntero) Then
|
If ObjAcum.FoliosGarantiaUpdate(CveFolioGarantia, TxtFolioGarantia.Text, If(ChkEstatus.Checked = True, 1, 0), UsuarioActual.CveUsuario, DdlSubProyectos.SelectedValue.ToEntero,
|
||||||
|
DdlTipoFolioModal.SelectedValue, TxtLimite.Text.ToEntero) Then
|
||||||
|
|
||||||
TxtFolioGarantia.Text = ""
|
TxtFolioGarantia.Text = ""
|
||||||
ChkEstatus.Checked = True
|
ChkEstatus.Checked = True
|
||||||
@@ -144,7 +145,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
'TxtCompra.Text = ""
|
'TxtCompra.Text = ""
|
||||||
'TxtPuntos.Text = ""
|
'TxtPuntos.Text = ""
|
||||||
|
|
||||||
CargadatosGvFolioGarantia()
|
CargadatosGvFolioGarantia(-1, "-1")
|
||||||
UpModalFolioGarantia.Update()
|
UpModalFolioGarantia.Update()
|
||||||
|
|
||||||
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarFolioGarantia"), "jsHideModalFolioGarantia")
|
RegistraScript(String.Format("$('#{0}').modal('hide');", "DivAgregarFolioGarantia"), "jsHideModalFolioGarantia")
|
||||||
@@ -171,7 +172,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
Dim CveCapacitador As Integer = GvRow.DataKey("CveFolioGarantia")
|
Dim CveCapacitador As Integer = GvRow.DataKey("CveFolioGarantia")
|
||||||
|
|
||||||
If objAcum.FoliosGarantiaRemove(CveCapacitador, UsuarioActual.CveEmpresa) Then
|
If objAcum.FoliosGarantiaRemove(CveCapacitador, UsuarioActual.CveEmpresa) Then
|
||||||
CargadatosGvFolioGarantia()
|
CargadatosGvFolioGarantia(-1, "-1")
|
||||||
|
|
||||||
Alert("Capacitador Eliminó Correctamente ", TipoMensaje.MsgInformacion)
|
Alert("Capacitador Eliminó Correctamente ", TipoMensaje.MsgInformacion)
|
||||||
Else
|
Else
|
||||||
@@ -180,7 +181,7 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
|
|
||||||
objAcum.Dispose()
|
objAcum.Dispose()
|
||||||
|
|
||||||
CargadatosGvFolioGarantia()
|
CargadatosGvFolioGarantia(-1, "-1")
|
||||||
|
|
||||||
CveFolioGarantia = -1
|
CveFolioGarantia = -1
|
||||||
|
|
||||||
@@ -198,6 +199,8 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
|
|
||||||
TxtFolioGarantia.Text = GvRow.DataKey("FolioGarantia")
|
TxtFolioGarantia.Text = GvRow.DataKey("FolioGarantia")
|
||||||
ChkEstatus.Checked = If(GvRow.DataKey("Estatus") = "Activo", True, False)
|
ChkEstatus.Checked = If(GvRow.DataKey("Estatus") = "Activo", True, False)
|
||||||
|
TxtLimite.Text = GvRow.DataKey("Limite")
|
||||||
|
DdlTipoFolioModal.SelectedValue = GvRow.DataKey("tipoFolio")
|
||||||
'TxtCargo.Text = GvRow.DataKey("Cargo").ToDecimal.ToString("###,###,###.00")
|
'TxtCargo.Text = GvRow.DataKey("Cargo").ToDecimal.ToString("###,###,###.00")
|
||||||
'TxtBonificacion.Text = GvRow.DataKey("Bonificacion").ToDecimal.ToString("###,###,###.00")
|
'TxtBonificacion.Text = GvRow.DataKey("Bonificacion").ToDecimal.ToString("###,###,###.00")
|
||||||
'TxtCompra.Text = GvRow.DataKey("Compra").ToDecimal.ToString("###,###,###.00")
|
'TxtCompra.Text = GvRow.DataKey("Compra").ToDecimal.ToString("###,###,###.00")
|
||||||
@@ -221,6 +224,8 @@ Partial Class Acumuladores_CatFoliosGarantia
|
|||||||
|
|
||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
Protected Sub BtnConsultar_Click(sender As Object, e As EventArgs)
|
||||||
|
CargadatosGvFolioGarantia(DdlEstatus.SelectedValue.ToEntero, DdlTipoFolio.SelectedValue)
|
||||||
|
End Sub
|
||||||
|
|
||||||
End Class
|
End Class
|
||||||
|
|||||||
@@ -483,7 +483,7 @@ Public Class ClsAcumuladores
|
|||||||
|
|
||||||
#Region " FOLIOS GARANTÍA "
|
#Region " FOLIOS GARANTÍA "
|
||||||
|
|
||||||
Public Function FoliosGarantiaGet(CveFolioGarantia As Integer, CveEmpresa As Integer, Optional Estatus As Integer = -1) As Boolean
|
Public Function FoliosGarantiaGet(CveFolioGarantia As Integer, CveEmpresa As Integer, Optional Estatus As Integer = -1, Optional TipoFolio As String = "-1") As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
'Data = New DataTable
|
'Data = New DataTable
|
||||||
|
|
||||||
@@ -493,6 +493,7 @@ Public Class ClsAcumuladores
|
|||||||
.Add("@CveFolioGarantia", SqlDbType.Int).Value = CveFolioGarantia
|
.Add("@CveFolioGarantia", SqlDbType.Int).Value = CveFolioGarantia
|
||||||
.Add("@Estatus", SqlDbType.Int).Value = Estatus
|
.Add("@Estatus", SqlDbType.Int).Value = Estatus
|
||||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
|
.Add("@tipoFolio", SqlDbType.VarChar).Value = TipoFolio
|
||||||
End With
|
End With
|
||||||
|
|
||||||
Try
|
Try
|
||||||
@@ -507,7 +508,7 @@ Public Class ClsAcumuladores
|
|||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function FoliosGarantiaAdd(FolioGarantia As String, Estatus As Integer, CveUsuario As Integer, CveEmpresa As Integer, CveSubProyecto As Integer) As Boolean
|
Public Function FoliosGarantiaAdd(FolioGarantia As String, Estatus As Integer, CveUsuario As Integer, CveEmpresa As Integer, CveSubProyecto As Integer, TipoFolio As String, Limite As Integer) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
'Data = New DataTable
|
'Data = New DataTable
|
||||||
|
|
||||||
@@ -520,6 +521,8 @@ Public Class ClsAcumuladores
|
|||||||
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||||
|
.Add("@TipoFolio", SqlDbType.VarChar).Value = TipoFolio
|
||||||
|
.Add("@Limite", SqlDbType.Int).Value = Limite
|
||||||
|
|
||||||
End With
|
End With
|
||||||
|
|
||||||
@@ -535,7 +538,7 @@ Public Class ClsAcumuladores
|
|||||||
Return Retorno
|
Return Retorno
|
||||||
End Function
|
End Function
|
||||||
|
|
||||||
Public Function FoliosGarantiaUpdate(CveFolioGarantia As Integer, FolioGarantia As String, Estatus As Integer, CveUsuario As Integer, CveSubProyecto As Integer) As Boolean
|
Public Function FoliosGarantiaUpdate(CveFolioGarantia As Integer, FolioGarantia As String, Estatus As Integer, CveUsuario As Integer, CveSubProyecto As Integer, TipoFolio As String, Limite As Integer) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
'Data = New DataTable
|
'Data = New DataTable
|
||||||
|
|
||||||
@@ -548,6 +551,8 @@ Public Class ClsAcumuladores
|
|||||||
.Add("@Estatus", SqlDbType.Bit).Value = Estatus
|
.Add("@Estatus", SqlDbType.Bit).Value = Estatus
|
||||||
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
|
||||||
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
|
||||||
|
.Add("@TipoFolio", SqlDbType.VarChar).Value = TipoFolio
|
||||||
|
.Add("@Limite", SqlDbType.Int).Value = Limite
|
||||||
|
|
||||||
End With
|
End With
|
||||||
|
|
||||||
|
|||||||
@@ -3345,7 +3345,7 @@ Public Class ClsBancos
|
|||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
#Region "PagosCajaChica"
|
#Region "PagosCajaChica"
|
||||||
Public Function GetPagosCajaChica(FechaI As String, FechaF As String, CveEmpresa As Integer, CveCuenta As Integer) As Boolean
|
Public Function GetPagosCajaChica(FechaI As String, FechaF As String, CveEmpresa As Integer, CveCuenta As Integer, Optional TipoPago As Integer = -1) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
DataAdapter("PA_BancosCajaChicaPagosGet")
|
DataAdapter("PA_BancosCajaChicaPagosGet")
|
||||||
|
|
||||||
@@ -3354,6 +3354,7 @@ Public Class ClsBancos
|
|||||||
.Add("@FechaF", SqlDbType.VarChar).Value = FechaF
|
.Add("@FechaF", SqlDbType.VarChar).Value = FechaF
|
||||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
.Add("@CveCuenta", SqlDbType.Int).Value = CveCuenta
|
.Add("@CveCuenta", SqlDbType.Int).Value = CveCuenta
|
||||||
|
.Add("@TipoChequeEfectivo", SqlDbType.Int).Value = TipoPago
|
||||||
End With
|
End With
|
||||||
|
|
||||||
Try
|
Try
|
||||||
|
|||||||
@@ -133,6 +133,26 @@ Public Class ClsGenerales
|
|||||||
End With
|
End With
|
||||||
End Sub
|
End Sub
|
||||||
|
|
||||||
|
Public Function IEPSxEntidadFed(cveEstado As Int32, tasaIEPS As Decimal, fechaInicio As String, fechaFin As String, cveEmpresa As Int32, Agrupador As Int32) As Boolean
|
||||||
|
Dim retorno As Boolean = False
|
||||||
|
DataAdapter("PA_GralIepsPorEntidadFederativa", CommandType.StoredProcedure)
|
||||||
|
With SqlAdapter.SelectCommand.Parameters
|
||||||
|
|
||||||
|
.Add("@CveEstado", SqlDbType.Int).Value = (cveEstado)
|
||||||
|
.Add("@TasaIEPS", SqlDbType.Decimal).Value = (tasaIEPS)
|
||||||
|
.Add("@FechaInicio", SqlDbType.VarChar).Value = (fechaInicio)
|
||||||
|
.Add("@FechaFin", SqlDbType.VarChar).Value = (fechaFin)
|
||||||
|
.Add("@Agrupador", SqlDbType.Int).Value = (Agrupador)
|
||||||
|
.Add("@CveEmpresa", SqlDbType.Int).Value = (cveEmpresa)
|
||||||
|
End With
|
||||||
|
Try
|
||||||
|
SqlAdapter.Fill(Data)
|
||||||
|
retorno = True
|
||||||
|
Catch ex As Exception
|
||||||
|
OnError("Ocurrió un error al obtener el reporte de IEPS por entidad federativa.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
|
End Try
|
||||||
|
Return retorno
|
||||||
|
End Function
|
||||||
Public Function RepConciliacionSatDetalleGET(cveEmpresa As Int32, tipoDocto As String, fechaI As String, fechaF As String, RegistroEn As Integer) As Boolean
|
Public Function RepConciliacionSatDetalleGET(cveEmpresa As Int32, tipoDocto As String, fechaI As String, fechaF As String, RegistroEn As Integer) As Boolean
|
||||||
Dim retorno As Boolean = False
|
Dim retorno As Boolean = False
|
||||||
DataAdapter("PA_RepConciliacionSatDetalleGET", CommandType.StoredProcedure)
|
DataAdapter("PA_RepConciliacionSatDetalleGET", CommandType.StoredProcedure)
|
||||||
|
|||||||
@@ -3517,6 +3517,7 @@ Public Class ClsPaginas
|
|||||||
|
|
||||||
PaginaDict.Add("/Inicio.aspx".ToUpper(), -1)
|
PaginaDict.Add("/Inicio.aspx".ToUpper(), -1)
|
||||||
PaginaDict.Add("/reporteador.aspx".ToUpper(), -1)
|
PaginaDict.Add("/reporteador.aspx".ToUpper(), -1)
|
||||||
|
PaginaDict.Add("/General/CATIEPSxEntidadFed.aspx".ToUpper(), 719)
|
||||||
PaginaDict.Add("/GPS/RepArrastre.aspx".ToUpper(), 718)
|
PaginaDict.Add("/GPS/RepArrastre.aspx".ToUpper(), 718)
|
||||||
PaginaDict.Add("/Ventas/RepConciliacionEmitidosSat.aspx".ToUpper(), -1)
|
PaginaDict.Add("/Ventas/RepConciliacionEmitidosSat.aspx".ToUpper(), -1)
|
||||||
PaginaDict.Add("/Ventas/RepConciliacionSat.aspx".ToUpper(), 716)
|
PaginaDict.Add("/Ventas/RepConciliacionSat.aspx".ToUpper(), 716)
|
||||||
@@ -4877,10 +4878,21 @@ Public Class ClsPaginas
|
|||||||
End Select
|
End Select
|
||||||
End If
|
End If
|
||||||
|
|
||||||
' End If
|
If Pagina.ToUpper() = ("/Ventas/Ventas.aspx").ToUpper() Then
|
||||||
|
Select Case Request("Op")
|
||||||
|
Case "Cot" : Retorno = 366
|
||||||
|
Case "Rem" : Retorno = 2018
|
||||||
|
Case Else : Retorno = 6
|
||||||
|
End Select
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Pagina.ToUpper() = ("/Ventas/RepVentas.aspx").ToUpper() Then
|
||||||
|
Select Case Request("Op")
|
||||||
|
Case "Cot" : Retorno = 367
|
||||||
|
Case Else : Retorno = 9
|
||||||
|
End Select
|
||||||
|
End If
|
||||||
|
|
||||||
'PaginaDict = Nothing
|
|
||||||
Return Retorno
|
Return Retorno
|
||||||
|
|
||||||
End Function
|
End Function
|
||||||
|
|||||||
@@ -70,6 +70,15 @@
|
|||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<label class="col-md-1 truncate" style="width: 80px;">Tipo Pago:</label>
|
||||||
|
<div class="col-md-2">
|
||||||
|
<asp:DropDownList ID="DdlTipoPago" runat="server" AppendDataBoundItems="true" DataTextField="NumCuentaMoneda" DataValueField="CveCuenta" Class="table-group-action-input form-control input-inline input-small input-sm select2me">
|
||||||
|
<asp:ListItem Value="-1" Text="Todos"></asp:ListItem>
|
||||||
|
<asp:ListItem Value="13" Text="Efectivo"></asp:ListItem>
|
||||||
|
<asp:ListItem Value="3" Text="Cheque"></asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@@ -114,7 +123,8 @@
|
|||||||
<asp:label runat="server">Importe seleccionado: $</asp:label><asp:label runat="server" ID="lblValorTotal">00.00</asp:label>
|
<asp:label runat="server">Importe seleccionado: $</asp:label><asp:label runat="server" ID="lblValorTotal">00.00</asp:label>
|
||||||
</div>
|
</div>
|
||||||
<br />
|
<br />
|
||||||
<asp:GridView ID="GvFacturas" runat="server" AutoGenerateColumns="False" DataKeyNames="CveVenta, CvePrePoliza, CveIE, TipoCambio, CveMoneda, CveCliente, IdCtaContableBancos, IdCtaContClientes, Importe" CssClass="table detallerow table-hover" Style="text-align: center; float: right; width: 100%; font-size: medium;" GridLines="None">
|
<div style="height:575px;overflow-x:scroll">
|
||||||
|
<asp:GridView ID="GvFacturas" runat="server" AutoGenerateColumns="False" DataKeyNames="CveVenta, CvePrePoliza, CveIE, TipoCambio, CveMoneda, CveCliente, IdCtaContableBancos, IdCtaContClientes, Importe" CssClass="table table-striped table-advance table-hover" Style="text-align: center; float: right; width: 100%; font-size: medium;" GridLines="None">
|
||||||
<Columns>
|
<Columns>
|
||||||
<asp:TemplateField>
|
<asp:TemplateField>
|
||||||
<HeaderTemplate>
|
<HeaderTemplate>
|
||||||
@@ -141,6 +151,12 @@
|
|||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
<ItemStyle HorizontalAlign="Left"></ItemStyle>
|
<ItemStyle HorizontalAlign="Left"></ItemStyle>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Tipo Pago">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Literal ID="LtTipoPago" runat="server" ClientIDMode="Static" Text='<%# Eval("TipoPago")%>'></asp:Literal>
|
||||||
|
</ItemTemplate>
|
||||||
|
<ItemStyle HorizontalAlign="Left"></ItemStyle>
|
||||||
|
</asp:TemplateField>
|
||||||
<asp:TemplateField HeaderText="Importe">
|
<asp:TemplateField HeaderText="Importe">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:Literal ID="LtImporte" runat="server" ClientIDMode="Static" Text='<%# Eval("Importe", "{0:N2}")%>'></asp:Literal>
|
<asp:Literal ID="LtImporte" runat="server" ClientIDMode="Static" Text='<%# Eval("Importe", "{0:N2}")%>'></asp:Literal>
|
||||||
@@ -152,6 +168,7 @@
|
|||||||
<RowStyle Font-Size="Smaller" />
|
<RowStyle Font-Size="Smaller" />
|
||||||
<HeaderStyle CssClass="Titulos" />
|
<HeaderStyle CssClass="Titulos" />
|
||||||
</asp:GridView>
|
</asp:GridView>
|
||||||
|
</div>
|
||||||
|
|
||||||
</ContentTemplate>
|
</ContentTemplate>
|
||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
|
|||||||
@@ -41,7 +41,7 @@ Partial Class Bancos_DepositosCaja
|
|||||||
FechaI = If(IsDate(txtFechaI.Text.Trim()), txtFechaI.Text.Trim(), "-1")
|
FechaI = If(IsDate(txtFechaI.Text.Trim()), txtFechaI.Text.Trim(), "-1")
|
||||||
FechaF = If(IsDate(txtFechaF.Text.Trim()), txtFechaF.Text.Trim(), "-1")
|
FechaF = If(IsDate(txtFechaF.Text.Trim()), txtFechaF.Text.Trim(), "-1")
|
||||||
|
|
||||||
ObjBancos.GetPagosCajaChica(FechaI, FechaF, UsuarioActual.CveEmpresa, DdlCajaChica.SelectedValue.ToEntero)
|
ObjBancos.GetPagosCajaChica(FechaI, FechaF, UsuarioActual.CveEmpresa, DdlCajaChica.SelectedValue.ToEntero, DdlTipoPago.SelectedValue.ToEntero)
|
||||||
|
|
||||||
GvFacturas.DataSource = ObjBancos.DtResultados
|
GvFacturas.DataSource = ObjBancos.DtResultados
|
||||||
ObjBancos.Dispose()
|
ObjBancos.Dispose()
|
||||||
|
|||||||
@@ -720,7 +720,7 @@ Partial Class Bancos_ProveedoresAbonar
|
|||||||
|
|
||||||
Valida.Verificar(gvr.DataKey("UUID"), gvr.DataKey("RFC"), UsuarioActual.Empresa.RFC, gvr.DataKey("Original").ToDecimal)
|
Valida.Verificar(gvr.DataKey("UUID"), gvr.DataKey("RFC"), UsuarioActual.Empresa.RFC, gvr.DataKey("Original").ToDecimal)
|
||||||
|
|
||||||
If UsuarioActual.CveEmpresa < 2 Then
|
If Not UsuarioActual.Empresa.FacturaProduccion OrElse UsuarioActual.CveEmpresa < 2 Then
|
||||||
Valida.EsValida = 1
|
Valida.EsValida = 1
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -1099,7 +1099,7 @@
|
|||||||
<Paragraph>
|
<Paragraph>
|
||||||
<TextRuns>
|
<TextRuns>
|
||||||
<TextRun>
|
<TextRun>
|
||||||
<Value>=Fields!PS.Value & " " & Fields!Obs.Value</Value>
|
<Value>=Fields!PS.Value & System.Environment.NewLine & IIF(Fields!Obs.Value <> "","Observaciones: ","") & Fields!Obs.Value</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontFamily>calibri</FontFamily>
|
<FontFamily>calibri</FontFamily>
|
||||||
<FontSize>8.75pt</FontSize>
|
<FontSize>8.75pt</FontSize>
|
||||||
@@ -3150,7 +3150,7 @@
|
|||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
</ReportItems>
|
</ReportItems>
|
||||||
<Height>20.5093cm</Height>
|
<Height>20.50931cm</Height>
|
||||||
<Style />
|
<Style />
|
||||||
</Body>
|
</Body>
|
||||||
<Width>21.16666cm</Width>
|
<Width>21.16666cm</Width>
|
||||||
|
|||||||
@@ -372,7 +372,7 @@
|
|||||||
<Paragraph>
|
<Paragraph>
|
||||||
<TextRuns>
|
<TextRuns>
|
||||||
<TextRun>
|
<TextRun>
|
||||||
<Value>=IIf(Fields!PS.Value = "", "Folio: " & Fields!FolioSalida.Value, Fields!Cantidad.Value)</Value>
|
<Value>=IIf(Fields!PS.Value = "", IIf(Fields!FolioSalida.Value > 0,"Folio: " & Fields!FolioSalida.Value,"Total General"), Fields!Cantidad.Value)</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontSize>8pt</FontSize>
|
<FontSize>8pt</FontSize>
|
||||||
<FontWeight>=IIf(Fields!PS.Value = "", "Bold", "Default")</FontWeight>
|
<FontWeight>=IIf(Fields!PS.Value = "", "Bold", "Default")</FontWeight>
|
||||||
@@ -478,7 +478,7 @@
|
|||||||
<Paragraph>
|
<Paragraph>
|
||||||
<TextRuns>
|
<TextRuns>
|
||||||
<TextRun>
|
<TextRun>
|
||||||
<Value>=IIf(Fields!PS.Value = "", "Almacén Origen: " & Fields!Almacen.Value & " Almacén Destino: " & Fields!AlmacenDestino.Value & " Responsable: " & Fields!Recibio.Value, Fields!PS.Value)</Value>
|
<Value>=IIf(Fields!PS.Value = "", IIf(Fields!FolioSalida.Value > 0,"Almacén Origen: " & Fields!Almacen.Value & " Almacén Destino: " & Fields!AlmacenDestino.Value & " Responsable: " & Fields!Recibio.Value,""), Fields!PS.Value)</Value>
|
||||||
<Style>
|
<Style>
|
||||||
<FontSize>8pt</FontSize>
|
<FontSize>8pt</FontSize>
|
||||||
<FontWeight>=IIf(Fields!PS.Value = "", "Bold", "Default")</FontWeight>
|
<FontWeight>=IIf(Fields!PS.Value = "", "Bold", "Default")</FontWeight>
|
||||||
@@ -501,7 +501,6 @@
|
|||||||
<PaddingBottom>2pt</PaddingBottom>
|
<PaddingBottom>2pt</PaddingBottom>
|
||||||
</Style>
|
</Style>
|
||||||
</Textbox>
|
</Textbox>
|
||||||
<rd:Selected>true</rd:Selected>
|
|
||||||
</CellContents>
|
</CellContents>
|
||||||
</TablixCell>
|
</TablixCell>
|
||||||
<TablixCell>
|
<TablixCell>
|
||||||
|
|||||||
@@ -490,6 +490,215 @@
|
|||||||
</TablixCell>
|
</TablixCell>
|
||||||
</TablixCells>
|
</TablixCells>
|
||||||
</TablixRow>
|
</TablixRow>
|
||||||
|
<TablixRow>
|
||||||
|
<Height>0.44125cm</Height>
|
||||||
|
<TablixCells>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox20">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value>=Sum(Fields!Cantidad.Value)</Value>
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
<FontWeight>Bold</FontWeight>
|
||||||
|
<Format>#,0;(#,0)</Format>
|
||||||
|
<Language>es-MX</Language>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox20</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox21">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value>Total Productos</Value>
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
<FontWeight>Bold</FontWeight>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox21</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox23">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value />
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox23</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox37">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value />
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox37</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox41">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value />
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
<FontWeight>SemiBold</FontWeight>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox41</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
<TablixCell>
|
||||||
|
<CellContents>
|
||||||
|
<Textbox Name="Textbox42">
|
||||||
|
<CanGrow>true</CanGrow>
|
||||||
|
<KeepTogether>true</KeepTogether>
|
||||||
|
<Paragraphs>
|
||||||
|
<Paragraph>
|
||||||
|
<TextRuns>
|
||||||
|
<TextRun>
|
||||||
|
<Value />
|
||||||
|
<Style>
|
||||||
|
<FontSize>8pt</FontSize>
|
||||||
|
<Format>#,0.00;(#,0.00)</Format>
|
||||||
|
</Style>
|
||||||
|
</TextRun>
|
||||||
|
</TextRuns>
|
||||||
|
<Style>
|
||||||
|
<TextAlign>Left</TextAlign>
|
||||||
|
</Style>
|
||||||
|
</Paragraph>
|
||||||
|
</Paragraphs>
|
||||||
|
<rd:DefaultName>Textbox42</rd:DefaultName>
|
||||||
|
<Style>
|
||||||
|
<Border>
|
||||||
|
<Style>None</Style>
|
||||||
|
</Border>
|
||||||
|
<VerticalAlign>Bottom</VerticalAlign>
|
||||||
|
<PaddingLeft>2pt</PaddingLeft>
|
||||||
|
<PaddingRight>2pt</PaddingRight>
|
||||||
|
<PaddingTop>=IIf(rownumber(nothing) = 1, "2pt", "0pt")</PaddingTop>
|
||||||
|
</Style>
|
||||||
|
</Textbox>
|
||||||
|
</CellContents>
|
||||||
|
</TablixCell>
|
||||||
|
</TablixCells>
|
||||||
|
</TablixRow>
|
||||||
</TablixRows>
|
</TablixRows>
|
||||||
</TablixBody>
|
</TablixBody>
|
||||||
<TablixColumnHierarchy>
|
<TablixColumnHierarchy>
|
||||||
@@ -509,13 +718,19 @@
|
|||||||
</TablixMember>
|
</TablixMember>
|
||||||
<TablixMember>
|
<TablixMember>
|
||||||
<Group Name="Details" />
|
<Group Name="Details" />
|
||||||
|
<TablixMembers>
|
||||||
|
<TablixMember />
|
||||||
|
</TablixMembers>
|
||||||
|
</TablixMember>
|
||||||
|
<TablixMember>
|
||||||
|
<KeepWithGroup>Before</KeepWithGroup>
|
||||||
</TablixMember>
|
</TablixMember>
|
||||||
</TablixMembers>
|
</TablixMembers>
|
||||||
</TablixRowHierarchy>
|
</TablixRowHierarchy>
|
||||||
<DataSetName>DsInventarios</DataSetName>
|
<DataSetName>DsInventarios</DataSetName>
|
||||||
<Top>0.07056cm</Top>
|
<Top>0.07056cm</Top>
|
||||||
<Left>0.00711cm</Left>
|
<Left>0.00711cm</Left>
|
||||||
<Height>0.73434cm</Height>
|
<Height>1.17559cm</Height>
|
||||||
<Width>19.56807cm</Width>
|
<Width>19.56807cm</Width>
|
||||||
<Style>
|
<Style>
|
||||||
<Border>
|
<Border>
|
||||||
@@ -524,10 +739,10 @@
|
|||||||
</Style>
|
</Style>
|
||||||
</Tablix>
|
</Tablix>
|
||||||
</ReportItems>
|
</ReportItems>
|
||||||
<Height>0.42708in</Height>
|
<Height>0.68252in</Height>
|
||||||
<Style />
|
<Style />
|
||||||
</Body>
|
</Body>
|
||||||
<Width>7.70923in</Width>
|
<Width>7.72259in</Width>
|
||||||
<Page>
|
<Page>
|
||||||
<PageHeader>
|
<PageHeader>
|
||||||
<Height>5.08094cm</Height>
|
<Height>5.08094cm</Height>
|
||||||
|
|||||||
129
General/CATIEPSxEntidadFed.aspx
Normal file
129
General/CATIEPSxEntidadFed.aspx
Normal file
@@ -0,0 +1,129 @@
|
|||||||
|
<%@ Page Title="" Language="C#" MasterPageFile="~/Site.master" AutoEventWireup="true" CodeFile="CATIEPSxEntidadFed.aspx.cs" Inherits="General_CATIEPSxEntidadFed" %>
|
||||||
|
|
||||||
|
<asp:Content ID="Content1" ContentPlaceHolderID="CP" runat="Server">
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content2" ContentPlaceHolderID="Css" runat="Server">
|
||||||
|
<style>
|
||||||
|
.GVIEPSxEntidadFed tr td:nth-child(n+2) {
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
</style>
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
|
||||||
|
IEPS Por Entidad Federativa
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
|
||||||
|
<li>
|
||||||
|
<asp:LinkButton ID="LnkPDF" OnClick="LnkPDF_Click" runat="server"><i class="fa fa-ad-pdf "></i> PDF</asp:LinkButton>
|
||||||
|
</li>
|
||||||
|
<li>
|
||||||
|
<asp:LinkButton ID="LnkExcel" OnClick="LnkExcel_Click" runat="server"><i class="fa fa-ad-excel "></i> Excel</asp:LinkButton>
|
||||||
|
</li>
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content9" ContentPlaceHolderID="C" runat="Server">
|
||||||
|
<asp:UpdatePanel ID="UPFiltros" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<div class="portlet solid grey-cascade portlet-filter" id="idnecesaria">
|
||||||
|
<div class="portlet-title portlet-filterT smalltitle" style="min-height: 51px;">
|
||||||
|
<div class="tools">
|
||||||
|
<asp:Button ID="BtnIEPSFiltrar" OnClick="BtnIEPSFiltrar_Click" runat="server" Text="Consultar" class="btn btn-primary" />
|
||||||
|
<a href="javascript:;" class="expand"></a>
|
||||||
|
</div>
|
||||||
|
<div class="titlefiltros caption">
|
||||||
|
<div class="row">
|
||||||
|
<label class="col-md-1" style="padding-top: 13px;width: 5%;">Agrupador </label>
|
||||||
|
<div class="col-md-1" style="">
|
||||||
|
<asp:DropDownList ID="DdlAgrupador" runat="server"
|
||||||
|
CssClass="form-control select2me" Width="100%">
|
||||||
|
<asp:ListItem Value="1" Text="IEPS - Estado" Selected="True" ></asp:ListItem>
|
||||||
|
<asp:ListItem Value="2" Text="Estado - IEPS"></asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
<label class="col-md-1" style="padding-top: 13px;width: 4.5%;">IEPS </label>
|
||||||
|
<div class="col-md-1" style="">
|
||||||
|
<asp:DropDownList ID="DdlIeps" runat="server"
|
||||||
|
CssClass="form-control select2me" Width="100%">
|
||||||
|
<asp:ListItem Value="-1" Text="Todos"></asp:ListItem>
|
||||||
|
<asp:ListItem Value=".06" Text="6.00%"></asp:ListItem>
|
||||||
|
<asp:ListItem Value=".07" Text="7.00%"></asp:ListItem>
|
||||||
|
<asp:ListItem Value=".09" Text="9.00%"></asp:ListItem>
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
<label class="col-md-1" style="padding-top: 13px;width: 5%;">Estado</label>
|
||||||
|
<div class="col-md-2" style="">
|
||||||
|
<asp:DropDownList ID="DdlEstado" runat="server" DataTextField="ClaveSATEstadoNombreEstado" DataValueField="CveEstado" CssClass="form-control select2me" Width="100%">
|
||||||
|
</asp:DropDownList>
|
||||||
|
</div>
|
||||||
|
<div class="col-md-1 truncate" style="padding-top: 13px;">
|
||||||
|
Fecha Inicio
|
||||||
|
</div>
|
||||||
|
<div class="col-md-1" style="padding-top: 9px;">
|
||||||
|
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 80px !important; padding: 0px;">
|
||||||
|
<asp:TextBox ID="TxtIEPSfechaInicio" CssClass="form-control input-sm ADSMaskDate" Style="width: 78px" runat="server"></asp:TextBox>
|
||||||
|
<span class="input-group-btn ">
|
||||||
|
<asp:LinkButton ID="LnkIEPSfechaInicio" class="btn default " Text=" <i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<ajax:MaskedEditExtender ID="MEEIEPSfechaInicio" runat="server" TargetControlID="TxtIEPSfechaInicio" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||||
|
<ajax:CalendarExtender runat="server" ID="CEEIEPSfechaInicio" TargetControlID="TxtIEPSfechaInicio" PopupButtonID="LnkIEPSfechaInicio" PopupPosition="BottomRight" Enabled="True" Format="dd/MM/yyyy"></ajax:CalendarExtender>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
<div class="col-md-1 truncate" style="padding-top: 13px;">
|
||||||
|
Fecha Fin
|
||||||
|
</div>
|
||||||
|
<div class="col-md-1" style="padding-top: 9px;">
|
||||||
|
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 80px !important; padding: 0px;">
|
||||||
|
<asp:TextBox ID="TxtIEPSfechaFin" CssClass="form-control input-sm ADSMaskDate" Style="width: 78px" runat="server"></asp:TextBox>
|
||||||
|
<span class="input-group-btn ">
|
||||||
|
<asp:LinkButton ID="LnkIEPSfechaFin" class="btn default " Text=" <i class='fa fa-calendar'></i>" runat="server"></asp:LinkButton>
|
||||||
|
</span>
|
||||||
|
</div>
|
||||||
|
<ajax:MaskedEditExtender ID="MEEIEPSfechaFin" runat="server" TargetControlID="TxtIEPSfechaFin" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
|
||||||
|
<ajax:CalendarExtender runat="server" ID="CEEIEPSfechaFin" TargetControlID="TxtIEPSfechaFin" PopupButtonID="LnkIEPSfechaFin" PopupPosition="BottomRight" Enabled="True" Format="dd/MM/yyyy"></ajax:CalendarExtender>
|
||||||
|
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
<div class="portlet-body" style="display: none">
|
||||||
|
</div>
|
||||||
|
</div>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
<asp:UpdatePanel ID="upDatosIEPS" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<asp:GridView ID="GVIEPSxEntidadFed" runat="server" GridLines="None" CssClass="table table-hover table-striped ScrollAD GVIEPSxEntidadFed" AutoGenerateColumns="False" Width="100%"
|
||||||
|
DataKeyNames="CveEstado,NombreEstado,PorcentajeIEPS,SubTotal,IEPS" OnRowDataBound="GVIEPSxEntidadFed_RowDataBound">
|
||||||
|
<Columns>
|
||||||
|
<asp:TemplateField HeaderText="Nombre Estado">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblGrupo" runat="server" Text='<%# Eval("Grupo")%>'> </asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Porcentaje IEPS">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblporcentajeIEPS" runat="server" Text='<%# Eval("PorcentajeIEPS","{0:P2}")%>'> </asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="Sub Total">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lblsubTotal" runat="server" Text='<%# Eval("SubTotal","{0:N2}")%>'> </asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
<asp:TemplateField HeaderText="IEPS">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:Label ID="lbliEPS" runat="server" Text='<%# Eval("IEPS","{0:N2}")%>'> </asp:Label>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
</Columns>
|
||||||
|
</asp:GridView>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
</asp:Content>
|
||||||
|
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
|
||||||
|
</asp:Content>
|
||||||
|
|
||||||
122
General/CATIEPSxEntidadFed.aspx.cs
Normal file
122
General/CATIEPSxEntidadFed.aspx.cs
Normal file
@@ -0,0 +1,122 @@
|
|||||||
|
using System;
|
||||||
|
using System.Collections.Generic;
|
||||||
|
using System.Linq;
|
||||||
|
using System.Web;
|
||||||
|
using System.Web.UI;
|
||||||
|
using System.Web.UI.WebControls;
|
||||||
|
using Extensiones;
|
||||||
|
using Microsoft.Reporting.WebForms;
|
||||||
|
using System.Data;
|
||||||
|
public partial class General_CATIEPSxEntidadFed : ClsPaginas
|
||||||
|
{
|
||||||
|
#region Propiedades
|
||||||
|
private int RAgrupador
|
||||||
|
{
|
||||||
|
get { return (ViewState["RAgrupador"] == null) ? 1 : Convert.ToInt32(ViewState["RAgrupador"]); }
|
||||||
|
set { ViewState["RAgrupador"] = value; }
|
||||||
|
}
|
||||||
|
private int RcveEstado
|
||||||
|
{
|
||||||
|
get { return (ViewState["RcveEstado"] == null) ? 0 : Convert.ToInt32(ViewState["RcveEstado"]); }
|
||||||
|
set { ViewState["RcveEstado"] = value; }
|
||||||
|
}
|
||||||
|
private decimal RtasaIEPS
|
||||||
|
{
|
||||||
|
get { return (ViewState["RtasaIEPS"] == null) ? 0 : Convert.ToDecimal(ViewState["RtasaIEPS"]); }
|
||||||
|
set { ViewState["RtasaIEPS"] = value; }
|
||||||
|
}
|
||||||
|
private string RfechaInicio
|
||||||
|
{
|
||||||
|
get { return (ViewState["RfechaInicio"] == null) ? "-1" : (ViewState["RfechaInicio"]).ToString(); }
|
||||||
|
set { ViewState["RfechaInicio"] = value; }
|
||||||
|
}
|
||||||
|
private string RfechaFin
|
||||||
|
{
|
||||||
|
get { return (ViewState["RfechaFin"] == null) ? "-1" : (ViewState["RfechaFin"]).ToString(); }
|
||||||
|
set { ViewState["RfechaFin"] = value; }
|
||||||
|
}
|
||||||
|
private DataTable DtIEPS{
|
||||||
|
get { return (ViewState["DtIEPS"] == null) ? null : (DataTable)(ViewState["DtIEPS"]); }
|
||||||
|
set { ViewState["DtIEPS"] = value; }
|
||||||
|
}
|
||||||
|
|
||||||
|
#endregion
|
||||||
|
protected void Page_Load(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
if (!IsPostBack)
|
||||||
|
{
|
||||||
|
|
||||||
|
DdlEstado.DataSource = get_GlobalDTEstado("Mex");
|
||||||
|
DdlEstado.DataBind();
|
||||||
|
|
||||||
|
|
||||||
|
DdlEstado.Items.Insert(0, new ListItem("Seleccione", "-1"));
|
||||||
|
RcveEstado = Request["cveEstado"] == null ? -1 : Request["cveEstado"].ToString().ToEntero();
|
||||||
|
RtasaIEPS = Request["tasaIEPS"] == null ? -1 : Request["tasaIEPS"].ToString().ToDecimal();
|
||||||
|
RfechaInicio = Request["fechaInicio"] == null ? string.Format("01/{0:MM/yyyy}", DateTime.Now.AddMonths(-1)) : Request["fechaInicio"].ToString();
|
||||||
|
RfechaFin = Request["fechaFin"] == null ? string.Format("{0:dd/MM/yyyy}", DateTime.Now.AddMonths(-1).LastDayOfMonth()) : Request["fechaFin"].ToString();
|
||||||
|
DdlEstado.SelectedValueExist(RcveEstado.ToString());
|
||||||
|
DdlIeps.SelectedValueExist(RtasaIEPS.ToString());
|
||||||
|
TxtIEPSfechaInicio.Text = $"{RfechaInicio:dd/MM/yyyy}";
|
||||||
|
TxtIEPSfechaFin.Text = $"{RfechaFin:dd/MM/yyyy}";
|
||||||
|
|
||||||
|
RfechaInicio = RfechaInicio.ToDate().ToString("yyyy/MM/dd");
|
||||||
|
RfechaFin = RfechaFin.ToDate().ToString("yyyy/MM/dd");
|
||||||
|
CargaIEPSxEntidadFed();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
protected void CargaIEPSxEntidadFed()
|
||||||
|
{
|
||||||
|
ClsGenerales ObjIEPS = new ClsGenerales();
|
||||||
|
ObjIEPS.IEPSxEntidadFed(RcveEstado, RtasaIEPS, RfechaInicio, RfechaFin, 119, RAgrupador);
|
||||||
|
GVIEPSxEntidadFed.DataSource = ObjIEPS.DtResultados;
|
||||||
|
DtIEPS = ObjIEPS.DtResultados;
|
||||||
|
ObjIEPS.Dispose();
|
||||||
|
GVIEPSxEntidadFed.DataBind();
|
||||||
|
upDatosIEPS.Update();
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void GVIEPSxEntidadFed_RowDataBound(object sender, GridViewRowEventArgs e)
|
||||||
|
{
|
||||||
|
if (e.Row.RowType == DataControlRowType.DataRow)
|
||||||
|
{
|
||||||
|
int cveGrupo = e.Row.DBCampo("CveGrupo").ToEntero();
|
||||||
|
if (cveGrupo == 1)
|
||||||
|
{
|
||||||
|
e.Row.CssClass = "Titulos";
|
||||||
|
}
|
||||||
|
if (cveGrupo == 2)
|
||||||
|
{
|
||||||
|
e.Row.CssClass = "Totales";
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
protected void BtnIEPSFiltrar_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
|
||||||
|
RAgrupador = DdlAgrupador.SelectedValue.ToEntero();
|
||||||
|
RcveEstado = DdlEstado.SelectedValue.ToEntero();
|
||||||
|
RtasaIEPS = DdlIeps.SelectedValue.ToDecimal();
|
||||||
|
RfechaInicio = TxtIEPSfechaInicio.Text.ToDate().ToString("yyyy/MM/dd");
|
||||||
|
RfechaFin = TxtIEPSfechaFin.Text.ToDate().ToString("yyyy/MM/dd");
|
||||||
|
|
||||||
|
CargaIEPSxEntidadFed();
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void LnkExcel_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
GVIEPSxEntidadFed.ExportToExcelx("IEPS porEntidad Federativa");
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void LnkPDF_Click(object sender, EventArgs e)
|
||||||
|
{
|
||||||
|
List<ReportParameter> paramList = new List<ReportParameter>();
|
||||||
|
paramList.Add(new ReportParameter("Logo", String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.jpg", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)));
|
||||||
|
paramList.Add(new ReportParameter("FechaInicio", TxtIEPSfechaInicio.Text));
|
||||||
|
paramList.Add(new ReportParameter("FechaFin", TxtIEPSfechaFin.Text));
|
||||||
|
paramList.Add(new ReportParameter("Agrupador", DdlAgrupador.SelectedValue));
|
||||||
|
|
||||||
|
ImprimirPDF("Empresas/Grales/Formatos/CatIepsEntidadFed.rdlc", DtIEPS, paramList,"IEPS por entidades federativa",RDSName:"DsInventarios");
|
||||||
|
}
|
||||||
|
}
|
||||||
@@ -807,6 +807,8 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
End If
|
End If
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub CargaCompra(pCveCompra As Integer, pCveProveedor As Integer)
|
Private Sub CargaCompra(pCveCompra As Integer, pCveProveedor As Integer)
|
||||||
|
CargaAlmacenes(-1)
|
||||||
|
|
||||||
Dim ObjCompras As New ClsCompras
|
Dim ObjCompras As New ClsCompras
|
||||||
Dim ObjInventario As New ClsInventarios
|
Dim ObjInventario As New ClsInventarios
|
||||||
|
|
||||||
@@ -838,16 +840,34 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
CargaAlmacenes(-1, "21,2")
|
CargaAlmacenes(-1, "21,2")
|
||||||
End If
|
End If
|
||||||
RecibidaCompleta = False
|
RecibidaCompleta = False
|
||||||
|
|
||||||
|
Dim CargaSoloUsados As Boolean = False
|
||||||
If ObjInventario.RecepcionAlmacenGet(pCveCompra, BuscaEntregaDirecta, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
|
If ObjInventario.RecepcionAlmacenGet(pCveCompra, BuscaEntregaDirecta, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
|
||||||
|
Dim DtRecepcion As DataTable = Nothing
|
||||||
|
Dim NumUsados = ObjInventario.DtResultados.COUNT("EsUsado", "EsUsado = True").ToEntero()
|
||||||
|
Dim NumProductos = ObjInventario.DtResultados.COUNT("EsUsado", "EsUsado = False").ToEntero()
|
||||||
|
|
||||||
|
'SI LA COMPRA TIENE PRODUCTOS Y USADOS SOLO MOSTRAR LOS PRODUCTOS
|
||||||
|
If NumProductos > 0 AndAlso NumUsados > 0 Then
|
||||||
|
DtRecepcion = ObjInventario.DtResultados.FiltraParametros("EsUsado = False")
|
||||||
|
'SI LA COMPRA TIENE PUROS USADOS, MOSTRAR LOS USADOS Y CARGAR LOS ALMACENES
|
||||||
|
ElseIf NumProductos = 0 AndAlso NumUsados > 0 Then
|
||||||
|
CargaSoloUsados = True
|
||||||
|
DtRecepcion = ObjInventario.DtResultados.Copy()
|
||||||
|
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, "22")
|
||||||
|
Else
|
||||||
|
DtRecepcion = ObjInventario.DtResultados.Copy()
|
||||||
|
End If
|
||||||
|
|
||||||
DtDatosDetalle = Nothing
|
DtDatosDetalle = Nothing
|
||||||
CreaDtDetalle()
|
CreaDtDetalle()
|
||||||
DtDatosLoteDetalle = Nothing
|
DtDatosLoteDetalle = Nothing
|
||||||
CreaDtLoteDetalle()
|
CreaDtLoteDetalle()
|
||||||
CreaDTInv(ObjInventario.DtResultados)
|
CreaDTInv(DtRecepcion)
|
||||||
BtnGuardar.Visible = True
|
BtnGuardar.Visible = True
|
||||||
|
|
||||||
'cuando están todos los detalles de la compra, nos indica que se va a recibir la totalidad de la compra
|
'cuando están todos los detalles de la compra, nos indica que se va a recibir la totalidad de la compra
|
||||||
If ObjInventario.DtResultados.Rows.Count = ObjInventario.DtResultados.Rows(0)("NumDetalles").ToString.ToEntero Then
|
If DtRecepcion.Rows.Count = DtRecepcion.Rows(0)("NumDetalles").ToString.ToEntero Then
|
||||||
RecibidaCompleta = True
|
RecibidaCompleta = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -869,8 +889,8 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
LtAdvertencia.Text = "La mercancía tendra salida inmediata por ser entrega directa al cliente"
|
LtAdvertencia.Text = "La mercancía tendra salida inmediata por ser entrega directa al cliente"
|
||||||
DivAdvertencia.Visible = True
|
DivAdvertencia.Visible = True
|
||||||
EntregaDirecta = True
|
EntregaDirecta = True
|
||||||
CveCliente = ObjInventario.DtResultados.Rows(0)("CveCliente").ToString.ToEntero
|
CveCliente = DtRecepcion.Rows(0)("CveCliente").ToString.ToEntero
|
||||||
CveVendedor = ObjInventario.DtResultados.Rows(0)("CveVendedor").ToString.ToEntero
|
CveVendedor = DtRecepcion.Rows(0)("CveVendedor").ToString.ToEntero
|
||||||
|
|
||||||
|
|
||||||
If DtInv.COUNT("EntregaDirecta") <> DtInv.Rows.Count Then
|
If DtInv.COUNT("EntregaDirecta") <> DtInv.Rows.Count Then
|
||||||
@@ -884,7 +904,7 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
Alert("No hay productos pendientes de surtir de esta compra. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
|
Alert("No hay productos pendientes de surtir de esta compra. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgAdvertencia)
|
||||||
Else
|
Else
|
||||||
|
|
||||||
If ObjInventario.DtResultados.Rows(0)("CveVendedor").ToString.ToEntero > 0 And ObjInventario.DtResultados.Rows(0)("CveCliente").ToString.ToEntero > 0 Then
|
If DtRecepcion.Rows(0)("CveVendedor").ToString.ToEntero > 0 And DtRecepcion.Rows(0)("CveCliente").ToString.ToEntero > 0 Then
|
||||||
If DtInv.SUM("EntregaDirecta") > 0 Then
|
If DtInv.SUM("EntregaDirecta") > 0 Then
|
||||||
''ENTREGA DIRECTA
|
''ENTREGA DIRECTA
|
||||||
'LtAdvertencia.Text = "La mercancía tendra salida inmediata por ser entrega directa al cliente"
|
'LtAdvertencia.Text = "La mercancía tendra salida inmediata por ser entrega directa al cliente"
|
||||||
@@ -892,9 +912,9 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
'EntregaDirecta = True
|
'EntregaDirecta = True
|
||||||
Else
|
Else
|
||||||
'APARTADO
|
'APARTADO
|
||||||
'If UsuarioActual.CveUsuario.Contiene(100) Or (ObjInventario.DtResultados.Rows(0)("CveUsuarioOC").ToString.ToEntero = 1559 And ObjInventario.DtResultados.Rows(0)("FechaIngOC").ToString.ToDateTime > "2017-04-24 12:00".ToDateTime) Then
|
'If UsuarioActual.CveUsuario.Contiene(100) Or (DtRecepcion .Rows(0)("CveUsuarioOC").ToString.ToEntero = 1559 And DtRecepcion .Rows(0)("FechaIngOC").ToString.ToDateTime > "2017-04-24 12:00".ToDateTime) Then
|
||||||
If UsuarioActual.Empresa.Funcionalidad(148) = "1" Then
|
If UsuarioActual.Empresa.Funcionalidad(148) = "1" Then
|
||||||
CveAlmacenApartado = ObjInventario.DtResultados.Rows(0)("CveAlmacenApartado").ToString.ToEntero
|
CveAlmacenApartado = DtRecepcion.Rows(0)("CveAlmacenApartado").ToString.ToEntero
|
||||||
DivAdvertencia.Visible = True
|
DivAdvertencia.Visible = True
|
||||||
Apartado = True
|
Apartado = True
|
||||||
|
|
||||||
@@ -903,7 +923,11 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
LtAdvertencia.Text = "No se puede recibir la mercancía por ser de apartados y no contar con un almacen de apartado."
|
LtAdvertencia.Text = "No se puede recibir la mercancía por ser de apartados y no contar con un almacen de apartado."
|
||||||
Else
|
Else
|
||||||
LtAdvertencia.Text = "La mercancía sera traspasada ha apartados"
|
LtAdvertencia.Text = "La mercancía sera traspasada ha apartados"
|
||||||
CargaAlmacenes(ObjInventario.DtResultados.Rows(0)("CveSubProyecto").ToString.ToEntero)
|
If CargaSoloUsados Then
|
||||||
|
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero, "22")
|
||||||
|
Else
|
||||||
|
CargaAlmacenes(DtRecepcion.Rows(0)("CveSubProyecto").ToString.ToEntero)
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
'End If
|
'End If
|
||||||
@@ -912,19 +936,19 @@ Partial Class Inventarios_RecepcionAlmacen
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
Dim CantidadFaltante As Double = ObjInventario.DtResultados.SUM("CantidadC", "CantidadF > 0")
|
Dim CantidadFaltante As Double = DtRecepcion.SUM("CantidadC", "CantidadF > 0")
|
||||||
|
|
||||||
If UsuarioActual.Empresa.UsaAC AndAlso CantidadFaltante > 0 Then
|
If UsuarioActual.Empresa.UsaAC AndAlso CantidadFaltante > 0 Then
|
||||||
PnlAC.Visible = True
|
PnlAC.Visible = True
|
||||||
CargaAC()
|
CargaAC()
|
||||||
LbTotalPorDevengar.Text = ObjInventario.DtResultados.SUM("Total", "CantidadF > 0").FormatoNumero
|
LbTotalPorDevengar.Text = DtRecepcion.SUM("Total", "CantidadF > 0").FormatoNumero
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
'Existencias
|
'Existencias
|
||||||
If TipoMovimiento = 2 Then
|
If TipoMovimiento = 2 Then
|
||||||
If ObjInventario.ComprasDevolucionExistenciasGet(CveCompraSurtir) Then
|
If ObjInventario.ComprasDevolucionExistenciasGet(CveCompraSurtir) Then
|
||||||
DtExistencias = ObjInventario.DtResultados
|
DtExistencias = DtRecepcion
|
||||||
Else
|
Else
|
||||||
Alert("No se pudieron cargar las existencias del movimiento de entrada, por lo cual no se podra hacer la devolución.", TipoMensaje.MsgError)
|
Alert("No se pudieron cargar las existencias del movimiento de entrada, por lo cual no se podra hacer la devolución.", TipoMensaje.MsgError)
|
||||||
BtnGuardar.Enabled = False
|
BtnGuardar.Enabled = False
|
||||||
|
|||||||
@@ -100,13 +100,16 @@ Partial Class RepTraspasoAlmacen
|
|||||||
If e.Row.RowType = DataControlRowType.DataRow Then
|
If e.Row.RowType = DataControlRowType.DataRow Then
|
||||||
|
|
||||||
'Cuando es titulo
|
'Cuando es titulo
|
||||||
If e.Row.DBCampo("PS").ToString.Trim = "" Then
|
If e.Row.DBCampo("PS").ToString.Trim = "" And e.Row.DBCampo("FechaMovto") <> "" Then
|
||||||
|
|
||||||
e.Row.CssClass = "Totales"
|
e.Row.CssClass = "Totales"
|
||||||
|
|
||||||
e.Row.Cells(0).Text = String.Format("Folio: <a class=""texto"" style=""color:white;"" target='_blank' href='/Inventarios/EntradasSalidas.aspx?CveMovimiento={1}'>{0}</a> ", e.Row.DBCampo("FolioSalida"), e.Row.DBCampo("CveMovimientoSalida"))
|
e.Row.Cells(0).Text = String.Format("Folio: <a class=""texto"" style=""color:white;"" target='_blank' href='/Inventarios/EntradasSalidas.aspx?CveMovimiento={1}'>{0}</a> ", e.Row.DBCampo("FolioSalida"), e.Row.DBCampo("CveMovimientoSalida"))
|
||||||
e.Row.Cells(1).Text = String.Format("{0}", e.Row.DBCampo("FechaMovto").ToString.ToDate.ToShortDateString)
|
e.Row.Cells(1).Text = String.Format("{0}", e.Row.DBCampo("FechaMovto").ToString.ToDate.ToShortDateString)
|
||||||
e.Row.Cells(3).Text = String.Format("Almacen Origen: {0} Almacen Destino: {1} Responsable: {2}", e.Row.DBCampo("Almacen"), e.Row.DBCampo("AlmacenDestino"), e.Row.DBCampo("Recibio"))
|
e.Row.Cells(3).Text = String.Format("Almacen Origen: {0} Almacen Destino: {1} Responsable: {2}", e.Row.DBCampo("Almacen"), e.Row.DBCampo("AlmacenDestino"), e.Row.DBCampo("Recibio"))
|
||||||
|
ElseIf e.Row.DBCampo("FechaMovto") = "" Then
|
||||||
|
e.Row.CssClass = "Totales"
|
||||||
|
e.Row.Cells(0).Text = "Total General"
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -907,9 +907,11 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
Dim Concepto As String = TxtObservaciones.Text
|
||||||
|
If Concepto = "" Then Concepto = "Traspaso"
|
||||||
'AGREGAMOS PREPOLIZAS TRASPASO DIRECTO:
|
'AGREGAMOS PREPOLIZAS TRASPASO DIRECTO:
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, TxtObservaciones.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, Concepto, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
||||||
|
|
||||||
Dim resultado As DataTable = ObjInventario.DtResultados
|
Dim resultado As DataTable = ObjInventario.DtResultados
|
||||||
@@ -920,11 +922,11 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
|
|
||||||
If IdCtaContableSalida = IdCtaContableEntrada Then Contabilizable = False
|
If IdCtaContableSalida = IdCtaContableEntrada Then Contabilizable = False
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContableSalida, -1, CveMovimientoAlmacen:=CveMovimientoSalida, Contabilizable:=Contabilizable) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContableSalida, -1, CveMovimientoAlmacen:=CveMovimientoSalida, Contabilizable:=Contabilizable, ImporteMX:=importe) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContableEntrada, -1, CveMovimientoAlmacen:=CveMovimientoEntrada, Contabilizable:=Contabilizable) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContableEntrada, -1, CveMovimientoAlmacen:=CveMovimientoEntrada, Contabilizable:=Contabilizable, ImporteMX:=importe) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -932,18 +934,20 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, TxtObservaciones.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
Dim Concepto As String = TxtObservaciones.Text
|
||||||
|
If Concepto = "" Then Concepto = "Traspaso"
|
||||||
|
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, Concepto, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
||||||
|
|
||||||
Dim resultado As DataTable = ObjInventario.DtResultados
|
Dim resultado As DataTable = ObjInventario.DtResultados
|
||||||
Dim importe As Decimal = resultado.SUM("Total").ToDecimal
|
Dim importe As Decimal = resultado.SUM("Total").ToDecimal
|
||||||
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorio.SelectedValue.ToEntero)).ToEntero
|
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorio.SelectedValue.ToEntero)).ToEntero
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=importe, Contabilizable:=False) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 289, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 289, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=importe, Contabilizable:=False) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -1507,6 +1511,7 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
Dim ObjInventario As New ClsInventarios
|
Dim ObjInventario As New ClsInventarios
|
||||||
|
Dim ObjConta As New ClsContabilidad(ObjInventario.IniciaTransacSQL())
|
||||||
ObjInventario.IniciaTransacSQL()
|
ObjInventario.IniciaTransacSQL()
|
||||||
Dim CveMovimientoEntrada As Integer = 0
|
Dim CveMovimientoEntrada As Integer = 0
|
||||||
Dim Folio = 0
|
Dim Folio = 0
|
||||||
@@ -1514,31 +1519,58 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
Dim TextoError = ""
|
Dim TextoError = ""
|
||||||
Dim Fecha As Date = TxtFechaRecepcion.Text.ToDate
|
Dim Fecha As Date = TxtFechaRecepcion.Text.ToDate
|
||||||
|
|
||||||
CveMovimientoEntrada = ObjInventario.AddMovimiento(GvDatosRecepcion.Rows(0).DataKey("CveAlmacenDestino").ToEntero, 27, 1, Fecha, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1,
|
CveMovimientoEntrada = ObjInventario.AddMovimiento(GvDatosRecepcion.Rows(0).DataKey("CveAlmacenSalida").ToEntero, 27, 1, Fecha, -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, -1, -1, -1,
|
||||||
Observaciones:=TxtObservacionesRecepcion.Text.Trim, Recibio:=TxtRecibio.Text, CveAlmacenDestino:=GvDatosRecepcion.Rows(0).DataKey("CveAlmacenDestino").ToEntero, CveMovimientoRelacionado:=CveMovimientoSalida, Modulo:="TA/G")
|
Observaciones:=TxtObservacionesRecepcion.Text.Trim, Recibio:=TxtRecibio.Text, CveAlmacenDestino:=GvDatosRecepcion.Rows(0).DataKey("CveAlmacenSalida").ToEntero,
|
||||||
|
CveMovimientoRelacionado:=CveMovimientoSalida, Modulo:="TA/G")
|
||||||
|
|
||||||
|
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, TxtObservacionesRecepcion.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
|
If CvePrePoliza <= 0 Then
|
||||||
|
TextoError = "No se pudo generar la Poliza para la cancelacion"
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
|
||||||
Folio = ObjInventario.Folio
|
Folio = ObjInventario.Folio
|
||||||
|
|
||||||
If CveMovimientoEntrada <= 0 Then
|
If CveMovimientoEntrada <= 0 And Not ErrorMovInv Then
|
||||||
TextoError = "No se pudo generar el movimiento de entrada correctamente"
|
TextoError = "No se pudo generar el movimiento de entrada correctamente"
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
Else
|
Else
|
||||||
Dim CveMovimientoDetalleSalida As Integer = 0
|
Dim CveMovimientoDetalleSalida As Integer = 0
|
||||||
|
Dim importe As Double = 0
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
||||||
For Each Dr As DataRow In ObjInventario.DtResultados.Rows
|
For Each Dr As DataRow In ObjInventario.DtResultados.Rows
|
||||||
CveMovimientoDetalleSalida = Dr("CveMovimientoDetalle").ToString.ToEntero
|
CveMovimientoDetalleSalida = Dr("CveMovimientoDetalle").ToString.ToEntero
|
||||||
|
Dim Cantidad As Double = Dr("Cantidad").ToString.ToDouble
|
||||||
|
Dim PrecioUnitario As Double = Dr("PU").ToString.ToDouble
|
||||||
If CveMovimientoDetalleSalida <= 0 Then
|
If CveMovimientoDetalleSalida <= 0 Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
TextoError = "Ocurrió un error al guardar los movimientos de salida"
|
TextoError = "Ocurrió un error al guardar los movimientos de salida"
|
||||||
Exit For
|
Exit For
|
||||||
End If
|
End If
|
||||||
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDouble, Dr("CveAF").ToString.ToEntero, -1, Dr("SerieLote").ToString, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, CveMovimientoDetalleEntrada:=CveMovimientoDetalleSalida) Then
|
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Cantidad, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, PrecioUnitario, Dr("CveAF").ToString.ToEntero, -1, Dr("SerieLote").ToString, Lote:=Dr("Lote").ToString, Batch:=Dr("Batch").ToString, CveMovimientoDetalleEntrada:=CveMovimientoDetalleSalida) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
TextoError = "Ocurrió un error al guardar los movimientos de entrada"
|
TextoError = "Ocurrió un error al guardar los movimientos de entrada"
|
||||||
Exit For
|
Exit For
|
||||||
End If
|
End If
|
||||||
|
importe += Cantidad * PrecioUnitario
|
||||||
Next
|
Next
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
If Not ErrorMovInv Then
|
||||||
|
Dim ImporteDecimal As Decimal = importe.ToDecimal
|
||||||
|
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorioRecepcion.SelectedValue.ToEntero)).ToEntero
|
||||||
|
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, ImporteDecimal, TxtObservaciones.Text, 289, TxtObservaciones.Text, Fecha, IdCtaContable, -1,
|
||||||
|
CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=ImporteDecimal) Then
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, ImporteDecimal, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContable, -1,
|
||||||
|
CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=ImporteDecimal) Then
|
||||||
|
ErrorMovInv = True
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
@@ -1561,8 +1593,10 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
UPDatosAlmacen.Update()
|
UPDatosAlmacen.Update()
|
||||||
Else
|
Else
|
||||||
ObjInventario.RollBack()
|
ObjInventario.RollBack()
|
||||||
|
ObjConta.RollBack()
|
||||||
Alert(TextoError, TipoMensaje.MsgError)
|
Alert(TextoError, TipoMensaje.MsgError)
|
||||||
End If
|
End If
|
||||||
|
ObjConta.Dispose()
|
||||||
ObjInventario.Dispose()
|
ObjInventario.Dispose()
|
||||||
CargaRecepcion()
|
CargaRecepcion()
|
||||||
End Sub
|
End Sub
|
||||||
@@ -1668,18 +1702,20 @@ Partial Class Inventarios_TraspasoAlmacen
|
|||||||
Cont += 1
|
Cont += 1
|
||||||
Next
|
Next
|
||||||
If Not ErrorMovInv Then
|
If Not ErrorMovInv Then
|
||||||
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, TxtObservacionesRecepcion.Text, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
Dim Concepto As String = TxtObservacionesRecepcion.Text
|
||||||
|
If Concepto = "" Then Concepto = "Recepción Traspaso"
|
||||||
|
Dim CvePrePoliza As Integer = ObjConta.AddPrePolizas("Inventario/TraspasoAlmacen", 53, 0, 0, 1, Fecha, Concepto, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
|
||||||
|
|
||||||
Dim resultado As DataTable = ObjInventario.DtResultados
|
Dim resultado As DataTable = ObjInventario.DtResultados
|
||||||
Dim importe As Decimal = resultado.SUM("Total").ToDecimal
|
Dim importe As Decimal = resultado.SUM("Total").ToDecimal
|
||||||
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorioRecepcion.SelectedValue.ToEntero)).ToEntero
|
Dim IdCtaContable As Integer = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", DdlAlmacenTransitorioRecepcion.SelectedValue.ToEntero)).ToEntero
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 289, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 289, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=importe, Contabilizable:=False) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida) Then
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, importe, TxtObservaciones.Text, 68, TxtObservaciones.Text, Fecha, IdCtaContable, -1, CveMovimientoAlmacen:=CveMovimientoSalida, ImporteMX:=importe, Contabilizable:=False) Then
|
||||||
ErrorMovInv = True
|
ErrorMovInv = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -2793,7 +2793,7 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
|
|
||||||
'CANCELA IE
|
'CANCELA IE
|
||||||
If Not ErrorCancelar Then
|
If Not ErrorCancelar Then
|
||||||
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, True, IdPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, True, IdPolizaNueva, FolioPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
||||||
ErrorCancelar = True
|
ErrorCancelar = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -2820,7 +2820,7 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
|
|
||||||
'CANCELA IE
|
'CANCELA IE
|
||||||
If Not ErrorCancelar Then
|
If Not ErrorCancelar Then
|
||||||
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, False, IdPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, False, IdPolizaNueva, FolioPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
||||||
ErrorCancelar = True
|
ErrorCancelar = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -2833,12 +2833,12 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
|
|
||||||
If FechaCorteIE.Month < TxtFechaDocumento.Text.ToDate.Month Or FechaCorteIE.Year < TxtFechaDocumento.Text.ToDate.Year Then
|
If FechaCorteIE.Month < TxtFechaDocumento.Text.ToDate.Month Or FechaCorteIE.Year < TxtFechaDocumento.Text.ToDate.Year Then
|
||||||
'CANCELA IE MES ANTERIOR
|
'CANCELA IE MES ANTERIOR
|
||||||
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, True, IdPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, True, IdPolizaNueva, FolioPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
||||||
ErrorCancelar = True
|
ErrorCancelar = True
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
'CANCELA IE MES ACTUAL
|
'CANCELA IE MES ACTUAL
|
||||||
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, False, IdPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
If Not Banc.CancelarBancos_IE(UsuarioActual.CveUsuario, CveIESustitucion, False, IdPolizaNueva, FolioPolizaNueva, TxtFechaDocumento.Text.ToDate) Then
|
||||||
ErrorCancelar = True
|
ErrorCancelar = True
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|||||||
@@ -2918,7 +2918,7 @@
|
|||||||
<div class="form-group form-md-line-input input-iconright">
|
<div class="form-group form-md-line-input input-iconright">
|
||||||
<asp:TextBox ID="TxtCodInspeccion" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
|
<asp:TextBox ID="TxtCodInspeccion" CssClass="form-control" runat="server" MaxLength="50"></asp:TextBox>
|
||||||
<asp:CustomValidator id="CVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" ClientValidationFunction="ValidarCodigoInspeccion" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod.Inspección''</b> es incorrecto, por favor ingréselo correctamente." ValidationGroup="GrpAddVenta" />
|
<asp:CustomValidator id="CVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" ClientValidationFunction="ValidarCodigoInspeccion" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod.Inspección''</b> es incorrecto, por favor ingréselo correctamente." ValidationGroup="GrpAddVenta" />
|
||||||
<asp:RegularExpressionValidator ID="REVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod. Inspección''</b> es incorrecto, por favor ingréselo correctamente." ValidationGroup="GrpAddVenta" ValidationExpression="^[A-L][0-9][1-9A-Z][A-HJ-M]$"></asp:RegularExpressionValidator>
|
<%-- <asp:RegularExpressionValidator ID="REVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" CssClass="help-block errorimput" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod. Inspección''</b> es incorrecto, por favor ingréselo correctamente." ValidationGroup="GrpAddVenta" ValidationExpression="^[A-L][0-9][1-9A-Z][A-HJ-M]$"></asp:RegularExpressionValidator>--%>
|
||||||
<%--<asp:RequiredFieldValidator ID="RFVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod. Inspeccion''</b> es necesario, por favor ingréselo." ValidationGroup="VGMAjuste"></asp:RequiredFieldValidator>--%>
|
<%--<asp:RequiredFieldValidator ID="RFVCodInspeccion" runat="server" ControlToValidate="TxtCodInspeccion" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cod. Inspeccion''</b> es necesario, por favor ingréselo." ValidationGroup="VGMAjuste"></asp:RequiredFieldValidator>--%>
|
||||||
<%--<ajax:ValidatorCalloutExtender ID="VCECodInspeccion" runat="server" HighlightCssClass="vco" TargetControlID="RFVCodInspeccion"></ajax:ValidatorCalloutExtender>--%>
|
<%--<ajax:ValidatorCalloutExtender ID="VCECodInspeccion" runat="server" HighlightCssClass="vco" TargetControlID="RFVCodInspeccion"></ajax:ValidatorCalloutExtender>--%>
|
||||||
<label for="<%= TxtCodInspeccion.ClientID.ToString()%>">Cod. Inspección:</label>
|
<label for="<%= TxtCodInspeccion.ClientID.ToString()%>">Cod. Inspección:</label>
|
||||||
@@ -3019,7 +3019,8 @@
|
|||||||
|
|
||||||
//SI ES MOTOBATERIA
|
//SI ES MOTOBATERIA
|
||||||
if (CveClasificacion = "20517") {
|
if (CveClasificacion = "20517") {
|
||||||
regex = "[*]|"
|
regex = "[1X]|"
|
||||||
|
//regex = "[*]|"
|
||||||
//SI ES OPTIMA
|
//SI ES OPTIMA
|
||||||
} else if (CveClasificacion = "20511") {
|
} else if (CveClasificacion = "20511") {
|
||||||
regex = "[1X]|"
|
regex = "[1X]|"
|
||||||
@@ -3064,15 +3065,25 @@
|
|||||||
let clasificaciones = ["20517", "20511"]
|
let clasificaciones = ["20517", "20511"]
|
||||||
|
|
||||||
//SI ES MOTOBATERIA
|
//SI ES MOTOBATERIA
|
||||||
if (clasificaciones.includes(CveClasificacion)) {
|
if (CveClasificacion = "20517") {
|
||||||
var re = new RegExp("^[*]|[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
var re = new RegExp("^[X]|[x]|[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
||||||
arguments.IsValid = re.test(parseInt(arguments.Value));
|
arguments.IsValid = re.test(arguments.Value);
|
||||||
return;
|
return;
|
||||||
} else {
|
} else {
|
||||||
var re = new RegExp("^[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
var re = new RegExp("^[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
||||||
arguments.IsValid = re.test(arguments.Value);
|
arguments.IsValid = re.test(arguments.Value);
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
//if (clasificaciones.includes(CveClasificacion)) {
|
||||||
|
// //var re = new RegExp("^[*]|[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
||||||
|
// var re = new RegExp("^[X]|[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
||||||
|
// arguments.IsValid = re.test(parseInt(arguments.Value));
|
||||||
|
// return;
|
||||||
|
//} else {
|
||||||
|
// var re = new RegExp("^[A-L][0-9][1-9A-Z][A-HJ-M]$");
|
||||||
|
// arguments.IsValid = re.test(arguments.Value);
|
||||||
|
// return;
|
||||||
|
//}
|
||||||
}
|
}
|
||||||
|
|
||||||
function CalculaMesesUso() {
|
function CalculaMesesUso() {
|
||||||
|
|||||||
@@ -2882,6 +2882,15 @@ Partial Class PV
|
|||||||
End If
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
'Descuento por clasificación
|
||||||
|
If drPS("CveClasificacion").ToString.ToEntero.Contiene(20516, 20515) Then
|
||||||
|
Dim clasificacionesDescuentos As New Dictionary(Of Integer, Double) From {
|
||||||
|
{20516, 0.23}, 'Descuento para lubricantes LTH
|
||||||
|
{20515, 0.24} 'Descuento para filtros LTH
|
||||||
|
}
|
||||||
|
TxtDescuento.Text = (PrecioSugerido * clasificacionesDescuentos(drPS("CveClasificacion").ToString.ToEntero)).ToString("F2")
|
||||||
|
End If
|
||||||
|
|
||||||
If ChkAjuste.Checked Then
|
If ChkAjuste.Checked Then
|
||||||
CalculaMesesUso()
|
CalculaMesesUso()
|
||||||
UpAjuste.Update()
|
UpAjuste.Update()
|
||||||
@@ -5089,7 +5098,7 @@ Partial Class PV
|
|||||||
|
|
||||||
Dim ObjGral As New ClsGenerales
|
Dim ObjGral As New ClsGenerales
|
||||||
If ObjGral.BCIUsadoGet(UsuarioActual.CveEmpresa) Then
|
If ObjGral.BCIUsadoGet(UsuarioActual.CveEmpresa) Then
|
||||||
e.Row.FCDropDownList("DdlBCIUsado").DataSource = ObjGral.DtResultados
|
e.Row.FCDropDownList("DdlBCIUsado").DataSource = ObjGral.DtResultados.FiltraParametros(String.Format("CveTamaño = {0}", e.Row.DataKey("CveTamaño")))
|
||||||
End If
|
End If
|
||||||
'DdlBCIUsado.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
'DdlBCIUsado.Items.Insert(0, New ListItem("Seleccione", "-1"))
|
||||||
'DdlBCIUsado.SelectedValueExist(-1)
|
'DdlBCIUsado.SelectedValueExist(-1)
|
||||||
@@ -5503,7 +5512,14 @@ Partial Class PV
|
|||||||
Dim ObjAcumuladores As New ClsAcumuladores
|
Dim ObjAcumuladores As New ClsAcumuladores
|
||||||
If ObjAcumuladores.GetNuevoConsecutivoFolio(DdlFolioGarantia.SelectedValue.ToEntero) Then
|
If ObjAcumuladores.GetNuevoConsecutivoFolio(DdlFolioGarantia.SelectedValue.ToEntero) Then
|
||||||
Dim resultado As Integer = ObjAcumuladores.DtResultados.FiltroPrimeroValor("NuevoConsecutivo").ToEntero
|
Dim resultado As Integer = ObjAcumuladores.DtResultados.FiltroPrimeroValor("NuevoConsecutivo").ToEntero
|
||||||
TxtConsecutivoAjuste.Text = resultado.ToString
|
If ObjAcumuladores.FoliosGarantiaGet(DdlFolioGarantia.SelectedValue.ToEntero, UsuarioActual.CveEmpresa) Then
|
||||||
|
Dim Limite As Integer = If(ObjAcumuladores.DtResultados.FiltroPrimeroValor("Limite") IsNot Nothing, ObjAcumuladores.DtResultados.FiltroPrimeroValor("Limite").ToEntero, 0) 'ObjAcumuladores.DtResultados.FiltroPrimeroValor("Limite").ToEntero
|
||||||
|
If resultado < Limite Or Limite = 0 Then
|
||||||
|
TxtConsecutivoAjuste.Text = resultado.ToString
|
||||||
|
Else
|
||||||
|
Alert("limite de folios alcanzado")
|
||||||
|
End If
|
||||||
|
End If
|
||||||
UpAjuste.Update()
|
UpAjuste.Update()
|
||||||
End If
|
End If
|
||||||
ObjAcumuladores.Dispose()
|
ObjAcumuladores.Dispose()
|
||||||
|
|||||||
@@ -5824,9 +5824,9 @@ Partial Class Ventas
|
|||||||
Dim objPS As New ClsProductosServicios
|
Dim objPS As New ClsProductosServicios
|
||||||
If objPS.GetPSSucursalesALL(CvePS, UsuarioActual.CveEmpresa, CveSubProyecto:=DdlSubProyectoDatos.SelectedValue.ToEntero) Then
|
If objPS.GetPSSucursalesALL(CvePS, UsuarioActual.CveEmpresa, CveSubProyecto:=DdlSubProyectoDatos.SelectedValue.ToEntero) Then
|
||||||
PrecioMinimo = objPS.DtResultados.FiltroPrimeroValor("PrecioMinimo", "").ToDecimal
|
PrecioMinimo = objPS.DtResultados.FiltroPrimeroValor("PrecioMinimo", "").ToDecimal
|
||||||
'If PrecioMinimo > 0 Then
|
If PrecioMinimo > 0 Then
|
||||||
' Costo = PrecioMinimo
|
Costo = PrecioMinimo
|
||||||
'End If
|
End If
|
||||||
End If
|
End If
|
||||||
objPS.Dispose()
|
objPS.Dispose()
|
||||||
|
|
||||||
@@ -6890,7 +6890,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
If ErrorList.Count = 0 Then
|
If ErrorList.Count = 0 Then
|
||||||
If ObjFactura.CveVenta > 0 And CveAlmacenExistenciasContrato > 0 And DdlTipoComprobante.SelectedValue = "Ing" Then
|
If ObjFactura.CveVenta > 0 And CveAlmacenExistenciasContrato > 0 And DdlTipoComprobante.SelectedValue = "Ing" Then
|
||||||
If Not RegistraAlmacenConsignacionVenta(ObjInventario, ObjFactura) Then
|
If Not RegistraAlmacenConsignacionVenta(ObjInventario, ObjConta, ObjFactura, ObjContPaq) Then
|
||||||
ErrorList.Add("Ocurrió un error al registrar los movimientos de almacén del contrato de consignación")
|
ErrorList.Add("Ocurrió un error al registrar los movimientos de almacén del contrato de consignación")
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
@@ -11533,8 +11533,8 @@ Partial Class Ventas
|
|||||||
HdnTieneAnticiposVinculados.Value = "0"
|
HdnTieneAnticiposVinculados.Value = "0"
|
||||||
|
|
||||||
Dim ObjMovtos As New ClsMovimientos()
|
Dim ObjMovtos As New ClsMovimientos()
|
||||||
If ObjMovtos.GetAnticiposNCIxCCliente(CveCliente, DdlMoneda.SelectedValue.ToEntero) Then
|
If ObjMovtos.GetAnticiposNCIxCCliente(CveCliente) Then
|
||||||
GVAnticipos.DataSource = ObjMovtos.DtResultados.FiltraParametros($"Saldo > 0 AND SaldoSubtotal > 0 {If(CveVenta < 0, "AND Tipo = 'Ant'", "")} {If(DdlTipoComprobante.SelectedValue = "Ant", "AND Tipo = 'NC'", "")}")
|
GVAnticipos.DataSource = ObjMovtos.DtResultados.FiltraParametros($"Saldo > 0 AND SaldoSubtotal > 0 {If(CveVenta < 0, $"AND Tipo = 'Ant'{If(DdlTipoComprobante.SelectedValue = "Ing", $" AND CveMoneda ={DdlMoneda.SelectedValue.ToEntero()}", "")} ", "")} {If(DdlTipoComprobante.SelectedValue = "Ant", "AND Tipo = 'NC'", "")}")
|
||||||
If ObjMovtos.DtResultados.SUM("Saldo", "Saldo > 0 AND SaldoSubtotal > 0 AND Tipo = 'Ant'") > 0 Then
|
If ObjMovtos.DtResultados.SUM("Saldo", "Saldo > 0 AND SaldoSubtotal > 0 AND Tipo = 'Ant'") > 0 Then
|
||||||
HdnTieneAnticipos.Value = "1"
|
HdnTieneAnticipos.Value = "1"
|
||||||
End If
|
End If
|
||||||
@@ -14624,6 +14624,7 @@ Partial Class Ventas
|
|||||||
TmpDT.Columns.Add("CveConcepto", GetType(Integer))
|
TmpDT.Columns.Add("CveConcepto", GetType(Integer))
|
||||||
|
|
||||||
TmpDT.Columns.Add("EsOutSourcing", GetType(Boolean))
|
TmpDT.Columns.Add("EsOutSourcing", GetType(Boolean))
|
||||||
|
TmpDT.Columns.Add("EsUsado", GetType(Boolean))
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
Private Sub CreaDTmpC()
|
Private Sub CreaDTmpC()
|
||||||
@@ -15711,7 +15712,8 @@ Partial Class Ventas
|
|||||||
|
|
||||||
Return Not OcurrioError
|
Return Not OcurrioError
|
||||||
End Function
|
End Function
|
||||||
Private Function GenerarMovimientoAlmacen(ByRef ObjInventario As ClsInventarios, DtMovDetalle As DataTable, CveAlmacen As Integer, ConceptoEntrada As Integer, CveMoneda As Integer, CveVenta As Integer, Optional MovimientoPrePoliza As Boolean = False, Optional ByRef ObjConta As ClsContabilidad = Nothing, Optional CveMovimientoRelacionado As Integer = -1, Optional AplicaMovimientoDetalleEntrada As Boolean = False) As Integer
|
Private Function GenerarMovimientoAlmacen(ByRef ObjInventario As ClsInventarios, DtMovDetalle As DataTable, CveAlmacen As Integer, ConceptoEntrada As Integer, CveMoneda As Integer, CveVenta As Integer, Optional MovimientoPrePoliza As Boolean = False,
|
||||||
|
Optional ByRef ObjConta As ClsContabilidad = Nothing, Optional CveMovimientoRelacionado As Integer = -1, Optional AplicaMovimientoDetalleEntrada As Boolean = False, Optional ObjContPaq As ClsContPAQi = Nothing) As Integer
|
||||||
Dim OcurrioError As Boolean = False
|
Dim OcurrioError As Boolean = False
|
||||||
Dim ContadorMovtosDetalles = 0
|
Dim ContadorMovtosDetalles = 0
|
||||||
|
|
||||||
@@ -15780,6 +15782,7 @@ Partial Class Ventas
|
|||||||
'Agregamos las PrePolizas
|
'Agregamos las PrePolizas
|
||||||
If Not OcurrioError Then
|
If Not OcurrioError Then
|
||||||
If MovimientoPrePoliza AndAlso CveMovimientoInventario > 0 Then
|
If MovimientoPrePoliza AndAlso CveMovimientoInventario > 0 Then
|
||||||
|
'OcurrioError = Not GeneraPrePolizaMovimientoAlmacen(ObjInventario, ObjConta, ObjContPaq, ObjFactura, ObjFactura.CvePrePoliza, CveMovimientoInventario, CveAlmacen)
|
||||||
If ObjInventario.GetMovimientosDetalle(CveMovimientoInventario, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoInventario, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
|
||||||
Dim DtCostos = ObjInventario.DtResultados.Copy
|
Dim DtCostos = ObjInventario.DtResultados.Copy
|
||||||
Dim DtCostosDistinct As DataTable = ObjInventario.DtResultados.FiltraParametros("", "", {"CveClasificacion"})
|
Dim DtCostosDistinct As DataTable = ObjInventario.DtResultados.FiltraParametros("", "", {"CveClasificacion"})
|
||||||
@@ -15847,6 +15850,99 @@ Partial Class Ventas
|
|||||||
'Return Not OcurrioError
|
'Return Not OcurrioError
|
||||||
|
|
||||||
End Function
|
End Function
|
||||||
|
Private Function GeneraPrePolizaMovimientoAlmacen(ByRef ObjInventario As ClsInventarios, ByRef ObjConta As ClsContabilidad, ByRef ObjContPaq As ClsContPAQi, ObjFactura As Modelos.Factura, CvePrePoliza As Integer, CveMovimientoInventario As Integer, CveAlmacen As Integer) As Boolean
|
||||||
|
Dim OcurrioError As Boolean = False
|
||||||
|
Dim GenerarPrePolizaNueva As Boolean = False
|
||||||
|
Try
|
||||||
|
Dim DtCostos As DataTable = Nothing
|
||||||
|
Dim DtCostosDistinct As DataTable = Nothing
|
||||||
|
Dim IdCtaContable As Integer = 0
|
||||||
|
Dim CveCuenta As Integer = 0
|
||||||
|
Dim ValorInventario As Decimal = 0D
|
||||||
|
Dim TotalCostoAcumulado As Decimal = 0D
|
||||||
|
Dim Cont As Integer = 1
|
||||||
|
|
||||||
|
|
||||||
|
If ObjInventario.GetMovimientosDetalle(CveMovimientoInventario, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0 Then
|
||||||
|
DtCostos = ObjInventario.DtResultados.Copy
|
||||||
|
DtCostosDistinct = ObjInventario.DtResultados.FiltraParametros("", "", {"CveClasificacion"})
|
||||||
|
Else
|
||||||
|
OcurrioError = True
|
||||||
|
End If
|
||||||
|
|
||||||
|
If OcurrioError Then
|
||||||
|
Return Not OcurrioError
|
||||||
|
End If
|
||||||
|
|
||||||
|
Dim TotalCosto As Decimal = DtCostos.SUMD("Total").RoundSQL
|
||||||
|
|
||||||
|
If CvePrePoliza <= 0 Then
|
||||||
|
GenerarPrePolizaNueva = True
|
||||||
|
CvePrePoliza = ObjConta.AddPrePolizas("Ventas/GeneraMovimientoAlmacen", ObjFactura.CvePlantillaPoliza, TotalCosto, TotalCosto, ObjFactura.CveMoneda, ObjFactura.Fecha, If(CveEmpresaCRM > 0, LblEmpresaCRM.Text, ObjFactura.Cliente.Nombre), ObjFactura.CveUsuario, UsuarioActual.CveEmpresa)
|
||||||
|
|
||||||
|
If CvePrePoliza <= 0 Then
|
||||||
|
OcurrioError = True
|
||||||
|
Return Not OcurrioError
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
For Each RowInv As DataRow In DtCostosDistinct.Rows
|
||||||
|
ValorInventario = DtCostos.SUMD("Total", String.Format("CveClasificacion = {0}", RowInv("CveClasificacion"))).RoundSQL
|
||||||
|
IdCtaContable = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaCostos", $"CveClasificacion = {RowInv("CveClasificacion")}").ToEntero
|
||||||
|
CveCuenta = GlobalDTClasificaciones(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCuentaGastoSIG", $"CveClasificacion = {RowInv("CveClasificacion")}").ToEntero
|
||||||
|
TotalCostoAcumulado += ValorInventario
|
||||||
|
|
||||||
|
'cuando es el último movimiento y hay diferencias en los importes
|
||||||
|
If Cont = DtCostosDistinct.Rows.Count AndAlso TotalCosto <> TotalCostoAcumulado Then
|
||||||
|
ValorInventario = ValorInventario + (TotalCosto - TotalCostoAcumulado)
|
||||||
|
End If
|
||||||
|
|
||||||
|
Try
|
||||||
|
'If ValorInventario <> 0 Then
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, False, ValorInventario, ObjFactura.SerieFolio, 69, ObjFactura.SerieFolio, ObjFactura.Fecha, IdCtaContable, -1, CveVenta:=CveVenta, CveCliente:=ObjFactura.CveCliente, CveClasificacion:=RowInv("CveClasificacion").ToString.ToEntero, CveMovimientoAlmacen:=CveMovimientoInventario, ImporteMX:=ValorInventario, CveCuenta:=CveCuenta, CveSubProyecto:=ObjFactura.CveSubProyecto) Then
|
||||||
|
OcurrioError = True
|
||||||
|
Exit For
|
||||||
|
End If
|
||||||
|
'End If
|
||||||
|
Catch ex As Exception
|
||||||
|
OcurrioError = True
|
||||||
|
Alert("Error inesperado (15147). Por favor comuniquese con atención SIG.", TipoMensaje.ToastError)
|
||||||
|
End Try
|
||||||
|
Cont += 1
|
||||||
|
Next
|
||||||
|
|
||||||
|
If Not OcurrioError Then
|
||||||
|
IdCtaContable = GlobalDTAlmacen(UsuarioActual.CveEmpresa).FiltroPrimeroValor("IdCtaContable", String.Format("CveAlmacen = {0}", CveAlmacen)).ToEntero
|
||||||
|
If Not ObjConta.AddPrePolizasDetalle(CvePrePoliza, True, TotalCosto, ObjFactura.SerieFolio, 68, ObjFactura.SerieFolio, ObjFactura.Fecha, IdCtaContable, -1, CveVenta:=CveVenta, CveCliente:=ObjFactura.CveCliente, CveMovimientoAlmacen:=CveMovimientoInventario, ImporteMX:=TotalCosto, CveCuenta:=CveCuenta, CveSubProyecto:=ObjFactura.CveSubProyecto) Then
|
||||||
|
OcurrioError = True
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
If GenerarPrePolizaNueva Then
|
||||||
|
Dim AutoConta As Boolean = UsuarioActual.Empresa.Funcionalidad(200) = "1"
|
||||||
|
|
||||||
|
If UsuarioActual.CveEmpresa = 119 AndAlso DdlTipoComprobante.SelectedValue.Contiene("Ant", "Rem", "RNC", "Cot", "Ped", "Pd2", "PA", "Egs", "Dev") Then
|
||||||
|
AutoConta = False
|
||||||
|
End If
|
||||||
|
|
||||||
|
If AutoConta Then
|
||||||
|
If idCuentaContabilizacion > 0 Then
|
||||||
|
If Not ObjConta.ContabilizarPrePoliza(ObjFactura.CvePrePoliza, ObjFactura.CveUsuario, UsuarioActual.Empresa, ObjConta:=ObjContPaq) Then
|
||||||
|
Alert("Ocurrio un Error al contabilizar la prepoliza de almacen, pongase en contacto con Soporte Técnico", TipoMensaje.MsgError)
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
Alert(String.Format("Falta asignación de las siguientes cuentas contables: {0}", CuentasContablesInvalidas), TipoMensaje.MsgAdvertencia)
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
|
Catch ex As Exception
|
||||||
|
OnError("Ocurrió un error al generar la prepoliza del movimiento de almacen", ex)
|
||||||
|
OcurrioError = True
|
||||||
|
End Try
|
||||||
|
|
||||||
|
Return Not OcurrioError
|
||||||
|
End Function
|
||||||
Private Function GenerarMovimientoAlmacenVirtual(CveRemision As Integer, ByRef ObjInventario As ClsInventarios, ObjFactura As Modelos.Factura) As Boolean
|
Private Function GenerarMovimientoAlmacenVirtual(CveRemision As Integer, ByRef ObjInventario As ClsInventarios, ObjFactura As Modelos.Factura) As Boolean
|
||||||
Dim OcurrioError As Boolean = False
|
Dim OcurrioError As Boolean = False
|
||||||
|
|
||||||
@@ -18440,42 +18536,38 @@ Partial Class Ventas
|
|||||||
'End If
|
'End If
|
||||||
If DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Dev", "Egs", "RNC") Then
|
If DdlTipoComprobante.SelectedValue.Contiene("Ing", "Ant", "Dev", "Egs", "RNC") Then
|
||||||
|
|
||||||
'SI ES PRODUCCION VERIFICA EL ESTATUS ANTE EL SAT
|
Dim sb As New StringBuilder()
|
||||||
If UsuarioActual.Empresa.FacturaProduccion AndAlso Not FolioFiscal.Contains("test") Then
|
sb.Append("La factura se encuentra en el siguiente estatus del SAT:<br/>")
|
||||||
Dim sb As New StringBuilder()
|
|
||||||
sb.Append("La factura se encuentra en el siguiente estatus del SAT:<br/>")
|
|
||||||
|
|
||||||
Dim TotalT As Decimal = TxtTotal.Text.ToDecimal
|
Dim TotalT As Decimal = TxtTotal.Text.ToDecimal
|
||||||
Dim RFCReceptor As String = LblRFC.Text.Trim
|
Dim RFCReceptor As String = LblRFC.Text.Trim
|
||||||
Dim Vigencia = Timbrado.VerificarVigenciaSAT(FolioFiscal, UsuarioActual.Empresa.RFC, RFCReceptor, TotalT.ToString(), True)
|
Dim Vigencia = Timbrado.VerificarVigenciaSAT(FolioFiscal, UsuarioActual.Empresa.RFC, RFCReceptor, TotalT.ToString(), True)
|
||||||
If Vigencia IsNot Nothing Then
|
If Vigencia IsNot Nothing Then
|
||||||
If Vigencia.EsCancelable.ToUpper() = "NO CANCELABLE" Then
|
If Vigencia.EsCancelable.ToUpper() = "NO CANCELABLE" Then
|
||||||
Alert("Esta factura no es cancelable.", TipoMensaje.MsgAdvertencia)
|
Alert("Esta factura no es cancelable.", TipoMensaje.MsgAdvertencia)
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
If String.IsNullOrEmpty(Vigencia.EsCancelable) Then
|
||||||
|
If UsuarioActual.Empresa.FacturaProduccion AndAlso Not String.IsNullOrEmpty(FolioFiscal) Then
|
||||||
|
Alert("No se pudo encontrar el estatus de la factura en el SAT.", TipoMensaje.MsgAdvertencia)
|
||||||
Exit Sub
|
Exit Sub
|
||||||
End If
|
End If
|
||||||
If String.IsNullOrEmpty(Vigencia.EsCancelable) Then
|
|
||||||
If Not String.IsNullOrEmpty(FolioFiscal) Then
|
|
||||||
Alert("No se pudo encontrar el estatus de la factura en el SAT.", TipoMensaje.MsgAdvertencia)
|
|
||||||
Exit Sub
|
|
||||||
End If
|
|
||||||
sb.Append("<b>No encontrado</b> <br/>")
|
|
||||||
Else
|
|
||||||
sb.AppendFormat("<b>{0}</b> <br/>", Vigencia.EsCancelable)
|
|
||||||
End If
|
|
||||||
Else
|
|
||||||
sb.Append("<b>No encontrado</b> <br/>")
|
sb.Append("<b>No encontrado</b> <br/>")
|
||||||
|
Else
|
||||||
|
sb.AppendFormat("<b>{0}</b> <br/>", Vigencia.EsCancelable)
|
||||||
End If
|
End If
|
||||||
|
|
||||||
sb.Append("Está seguro de cancelar el documento?.")
|
|
||||||
|
|
||||||
LblCancelarDocumento.Text = sb.ToString()
|
|
||||||
|
|
||||||
RegistraScript("$('#ModalCancelarDocumento').modal();")
|
|
||||||
UpCancelarDocumento.Update()
|
|
||||||
Else
|
Else
|
||||||
CancelarDocumento()
|
sb.Append("<b>No encontrado</b> <br/>")
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
sb.Append("Está seguro de cancelar el documento?.")
|
||||||
|
|
||||||
|
LblCancelarDocumento.Text = sb.ToString()
|
||||||
|
|
||||||
|
RegistraScript("$('#ModalCancelarDocumento').modal();")
|
||||||
|
UpCancelarDocumento.Update()
|
||||||
|
|
||||||
Else
|
Else
|
||||||
CancelarDocumento()
|
CancelarDocumento()
|
||||||
End If
|
End If
|
||||||
@@ -19665,7 +19757,7 @@ Partial Class Ventas
|
|||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
#Region " CONTRATO DE CONSIGNACION DE VENTA - SURTIDO DE ALMACÉN "
|
#Region " CONTRATO DE CONSIGNACION DE VENTA - SURTIDO DE ALMACÉN "
|
||||||
Function RegistraAlmacenConsignacionVenta(ByRef ObjInventario As ClsInventarios, factura As Modelos.Factura) As Boolean
|
Function RegistraAlmacenConsignacionVenta(ByRef ObjInventario As ClsInventarios, ByRef ObjConta As ClsContabilidad, factura As Modelos.Factura, ObjContPaq As ClsContPAQi) As Boolean
|
||||||
If Not (UsuarioActual.Empresa.UsaInventarios AndAlso CveAlmacenExistenciasContrato > 0) Then
|
If Not (UsuarioActual.Empresa.UsaInventarios AndAlso CveAlmacenExistenciasContrato > 0) Then
|
||||||
Return True
|
Return True
|
||||||
End If
|
End If
|
||||||
@@ -19742,6 +19834,11 @@ Partial Class Ventas
|
|||||||
End If
|
End If
|
||||||
Next
|
Next
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
'GENERAR PREPOLIZA
|
||||||
|
If Not GeneraPrePolizaMovimientoAlmacen(ObjInventario, ObjConta, ObjContPaq, ObjFactura, ObjFactura.CvePrePoliza, CveMovimientoEntradaGeneral, CveAlmacenOrigenContrato) Then
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
Else
|
Else
|
||||||
Return False
|
Return False
|
||||||
End If
|
End If
|
||||||
@@ -21364,8 +21461,8 @@ Partial Class Ventas
|
|||||||
|
|
||||||
For Each Dr As DataRow In DtImpuestosLocal.Rows
|
For Each Dr As DataRow In DtImpuestosLocal.Rows
|
||||||
FiltroStr = String.Format("ISNULL(PorcentajeIVA,0) = {0} AND ISNULL(PorcentajeRetIVA,0) = {1} AND ISNULL(PorcentajeRetISR,0) = {2} AND ISNULL(PorcentajeIEPS,0) = {3} AND ISNULL(CveSubProyecto,0) = {4} ", Dr("PorcentajeIVA").ToString.ToDecimal, Dr("PorcentajeRetIVA").ToString.ToDecimal, Dr("PorcentajeRetISR").ToString.ToDecimal, Dr("PorcentajeIEPS").ToString.ToDecimal, Dr("CveSubProyecto"))
|
FiltroStr = String.Format("ISNULL(PorcentajeIVA,0) = {0} AND ISNULL(PorcentajeRetIVA,0) = {1} AND ISNULL(PorcentajeRetISR,0) = {2} AND ISNULL(PorcentajeIEPS,0) = {3} AND ISNULL(CveSubProyecto,0) = {4} ", Dr("PorcentajeIVA").ToString.ToDecimal, Dr("PorcentajeRetIVA").ToString.ToDecimal, Dr("PorcentajeRetISR").ToString.ToDecimal, Dr("PorcentajeIEPS").ToString.ToDecimal, Dr("CveSubProyecto"))
|
||||||
importePuTemp = (Porcentaje * (TmpDT.SUM("TotalImporte", FiltroStr) - TmpDT.SUM("Descuento", FiltroStr))).ToDecimal
|
importePuTemp = (Porcentaje * (TmpDT.SUM("TotalImporte", FiltroStr).ToDecimal() - TmpDT.SUM("Descuento", FiltroStr).ToDecimal()))
|
||||||
Dr("ImporteTotal") = importePuTemp.RoundSQL()
|
Dr("ImporteTotal") = importePuTemp.RoundSQL(2)
|
||||||
|
|
||||||
|
|
||||||
Dr("ImporteIEPS") = (importePuTemp * Dr("PorcentajeIEPS").ToString().ToDecimal()).RoundSQL(2)
|
Dr("ImporteIEPS") = (importePuTemp * Dr("PorcentajeIEPS").ToString().ToDecimal()).RoundSQL(2)
|
||||||
@@ -21378,7 +21475,7 @@ Partial Class Ventas
|
|||||||
'Dr("ImporteRetIVA") = Math.Round(Porcentaje * TmpDT.SUM("ImporteRetIVA", FiltroStr), 2)
|
'Dr("ImporteRetIVA") = Math.Round(Porcentaje * TmpDT.SUM("ImporteRetIVA", FiltroStr), 2)
|
||||||
'Dr("ImporteRetISR") = Math.Round(Porcentaje * TmpDT.SUM("ImporteRetISR", FiltroStr), 2)
|
'Dr("ImporteRetISR") = Math.Round(Porcentaje * TmpDT.SUM("ImporteRetISR", FiltroStr), 2)
|
||||||
'Dr("ImporteIEPS") = Math.Round(Porcentaje * TmpDT.SUM("ImporteIEPS", FiltroStr), 2)
|
'Dr("ImporteIEPS") = Math.Round(Porcentaje * TmpDT.SUM("ImporteIEPS", FiltroStr), 2)
|
||||||
Dr("ImportePU") = Dr("ImporteTotal").ToString.ToDecimal.RoundSQL(2) '(Dr("ImporteTotal").ToString.ToDecimal - Dr("ImporteIVA").ToString.ToDecimal - Dr("ImporteRetIVA").ToString.ToDecimal - Dr("ImporteRetISR").ToString.ToDecimal - Dr("ImporteIEPS").ToString.ToDecimal)
|
Dr("ImportePU") = importePuTemp.RoundSQL(6) 'Dr("ImporteTotal").ToString.ToDecimal.RoundSQL(2) '(Dr("ImporteTotal").ToString.ToDecimal - Dr("ImporteIVA").ToString.ToDecimal - Dr("ImporteRetIVA").ToString.ToDecimal - Dr("ImporteRetISR").ToString.ToDecimal - Dr("ImporteIEPS").ToString.ToDecimal)
|
||||||
Next
|
Next
|
||||||
|
|
||||||
|
|
||||||
@@ -21668,7 +21765,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
Dim AplicaPUEditado As Boolean = UsuarioActual.TienePermisoProceso(253)
|
Dim AplicaPUEditado As Boolean = UsuarioActual.TienePermisoProceso(253)
|
||||||
|
|
||||||
Dim DtUsados As DataTable = TmpDT.FiltraParametros("CveClasificacion = 20519")
|
Dim DtUsados As DataTable = TmpDT.FiltraParametros("EsUsado = True")
|
||||||
|
|
||||||
TmpDT.Clear()
|
TmpDT.Clear()
|
||||||
For Each Gv As GridViewRow In GvAplicaDevolucion.Rows
|
For Each Gv As GridViewRow In GvAplicaDevolucion.Rows
|
||||||
@@ -24031,9 +24128,11 @@ Partial Class Ventas
|
|||||||
Else
|
Else
|
||||||
Row("PorcentajeIVA") = DrPS("IVA")
|
Row("PorcentajeIVA") = DrPS("IVA")
|
||||||
End If
|
End If
|
||||||
Dim TotalCalculableImpuestos = (Row("Cantidad").ToString.ToDouble * Row("PU").ToString.ToDouble) - Row("Descuento").ToString.ToDouble
|
Dim TotalCalculableImpuestos As Decimal = (Row("Cantidad").ToString.ToDecimal * Row("PU").ToString.ToDecimal) - Row("Descuento").ToString.ToDecimal
|
||||||
|
Dim TotalCalculableImpuestosIVA As Decimal = TotalCalculableImpuestos * (1 + Row("PorcentajeIEPS").ToString.ToDecimal)
|
||||||
|
|
||||||
Row("IVA") = Row("PorcentajeIVA").ToString.ToDouble
|
Row("IVA") = Row("PorcentajeIVA").ToString.ToDouble
|
||||||
Row("ImporteIVA") = Math.Round(Row("PorcentajeIVA").ToString.ToDouble * TotalCalculableImpuestos, NumeroDecimales)
|
Row("ImporteIVA") = (Row("PorcentajeIVA").ToString.ToDouble * TotalCalculableImpuestosIVA).RoundSQL(NumeroDecimales)
|
||||||
End If
|
End If
|
||||||
Else
|
Else
|
||||||
Row("IVA") = 0
|
Row("IVA") = 0
|
||||||
|
|||||||
Reference in New Issue
Block a user