买家会员可以设置收货信息、关注好友、发送消息、查看预存款记录、查看历史足迹、解绑第三方账户、管理自己的订单、收藏商品或店铺、领取代金券、申请退货退款、违规举报、成为分销员等。
买家从前台登录入口/home/login/login登录后,从member表里获取会员信息,并执行member模型中的createSession方法设置买家会员session信息、增加会员积分、增加会员经验值、更新用户登录信息、将cookie中的购物车信息以及浏览记录存入数据库。
if (!$reg) { //添加会员积分 $this->addPoint($member_info); //添加会员经验值 $this->addExppoint($member_info); } if (!empty($member_info['member_logintime'])) { $update_info = array( 'member_loginnum' => ($member_info['member_loginnum'] + 1), 'member_logintime' => TIMESTAMP, 'member_old_logintime' => $member_info['member_logintime'], 'member_login_ip' => request()->ip(), 'member_old_login_ip' => $member_info['member_login_ip'] ); $this->editMember(array('member_id' => $member_info['member_id']), $update_info); } cookie('cart_goods_num', '', -3600); // cookie中的cart存入数据库 model('cart')->mergeCart($member_info, session('store_id')); // cookie中的浏览记录存入数据库 model('goodsbrowse')->mergeGoodsbrowse(session('member_id'), session('store_id'));
买家所有的业务模块均继承自基类application\home\controller\BaseMember.php,其中getMemberMenuList方法保存了买家用户中心的菜单信息。
$menu_list = array( 'info' => array( 'name' => 'info', 'text' => lang('ds_data_management'), 'url' => url('Memberinformation/index'), 'submenu' => array( array('name' => 'member_information', 'text' => lang('ds_account_information'), 'url' => url('Memberinformation/index'),), array('name' => 'member_security', 'text' =>lang('ds_account_security'), 'url' => url('Membersecurity/index'),), array('name' => 'member_address', 'text' => lang('ds_member_path_address'), 'url' => url('Memberaddress/index'),), array('name' => 'member_message', 'text' => lang('ds_my_news'), 'url' => url('Membermessage/message'),), array('name' => 'member_snsfriend', 'text' => lang('ds_my_good_friend'), 'url' => url('Membersnsfriend/index'),), array('name' => 'member_goodsbrowse', 'text' => lang('ds_my_footprint'), 'url' => url('Membergoodsbrowse/listinfo'),), array('name' => 'member_connect', 'text' => lang('ds_third_party_account_login'), 'url' => url('Memberconnect/qqbind'),), ) ), ……
QQ:858761000
联系电话:15364080101(微信同号)
Copyright@2010-2024 长沙德尚网络科技有限公司 版权所有
湘ICP备14007737号-2