增加了添加新闻时默认加入平台名称的功能
This commit is contained in:
parent
3110ae7d9c
commit
e00911af13
|
@ -372,8 +372,10 @@ class Archive
|
||||||
return 0;
|
return 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$config = \Zend_Registry::get('config');
|
||||||
|
|
||||||
//执行SQL语句后返回插入文章表的ID
|
//执行SQL语句后返回插入文章表的ID
|
||||||
$sql = "INSERT INTO ".$this->tbl_archives." (userid,title,description,image,source,ts_published,is_pub,body)
|
$sql = "INSERT INTO ".$this->tbl_archives." (userid,title,description,image,source,ts_published,is_pub,body,sub)
|
||||||
VALUES (
|
VALUES (
|
||||||
".$data['userid'].",
|
".$data['userid'].",
|
||||||
".$data['title'].",
|
".$data['title'].",
|
||||||
|
@ -382,7 +384,8 @@ class Archive
|
||||||
".$data['source'].",
|
".$data['source'].",
|
||||||
".$data['ts_published'].",
|
".$data['ts_published'].",
|
||||||
".$data['is_pub'].",
|
".$data['is_pub'].",
|
||||||
".$data['body']."
|
".$data['body'].",
|
||||||
|
'".$config->sub->metadata."'
|
||||||
)
|
)
|
||||||
RETURNING id";
|
RETURNING id";
|
||||||
try{
|
try{
|
||||||
|
|
Loading…
Reference in New Issue