Ejemplo n.º 1
0
        /// <summary>
        /// Remove the rep participant.
        /// </summary>
        /// <param name="participant">The participant.</param>
        public void RemoveRepParticipant(UPCRMRepParticipant participant)
        {
            participant.Context = this;

            if (this.mutableRepParticipantArray.Contains(participant))
            {
                this.mutableRepParticipantArray.Remove(participant);
            }
        }
Ejemplo n.º 2
0
        /// <summary>
        /// Adds the rep participant with rep identifier.
        /// </summary>
        /// <param name="repId">The rep identifier.</param>
        /// <param name="options">The options.</param>
        /// <returns></returns>
        public UPCRMRepParticipant AddRepParticipantWithRepId(string repId, Dictionary <string, object> options)
        {
            UPCRMRepParticipant repParticipant = new UPCRMRepParticipant(repId);

            repParticipant.Options = options;
            this.AddRepParticipant(repParticipant);

            return(repParticipant);
        }
Ejemplo n.º 3
0
        /// <summary>
        /// Adds the rep participant.
        /// </summary>
        /// <param name="participant">The participant.</param>
        public void AddRepParticipant(UPCRMRepParticipant participant)
        {
            participant.Context = this;

            if (this.mutableRepParticipantArray == null)
            {
                this.mutableRepParticipantArray = new List <UPCRMRepParticipant>();
            }

            this.mutableRepParticipantArray.Add(participant);
        }
Ejemplo n.º 4
0
        /// <summary>
        /// Adds the new rep participant.
        /// </summary>
        /// <returns></returns>
        public UPCRMRepParticipant AddNewRepParticipant()
        {
            UPCRMRepParticipant participant = new UPCRMRepParticipant("rep_" + this.NextKey())
            {
                AcceptanceText  = "0",
                RequirementText = "0",
                Context         = this
            };

            this.AddRepParticipant(participant);

            return(participant);
        }