Merge branch 'master' of http://192.168.10.111:8383/SIG
This commit is contained in:
@@ -20756,14 +20756,16 @@ Partial Class Compras_Compras
|
||||
Public Function ValidaPresupuesto(Opcion As Integer, Optional ValCveSubProyecto As Integer = -1, Optional ValSubProyecto As String = "", Optional ValCveClasificacion As Integer = -1, Optional ValClasificacion As String = "",
|
||||
Optional ValCveTipoGasto As Integer = -1, Optional ValTipoGasto As String = "", Optional ValImporte As Decimal = 0) As Boolean
|
||||
|
||||
|
||||
Dim respuesta As Boolean = False
|
||||
|
||||
If DdlTipoComprobante.SelectedValue <> "Fac" Then
|
||||
Return True
|
||||
End If
|
||||
|
||||
If UsuarioActual.Empresa.Funcionalidad(532) = "1" Then
|
||||
|
||||
If Opcion = 1 Or OCVinculada Or DdlTipoComprobante.SelectedValue <> "Fac" Then
|
||||
Return True
|
||||
End If
|
||||
|
||||
Dim ObjCon As New ClsContratos
|
||||
Dim CvePresupuesto As Integer = 0
|
||||
Dim Autorizado As Double = 0
|
||||
|
||||
@@ -2053,7 +2053,7 @@
|
||||
<asp:UpdatePanel runat="server" ID="UpDocumentos" UpdateMode="Conditional">
|
||||
<ContentTemplate>
|
||||
<asp:GridView ID="GvDocs" AutoGenerateColumns="false" runat="server" GridLines="none"
|
||||
DataKeyNames="CveDocumentacion,Documentacion,Orden,CveDocumentacionElectronica,Adjunto,Estatus,Observacion,Fecha,FechaIng,Usuario,FechaLimite,FechaVigencia,DiasLimite,AplicaDiasLimite,AplicaFechaVencimiento">
|
||||
DataKeyNames="CveDocumentacion,Documentacion,Orden,CveDocumentacionElectronica,Adjunto,Estatus,Observacion,Fecha,FechaIng,Usuario,FechaLimite,FechaVigencia,DiasLimite,AplicaDiasLimite,AplicaFechaVencimiento">
|
||||
<Columns>
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="center" ItemStyle-Width="60px">
|
||||
<ItemTemplate>
|
||||
@@ -2093,11 +2093,17 @@
|
||||
CssClass="btn btn-circle btn-sm green" Text="<i class='fa fa-upload' ></i>" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Left" ItemStyle-Width="50px">
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Left" ItemStyle-Width="50px" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:Literal ID="ImgDownLoad" runat="server"></asp:Literal>
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Right" ItemStyle-Width="50px">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LnkDownLoadDoc" CssClass="btn btn-circle btn-sm blue" OnClick="LnkDownLoadDoc_Click" runat="server"
|
||||
Text="<i class='fa fa-download' style='color:white' title='Descargar Documento'></i>" CausesValidation="False" Visible="false" />
|
||||
</ItemTemplate>
|
||||
</asp:TemplateField>
|
||||
<asp:TemplateField ItemStyle-HorizontalAlign="Right" ItemStyle-Width="50px" Visible="false">
|
||||
<ItemTemplate>
|
||||
<asp:LinkButton ID="LnkGVEliminar" runat="server" AlternateText="Editar" CausesValidation="False" OnClick="LnkGVEliminar_Click"
|
||||
|
||||
@@ -2526,6 +2526,8 @@ Partial Class Compras_Proveedores
|
||||
Dim AplicaDiasLimite As Boolean = If(e.Row.DataKey("AplicaDiasLimite").ToString = "1", True, False)
|
||||
Dim AplicaFechaVencimiento As Boolean = If(e.Row.DataKey("AplicaFechaVencimiento").ToString = "1", True, False)
|
||||
|
||||
Dim LnkDownLoadDoc As LinkButton = e.Row.FCLinkButton("LnkDownLoadDoc")
|
||||
|
||||
txtFechaLimite.Visible = If(AplicaDiasLimite, True, False)
|
||||
' txtFechaVigencia.Visible = If(AplicaFechaVencimiento, True, False)
|
||||
|
||||
@@ -2569,19 +2571,25 @@ Partial Class Compras_Proveedores
|
||||
Dim linkDescargaArchivo As String = UsuarioActual.Empresa.Ruta & "Edoc/Proveedor/" & CveProveedor & "/" & Adjunto
|
||||
|
||||
If File.Exists(linkDescargaArchivo) Then
|
||||
ImgDownLoad.Visible = True
|
||||
|
||||
If extencion.Length > 0 Then
|
||||
ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black' download='{1}'><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga, CveDocumentacionElectronica & "." & extencion)
|
||||
Else
|
||||
ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black' download='{1}'><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga, CveDocumentacionElectronica)
|
||||
End If
|
||||
'ImgDownLoad.Visible = True
|
||||
|
||||
LnkDownLoadDoc.Visible = True
|
||||
ScriptManager.GetCurrent(Me).RegisterPostBackControl(LnkDownLoadDoc)
|
||||
|
||||
'If extencion.Length > 0 Then
|
||||
' ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black' download='{1}'><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga, CveDocumentacionElectronica & "." & extencion)
|
||||
'Else
|
||||
' ImgDownLoad.Text = String.Format(" <a class='btn btn-circle btn-sm blue' href='{0}' target='_black' download='{1}'><i class='fa fa-download' title='Descargar documento'></i></a>", linkDescarga, CveDocumentacionElectronica)
|
||||
'End If
|
||||
|
||||
|
||||
Else
|
||||
ImgDownLoad.Visible = False
|
||||
'ImgDownLoad.Visible = False
|
||||
End If
|
||||
|
||||
Else
|
||||
ImgDownLoad.Visible = False
|
||||
'ImgDownLoad.Visible = False
|
||||
End If
|
||||
|
||||
If requerido Then
|
||||
@@ -5835,6 +5843,28 @@ Partial Class Compras_Proveedores
|
||||
End Sub
|
||||
|
||||
#End Region
|
||||
|
||||
Protected Sub LnkDownLoadDoc_Click(sender As Object, e As EventArgs)
|
||||
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
|
||||
Dim Adjunto As String = GvRow.DataKey("Adjunto")
|
||||
|
||||
|
||||
Dim stringDescargaDocumento As String = UsuarioActual.Empresa.Ruta & String.Format("Edoc\\Proveedor\{0}\{1}", CveProveedor, Adjunto)
|
||||
|
||||
|
||||
Dim File As New FileInfo(stringDescargaDocumento)
|
||||
|
||||
If File.Exists Then
|
||||
Response.Clear()
|
||||
Response.AddHeader("Content-Disposition", "attachment; filename=" + File.Name)
|
||||
Response.AddHeader("Content-Length", File.Length.ToString())
|
||||
Response.ContentType = "text/octet-stream"
|
||||
Response.Flush()
|
||||
Response.TransmitFile(File.FullName)
|
||||
Response.End()
|
||||
End If
|
||||
|
||||
End Sub
|
||||
End Class
|
||||
|
||||
|
||||
|
||||
@@ -552,22 +552,15 @@
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkObservaciones" runat="server" Text="Observaciones" Checked="false" /></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkSubTotalPend" runat="server" Text=" SubTotal Pendiente" Checked="false" /></td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkIVAPend" runat="server" Text=" IVA Pendiente" Checked="false" /></td>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkIEPSPend" runat="server" Text=" IEPS Pendiente" Checked="false" Visible="false" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkSubTotalPend" runat="server" Text=" SubTotal Pendiente" Checked="false" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIVAPend" runat="server" Text=" IVA Pendiente" Checked="false" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIEPSPend" runat="server" Text=" IEPS Pendiente" Checked="false" Visible="false" /></td>
|
||||
<td style="text-align: left;"></td>
|
||||
</tr>
|
||||
<tr>
|
||||
<td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkIEPSP" runat="server" Text=" IEPS Pendiente" Checked="False" Visible="false" TextAlign="Right" />
|
||||
</td><td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkRetIVAPendiente" runat="server" Text=" Ret IVA Pendiente" Checked="False" TextAlign="Right" />
|
||||
</td><td style="text-align: left;">
|
||||
<asp:CheckBox ID="ChkRetISRPendiente" runat="server" Text=" Ret ISR Pendiente" Checked="False" TextAlign="Right" />
|
||||
</td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkIEPSP" runat="server" Text=" IEPS Pendiente" Checked="False" Visible="false" TextAlign="Right" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetIVAPendiente" runat="server" Text=" Ret IVA Pendiente" Checked="False" TextAlign="Right" /></td>
|
||||
<td style="text-align: left;"><asp:CheckBox ID="ChkRetISRPendiente" runat="server" Text=" Ret ISR Pendiente" Checked="False" TextAlign="Right" /></td>
|
||||
</tr>
|
||||
</table>
|
||||
|
||||
|
||||
Reference in New Issue
Block a user