Пример #1
0
 /**
  * 安币返还,每个$cashBackTypeId只能返还一次
  * @param $brokerId
  * @param $cityId
  * @param $amount 返还金额,单位“分”
  * @param $cashBackTypeId 该id由self::getCashBackTypeId生成
  * @param $note 经纪人账户日志里面展示的备注
  * @param int $accounttype 1-经纪人个人账户,2-经纪人公司账户
  * @return bool
  */
 public static function addCashBack($brokerId, $cityId, $amount, $cashBackTypeId, $note, $accounttype = 2)
 {
     $cashBackQueueData = array('typeid' => $cashBackTypeId, 'brokerid' => $brokerId, 'accounttype' => $accounttype, 'amount' => $amount, 'remark' => $note, 'addtime' => time(), 'cityid' => $cityId);
     return Model_Broker_AjkPppccoinQueen::addQueue($cashBackQueueData);
 }
Пример #2
0
 /**
  * 返钱
  * @param $typeId 返还类型Id -> ppc_db.ajk_ppccoin_type
  * @param $accountType '送回帐号类型,1个人账户,2公司账户'
  * @param $brokerId
  * @param $brokerType int 经纪人类型,1-二手房经纪人,2-好租经纪人,3-金铺经纪人 -> 建议统一二手房
  * @param $amount 送钱金额,单位分
  * @param $remark 备注
  * @param $cityId
  * @param $brokerAccountType int 账户类型,1-二手房经纪人,2-好租经纪人,3-金铺经纪人
  * @return int
  */
 public static function addReturnQueue($brokerId, $cityId, $typeId, $amount, $remark, $accountType = 2, $brokerAccountType = 1, $brokerType = 1)
 {
     return Model_Broker_AjkPppccoinQueen::addQueue(array('typeid' => $typeId, 'accounttype' => $accountType, 'brokerid' => $brokerId, 'amount' => $amount, 'remark' => $remark, 'cityid' => $cityId, 'brokertype' => $brokerType, 'brokeraccounttype' => $brokerAccountType, 'addtime' => time(), 'updatetime' => time()));
 }