Beispiel #1
0
 protected void edsBinCode_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (!IsPostBack)
     {
         e.Cancel = true;
     }
 }
Beispiel #2
0
    // FuenteDeDatosEDS2 incluye una consulta que da el mismo resultado que la siguiente.

    // Consulta independiente (FuenteDeDatosEDS3)
    protected void FuenteDeDatosEDS3_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
    {
        e.DataSource.Where = "it.id_asignatura == @idAsig && it.id_alumno == @idAlum";
        e.DataSource.WhereParameters.Clear();
        e.DataSource.WhereParameters.Add(new ControlParameter("idAsig", TypeCode.Int32, "lsdAsignatura", "SelectedValue"));
        e.DataSource.WhereParameters.Add(new ControlParameter("idAlum", TypeCode.Int32, "ctDni", "Text"));
    }
Beispiel #3
0
 protected void edsAdministratorPermission_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (Helper.Current.AdministratorRoleCode() != Helper.Constant.CODE_ROLE_DEVELOPER && Helper.Current.AdministratorRoleCode() != Helper.Constant.CODE_ROLE_SUPERADMINISTRATOR)
     {
         edsAdministratorPermission.Where = "it.[IsSelectable]=TRUE";
     }
 }
 protected void EntityDataSourceClasificaciones_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (this.cboTipoParametro.Text == "")
     {
         e.DataSource.Where = "";
         e.DataSource.AutoGenerateWhereClause = true;
     }
 }
        protected void eds_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
        {
            string templateid = GetTemplateId();

            eds.WhereParameters.Clear();
            eds.Where = "it.ServiceTemplateCrmEvolutionId= @TemplateId";
            eds.WhereParameters.Add(new Parameter("TemplateId", TypeCode.Int32, templateid));
        }
Beispiel #6
0
 protected void EntityDataSourceEmpresas_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (this.txtApellidoLegajo.Text == string.Empty)
     {
         e.DataSource.Where = "";
         e.DataSource.AutoGenerateWhereClause = true;
     }
 }
Beispiel #7
0
        protected void eds_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
        {
            string serviceid = Request.QueryString["serviceid"].ToString();

            eds.WhereParameters.Clear();
            eds.Where = "it.ServiceId = @ServiceId";
            eds.WhereParameters.Add(new Parameter("ServiceId", TypeCode.Int32, serviceid.ToString()));
        }
        protected void eds_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
        {
            string logid = GetLogId();

            eds.WhereParameters.Clear();
            eds.Where = "it.SyncLogCrmEvolutionId= @LogId";
            eds.WhereParameters.Add(new Parameter("LogId", TypeCode.Int32, logid));
        }
 protected void EntityDataSource1_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (this.ParentID != -1)
     {
         if (e.DataSource.Where != string.Empty)
         {
             e.DataSource.Where += " AND ";
         }
         EntityDataSource1.Where = "it.TaskID = " + this.ParentID.ToString();
     }
 }
Beispiel #10
0
 protected void edsMovPorCuenta_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     if (idCuentaBancariaActual() == 0)
     {
         e.Cancel = true;
     }
     else
     {
         var idCtaxBco = idCuentaBancariaActual();
         e.DataSource.WhereParameters["fechaInicio"].DefaultValue = deFechaInicio.Date.Date.ToString();
         e.DataSource.WhereParameters["fechaFin"].DefaultValue    = deFechaFin.Date.Date.AddDays(1).AddMilliseconds(-1).ToString();
         e.DataSource.Where = "it.IdCtaxBco = " + idCtaxBco
                              + " AND it.dFecOpe >= @fechaInicio AND it.dFecOpe <= @fechaFin AND it.cEstado = 'A'";
         e.DataSource.OrderBy = "it.dFecOpe Desc, it.IdMovCtaxBco Desc";
     }
 }
Beispiel #11
0
 void edcEvents_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     e.Cancel = CheckEmptySearch(RepertoireSearchPanel);
 }
 protected void EDS_proyecto_vs_poblacion_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }
Beispiel #13
0
 private void edcEvents_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     e.Cancel = CheckEmptySearch(basicPanel) && CheckEmptySearch(advancedPanel);
 }
 private void edcArtists_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     e.Cancel = CheckEmptySearch(ArtistSearchPanel);
 }
			/// <summary>
			/// Gets a list of data from the underlying data storage.
			/// </summary>
			/// <param name="arguments">A System.Web.UI.DataSourceSelectArguments that
			/// is used to request operations on the data beyond basic data retrieval.</param>
			/// <returns>An System.Collections.IEnumerable list of data from the underlying data storage.</returns>
			protected override IEnumerable ExecuteSelect(DataSourceSelectArguments arguments)
			{
				arguments.RaiseUnsupportedCapabilitiesError(this);
				IEnumerable entityList = null;

				Hashtable param = new Hashtable();
				Object entityId = GetEntityId();

				if ( entityId != null )
				{
					String key = EntityKeyName ?? EntityDataSource.EntityIdParameterName;
					param.Add(key, entityId);
				}

				EntityDataSourceSelectingEventArgs eventArgs = new EntityDataSourceSelectingEventArgs(param, arguments);
				OnSelecting(eventArgs);

				if ( eventArgs.Cancel )
				{
					return null;
				}

				try
				{
					entityList = GetEntityList(arguments);

					if ( entityList != null )
					{
						IList list = EntityUtil.GetEntityList(entityList);

						// make sure we have a valid TotalRowCount
						if ( arguments.TotalRowCount < 1 )
						{
							arguments.TotalRowCount = list.Count;
						}

						UpdateEntityId(entityList);
						OnSelected(new EntityDataSourceMethodEventArgs(entityList, EntityIndex, param, arguments.TotalRowCount));

						if ( arguments.TotalRowCount > 0 && list.Count > 0 )
						{
							// raise linked event
							OnAfterSelected(new LinkedDataSourceEventArgs(list[EntityIndex], _owner.GetParameterValueMap(), EntityIndex));
						}
					}
				}
				catch ( Exception ex )
				{
					EntityDataSourceMethodEventArgs e = new EntityDataSourceMethodEventArgs(entityList, EntityIndex, param, 0, ex);
					OnSelected(e);

					if ( !e.ExceptionHandled )
					{
						throw;
					}
				}

				return entityList;
			}
			/// <summary>
			/// Raises the EntityDataSource.Selecting event.
			/// </summary>
			/// <param name="args">An instance of EntityDataSourceSelectingEventArgs containing the event data.</param>
			internal void OnSelecting(EntityDataSourceSelectingEventArgs args)
			{
				if ( _owner.Selecting != null )
				{
					_owner.Selecting(_owner, args);
				}
			}
Beispiel #17
0
 protected void EntityDataSourceCountries_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }
Beispiel #18
0
 protected void edsCuentasBancarias_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     e.DataSource.Where          = "it.cEstado = 'A'";
     edsCuentasBancarias.Include = "TTipIns";
 }
 protected void EDS_municipio_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }
 protected void eds_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }
Beispiel #21
0
 protected void EntityDataSource1_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
     WriteMessage();
 }
 protected void EntityDataSourceCustomers_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }
 protected void DatosFuente_Selecting(object sender, EntityDataSourceSelectingEventArgs e)
 {
 }