增加了元数据评论后使用邮件模板功能发送通知邮件到系统邮箱的功能
This commit is contained in:
parent
7b6a1e1cc6
commit
b95094527b
|
@ -752,6 +752,21 @@ class DataController extends Zend_Controller_Action
|
||||||
|
|
||||||
if($exec)
|
if($exec)
|
||||||
{
|
{
|
||||||
|
@$mailtp=new EmailText(
|
||||||
|
$this->db,
|
||||||
|
'data-comments-posted',
|
||||||
|
array(
|
||||||
|
'user' =>$data['author'],
|
||||||
|
'uuid' =>$data['uuid'],
|
||||||
|
'title' =>$this->replace(trim($this->_request->getParam('mdtitle'))),
|
||||||
|
)
|
||||||
|
);
|
||||||
|
@$mail=new WestdcMailer($this->view->config->smtp);
|
||||||
|
@$mail->setBodyText($mailtp->getBody());
|
||||||
|
@$mail->setFrom($this->view->config->service->email,'WDSCAR Service Team');
|
||||||
|
@$mail->addTo($this->view->config->service->email);
|
||||||
|
@$mail->setSubject($mailtp->getSubject());
|
||||||
|
@$mail->send();
|
||||||
$msg = "用户".$user->username."对元数据《".$this->replace(trim($this->_request->getParam('mdtitle')))."》进行了评论,<a href=\"/admin/data/comment\">点击查看</a>";
|
$msg = "用户".$user->username."对元数据《".$this->replace(trim($this->_request->getParam('mdtitle')))."》进行了评论,<a href=\"/admin/data/comment\">点击查看</a>";
|
||||||
include_once("message.php");
|
include_once("message.php");
|
||||||
message::post($this->db,0,-1,"收到新数据评论",$msg);
|
message::post($this->db,0,-1,"收到新数据评论",$msg);
|
||||||
|
|
Loading…
Reference in New Issue