first commit
This commit is contained in:
1
滴滴淘/diditao/app/controller/.pydio
Normal file
1
滴滴淘/diditao/app/controller/.pydio
Normal file
@@ -0,0 +1 @@
|
||||
ca7a75b2-edaf-46a0-b197-4c7575bd45a4
|
||||
26
滴滴淘/diditao/app/controller/Api.php
Normal file
26
滴滴淘/diditao/app/controller/Api.php
Normal file
@@ -0,0 +1,26 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace app\controller;
|
||||
|
||||
|
||||
use diditao\common\base\BaseController;
|
||||
use diditao\common\response\facade\AppResponse;
|
||||
|
||||
class Api extends BaseController
|
||||
{
|
||||
public function getSmsCode()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
public function upload()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
public function getBuyerAvailableBankList()
|
||||
{
|
||||
return AppResponse::handle();
|
||||
}
|
||||
}
|
||||
19
滴滴淘/diditao/app/controller/Index.php
Normal file
19
滴滴淘/diditao/app/controller/Index.php
Normal file
@@ -0,0 +1,19 @@
|
||||
<?php
|
||||
namespace app\controller;
|
||||
|
||||
use app\BaseController;
|
||||
use diditao\common\interceptor\auth\facade\Auth;
|
||||
use diditao\common\request\facade\AppRequest;
|
||||
|
||||
class Index extends BaseController
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
|
||||
}
|
||||
|
||||
public function hello($name = 'ThinkPHP6')
|
||||
{
|
||||
return 'hello,' . $name;
|
||||
}
|
||||
}
|
||||
20
滴滴淘/diditao/app/controller/Landing.php
Normal file
20
滴滴淘/diditao/app/controller/Landing.php
Normal file
@@ -0,0 +1,20 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace app\controller;
|
||||
|
||||
|
||||
use diditao\common\base\BaseController;
|
||||
use diditao\common\request\facade\AppRequest;
|
||||
use think\facade\Config;
|
||||
use think\facade\View;
|
||||
|
||||
class Landing extends BaseController
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
|
||||
halt(AppRequest::param());
|
||||
return View::fetch('index');
|
||||
}
|
||||
}
|
||||
62
滴滴淘/diditao/app/controller/Login.php
Normal file
62
滴滴淘/diditao/app/controller/Login.php
Normal file
@@ -0,0 +1,62 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace app\controller;
|
||||
|
||||
|
||||
use diditao\common\base\BaseController;
|
||||
use diditao\common\response\facade\AppResponse;
|
||||
|
||||
class Login extends BaseController
|
||||
{
|
||||
/**
|
||||
* @desc 用户登录
|
||||
* @user Liu qian
|
||||
* @time 2020/5/8 22:13
|
||||
* @return mixed
|
||||
* @throws \diditao\common\exception\AppError
|
||||
*/
|
||||
public function index()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
|
||||
/**
|
||||
* @desc 用户注册
|
||||
* @user Liu qian
|
||||
* @time 2020/5/8 22:13
|
||||
* @return mixed
|
||||
* @throws \diditao\common\exception\AppError
|
||||
*/
|
||||
public function reg()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
|
||||
/**
|
||||
* @desc 重置密码
|
||||
* @user Liu qian
|
||||
* @time 2020/5/8 22:13
|
||||
* @return mixed
|
||||
* @throws \diditao\common\exception\AppError
|
||||
*/
|
||||
public function forget()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
|
||||
/**
|
||||
* @desc 退出登录
|
||||
* @user Liu qian
|
||||
* @time 2020/5/9 1:00
|
||||
* @return mixed
|
||||
*/
|
||||
public function logout()
|
||||
{
|
||||
return AppResponse::handle();
|
||||
}
|
||||
|
||||
}
|
||||
71
滴滴淘/diditao/app/controller/Test.php
Normal file
71
滴滴淘/diditao/app/controller/Test.php
Normal file
@@ -0,0 +1,71 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace app\controller;
|
||||
|
||||
|
||||
use Carbon\Carbon;
|
||||
use diditao\caching\facade\UserReferCache;
|
||||
use diditao\certification_api\facade\CertificationApi;
|
||||
use diditao\certification_api\provider\BankFourDetails;
|
||||
use diditao\certification_api\provider\CellphoneAge;
|
||||
use diditao\certification_api\provider\CellphoneLocation;
|
||||
use diditao\common\base\BaseController;
|
||||
use diditao\common\debug\facade\AppDebug;
|
||||
use diditao\common\request\facade\AppRequest;
|
||||
use diditao\common\service\upload\support\ImageWater;
|
||||
use diditao\orm\model\admin\AdminUser;
|
||||
use diditao\orm\model\buyer\BuyerCertificationRecord;
|
||||
use diditao\orm\model\upload\Uploads;
|
||||
use diditao\orm\model\user\User;
|
||||
use diditao\stat_client\facade\QueueClient;
|
||||
use think\facade\Config;
|
||||
use think\helper\Str;
|
||||
|
||||
class Test extends BaseController
|
||||
{
|
||||
public function index()
|
||||
{
|
||||
$record = BuyerCertificationRecord::where('id','=',2)->findOrEmpty();
|
||||
$res = QueueClient::buyerCertifyQueue($record);
|
||||
dump($res);
|
||||
}
|
||||
public function temp()
|
||||
{
|
||||
$stat = User::field(['id','father_id','grandfather_id'])->whereOr('grandfather_id','=',1)->whereOr('father_id','=',1)->select();
|
||||
$son = $stat->where('father_id','=',1)->count();
|
||||
$grandson = $stat->where('grandfather_id','=',1)->count();
|
||||
dump($son);
|
||||
dump($grandson);
|
||||
}
|
||||
|
||||
protected function isBankNum($value)
|
||||
{
|
||||
$arr_no = str_split($value);
|
||||
$last_n = $arr_no[count($arr_no)-1];
|
||||
krsort($arr_no);
|
||||
$i = 1;
|
||||
$total = 0;
|
||||
foreach ($arr_no as $n){
|
||||
if($i%2==0){
|
||||
$ix = $n*2;
|
||||
if($ix>=10){
|
||||
$nx = 1 + ($ix % 10);
|
||||
$total += $nx;
|
||||
}else{
|
||||
$total += $ix;
|
||||
}
|
||||
}else{
|
||||
$total += $n;
|
||||
}
|
||||
$i++;
|
||||
}
|
||||
$total -= $last_n;
|
||||
$x = 10 - ($total % 10);
|
||||
if($x == $last_n){
|
||||
return true;
|
||||
}else{
|
||||
return '请输入正确的银行卡号';
|
||||
}
|
||||
}
|
||||
}
|
||||
1
滴滴淘/diditao/app/controller/certification/.pydio
Normal file
1
滴滴淘/diditao/app/controller/certification/.pydio
Normal file
@@ -0,0 +1 @@
|
||||
6dbe1ccb-dfa9-44ec-9a55-5e9bc655268e
|
||||
21
滴滴淘/diditao/app/controller/certification/Buyer.php
Normal file
21
滴滴淘/diditao/app/controller/certification/Buyer.php
Normal file
@@ -0,0 +1,21 @@
|
||||
<?php
|
||||
|
||||
|
||||
namespace app\controller\certification;
|
||||
|
||||
|
||||
use diditao\common\base\BaseController;
|
||||
use diditao\common\response\facade\AppResponse;
|
||||
|
||||
class Buyer extends BaseController
|
||||
{
|
||||
public function add()
|
||||
{
|
||||
$this->validate();
|
||||
return AppResponse::handle();
|
||||
}
|
||||
public function get()
|
||||
{
|
||||
return AppResponse::handle();
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user