56 lines
1.3 KiB
PHP
56 lines
1.3 KiB
PHP
<?php
|
|
|
|
namespace app\controller\api\common;
|
|
|
|
|
|
use app\common\repositories\common\ContractRepository;
|
|
use crmeb\basic\BaseController;
|
|
use think\App;
|
|
|
|
/**
|
|
* Common: 法大大合同签约
|
|
* Author: wu-hui
|
|
* Time: 2024/07/04 10:37
|
|
* Class Contract
|
|
* @package app\controller\api\common
|
|
*/
|
|
class Contract extends BaseController{
|
|
|
|
protected $repository;
|
|
|
|
public function __construct(App $app, ContractRepository $contractRepository){
|
|
parent::__construct($app);
|
|
|
|
$this->repository = $contractRepository;
|
|
}
|
|
/**
|
|
* Common: 法大大 - 获取授权信息
|
|
* Author: wu-hui
|
|
* Time: 2024/07/04 10:55
|
|
* @return mixed
|
|
*/
|
|
public function authInfo(){
|
|
$params = $this->request->params([
|
|
['role_type', 0],
|
|
['role_id', 0]
|
|
]);
|
|
$uid = $this->request->uid();
|
|
$info = $this->repository->getAuthInfo((int)$uid,(int)$params['role_type'],(int)$params['role_id']);
|
|
|
|
return app('json')->success($info);
|
|
}
|
|
/**
|
|
* Common: 法大大 - 获取合同签署信息
|
|
* Author: wu-hui
|
|
* Time: 2024/07/05 10:06
|
|
* @return mixed
|
|
*/
|
|
public function getSignInfo(){
|
|
$id = $this->request->param('id', 0);
|
|
$info = $this->repository->getSignInfo((int)$id);
|
|
|
|
return app('json')->success($info);
|
|
}
|
|
|
|
}
|