Exemplo n.º 1
0
        private void bindDropDownLists()
        {
            #region Bind General Child Data

            #endregion

            #region Bind Contact Child Data

            msContact.Items.Add(new ListItem("Null", "Null"));
            GreyFoxContactManager    contactManager    = new GreyFoxContactManager("kitTessen_SeminarRegistrations_Contacts");
            GreyFoxContactCollection contactCollection = contactManager.GetCollection(string.Empty, string.Empty);
            foreach (GreyFoxContact contact in contactCollection)
            {
                ListItem i = new ListItem(contact.ToString(), contact.ID.ToString());
                msContact.Items.Add(i);
            }

            #endregion

            #region Bind Rappahanock Child Data

            msCustomer.Items.Add(new ListItem("Null", "Null"));
            RHCustomerManager    customerManager    = new RHCustomerManager();
            RHCustomerCollection customerCollection = customerManager.GetCollection(string.Empty, string.Empty, null);
            foreach (RHCustomer customer in customerCollection)
            {
                ListItem i = new ListItem(customer.ToString(), customer.ID.ToString());
                msCustomer.Items.Add(i);
            }

            msInvoiceLine.Items.Add(new ListItem("Null", "Null"));
            RHInvoiceLineManager    invoiceLineManager    = new RHInvoiceLineManager();
            RHInvoiceLineCollection invoiceLineCollection = invoiceLineManager.GetCollection(string.Empty, string.Empty, null);
            foreach (RHInvoiceLine invoiceLine in invoiceLineCollection)
            {
                ListItem i = new ListItem(invoiceLine.ToString(), invoiceLine.ID.ToString());
                msInvoiceLine.Items.Add(i);
            }

            msSalesOrderLine.Items.Add(new ListItem("Null", "Null"));
            RHSalesOrderLineManager    salesOrderLineManager    = new RHSalesOrderLineManager();
            RHSalesOrderLineCollection salesOrderLineCollection = salesOrderLineManager.GetCollection(string.Empty, string.Empty, null);
            foreach (RHSalesOrderLine salesOrderLine in salesOrderLineCollection)
            {
                ListItem i = new ListItem(salesOrderLine.ToString(), salesOrderLine.ID.ToString());
                msSalesOrderLine.Items.Add(i);
            }

            #endregion
        }
Exemplo n.º 2
0
        private void bindDropDownLists()
        {
            #region Bind General Child Data

            msMemberType.Items.Add(new ListItem("Null", "Null"));
            DojoMemberTypeManager    memberTypeManager    = new DojoMemberTypeManager();
            DojoMemberTypeCollection memberTypeCollection = memberTypeManager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMemberType memberType in memberTypeCollection)
            {
                ListItem i = new ListItem(memberType.ToString(), memberType.ID.ToString());
                msMemberType.Items.Add(i);
            }

            msPublicContact.Items.Add(new ListItem("Null", "Null"));
            GreyFoxContactManager    publicContactManager    = new GreyFoxContactManager("kitTessen_Members_PublicContacts");
            GreyFoxContactCollection publicContactCollection = publicContactManager.GetCollection(string.Empty, string.Empty);
            foreach (GreyFoxContact publicContact in publicContactCollection)
            {
                ListItem i = new ListItem(publicContact.ToString(), publicContact.ID.ToString());
                msPublicContact.Items.Add(i);
            }

            msParentMember.Items.Add(new ListItem("Null", "Null"));
            DojoMemberManager    parentMemberManager    = new DojoMemberManager();
            DojoMemberCollection parentMemberCollection = parentMemberManager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMember parentMember in parentMemberCollection)
            {
                ListItem i = new ListItem(parentMember.ToString(), parentMember.ID.ToString());
                msParentMember.Items.Add(i);
            }

            #endregion

            #region Bind Membership Child Data

            msPrimaryOrgMembership.Items.Add(new ListItem("Null", "Null"));
            DojoMembershipManager    primaryOrgMembershipManager    = new DojoMembershipManager();
            DojoMembershipCollection primaryOrgMembershipCollection = primaryOrgMembershipManager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMembership primaryOrgMembership in primaryOrgMembershipCollection)
            {
                ListItem i = new ListItem(primaryOrgMembership.ToString(), primaryOrgMembership.ID.ToString());
                msPrimaryOrgMembership.Items.Add(i);
            }

            msParentOrgMembership.Items.Add(new ListItem("Null", "Null"));
            DojoMembershipManager    parentOrgMembershipManager    = new DojoMembershipManager();
            DojoMembershipCollection parentOrgMembershipCollection = parentOrgMembershipManager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMembership parentOrgMembership in parentOrgMembershipCollection)
            {
                ListItem i = new ListItem(parentOrgMembership.ToString(), parentOrgMembership.ID.ToString());
                msParentOrgMembership.Items.Add(i);
            }

            #endregion

            #region Bind Attendance Child Data

            msInstructor1.Items.Add(new ListItem("Null", "Null"));
            DojoMemberManager    instructor1Manager    = new DojoMemberManager();
            DojoMemberCollection instructor1Collection = instructor1Manager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMember instructor1 in instructor1Collection)
            {
                ListItem i = new ListItem(instructor1.ToString(), instructor1.ID.ToString());
                msInstructor1.Items.Add(i);
            }

            msInstructor2.Items.Add(new ListItem("Null", "Null"));
            DojoMemberManager    instructor2Manager    = new DojoMemberManager();
            DojoMemberCollection instructor2Collection = instructor2Manager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMember instructor2 in instructor2Collection)
            {
                ListItem i = new ListItem(instructor2.ToString(), instructor2.ID.ToString());
                msInstructor2.Items.Add(i);
            }

            msInstructor3.Items.Add(new ListItem("Null", "Null"));
            DojoMemberManager    instructor3Manager    = new DojoMemberManager();
            DojoMemberCollection instructor3Collection = instructor3Manager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoMember instructor3 in instructor3Collection)
            {
                ListItem i = new ListItem(instructor3.ToString(), instructor3.ID.ToString());
                msInstructor3.Items.Add(i);
            }

            #endregion

            #region Bind Activity Child Data

            msPromotionFlags.Items.Add(new ListItem("Null", "Null"));
            DojoPromotionFlagManager    promotionFlagsManager    = new DojoPromotionFlagManager();
            DojoPromotionFlagCollection promotionFlagsCollection = promotionFlagsManager.GetCollection(string.Empty, string.Empty);
            foreach (DojoPromotionFlag promotionFlags in promotionFlagsCollection)
            {
                ListItem i = new ListItem(promotionFlags.ToString(), promotionFlags.ID.ToString());
                msPromotionFlags.Items.Add(i);
            }

            msRank.Items.Add(new ListItem("Null", "Null"));
            DojoRankManager    rankManager    = new DojoRankManager();
            DojoRankCollection rankCollection = rankManager.GetCollection(string.Empty, string.Empty, null);
            foreach (DojoRank rank in rankCollection)
            {
                ListItem i = new ListItem(rank.ToString(), rank.ID.ToString());
                msRank.Items.Add(i);
            }

            #endregion

            #region Bind Security Child Data

            #endregion

            #region Bind Rappahanock Child Data

            msCustomer.Items.Add(new ListItem("Null", "Null"));
            RHCustomerManager    customerManager    = new RHCustomerManager();
            RHCustomerCollection customerCollection = customerManager.GetCollection(string.Empty, string.Empty, null);
            foreach (RHCustomer customer in customerCollection)
            {
                ListItem i = new ListItem(customer.ToString(), customer.ID.ToString());
                msCustomer.Items.Add(i);
            }

            #endregion
        }