attributes['expire']); } public function order($shop) { if ($this->attributes['shop'] == '') { return true; } $shop_array = explode(',', $this->attributes['shop']); foreach ($shop_array as $shopid) { if ($shopid == $shop) { return true; } } return false; } }