This commit is contained in:
JORGE LUIS CAUDILLO ESPARZA
2020-06-04 14:41:16 -07:00
42 changed files with 2010 additions and 213 deletions

View File

@@ -492,7 +492,8 @@ Public Class ClsCGame
#End Region
#Region "ORDEN DE PRODUCCION"
Public Function GetOrdenProduccion(CveOrdenProduccion As Integer, CveEmpresa As Integer, CveEstatus As Integer, Folio As String, FEntregaI As Date, FEntregaF As Date, CveCliente As Integer) As Boolean
Public Function GetOrdenProduccion(CveOrdenProduccion As Integer, CveEmpresa As Integer, CveEstatus As Integer, Folio As String, FEntregaI As Date, FEntregaF As Date,
CveCliente As Integer, Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_CGame_OrdenProduccionGet")
With SqlAdapter.SelectCommand.Parameters
@@ -503,6 +504,7 @@ Public Class ClsCGame
.Add("@FEntregaI", SqlDbType.Date).Value = FEntregaI
.Add("@FEntregaF", SqlDbType.Date).Value = FEntregaF
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With
Try
SqlAdapter.Fill(Data)
@@ -1039,7 +1041,9 @@ Public Class ClsCGame
#End Region
#Region "PRODUCCION"
Public Function GetProduccion(CveEmpresa As Integer, Optional Folio As String = "-1", Optional CveProduccion As Integer = -1, Optional CveHuerta As Integer = -1, Optional FechaI As Date = MinFecha, Optional FechaF As Date = MaxFecha, Optional Opcion As Integer = -1, Optional Modalidad As Integer = -1) As Boolean
Public Function GetProduccion(CveEmpresa As Integer, Optional Folio As String = "-1", Optional CveProduccion As Integer = -1, Optional CveHuerta As Integer = -1,
Optional FechaI As Date = MinFecha, Optional FechaF As Date = MaxFecha, Optional Opcion As Integer = -1, Optional Modalidad As Integer = -1,
Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_CGame_ProduccionGet")
With SqlAdapter.SelectCommand.Parameters
@@ -1051,6 +1055,7 @@ Public Class ClsCGame
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@Opcion", SqlDbType.Int).Value = Opcion
.Add("@Modalidad", SqlDbType.Int).Value = Modalidad
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With
Try
SqlAdapter.Fill(Data)

View File

@@ -651,7 +651,7 @@ Public Class ClsCRM
Public Function GetAcercamiento(CveEmpresa As Integer, Optional CveEmpresaCRM As Integer = -1, Optional CveAcercamiento As Integer = -1, Optional CveTipoProceso As Integer = -1,
Optional CveVendedor As Integer = -1, Optional FechaInicio As String = "-1", Optional FechaFin As String = "-1", Optional NombreAcercamiento As String = "-1",
Optional CveMedioCaptacion As Integer = -1, Optional CveRechazoMotivo As Integer = -1, Optional CveProbabilidad As Integer = -1,
Optional FechaApertura As String = "-1", Optional FechaCierre As String = "-1") As Boolean
Optional FechaApertura As String = "-1", Optional FechaCierre As String = "-1", Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_CRM_AcercamientoGet")
With SqlAdapter.SelectCommand.Parameters
@@ -673,6 +673,8 @@ Public Class ClsCRM
.Add("@FechaFin", SqlDbType.VarChar).Value = FechaFin
.Add("@FechaApertura", SqlDbType.VarChar).Value = FechaApertura
.Add("@FechaCierre", SqlDbType.VarChar).Value = FechaCierre
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With
Try
SqlAdapter.Fill(Data)

View File

@@ -1880,7 +1880,8 @@ Public Class ClsContratos
#Region " REPORTE BUSQUEDA"
Public Function GetContratosBusquedaRep(TipoVenta As Integer, CveContratoTipo As Integer, NumeroContrato As String, DescripcionContrato As String, Ubicacion As String, Responsable As String,
EstatusContrato As Integer, CveProyecto As Integer, CveSubProyecto As Integer, CveEmpresa As Integer, CveCliente As Integer, CveProveedor As Integer) As Boolean
EstatusContrato As Integer, CveProyecto As Integer, CveSubProyecto As Integer, CveEmpresa As Integer, CveCliente As Integer, CveProveedor As Integer,
Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Con_ContratosBusquedaRepGet")
@@ -1898,6 +1899,7 @@ Public Class ClsContratos
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
.Add("@CveProveedor", SqlDbType.Int).Value = CveProveedor
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With

View File

@@ -732,7 +732,8 @@ Public Class ClsInventarios
Return Retorno
End Function
Public Function GetMovimientosRep(CveAlmacen As Integer, CveTipoMovimiento As Integer, Folio As Integer, FechaIngI As Date, FechaIngF As Date, FechaInicio As Date, FechaFin As Date, CveUsuario As Integer, CveEmpresa As Integer) As Boolean
Public Function GetMovimientosRep(CveAlmacen As Integer, CveTipoMovimiento As Integer, Folio As Integer, FechaIngI As Date, FechaIngF As Date, FechaInicio As Date,
FechaFin As Date, CveUsuario As Integer, CveEmpresa As Integer, Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Inv_MovimientosRep")
@@ -746,6 +747,7 @@ Public Class ClsInventarios
.Add("@FechaFin ", SqlDbType.DateTime).Value = FechaFin
.Add("@CveUsuario", SqlDbType.Int).Value = CveUsuario
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With
Try
SqlAdapter.Fill(Data)
@@ -1818,7 +1820,7 @@ Public Class ClsInventarios
Optional FechaMovto As String = "-1", Optional CveVendedor As Integer = -1, Optional CveCliente As Integer = -1,
Optional Serie As String = "-1", Optional Lote As String = "-1", Optional Caducidad As Date = MinFecha,
Optional ExcluyeAdelantado As Integer = -1, Optional PendientePorSurtir As Integer = -1,
Optional ExcluyeApartados As Integer = 1, Optional RestringirAlmacenes As Integer = -1) As Boolean
Optional ExcluyeApartados As Integer = 1, Optional RestringirAlmacenes As Integer = -1, Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Inv_ExistenciasGet")
@@ -1839,6 +1841,7 @@ Public Class ClsInventarios
.Add("@PendientePorSurtir", SqlDbType.Int).Value = PendientePorSurtir
.Add("@ExcluyeApartados", SqlDbType.Int).Value = ExcluyeApartados
.Add("@RestringirAlmacenes", SqlDbType.Int).Value = RestringirAlmacenes
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
.Add("@Existencia", SqlDbType.Money).Direction = ParameterDirection.Output
End With
@@ -4746,13 +4749,17 @@ Public Class ClsInventarios
#Region "MOVIMIENTOS SALIDA"
Public Function GetRepMovimientosSalida(FechaI As Date, FechaF As Date, CveEmpresa As Integer) As Boolean
Public Function GetRepMovimientosSalida(FechaI As Date, FechaF As Date, CveSubProyecto As Integer, CveCliente As Integer, CveClasificacion As Integer, Grupo As Integer, CveEmpresa As Integer) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_Inv_RepMovimientosSalidaGet")
With SqlAdapter.SelectCommand.Parameters
.Add("@FechaI", SqlDbType.Date).Value = FechaI
.Add("@FechaF", SqlDbType.Date).Value = FechaF
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
.Add("@CveCliente", SqlDbType.Int).Value = CveCliente
.Add("@CveClasificacion", SqlDbType.Int).Value = CveClasificacion
.Add("@CveEmpresa", SqlDbType.Int).Value = CveEmpresa
.Add("@Grupo", SqlDbType.Int).Value = Grupo
End With
Try
SqlAdapter.Fill(Data)

View File

@@ -1728,7 +1728,7 @@ Public Class ClsOC
Public Function GetOrdenesCompraRep(Tipo As String, CveProyecto As Integer, CveSubProyecto As Integer, CveClasificacion As Integer, CveEstatus As Integer,
FechaInicio As Date, FechaFin As Date, CveOrdenCompra As Integer, CveProveedor As Integer, Folio As Integer, CveUsuarioRegistro As Integer, CveUsuario As Integer, CveEmpresa As Integer, CvePS As Integer, Optional PendientePorSurtir As Boolean = False, Optional CveCliente As Integer = -1, Optional Guia As String = "-1", Optional CveActivoFijo As Integer = -1,
Optional SoloSubProyectosConPermiso As Boolean = False, Optional CveUsuarioAutorizo As Integer = -1) As Boolean
Optional SoloSubProyectosConPermiso As Boolean = False, Optional CveUsuarioAutorizo As Integer = -1, Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_OC_OrdenesCompraRep")
@@ -1754,6 +1754,7 @@ Public Class ClsOC
.Add("@CveActivoFijo", SqlDbType.Int).Value = CveActivoFijo
.Add("@SoloSubProyectosConPermiso", SqlDbType.Bit).Value = SoloSubProyectosConPermiso
.Add("@CveUsuarioAutorizo", SqlDbType.Int).Value = CveUsuarioAutorizo
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With

View File

@@ -470,7 +470,8 @@ Public Class ClsOS
Return Retorno
End Function
Public Function GetOrdenesServicios(CveOS As Integer, CveCliente As Integer, Folio As Integer, CveUsuarioRecibio As Integer, CveEstatusOrdenServicio As Integer, CveEmpresa As Integer, Optional CveSubProyecto As Integer = -1) As Boolean
Public Function GetOrdenesServicios(CveOS As Integer, CveCliente As Integer, Folio As Integer, CveUsuarioRecibio As Integer, CveEstatusOrdenServicio As Integer,
CveEmpresa As Integer, Optional CveSubProyecto As Integer = -1, Optional TopSelect As Integer = 10000) As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_OS_OrdenesServiciosGet")
@@ -482,6 +483,7 @@ Public Class ClsOS
.Add("@CveUsuarioRecibio", SqlDbType.Int).Value = CveUsuarioRecibio
.Add("@CveEstatusOrdenServicio", SqlDbType.Int).Value = CveEstatusOrdenServicio
.Add("@CveSubProyecto", SqlDbType.Int).Value = CveSubProyecto
.Add("@TopSelect", SqlDbType.Int).Value = TopSelect
End With
Try
SqlAdapter.Fill(Data)

View File

@@ -4262,13 +4262,14 @@ Public Class ClsPaginas
PaginaDict.Add("/General/CatDiasInhabiles.aspx".ToUpper(), 429)
PaginaDict.Add("/General/CatTipoCambio.aspx".ToUpper(), 642)
PaginaDict.Add("/General/PopUpPaqueteriasGuias.aspx".ToUpper(), 659)
PaginaDict.Add("/General/PopUpPaqueteriasGuiasInternas.aspx".ToUpper(), 659)
PaginaDict.Add("/General/CatPaqueterias.aspx".ToUpper(), 665)
PaginaDict.Add("/General/CatDocumentacionTipo.aspx".ToUpper(), -1)
PaginaDict.Add("/General/CatModelos.aspx".ToUpper(), 710)
PaginaDict.Add("/General/CatRinTamanios.aspx".ToUpper(), 711)
PaginaDict.Add("/General/CatMedidas.aspx".ToUpper(), 712)
PaginaDict.Add("/General/CatSatListado69B.aspx".ToUpper, 1038)
PaginaDict.Add("/General/PopUpPaqueteriasGuiasInternas.aspx".ToUpper(), 727)
#End Region
#Region "GPS"

View File

@@ -339,7 +339,8 @@ Public Class ClsVentas
Optional ObservacionesAlmacen As String = "", Optional CveSubProyecto As Integer = -1, Optional CveSubProyectoEjecucion As Integer = -1, Optional CveSubProyectoCobranza As Integer = -1,
Optional CveFormaPago33 As Integer = -1, Optional CveMetodoPago33 As Integer = -1, Optional CveUsoCFDI As Integer = -1, Optional OrdenCompra As String = "-1", Optional CveCuentaTerminal As Integer = -1, Optional CveTipoRelacion As Integer = -1, Optional ImpuestoLocal As Double = 0,
Optional CveTipoAmortizacionAnticipo As Integer = -1, Optional CveVentaRelacion As Integer = -1, Optional ImporteRelacion As Decimal = -1, Optional CveEmpresaCRM As Integer = -1, Optional EsInterno As Integer = -1, Optional CveAcercamientoCRM As Integer = -1,
Optional DiasCredito As Integer = 0, Optional EsDiasCreditoFijo As Boolean = False, Optional AnticipoEspecial As Boolean = False, Optional Kilometraje As Double = 0, Optional EsAmortizacion As Boolean = False, Optional CveTipoRetencion As Integer = 0) As Boolean
Optional DiasCredito As Integer = 0, Optional EsDiasCreditoFijo As Boolean = False, Optional AnticipoEspecial As Boolean = False, Optional Kilometraje As Double = 0, Optional EsAmortizacion As Boolean = False, Optional CveTipoRetencion As Integer = 0,
Optional CorreoNotificacion As String = "") As Boolean
Dim Retorno As Boolean = False
DataAdapter("PA_VentasAdd")
@@ -428,6 +429,7 @@ Public Class ClsVentas
.Add("@Kilometraje", SqlDbType.Float).Value = Kilometraje
.Add("@EsAmortizacion", SqlDbType.Bit).Value = EsAmortizacion
.Add("@CveTipoRetencion", SqlDbType.TinyInt).Value = CveTipoRetencion
.Add("@CorreoNotificacion", SqlDbType.VarChar).Value = CorreoNotificacion
.Add("@RETURN_VALUE", SqlDbType.Int).Direction = ParameterDirection.ReturnValue
End With

View File

@@ -544,6 +544,8 @@ Namespace Extensiones
Alert("", String.Format("{0} code[FilesMove]", ex.Message), TipoMensaje.MsgAdvertencia)
retorno = False
End Try
directorioOld.Clear()
directorioNew.Clear()
Return retorno
End Function
<Runtime.CompilerServices.Extension()>
@@ -2044,6 +2046,8 @@ Namespace Extensiones
HttpContext.Current.Response.Write(style.ToString)
HttpContext.Current.Response.Write(sb.ToString())
HttpContext.Current.Response.End()
sb.Clear()
style.Clear()
End If
End Sub
@@ -2076,6 +2080,8 @@ Namespace Extensiones
HttpContext.Current.Response.Write(style.ToString)
HttpContext.Current.Response.Write(sb.ToString())
HttpContext.Current.Response.End()
sb.Clear()
style.Clear()
End Sub
<Runtime.CompilerServices.Extension()>
Public Sub ExportToExcel(datatable As DataTable, NombreArchivoXLSX As String)
@@ -2284,6 +2290,7 @@ Namespace Extensiones
HttpContext.Current.Response.Write(style.ToString)
HttpContext.Current.Response.Write(pdfDoc)
HttpContext.Current.Response.[End]()
style.Clear()
End Using
End Using
End Sub

View File

@@ -77,7 +77,7 @@ Partial Class Bancos_CargarConciliacionesBancarias
Protected Sub BtnCargaExcel_Click(sender As Object, e As EventArgs)
If TxtExcel.getfiles().Archivos.Count > 0 Then
Dim file As Archivo = TxtExcel.getfiles().Archivos(0)
Dim Directorio As String = ModExtensiones.DirectorioBaseEmpresas & file.patch
Dim Directorio As String = AppDomain.CurrentDomain.BaseDirectory & file.patch
Dim Tipo As String = If(file.Extencion.Contiene("xlsx", "xlsx", "xlsm", "xlsb"), "EXCEL", "CSV")
CargaExcel(Directorio, file.filename, Tipo)
Else

View File

@@ -644,9 +644,12 @@ Partial Class Bancos_ConciliacionesBancariasaspx
ObjConta.Dispose()
End If
Dim Filtros As String = String.Format("<b>Cuenta: </b>{0}&emsp;<b>Conciliado: </b>{1}&emsp;<b>Fecha Inicial: </b>{2}&emsp;<b>Fecha Final: </b>{3}", DdlCuenta.SelectedItem.Text, DdlConciliado.SelectedItem.Text, txtFechaI.Text, txtFechaF.Text)
params.Add(New ReportParameter("SaldoFinalContabilidad", (SaldoFinalContabilidad.FormatoNumero)))
params.Add(New ReportParameter("SaldoFinalContabilidadComplementaria", (SaldoFinalContabilidadComplementaria.FormatoNumero)))
params.Add(New ReportParameter("Diferencia", (SaldoFinalLibros - SaldoFinalContabilidad).FormatoNumero))
params.Add(New ReportParameter("Filtros", Filtros))
If Imagen.Exists Then
params.Add(New ReportParameter("LogoPath", logouri))

View File

@@ -941,7 +941,8 @@ Partial Class Bancos_IE
HplListaProveedores.NavigateUrl = $"/Compras/PopUpVerFactura.aspx?P={StrEncript}"
Else
HplListaProveedores.NavigateUrl = String.Format("/Bancos/Reportes.aspx?Opcion=ImprimeMov&CveIE={0}", ObjIE.CveIE)
Dim StrEncript As String = Encripta($"OP=ImprimeMov&CveIE={ObjIE.CveIE}")
HplListaProveedores.NavigateUrl = String.Format("/Compras/PopUpVerFactura.aspx?P={0}", StrEncript)
End If
If CveIEDeposito2 > 0 Then
divDepositado.Visible = True
@@ -2492,7 +2493,7 @@ Partial Class Bancos_IE
'GUARDA COMPROBANTE
If filemove <> "" Then
filemove.FilesMove(CveIE.ToString, String.Format("Empresas\{0}\IE", UsuarioActual.CveEmpresa, UsuarioActual.Empresa.Ruta))
filemove.FilesMove(CveIE.ToString, String.Format("Empresas\{0}\IE", UsuarioActual.CveEmpresa))
End If
'GUARDA PREPOLIZAS DETALLE [PRIMERO SON LOS CASOS ESPECIALES, AL FINAL (ELSE) LOS CASOS NORMALES] --REEMPLAZA IFs

View File

@@ -31,7 +31,7 @@ public partial class CGame_PopUpBuscarProduccion :ClsPaginas
DdlHuerta.DataBind();
}
ObjCort.Dispose();
UPDatos.Update();
UPDatos.Update();
}
protected void Consultar_Click(object sender, EventArgs e)

View File

@@ -39,7 +39,8 @@ Partial Class CGame_PopUpBuscarOrdenProduccion
If TxtFolio.Text.Trim <> "" Then Folio = TxtFolio.Text Else Folio = "-1"
If ValidarFiltrosSeleccionado() Then
Dim ObjOP As New ClsCGame
If ObjOP.GetOrdenProduccion(-1, UsuarioActual.CveEmpresa, DdlEstatus.SelectedValue.ToEntero, Folio, TxtFechaEntregaI.Text.ToDate, TxtFechaEntregaF.Text.ToDate, DdlCliente.SelectedValue.ToEntero) Then
If ObjOP.GetOrdenProduccion(-1, UsuarioActual.CveEmpresa, DdlEstatus.SelectedValue.ToEntero, Folio, TxtFechaEntregaI.Text.ToDate, TxtFechaEntregaF.Text.ToDate,
DdlCliente.SelectedValue.ToEntero, TopSelect:=100) Then
GvOP.DataSource = ObjOP.DtResultados
GvOP.DataBind()
LtlTotalRegistros.Text = ObjOP.DtResultados.Rows.Count.ToString

View File

@@ -167,7 +167,8 @@ public partial class CRM_PopUpBuscarAcercamiento : ClsPaginas
if (ValidarFiltrosSeleccionados())
{
ClsCRM ObjCRM = new ClsCRM();
if (ObjCRM.GetAcercamiento(UsuarioActual.CveEmpresa, CveEmpresaCRM, -1, CveTipoProceso, CveVendedor, "-1", "-1", NombreAcercamiento, CveMedioCaptacion, CveRechazoMotivo, CveProbabilidad, FechaApertura, FechaCierre))
if (ObjCRM.GetAcercamiento(UsuarioActual.CveEmpresa, CveEmpresaCRM, -1, CveTipoProceso, CveVendedor, "-1", "-1", NombreAcercamiento, CveMedioCaptacion, CveRechazoMotivo,
CveProbabilidad, FechaApertura, FechaCierre, TopSelect:100))
{
GVDatos.DataSource = ObjCRM.DtResultados;
GVDatos.DataBind();

View File

@@ -2364,10 +2364,8 @@
<table>
<tr id="TrRembolsoUpdate" runat="server" visible="False">
<td>Rembolso:
<td>Reembolso:
<asp:RadioButtonList ID="RblRembolso" OnSelectedIndexChanged="RblRembolso_SelectedIndexChanged" RepeatDirection="Horizontal" runat="server" AutoPostBack="True">
<asp:ListItem Value="1">Personal/Empleado</asp:ListItem>
<asp:ListItem Value="2">Caja Chica</asp:ListItem>
@@ -2554,10 +2552,11 @@
<asp:UpdatePanel ID="UpFacturar" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<asp:Button ID="BtnGuardar" CssClass="btn btn-primary " runat="server" data-toggle="confirmation" data-popout="true" data-original-title="<b>Verifique los datos para continuar</b>. <br/><br/> <center>¿Seguro de registrar el documento con la información actual?</center>" data-btn-ok-label="si" Text="Registrar Compra" />
<asp:Button ID="BtnGuardar" CssClass="btn btn-primary " runat="server" ValidationGroup="GrpGuardar" data-toggle="confirmation" data-popout="true" data-original-title="<b>Verifique los datos para continuar</b>. <br/><br/> <center>¿Seguro de registrar el documento con la información actual?</center>" data-btn-ok-label="si" Text="Registrar Compra" />
<asp:Button ID="BtnActualizar" CssClass="btn btn-success" runat="server" Text="Actualizar Compra" ValidationGroup="GrpGuardar" Visible="False" />
<br />
<br />
<asp:Button ID="BtnEliminarCompra" CssClass="btn btn-danger" Visible="False" runat="server" Text="Eliminar Compra" data-toggle="confirmation" data-popout="true" data-original-title="¿Seguro que desea eliminar la compra?" data-btn-ok-label="si" />
<br />
<br />
@@ -3920,8 +3919,8 @@
<div class="row">
<div class="col-md-2" style="width: 90%; margin-left: 5%; margin-right: 5%; text-align: left">
<asp:TextBox ID="TxtNumeroReembolso" runat="server" Width="100%" />
<asp:RequiredFieldValidator ID="RFVNumeroReembolso" runat="server" ControlToValidate="TxtNumeroReembolso" InitialValue="" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero de Reembolso''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCENumeroReembolso" runat="server" HighlightCssClass="vco" TargetControlID="RFVNumeroReembolso" Width="300px"></ajax:ValidatorCalloutExtender>
<%-- <asp:RequiredFieldValidator ID="RFVNumeroReembolso" runat="server" ControlToValidate="TxtNumeroReembolso" InitialValue="" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Numero de Reembolsoxx''</b> es necesario, por favor seleccione uno." ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCENumeroReembolso" runat="server" HighlightCssClass="vco" TargetControlID="RFVNumeroReembolso" Width="300px"></ajax:ValidatorCalloutExtender>--%>
</div>
</div>
</div>

View File

@@ -10695,7 +10695,6 @@ Partial Class Compras_Compras
'VALIDA UNIDAD DE MEDIDA
If e.Row.DBCampo("CvePS").ToString.ToEntero > 0 Then
Dim DtEquivalencias = GlobalDTProductosServiciosEquivalencias(e.Row.DBCampo("CvePS").ToString.ToEntero, -1, UsuarioActual.CveEmpresa)
'SI UM NO ESTA REGISTRADA
If e.Row.DBCampo("CveUM").ToString.ToEntero <= 0 Then
@@ -10707,6 +10706,8 @@ Partial Class Compras_Compras
'EQUIVALENCIA
If e.Row.DBCampo("CveUM").ToString.ToEntero > 0 And e.Row.DBCampo("CveTipoPS").ToString.ToEntero = 2 Then
Dim DtEquivalencias As DataTable = GlobalDTProductosServiciosEquivalencias(e.Row.DBCampo("CvePS").ToString.ToEntero, e.Row.DBCampo("CveUM").ToString.ToEntero, UsuarioActual.CveEmpresa)
If DtEquivalencias.FiltraParametros($"CveUM = {e.Row.DBCampo("CveUM").ToString.ToEntero}").Rows.Count > 0 Then
If Not DtEquivalencias.FiltraParametros($"CveUM = {e.Row.DBCampo("CveUM").ToString.ToEntero} AND UnidadBase = 1").Rows.Count > 0 Then
'UM NO BASE
@@ -10724,6 +10725,7 @@ Partial Class Compras_Compras
e.Row.FCLabel("LtlUnidadMedida").Attributes.Add("data-toggle", "tooltip")
e.Row.FCLabel("LtlUnidadMedida").Attributes.Add("title", "Unidad de medida SIN equivalencia")
End If
DtEquivalencias.Dispose()
End If
End If

View File

@@ -382,6 +382,13 @@ Partial Class PopUpVerFactura
End If
End If
'Imprime Movimiento de IE
If UrlParametros("OP").ToString = "ImprimeMov" Then
If UrlParametros("CVEIE") IsNot Nothing AndAlso UrlParametros("CVEIE").ToString.ToEntero > 0 Then
ImprimeMov(UrlParametros("CVEIE").ToString.ToEntero)
End If
End If
'IMPRIME DEPOSITOS CAJA
If UrlParametros("OP").ToString = "DC" Then
If UrlParametros("CVEIE") IsNot Nothing AndAlso UrlParametros("CVEIE").ToString.ToEntero > 0 Then
@@ -3922,10 +3929,166 @@ Partial Class PopUpVerFactura
ObjIE.Dispose()
End Sub
End Sub
Private Sub ImprimeMov(CveIE As Integer)
Dim ObjIE As New ClsBancos()
Dim DtGvRH As New DataTable
Dim DtComprobacion As New DataTable
Dim ParamComprobacion As New DataTable
'Movimientos Relacionados de Comprobacion - Hijo
If ObjIE.GetBancosIEMovimientosHijo(CveIE, UsuarioActual.CveEmpresa) Then
DtGvRH = ObjIE.DtResultados
End If
If DtGvRH IsNot Nothing AndAlso DtGvRH.Rows.Count > 0 Then
If ObjIE.GetBancosIE(CveIE, UsuarioActual.CveEmpresa) Then
ParamComprobacion = ObjIE.DtResultados
End If
Dim ObjMov As New ClsMovimientos
For Each dr As DataRow In DtGvRH.Rows
If ObjMov.GetPersonalCajaChica(UsuarioActual.CveEmpresa, dr("CveCompra").ToString.ToEntero) Then
DtComprobacion.Merge(ObjMov.DtResultados.FiltraParametros("CveCompra =" + dr("CveCompra").ToString))
End If
Next
ObjMov.Dispose()
Dim Archivo As New System.IO.FileInfo(String.Format("{0}Formatos\Reembolso.rdlc", UsuarioActual.Empresa.Ruta))
Dim Imagen As New System.IO.FileInfo(String.Format("{0}Logo.png", UsuarioActual.Empresa.Ruta))
Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)
Dim params As New List(Of ReportParameter)
If Archivo.Exists Then
If UsuarioActual.CveEmpresa = 72 Then
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
params.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToString))
params.Add(New ReportParameter("CveCajaChica", DtComprobacion.Rows(0)("CveCajaChica").ToString))
params.Add(New ReportParameter("CveFyE", "0")) '
params.Add(New ReportParameter("cuentaRetiro", "Cuenta retiro: " & ParamComprobacion.Rows(0)("BancoNumCuentaMoneda").ToString))
params.Add(New ReportParameter("CajaChica", "Caja chica: " & ParamComprobacion.Rows(0)("BancoNumCuentaMoneda").ToString))
params.Add(New ReportParameter("observaciones", "Observaciones: " & ParamComprobacion.Rows(0)("Observaciones").ToString))
params.Add(New ReportParameter("folio", ParamComprobacion.Rows(0)("Folio").ToString))
params.Add(New ReportParameter("fecha", ParamComprobacion.Rows(0)("FechaDocumento").ToString))
params.Add(New ReportParameter("importe", ParamComprobacion.Rows(0)("Importe").ToString))
params.Add(New ReportParameter("TotAbono", DtComprobacion.SUM("Abonado").ToString))
ImprimirPDF(String.Format("{0}Formatos\Reembolso.rdlc", UsuarioActual.Empresa.Ruta), DtComprobacion, params, String.Format("IE{0}", CveIE), Formato:="PDF")
Else
params.Add(New ReportParameter("Numero", "")) '
params.Add(New ReportParameter("Anio", DtComprobacion.FiltraParametros("CveCompra > 0").MAX("Fecha").ToDate.Year.ToString))
params.Add(New ReportParameter("Nombre", DtComprobacion.MAX("SubProyecto")))
params.Add(New ReportParameter("Fecha", Now.Date.ToString))
params.Add(New ReportParameter("Elaboro", ""))
params.Add(New ReportParameter("Autorizo", ""))
params.Add(New ReportParameter("ElaboroPuesto", ""))
params.Add(New ReportParameter("AutorizoPuesto", ""))
ImprimirPDF(String.Format("{0}Formatos\Reembolso.rdlc", UsuarioActual.Empresa.Ruta), DtComprobacion.FiltraParametros("CveCompra > 0"), params, String.Format("IE{0}", CveIE), RDSName:="DsCompras")
End If
Else
params.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
params.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
params.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToString))
params.Add(New ReportParameter("cuentaRetiro", "Cuenta retiro: " & ParamComprobacion.Rows(0)("BancoNumCuentaMoneda").ToString))
params.Add(New ReportParameter("CajaChica", "Caja chica: " & ParamComprobacion.Rows(0)("BancoNumCuentaMoneda").ToString))
params.Add(New ReportParameter("observaciones", "Observaciones: " & ParamComprobacion.Rows(0)("Observaciones").ToString))
params.Add(New ReportParameter("folio", ParamComprobacion.Rows(0)("Folio").ToString))
params.Add(New ReportParameter("fecha", ParamComprobacion.Rows(0)("FechaDocumento").ToString))
params.Add(New ReportParameter("importe", ParamComprobacion.Rows(0)("Importe").ToString))
params.Add(New ReportParameter("TotAbono", DtComprobacion.SUM("Abonado").ToString))
If Imagen.Exists Then
params.Add(New ReportParameter("LogoPath", logouri))
Else
params.Add(New ReportParameter("LogoPath", ""))
End If
ImprimirPDF("Empresas/Grales/Formatos/RepRembolsosComprobaciones.rdlc", DtComprobacion, params, String.Format("IE{0}", CveIE), Formato:="PDF")
End If
Else
If ObjIE.GetBancosIE(CveIE, UsuarioActual.CveEmpresa) Then
If ObjIE.DtResultados.Rows.Count > 0 Then
Dim reportDataSetsList As New List(Of ReportDataSource)
Dim dtMovs As New DataTable
Dim Mov As New ClsContabilidad
If Mov.GetPrePolizasDetalle(-1, CveIE) Then
dtMovs = Mov.DtResultados.FiltraParametros("CveConceptoContable IN (17,2,312)")
If Not UsuarioActual.CveEmpresa.Contiene(13, 83) Then
'CONVIERTO A PESOS CUANDO SE PAGA CON PESOS FACTURAS DE DOLARES
For Each Dr As DataRow In dtMovs.Rows
Dr("Importe") = Dr("ImporteMN").ToString.ToDecimal
Dr("ImporteNC") = Dr("ImporteNC").ToString.ToDecimal * Dr("TC").ToString.ToDecimal
Dr("Total") = Dr("Total").ToString.ToDecimal * Dr("TC").ToString.ToDecimal
Dr("Saldo") = Dr("Saldo").ToString.ToDecimal * Dr("TC").ToString.ToDecimal
Next
End If
End If
Mov.Dispose()
Dim rds = New ReportDataSource("DataSet1", dtMovs)
reportDataSetsList.Add(rds)
Dim dtnc As New DataTable
Dim ObjCompra As New ClsCompras()
If ObjCompra.GetComprasNotasCredito(-1, -1, CveIE) Then
dtnc = ObjCompra.DtResultados
End If
ObjCompra.Dispose()
Dim rds2 = New ReportDataSource("DataSet2", dtnc)
reportDataSetsList.Add(rds2)
Dim paramList As New List(Of ReportParameter)
With paramList
'Dim Imagen As New System.IO.FileInfo(String.Format("{0}/Logo.png", UsuarioActual.Empresa.Ruta))
'Dim logouri = String.Format("{0}://{1}:{2}/Empresas/{3}/Logo.png", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, UsuarioActual.CveEmpresa)
Dim LogoRutaFisica As String = String.Format("Empresas\{0}\Logo.png", UsuarioActual.CveEmpresa)
Dim logouri = String.Format("{0}://{1}:{2}/ashx/sigfiles.ashx?P={3}", Request.Url.Scheme, Request.Url.Host, Request.Url.Port, Encripta(LogoRutaFisica))
Dim Imagen As New System.IO.FileInfo(String.Format("{0}Logo.png", UsuarioActual.Empresa.Ruta))
.Add(New ReportParameter("UsuarioImprimio", UsuarioActual.Nombre))
.Add(New ReportParameter("FechaImpresion", Now.ToDateTime.ToShortDateString))
.Add(New ReportParameter("NombreEmpresa", UsuarioActual.Empresa.Empresa))
.Add(New ReportParameter("Cuenta", ObjIE.NumCuenta, True))
.Add(New ReportParameter("Fecha", ObjIE.FechaDocumento.ToString("dd/MM/yyyy"), True))
.Add(New ReportParameter("Paguese", ObjIE.PagueseA.Trim, True))
.Add(New ReportParameter("Importe", ObjIE.Importe.ToString, True))
.Add(New ReportParameter("Observaciones", ObjIE.Observaciones, True))
.Add(New ReportParameter("Folio", ObjIE.Folio, True))
.Add(New ReportParameter("MonedaAbreviatura", ObjIE.MonedaAbreviatura, True))
If Imagen.Exists Then
.Add(New ReportParameter("LogoPath", logouri))
Else
.Add(New ReportParameter("LogoPath", ""))
End If
End With
ImprimirPDF("Empresas\Grales\Formatos\rptChequeMovimientos.rdlc", reportDataSetsList, paramList, "IE Movimient", "PDF")
End If
End If
End If
ObjIE.Dispose()
End Sub
#End Region
#Region "OP = RECIBO DE PAGOS"
Private Sub ImprimirReciboDePagos(CveIE As Integer, CveVenta As Integer)

View File

@@ -145,7 +145,7 @@ Partial Class Contratos_PopUpBuscarContrato
Dim objContratos As New ClsContratos
If (objContratos.GetContratosBusquedaRep(DdlTipo.SelectedValue.ToEntero, DdlTipoContrato.SelectedValue.ToEntero, NumeroContrato, Descripcion, Ubicacion, Responsable, Estatus,
DdlProyecto.SelectedValue.ToEntero, DdlSubProtecto.SelectedValue.ToEntero, UsuarioActual.Empresa.CveEmpresa, DdlCliente.SelectedValue.ToEntero,
DdlProveedor.SelectedValue.ToEntero)) Then
DdlProveedor.SelectedValue.ToEntero, TopSelect:=100)) Then
GV.DataSource = objContratos.DtResultados
LtlTotalRegistros.Text = objContratos.DtResultados.Rows.Count.ToString
Else

File diff suppressed because it is too large Load Diff

View File

@@ -339,7 +339,7 @@
<RepeatColumnHeaders>true</RepeatColumnHeaders>
<FixedColumnHeaders>true</FixedColumnHeaders>
<DataSetName>DataSet1</DataSetName>
<Top>1.94937cm</Top>
<Top>2.58437cm</Top>
<Height>1.09417cm</Height>
<Width>19.82496cm</Width>
<Style>
@@ -430,7 +430,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>1.34937cm</Top>
<Top>1.98437cm</Top>
<Height>0.52945cm</Height>
<Width>561.96737pt</Width>
<ZIndex>2</ZIndex>
@@ -781,7 +781,7 @@
<RepeatColumnHeaders>true</RepeatColumnHeaders>
<FixedColumnHeaders>true</FixedColumnHeaders>
<DataSetName>DataSet2</DataSetName>
<Top>4.17187cm</Top>
<Top>4.80687cm</Top>
<Height>1.09417cm</Height>
<Width>19.82496cm</Width>
<ZIndex>3</ZIndex>
@@ -825,7 +825,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>3.57187cm</Top>
<Top>4.20687cm</Top>
<Height>0.52945cm</Height>
<Width>561.96737pt</Width>
<ZIndex>4</ZIndex>
@@ -1176,7 +1176,7 @@
<RepeatColumnHeaders>true</RepeatColumnHeaders>
<FixedColumnHeaders>true</FixedColumnHeaders>
<DataSetName>DataSet3</DataSetName>
<Top>6.42083cm</Top>
<Top>7.05583cm</Top>
<Height>1.12063cm</Height>
<Width>19.82496cm</Width>
<ZIndex>5</ZIndex>
@@ -1220,7 +1220,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>5.82083cm</Top>
<Top>6.45583cm</Top>
<Height>0.52945cm</Height>
<Width>561.96737pt</Width>
<ZIndex>6</ZIndex>
@@ -1571,7 +1571,7 @@
<RepeatColumnHeaders>true</RepeatColumnHeaders>
<FixedColumnHeaders>true</FixedColumnHeaders>
<DataSetName>DataSet4</DataSetName>
<Top>8.56395cm</Top>
<Top>9.19895cm</Top>
<Height>1.12063cm</Height>
<Width>19.82496cm</Width>
<ZIndex>7</ZIndex>
@@ -1615,7 +1615,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>7.96395cm</Top>
<Top>8.59895cm</Top>
<Height>0.52945cm</Height>
<Width>561.96737pt</Width>
<ZIndex>8</ZIndex>
@@ -1663,7 +1663,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.21319cm</Top>
<Top>10.84819cm</Top>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>9</ZIndex>
@@ -1711,7 +1711,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.63681cm</Top>
<Top>11.27181cm</Top>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>10</ZIndex>
@@ -1766,7 +1766,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.21319cm</Top>
<Top>10.84819cm</Top>
<Left>16.83317cm</Left>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
@@ -1815,7 +1815,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>10.63681cm</Top>
<Top>11.27181cm</Top>
<Left>16.83317cm</Left>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
@@ -1913,7 +1913,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>12.33483cm</Top>
<Top>12.96983cm</Top>
<Left>16.83317cm</Left>
<Height>0.52945cm</Height>
<Width>84.80665pt</Width>
@@ -1933,30 +1933,6 @@
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value> LCP Jesus Nazareth Peralta Ortíz</Value>
<MarkupType>HTML</MarkupType>
<Style />
</TextRun>
<TextRun>
<Value>____________</Value>
<MarkupType>HTML</MarkupType>
<Style>
<Color>White</Color>
</Style>
</TextRun>
<TextRun>
<Value>CP Benjamin Carrillo Cota</Value>
<MarkupType>HTML</MarkupType>
<Style />
</TextRun>
<TextRun>
<Value>______________</Value>
<MarkupType>HTML</MarkupType>
<Style>
<Color>White</Color>
</Style>
</TextRun>
<TextRun>
<Value>CP Sara Eduwiges Ruíz Félix</Value>
<MarkupType>HTML</MarkupType>
@@ -1969,9 +1945,10 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>16.31254cm</Top>
<Top>16.94754cm</Top>
<Left>14.51918cm</Left>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<Width>139.98364pt</Width>
<ZIndex>15</ZIndex>
<Style>
<Border>
@@ -2038,7 +2015,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>15.6424cm</Top>
<Top>16.2774cm</Top>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<ZIndex>16</ZIndex>
@@ -2094,7 +2071,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>13.12403cm</Top>
<Top>13.75903cm</Top>
<Height>0.6cm</Height>
<Width>561.96737pt</Width>
<ZIndex>17</ZIndex>
@@ -2163,7 +2140,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>AgrupadoPor</rd:DefaultName>
<Top>13.90042cm</Top>
<Top>14.53542cm</Top>
<Height>1.25264cm</Height>
<Width>561.96737pt</Width>
<ZIndex>18</ZIndex>
@@ -2211,7 +2188,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.06042cm</Top>
<Top>11.69542cm</Top>
<Height>0.42362cm</Height>
<Width>477.16077pt</Width>
<ZIndex>19</ZIndex>
@@ -2262,7 +2239,7 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox2</rd:DefaultName>
<Top>11.06042cm</Top>
<Top>11.69542cm</Top>
<Left>16.83317cm</Left>
<Height>0.42362cm</Height>
<Width>84.80665pt</Width>
@@ -2280,11 +2257,110 @@
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Filtros">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>=Parameters!Filtros.Value</Value>
<MarkupType>HTML</MarkupType>
<Style>
<FontSize>9pt</FontSize>
</Style>
</TextRun>
</TextRuns>
<Style />
</Paragraph>
</Paragraphs>
<rd:DefaultName>Filtros</rd:DefaultName>
<Top>1.20798cm</Top>
<Left>0.06614cm</Left>
<Height>0.6cm</Height>
<Width>19.75882cm</Width>
<ZIndex>21</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox47">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>CP. Daniel Hernández Tapia</Value>
<MarkupType>HTML</MarkupType>
<Style />
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox47</rd:DefaultName>
<Top>16.94754cm</Top>
<Left>0.47837cm</Left>
<Height>0.6cm</Height>
<Width>5.38396cm</Width>
<ZIndex>22</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
<Textbox Name="Textbox48">
<CanGrow>true</CanGrow>
<KeepTogether>true</KeepTogether>
<Paragraphs>
<Paragraph>
<TextRuns>
<TextRun>
<Value>CP Benjamin Carrillo Cota</Value>
<MarkupType>HTML</MarkupType>
<Style />
</TextRun>
</TextRuns>
<Style>
<TextAlign>Left</TextAlign>
</Style>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox48</rd:DefaultName>
<Top>16.94754cm</Top>
<Left>7.96078cm</Left>
<Height>0.6cm</Height>
<Width>4.88125cm</Width>
<ZIndex>23</ZIndex>
<Style>
<Border>
<Style>None</Style>
</Border>
<PaddingLeft>2pt</PaddingLeft>
<PaddingRight>2pt</PaddingRight>
<PaddingTop>2pt</PaddingTop>
<PaddingBottom>2pt</PaddingBottom>
</Style>
</Textbox>
</ReportItems>
<Height>6.6828in</Height>
<Height>6.95328in</Height>
<Style />
</Body>
<Width>7.81552in</Width>
<Width>7.8051in</Width>
<Page>
<PageHeader>
<Height>2.88508cm</Height>
@@ -2824,6 +2900,12 @@
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
<ReportParameter Name="Filtros">
<DataType>String</DataType>
<Nullable>true</Nullable>
<AllowBlank>true</AllowBlank>
<Prompt>ReportParameter1</Prompt>
</ReportParameter>
</ReportParameters>
<rd:ReportUnitType>Cm</rd:ReportUnitType>
<rd:ReportID>40c94aad-a12a-44fb-ab0d-ea36a9656792</rd:ReportID>

View File

@@ -92,14 +92,14 @@ public partial class General_PopUpPaqueteriasGuiasInternas : ClsPaginas
String Observaciones = TxtObservaciones.Text;
int CvePaqueteriaGuia = ObjGeneral.AddPaqueteriasGuias(-1, -1, CveEstatus, CveSubProyecto, Fecha, "-1", "-1", NoCajas, 0.00, "-1", FechaEstimada, Observaciones,
int CvePaqueteriaGuia = ObjGeneral.AddPaqueteriasGuias(-1, 9, CveEstatus, CveSubProyecto, Fecha, "-1", "-1", NoCajas, 0.00, "-1", FechaEstimada, Observaciones,
UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, EsEntregaInterna:true);
if (CvePaqueteriaGuia > 0)
{
if (CveVenta > 0 || CveSubProyecto > 0 )
{
TieneError = !ObjGeneral.AddPaqueteriasGuiasDetalles(CvePaqueteriaGuia, CveVenta, -1, CveSubProyecto, -1);
TieneError = !ObjGeneral.AddPaqueteriasGuiasDetalles(CvePaqueteriaGuia, CveVenta, -1, -1, -1);
}
}
else

View File

@@ -235,7 +235,7 @@ public partial class General_RepPaqueteriasGuias : ClsPaginas
{
DdlUsuarios.DataSource = get_GlobalDTUsuarios(CveEmpresa:UsuarioActual.CveEmpresa);
DdlUsuarios.DataBind();
DdlUsuarios.Items.Insert(0, new ListItem("Seleccione ", "-1"));
DdlUsuarios.Items.Insert(0, new ListItem("Todos ", "-1"));
}
protected void InicializaFechas()

View File

@@ -2231,7 +2231,7 @@ Partial Class Inventarios_EntradasSalidas
GvM.Columns(9).Visible = DtTemp.MAX("Serie") <> ""
GvM.Columns(10).Visible = DtTemp.MAX("Lote") <> ""
GvM.Columns(11).Visible = DtTemp.MAX("FechaCaducidad").ToDate > MinFecha
GvM.Columns(12).Visible = DtTemp.MAX("CveSeccionAlmacen") <> ""
GvM.Columns(12).Visible = DtTemp.MAX("CveSeccionAlmacen").ToEntero > 0
End If

View File

@@ -65,11 +65,15 @@
<ul class="list-inline">
<li>Cliente:
<ADS:Dropdownlost ID="DdlClientes" CssClassDdl="select2me" runat="server" CssStyle="width: 350px;" DataTextField="NombreComercial" Onselectedindexchange="DdlCliente_SelectedIndexChanged" DataValueField="CveCliente"></ADS:Dropdownlost>
<%--<asp:DropDownList ID="DdlClientes" runat="server" DataValueField="CveCliente" DataTextField="Nombre" OnSelectedIndexChanged="DdlCliente_SelectedIndexChanged" AutoPostBack="true" CssClass="form-control input-sm select2me" Width="350px"></asp:DropDownList>--%>
</li>
<li>Serie-Folio:
<asp:DropDownList ID="DdlFolio" runat="server" DataValueField="CveVenta" DataTextField="SerieFolio" CssClass="form-control input-sm select2me" Width="250px"></asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVFolio" runat="server" ControlToValidate="DdlFolio" InitialValue="-1" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Folio''</b> es necesario, por favor ingréselo." ValidationGroup="GrpBuscar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEFolio" runat="server" HighlightCssClass="vco" TargetControlID="RFVFolio" Width="300px"></ajax:ValidatorCalloutExtender>
@@ -238,11 +242,13 @@
</tr>
<tr>
<td colspan="2">
<div style="display:none;">
<asp:RadioButton id="RbSinEntrega" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="33%" GroupName="EntregaRadioGroup" Text="Sin Entrega" AutoPostBack="true"></asp:RadioButton>
<asp:RadioButton id="RbEntregaInterna" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="33%" GroupName="EntregaRadioGroup" Text="Entrega Interna" AutoPostBack="true"></asp:RadioButton>
<asp:RadioButton id="RbEntregaExterna" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="33%" GroupName="EntregaRadioGroup" Text="Entrega Externa" AutoPostBack="true"></asp:RadioButton>
</div>
<asp:Panel ID="PnlEntrega" runat="server" Visible="false">
<asp:RadioButton id="RbSinEntrega" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="25%" GroupName="EntregaRadioGroup" Text="Sin Entrega" AutoPostBack="true"></asp:RadioButton>
<asp:RadioButton id="RbEntregaInterna" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="25%" GroupName="EntregaRadioGroup" Text="Entrega Interna" AutoPostBack="true"></asp:RadioButton>
<asp:RadioButton id="RbEntregaExterna" runat="server" OnCheckedChanged="EntregaRadioGroup_Click" Width="25%" GroupName="EntregaRadioGroup" Text="Entrega Externa" AutoPostBack="true"></asp:RadioButton>
</asp:Panel>
</td>
</tr>
@@ -281,6 +287,8 @@
</code>
&nbsp;
<b>Sucursal:</b>
<asp:DropDownList ID="DdlSubProyectos" runat="server" CssClass="form-control input-sm select2me" DataTextField="SubProyecto" DataValueField="CveSubProyecto" Width="90px"></asp:DropDownList>
@@ -810,6 +818,96 @@
</asp:UpdatePanel>
</div>
<div id="ModalPaqueteriaInterna" class="modal ADS fade" role="dialog">
<asp:UpdatePanel ID="UpPaqInterna" class="modal-dialog rowpadding" tabindex="-1" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="modal-content">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal">&times;</button>
<h4 class="modal-title">Paqueterías Interna</h4>
</div>
<div class="modal-body">
<table class="Widthall">
<tr runat="server" id="RowPaqueteria" align="left" visible="true">
<td class="text-right"><b>Estatus:</b></td>
<td>
<asp:DropDownList ID="DdlEstatus" runat="server" Class="table-group-action-input form-control input-inline input-sm select2me" Width="200px">
<%-- <asp:ListItem Selected="False" Text="Seleccione" Value="-1"></asp:ListItem>--%>
<asp:ListItem Selected="True" Text="En Proceso" Value="1"></asp:ListItem>
<asp:ListItem Selected="False" Text="Confirmado por Proveedor" Value="2"></asp:ListItem>
<asp:ListItem Selected="False" Text="Entregado" Value="3"></asp:ListItem>
<asp:ListItem Selected="False" Text="Confirmado por Cliente" Value="4"></asp:ListItem>
</asp:DropDownList>
<%-- <asp:RequiredFieldValidator ID="RFVDdlEstatus" runat="server" ControlToValidate="DdlEstatus" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Estatus''</b> es necesario." InitialValue="-1" ValidationGroup="GrpCrearGuia"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEDdlEstatus" runat="server" HighlightCssClass="vco" TargetControlID="RFVDdlEstatus" Width="250px"></ajax:ValidatorCalloutExtender>--%>
</td>
</tr>
<tr runat="server" id="RowRastreo" align="left" visible="true">
<td class="text-right" style="width: 140px"><b>Fecha:</b></td>
<td style="width: 200px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 117px !important; padding: 0px;">
<asp:TextBox ID="TxtFechaPaqInterna" runat="server" CssClass="form-control" Width="170px" Height="30px" Style="padding: 0px" CausesValidation="true" MaxLength="10"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="LnkFechaInterna" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server" Width="30px"></asp:LinkButton>
</span>
<ajax:MaskedEditExtender ID="MeFechaPaqInterna" runat="server" TargetControlID="TxtFechaPaqInterna" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CalendarExtender1" TargetControlID="TxtFechaPaqInterna" PopupButtonID="LnkFechaInterna" PopupPosition="BottomRight" Enabled="True"></ajax:CalendarExtender>
<asp:RequiredFieldValidator ID="RfvFechaPaqInterna" runat="server" ControlToValidate="TxtFechaPaqInterna" Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha''</b> es necesario." ValidationGroup="GrpCrearGuia"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEFecha" runat="server" HighlightCssClass="vco" TargetControlID="RfvFechaPaqInterna" Width="250px"></ajax:ValidatorCalloutExtender>
</div>
</td>
</tr>
<tr runat="server" id="RowFechas" align="left" visible="true">
<td class="text-right" style="width: 140px;"><b>Fecha Estimada:</b></td>
<td style="width: 200px">
<div class="input-group input-sm input-small date date-picker " data-date-format="dd/mm/yyyy" style="width: 117px !important; padding: 0px;">
<asp:TextBox ID="TxtFechaEstimada" runat="server" CssClass="form-control" Width="170px" Height="30px" Style="padding: 0px"></asp:TextBox>
<span class="input-group-btn ">
<asp:LinkButton ID="LnkFechaEstimada" class="btn default " Text="<i class='fa fa-calendar'></i>" runat="server" Width="30px"></asp:LinkButton>
</span>
<ajax:MaskedEditExtender ID="MEEFechaEstimada" runat="server" TargetControlID="TxtFechaEstimada" Mask="99/99/9999" MaskType="Date" DisplayMoney="Left" AcceptNegative="Left"></ajax:MaskedEditExtender>
<ajax:CalendarExtender runat="server" ID="CEFechaEstimada" TargetControlID="TxtFechaEstimada" PopupButtonID="LnkFechaEstimada" PopupPosition="BottomLeft" Enabled="True"></ajax:CalendarExtender>
</div>
</td>
</tr>
<tr runat="server" id="RowDimensiones" align="left" visible="true">
<td class="text-right" style="width: 140px"><b># Cajas:</b></td>
<td style="width: 200px">
<asp:TextBox ID="TxtNoCajas" runat="server" CssClass="form-control" Width="200px" Height="30px" Style="padding: 0px"></asp:TextBox>
</td>
</tr>
<tr runat="server" id="RowCajas" align="left" visible="true">
<td class="text-right" align="left" valign="top" style="width: 140px; padding-top: 4px;"><b>Observaciones:</b></td>
<td style="width: 200px;">
<asp:TextBox ID="TxtObservacionesPaqInterna" runat="server" CssClass="form-control MultiLineTextBox" Width="200px" Height="60px" Style="padding: 0px" TextMode="MultiLine"></asp:TextBox>
</td>
</tr>
<tr></tr>
</table>
</div>
<div class="modal-footer">
<asp:Button ID="BtnGuiaInterna" runat="server" ClientIDMode="Static" Text="Aplicar" data-dismiss="modal" CssClass="btn btn-primary" />
<button id="BtnCancelarGuiaInterna" type="button" class="btn btn-default" data-dismiss="modal">Cerrar</button>
</div>
</div>
</ContentTemplate>
</asp:UpdatePanel>
</div>
</asp:Content>
<asp:Content ID="Content7" ContentPlaceHolderID="JS" runat="Server">
<script src="/Metronic/assets/global/plugins/jquery.pulsate.min.js"></script>

View File

@@ -2,16 +2,14 @@
Option Explicit On
Imports System.Data
Imports System.IO
Imports System.Linq
Imports CrystalDecisions.[Shared].Json
Imports System.IO
Imports Extensiones
Imports Microsoft.Reporting.WebForms
Partial Class Inventarios_EntregaAlmacen
Inherits ClsPaginas
Inherits ClsPaginas
#Region "PROPIEDADES"
Private Property CveVentaAD As Integer
Get
@@ -245,10 +243,10 @@ Partial Class Inventarios_EntregaAlmacen
Set(value As Boolean)
ViewState("EsDevolucionDirecta") = value
End Set
End Property
End Property
#End Region
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
@@ -256,9 +254,9 @@ Partial Class Inventarios_EntregaAlmacen
CargaParametrosAD()
If UsuarioActual.CveEmpresa.Contiene(72, 80) Then DdlAlmacen.AutoPostBack = True
End If
End Sub
End Sub
#Region " INICIALIZA VALORES "
Private Sub InicializaValores()
TipoEstatus = -1
@@ -318,18 +316,19 @@ Partial Class Inventarios_EntregaAlmacen
DdlSubProyectos.SelectedValueExist(UsuarioActual.CveSubProyecto.ToString)
If UsuarioActual.TienePermisoProceso(152) Then DdlSubProyectos.Enabled = False
If UsuarioActual.Empresa.Funcionalidad(280) = "1" Then PnlEntrega.Visible = True
CreaDtDetalle()
CreaDtDetalleLote()
CargaPendientes()
End Sub
LimpiaCampos()
End Sub
#End Region
#Region " CARGA PARAMETROS - EXCLUSIVO USO AD "
Private Sub CargaParametrosAD()
@@ -347,9 +346,9 @@ Partial Class Inventarios_EntregaAlmacen
BtnGuardar.Visible = False
End If
End Sub
End Sub
#End Region
#Region " CARGA PENDIENTES POR SURTIR "
Protected Sub DdlCliente_SelectedIndexChanged(sender As Object, e As EventArgs)
CargaFolios()
@@ -467,11 +466,11 @@ Partial Class Inventarios_EntregaAlmacen
End Select
UpPendientes.Update()
End If
End Sub
End Sub
#End Region
#Region " CARGA VENTA POR SURTIR "
Protected Sub BtnSurtir_Click(sender As Object, e As EventArgs)
@@ -917,14 +916,14 @@ Partial Class Inventarios_EntregaAlmacen
End If
objInv.Dispose()
GvDocs.DataBind()
End Sub
End Sub
#End Region
#Region " AGREGAR "
Protected Sub BtnSerie_Click(sender As Object, e As EventArgs)
Dim Argumentos = CType(sender, Button).CommandArgument.Split("°"c)
@@ -951,10 +950,10 @@ Partial Class Inventarios_EntregaAlmacen
UpLoteBatch.Update()
End If
End Sub
End Sub
#Region " AGREGA POR SERIE/LOTE "
Private Sub CreaDtDetalle()
If DtDatosDetalle Is Nothing Then
DtDatosDetalle = New DataTable
@@ -1159,11 +1158,11 @@ Partial Class Inventarios_EntregaAlmacen
DtDatosDetalle.AcceptChanges()
CargaSerie()
End Sub
End Sub
#End Region
#Region " AGREGA CON LOTE BATCH "
Private Sub CreaDtDetalleLote()
If DtDatosDetalleLote Is Nothing Then
DtDatosDetalleLote = New DataTable
@@ -1351,9 +1350,9 @@ Partial Class Inventarios_EntregaAlmacen
End Try
DtDatosDetalleLote.AcceptChanges()
CargaLote()
End Sub
End Sub
#End Region
#Region " AGREGA CON TXT | CODIGO - SERIE "
Protected Sub BtnCodigoPS_Click(sender As Object, e As EventArgs)
@@ -1487,12 +1486,12 @@ Partial Class Inventarios_EntregaAlmacen
End If
TxtCantidadEspecialDiv.Text = "1"
End Sub
End Sub
#End Region
#End Region
#Region " GUARDAR "
Protected Sub BtnGuardar_Click(sender As Object, e As EventArgs)
@@ -1594,6 +1593,7 @@ Partial Class Inventarios_EntregaAlmacen
Dim ObjVentas As New ClsVentas(ObjInventario.IniciaTransacSQL())
Dim ObjEventos As New ClsOIEventos(ObjInventario.IniciaTransacSQL())
Dim ObjAcumuladores As New ClsAcumuladores(ObjInventario.IniciaTransacSQL())
Dim ObjGeneral As New ClsGenerales(ObjInventario.IniciaTransacSQL())
Dim CveMovimiento As Integer
Dim Folio As Integer
Dim ErrorMovInv As Boolean
@@ -2414,8 +2414,40 @@ Partial Class Inventarios_EntregaAlmacen
OnError("Ocurrió un error al guardar", ex)
End Try
'Paqueterias guias
If RbEntregaInterna.Checked AndAlso Not ErrorMovInv Then
Dim CveEstatus As Integer = DdlEstatus.SelectedValue.ToEntero()
Dim Fecha As String = TxtFechaPaqInterna.Text
Dim FechaEstimada As String = If(TxtFechaEstimada.Text = "", "-1", TxtFechaEstimada.Text)
Dim NoCajas As Integer = TxtNoCajas.Text.ToEntero()
Dim Observaciones As String = TxtObservacionesPaqInterna.Text
Dim CvePaqueteria As Integer = GlobalDTPaqueterias().FiltroPrimeroValor("CvePaqueteria", String.Format("CveEmpresa={0} AND TipoPaqueteria = 0", UsuarioActual.CveEmpresa)).ToEntero
Dim CvePaqueteriaGuia As Integer = ObjGeneral.AddPaqueteriasGuias(CvePaqueteria, 9, CveEstatus, CveSubProyecto, Fecha, "", "", NoCajas, 0.00, "-1", FechaEstimada, Observaciones, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, EsEntregaInterna:=True)
If CvePaqueteriaGuia > 0 Then
If CveVentaSurtir > 0 OrElse CveSubProyecto > 0 Then
If ObjGeneral.AddPaqueteriasGuiasDetalles(CvePaqueteriaGuia, CveVentaSurtir, -1, CveMovimiento, -1) Then
''manda correo
MandaCorreoEntrega(CveVentaSurtir)
Else
ErrorMovInv = True
End If
End If
If ErrorMovInv Then
Alert("Error en el paqueteria guia detalle", TipoMensaje.MsgError)
End If
Else
ErrorMovInv = True
Alert("Error en el paqueteria guia", TipoMensaje.MsgError)
End If
End If
If Not ErrorMovInv Then
ObjInventario.Commit()
ObjGeneral.Dispose()
RegistraScript("playsonidito('beep-07.wav')")
Dim Msg As New StringBuilder
@@ -2445,10 +2477,15 @@ Partial Class Inventarios_EntregaAlmacen
Msg.AppendFormat("<br/><a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={0}"">Imprimir Movimiento</a> ", Encripta(String.Format("OP=Alm&CveMovimiento={0}", CveMovimientoVirtual)))
End If
If RbEntregaInterna.Checked Then
Msg.AppendFormat("<br/><br/>Se agregó una guía de paquetería interna")
End If
Alert(Msg.ToString, TipoMensaje.MsgInformacion)
Limpia()
CargaPendientes()
LimpiaCampos()
Else
ObjInventario.RollBack()
Alert(TextoError.ToString, TipoMensaje.MsgError)
@@ -2492,6 +2529,7 @@ Partial Class Inventarios_EntregaAlmacen
End If
Dim ObjInventario As New ClsInventarios : ObjInventario.IniciaTransacSQL()
Dim ObjGeneral As New ClsGenerales(ObjInventario.IniciaTransacSQL())
Dim CveMovimientoSalida As Integer
Dim ConceptoMovimiento = 0
Dim FolioSalida As Integer
@@ -2668,9 +2706,32 @@ Partial Class Inventarios_EntregaAlmacen
End If
End If
'Paqueterias Guias
If RbEntregaInterna.Checked AndAlso Not ErrorMovInv Then
Dim CveEstatus As Integer = DdlEstatus.SelectedValue.ToEntero()
Dim Fecha As String = TxtFechaPaqInterna.Text
Dim FechaEstimada As String = If(TxtFechaEstimada.Text = "", "-1", TxtFechaEstimada.Text)
Dim NoCajas As Integer = TxtNoCajas.Text.ToEntero()
Dim Observaciones As String = TxtObservacionesPaqInterna.Text
Dim CvePaqueteriaGuia As Integer = ObjGeneral.AddPaqueteriasGuias(-1, -1, CveEstatus, CveSubProyecto, Fecha, "-1", "-1", NoCajas, 0.00, "-1", FechaEstimada, Observaciones, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, EsEntregaInterna:=True)
If CvePaqueteriaGuia > 0 Then
If CveVentaSurtir > 0 OrElse CveSubProyecto > 0 Then
ErrorMovInv = Not ObjGeneral.AddPaqueteriasGuiasDetalles(CvePaqueteriaGuia, CveVentaSurtir, -1, CveMovimiento, -1)
End If
If ErrorMovInv Then
Alert("Error en el paqueteria guia detalle", TipoMensaje.MsgError)
End If
Else
ErrorMovInv = True
Alert("Error en el paqueteria guia", TipoMensaje.MsgError)
End If
End If
If Not ErrorMovInv Then
ObjInventario.Commit()
ObjGeneral.Dispose()
RegistraScript("playsonidito('beep-07.wav')")
Dim Msg As New StringBuilder
@@ -2680,9 +2741,14 @@ Partial Class Inventarios_EntregaAlmacen
Msg.AppendFormat("<br/><br/> Movimiento Entrada (Traspaso): <b><a href=""/Inventarios/EntradasSalidas.aspx?CveMovimiento={0}"" target=""_blank"">{1}</a></b>", CveMovimientoEntrada, FolioEntrada)
Msg.AppendFormat("<br/> <a class=""Texto"" target='_blank' href=""/Compras/PopUpVerFactura.aspx?P={0}"">Imprimir Movimiento</a> ", Encripta(String.Format("OP=Alm&CveMovimiento={0}", CveMovimientoEntrada)))
If RbEntregaInterna.Checked Then
Msg.AppendFormat("<br/><br/>Se agregó una guía de paquetería interna")
End If
Alert(Msg.ToString, TipoMensaje.MsgInformacion)
Limpia()
LimpiaCampos()
CargaPendientes()
Else
Alert(TextoError, TipoMensaje.MsgError)
@@ -2694,6 +2760,53 @@ Partial Class Inventarios_EntregaAlmacen
End Sub
Private Sub MandaCorreoEntrega(tCveVenta As Integer)
Dim Correo As New ClsSisMail()
Dim SerieFolio As String = ""
Dim Asunto As String = String.Format("{0} Envio de pedido: {1}", UsuarioActual.Empresa.NombreCorto, SerieFolio)
Dim Cuerpo As New StringBuilder()
Dim Destinatario As String = ""
Dim MensajeEnviado = False
Dim tCvecliente As Integer
Dim ObjVentas As New ClsVentas()
If (ObjVentas.GetVenta(tCveVenta, UsuarioActual.CveEmpresa)) Then
Dim dr As DataRow = ObjVentas.DtResultados.FiltroPrimero("")
Destinatario = String.Format("{0};{1}", dr("CorreoNotificacion"), dr("CorreoVendedorVenta"))
tCvecliente = dr("CveCliente").ToString.ToEntero
Dim drC As DataRow = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=tCvecliente).FiltroPrimero("")
Destinatario += String.Format("{0};{1}", drC("CorreoEntregaCompras"), drC("CorreoEntregaAlmacen"))
Cuerpo.AppendLine(String.Format("Estimado {0} le informamos que los productos de la factura {1} han sido enviados a entrega. <br><br>", dr("ClienteNombre"), dr("SerieFolio")))
Cuerpo.AppendLine("<br><br>Dudas y aclaraciones con su coordinador empresarial.")
End If
ObjVentas.Dispose()
' Dim ArchivoAdjunto As New ClsSisMail.ArchivoMail()
'Dim ListaAdjuntos As New List(ClsSisMail.ArchivoMail)
'If (File.Exists(RutaArchivoAdjunto))Then
' {
' ArchivoAdjunto.ArchivoBinario = File.ReadAllBytes(RutaArchivoAdjunto);
' ArchivoAdjunto.Ruta = RutaArchivoAdjunto;
' ArchivoAdjunto.NombreArchivo = new FileInfo(RutaArchivoAdjunto).Name;
' ListaAdjuntos.Add(ArchivoAdjunto);
' }
MensajeEnviado = Correo.SendMail(UsuarioActual.Empresa, Destinatario, Asunto, Cuerpo.ToString())
End Sub
Private Sub Limpia()
'DATOS DE LA VENTA
@@ -2990,7 +3103,7 @@ Partial Class Inventarios_EntregaAlmacen
If fi.Exists() Then
linkDescarga = $"/Empresas/{UsuarioActual.CveEmpresa}/Documentacion/ventas/{fi.Name}"
ImgDownLoad.Visible = True
ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black' ><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga)
ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black'><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga)
End If
@@ -3113,11 +3226,22 @@ Partial Class Inventarios_EntregaAlmacen
If RbEntregaExterna.Checked Then
RegistraScript("AbrirVentana('/General/PopUpPaqueteriasGuias.aspx',800,547,'N')")
ElseIf RbEntregaInterna.Checked Then
RegistraScript($"AbrirVentana('/General/PopUpPaqueteriasGuiasInternas.aspx?CveVenta={CveVentaSurtir}&CveSubProyecto={CveSubProyecto}',800,547,'N')")
RegistraScript("$('#ModalPaqueteriaInterna').modal('show')")
'RegistraScript($"AbrirVentana('/General/PopUpPaqueteriasGuiasInternas.aspx?CveVenta={CveVentaSurtir}&CveSubProyecto={CveSubProyecto}',800,547,'N')")
'CveVentaSurtir
ElseIf RbSinEntrega.Checked Then
LimpiaCampos()
End If
End Sub
Protected Sub LimpiaCampos()
DdlEstatus.SelectedValue = "1"
TxtFechaPaqInterna.Text = ""
TxtFechaEstimada.Text = ""
TxtNoCajas.Text = ""
TxtObservacionesPaqInterna.Text = ""
UpPaqInterna.Update()
End Sub
#End Region

View File

@@ -15,11 +15,25 @@
</style>
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="E" runat="Server">
<%--Paqueterías Guías--%>Entrega Interna
Entregas por Realizar
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="HB" runat="Server">
<li>
<asp:LinkButton ID="LnkImprimir" runat="server" OnClick="LnkImprimir_Click"> <i class="fa fa-file-pdf-o" style="font-weight:bold;"></i> PDF</asp:LinkButton>
</li>
</asp:Content>
<asp:Content ID="Content5" ContentPlaceHolderID="H" runat="Server">
<asp:UpdatePanel runat="server" ID="UpAccionesComplementos">
<ContentTemplate>
<li>
<asp:LinkButton ID="LnkImprimir" runat="server" OnClick="LnkImprimir_Click" Style="color: #686868;" Text="<i class='fa fa-pdf' style='color:#686868;'></i> Imprimir"/>
</li>
</ContentTemplate>
<Triggers>
<asp:PostBackTrigger ControlID="LnkImprimir"/>
</Triggers>
</asp:UpdatePanel>
</asp:Content>
<asp:Content ID="Content6" ContentPlaceHolderID="HA" runat="Server">
</asp:Content>
@@ -70,9 +84,10 @@
&nbsp;<asp:CheckBox ID="ChkAsigna" runat="server" Checked="false" />
</ItemTemplate>
</asp:TemplateField>
<asp:BoundField HeaderText="Cons" DataField="Num" HeaderStyle-Width="25px" ItemStyle-HorizontalAlign="Center" />
<asp:TemplateField HeaderText="Folio" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="10%" HeaderStyle-Width="10%">
<ItemTemplate>
&nbsp;<asp:Literal ID="LblFolio" runat="server" Text='<%# Eval("Folio") %>'></asp:Literal>
&nbsp;<asp:Literal ID="LblFolio" runat="server" Text='<%# Eval("SerieFolio") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>

View File

@@ -6,9 +6,22 @@ using System.Web.UI;
using System.Web.UI.WebControls;
using System.Data;
using Extensiones;
using Microsoft.Reporting.WebForms;
public partial class Inventarios_EntregasPorRealizar : ClsPaginas
{
private DataTable DtPaqueteriasGuias
{
get
{
return (ViewState["DtPaqueteriasGuias"] == null) ? null : (DataTable)ViewState["DtPaqueteriasGuias"];
}
set
{
ViewState["DtPaqueteriasGuias"] = value;
}
}
protected void Page_Load(object sender, EventArgs e)
{
if (!IsPostBack)
@@ -65,6 +78,7 @@ public partial class Inventarios_EntregasPorRealizar : ClsPaginas
if (ObjGeneral.GetEntregasPorRealizar(UsuarioActual.CveEmpresa))
{
GvPaqueteriasGuias.DataSource = ObjGeneral.DtResultados;
DtPaqueteriasGuias = ObjGeneral.DtResultados;
GvPaqueteriasGuias.DataBind();
}
ObjGeneral.Dispose();
@@ -76,4 +90,15 @@ public partial class Inventarios_EntregasPorRealizar : ClsPaginas
DdlUsuario.DataBind();
DdlUsuario.Items.Insert(0, new ListItem("Seleccione", "-1"));
}
protected void LnkImprimir_Click(object sender, EventArgs e)
{
List<ReportParameter> RepParams = new List<ReportParameter>();
string Usuario = DdlUsuario.SelectedValue.ToEntero() > 0 ? DdlUsuario.SelectedItem.Text : "Todos";
RepParams.Add(new ReportParameter("Fecha", DateTime.Today.ToString()));
RepParams.Add(new ReportParameter("AsignadoA", Usuario));
RepParams.Add(new ReportParameter("UsuarioImprimio", UsuarioActual.Nombre));
ImprimirPDF($"Empresas/{UsuarioActual.CveEmpresa}/Formatos/EntregasPorRealizar.rdlc", DtPaqueteriasGuias, RepParams, "Entregas por realizar", "PDF",RDSName:"DsInventarios");
}
}

View File

@@ -713,8 +713,8 @@ Partial Class Inventarios_PaquetesArmadoDesarmado
If e.Row.RowType = DataControlRowType.DataRow Then
If e.Row.DBCampo("Inv_CveMetodoInventario") = "5" Then
e.Row.FCButton("BtnSerieLote").Visible = True
e.Row.FCButton("BtnSerieLote").CommandArgument = String.Format("{0}°{1}°{2}°{3}°{4}°1", e.Row.DBCampo("CvePS"), e.Row.DBCampo("CveUM"), e.Row.DBCampo("PS"), e.Row.DBCampo("Cantidad"), e.Row.DBCampo("Consec"))
e.Row.FCButton("BtnSerie").Visible = True
e.Row.FCButton("BtnSerie").CommandArgument = String.Format("{0}°{1}°{2}°{3}°{4}°1", e.Row.DBCampo("CvePS"), e.Row.DBCampo("CveUM"), e.Row.DBCampo("PS"), e.Row.DBCampo("Cantidad"), e.Row.DBCampo("Consec"))
e.Row.FCLinkButton("BtnSeriePaquete").CommandArgument = e.Row.DBCampo("Consec")
'Dim Contador = DtDatosDetalle.FiltraParametros(String.Format("ConsecId = {0}", e.Row.DBCampo("Consec"))).Rows.Count
'e.Row.FCTextBox("TbCantidadF").Text = Contador.ToString
@@ -727,7 +727,7 @@ Partial Class Inventarios_PaquetesArmadoDesarmado
GvDatosArmado.Columns(4).Visible = True
Else
e.Row.FCButton("BtnSerieLote").Visible = False
e.Row.FCButton("BtnSerie").Visible = False
End If
''FUNCIONALIDAD PISTOLA DE CODIGOS
@@ -744,10 +744,10 @@ Partial Class Inventarios_PaquetesArmadoDesarmado
If e.Row.RowType = DataControlRowType.DataRow Then
If e.Row.DBCampo("Inv_CveMetodoInventario") = "5" Then
e.Row.FCButton("BtnSerieLote").Visible = True
e.Row.FCButton("BtnSerieLote").CommandArgument = String.Format("{0}°{1}°{2}°{3}°{4}°2", e.Row.DBCampo("CvePS"), e.Row.DBCampo("CveUM"), e.Row.DBCampo("PS"), e.Row.DBCampo("Cantidad"), e.Row.DBCampo("Consec"))
e.Row.FCButton("BtnSerie").Visible = True
e.Row.FCButton("BtnSerie").CommandArgument = String.Format("{0}°{1}°{2}°{3}°{4}°2", e.Row.DBCampo("CvePS"), e.Row.DBCampo("CveUM"), e.Row.DBCampo("PS"), e.Row.DBCampo("Cantidad"), e.Row.DBCampo("Consec"))
Else
e.Row.FCButton("BtnSerieLote").Visible = False
e.Row.FCButton("BtnSerie").Visible = False
End If
@@ -770,7 +770,7 @@ Partial Class Inventarios_PaquetesArmadoDesarmado
DtDatosDetalle.Columns.Add("SeriePaquete", GetType(String))
End If
End Sub
Protected Sub BtnSerieLote_Click(sender As Object, e As EventArgs)
Protected Sub BtnSerie_Click(sender As Object, e As EventArgs)
Dim Argumentos = CType(sender, Button).CommandArgument.Split("°"c)

View File

@@ -58,7 +58,7 @@ Partial Class PopUpBuscarFolio
Dim FechaIngF = If(TxtFechaIngFin.Text.Trim <> "" AndAlso TxtFechaIngFin.Text <> "__/__/____", TxtFechaIngFin.Text.ToDate, MaxFecha)
If Reporte.GetMovimientosRep(DdlAlmacen.SelectedValue.ToEntero, DdlTipoMovimiento.SelectedValue.ToEntero, If(TxtFolio.Text = "", "-1", TxtFolio.Text.Trim).ToEntero,
FechaIngI, FechaIngF, FechaInicial, FechaFinal, -1, UsuarioActual.CveEmpresa) Then
FechaIngI, FechaIngF, FechaInicial, FechaFinal, -1, UsuarioActual.CveEmpresa, TopSelect:=100) Then
GvM.DataSource = Reporte.DtResultados
LtlTotalRegistros.Text = Reporte.DtResultados.Rows.Count.ToString.FormatoNumero(0)
Else

View File

@@ -97,7 +97,8 @@ Partial Class Inventarios_Default
If ValidarFiltrosSeleccionados() Then
Dim ObjInventarios As New ClsInventarios()
If ObjInventarios.GetExistenciasProducto(CvePS, -1, UsuarioActual.CveEmpresa, -1, FechaMovto:=DateTime.Today.AddDays(1).ToString("yyyy/MM/dd HH:mm"), ExcluyeApartados:=-1, ExcluyeAdelantado:=1, CveSubProyecto:=DdlSubProyecto.SelectedValue.ToEntero) Then
If ObjInventarios.GetExistenciasProducto(CvePS, -1, UsuarioActual.CveEmpresa, -1, FechaMovto:=DateTime.Today.AddDays(1).ToString("yyyy/MM/dd HH:mm"),
ExcluyeApartados:=-1, ExcluyeAdelantado:=1, CveSubProyecto:=DdlSubProyecto.SelectedValue.ToEntero, TopSelect:=100) Then
Dim dr As Data.DataRow = GlobalDTPS(UsuarioActual.CveEmpresa, CvePS:=CvePS).FiltroPrimero("")
If dr IsNot Nothing Then

View File

@@ -208,7 +208,7 @@
<th width="40%">Clasificación<br />
Producto </th>
<th width="10%">U.M.</th>
<th style="width: 20%" runat="server" id="ThSerie" visible="false">Serie - Lote</th>
<th style="width: 20%" runat="server" id="ThSerie" visible="false">Serie</th>
<th style="width: 10%;">Observaciones</th>
<th width="10%"></th>
</tr>

View File

@@ -84,22 +84,6 @@ Partial Class Inventarios_ResguardoMaterial
End Property
Private Property DtSeccionAlmacen As DataTable
Get
Return CType(ViewState("DtSeccionAlmacen"), DataTable)
End Get
Set(value As DataTable)
ViewState("DtSeccionAlmacen") = value
End Set
End Property
Private Property IndexSeccionAlmacen As Integer
Get
Return CType(ViewState("IndexSeccionAlmacen"), Integer)
End Get
Set(value As Integer)
ViewState("IndexSeccionAlmacen") = value
End Set
End Property
Private Property CantidadTotal As Decimal
Get
Return CType(ViewState("CantidadTotal"), Decimal)
@@ -174,7 +158,6 @@ Partial Class Inventarios_ResguardoMaterial
GvM.DataBind()
CantidadTotal = 0
IndexSeccionAlmacen = 0
CvePS = 0
TipoSeccionAlmacen = 0
@@ -379,7 +362,7 @@ Partial Class Inventarios_ResguardoMaterial
#End Region
#Region " EISTENCIAS "
#Region " EXISTENCIAS "
Private Function GetExistencias(CvePS As Integer, CveUnidadMedida As Integer, CveEmpresa As Integer, CveAlmacen As Integer, Optional Serie As String = "-1") As Double
Dim Inv As New ClsInventarios
Dim Existencia As Double = Inv.GetExistenciasPS(CvePS, CveUnidadMedida, CveEmpresa, CveAlmacen, FechaMovto:=TxtFecha.Text.ToDateTime.ToString("yyyy/MM/dd HH:mm"), Serie:=Serie)
@@ -481,10 +464,10 @@ Partial Class Inventarios_ResguardoMaterial
Protected Sub GvM_RowDataBound(sender As Object, e As GridViewRowEventArgs)
If e.Row.RowType = DataControlRowType.DataRow Then
If DtSeccionAlmacen.FiltraParametros($"IndexSeccionAlmacen = {e.Row.RowIndex}").SUMD("CantidadSeccionAlmacen") > 0 Then
e.Row.FCLinkButton("lnkRemove").Visible = False
e.Row.FCLinkButton("lnkRemove").ToolTip = "Cuenta con sección almacen"
End If
'If DtSeccionAlmacen.FiltraParametros($"IndexSeccionAlmacen = {e.Row.RowIndex}").SUMD("CantidadSeccionAlmacen") > 0 Then
' e.Row.FCLinkButton("lnkRemove").Visible = False
' e.Row.FCLinkButton("lnkRemove").ToolTip = "Cuenta con sección almacen"
'End If
End If
End Sub
#End Region
@@ -502,7 +485,6 @@ Partial Class Inventarios_ResguardoMaterial
DdlAlmacen.SelectedValueExist("-1")
DdlAlmacenDestino.SelectedValueExist("-1")
DtSeccionAlmacen.Rows.Clear()
TxtObservaciones.Text = ""
TxtFecha.Text = Now.ToShortDateString
@@ -595,8 +577,6 @@ Partial Class Inventarios_ResguardoMaterial
FechaLiberacion = TxtFechaLiberacion.Text
BtnGuardarLiberacion.Visible = True
DtSeccionAlmacen.Rows.Clear()
UpGeneralesLibreacion.Update()
Else
Alert("Ocurrió un error al cargar los resguardos del personal. Por favor vuelva a intentar.", TipoMensaje.MsgError)
@@ -633,8 +613,6 @@ Partial Class Inventarios_ResguardoMaterial
LbFechaLiberacion.Text = ""
FechaLiberacion = ""
BtnGuardarLiberacion.Visible = False
DtSeccionAlmacen.Rows.Clear()
DdlAlmacenDestinoLiberacion.SelectedValue = "-1"
TxtObservacionesLiberacion.Text = ""
@@ -685,14 +663,6 @@ Partial Class Inventarios_ResguardoMaterial
Alert(TextoExistencia.ToString, TipoMensaje.MsgError)
End If
Dim TotalCantidad As Double = DtMovimientos.SUMD("Cantidad")
If UsuarioActual.Empresa.Funcionalidad(563) = "1" Then
If TotalCantidad <> DtSeccionAlmacen.FiltraParametros("TipoSeccionAlmacen = 1").SUMD("CantidadSeccionAlmacen") Then
Alert("La seccion de almacen no ha sido agregada completamente.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
End If
Guardar(23)
End Sub
@@ -724,13 +694,6 @@ Partial Class Inventarios_ResguardoMaterial
Exit Sub
End If
If UsuarioActual.Empresa.Funcionalidad(563) = "1" Then
If TotalCantidad <> DtSeccionAlmacen.FiltraParametros("TipoSeccionAlmacen = 2").SUMD("CantidadSeccionAlmacen") Then
Alert("La seccion de almacen no ha sido agregada completamente.", TipoMensaje.MsgAdvertencia)
Exit Sub
End If
End If
Guardar(24)
@@ -824,7 +787,7 @@ Partial Class Inventarios_ResguardoMaterial
Dim Cont As Integer = 0
For Each Gvr As GridViewRow In GvMLiberacion.Rows
If Gvr.FCTextBox("TxtCantidad").Text.ToDouble > 0 Then
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoSalida, Gvr.FCTextBox("TxtCantidad").Text.ToDouble, Gvr.DataKey("CveUM").ToString.ToEntero, Gvr.DataKey("CvePS").ToString.ToEntero, Gvr.DataKey("PU").ToString.ToDecimal, -1, -1, Gvr.DataKey("SerieLote").ToString, Gvr.DataKey("Observaciones").ToString) Then
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoSalida, Gvr.FCTextBox("TxtCantidad").Text.ToDouble, Gvr.DataKey("CveUM").ToString.ToEntero, Gvr.DataKey("CvePS").ToString.ToEntero, Gvr.DataKey("PU").ToString.ToDecimal, -1, -1, Gvr.DataKey("Serie").ToString, Gvr.DataKey("Observaciones").ToString) Then
MensajeError = "Ocurrió un error al guardar los detalles del movimiento de salida. Por favor vuelva a intentar."
TieneError = True
Exit For
@@ -846,7 +809,7 @@ Partial Class Inventarios_ResguardoMaterial
If ObjInventario.GetMovimientosDetalle(CveMovimientoSalida, UsuarioActual.CveEmpresa) Then
Cont = 0
For Each Dr As DataRow In ObjInventario.DtResultados.Rows
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDecimal, Dr("CveAF").ToString.ToEntero, -1, Dr("SerieLote").ToString, Dr("Observaciones").ToString) Then
If Not ObjInventario.AddMovimientoDetalle(CveMovimientoEntrada, Dr("Cantidad").ToString.ToDouble, Dr("CveUM").ToString.ToEntero, Dr("CvePS").ToString.ToEntero, Dr("PU").ToString.ToDecimal, Dr("CveAF").ToString.ToEntero, -1, Dr("Serie").ToString, Dr("Observaciones").ToString) Then
TieneError = True
MensajeError = "Ocurrió un error al guardar los movimientos de entrada"
Exit For

View File

@@ -173,7 +173,7 @@ Partial Class OC_PopUpBuscarReq
Dim ObjOC As New ClsOC
ObjOC.GetOrdenesCompraRep(DdlTipo.SelectedValue, CveProyecto, CveSubProyecto, -1, DdlEstatus.SelectedValue.ToEntero, FI, MaxFecha, -1, DdlProveedor.SelectedValue.ToEntero,
If(TxtFolio.Text.ToEntero <= 0, -1, TxtFolio.Text.ToEntero), -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, -1, Guia:=guia,
SoloSubProyectosConPermiso:=If(UsuarioActual.Empresa.Funcionalidad(530) = "1", True, False))
SoloSubProyectosConPermiso:=If(UsuarioActual.Empresa.Funcionalidad(530) = "1", True, False), TopSelect:=100)
Dim DtOC = ObjOC.DtResultados ' tipotermino, esattus inicial
ObjOC.Dispose()

View File

@@ -84,6 +84,8 @@
<div class="bodycorreos">
<asp:Literal ID="LtlPara" runat="server"></asp:Literal>
<asp:TextBox ID="TxtCorreo" Enabled ="false" runat="server" CssClass="form-control " TextMode="MultiLine" Rows="3"></asp:TextBox>
<asp:RequiredFieldValidator ID="RfvCorreo" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtCorreo" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Correo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpCircular"></asp:RequiredFieldValidator>
<%--<ajax:ValidatorCalloutExtender ID="VCEFolio" runat="server" HighlightCssClass="vco" TargetControlID="RfvCorreo" Width="300px"></ajax:ValidatorCalloutExtender>--%>
<%--
<asp:LinkButton ID="Lnkuser1" runat="server" CssClass="linkCorreo" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar Correo?" data-btn-ok-label="si">Jorge caudillo(jcaudillo@adsistemas.mx)</asp:LinkButton>;
<asp:LinkButton ID="Lnkuser2" runat="server" CssClass="linkCorreo" data-toggle="confirmation" data-popout="true" data-original-title="¿Está seguro que desea eliminar Correo?" data-btn-ok-label="si">Julian Moreno(Julianmoreno@adsistemas.mx)</asp:LinkButton>;
@@ -106,6 +108,8 @@
</div>
<div class="bodycorreos">
<asp:TextBox ID="TxtAsunto" runat="server" CssClass="form-control "></asp:TextBox>
<asp:RequiredFieldValidator ID="RfvAsunto" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtAsunto" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Asunto''</b> es necesario, por favor ingréselo." ValidationGroup="GrpCircular"></asp:RequiredFieldValidator>
<%--<ajax:ValidatorCalloutExtender ID="VceAsunto" runat="server" HighlightCssClass="vco" TargetControlID="RfvAsunto" Width="300px"></ajax:ValidatorCalloutExtender>--%>
</div>
</div>
@@ -126,11 +130,13 @@
</div>
<div class="bodycorreos ">
<asp:TextBox ID="TxtCircular" runat="server" CssClass="form-control ADSckeditor" TextMode="MultiLine" Rows="3"></asp:TextBox>
<asp:RequiredFieldValidator ID="RfvCircular" runat="server" CssClass="help-block errorimput" ControlToValidate="TxtCircular" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Cuerpo''</b> es necesario, por favor ingréselo." ValidationGroup="GrpCircular"></asp:RequiredFieldValidator>
<%--<ajax:ValidatorCalloutExtender ID="VceCircular" runat="server" HighlightCssClass="vco" TargetControlID="RfvCircular" Width="300px"></ajax:ValidatorCalloutExtender>--%>
</div>
</div>
<div class="text-center">
<asp:Button ID="BtnGuardar" OnClick="BtnGuardar_Click" runat="server" CssClass="btn btn-primary" Text="Guardar" Visible="true" ValidationGroup="GrpGuardar" />
<asp:Button ID="BtnGuardar" OnClick="BtnGuardar_Click" runat="server" CssClass="btn btn-primary" Text="Guardar" Visible="true" ValidationGroup="GrpCircular" />
<asp:Button ID="BtnEliminar" OnClick="BtnEliminar_Click" runat="server" CssClass="btn btn-danger" Text="Eliminar" Visible="false" data-toggle="confirmation" data-popout="true" data-original-title="Confirmar" data-btn-ok-label="si" />
</div>

View File

@@ -605,12 +605,12 @@
<label for="<%= DdlTipoCliente.ClientID.ToString()%>">Tipo de Cliente:</label>
</div>
<div class="form-group form-md-line-input input-iconright">
<div class="form-group form-md-line-input input-iconright" id="divCorreoEntregaCompras" runat="server" visible="false" >
<asp:TextBox runat="server" ID="TxtCorreoEntregaCompras" CssClass="form-control"/>
<label for="<%= TxtCorreoEntregaCompras.ClientID.ToString()%>">Correo de Entrega de Compras:</label>
</div>
<div class="form-group form-md-line-input input-iconright">
<div class="form-group form-md-line-input input-iconright" id="divCorreoEntregaAlmacen" runat="server" visible="false">
<asp:TextBox runat="server" ID="TxtCorreoEntregaAlmacen" CssClass="form-control"/>
<label for="<%= TxtCorreoEntregaAlmacen.ClientID.ToString()%>">Correo de Entrega de Almacén:</label>
</div>

View File

@@ -1667,7 +1667,7 @@ Partial Class Clientes
End If
TxtCorreoEntregaCompras.Text = ObjClientes.DtResultados(0)("CorreoEntregaCompras").ToString
TxtCorreoEntregaAlmacen.Text = ObjClientes.DtResultados(0)("CorreoEntregaCompras").ToString
TxtCorreoEntregaAlmacen.Text = ObjClientes.DtResultados(0)("CorreoEntregaAlmacen").ToString
Else
Existe = False
Alert("El Cliente Solicitado no existe, por favor revise su búsqueda.", TipoMensaje.MsgAdvertencia)
@@ -5622,6 +5622,11 @@ Partial Class Clientes
CobranzaTelefono = ""
CodigoCliente = ""
If UsuarioActual.CveEmpresa.Contiene(1, 72, 80) Then
divCorreoEntregaCompras.Visible = True
divCorreoEntregaAlmacen.Visible = True
End If
End Sub
Protected Sub BtnCargaExcel_Click(sender As Object, e As EventArgs) Handles BtnCargaExcel.Click

View File

@@ -280,12 +280,12 @@ Partial Class PopUpBuscarFolio
End Sub
Private Function ValidarUnFiltroSeleccionado() As Boolean
If DdlTipoDocto.SelectedValue.ToEntero > 0 Then Return True
If DdlTipoDocto.SelectedValue <> "-1" Then Return True
If DdlSubProyecto.SelectedValue.ToEntero > 0 Then Return True
If DdlEstatusFactura.SelectedValue.ToEntero > 0 Then Return True
If DdlUsuario.SelectedValue.ToEntero > 0 Then Return True
If DdlPS.SelectedValue.ToEntero > 0 Then Return True
If TxtFolio.Text.Trim.Length > 0 Then Return True
If DdlNombre.SelectedValue.ToEntero > 0 Then Return True
If TxtFolioFiscal.Text.Trim.Length > 0 Then Return True
If TxtPedidoContrato.Text.Length > 0 Then Return True

View File

@@ -130,7 +130,7 @@
</div>
</div>
</div>
<asp:Button ID="BtnRefacturarDocumento" runat="server" ClientIDMode="Static" Text="Refacturar Documento" Style="display: none;" />
<asp:HiddenField ID="HdnLigaRefacturar" runat="server" Value="" ClientIDMode="Static" />
</ContentTemplate>
</asp:UpdatePanel>
<asp:Button ID="BtnEnviarMailCancelacion" runat="server" ClientIDMode="Static" Text="Enviar Mail Cliente" Style="display: none;" OnClick="BtnEnviarMailCancelacion_Click" />
@@ -138,8 +138,8 @@
<asp:Content ID="Content8" ContentPlaceHolderID="JS" runat="Server">
<script src="/Metronic/assets/global/plugins/jquery.pulsate.min.js"></script>
<script type="text/javascript">
function BtnRefacturarDocumento() {
$('#BtnRefacturarDocumento').click();
function RefacturarDocumento() {
window.location.replace(HdnLigaRefacturar.value);
}
function BtnEnviarMailCancelacion() {

View File

@@ -33,6 +33,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
}
private void CargaDatos()
{
HdnLigaRefacturar.Value = "";
if (Request["CveVenta"] != null)
{
this.CveVenta = Request["CveVenta"].ToString().ToEntero();
@@ -63,7 +64,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
}
protected void BtnValidar_Click(object sender, EventArgs e)
{
HdnLigaRefacturar.Value = "";
GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
int CveVenta = GvRow.DataKey("CveVenta").ToEntero();
int CveCliente = GvRow.DataKey("CveCliente").ToEntero();
@@ -91,7 +92,7 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
}
protected void BtnValidarRefacturacion_Click(object sender, EventArgs e)
{
HdnLigaRefacturar.Value = "";
GridViewRow GvRow = (GridViewRow)(((LinkButton)sender).NamingContainer);
int CveVenta = GvRow.DataKey("CveVenta").ToEntero();
int CveCliente = GvRow.DataKey("CveCliente").ToEntero();
@@ -106,10 +107,17 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
if (CveVenta > 0)
{
var respuesta = VerificarVigenciaSAT(CveVenta, CveCliente, Folio, TipoDocto, Uuid, UsuarioActual.Empresa.RFC, RFCCliente, Total, true);
Alert(respuesta.Mensaje);
CargaDatos();
CargaDatos();
if (respuesta.CveEstatus.Contiene(4,5))
{
HdnLigaRefacturar.Value = respuesta.LigaRefacturacion;
Alert(respuesta.Mensaje, JSBtnAceptar: $"RefacturarDocumento();");
}
else
{
Alert(respuesta.Mensaje,TipoMensaje.MsgAdvertencia);
}
//if (respuesta.IrARefacturar)
//{
// Server.Transfer(respuesta.LigaRefacturacion);
@@ -120,10 +128,12 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
// CargaDatos();
//}
}
UPDatos.Update();
}
private MRespuestaSAT VerificarVigenciaSAT(int CveVenta, int CveCliente, string Folio, string TipoDocto, string uuid, string emisor, string receptor, string total, bool EsRefacturacion = false)
{
HdnLigaRefacturar.Value = "";
var retorno = new MRespuestaSAT()
{
Mensaje = "",
@@ -161,14 +171,18 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
{
var respCancelacion = CancelarDocumento(CveVenta, CveEstatus, CveCliente, Folio, uuid, CancelacionAcuse, CancelacionFecha, TipoDocto, total.ToDouble(), UsuarioActual.Empresa.CvePAC, EsRefacturacion: EsRefacturacion);
sb.AppendFormat("{0} <br/>", respCancelacion.Mensaje);
//sb.AppendFormat("{0} <br/>", respCancelacion.Mensaje);
if (!respCancelacion.HuboError)
{
CveEstatus = respCancelacion.CveEstatus;
retorno.EnviarAcuse = true;
sb.Append("El Documento se canceló correctamente.");
sb.Append("El documento se canceló correctamente.");
sb.Append($"</br> <a href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=CAN&CVEVTA={CveVenta}")}' class='Texto' target='_blank'>Imprimir Acuse</a>");
sb.Append("</br></br> ¿Desea enviar el Acuse de Cancelación al Cliente?");
if (!EsRefacturacion)
{
sb.Append("</br></br> ¿Desea enviar el Acuse de Cancelación al Cliente?");
}
}
if (respCancelacion.CveEstatus.Contiene(4, 5) && EsRefacturacion)
@@ -192,12 +206,17 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
var respCancelacion = CancelarDocumento(CveVenta, CveEstatus, CveCliente, Folio, uuid, CancelacionAcuse, CancelacionFecha, TipoDocto, total.ToDouble(), UsuarioActual.Empresa.CvePAC, EsRefacturacion: EsRefacturacion);
sb.AppendFormat("{0} <br/>", respCancelacion.Mensaje);
//sb.AppendFormat("{0} <br/>", respCancelacion.Mensaje);
if (!respCancelacion.HuboError)
{
sb.Append("El Documento se canceló correctamente.");
retorno.EnviarAcuse = true;
CveEstatus = respCancelacion.CveEstatus;
sb.Append("El documento se canceló correctamente.");
sb.Append($"</br> <a href='/Compras/PopUpVerFactura.aspx?P={Encripta($"OP=CAN&CVEVTA={CveVenta}")}' class='Texto' target='_blank'>Imprimir Acuse</a>");
sb.Append("</br></br> ¿Desea enviar el Acuse de Cancelación al Cliente?");
if (!EsRefacturacion)
{
sb.Append("</br></br> ¿Desea enviar el Acuse de Cancelación al Cliente?");
}
}
if (respCancelacion.CveEstatus.Contiene(4, 5) && EsRefacturacion)
@@ -237,6 +256,8 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
return retorno;
}
retorno.CveEstatus = CveEstatus;
retorno.Mensaje = sb.ToString();
return retorno;
}
@@ -413,10 +434,10 @@ public partial class Ventas_RepCancelacionesPorRespuesta : ClsPaginas
}
}
}
public class MRespuestaSAT
{
public int CveEstatus { get; set; }
public bool EnviarAcuse { get; set; }
public string LigaRefacturacion { get; set; }
public bool IrARefacturar { get; set; }

View File

@@ -3259,7 +3259,7 @@
<tr align="left">
<td>
<asp:TextBox ID="TxtObsFact" runat="server" Rows="3" TextMode="MultiLine" Width="250px" MaxLength="800" CssClass="form-control input-sm"></asp:TextBox></td>
</tr>
</tr>
<tr id="TrOC" runat="server">
<td>Orden de Compra: &nbsp;
<asp:TextBox ID="TxtOrdenCompra" runat="server" Width="100%" CssClass="form-control" CausesValidation="true"></asp:TextBox>
@@ -3287,6 +3287,13 @@
<td>Kilometraje&nbsp;
<asp:TextBox ID="TxtKilometraje" runat="server" Width="250px" CssClass="form-control input-sm"></asp:TextBox></td>
</tr>
<tr align="left" id="trCorreoNotif1" runat="server" visible="false">
<td id="Td1" runat="server">Correo Notificacion:&nbsp;</td>
</tr>
<tr align="left" id="trCorreoNotif2" runat="server" visible="false">
<td>
<asp:TextBox ID="TxtCorreoNotificaciones" runat="server" Width="100%" CssClass="form-control"></asp:TextBox></td>
</tr>
</table>
</div>
</ContentTemplate>

View File

@@ -1854,8 +1854,10 @@ Partial Class Ventas
thPredial2.Visible = True
End If
If UsuarioActual.CveEmpresa.Contiene(72, 80) Then ' PARA BUSCAR FOLIO DE OC, YA FACTURADA EN EL CAMPO ORDEN DE COMPRA
If UsuarioActual.CveEmpresa.Contiene(1, 72, 80) Then ' PARA BUSCAR FOLIO DE OC, YA FACTURADA EN EL CAMPO ORDEN DE COMPRA
TxtOrdenCompra.Attributes.Add("onblur", "BuscarOCRegistrada();")
trCorreoNotif1.Visible = True
trCorreoNotif2.Visible = True
End If
If UsuarioActual.Empresa.Funcionalidad(561).ToString() = "1" Then
@@ -3936,6 +3938,8 @@ Partial Class Ventas
TxtSubTotal2.Text = (TxtSubTotal.Text.Replace(",", "").Trim.Trim.ToDouble - LblDescuentos.Text.Replace(",", "").Trim.Trim.ToDouble - LblAmortizacion.Text.Replace(",", "").Trim.Trim.ToDouble).FormatoNumero(2)
TxtIVA.Text = DbRowVenta("IVA").ToString().FormatoNumero(2)
TxtRetIVA.Text = DbRowVenta("RetIVA").ToString().FormatoNumero(2)
TxtCorreoNotificaciones.Text = DbRowVenta("CorreoNotificacion").ToString()
If TxtRetIVA.Text.ToDecimal() > 0 Then
TrRetIVA.Style.Add("display", "")
UsuarioActual.Empresa.MostrarRetIVA = True
@@ -7858,7 +7862,7 @@ Partial Class Ventas
dr("SATClaveUM") = "ACT"
dr("Consec") = ii
dr("PorcentajeIVA") = dr("PorcentajeIVA").ToString().ToDecimal
dr("PorcentajeIVA") = Drr("PorcentajeIVA").ToString().ToDecimal
dr("IVA") = Drr("PorcentajeIVA")
dr("ImporteIVA") = Drr("ImporteIVA").ToString().ToDecimal
@@ -9498,7 +9502,7 @@ Partial Class Ventas
CveVentaRelacion:=(If(factura.CveVentaRelacion.ToEntero() > 0, factura.CveVentaRelacion, -1)), ImporteRelacion:=(If(factura.ImporteRelacion <> Nothing, factura.ImporteRelacion, -1)),
CveTipoAmortizacionAnticipo:=factura.CveTipoAmortizacionAnticipo, CveEmpresaCRM:=CveEmpresaCRM, EsInterno:=EsInterno, CveAcercamientoCRM:=CveAcercamientoCRM,
DiasCredito:=factura.DiasCredito, EsDiasCreditoFijo:=factura.EsDiasCreditoFijo, AnticipoEspecial:=If(TrAntEspecial.Visible, ChkAntEspecial.Checked, False),
Kilometraje:=TxtKilometraje.Text.ToDouble, EsAmortizacion:=EsNCAmortizacion, CveTipoRetencion:=CveTipoRetencion) Then
Kilometraje:=TxtKilometraje.Text.ToDouble, EsAmortizacion:=EsNCAmortizacion, CveTipoRetencion:=CveTipoRetencion, CorreoNotificacion:=TxtCorreoNotificaciones.Text) Then
ErrorList.Add("Ocurrió un error al Generar la Venta.<br />Revise su factura y cualquier detalle comuníquese a Soporte Técnico")
Else
If factura.TipoDocto.Contiene("Dev", "Egs") Or DtVentasNC IsNot Nothing Or CveEstatusRefacturacion = 1 Then
@@ -12817,13 +12821,13 @@ Partial Class Ventas
'cuando es amortización por NOTA DE CREDITO
If DdlTipoAmortizacionAnticipo.SelectedValue = "2" Then
LblAntAplicados.Text = "Amortización por Nota de Crédito" : LblAntAplicados.Visible = True
LblAntAplicados.Text = String.Format("Amortización por Nota de Crédito: {0:C}", Amortizacion) : LblAntAplicados.Visible = True
Amortizacion = 0
HdnTipoDescuento.Value = "-1"
HdnDescuento.Value = "0"
RegistraScript("BorraDescuentos();")
HdnTieneAnticiposVinculados.Value = "1"
AplicaNCMasiva = True
End If
'cuando es AMORTIZACIÓN CON FACTURA EN CERO
@@ -13775,7 +13779,7 @@ Partial Class Ventas
End If
Dim PorcentajePrecio As Double = 0
If PrecioSugerido = 0 Then
If PrecioSugerido = 0 AndAlso CveCliente > 0 Then
CvePrecioListaPS = GlobalDTCliente(UsuarioActual.CveEmpresa, Estatus:=-1, CveCliente:=CveCliente).FiltroPrimeroValor("CvePrecioLista").ToEntero()
If CvePrecioListaPS > 0 Then
Dim ObjPS As New ClsProductosServicios