fix #621
This commit is contained in:
parent
0526231290
commit
fc16907197
|
@ -153,10 +153,14 @@ class Order
|
||||||
{
|
{
|
||||||
$uid = view::User('id');
|
$uid = view::User('id');
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$sql = "select count(*) as cnt from dataorder where status=1 and uuid in (select uuid from $this->config->sub->metadata) and userid=".$uid;
|
||||||
|
$row=$this->db->FetchRow($sql);
|
||||||
|
if ($row['cnt']>=$this->config->download->max) return "一次申请不能大于5条数据!请移除部分数据。";
|
||||||
|
|
||||||
if($id == -1)
|
if($id == -1)
|
||||||
{
|
{
|
||||||
$sql = $this->db->quoteInto("update dataorder set status=2 where status=1 and userid=?",$uid);
|
$sql = $this->db->quoteInto("update dataorder set status=2 where status=1 and uuid in (select uuid from $this->config->sub->metadata) and userid=?",$uid);
|
||||||
if($this->db->exec($sql))
|
if($this->db->exec($sql))
|
||||||
{
|
{
|
||||||
return true;
|
return true;
|
||||||
|
|
Loading…
Reference in New Issue