Exemplo n.º 1
0
 public MessageClass(MESSAGES message)
 {
     id          = message.MESSAGE_ID;
     fromUser    = new UserPublicInfoClass(message.FROM_USER_ID);
     title       = message.MESSAGE_SUBJECT;
     status      = message.MESSAGE_TYPE;
     body        = HtmlToText.HtmlToPlainText(message.MESSAGE_CONTENT);
     date        = message.MESSAGE_DATE;
     group       = message.GROUP_ID == null ? null : new GroupClass(message.GROUP_ID);
     subject     = message.SUBJECT_ID == null ? null : new SubjectClass(message.SUBJECT_ID);
     attachments = getAttachments();
 }
Exemplo n.º 2
0
        public CourseClass(COURSES co)
        {
            id      = co.COURSE_ID;
            subject = new SubjectClass(co.SUBJECT_ID);
            if (co.IS_MANUALLY == 0)
            {
                teacher = new UserPublicInfoClass(co.TEACHERS.USERS);
            }
            _class        = new ClassClass(co.CLASSES);
            order_in_week = co.ORDER_IN_WEEK;
            Day d = (Day)co.DAY_OF_THE_WEEK - 1;

            day = d.ToString();
        }