private void InitializeControlControls()
        {
            if (LicenseManager.UsageMode != LicenseUsageMode.Designtime)
            {
                ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

                this.controlCustomerInfrastructurePersonalComputers.cbcComputerBrand.Parameters = pmtComputerBrand;
                this.controlCustomerInfrastructurePersonalComputers.cbcComputerBrand.Refresh();

                PersonalComputerTypeParameters pmtPersonalComputerType = new PersonalComputerTypeParameters();

                this.controlCustomerInfrastructurePersonalComputers.pctcPersonalComputerType.Parameters = pmtPersonalComputerType;
                this.controlCustomerInfrastructurePersonalComputers.pctcPersonalComputerType.Refresh();

                OperativeSystemParameters pmtOperativeSystem = new OperativeSystemParameters();

                this.controlCustomerInfrastructurePersonalComputers.oscOperativeSystem.Parameters = pmtOperativeSystem;
                this.controlCustomerInfrastructurePersonalComputers.oscOperativeSystem.Refresh();

                this.controlCustomerInfrastructurePersonalComputers.cipcccCustomerInfrastructurePersonalComputerClassification
                .Parameters = new CustomerInfrastructurePersonalComputerClassificationParameters();
                this.controlCustomerInfrastructurePersonalComputers.cipcccCustomerInfrastructurePersonalComputerClassification
                .Refresh();

                this.controlCustomerInfrastructurePersonalComputers
                .cipcccCustomerInfrastructurePersonalComputerClassification.ValueChanged
                    += new SamsaraEntityChooserValueChangedEventHandler <
                           CustomerInfrastructurePersonalComputerClassification>
                           (cipcccCustomerInfrastructurePersonalComputerClassification_ValueChanged);

                this.controlCustomerInfrastructurePersonalComputers.grdRelations.InitializeLayout
                    += new InitializeLayoutEventHandler(grdRelations_InitializeLayout);
            }
        }
        private void grdRelations_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            UltraGridBand band = e.Layout.Bands[0];

            band.Override.AllowUpdate = DefaultableBoolean.False;

            ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

            IList <ComputerBrand> cctvBrands = this.srvComputerBrand.GetListByParameters(pmtComputerBrand);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvBrands,
                                                   band.Columns["ComputerBrandId"], "ComputerBrandId", "Name", "Seleccione");

            OperativeSystemParameters pmtOperativeSystem = new OperativeSystemParameters();

            IList <OperativeSystem> cctvOperativeSystems = this.srvOperativeSystem.GetListByParameters(pmtOperativeSystem);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvOperativeSystems,
                                                   band.Columns["OperativeSystemId"], "OperativeSystemId", "Name", "Seleccione");;

            PersonalComputerTypeParameters pmtPersonalComputerType = new PersonalComputerTypeParameters();

            IList <PersonalComputerType> cctvTypes = this.srvPersonalComputerType.GetListByParameters(pmtPersonalComputerType);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvTypes,
                                                   band.Columns["PersonalComputerTypeId"], "PersonalComputerTypeId", "Name", "Seleccione");
        }
        private void grdRelations_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            UltraGridBand band = e.Layout.Bands[0];

            band.Override.AllowUpdate = DefaultableBoolean.False;

            ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

            IList <ComputerBrand> cctvBrands = this.srvComputerBrand.GetListByParameters(pmtComputerBrand);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvBrands,
                                                   band.Columns["ComputerBrandId"], "ComputerBrandId", "Name", "Seleccione");

            OperativeSystemParameters pmtOperativeSystem = new OperativeSystemParameters()
            {
                OperativeSystemTypeId = ParameterConstants.IntDefault
            };

            IList <OperativeSystem> cctvTypes = this.srvOperativeSystem.GetListByParameters(pmtOperativeSystem);

            this.controlCustomerInfrastructureServerComputers.oscOperativeSystem.Parameters = pmtOperativeSystem;
            this.controlCustomerInfrastructureServerComputers.oscOperativeSystem.Refresh();

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvTypes,
                                                   band.Columns["OperativeSystemId"], "OperativeSystemId", "Name", "Seleccione");
        }
        private void Search()
        {
            ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

            pmtComputerBrand.Name = "%" + this.frmComputerBrand.txtSchName.Text + "%";

            DataTable dtComputerBrands = srvComputerBrand.SearchByParameters(pmtComputerBrand);

            this.frmComputerBrand.grdSchSearch.DataSource = null;
            this.frmComputerBrand.grdSchSearch.DataSource = dtComputerBrands;
        }
Ejemplo n.º 5
0
        private void InitializeControlControls()
        {
            if (LicenseManager.UsageMode != LicenseUsageMode.Designtime)
            {
                ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

                this.controlCustomerInfrastructureServerComputers.cbcComputerBrand.Parameters = pmtComputerBrand;
                this.controlCustomerInfrastructureServerComputers.cbcComputerBrand.Refresh();

                OperativeSystemParameters pmtOperativeSystem = new OperativeSystemParameters();

                this.controlCustomerInfrastructureServerComputers.oscOperativeSystem.Parameters = pmtOperativeSystem;
                this.controlCustomerInfrastructureServerComputers.oscOperativeSystem.Refresh();

                this.controlCustomerInfrastructureServerComputers.grdRelations.InitializeLayout
                    += new InitializeLayoutEventHandler(grdRelations_InitializeLayout);
            }
        }
Ejemplo n.º 6
0
        private void grdRelations_InitializeLayout(object sender, InitializeLayoutEventArgs e)
        {
            UltraGridBand band = e.Layout.Bands[0];

            band.Override.AllowUpdate = DefaultableBoolean.False;

            ComputerBrandParameters pmtComputerBrand = new ComputerBrandParameters();

            IList <ComputerBrand> cctvBrands = this.srvComputerBrand.GetListByParameters(pmtComputerBrand);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, cctvBrands,
                                                   band.Columns["ComputerBrandId"], "ComputerBrandId", "Name", "Seleccione");

            OperativeSystemParameters pmtOperativeSystem = new OperativeSystemParameters()
            {
                OperativeSystemTypeId = (int)OperativeSystemTypeEnum.Server
            };

            IList <OperativeSystem> operativeSystemTypes = this.srvOperativeSystem.GetListByParameters(pmtOperativeSystem);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, operativeSystemTypes,
                                                   band.Columns["OperativeSystemId"], "OperativeSystemId", "Name", "Seleccione");

            ServerComputerTypeParameters pmtServerComputerType = new ServerComputerTypeParameters();

            IList <ServerComputerType> serverComputerTypes = this.srvServerComputerType.GetListByParameters(pmtServerComputerType);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, serverComputerTypes,
                                                   band.Columns["ServerComputerTypeId"], "ServerComputerTypeId", "Name", "Seleccione");

            RackTypeParameters pmtRackType = new RackTypeParameters();

            IList <RackType> rackTypes = this.srvRackType.GetListByParameters(pmtRackType);

            WindowsFormsUtil.SetUltraGridValueList(e.Layout, rackTypes,
                                                   band.Columns["RackTypeId"], "RackTypeId", "Name", "Seleccione");
        }