- se tomaron los cambios locales

This commit is contained in:
2024-01-29 20:05:45 -07:00
11 changed files with 3680 additions and 106 deletions

View File

@@ -38,6 +38,7 @@ Public Class ClsContratos
Public Property NumeroEstimacionNueva As Integer
Public Property CveEstimacionNueva As Integer
Public Property CveChofer As Integer
@@ -299,6 +300,7 @@ Public Class ClsContratos
Me.ImporteTotal = Data.Rows(0)("ImporteTotal").ToString.ToDecimal
Me.Lugar = Data.Rows(0)("Lugar").ToString
Me.LimiteDeGasto = Data.Rows(0)("LimiteDeGasto").ToString.ToDouble
CveChofer = Data.Rows(0)("CveChofer").ToString.ToEntero
Observaciones = Data.Rows(0)("Observaciones").ToString
CveDireccionEnvio = Data.Rows(0)("CveDireccionEnvio").ToString.ToEntero
@@ -319,7 +321,7 @@ Public Class ClsContratos
Optional CveContratosEstatus As Integer = -1, Optional CveContratoTipo As Integer = -1, Optional TipoCambio As Double = 1, Optional CveSucursalCliente As Integer = -1, Optional CveAlmacenOrigen As Integer = -1, Optional CveAlmacenDestino As Integer = -1, Optional PorcentajeComision As Integer = -1,
Optional TipoGarantia As Integer = -1, Optional Folio As Integer = -1, Optional FechaVenc As Date = Nothing, Optional EstatusFianza As Integer = -1, Optional CvePeriodo As Integer = -1, Optional CveContratoPlantilla As Integer = -1, Optional CveCuentaEquipo As Integer = -1,
Optional CveVendedor As Integer = -1, Optional Observaciones As String = "", Optional CveDireccionEnvio As Integer = -1, Optional AplicaImpuestosLocales As Boolean = False, Optional CorreoNotificacionPedDev As String = "",
Optional FacturacionCicilica As Boolean = False, Optional FacturacionCiclicaAutomatico As Boolean = False, Optional DiaMesFacturacion As Integer = 1, Optional ObservacionesGenerales As String = "", Optional CveTipoAF As Integer = -1) As Integer
Optional FacturacionCicilica As Boolean = False, Optional FacturacionCiclicaAutomatico As Boolean = False, Optional DiaMesFacturacion As Integer = 1, Optional ObservacionesGenerales As String = "", Optional CveTipoAF As Integer = -1, Optional CveChofer As Integer = -1) As Integer
Dim Retorno As Integer = -1
DataAdapter("PA_Con_ContratosAdd")
@@ -376,6 +378,7 @@ Public Class ClsContratos
.Add("@DiaMesFacturacion", SqlDbType.TinyInt).Value = DiaMesFacturacion
.Add("@ObservacionesGenerales", SqlDbType.VarChar).Value = ObservacionesGenerales
.Add("@CveTipoAF", SqlDbType.Int).Value = CveTipoAF
.Add("@CveChofer", SqlDbType.Int).Value = CveChofer
End With

View File

@@ -443,11 +443,13 @@ Public Class CargaEventos : Implements IHttpHandler, IRequiresSessionState
Dim usuarioActual_ As Usuario = UsuarioActual(context)
Dim ErrorEventos As Boolean = False
Dim Colores() As String = {"#006699", "#0099cc", "#0066cc", "#0033cc", "#0000ff", "#3333ff", "#3333ff", "#6600ff", "#9933ff", "#cc00ff", "#cc00cc", "#cc0099", "#cc3399", "#cc6699", "#cc0066", "#009933", "#00cc00", "#00cc66", "#009999", "#669900", "#99cc00", "#cccc00", "#cc9900", "#ff9900", "#006666", "#669999"}
Dim tipoVista As String = context.Request("tipoVista")
DT_SubProyectos.Columns.Add("CveSubProyecto", GetType(Integer))
DT_SubProyectos.Columns.Add("backgroundColor")
DT_EstatusOS.Columns.Add("", GetType(Integer))
If ObjContratos.GetContratos(-1, usuarioActual_.CveEmpresa, TipoContrato:=2) Then
If ObjContratos.DtResultados.Rows.Count > 0 Then
@@ -460,7 +462,7 @@ Public Class CargaEventos : Implements IHttpHandler, IRequiresSessionState
cevent.id = dr("CveContrato").ToString.ToEntero
cevent.title = dr("DescripcionContrato").ToString
cevent.start = String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime)
cevent.end = String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime)
cevent.end = If(tipoVista = "fecha", String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime.AddHours(1)), String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime)) 'Agregar una hora, fecha final como default
cevent.allDay = False
cevent.CveEventoEstatus = dr("NumeroContrato").ToString.ToEntero
@@ -516,12 +518,10 @@ Public Class CargaEventos : Implements IHttpHandler, IRequiresSessionState
cevent.id = dr("CveContrato").ToString.ToEntero
cevent.description = dr("DescripcionContrato").ToString
cevent.start = String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime)
cevent.end = String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime)
cevent.end = If(tipoVista = "fecha", String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime.AddHours(1)), String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime))
cevent.allDay = False
cevent.CveEventoEstatus = dr("NumeroContrato").ToString.ToEntero
'11/05/2018 - Evento Gasto Recurrente
cevent.CveTipoEvento = dr("CveTipoEvento").ToString.ToEntero
If cevent.CveTipoEvento = 10 Then
@@ -542,7 +542,7 @@ Public Class CargaEventos : Implements IHttpHandler, IRequiresSessionState
cevent.id = dr("CveContrato").ToString.ToEntero
cevent.description = dr("DescripcionContrato").ToString
cevent.start = String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime)
cevent.end = String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime)
cevent.end = If(tipoVista = "fecha", String.Format("{0:s}", dr("FechaInicial").ToString.ToDateTime.AddHours(1)), String.Format("{0:s}", dr("FechaFinal").ToString.ToDateTime))
cevent.allDay = False
'cevent.CveEventoEstatus = dr("NumeroContrato").ToString.ToEntero
'cevent.CveEventoEstatus = dr("CveEventoEstatus").ToString.ToEntero

View File

@@ -1477,7 +1477,13 @@
<Paragraph>
<TextRuns>
<TextRun>
<Value>Proveedor: </Value>
<Value>=IIF( LEN(Parameters!Documentacion.Value) &gt; 0, "Proveedor:","")</Value>
<Style>
<FontWeight>Bold</FontWeight>
</Style>
</TextRun>
<TextRun>
<Value xml:space="preserve"> </Value>
<Style>
<FontWeight>Bold</FontWeight>
</Style>
@@ -1493,8 +1499,8 @@
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox31</rd:DefaultName>
<Top>2.16703cm</Top>
<Left>0.13678cm</Left>
<Top>2.0612cm</Top>
<Left>0.10068cm</Left>
<Height>1.27434cm</Height>
<Width>13.15003cm</Width>
<ZIndex>1</ZIndex>
@@ -1864,19 +1870,25 @@ CIUDAD DE MEXICO</Value>
</TextRun>
<TextRun>
<Value>.
Sucursal: .</Value>
</Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value>=Parameters!ClienteSucursal.Value</Value>
<Value>=IIF(LEN(Parameters!ClienteSucursal.Value)&gt; 0,"Sucursal: ","")</Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value> RFC: </Value>
<Value>=IIF(LEN(Parameters!ClienteSucursal.Value)&gt;0, Parameters!ClienteSucursal.Value &amp; " ","")</Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
</TextRun>
<TextRun>
<Value> RFC: </Value>
<Style>
<FontSize>7pt</FontSize>
</Style>
@@ -1985,8 +1997,8 @@ Municipio y/o Delegación: </Value>
</Paragraph>
</Paragraphs>
<rd:DefaultName>Textbox7</rd:DefaultName>
<Top>2.32101cm</Top>
<Left>0.10068cm</Left>
<Top>2.2681cm</Top>
<Left>0.06622cm</Left>
<Height>2.12398cm</Height>
<Width>20.93288cm</Width>
<ZIndex>9</ZIndex>
@@ -2468,6 +2480,7 @@ Municipio y/o Delegación: </Value>
</Style>
</Textbox>
<Line Name="Line5">
<Top>0cm</Top>
<Left>0.13678cm</Left>
<Height>0cm</Height>
<Width>20.28859cm</Width>
@@ -2479,6 +2492,7 @@ Municipio y/o Delegación: </Value>
</Style>
</Line>
<Line Name="Line4">
<Top>0cm</Top>
<Left>0.13678cm</Left>
<Height>0cm</Height>
<Width>25.72414cm</Width>

File diff suppressed because it is too large Load Diff

View File

@@ -155,12 +155,10 @@
</ContentTemplate>
</asp:UpdatePanel>
<div class="row">
<div class="col-md-12" style="text-align:right">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="display: inline-block; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
</div>
<div class="" align="right">
<input type="text" id="TxtBusqueda" class="form-control input-sm" onkeyup="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="display: inline-block; margin-right: -20px; width: 150px;" />
<a href="javascript:;" onclick="<%= String.Format("FiltrarTabla('TxtBusqueda','{0}')", GvDatos.ClientID) %>" style="margin-top: -3px;" class="btn btn-circle btn-sm label-info"><i class="icon-magnifier"></i></a>
</div>
<asp:UpdatePanel ID="UPDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>

View File

@@ -16,7 +16,6 @@ Partial Class ListadoContratos
End Property
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
DdlClientes.setEsWebService(True)
InicializaCombos()
CargaDatos()
End If
@@ -51,20 +50,22 @@ Partial Class ListadoContratos
UpTitulos.Update()
End Sub
Protected Sub MostrarModal()
TxtDescripcion.Text = ""
TxtFechaSalida.Text = ""
TxtFechaRegreso.Text = ""
TxtObservaciones.Text = ""
TxtUbicacion.Text = ""
DdlTransporte.SelectedValue = ""
DdlClientes.SelectedText = ""
TxtDolares.Text = ""
TxtPesos.Text = ""
TxtAnticipo.Text = ""
BtnGuardar.Text = "Guardar"
myModalLabel.InnerHtml = "Agregar Contrato"
Protected Sub MostrarModal(Optional Descripcion As String = "", Optional FechaSalida As String = "", Optional FechaRegreso As String = "", Optional Observaciones As String = "", Optional Ubicacion As String = "", Optional Transporte As String = "", Optional Cliente As String = "", Optional Dolares As String = "", Optional Pesos As String = "", Optional Anticipo As String = "", Optional Boton As String = "Guardar", Optional Chofer As String = "")
TxtDescripcion.Text = Descripcion
TxtFechaSalida.Text = FechaSalida
TxtFechaRegreso.Text = FechaRegreso
TxtObservaciones.Text = Observaciones
TxtUbicacion.Text = Ubicacion
DdlTransporte.SelectedValue = Transporte
DdlClientes.SelectedText = Cliente
DdlChofer.SelectedValue = Chofer
TxtDolares.Text = Dolares
TxtPesos.Text = Pesos
TxtAnticipo.Text = Anticipo
BtnGuardar.Text = Boton
myModalLabel.InnerHtml = $"{Boton} Contrato"
UpModal.Update()
RegistraScript(String.Format("$('#{0}').modal('show');", "ModalAgregar"))
End Sub
Private Sub LBAgregarContrato_Click(sender As Object, e As EventArgs) Handles LBAgregarContrato.Click
@@ -81,7 +82,6 @@ Partial Class ListadoContratos
ObjContratos.IniciaTransacSQL()
Try
Dim CveEstatusInicial As Integer = 10
Dim CveContratoHijo As Integer = -1
Dim CveContratoTipo As Integer = 2
@@ -92,7 +92,7 @@ Partial Class ListadoContratos
End If
'Agregar contrato
If BtnGuardar.Text = "Guardar" Then
CveContratoHijo = ObjContratos.AddContratos("", TxtDescripcion.Text, "", UsuarioActual.CveProveedor, DdlClientes.SelectedValue.ToEntero, -1, TxtFechaSalida.Text.ToDate, TxtFechaRegreso.Text.ToDate, TxtUbicacion.Text, "", 10, -1, -1, -1, -1, "", "", -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, False, TxtAnticipo.Text.ToDecimal, TxtPesos.Text.ToDecimal, TxtDolares.Text.ToDecimal, -1, 0, CveContratoTipo:=2, CveContratosEstatus:=1, CveTipoAF:=DdlTransporte.SelectedValue.ToEntero)
CveContratoHijo = ObjContratos.AddContratos("", TxtDescripcion.Text, "", UsuarioActual.CveProveedor, DdlClientes.SelectedValue.ToEntero, -1, TxtFechaSalida.Text.ToDate, TxtFechaRegreso.Text.ToDate, TxtUbicacion.Text, "", 10, -1, -1, -1, -1, "", "", -1, UsuarioActual.CveUsuario, UsuarioActual.CveEmpresa, False, TxtAnticipo.Text.ToDecimal, TxtPesos.Text.ToDecimal, TxtDolares.Text.ToDecimal, -1, 0, CveContratoTipo:=2, CveContratosEstatus:=1, CveTipoAF:=DdlTransporte.SelectedValue.ToEntero, CveChofer:=DdlChofer.SelectedValue.ToEntero)
End If
If CveContratoHijo > 0 Then
@@ -132,33 +132,10 @@ Partial Class ListadoContratos
End Sub
Protected Sub UpdateContrato(sender As Object, e As EventArgs)
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
Dim fechaInicial As DateTime
Dim fechaFinal As DateTime
CveContrato = GvRow.DataKey("CveContrato").ToEntero
DdlClientes.SelectedValue = GvRow.DataKey("CveCliente")
If GvRow.DataKey("CveCliente").ToEntero > 0 Then
DdlClientes.SelectedText = GlobalDTCliente(UsuarioActual.CveEmpresa, CveCliente:=GvRow.DataKey("CveCliente").ToEntero).FiltroPrimeroValor("NombreComercial")
End If
TxtDescripcion.Text = GvRow.DataKey("DescripcionContrato")
TxtObservaciones.Text = GvRow.DataKey("DescripcionContrato")
TxtUbicacion.Text = GvRow.DataKey("Ubicacion")
DdlTransporte.SelectedValue = GvRow.DataKey("CveTipoAF")
TxtDolares.Text = GvRow.DataKey("Importe")
TxtPesos.Text = GvRow.DataKey("ImporteMax")
TxtAnticipo.Text = GvRow.DataKey("ImporteMin")
If DateTime.TryParse(GvRow.DataKey("FechaInicial").ToString, fechaInicial) And DateTime.TryParse(GvRow.DataKey("FechaFinal").ToString, fechaFinal) Then
TxtFechaSalida.Text = fechaInicial.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T")
TxtFechaRegreso.Text = fechaFinal.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T")
End If
BtnGuardar.Text = "Editar"
myModalLabel.InnerHtml = "Editar Contrato"
RegistraScript(String.Format("$('#{0}').modal('show');", "ModalAgregar"))
MostrarModal(
Descripcion:=GvRow.DataKey("DescripcionContrato"), FechaSalida:=GvRow.DataKey("FechaInicial").ToDateTime.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T"), FechaRegreso:=GvRow.DataKey("FechaFinal").ToDateTime.ToString("yyyy-MM-dd HH:mm:ss").Replace(" ", "T"), Observaciones:=GvRow.DataKey("DescripcionContrato"), Ubicacion:=GvRow.DataKey("Ubicacion"), Transporte:=GvRow.DataKey("CveTipoAF"), Cliente:=GvRow.DataKey("CveCliente"), Dolares:=GvRow.DataKey("Importe"), Pesos:=GvRow.DataKey("ImporteMax"), Anticipo:=GvRow.DataKey("ImporteMin"), Boton:="Editar", Chofer:=GvRow.DataKey("CveChofer"))
End Sub
Protected Sub RemoveContrato(sender As Object, e As EventArgs)
Dim GvRow As GridViewRow = DirectCast(DirectCast(sender, LinkButton).NamingContainer, GridViewRow)
@@ -169,7 +146,6 @@ Partial Class ListadoContratos
CargaDatos()
End If
ObjContratos.Dispose()
End Sub
Protected Sub LBExcel_Click(sender As Object, e As EventArgs) Handles LBExcel.Click

View File

@@ -5,6 +5,11 @@
<asp:Content ID="Content1" ContentPlaceHolderID="Css" runat="Server">
<style type="text/css">
.tipo_vista {
display: flex;
align-items: center;
gap: 2rem;
}
</style>
</asp:Content>
@@ -12,24 +17,263 @@
Calendario de contratos
</asp:Content>
<asp:Content ID="Content3" ContentPlaceHolderID="H" runat="Server">
</asp:Content>
<asp:Content ID="Content4" ContentPlaceHolderID="C" runat="Server">
<div class="row">
<div class="col-md-12 col-sm-12">
<div class="portlet light calendar ">
<div class="portlet-title ">
<div class="caption">
<i class="icon-calendar font-green-sharp"></i>
<span class="caption-subject font-green-sharp bold uppercase">Contratos</span>
</div>
</div>
<asp:Panel ID="PnlGeneral" runat="server">
<ContentTemplate>
<%--Calendario Tab--%>
<ajax:TabContainer ID="Tab" runat="server" Width="100%" ActiveTabIndex="0">
<div class="portlet-body">
<div id="calendar">
<ajax:TabPanel ID="TabAlta" runat="server" HeaderText="Calendario"> <asp:UpdatePanel ID="UpDatos" runat="server" UpdateMode="Conditional">
<ContentTemplate>
<div class="row">
<div class="col-md-12 col-sm-12">
<div class="portlet light calendar ">
<div class="tipo_vista">
<div>
<h4 class="bold ribbon-color-success">Tipo de Vista</h4>
</div>
<asp:RadioButtonList ID="RBTipoVista" runat="server" AutoPostBack="True">
<asp:ListItem Text="Duración" Value="duracion" Selected="True" />
<asp:ListItem Text="Fecha de Inicio" Value="fecha" />
</asp:RadioButtonList>
</div>
<div class="portlet-body">
<div id="calendar">
</div>
</div>
</div>
</div>
</div>
</ContentTemplate>
</ajax:TabPanel>
<%--Contratos Tab--%>
<ajax:TabPanel ID="TabPanel1" runat="server" HeaderText="Contratos">
<ContentTemplate>
<asp:GridView ID="GvContratos" runat="server" AutoGenerateColumns="false" EmptyDataText="No se Encontró Contrato Registrado"
CssClass="table table-striped table-hover Widthall ScrollAD mysmallbtn" GridLines="None"
data-sort="true" DataKeyNames="CveContrato, DescripcionContrato, Ubicacion, FechaInicial, FechaFinal, CveCliente, CveTipoAF, Importe, ImporteMin, ImporteMax ">
<Columns>
<asp:TemplateField HeaderText="No. Contrato">
<ItemTemplate>
<asp:Literal ID="LtlCveContrato" runat="server" Text='<%# Eval("CveContrato") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Descripcion">
<ItemTemplate>
<asp:Literal ID="LtlDescripcionContrato" runat="server" Text='<%# Eval("DescripcionContrato") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-HorizontalAlign="Center" HeaderText="Ubicación">
<ItemTemplate>
<asp:Literal ID="LtUbicacion" runat="server" Text='<%# Eval("Ubicacion") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-HorizontalAlign="Center" HeaderText="Cliente">
<ItemTemplate>
<asp:Literal ID="LtNombreComercial" runat="server" Text='<%# Eval("NombreComercial") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField ItemStyle-HorizontalAlign="Center" ItemStyle-Width="100px">
<HeaderTemplate>
Fecha<br />
Salida
</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlFechaIng" runat="server" Text='<%# Eval("FechaInicial", "{0:d}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
<asp:TemplateField HeaderText="Fecha Final" ItemStyle-HorizontalAlign="Center" ItemStyle-Width="100px">
<HeaderTemplate>
Fecha<br />
Regreso
</HeaderTemplate>
<ItemTemplate>
<asp:Literal ID="LtlFechaFinal" runat="server" Text='<%# Eval("FechaFinal", "{0:d}") %>'></asp:Literal>
</ItemTemplate>
</asp:TemplateField>
</Columns>
</asp:GridView>
</ContentTemplate>
</ajax:TabPanel>
</ajax:TabContainer>
</ContentTemplate>
</asp:UpdatePanel>
</asp:Panel>
<div id="ModalAgregar" class="modal ADS fade" role="dialog">
<div class="modal-dialog">
<div id="UpAddChofer" class="modal-content rowpadding" tabindex="-1"
runat="server">
<contenttemplate>
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-label="Close">
<span aria-hidden="true">&times;</span>
</button>
<h4 class="modal-title" id="myModalLabel" runat="server">Agregar Contrato</h4>
</div>
</div>
<div class="modal-body">
<div class="portlet-body">
<div class="row my-1" id="TrCliente" runat="server">
<label class="col-md-4 bold">
<asp:Label ID="Label1" runat="server" Text="Cliente:"></asp:Label></label><div class="col-md-8">
<ADS:Dropdownlost CssClassDdl="select2me" ID="DdlClientes" Width="100%" data-metodo="getcliente"
runat="server" DataTextField="NombreComercial" DataValueField="CveCliente" CssStyle="width: 100%;"
UsaWebService="true"></ADS:Dropdownlost>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Servicio:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtDescripcion" runat="server" MaxLength="70" Width="100%"
TextMode="MultiLine"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVDescripcion" runat="server" ControlToValidate="TxtDescripcion"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Descripcion''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEDescripcion" runat="server" HighlightCssClass="vco"
TargetControlID="RFVDescripcion" Width="100%" BehaviorID="_content_VCEDescripcion">
</ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row">
<label class="col-md-4 bold">Lugar de Salida:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtUbicacion" runat="server" MaxLength="70" Width="100%"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVUbicacion" runat="server" ControlToValidate="TxtUbicacion"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Ubicación''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEUbicacion" runat="server" HighlightCssClass="vco"
TargetControlID="RFVUbicacion" Width="100%" BehaviorID="_content_VCEUbicacion">
</ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Fecha Salida:</label>
<div class="col-md-8">
<div class="input-group input-sm input-small date date-picker">
<asp:TextBox ID="TxtFechaSalida" runat="server" CssClass="form-control" CausesValidation="True"
type="datetime-local"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVTxtFechaSalida" runat="server" ControlToValidate="TxtFechaSalida"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Salida''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCETxtFechaSalida" runat="server" HighlightCssClass="vco"
TargetControlID="RFVTxtFechaSalida" Width="100%" BehaviorID="_content_VCETxtFechaSalida">
</ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Fecha Regreso:</label>
<div class="col-md-8">
<div class="input-group input-sm input-small date date-picker">
<asp:TextBox ID="TxtFechaRegreso" runat="server" CssClass="form-control" CausesValidation="True"
type="datetime-local"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVTxtFechaRegreso" runat="server" ControlToValidate="TxtFechaRegreso"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Fecha Regreso''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="ValidatorCalloutExtender1" runat="server" HighlightCssClass="vco"
TargetControlID="RFVTxtFechaRegreso" Width="100%" BehaviorID="_content_VCETxtFechaRegreso">
</ajax:ValidatorCalloutExtender>
</div>
</div>
</div>
<div class="row margin-bottom-5" id="TrAF" runat="server">
<label class="col-md-4 bold">
<asp:Label runat="server" Text="Transporte:"></asp:Label></label><div
class="col-md-8">
<asp:DropDownList ID="DdlTransporte" AppendDataBoundItems="true" DataTextField="Descripcion"
DataValueField="CveTipoActivoFijo" Class="table-group-action-input form-control input-inline text-center"
Width="200px" runat="server">
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVTransporte" runat="server" ControlToValidate="DdlTransporte"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Transporte''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCETransporte" runat="server" HighlightCssClass="vco"
TargetControlID="RFVTransporte" Width="400px" BehaviorID="_content_VCETransporte">
</ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row margin-bottom-5" id="TrChofer" runat="server">
<label class="col-md-4 bold">
<asp:Label runat="server" Text="Chofer:"></asp:Label></label><div
class="col-md-8">
<asp:DropDownList ID="DdlChofer" AppendDataBoundItems="true" DataValueField="CvePersonal"
DataTextField="NombreCompleto" Class="table-group-action-input form-control input-inline text-center"
Width="200px" runat="server">
</asp:DropDownList>
<asp:RequiredFieldValidator ID="RFVChofer" runat="server" ControlToValidate="DdlChofer"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Chofer''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEChofer" runat="server" HighlightCssClass="vco"
TargetControlID="RFVChofer" Width="400px" BehaviorID="_content_VCEChofer">
</ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Observaciones:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtObservaciones" runat="server" MaxLength="70" Width="100%"
TextMode="MultiLine"></asp:TextBox>
<asp:RequiredFieldValidator ID="RFVObservaciones" runat="server" ControlToValidate="TxtObservaciones"
Display="None" ErrorMessage="<b><span style='text-decoration: underline'>ERROR:</span></b><br />El campo <b>''Descripcion''</b> es necesario, por favor ingréselo."
ValidationGroup="GrpGuardar"></asp:RequiredFieldValidator>
<ajax:ValidatorCalloutExtender ID="VCEObservaciones" runat="server" HighlightCssClass="vco"
TargetControlID="RFVObservaciones" Width="100%" BehaviorID="_content_VCEObservaciones">
</ajax:ValidatorCalloutExtender>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Costo dólares:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtDolares" runat="server" type="number"></asp:TextBox>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Costo pesos:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtPesos" runat="server" type="number"></asp:TextBox>
</div>
</div>
<div class="row my-1">
<label class="col-md-4 bold">Anticipo:</label>
<div class="col-md-8">
<asp:TextBox ID="TxtAnticipo" runat="server" type="decimal"></asp:TextBox>
</div>
</div>
</div>
</div>
</contenttemplate>
</div>
</div>
</div>
@@ -146,14 +390,15 @@
selectHelper: true,
select: selectDate,
editable: true,
minTime: "08:00:00",
maxTime: "19:00:00",
minTime: "00:00:00",
maxTime: "24:00:00",
events: {
url: '/Ashx/CargaEventos.ashx',
type: 'GET',
data: {
U: ' <%= UsuarioActual.CveUsuario %>',
E: '<%= UsuarioActual.CveEmpresa %>',
tipoVista: '<%= RBTipoVista.Text %>',
METODO: 'contrato_transportes',
CveUsuarioPara: $('#DdlTecnico').val(),
CveSubProyecto: $('#DdlSubProyecto').val()
@@ -164,6 +409,7 @@
});
clickSemana();
}
</script>

View File

@@ -11,11 +11,27 @@ Partial Class RepContratosCalendario
Protected Sub Page_Load(sender As Object, e As System.EventArgs) Handles Me.Load
If Not IsPostBack Then
InicializaCalendar()
CargaDatos()
End If
InicializaCalendar()
End Sub
Private Sub CargaDatos()
Dim ObjContratos As New ClsContratos
If ObjContratos.GetContratos(-1, UsuarioActual.CveEmpresa, TipoContrato:=2) Then
GvContratos.DataSource = ObjContratos.DtResultados
End If
ObjContratos.Dispose()
GvContratos.DataBind()
End Sub
Private Sub InicializaCalendar()
RegistraScript("InitCalendar();")
DirectCast(Master.FindControl("TSM"), ScriptManager).EnablePageMethods = True
End Sub
End Class

View File

@@ -23,14 +23,6 @@
<li>
<asp:LinkButton ID="LBAgregarViaje" runat="server"><i class='fa fa-plus'></i>Agregar viaje</asp:LinkButton>
</li>
<%-- <li>
<asp:HyperLink ID="LBListadoContratos" runat="server" NavigateUrl="ListadoContratos.aspx"
Target="_blank"><i class='fa fa-file'></i>Contratos</asp:HyperLink>
</li>
<li>
<asp:HyperLink ID="LBListadoViajes" runat="server" NavigateUrl="ListadoViajes.aspx"
Target="_blank"><i class='fa fa-road'></i>Viajes</asp:HyperLink>
</li>--%>
</contenttemplate>
</asp:Content>

View File

@@ -4144,7 +4144,6 @@
<asp:UpdatePanel ID="UpFacturar" runat="server" class="portlet light xspadding bordered " style="max-width: 300px;" align="right" UpdateMode="Conditional">
<Triggers>
<asp:PostBackTrigger ControlID="BtnVistaPrevia" />
<asp:PostBackTrigger ControlID="LBVistaPrevia" />
</Triggers>
<ContentTemplate>
@@ -4186,9 +4185,6 @@
Facturar <i class="fa fa-angle-down"></i>
</button>
<ul class="dropdown-menu">
<li>
<asp:LinkButton ID="LBVistaPrevia" Text="Vista Previa" OnClick="LBVistaPrevia_Click" runat="server" Visible="false" />
</li>
<li>
<asp:LinkButton ID="LBFacturarIngreso" Text="Ingreso" OnClick="LBFacturarIngreso_Click" runat="server" data-toggle="confirmation" data-popout="true" data-original-title="¿Seguro que desea facturar como tipo ingreso?" data-btn-ok-label="si" />
</li>

View File

@@ -2599,7 +2599,6 @@ Partial Class Ventas
CargaMedicos()
CargaProcedimientos()
CargaDdlClientesSucursal()
LBVistaPrevia.Visible = True
End If
@@ -5662,6 +5661,10 @@ Partial Class Ventas
ChkConvertirDoctoPesos.Enabled = Not UsuarioActual.TienePermisoProceso(324)
TxtTipoCambio.Enabled = True
End If
If UsuarioActual.Empresa.Funcionalidad(578) = "1" Then
TrVistaPrevia.Visible = True
End If
End If
'Si es Empresa de Acumuladores
@@ -15590,7 +15593,12 @@ Partial Class Ventas
Exit Sub
End If
CreaObjetosVenta(True)
Dim TipoDoctoVistaPrevia As String = ""
If CveVenta > 0 AndAlso DdlTipoComprobante.SelectedValue = "Rem" AndAlso BtnsFacturar.Visible = True Then
TipoDoctoVistaPrevia = "Ing"
End If
CreaObjetosVenta(True, TipoDoctoVistaPrevia:=TipoDoctoVistaPrevia)
If ObjFactura Is Nothing Or (ObjFactura.Cliente Is Nothing And Not CveEmpresaCRM > 0) Then
Alert("Ocurrió un error al procesar los datos para la vista previa. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgError)
@@ -36730,18 +36738,5 @@ Partial Class Ventas
CargaAnticipos(CveCliente)
End Sub
Protected Sub LBVistaPrevia_Click(sender As Object, e As EventArgs)
CreaObjetosVenta(True, TipoDoctoVistaPrevia:="Ing")
If ObjFactura Is Nothing Or (ObjFactura.Cliente Is Nothing And Not CveEmpresaCRM > 0) Then
Alert("Ocurrió un error al procesar los datos para la vista previa. Por favor rectifique y vuelva a intentar.", TipoMensaje.MsgError)
ObjFactura = Nothing
Exit Sub
End If
Dim CartaPorte As Modelos.MSubReportData = Nothing
ImprimirbytesPDF(PdfFactura(ObjFactura, Guardar:=False, SubReportData:=CartaPorte), "Factura", "PDF")
End Sub
End Class