if(session('iszb')=='是'){ $map=' and id<>0 '; }else{ $map=" and shopid=".session('shopid')." "; }

#### {$Think.session.shopid|get_shop_name=###} 地址：echo M('shop')->where(array('id'=>session('shopid')))->getField('dizhi'); 电话：echo M('shop')->where(array('id'=>session('shopid')))->getField('dianhua');

今天新增会员：echo M('huiyuan')->where("addtime like '%".date('Y-m-d',time())."%'".$map)->count('id')/1;人 今天 现金收入：echo M('zijin')->where("addtime like '%".date('Y-m-d',time())."%' ".$map)->sum('xianjin')/1;元 / 银联收入echo M('zijin')->where("addtime like '%".date('Y-m-d',time())."%' ".$map)->sum('pos')/1;元 / 卡支付echo M('zijin')->where("addtime like '%".date('Y-m-d',time())."%' ".$map)->sum('yue')/1;元 / 赠送echo M('zijin')->where("addtime like '%".date('Y-m-d',time())."%' ".$map)->sum('song')/1;元 / 优惠echo M('zijin')->where("addtime like '%".date('Y-m-d',time())."%' ".$map)->sum('jian')/1;元

##### 我的便签、记事本

{$Rs.bian}

### 近期生日的会员 详细

姓名 | 性别 | 联系电话 | 会员等级 | 会员生日
--- | --- | --- | --- | ---
$benyue=date("-m-",time()); $xiayue=date("-m-",strtotime("+1 month")); $list = M('huiyuan')->where("shengri like '%".$benyue."%' or shengri like '%".$xiayue."%'")->limit(5)->select();
{$v.xingming|msubstr=###,0,20} | {$v.sex} | {$v.dianhua|msubstr=###,0,20} | {$v.dengji} | {$v.shengri|substr=###,0,10}

### 一个月未来消费 详细

姓名 | 性别 | 联系电话 | 会员等级 | 上次消费
--- | --- | --- | --- | ---
$list = M('huiyuan')->where(array('updatetime'=>array('elt',date("Y-m-d",strtotime("-1 month")))))->limit(5)->select();
{$v.xingming|msubstr=###,0,20} | {$v.sex} | {$v.dianhua|msubstr=###,0,20} | {$v.dengji} | {$v.updatetime|substr=###,0,10}

### 新闻动态 详细

标题 | 分类 | 浏览 | 发布
--- | --- | --- | ---
$list=M('news')->order("id desc")->limit(5)->select();
{$v.title|msubstr=###,0,30} | {$v.fenlei|msubstr=###,0,10} | 打开浏览 | {$v.addtime|substr=###,0,10}

### 客户预约 详细

会员 | 预约时间 | 预约内容 | 员工姓名 | 新增时间
--- | --- | --- | --- | ---
if(session('iszb')!=='是'){ $map1['shopid'] = array('EQ', session('shopid')); }else{ $map1='id<>0'; } $list=M('yuyue')->where($map1)->order("id desc")->limit(5)->select();
{$v.xingming} | {$v.yytime} | {$v.title} | {$v.juname} | {$v.addtime|substr=###,0,10}