コード例 #1
0
 public function UpdateQuestion(PluginReceptiondesk_ModuleQuestion_EntityQuestion $oQuestion)
 {
     $sql = "UPDATE " . Config::Get('db.table.receptiondesk_questions') . " SET question_category_id=?d,question_date_edit=?,question_text=?,question_text_source=?,answer_text=?,answer_text_source=?,question_publish=?d,answer_date_add=? WHERE question_id=?d;";
     if ($this->oDb->query($sql, $oQuestion->getCategoryId(), $oQuestion->getDateEdit(), $oQuestion->getText(), $oQuestion->getTextSource(), $oQuestion->getAnswerText(), $oQuestion->getAnswerTextSource(), $oQuestion->getPublish(), $oQuestion->getAnswerDateAdd(), $oQuestion->getId()) !== false) {
         return true;
     }
     return false;
 }
コード例 #2
0
ファイル: Tools.class.php プロジェクト: olegverstka/kprf.dev
 public function SendQuestionMail(PluginReceptiondesk_ModuleQuestion_EntityQuestion $oQuestion)
 {
     if (!$oQuestion->getAuthorMail()) {
         return false;
     }
     $sName = $oQuestion->getAuthorName() ? $oQuestion->getAuthorName() : $this->Lang_Get('plugin.receptiondesk.receptiondesk_send_mail_guest');
     $this->SendMail($oQuestion->getAuthorMail(), $sName, 'notify.answer_mail.tpl', $this->Lang_Get('plugin.receptiondesk.receptiondesk_send_mail_title'), array('sUserName' => $sName, 'oQuestion' => $oQuestion));
     return true;
 }