This commit is contained in:
molong
2022-11-01 11:42:28 +08:00
parent f8927e3193
commit 5cee9dcfab
23 changed files with 550 additions and 235 deletions

39
app/controller/Index.php Normal file
View File

@@ -0,0 +1,39 @@
<?php
// +----------------------------------------------------------------------
// | SentCMS [ WE CAN DO IT JUST THINK IT ]
// +----------------------------------------------------------------------
// | Copyright (c) 2013 http://www.tensent.cn All rights reserved.
// +----------------------------------------------------------------------
// | Author: molong <molong@tensent.cn> <http://www.tensent.cn>
// +----------------------------------------------------------------------
namespace app\controller;
use app\controller\Base;
/**
* @title 首页
*/
class Index extends Base{
/**
* @title 首页
*
* @return void
*/
public function index(){
if(request()->isAjax()){
return ['code' => 1, 'data' => 'SentOS'];
}else{
return view('/index');
}
}
public function test(){
// $area = \think\facade\Db::name('areas')->select();
// $save = [];
// foreach($area as $val){
// $save[] = ['title' => $val['area'], 'code' => $val['area_id'], 'parent_id' => $val['city_id'], 'first' => '', 'create_time' => time(), 'update_time' => time()];
// }
// \think\facade\Db::name('area')->insertAll($save);
}
}