示例#1
0
        public NeedsAdd(Needs owner)
        {
            InitializeComponent();
            _needs             = owner;
            FormClosing       += NeedsAdd_FormClosing;
            _needsApiClient    = new NeedsApiClient();
            _clientApiClient   = new ClientApiClient();
            _realtorApiClient  = new RealtorApiClient();
            _realtiesApiClient = new RealtiesApiClient();

            List <ClientEntity> clientEntities = _clientApiClient.GetClients();

            client.DataSource    = clientEntities;
            client.DisplayMember = "GetInitials";
            client.ValueMember   = "id";

            List <RealtorEntity> realtorEntities = _realtorApiClient.GetRealtors();

            realtor.DataSource    = realtorEntities;
            realtor.DisplayMember = "GetInitials";
            realtor.ValueMember   = "id";


            List <RealtyTypeEntity> realtyTypeEntities = _realtiesApiClient.GetTypes();

            type.DataSource    = realtyTypeEntities;
            type.DisplayMember = "Name";
            type.ValueMember   = "Id";
        }
示例#2
0
        public Needs()
        {
            InitializeComponent();
            _needsApiClient = new NeedsApiClient();
            dt = new DataTable();
            AddColumns();
            _clientApiClient   = new ClientApiClient();
            _realtorApiClient  = new RealtorApiClient();
            _realtiesApiClient = new RealtiesApiClient();

            InitCombos();
        }
示例#3
0
        public DealsAdd(Deals owner)
        {
            InitializeComponent();
            _dealsApiClient = new DealsApiClient();
            _dealsForm      = owner;
            FormClosing    += DealsAdd_FormClosing;

            _offerApiClient = new OffersApiClient();
            _needApiClient  = new NeedsApiClient();

            offersEntities      = _offerApiClient.GetOffers();
            offer.DataSource    = offersEntities;
            offer.DisplayMember = "GetOffer";
            offer.ValueMember   = "id";

            needsEntities      = _needApiClient.GetNeeds();
            need.DataSource    = needsEntities;
            need.DisplayMember = "GetNeed";
            need.ValueMember   = "id";
        }
示例#4
0
        public Deals()
        {
            InitializeComponent();
            _dealsApiClient = new DealsApiClient();
            dt = new DataTable();
            AddColumns();
            _offerApiClient = new OffersApiClient();
            _needApiClient  = new NeedsApiClient();

            List <OfferEntity> offersEntities = _offerApiClient.GetOffers();

            offer.DataSource    = offersEntities;
            offer.DisplayMember = "GetOffer";
            offer.ValueMember   = "id";

            List <NeedsEntity> needsEntities = _needApiClient.GetNeeds();

            need.DataSource    = needsEntities;
            need.DisplayMember = "GetNeed";
            need.ValueMember   = "id";
        }