Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -190,7 +190,7 @@
|
|||||||
Acumulado
|
Acumulado
|
||||||
</HeaderTemplate>
|
</HeaderTemplate>
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:Literal ID="LtlCantidadAcumulado" runat="server" Text='<%# Eval("CantidadAcumulado", "{0:N0}") %>'></asp:Literal>
|
<asp:Literal ID="LtlCantidadAcumulado" runat="server" Text='<%# Eval("CantidadAcumulado", "{0:#,##0.##}") %>'></asp:Literal>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField ItemStyle-Width="20" ItemStyle-HorizontalAlign="Right">
|
<asp:TemplateField ItemStyle-Width="20" ItemStyle-HorizontalAlign="Right">
|
||||||
@@ -206,7 +206,7 @@
|
|||||||
Venta Diaria
|
Venta Diaria
|
||||||
</HeaderTemplate>
|
</HeaderTemplate>
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:Literal ID="LtlCantidadAlDia" runat="server" Text='<%# Eval("CantidadAldia", "{0:N0}") %>'></asp:Literal>
|
<asp:Literal ID="LtlCantidadAlDia" runat="server" Text='<%# Eval("CantidadAldia", "{0:#,##0.##}") %>'></asp:Literal>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField ItemStyle-Width="80" ItemStyle-HorizontalAlign="Right">
|
<asp:TemplateField ItemStyle-Width="80" ItemStyle-HorizontalAlign="Right">
|
||||||
|
|||||||
@@ -187,6 +187,9 @@ Public Class ClsContabilidad
|
|||||||
If Valor1 = "2" OrElse Valor2 = "2" Then
|
If Valor1 = "2" OrElse Valor2 = "2" Then
|
||||||
Retorno = 3
|
Retorno = 3
|
||||||
End If
|
End If
|
||||||
|
Case 140
|
||||||
|
Retorno = 2 'egreso
|
||||||
|
|
||||||
|
|
||||||
End Select
|
End Select
|
||||||
|
|
||||||
@@ -987,16 +990,20 @@ Public Class ClsContabilidad
|
|||||||
If ex1.Message.Contains("50015;") Then
|
If ex1.Message.Contains("50015;") Then
|
||||||
OnError("No se puede registrar una póliza en un ejercicio Cerrado", ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
OnError("No se puede registrar una póliza en un ejercicio Cerrado", ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
ElseIf ex1.Message.Contains("50024; La Cuenta no fue detectada") Then
|
ElseIf ex1.Message.Contains("50024; La Cuenta no fue detectada") Then
|
||||||
Dim Concepto1 As String = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("ConceptoContable", String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
Dim dr As Data.DataRow = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimero(String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
||||||
OnError(String.Format("El concepto '{0}' no tiene especificada la cuenta. Favor de especificarla en la asignación de cuentas.", Concepto1), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
Dim Strr As String = dr("ConceptoContable").ToString
|
||||||
ElseIf ex1.Message.Contains("Vw_Val_Conta_CuentasResultados_SubProyectos") Then
|
'If dr("AplicaClasificacion").ToString <> "No" Then
|
||||||
Dim Concepto2 As String = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("ConceptoContable", String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
' Strr = Strr + " - Clasificación: " + DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("", "")
|
||||||
OnError(String.Format("El concepto '{0}' requiere centro de costo", Concepto2), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
'End If
|
||||||
ElseIf ex1.Message.Contains("UK_Vw_Val_Conta_CuentasResultados_SubProyectos") Then
|
OnError(String.Format("El concepto '{0}' no tiene especificada la cuenta. Favor de especificarla en la asignación de cuentas.", dr("ConceptoContable").ToString), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
Dim Concepto3 As String = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("ConceptoContable", String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
ElseIf ex1.Message.Contains("Vw_Val_Conta_CuentasResultados_SubProyectos") Then
|
||||||
OnError(String.Format("El concepto '{0}' requiere centro de costo", Concepto3), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
Dim Concepto2 As String = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("ConceptoContable", String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
||||||
Else
|
OnError(String.Format("El concepto '{0}' requiere centro de costo", Concepto2), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
OnError("Ocurrió un error al Guardar", ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
ElseIf ex1.Message.Contains("UK_Vw_Val_Conta_CuentasResultados_SubProyectos") Then
|
||||||
|
Dim Concepto3 As String = DirectCast(HttpContext.Current.Application("GlobalDTContaConceptosContables"), DataTable).FiltroPrimeroValor("ConceptoContable", String.Format("CveConceptoContable = {0}", CveConceptoContable))
|
||||||
|
OnError(String.Format("El concepto '{0}' requiere centro de costo", Concepto3), ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
|
Else
|
||||||
|
OnError("Ocurrió un error al Guardar", ex1, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
End If '
|
End If '
|
||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
If ex.Message.Contains("50015;") Then
|
If ex.Message.Contains("50015;") Then
|
||||||
@@ -1188,8 +1195,10 @@ Public Class ClsContabilidad
|
|||||||
Catch ex As Exception
|
Catch ex As Exception
|
||||||
If ex.Message.Contains("50015;") Then
|
If ex.Message.Contains("50015;") Then
|
||||||
OnError("No se puede actualizar una póliza en un ejercicio Cerrado", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
OnError("No se puede actualizar una póliza en un ejercicio Cerrado", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
|
ElseIf ex.Message.Contains("IDX_UN_ContaPrePolizasCveEmpresaCveTipoPolizaFoliosAnioMes") Then
|
||||||
|
OnError($"El Folio <b>{Folio}</b> ya esta registrado.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo)
|
||||||
Else
|
Else
|
||||||
OnError("Ocurrió un error al contabilizar las prepoliza detalle.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
OnError("Ocurrió un error al contabilizar las prepoliza detalle.", ex, SqlAdapter.SelectCommand.Parameters.ParametrosInfo())
|
||||||
End If
|
End If
|
||||||
End Try
|
End Try
|
||||||
Return Retorno
|
Return Retorno
|
||||||
|
|||||||
@@ -5545,22 +5545,15 @@ Public Class ClsInventarios
|
|||||||
#End Region
|
#End Region
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
#Region "Camiones"
|
#Region "Camiones"
|
||||||
Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer, Optional CveTipoCamion As Integer = -1) As Boolean
|
Public Function GetCamiones(CveCamion As Integer, CveEmpresa As Integer, Optional CveTipoCamion As Integer = -1, Optional Estatus As Integer = -1) As Boolean
|
||||||
Dim Retorno As Boolean = False
|
Dim Retorno As Boolean = False
|
||||||
DataAdapter("PA_Inv_CamionesGet")
|
DataAdapter("PA_Inv_CamionesGet")
|
||||||
With SqlAdapter.SelectCommand.Parameters
|
With SqlAdapter.SelectCommand.Parameters
|
||||||
.Add("@CveCamion", SqlDbType.Int).Value = CveCamion
|
.Add("@CveCamion", SqlDbType.Int).Value = CveCamion
|
||||||
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
|
||||||
.Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
|
.Add("@CveTipoCamion", SqlDbType.Int).Value = CveTipoCamion
|
||||||
|
.Add("@Estatus", SqlDbType.Int).Value = Estatus
|
||||||
End With
|
End With
|
||||||
Try
|
Try
|
||||||
SqlAdapter.Fill(Data)
|
SqlAdapter.Fill(Data)
|
||||||
|
|||||||
@@ -4668,6 +4668,13 @@ Namespace Modelos
|
|||||||
Dim TieneAlmacen As Boolean = False
|
Dim TieneAlmacen As Boolean = False
|
||||||
Dim AplicaRefacturacionConPagos As Boolean = False
|
Dim AplicaRefacturacionConPagos As Boolean = False
|
||||||
|
|
||||||
|
Dim CveEstatusRefacturacion As Integer = If(ObjFactura.CveEstatusRefacturacion <= 0, 0, ObjFactura.CveEstatusRefacturacion)
|
||||||
|
|
||||||
|
'SI YA FUE MARCADA COMO REFACTURACION Y FUE SEPARADA, MANTENER EL COMPORTAMIENTO DE CANCELACION COMO REFACTURACION
|
||||||
|
If Not EsRefacturacion AndAlso CveEstatusRefacturacion = 4 Then
|
||||||
|
EsRefacturacion = True
|
||||||
|
End If
|
||||||
|
|
||||||
'1 NORMAL, 2 CON PAGOS
|
'1 NORMAL, 2 CON PAGOS
|
||||||
Dim ModalidadRefacturacion As Integer = UsuarioActual.Empresa.Funcionalidad(586).ToEntero()
|
Dim ModalidadRefacturacion As Integer = UsuarioActual.Empresa.Funcionalidad(586).ToEntero()
|
||||||
|
|
||||||
@@ -4800,11 +4807,7 @@ Namespace Modelos
|
|||||||
Return Retorno
|
Return Retorno
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
If Not EsRefacturacion AndAlso CveEstatusRefacturacion <> 4 Then
|
||||||
Dim CveEstatusRefacturacion As Integer = If(ObjFactura.CveEstatusRefacturacion <= 0, 0, ObjFactura.CveEstatusRefacturacion)
|
|
||||||
|
|
||||||
|
|
||||||
If Not EsRefacturacion Then
|
|
||||||
CveEstatusRefacturacion = 0
|
CveEstatusRefacturacion = 0
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -392,7 +392,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
int cveProveedor = (DdlProveedores.SelectedValue.ToEntero() > 0) ? DdlProveedores.SelectedValue.ToEntero() : -1;
|
int cveProveedor = (DdlProveedores.SelectedValue.ToEntero() > 0) ? DdlProveedores.SelectedValue.ToEntero() : -1;
|
||||||
int cvePersonal = (DdlPersonal.SelectedValue.ToEntero() > 0) ? DdlPersonal.SelectedValue.ToEntero() : -1;
|
int cvePersonal = (DdlPersonal.SelectedValue.ToEntero() > 0) ? DdlPersonal.SelectedValue.ToEntero() : -1;
|
||||||
int cveCliente = (DdlCliente.SelectedValue.ToEntero() > 0) ? DdlCliente.SelectedValue.ToEntero() : -1;
|
int cveCliente = (DdlCliente.SelectedValue.ToEntero() > 0) ? DdlCliente.SelectedValue.ToEntero() : -1;
|
||||||
bool TipoMovoDevolucion = false;
|
bool TipoMovtoDevolucion = false;
|
||||||
double TC = 1;
|
double TC = 1;
|
||||||
StringBuilder Msg = new StringBuilder();
|
StringBuilder Msg = new StringBuilder();
|
||||||
|
|
||||||
@@ -402,25 +402,25 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
PagueseA = DdlCliente.SelectedText.ToString();
|
PagueseA = DdlCliente.SelectedText.ToString();
|
||||||
CveConceptoContableDevolucion = 92;
|
CveConceptoContableDevolucion = 92;
|
||||||
CvePlantillaPoliza = 7;
|
CvePlantillaPoliza = 7;
|
||||||
TipoMovoDevolucion = false;
|
TipoMovtoDevolucion = false;
|
||||||
break;
|
break;
|
||||||
case "2":
|
case "2":
|
||||||
PagueseA = DdlProveedores.SelectedText.ToString();
|
PagueseA = DdlProveedores.SelectedText.ToString();
|
||||||
CveConceptoContableDevolucion = 21;
|
CveConceptoContableDevolucion = 21;
|
||||||
CvePlantillaPoliza = 7;
|
CvePlantillaPoliza = 7;
|
||||||
TipoMovoDevolucion = true;
|
TipoMovtoDevolucion = true;
|
||||||
break;
|
break;
|
||||||
case "3":
|
case "3":
|
||||||
PagueseA = DdlPersonal.SelectedItem.ToString();
|
PagueseA = DdlPersonal.SelectedItem.ToString();
|
||||||
CvePlantillaPoliza = 100;
|
CvePlantillaPoliza = 100;
|
||||||
TipoMovoDevolucion = true;
|
TipoMovtoDevolucion = true;
|
||||||
CveConceptoContableDevolucion = 250;
|
CveConceptoContableDevolucion = 250;
|
||||||
break;
|
break;
|
||||||
case "4":
|
case "4":
|
||||||
PagueseA = DdlPersonal.SelectedItem.ToString();
|
PagueseA = DdlPersonal.SelectedItem.ToString();
|
||||||
CveConceptoContableDevolucion = 273;
|
CveConceptoContableDevolucion = 273;
|
||||||
CvePlantillaPoliza = 100;
|
CvePlantillaPoliza = 100;
|
||||||
TipoMovoDevolucion = true;
|
TipoMovtoDevolucion = true;
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -464,7 +464,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
{
|
{
|
||||||
if (gvr.FCCheckBox("Chk").Checked)
|
if (gvr.FCCheckBox("Chk").Checked)
|
||||||
{
|
{
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, 0, -1, CveProveedor: cveProveedor, CvePersonal: cvePersonal, CveIE: gvr.DataKey("CveIE").ToEntero(), ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: CveIE, CveNominaMovtoPermanente: CveMovtoPermanente))
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, 0, -1, CveProveedor: cveProveedor, CvePersonal: cvePersonal, CveIE: gvr.DataKey("CveIE").ToEntero(), ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: CveIE, CveNominaMovtoPermanente: CveMovtoPermanente))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de Devolución";
|
MsgError = "No se pudo insertar concepto de Devolución";
|
||||||
break;
|
break;
|
||||||
@@ -474,7 +474,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
//Decimal tTotal = (TxtValor.Text.ToDecimal() * TxtVecesAplicar.Text.ToDecimal()).RoundSQL();
|
//Decimal tTotal = (TxtValor.Text.ToDecimal() * TxtVecesAplicar.Text.ToDecimal()).RoundSQL();
|
||||||
Decimal tTotal = gvr.FCTextBox("TxtAbonar").Text.ToDecimal();
|
Decimal tTotal = gvr.FCTextBox("TxtAbonar").Text.ToDecimal();
|
||||||
//GUARDA PREPOLIZAS DETALLE Via Nómina
|
//GUARDA PREPOLIZAS DETALLE Via Nómina
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, !TipoMovoDevolucion, tTotal, Ref, 174, Conc, DateTime.Now, 0, -1, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: cveCliente, CveProveedor: cveProveedor, CvePersonal: cvePersonal, CveIE: gvr.DataKey("CveIE").ToEntero(), ImporteMX: tTotal, CveNominaMovtoPermanente: CveMovtoPermanente))
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, !TipoMovtoDevolucion, tTotal, Ref, 174, Conc, DateTime.Now, 0, -1, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: cveCliente, CveProveedor: cveProveedor, CvePersonal: cvePersonal, CveIE: gvr.DataKey("CveIE").ToEntero(), ImporteMX: tTotal, CveNominaMovtoPermanente: CveMovtoPermanente))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de Devolución";
|
MsgError = "No se pudo insertar concepto de Devolución";
|
||||||
}
|
}
|
||||||
@@ -520,15 +520,24 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
else
|
else
|
||||||
{
|
{
|
||||||
//INGxC
|
//INGxC
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, IDCtaContableDevolucion, -1, CveIE: CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero(), ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: gvr.DataKey("CveIE").ToEntero()))
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, IDCtaContableDevolucion, -1, CveIE: CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero(), ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: gvr.DataKey("CveIE").ToEntero()))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de bancos";
|
MsgError = "No se pudo insertar concepto de bancos";
|
||||||
}
|
}
|
||||||
|
// OTROS INGRESOS
|
||||||
|
if (gvr.FCTextBox("TxtComision").Text.ToDecimal() != 0)
|
||||||
|
{
|
||||||
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtComision").Text.ToDecimal(), Ref, 78, Conc, DateTime.Now, UsuarioActual.Empresa.IdCuentaOtrosIngresos, -1, CveIE: CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: DdlCliente.SelectedValue.ToEntero(), ImporteMX: gvr.FCTextBox("TxtComision").Text.ToDecimal(), CveIEDevolucion: gvr.DataKey("CveIE").ToEntero()))
|
||||||
|
{
|
||||||
|
MsgError = "No se pudo insertar concepto de ot. ingresos/gastos";
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, IDCtaContableDevolucion, -1, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: CveIE))
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), Ref, CveConceptoContableDevolucion, Conc, DateTime.Now, IDCtaContableDevolucion, -1, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: gvr.FCTextBox("TxtAbonar").Text.ToDecimal(), CveIEDevolucion: CveIE))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de Devolución";
|
MsgError = "No se pudo insertar concepto de Devolución";
|
||||||
break;
|
break;
|
||||||
@@ -537,7 +546,11 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
// OTROS INGRESOS
|
// OTROS INGRESOS
|
||||||
if (gvr.FCTextBox("TxtComision").Text.ToDecimal() != 0)
|
if (gvr.FCTextBox("TxtComision").Text.ToDecimal() != 0)
|
||||||
{
|
{
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovoDevolucion, gvr.FCTextBox("TxtComision").Text.ToDecimal(), Ref, 78, Conc, DateTime.Now, UsuarioActual.Empresa.IdCuentaOtrosIngresos, -1, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: gvr.FCTextBox("TxtComision").Text.ToDecimal(), CveIEDevolucion: CveIE))
|
int tcvecon = 78;
|
||||||
|
if (gvr.FCTextBox("TxtComision").Text.ToDecimal() > 0)
|
||||||
|
tcvecon = 255;
|
||||||
|
|
||||||
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, TipoMovtoDevolucion, gvr.FCTextBox("TxtComision").Text.ToDecimal(), Ref, tcvecon, Conc, DateTime.Now, UsuarioActual.Empresa.IdCuentaOtrosIngresos, -1, CveIE: gvr.DataKey("CveIE").ToEntero(), CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: gvr.FCTextBox("TxtComision").Text.ToDecimal(), CveIEDevolucion: CveIE))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de Devolución";
|
MsgError = "No se pudo insertar concepto de Devolución";
|
||||||
break;
|
break;
|
||||||
@@ -548,7 +561,7 @@ public partial class Bancos_Devoluciones : ClsPaginas
|
|||||||
}
|
}
|
||||||
|
|
||||||
//GUARDA PREPOLIZAS DETALLE Bancos
|
//GUARDA PREPOLIZAS DETALLE Bancos
|
||||||
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, !TipoMovoDevolucion, TxtImporte.Text.ToDecimal(), Ref, CveConceptoContableBanco, Conc, DateTime.Now, IDCtaContableBancos, -1, CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: cveCliente, CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: TxtImporte.Text.ToDecimal()))
|
if (!ObjMov.AddPrePolizasDetalle(CvePrePoliza, !TipoMovtoDevolucion, TxtImporte.Text.ToDecimal(), Ref, CveConceptoContableBanco, Conc, DateTime.Now, IDCtaContableBancos, -1, CveIE, CveSubProyecto: DdlSubProyecto.SelectedValue.ToEntero(), CveCliente: cveCliente, CveProveedor: cveProveedor, CvePersonal: cvePersonal, ImporteMX: TxtImporte.Text.ToDecimal()))
|
||||||
{
|
{
|
||||||
MsgError = "No se pudo insertar concepto de bancos";
|
MsgError = "No se pudo insertar concepto de bancos";
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -39,7 +39,7 @@ Partial Class Bancos_RepEgresosSinComprobante
|
|||||||
DdlUsuarioRegistro.DataBind()
|
DdlUsuarioRegistro.DataBind()
|
||||||
DdlUsuarioRegistro.Items.Insert(0, New ListItem("Todos", "-1"))
|
DdlUsuarioRegistro.Items.Insert(0, New ListItem("Todos", "-1"))
|
||||||
Else
|
Else
|
||||||
DdlUsuarioRegistro.DataSource = GlobalDTUsuarios(UsuarioActual.CveUsuario)
|
DdlUsuarioRegistro.DataSource = GlobalDTUsuarios(UsuarioActual.CveUsuario, CveEmpresa:=UsuarioActual.CveEmpresa)
|
||||||
DdlUsuarioRegistro.DataBind()
|
DdlUsuarioRegistro.DataBind()
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -5829,7 +5829,6 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
function chkAnt(t, txt, importe, TotalSaldo, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal) {
|
function chkAnt(t, txt, importe, TotalSaldo, CveMonedaAnticipo, TCAnticipo, CveMonedaOriginal) {
|
||||||
var Total = ToDouble($get('TxtTotal').value);
|
var Total = ToDouble($get('TxtTotal').value);
|
||||||
//TotalSaldo = Total;
|
//TotalSaldo = Total;
|
||||||
@@ -5844,7 +5843,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
//var SaldoCompra = parseFloat(parseFloat($get('HdnCompraSaldo').value).toFixed(2));
|
//var SaldoCompra = parseFloat(parseFloat($get('HdnCompraSaldo').value).toFixed(2));
|
||||||
var SaldoCompra = (Total - FnSumaValoresAnt() + txtvalue).toFixed(2); // le agrego lo del valor actual para validarlo
|
var SaldoCompra = (TotalSaldo - FnSumaValoresAnt() + txtvalue).toFixed(2); // le agrego lo del valor actual para validarlo
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1025,6 +1025,21 @@ Partial Class Compras_Compras
|
|||||||
End Set
|
End Set
|
||||||
End Property
|
End Property
|
||||||
|
|
||||||
|
Private Property SubTotalRefacturacion As Decimal
|
||||||
|
Get
|
||||||
|
|
||||||
|
If ViewState("SubTotalRefacturacion") Is Nothing Then
|
||||||
|
ViewState("SubTotalRefacturacion") = 0.0D
|
||||||
|
End If
|
||||||
|
|
||||||
|
Return ViewState("SubTotalRefacturacion").ToString.ToDecimal
|
||||||
|
|
||||||
|
End Get
|
||||||
|
Set(value As Decimal)
|
||||||
|
ViewState("SubTotalRefacturacion") = value
|
||||||
|
End Set
|
||||||
|
End Property
|
||||||
|
|
||||||
Private Property IVAOriginal As Double
|
Private Property IVAOriginal As Double
|
||||||
Get
|
Get
|
||||||
|
|
||||||
@@ -2165,7 +2180,7 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
DdlRetIVAConcepto.Items.Add(New ListItem("Arrendamiento", "4"))
|
DdlRetIVAConcepto.Items.Add(New ListItem("Arrendamiento", "4"))
|
||||||
''If UsuarioActual.Empresa.Funcionalidad(577).ToEntero = 1 Then
|
''If UsuarioActual.Empresa.Funcionalidad(577).ToEntero = 1 Then
|
||||||
'DdlRetIVAConcepto.Items.Add(New ListItem("Ret IVA Servicios", "5"))
|
DdlRetIVAConcepto.Items.Add(New ListItem("Ret IVA Servicios", "5"))
|
||||||
''End If
|
''End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
@@ -5925,7 +5940,7 @@ Partial Class Compras_Compras
|
|||||||
Dim Concepto As String = ObjConta.ObtenerConceptoEmpresa(UsuarioActual.CveEmpresa, ConceptoContable, NombreProveedor, $"{TxtSerie.Text}-{TxtFolio.Text}", If(TxtDocumentoFolio.Visible, TxtDocumentoFolio.Text, If(TxtDocumentoFolioCaja.Visible, TxtDocumentoFolioCaja.Text, ConceptoPersonal)))
|
Dim Concepto As String = ObjConta.ObtenerConceptoEmpresa(UsuarioActual.CveEmpresa, ConceptoContable, NombreProveedor, $"{TxtSerie.Text}-{TxtFolio.Text}", If(TxtDocumentoFolio.Visible, TxtDocumentoFolio.Text, If(TxtDocumentoFolioCaja.Visible, TxtDocumentoFolioCaja.Text, ConceptoPersonal)))
|
||||||
Dim importeMN As Decimal = 0
|
Dim importeMN As Decimal = 0
|
||||||
|
|
||||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, -1, 1)
|
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
|
||||||
|
|
||||||
|
|
||||||
Dim Referencia As String = $"{TxtSerie.Text}-{TxtFolio.Text}" ' concatenation interpolation
|
Dim Referencia As String = $"{TxtSerie.Text}-{TxtFolio.Text}" ' concatenation interpolation
|
||||||
@@ -6314,7 +6329,7 @@ Partial Class Compras_Compras
|
|||||||
Funcionalidad = 313
|
Funcionalidad = 313
|
||||||
ConceptoContable = 248
|
ConceptoContable = 248
|
||||||
ElseIf DdlRetIVAConcepto.SelectedValue.ToEntero = 5 Then
|
ElseIf DdlRetIVAConcepto.SelectedValue.ToEntero = 5 Then
|
||||||
Funcionalidad = 577
|
Funcionalidad = 578
|
||||||
ConceptoContable = 285
|
ConceptoContable = 285
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -6517,7 +6532,14 @@ Partial Class Compras_Compras
|
|||||||
Exit Select 'Es credito el concepto 6 se agrega en CASE 17
|
Exit Select 'Es credito el concepto 6 se agrega en CASE 17
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If Not CveCompraRefacturacion > 0 OrElse (ChkRefacNC.Checked) Then
|
|
||||||
|
Dim DifSubTotatles As Decimal = 0D
|
||||||
|
|
||||||
|
If CveCompraRefacturacion > 0 Then
|
||||||
|
DifSubTotatles = Math.Abs(SubTotalRefacturacion - TxtSubTotal2.Text.ToDecimal)
|
||||||
|
End If
|
||||||
|
|
||||||
|
If DifSubTotatles > 0 Or (Not CveCompraRefacturacion > 0 OrElse (ChkRefacNC.Checked)) Then
|
||||||
'AF TipoAF 2 Es para las compras
|
'AF TipoAF 2 Es para las compras
|
||||||
DT = TmpDT.FiltraParametros("ISNULL(TipoAF,0) = 2 And ISNULL(AplicaCostoIndirecto,0) <> 1 ")
|
DT = TmpDT.FiltraParametros("ISNULL(TipoAF,0) = 2 And ISNULL(AplicaCostoIndirecto,0) <> 1 ")
|
||||||
If DT.Rows.Count > 0 AndAlso Not DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV", "Ant") Then
|
If DT.Rows.Count > 0 AndAlso Not DdlTipoComprobante.SelectedValue.Contiene("NC", "DEV", "Ant") Then
|
||||||
@@ -8972,7 +8994,7 @@ Partial Class Compras_Compras
|
|||||||
IdCtaContable = 0
|
IdCtaContable = 0
|
||||||
Dim Concepto As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
Dim Concepto As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
||||||
Dim importeMN As Decimal = 0
|
Dim importeMN As Decimal = 0
|
||||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, -1, 1)
|
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
|
||||||
Dim PorcentajeImpuesto As Decimal = 0
|
Dim PorcentajeImpuesto As Decimal = 0
|
||||||
Dim ConceptoPartida As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
Dim ConceptoPartida As String = String.Format("{0}-{1}", TxtSerie.Text, TxtFolio.Text)
|
||||||
|
|
||||||
@@ -10591,7 +10613,7 @@ Partial Class Compras_Compras
|
|||||||
Dim importeMovimiento As Decimal = 0
|
Dim importeMovimiento As Decimal = 0
|
||||||
Dim IdCtaContable As Integer = 0
|
Dim IdCtaContable As Integer = 0
|
||||||
Dim importeMN As Decimal = 0
|
Dim importeMN As Decimal = 0
|
||||||
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, -1, 1)
|
Dim Multiplicador As Integer = If(Row("Multiplicador").ToString.ToEntero = 1, 1, -1)
|
||||||
Dim Referencia As String = $"{TxtSerie.Text}-{TxtFolio.Text}" ' concatenation interpolation
|
Dim Referencia As String = $"{TxtSerie.Text}-{TxtFolio.Text}" ' concatenation interpolation
|
||||||
|
|
||||||
Select Case ConceptoContable
|
Select Case ConceptoContable
|
||||||
@@ -14731,14 +14753,19 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
Private Sub DdlRefacturacionFacturas_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlRefacturacionFacturas.SelectedIndexChanged
|
Private Sub DdlRefacturacionFacturas_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlRefacturacionFacturas.SelectedIndexChanged
|
||||||
|
|
||||||
|
SubTotalRefacturacion = 0.0D
|
||||||
|
|
||||||
If DdlRefacturacionFacturas.SelectedValue.ToEntero > 0 Then
|
If DdlRefacturacionFacturas.SelectedValue.ToEntero > 0 Then
|
||||||
Dim dr As DataRow = DtRefacturacion.FiltroPrimero(String.Format("CveCompra ={0}", DdlRefacturacionFacturas.SelectedValue))
|
Dim dr As DataRow = DtRefacturacion.FiltroPrimero(String.Format("CveCompra ={0}", DdlRefacturacionFacturas.SelectedValue))
|
||||||
If dr IsNot Nothing Then
|
If dr IsNot Nothing Then
|
||||||
|
|
||||||
HdnRefacturacionConcepto.Value = dr("CveConceptoContableAlmacen").ToString
|
HdnRefacturacionConcepto.Value = dr("CveConceptoContableAlmacen").ToString
|
||||||
ChkRefacturacionConAlmacen.Checked = If(dr("CveMovimientoAlmacen").ToString.ToEntero > 0, True, False)
|
ChkRefacturacionConAlmacen.Checked = If(dr("CveMovimientoAlmacen").ToString.ToEntero > 0, True, False)
|
||||||
|
SubTotalRefacturacion = dr("SubTotal").ToString.ToDecimal
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End Sub
|
End Sub
|
||||||
@@ -14991,12 +15018,12 @@ Partial Class Compras_Compras
|
|||||||
|
|
||||||
End If
|
End If
|
||||||
ObjComprasComprobacion.Dispose()
|
ObjComprasComprobacion.Dispose()
|
||||||
|
Dim cvemovimientoentrada As Integer = -1
|
||||||
|
|
||||||
'DEVOLUCIÓN AUTOMATICA
|
'DEVOLUCIÓN AUTOMATICA
|
||||||
If CheckDevAuto.Checked Then
|
If CheckDevAuto.Checked Then
|
||||||
Dim ErrorMovInv As Boolean = False
|
Dim ErrorMovInv As Boolean = False
|
||||||
Dim cvemovimientoentrada As Integer
|
|
||||||
Dim folio As Integer
|
Dim folio As Integer
|
||||||
Dim fecha As Date = TxtFechaCancelacion.Text.ToDate
|
Dim fecha As Date = TxtFechaCancelacion.Text.ToDate
|
||||||
Dim importeconcepto As Decimal
|
Dim importeconcepto As Decimal
|
||||||
@@ -15138,7 +15165,8 @@ Partial Class Compras_Compras
|
|||||||
If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), dr("Importe").ToString.ToDecimal * -1, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero,
|
If Not ObjContabilidad.AddPrePolizasDetalle(CvePrePolizaNueva, CBool(dr("TipoMovto").ToString), dr("Importe").ToString.ToDecimal * -1, dr("Referencia").ToString, dr("CveConceptoContable").ToString.ToEntero,
|
||||||
dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero,
|
dr("Concepto").ToString, TxtFechaCancelacion.Text.ToDate, dr("IdCtaContable").ToString.ToEntero, dr("IdSegmentoNegocio").ToString.ToEntero, dr("CveIE").ToString.ToEntero,
|
||||||
dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero,
|
dr("CveVenta").ToString.ToEntero, dr("CveCompra").ToString.ToEntero, dr("CveSubProyecto").ToString.ToEntero, dr("CveCliente").ToString.ToEntero, dr("CveProveedor").ToString.ToEntero, dr("CvePersonal").ToString.ToEntero,
|
||||||
dr("CveMovimientoAlmacen").ToString.ToEntero, dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero,
|
If(cvemovimientoentrada > 0, cvemovimientoentrada, dr("CveMovimientoAlmacen").ToString.ToEntero),
|
||||||
|
dr("CveActivoFijo").ToString.ToEntero, -1, -1, dr("CveCreditoDetalle").ToString.ToEntero,
|
||||||
ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero) Then
|
ImporteMX:=dr("Importe").ToString.ToDecimal * -1, ImporteME:=dr("Importe").ToString.ToDecimal * -1, CveTipoGasto:=dr("CveTipoGasto").ToString.ToEntero, CveClasificacion:=dr("CveClasificacion").ToString.ToEntero, CveOCDetalle:=dr("CveOCDetalle").ToString.ToEntero) Then
|
||||||
ErrorCancelar = True
|
ErrorCancelar = True
|
||||||
Exit For
|
Exit For
|
||||||
|
|||||||
@@ -728,15 +728,10 @@ Partial Class Compras_Proveedores
|
|||||||
cfdVer = "http://www.sat.gob.mx/cfd/4"
|
cfdVer = "http://www.sat.gob.mx/cfd/4"
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
'If Prefijo.ToLower <> "cfdi" Then cfdVer = "http://www.sat.gob.mx/cfd/2"
|
'If Prefijo.ToLower <> "cfdi" Then cfdVer = "http://www.sat.gob.mx/cfd/2"
|
||||||
namespaces.AddNamespace(Prefijo, cfdVer)
|
namespaces.AddNamespace(Prefijo, cfdVer)
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
Dim node As XmlNode
|
Dim node As XmlNode
|
||||||
node = XMLDoc.SelectSingleNode(String.Format("//{0}:Emisor", Prefijo), namespaces)
|
node = XMLDoc.SelectSingleNode(String.Format("//{0}:Emisor", Prefijo), namespaces)
|
||||||
If node IsNot Nothing Then
|
If node IsNot Nothing Then
|
||||||
|
|||||||
@@ -2883,7 +2883,7 @@ Partial Class Compras_eFacturas
|
|||||||
DTDocumentosRelacionados.Columns.Add("Manual", GetType(Boolean))
|
DTDocumentosRelacionados.Columns.Add("Manual", GetType(Boolean))
|
||||||
|
|
||||||
|
|
||||||
|
Dim TieneRegistros As Boolean = False
|
||||||
If IO.File.Exists(Archivo) Then
|
If IO.File.Exists(Archivo) Then
|
||||||
|
|
||||||
|
|
||||||
@@ -3034,18 +3034,29 @@ Partial Class Compras_eFacturas
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|
||||||
ObjCompraFolios.Dispose()
|
ObjCompraFolios.Dispose()
|
||||||
|
DTDocumentosRelacionados = DTDocumentosRelacionados.FiltraParametros("CveIE > 0 AND LEN(IdDocumento) > 0")
|
||||||
GVPDocumentosRelacionadosPagos.DataSource = DTDocumentosRelacionados
|
GVPDocumentosRelacionadosPagos.DataSource = DTDocumentosRelacionados
|
||||||
GVPDocumentosRelacionadosPagos.DataBind()
|
GVPDocumentosRelacionadosPagos.DataBind()
|
||||||
|
|
||||||
DTGVPagosVinculacion = DTDocumentosRelacionados
|
DTGVPagosVinculacion = DTDocumentosRelacionados
|
||||||
|
|
||||||
|
BtnVincularPago.Visible = False
|
||||||
|
If DTDocumentosRelacionados.Rows.Count > 0 Then
|
||||||
|
SerieFolioIE = DTDocumentosRelacionados.Rows(0)("SerieFolio").ToString
|
||||||
|
DivVincularPagoManualmente.Visible = False
|
||||||
|
BtnVincularPago.Visible = True
|
||||||
|
TieneRegistros = True
|
||||||
|
Else
|
||||||
|
DivVincularPagoManualmente.Visible = True
|
||||||
|
BtnVincularPago.Visible = False
|
||||||
|
End If
|
||||||
|
|
||||||
ComprasEnComplemento = DTGVPagosVinculacion.COUNT("CveCompra", " CveCompra > 0")
|
ComprasEnComplemento = DTGVPagosVinculacion.COUNT("CveCompra", " CveCompra > 0")
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
If DTDocumentosRelacionados.MAX("CveCompra").ToString.ToEntero > 0 Then
|
If DTDocumentosRelacionados.MAX("CveCompra").ToString.ToEntero > 0 Then
|
||||||
TieneCompras = True
|
TieneCompras = True
|
||||||
Else
|
Else
|
||||||
@@ -3096,25 +3107,25 @@ Partial Class Compras_eFacturas
|
|||||||
Dim ObjCompras As New ClsCompras
|
Dim ObjCompras As New ClsCompras
|
||||||
|
|
||||||
|
|
||||||
Dim TieneRegistros As Boolean = False
|
|
||||||
|
|
||||||
If ObjCompras.GetCompararComplementoPago(gvRow.DataKey("CveProveedor").ToEntero, Monto, nodePagos2.InnerXml.Replace("pago10:", "").Replace("pagos10:", ""), UsuarioActual.CveEmpresa) Then
|
|
||||||
GvVincularPago.DataSource = ObjCompras.DtResultados
|
|
||||||
|
|
||||||
If ObjCompras.DtResultados.Rows.Count > 0 Then
|
'If ObjCompras.GetCompararComplementoPago(gvRow.DataKey("CveProveedor").ToEntero, Monto, nodePagos2.InnerXml.Replace("pago10:", "").Replace("pagos10:", ""), UsuarioActual.CveEmpresa) Then
|
||||||
SerieFolioIE = ObjCompras.DtResultados.Rows(0)("SerieFolio").ToString
|
' GvVincularPago.DataSource = ObjCompras.DtResultados
|
||||||
DivVincularPagoManualmente.Visible = False
|
|
||||||
BtnVincularPago.Visible = True
|
' If ObjCompras.DtResultados.Rows.Count > 0 Then
|
||||||
TieneRegistros = True
|
' SerieFolioIE = ObjCompras.DtResultados.Rows(0)("SerieFolio").ToString
|
||||||
Else
|
' DivVincularPagoManualmente.Visible = False
|
||||||
DivVincularPagoManualmente.Visible = True
|
' BtnVincularPago.Visible = True
|
||||||
BtnVincularPago.Visible = False
|
' TieneRegistros = True
|
||||||
End If
|
' Else
|
||||||
'ImportePago = ObjCompras.DtResultados.SUMD("Monto")
|
' DivVincularPagoManualmente.Visible = True
|
||||||
Else
|
' BtnVincularPago.Visible = False
|
||||||
DivVincularPagoManualmente.Visible = False
|
' End If
|
||||||
BtnVincularPago.Visible = False
|
' 'ImportePago = ObjCompras.DtResultados.SUMD("Monto")
|
||||||
End If
|
'Else
|
||||||
|
' DivVincularPagoManualmente.Visible = False
|
||||||
|
' BtnVincularPago.Visible = False
|
||||||
|
'End If
|
||||||
|
|
||||||
For Each GvRowF As GridViewRow In GVPDocumentosRelacionadosPagos.Rows
|
For Each GvRowF As GridViewRow In GVPDocumentosRelacionadosPagos.Rows
|
||||||
|
|
||||||
|
|||||||
@@ -198,7 +198,13 @@ Partial Class PopUpAuxiliar
|
|||||||
e.Row.Cells(4).HorizontalAlign = HorizontalAlign.Left
|
e.Row.Cells(4).HorizontalAlign = HorizontalAlign.Left
|
||||||
|
|
||||||
If e.Row.FCLiteral("LtlContabilizado").Text = "Si" Then
|
If e.Row.FCLiteral("LtlContabilizado").Text = "Si" Then
|
||||||
Dim Liga As String = String.Format("<a class=""Texto"" href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">", e.Row.DBCampo("IdPoliza"))
|
Dim Liga As String
|
||||||
|
If UsuarioActual.Empresa.TipoContabilidad = 1 Then
|
||||||
|
Liga = String.Format("<a class=""Texto"" href=""/Contabilidad/RegPrePolizaS.aspx?CvePrePoliza={0}"">", e.Row.DBCampo("CvePrePoliza"))
|
||||||
|
Else
|
||||||
|
Liga = String.Format("<a class=""Texto"" href=""/Contabilidad/RegPoliza.aspx?IdPoliza={0}"">", e.Row.DBCampo("IdPoliza"))
|
||||||
|
End If
|
||||||
|
|
||||||
e.Row.FCLiteral("LtlPoliza").Text = String.Format("{0}{1}</a>", Liga, e.Row.DBCampo("Poliza"))
|
e.Row.FCLiteral("LtlPoliza").Text = String.Format("{0}{1}</a>", Liga, e.Row.DBCampo("Poliza"))
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
@@ -368,6 +368,7 @@
|
|||||||
<asp:DropDownList ID="DdlPersonal" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="NombreCompleto" DataValueField="CvePersonal" Width="160px" Visible="false"></asp:DropDownList>
|
<asp:DropDownList ID="DdlPersonal" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="NombreCompleto" DataValueField="CvePersonal" Width="160px" Visible="false"></asp:DropDownList>
|
||||||
<ADS:Dropdownlost ID="DdlClientes" CssStyle="width: 100%;" CssClassDdl="select2me" runat="server" AppendDataBoundItems="true" DataTextField="NombreComercial" DataValueField="CveCliente" Width="160px" Visible="false" AutoPostBack="true"></ADS:Dropdownlost>
|
<ADS:Dropdownlost ID="DdlClientes" CssStyle="width: 100%;" CssClassDdl="select2me" runat="server" AppendDataBoundItems="true" DataTextField="NombreComercial" DataValueField="CveCliente" Width="160px" Visible="false" AutoPostBack="true"></ADS:Dropdownlost>
|
||||||
<asp:DropDownList ID="DdlVentas" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="Folio" DataValueField="CveVenta" Width="160px" Visible="false"></asp:DropDownList>
|
<asp:DropDownList ID="DdlVentas" CssClass="form-control input-sm select2me" runat="server" AppendDataBoundItems="true" DataTextField="Folio" DataValueField="CveVenta" Width="160px" Visible="false"></asp:DropDownList>
|
||||||
|
<asp:Label ID="LblTC" runat="server" Text="TC" Visible="false"></asp:Label><asp:TextBox ID="TxtTCPreP" CssClass="form-control input-sm select2me" runat="server" Width="50px" Visible="false"></asp:TextBox>
|
||||||
|
|
||||||
</th>
|
</th>
|
||||||
<th>
|
<th>
|
||||||
|
|||||||
@@ -693,6 +693,17 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
Private Sub DdlConceptosContables_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlConceptosContables.SelectedIndexChanged
|
Private Sub DdlConceptosContables_SelectedIndexChanged(sender As Object, e As EventArgs) Handles DdlConceptosContables.SelectedIndexChanged
|
||||||
|
|
||||||
|
Dim dr As DataRow = GlobalDTContaConceptosContables(DdlConceptosContables.SelectedValue.ToEntero).FiltroPrimero("")
|
||||||
|
|
||||||
|
If dr IsNot Nothing Then
|
||||||
|
If dr("AplicaTC").ToString = "True" Then
|
||||||
|
TxtTCPreP.Visible = True
|
||||||
|
LblTC.Visible = True
|
||||||
|
Else
|
||||||
|
TxtTCPreP.Visible = False
|
||||||
|
LblTC.Visible = False
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
If DdlConceptosContables.SelectedValue.ToEntero.Contiene(5, 17, 201, 206, 14, 15, 16, 19, 25, 26, 21) Then
|
If DdlConceptosContables.SelectedValue.ToEntero.Contiene(5, 17, 201, 206, 14, 15, 16, 19, 25, 26, 21) Then
|
||||||
CargaProveedores()
|
CargaProveedores()
|
||||||
@@ -709,7 +720,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
Else
|
Else
|
||||||
DdlPersonal.Visible = False
|
DdlPersonal.Visible = False
|
||||||
End If
|
End If
|
||||||
If DdlConceptosContables.SelectedValue.ToEntero.Contiene(1, 2, 203, 207, 13, 61, 8, 9, 62, 63, 38, 39, 12, 91) Then
|
If DdlConceptosContables.SelectedValue.ToEntero.Contiene(1, 2, 203, 207, 13, 61, 8, 9, 62, 63, 38, 39, 12, 91, 291, 292) Then
|
||||||
CargaClientes()
|
CargaClientes()
|
||||||
DdlClientes.Visible = True
|
DdlClientes.Visible = True
|
||||||
DdlVentas.Visible = True
|
DdlVentas.Visible = True
|
||||||
@@ -1524,6 +1535,7 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
|
|
||||||
If AplicaBancos Then
|
If AplicaBancos Then
|
||||||
|
CargaModalConceptoTipoTransaccion("Egs")
|
||||||
'DvMoldalConceptoAncho.Attributes.Add("style", "width:1000px")
|
'DvMoldalConceptoAncho.Attributes.Add("style", "width:1000px")
|
||||||
DvMoldalConceptoSeccion1.Attributes.Add("class", "col-md-6")
|
DvMoldalConceptoSeccion1.Attributes.Add("class", "col-md-6")
|
||||||
DvMoldalConceptoSeccion2.Visible = True
|
DvMoldalConceptoSeccion2.Visible = True
|
||||||
@@ -2724,7 +2736,10 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
TxtFolio.Text = ObjConta.ContaFolio.ToString()
|
TxtFolio.Text = ObjConta.ContaFolio.ToString()
|
||||||
LnkFolioManual.Visible = False
|
LnkFolioManual.Visible = False
|
||||||
|
BtnContabilizar.Visible = False
|
||||||
|
BtnDescontabilizar.Visible = True
|
||||||
UpPoliza.Update()
|
UpPoliza.Update()
|
||||||
|
UpGuardar.Update()
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -3215,15 +3230,18 @@ Partial Class ContabilidadC_RegPrePolizaS
|
|||||||
|
|
||||||
|
|
||||||
If ObjConta.ContabilizaDesContabilizaPrePoliza(CvePrePoliza, False, UsuarioActual.CveEmpresa) Then
|
If ObjConta.ContabilizaDesContabilizaPrePoliza(CvePrePoliza, False, UsuarioActual.CveEmpresa) Then
|
||||||
|
|
||||||
Alert("Descontabilizado Correctamente.", TipoMensaje.MsgInformacion)
|
Alert("Descontabilizado Correctamente.", TipoMensaje.MsgInformacion)
|
||||||
TxtFolio.Text = ""
|
TxtFolio.Text = ""
|
||||||
LnkFolioManual.Visible = True
|
LnkFolioManual.Visible = True
|
||||||
|
BtnDescontabilizar.Visible = False
|
||||||
|
BtnContabilizar.Visible = True
|
||||||
End If
|
End If
|
||||||
|
|
||||||
ObjConta.Dispose()
|
ObjConta.Dispose()
|
||||||
|
|
||||||
UpPoliza.Update()
|
UpPoliza.Update()
|
||||||
|
UpGuardar.Update()
|
||||||
|
|
||||||
|
|
||||||
|
|
||||||
|
|||||||
@@ -1,5 +1,5 @@
|
|||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Report xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition" xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner">
|
<Report xmlns:rd="http://schemas.microsoft.com/SQLServer/reporting/reportdesigner" xmlns:cl="http://schemas.microsoft.com/sqlserver/reporting/2010/01/componentdefinition" xmlns="http://schemas.microsoft.com/sqlserver/reporting/2010/01/reportdefinition">
|
||||||
<AutoRefresh>0</AutoRefresh>
|
<AutoRefresh>0</AutoRefresh>
|
||||||
<DataSources>
|
<DataSources>
|
||||||
<DataSource Name="DataSet">
|
<DataSource Name="DataSet">
|
||||||
@@ -93,9 +93,9 @@
|
|||||||
</Paragraphs>
|
</Paragraphs>
|
||||||
<rd:DefaultName>Textbox1</rd:DefaultName>
|
<rd:DefaultName>Textbox1</rd:DefaultName>
|
||||||
<Top>3.15903cm</Top>
|
<Top>3.15903cm</Top>
|
||||||
<Left>2.98488cm</Left>
|
<Left>0.58123cm</Left>
|
||||||
<Height>0.6cm</Height>
|
<Height>0.6cm</Height>
|
||||||
<Width>14.64437cm</Width>
|
<Width>17.04802cm</Width>
|
||||||
<ZIndex>1</ZIndex>
|
<ZIndex>1</ZIndex>
|
||||||
<Style>
|
<Style>
|
||||||
<Border>
|
<Border>
|
||||||
@@ -261,9 +261,9 @@
|
|||||||
</Paragraphs>
|
</Paragraphs>
|
||||||
<rd:DefaultName>Textbox1</rd:DefaultName>
|
<rd:DefaultName>Textbox1</rd:DefaultName>
|
||||||
<Top>4.15713cm</Top>
|
<Top>4.15713cm</Top>
|
||||||
<Left>2.98488cm</Left>
|
<Left>0.58123cm</Left>
|
||||||
<Height>0.6cm</Height>
|
<Height>0.6cm</Height>
|
||||||
<Width>16.08307cm</Width>
|
<Width>18.48672cm</Width>
|
||||||
<ZIndex>6</ZIndex>
|
<ZIndex>6</ZIndex>
|
||||||
<Style>
|
<Style>
|
||||||
<Border>
|
<Border>
|
||||||
|
|||||||
@@ -8800,7 +8800,8 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
|||||||
|
|
||||||
|
|
||||||
//Tipo de registro A 1 1-1
|
//Tipo de registro A 1 1-1
|
||||||
sb.AppendLine("D");
|
sb.AppendLine("");
|
||||||
|
sb.Append("D");
|
||||||
//Fecha Aplicacion N 8 2-9
|
//Fecha Aplicacion N 8 2-9
|
||||||
sb.Append(DateTime.Now.ToString("yyyyMMdd"));
|
sb.Append(DateTime.Now.ToString("yyyyMMdd"));
|
||||||
|
|
||||||
@@ -8828,13 +8829,13 @@ public partial class Nomina_Nomina2 : ClsPaginas
|
|||||||
//NumeroCuenta N 18 120-137
|
//NumeroCuenta N 18 120-137
|
||||||
sb.Append(NumeroCuenta.PadLeft(18, Cero));
|
sb.Append(NumeroCuenta.PadLeft(18, Cero));
|
||||||
//Tipo movimiento N 1 138-138
|
//Tipo movimiento N 1 138-138
|
||||||
sb.Append(TipoCuenta.PadLeft(1, Cero));
|
sb.Append(TipoMovimiento.PadLeft(1, Cero));
|
||||||
//Accion N 1 139-139
|
//Accion N 1 139-139
|
||||||
sb.Append(Accion.PadLeft(1, Espacio));
|
sb.Append(Accion.PadLeft(1, Espacio));
|
||||||
//ImporteIvaOperacion 140-147
|
//ImporteIvaOperacion 140-147
|
||||||
sb.Append(ImporteIvaOperacion.PadLeft(8, Cero));
|
sb.Append(ImporteIvaOperacion.PadLeft(8, Cero));
|
||||||
//filler 18 148-165
|
//filler 18 148-165
|
||||||
sb.Append(string.Empty.PadLeft(77, Espacio));
|
sb.Append(string.Empty.PadLeft(18, Espacio));
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -196,7 +196,13 @@
|
|||||||
|
|
||||||
<div class="col-md-2" runat="server" id="DvLiquidacion1" visible="false">Liquidación:</div>
|
<div class="col-md-2" runat="server" id="DvLiquidacion1" visible="false">Liquidación:</div>
|
||||||
<div class="col-md-3" runat="server" id="DvLiquidacion2" visible="false">
|
<div class="col-md-3" runat="server" id="DvLiquidacion2" visible="false">
|
||||||
<asp:CheckBox ID="ChkLiquidacion" OnCheckedChanged="ChkLiquidacion_CheckedChanged" runat="server" AutoPostBack="true" />
|
<asp:UpdatePanel ID="UppTiempo" runat="server" UpdateMode="Conditional">
|
||||||
|
<ContentTemplate>
|
||||||
|
<asp:CheckBox ID="ChkLiquidacion" OnCheckedChanged="ChkLiquidacion_CheckedChanged" runat="server" AutoPostBack="true" />
|
||||||
|
<asp:Timer runat="server" ID="TimTiempo" Interval="300000" Enabled="false" OnTick="TimTiempo_Tick"></asp:Timer>
|
||||||
|
</ContentTemplate>
|
||||||
|
</asp:UpdatePanel>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
</div>
|
</div>
|
||||||
@@ -566,7 +572,7 @@
|
|||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<asp:UpdatePanel runat="server">
|
<asp:UpdatePanel runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
<asp:Button ID="BtnSaldarCuentasIncobrables" runat="server" CssClass="btn btn-primary" Text="Saldar cuentas" ValidationGroup="GrpIncobrable" />
|
<asp:Button ID="BtnSaldarCuentasIncobrables" runat="server" CssClass="btn btn-primary" Text="Saldar cuentas" ValidationGroup="GrpIncobrable" />
|
||||||
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
||||||
@@ -606,7 +612,7 @@
|
|||||||
</asp:UpdatePanel>
|
</asp:UpdatePanel>
|
||||||
</div>
|
</div>
|
||||||
<div class="modal-footer">
|
<div class="modal-footer">
|
||||||
<asp:UpdatePanel runat="server">
|
<asp:UpdatePanel runat="server" UpdateMode="Conditional">
|
||||||
<ContentTemplate>
|
<ContentTemplate>
|
||||||
<asp:Button ID="BtnVincularIntermediario" runat="server" CssClass="btn btn-primary" Text="Vincular Intermediario" />
|
<asp:Button ID="BtnVincularIntermediario" runat="server" CssClass="btn btn-primary" Text="Vincular Intermediario" />
|
||||||
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
<button type="button" class="btn btn-danger" data-dismiss="modal">Cancelar</button>
|
||||||
|
|||||||
@@ -1499,7 +1499,7 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If MsgError = "" AndAlso ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, 3) Then
|
If MsgError = "" AndAlso ObjMov.ValidacionPrePolizaCuadre(CvePrePoliza, 3) AndAlso UsuarioActual.CveEmpresa <> 158 Then
|
||||||
If ObjMov.ValorPolizaDescuadre > 0 Then
|
If ObjMov.ValorPolizaDescuadre > 0 Then
|
||||||
MsgError = ObjMov.MensajePolizaDescuadre + " La diferencia es de: " + ObjMov.ValorDiferencia
|
MsgError = ObjMov.MensajePolizaDescuadre + " La diferencia es de: " + ObjMov.ValorDiferencia
|
||||||
End If
|
End If
|
||||||
@@ -2871,11 +2871,15 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
|
|
||||||
#Region "LIQUIDACION"
|
#Region "LIQUIDACION"
|
||||||
|
|
||||||
|
Protected Sub TimTiempo_Tick(sender As Object, e As EventArgs)
|
||||||
|
Dim a As String = "se recarga para que no pierda sesíón el registro puede tardar más de una hora en llenar todos los datos" 'solo para que se ejecute sin que afecte a lo demás
|
||||||
|
End Sub
|
||||||
|
|
||||||
Protected Sub ChkLiquidacion_CheckedChanged(sender As Object, e As EventArgs)
|
Protected Sub ChkLiquidacion_CheckedChanged(sender As Object, e As EventArgs)
|
||||||
|
|
||||||
|
|
||||||
If ChkLiquidacion.Checked Then
|
If ChkLiquidacion.Checked Then
|
||||||
|
TimTiempo.Enabled = True 'para que no me saque
|
||||||
GvCxC.Columns(4).Visible = False
|
GvCxC.Columns(4).Visible = False
|
||||||
GvCxC.Columns(5).Visible = False
|
GvCxC.Columns(5).Visible = False
|
||||||
GvCxC.Columns(6).Visible = False
|
GvCxC.Columns(6).Visible = False
|
||||||
@@ -2899,6 +2903,7 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
|
|
||||||
|
|
||||||
Else
|
Else
|
||||||
|
TimTiempo.Enabled = False
|
||||||
GvCxC.Columns(4).Visible = True
|
GvCxC.Columns(4).Visible = True
|
||||||
GvCxC.Columns(5).Visible = True
|
GvCxC.Columns(5).Visible = True
|
||||||
GvCxC.Columns(6).Visible = True
|
GvCxC.Columns(6).Visible = True
|
||||||
@@ -2919,7 +2924,6 @@ Partial Class Ventas_ClientesAbonar
|
|||||||
GvCxC.Columns(27).Visible = True
|
GvCxC.Columns(27).Visible = True
|
||||||
GvCxC.Columns(28).Visible = True
|
GvCxC.Columns(28).Visible = True
|
||||||
|
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
UPVentas.Update()
|
UPVentas.Update()
|
||||||
|
|||||||
@@ -70,7 +70,7 @@
|
|||||||
<asp:BoundField HeaderText="Motivo" DataField="MotivoCancelacion" ItemStyle-Width="25%" />
|
<asp:BoundField HeaderText="Motivo" DataField="MotivoCancelacion" ItemStyle-Width="25%" />
|
||||||
<asp:TemplateField ItemStyle-Width="35px" HeaderText="Verificar">
|
<asp:TemplateField ItemStyle-Width="35px" HeaderText="Verificar">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<asp:LinkButton runat="server" OnClick="BtnValidar_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea verificar la cancelación?" data-btn-ok-label="si"></asp:LinkButton>
|
<asp:LinkButton runat="server" ID="BtnValidar" OnClick="BtnValidar_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea verificar la cancelación?" data-btn-ok-label="si"></asp:LinkButton>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
</Columns>
|
</Columns>
|
||||||
@@ -121,21 +121,26 @@
|
|||||||
<asp:LinkButton ID="LnkValidarRefac" runat="server" OnClick="BtnValidarRefacturacion_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea verificar la cancelación?" data-btn-ok-label="si"></asp:LinkButton>
|
<asp:LinkButton ID="LnkValidarRefac" runat="server" OnClick="BtnValidarRefacturacion_Click" CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-check'></i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea verificar la cancelación?" data-btn-ok-label="si"></asp:LinkButton>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:TemplateField ItemStyle-Width="35px" HeaderText="Cancelar">
|
<asp:TemplateField ItemStyle-Width="40px" HeaderText="Cancelar">
|
||||||
<ItemTemplate>
|
<ItemTemplate>
|
||||||
<div class="row" style="padding-bottom:3px;">
|
<div class="row" style="padding-bottom:3px;">
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<asp:LinkButton ID="LnkCancelar" Visible="false" runat="server" OnClick="BtnCancelarDocumento_Click" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-check'> Factura Pendiente</i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el documento?" data-btn-ok-label="si"></asp:LinkButton>
|
<asp:LinkButton ID="LnkCancelar" Visible="false" runat="server" OnClick="BtnCancelarDocumento_Click" CssClass="btn btn-circle btn-sm red" Text="<i class='fa fa-ban'> </i>" ToolTip="Cancelar refacturación" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el documento?" data-btn-ok-label="si"></asp:LinkButton>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-md-12">
|
<div class="col-md-12">
|
||||||
<asp:LinkButton ID="LnkCancelarFolioSustitucion" Visible="false" runat="server" OnClick="LnkCancelarFolioSustitucion_Click" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-check'> Folio Sustitucion</i>" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el documento?" data-btn-ok-label="si"></asp:LinkButton>
|
<asp:LinkButton ID="LnkCancelarFolioSustitucion" Visible="false" runat="server" OnClick="LnkCancelarFolioSustitucion_Click" CssClass="btn btn-circle btn-sm blue" Text="<i class='fa fa-ban'> 02</i>" ToolTip="Cancelar refacturación con método 02" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea cancelar el documento?" data-btn-ok-label="si"></asp:LinkButton>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
</ItemTemplate>
|
</ItemTemplate>
|
||||||
</asp:TemplateField>
|
</asp:TemplateField>
|
||||||
<asp:HyperLinkField HeaderText="Refacturar" Text="Refacturar" DataNavigateUrlFields="CveVenta" ItemStyle-Width="100px" DataNavigateUrlFormatString="/Ventas/Ventas.aspx?CveDevolucion={0}&NuevaFactura=1" />
|
<asp:TemplateField ItemStyle-Width="40px" HeaderText="Refact">
|
||||||
|
<ItemTemplate>
|
||||||
|
<asp:HyperLink ID="HplRefact" Visible="false" runat="server" Text="Refacturar" NavigateUrl="/Ventas/Ventas.aspx?CveDevolucion={0}&NuevaFactura=1" ></asp:HyperLink>
|
||||||
|
</ItemTemplate>
|
||||||
|
</asp:TemplateField>
|
||||||
|
|
||||||
</Columns>
|
</Columns>
|
||||||
<RowStyle CssClass="Texto" />
|
<RowStyle CssClass="Texto" />
|
||||||
<HeaderStyle CssClass="Titulos" />
|
<HeaderStyle CssClass="Titulos" />
|
||||||
|
|||||||
@@ -78,6 +78,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
|||||||
GvRefacturaciones.DataBind();
|
GvRefacturaciones.DataBind();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
GvDatos.DataBind();
|
GvDatos.DataBind();
|
||||||
UPDatos.Update();
|
UPDatos.Update();
|
||||||
}
|
}
|
||||||
@@ -569,11 +570,19 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
|
|||||||
{
|
{
|
||||||
if (e.Row.RowType == DataControlRowType.DataRow)
|
if (e.Row.RowType == DataControlRowType.DataRow)
|
||||||
{
|
{
|
||||||
if (e.Row.DBCampo("PuedeRefacturar").ToString().ToEntero() == 0 || !string.IsNullOrEmpty(e.Row.DBCampo("FolioFiscalSustitucion").ToString()))
|
GridView gv = (GridView)sender;
|
||||||
|
if (!(e.Row.DBCampo("PuedeRefacturar").ToString().ToEntero() == 0 || !string.IsNullOrEmpty(e.Row.DBCampo("FolioFiscalSustitucion").ToString())))
|
||||||
{
|
{
|
||||||
e.Row.Cells[12].Text = "";
|
e.Row.FCHyperLink("HplRefact").NavigateUrl = string.Format("/Ventas/Ventas.aspx?CveDevolucion={0}&NuevaFactura=1", e.Row.DBCampo("CveVenta"));
|
||||||
|
e.Row.FCHyperLink("HplRefact").Visible = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
if (e.Row.DBCampo("CveEstatusRefacturacion") == "4" && gv.ID=="GvDatos")
|
||||||
|
{
|
||||||
|
e.Row.FCLinkButton("BtnValidar").Text= "<i class='fa fa-check'>02</i>";
|
||||||
|
}
|
||||||
|
//
|
||||||
|
|
||||||
//if (e.Row.DBCampo("PuedeRefacturar").ToString().ToEntero() == 1 && e.Row.DBCampo("CveEstatusFactura").ToString().ToEntero() == 23)
|
//if (e.Row.DBCampo("PuedeRefacturar").ToString().ToEntero() == 1 && e.Row.DBCampo("CveEstatusFactura").ToString().ToEntero() == 23)
|
||||||
//{
|
//{
|
||||||
// e.Row.FCLinkButton("LnkValidarRefac").Visible = false;
|
// e.Row.FCLinkButton("LnkValidarRefac").Visible = false;
|
||||||
|
|||||||
@@ -6231,7 +6231,13 @@ Partial Class Ventas
|
|||||||
|
|
||||||
'SI LA VENTA YA ESTA REGISTRADA NO DEBE HABILITAR ACCIONES
|
'SI LA VENTA YA ESTA REGISTRADA NO DEBE HABILITAR ACCIONES
|
||||||
If CveVenta <= 0 Then
|
If CveVenta <= 0 Then
|
||||||
LnkRemisiones.Visible = If(UsuarioActual.TienePermisoProceso(199), True, False) : LnkOCs.Visible = True : LnkCotizaciones.Visible = True : LnkPedido2SinFacturar.Visible = True : InicializaAplicarNCMasiva()
|
Dim EsModuloCotizacion As Boolean = False
|
||||||
|
If Request("Op") IsNot Nothing AndAlso Request("Op").ToString() = "Cot" Then
|
||||||
|
EsModuloCotizacion = True
|
||||||
|
End If
|
||||||
|
If Not EsModuloCotizacion Then
|
||||||
|
LnkRemisiones.Visible = If(UsuarioActual.TienePermisoProceso(199), True, False) : LnkOCs.Visible = True : LnkCotizaciones.Visible = True : LnkPedido2SinFacturar.Visible = True : InicializaAplicarNCMasiva()
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If UsuarioActual.Empresa.CvePlataforma = 2 Then LnkOCs.Visible = False
|
If UsuarioActual.Empresa.CvePlataforma = 2 Then LnkOCs.Visible = False
|
||||||
@@ -7120,7 +7126,13 @@ Partial Class Ventas
|
|||||||
|
|
||||||
'SI LA VENTA YA ESTA REGISTRADA NO DEBE HABILITAR ACCIONES
|
'SI LA VENTA YA ESTA REGISTRADA NO DEBE HABILITAR ACCIONES
|
||||||
If CveVenta <= 0 Then
|
If CveVenta <= 0 Then
|
||||||
LnkRemisiones.Visible = If(UsuarioActual.TienePermisoProceso(199), True, False) : LnkOCs.Visible = True : LnkCotizaciones.Visible = True : LnkPedido2SinFacturar.Visible = True : InicializaAplicarNCMasiva()
|
Dim EsModuloCotizacion As Boolean = False
|
||||||
|
If Request("Op") IsNot Nothing AndAlso Request("Op").ToString() = "Cot" Then
|
||||||
|
EsModuloCotizacion = True
|
||||||
|
End If
|
||||||
|
If Not EsModuloCotizacion Then
|
||||||
|
LnkRemisiones.Visible = If(UsuarioActual.TienePermisoProceso(199), True, False) : LnkOCs.Visible = True : LnkCotizaciones.Visible = True : LnkPedido2SinFacturar.Visible = True : InicializaAplicarNCMasiva()
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
ObjCliente.Dispose()
|
ObjCliente.Dispose()
|
||||||
@@ -7693,10 +7705,31 @@ Partial Class Ventas
|
|||||||
If ValidaExistencia AndAlso DdlTipoComprobante.SelectedValue <> "Cot" And ChkSinExistencia.Checked = False AndAlso Not RegistroxOC Then
|
If ValidaExistencia AndAlso DdlTipoComprobante.SelectedValue <> "Cot" And ChkSinExistencia.Checked = False AndAlso Not RegistroxOC Then
|
||||||
'VALIDA EXISTENCIA
|
'VALIDA EXISTENCIA
|
||||||
If UsuarioActual.CveEmpresa.Contiene({72, 80, 119, 140, 153}) Then
|
If UsuarioActual.CveEmpresa.Contiene({72, 80, 119, 140, 153}) Then
|
||||||
If Existencia - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} AND (EntregaDirecta IS NULL OR EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
'SI ES VENTA NUEVA TOMA EN CUENTA LO DEL TMPDT
|
||||||
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
If CveVenta <= 0 Then
|
||||||
Exit Sub
|
If Existencia - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} AND (EntregaDirecta IS NULL OR EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
||||||
|
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
If DdlTipoComprobante.SelectedValue = "Rem" Then
|
||||||
|
Dim CantidadVenta As Double = 0
|
||||||
|
Using ObjVentas As New ClsVentas
|
||||||
|
If ObjVentas.GetVentaDetalle(CveVenta) Then
|
||||||
|
CantidadVenta = ObjVentas.DtResultados.SUM("Cantidad", $"CvePS = {CvePS}")
|
||||||
|
End If
|
||||||
|
End Using
|
||||||
|
|
||||||
|
'SUMA LO YA RESTADO EN PENDIENTE POR SURTIR QUE PERTENESCA A LA VENTA.
|
||||||
|
'PARA QUE NO RESTE LA EXISTENCIA 2 VECES Y PUEDAS COMPARAR LO REAL
|
||||||
|
If (Existencia + CantidadVenta) - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} AND (EntregaDirecta IS NULL OR EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
||||||
|
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
||||||
|
Exit Sub
|
||||||
|
End If
|
||||||
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
@@ -9146,6 +9179,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
If UsuarioActual.CveEmpresa = 140 Then
|
If UsuarioActual.CveEmpresa = 140 Then
|
||||||
AutoConta = True
|
AutoConta = True
|
||||||
|
idCuentaContabilizacion = 10
|
||||||
End If
|
End If
|
||||||
|
|
||||||
If AutoConta Then
|
If AutoConta Then
|
||||||
@@ -14352,7 +14386,7 @@ Partial Class Ventas
|
|||||||
|
|
||||||
Dim DebeGenerarMovimiento As Boolean = TmpDT.COUNT("CvePS", "CveTipoPS = 2") > 0
|
Dim DebeGenerarMovimiento As Boolean = TmpDT.COUNT("CvePS", "CveTipoPS = 2") > 0
|
||||||
'VERIFICA QUE SE REALIZO EL MOVIMIENTO DE ALMACEN
|
'VERIFICA QUE SE REALIZO EL MOVIMIENTO DE ALMACEN
|
||||||
If DebeGenerarMovimiento AndAlso UsuarioActual.Empresa.Funcionalidad(558) = "1" AndAlso UsuarioActual.Empresa.Funcionalidad(567) = "1" AndAlso factura.TipoDocto.Contiene("Ing", "Egs", "Rem") Then
|
If DebeGenerarMovimiento AndAlso UsuarioActual.Empresa.Funcionalidad(558) = "1" AndAlso UsuarioActual.Empresa.Funcionalidad(567) = "1" AndAlso factura.TipoDocto.Contiene("Ing", "Rem") Then
|
||||||
If Not (ObjInventario.GetInv_Mov(factura.CveVenta, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0) Then
|
If Not (ObjInventario.GetInv_Mov(factura.CveVenta, UsuarioActual.CveEmpresa) AndAlso ObjInventario.DtResultados.Rows.Count > 0) Then
|
||||||
OcurrioError = True
|
OcurrioError = True
|
||||||
ErrorList.Add("Ocurrió un error al verificar inventario.<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico")
|
ErrorList.Add("Ocurrió un error al verificar inventario.<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico")
|
||||||
@@ -17583,10 +17617,29 @@ Partial Class Ventas
|
|||||||
If DdlTipoComprobante.SelectedValue <> "Cot" And ChkSinExistencia.Checked = False Then
|
If DdlTipoComprobante.SelectedValue <> "Cot" And ChkSinExistencia.Checked = False Then
|
||||||
'VALIDA EXISTENCIA
|
'VALIDA EXISTENCIA
|
||||||
If UsuarioActual.CveEmpresa.Contiene({72, 80, 119, 153, 140}) Then
|
If UsuarioActual.CveEmpresa.Contiene({72, 80, 119, 153, 140}) Then
|
||||||
If Existencia - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} AND (EntregaDirecta IS NULL OR EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
If CveVenta <= 0 OrElse Me.EsCreaApartirDe Then
|
||||||
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
If Existencia - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} AND (EntregaDirecta IS NULL OR EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
||||||
Return False
|
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
Else
|
||||||
|
If DdlTipoComprobante.SelectedValue = "Rem" Then
|
||||||
|
Dim CantidadVenta As Double = 0
|
||||||
|
Using ObjVentasE As New ClsVentas
|
||||||
|
If ObjVentasE.GetVentaDetalle(CveVenta) Then
|
||||||
|
CantidadVenta = ObjVentasE.DtResultados.SUM("Cantidad", $"CvePS = {CvePS}")
|
||||||
|
End If
|
||||||
|
End Using
|
||||||
|
|
||||||
|
'SUMA LO YA RESTADO EN PENDIENTE POR SURTIR QUE PERTENESCA A LA VENTA.
|
||||||
|
'PARA QUE NO RESTE LA EXISTENCIA 2 VECES Y PUEDAS COMPARAR LO REAL
|
||||||
|
If (Existencia + CantidadVenta) - TmpDT.SUM("Cantidad", $"CvePS = {CvePS} And (EntregaDirecta Is NULL Or EntregaDirecta < 1)") < TxtCantidad.Text.ToDouble Then
|
||||||
|
Alert("No cuenta con la cantidad suficiente en inventario. Cuenta con " + Existencia.FormatoNumero(2) + ".", TipoMensaje.MsgAdvertencia)
|
||||||
|
Return False
|
||||||
|
End If
|
||||||
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
End If
|
End If
|
||||||
End If
|
End If
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user