...
|
...
|
@@ -58,7 +58,7 @@ class MessageModel |
|
|
* @param type $id
|
|
|
* @return type array
|
|
|
*/
|
|
|
public static function getContentData($uid, $page, $size, $id)
|
|
|
public static function getContentData($uid, $page, $size, $id, $name)
|
|
|
{
|
|
|
$result = array();
|
|
|
$inboxlist = MessageData::getInboxList($uid, $page, $size);
|
...
|
...
|
@@ -78,7 +78,28 @@ class MessageModel |
|
|
switch ($contentval['type']) {
|
|
|
case 'pullCoupon':
|
|
|
//领取生日券消息
|
|
|
$result['text'] = array(
|
|
|
'content' => $name . '祝您生日快乐!有货为感谢您的支持,特赠送您生日专属礼,享受专属优惠哦!'
|
|
|
);
|
|
|
$result['birthCoupon'] = true;
|
|
|
if ($contentval['is_collar'] === 'Y') {
|
|
|
$result['birthCoupon'] = array(
|
|
|
'over' => true,
|
|
|
'text' => '已领取',
|
|
|
);
|
|
|
break;
|
|
|
}
|
|
|
|
|
|
if ($contentval['is_over_time'] === 'Y') {
|
|
|
$result['birthCoupon'] = array(
|
|
|
'over' => true,
|
|
|
'text' => '生日券已过期'
|
|
|
);
|
|
|
break;
|
|
|
}
|
|
|
|
|
|
$result['coupons'] = array();
|
|
|
|
|
|
$coupondata = MessageData::getCouponId($uid); //获取优惠券信息
|
|
|
if (!empty($coupondata['data'])) {
|
|
|
foreach ($coupondata['data'] as $couponval) {
|
...
|
...
|
|