元数据评审 review 中增加了发表评审意见时发送邮件的功能,修改了html输出顺序

This commit is contained in:
Li Jianxuan 2011-11-15 09:02:42 +00:00
parent 21edc6794c
commit c2c039397c
1 changed files with 2 additions and 3 deletions

View File

@ -325,10 +325,10 @@ class ReviewController extends Zend_Controller_Action
$this->db->exec($sql); $this->db->exec($sql);
} }
echo '<div class="box box-success">保存成功!'; echo '<div class="box box-success">保存成功!';
echo "</div>";
if($data['status']>=0) if($data['status']>=0)
{ {
echo '<script>$("#postcomment").remove();</script>'; echo '<script>$("#postcomment").remove();</script>';
@$mailtp=new EmailText( @$mailtp=new EmailText(
$this->db, $this->db,
"mdreview-post-comment", "mdreview-post-comment",
@ -349,12 +349,11 @@ class ReviewController extends Zend_Controller_Action
}else }else
{ {
@$mail->addTo($email); //元数据作者 @$mail->addTo($email); //元数据作者
@$mail->addCc(); //管理员 @$mail->addCc($email); //管理员
} }
@$mail->setSubject($subject); @$mail->setSubject($subject);
@$mail->send(); @$mail->send();
} }
echo "</div>";
exit(); exit();
}catch(Exception $e){ }catch(Exception $e){
echo '<div class="box box-error">保存出错,请稍后再试!</div>'; echo '<div class="box box-error">保存出错,请稍后再试!</div>';