models/communities/MemberStatus.js

/** @class MemberStatus */
export default class MemberStatus {
    /**
     * Return name for a given status
     *
     * @memberof MemberStatus
     * @returns {string} Status name
     */
    static valueToName(value) {
        switch (value) {
        case MemberStatus.ApprovalPending:
            return 'approval pending';
        case MemberStatus.InvitationPending:
            return 'invitation pending';
        case MemberStatus.Member:
            return 'member';
        case MemberStatus.Rejected:
            return 'rejected';
        }
    }
}

/**
 * User is not approved yet
 * @memberof MemberStatus
 */
MemberStatus.ApprovalPending = 0;
/**
 * User has not accepted the invitation yet
 * @memberof MemberStatus
 */
MemberStatus.InvitationPending = 1;
/**
 * Member
 * @memberof MemberStatus
 */
MemberStatus.Member = 2;
/**
 * Rejected
 * @memberof MemberStatus
 */
 MemberStatus.Rejected = 3;