| 12345678910111213141516171819202122232425262728293031 |
- <?php
- namespace app\admin\model\dao;
- use app\common\model\UserModel;
- use think\facade\Db;
- class SystemArticle extends BaseDao
- {
- public static $table = "db_system_article";
- public function __construct()
- {
- }
- public static function count($type)
- {
- return $count = Db::table(self::$table)->where('type', $type)->count();
- }
- public static function getIdNameMapByStatus($int)
- {
- return Db::table(self::$table)
- ->where('status', $int)
- ->field('id,name')
- ->select()
- ->toArray();
- }
- }
|