where('name', 'LIKE', "%$where[name]%"); if ($where['status'] !== '') $model = $model->where('status', $where['status']); return self::page($model, $where); } /** * 根据模版编号获取模版ID * @param $tempkey */ public static function getTempid($tempkey) { return self::vialdWhere()->where('tempkey', $tempkey)->where('status', 1)->cache(true, 3600)->value('tempid'); } }