- 博客(2)
- 收藏
- 关注
转载 tp 查询日,周,月,年的数
// 获取当日的数据 Db::table(‘table’) ->whereTime(‘times’, ‘today’)->select(); // 获取昨天的数据 Db::table(‘table’)->whereTime(‘times’, ‘yesterday’)->select(); // 获取本周的数据 Db::table(‘table’)->whereTime(‘times’, ‘week’)->select(); // 获取上周的数据 Db::table(‘ta
2021-09-24 11:04:33
330
原创 2021-09-17
tp5数据的增加与减少的操作 setInc()增加字段数据,默认增加1 $shopmodel->where('id',$data['shop_id'])->setInc('shop'); setDec()减少字段数据,默认减少1 $shopmodel->where('id',$data['shop_id'])->setDec('stock');
2021-09-17 17:25:35
57
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人