确认添加初始版本应为最早的版本;若已有版本发布则不添加对应的初始版本
This commit is contained in:
parent
6fcd27682e
commit
d6cfe5e054
|
@ -3078,8 +3078,8 @@ class AuthorController extends Zend_Controller_Action
|
|||
$sql="insert into mdversion (xml,ts_created,uuid,changelog,userid)
|
||||
select x.data,m.ts_created,?,?,? from metadata m left join xml x on m.id=x.id
|
||||
left join mdversion v on m.uuid=v.uuid
|
||||
where m.uuid=? and v.changelog is null
|
||||
order by v.ts_created DESC LIMIT 1";
|
||||
where m.uuid=? and v.changelog is null and m.uuid not in (select uuid from mdversion where changelog is not null)
|
||||
order by v.ts_created ASC LIMIT 1";
|
||||
$sth=$this->db->prepare($sql);
|
||||
try
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue