Commit 7a0a9d74 authored by zhz's avatar zhz

邀请人相关

parent 61e2db8c
......@@ -1174,7 +1174,7 @@ class MemberServiceModel extends \Business\AbstractModel
$sess = \Yaf\Session::getInstance();
$authInfo = $sess->get('wxAuthInfo');
$openId = $authInfo['openid'];
$result = \DAO\Store\QmStoreInvite::getInstance()->getQmStoreInviteOne(array('invite_wxappopenid'=>$openId));
$result = \DAO\Store\QmStoreInviteModel::getInstance()->getQmStoreInviteOne(array('invite_wxappopenid'=>$openId));
return array('hasAddInviter'=>$result ? 1 : 0);
}
public function addInviter ($param, $memberId) {
......
......@@ -3,7 +3,7 @@
namespace DAO\Store;
class QmStoreInvite extends \DAO\AbstractModel
class QmStoreInviteModel extends \DAO\AbstractModel
{
......@@ -29,7 +29,7 @@ class QmStoreInvite extends \DAO\AbstractModel
public function getQmStoreInviteOne($where, $field = '*')
{
$this->setDb($this->dbName);
return $this->db->select($field)->where($where)->fetchOne();
return $this->db->from($this->_tableName)->select($field)->where($where)->fetchOne();
}
public function addQmStoreInvite($data)
{
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment