Пример #1
0
 public void setInfor(Question question, String commentId, FAQSetting faqSetting, String language)
     throws Exception {
   if (!language.equals(question.getLanguage())) {
     try {
       QuestionLanguage questionLanguage =
           getFAQService().getQuestionLanguageByLanguage(question.getPath(), language);
       this.questionContent = questionLanguage.getQuestion();
       this.questionDetail = questionLanguage.getDetail();
       languageSelected = language;
     } catch (Exception e) {
       this.questionContent = question.getQuestion();
       this.questionDetail = question.getDetail();
       languageSelected = question.getLanguage();
     }
   } else {
     this.questionContent = question.getQuestion();
     this.questionDetail = question.getDetail();
     languageSelected = question.getLanguage();
   }
   this.question_ = question;
   this.faqSetting_ = faqSetting;
   FAQUtils.getEmailSetting(faqSetting_, false, false);
   if (commentId.indexOf("new") < 0) {
     comment = getFAQService().getCommentById(question.getPath(), commentId, language);
     ((UIFormWYSIWYGInput) this.getChildById(COMMENT_CONTENT)).setValue(comment.getComments());
   }
 }