comment out email
This commit is contained in:
parent
dd7b94eecd
commit
0952b7e506
|
@ -1882,47 +1882,47 @@ class AuthorController extends Zend_Controller_Action
|
||||||
$this->db->query($sql,array($u_id,$id));
|
$this->db->query($sql,array($u_id,$id));
|
||||||
|
|
||||||
//email to admin
|
//email to admin
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"metadata-new-admin",array(
|
// $mailtp=new EmailText($this->db,"metadata-new-admin",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $iso->uuid,
|
// 'uuid' => $iso->uuid,
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $iso->resTitle,
|
// 'title'=> $iso->resTitle,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($this->view->config->service->email);
|
// $mail->addTo($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
$mail->send();
|
// $mail->send();
|
||||||
|
|
||||||
unset($mail);
|
unset($mail);
|
||||||
unset($mailtp);
|
unset($mailtp);
|
||||||
//email to author
|
//email to author
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"metadata-new-author",array(
|
// $mailtp=new EmailText($this->db,"metadata-new-author",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $iso->uuid,
|
// 'uuid' => $iso->uuid,
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $iso->resTitle,
|
// 'title'=> $iso->resTitle,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($user->email);
|
// $mail->addTo($user->email);
|
||||||
$mail->addCc($this->view->config->service->email);
|
// $mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交,请等待数据中心进一步处理!'));
|
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交,请等待数据中心进一步处理!'));
|
||||||
$this->jsonexit($data);
|
$this->jsonexit($data);
|
||||||
|
@ -1947,26 +1947,26 @@ class AuthorController extends Zend_Controller_Action
|
||||||
$this->db->query($sql,array($u_id,$id));
|
$this->db->query($sql,array($u_id,$id));
|
||||||
|
|
||||||
//email to admin & author
|
//email to admin & author
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"metadata-release",array(
|
// $mailtp=new EmailText($this->db,"metadata-release",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
'changelog'=>$changelog,
|
// 'changelog'=>$changelog,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($this->view->config->service->email);
|
// $mail->addTo($this->view->config->service->email);
|
||||||
//$mail->addCc($this->view->config->service->email);
|
// //$mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功发布!'));
|
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功发布!'));
|
||||||
$this->jsonexit($data);
|
$this->jsonexit($data);
|
||||||
|
@ -1987,48 +1987,48 @@ class AuthorController extends Zend_Controller_Action
|
||||||
@$iso->saveDB($this->db);
|
@$iso->saveDB($this->db);
|
||||||
|
|
||||||
//email to admin
|
//email to admin
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"version-commit-admin",array(
|
// $mailtp=new EmailText($this->db,"version-commit-admin",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
'changelog'=>$changelog,
|
// 'changelog'=>$changelog,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($this->view->config->service->email);
|
// $mail->addTo($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
$mail->send();
|
// $mail->send();
|
||||||
|
|
||||||
unset($mail);
|
unset($mail);
|
||||||
unset($mailtp);
|
unset($mailtp);
|
||||||
//email to author
|
//email to author
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"version-commit-author",array(
|
// $mailtp=new EmailText($this->db,"version-commit-author",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($user->email);
|
// $mail->addTo($user->email);
|
||||||
$mail->addCc($this->view->config->service->email);
|
// $mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交并同步,请等待数据中心进一步处理!'));
|
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交并同步,请等待数据中心进一步处理!'));
|
||||||
$this->jsonexit($data);
|
$this->jsonexit($data);
|
||||||
|
@ -2040,48 +2040,48 @@ class AuthorController extends Zend_Controller_Action
|
||||||
$iso=new ISO19115();
|
$iso=new ISO19115();
|
||||||
@$iso->loadXML($row['xml']);
|
@$iso->loadXML($row['xml']);
|
||||||
//email to admin
|
//email to admin
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"version-commit-admin",array(
|
// $mailtp=new EmailText($this->db,"version-commit-admin",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
'changelog'=>$changelog,
|
// 'changelog'=>$changelog,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($this->view->config->service->email);
|
// $mail->addTo($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
$mail->send();
|
// $mail->send();
|
||||||
|
|
||||||
unset($mail);
|
unset($mail);
|
||||||
unset($mailtp);
|
unset($mailtp);
|
||||||
//email to author
|
//email to author
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"version-commit-author",array(
|
// $mailtp=new EmailText($this->db,"version-commit-author",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($user->email);
|
// $mail->addTo($user->email);
|
||||||
$mail->addCc($this->view->config->service->email);
|
// $mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
//email to experts
|
//email to experts
|
||||||
$sql="select u.username,u.email from mdexpertreview e left join users u on e.id=u.id where e.status in (0,1) and e.uuid=?";
|
$sql="select u.username,u.email from mdexpertreview e left join users u on e.id=u.id where e.status in (0,1) and e.uuid=?";
|
||||||
|
@ -2091,29 +2091,29 @@ class AuthorController extends Zend_Controller_Action
|
||||||
|
|
||||||
unset($mail);
|
unset($mail);
|
||||||
unset($mailtp);
|
unset($mailtp);
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"version-commit-expert",array(
|
// $mailtp=new EmailText($this->db,"version-commit-expert",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$row['uuid']);
|
// $filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/doc/uuid/'.$row['uuid']);
|
||||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.doc');
|
// $mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.doc');
|
||||||
$filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$row['uuid']);
|
// $filecontent=file_get_contents("http://" . $_SERVER['HTTP_HOST'].'/service/pdf/uuid/'.$row['uuid']);
|
||||||
$mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.pdf');
|
// $mail->createAttachment($filecontent,'application/octet-stream',Zend_Mime::DISPOSITION_ATTACHMENT, Zend_Mime::ENCODING_BASE64, $row['title'].'.pdf');
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
foreach ($experts as $expert) $mail->addTo($expert['email']);
|
// foreach ($experts as $expert) $mail->addTo($expert['email']);
|
||||||
$mail->addCc($this->view->config->service->email);
|
// $mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交,请等待数据中心进一步处理!'));
|
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功提交,请等待数据中心进一步处理!'));
|
||||||
$this->jsonexit($data);
|
$this->jsonexit($data);
|
||||||
|
@ -2137,26 +2137,26 @@ class AuthorController extends Zend_Controller_Action
|
||||||
$this->db->query($sql,array($id));
|
$this->db->query($sql,array($id));
|
||||||
|
|
||||||
//email to admin & author
|
//email to admin & author
|
||||||
$mail=new WestdcMailer($this->view->config->smtp);
|
// $mail=new WestdcMailer($this->view->config->smtp);
|
||||||
$mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
// $mail->setFrom($this->view->config->service->email,'西部数据中心服务组');
|
||||||
$mailtp=new EmailText($this->db,"metadata-release",array(
|
// $mailtp=new EmailText($this->db,"metadata-release",array(
|
||||||
'user' => $user->username,
|
// 'user' => $user->username,
|
||||||
'uuid' => $row['uuid'],
|
// 'uuid' => $row['uuid'],
|
||||||
'email'=> $user->email,
|
// 'email'=> $user->email,
|
||||||
//元数据标题
|
// //元数据标题
|
||||||
'title'=> $row['title'],
|
// 'title'=> $row['title'],
|
||||||
'changelog'=>$changelog,
|
// 'changelog'=>$changelog,
|
||||||
));
|
// ));
|
||||||
$mail->setBodyText($mailtp->getBody());
|
// $mail->setBodyText($mailtp->getBody());
|
||||||
$mail->setSubject($mailtp->getSubject());
|
// $mail->setSubject($mailtp->getSubject());
|
||||||
if($this->debug==0)
|
// if($this->debug==0)
|
||||||
{
|
// {
|
||||||
$mail->addTo($this->view->config->service->email);
|
// $mail->addTo($this->view->config->service->email);
|
||||||
//$mail->addCc($this->view->config->service->email);
|
// //$mail->addCc($this->view->config->service->email);
|
||||||
}else{
|
// }else{
|
||||||
$mail->addTo($this->debug_email);
|
// $mail->addTo($this->debug_email);
|
||||||
}
|
// }
|
||||||
@$mail->send();
|
// @$mail->send();
|
||||||
|
|
||||||
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功发布!'));
|
$data = array("commited"=>1,"error"=>$this->alertbox('ok','该版本已经成功发布!'));
|
||||||
$this->jsonexit($data);
|
$this->jsonexit($data);
|
||||||
|
|
Loading…
Reference in New Issue