Commit c2f035e1 authored by jiangkebao's avatar jiangkebao

创建钉钉服务

parent 986b2f8e
<?php
/**
* Created by PhpStorm.
* User: 姜克保
* Date: 2020/5/20
* Time: 15:48
*/
namespace Meibuyu\Micro\Service\Interfaces\DingTalk;
interface DingAuthServiceInterface
{
/**
* 通过临时授权码获取用户信息
* @param $code 临时授权码
* @param $state 用于防止重放攻击,开发者可以根据此信息来判断redirect_uri只能执行一次来避免重放攻击
* @return array
*/
public function getDingUserByTempCode($code, $state): array;
}
<?php
/**
* Created by PhpStorm.
* User: 姜克保
* Date: 2020/5/20
* Time: 15:48
*/
namespace Meibuyu\Micro\Service\Interfaces\DingTalk;
interface DingDepartmentServiceInterface
{
public function getDepartmentList($id = null, $isFetchChild = false, $lang = null): array;
}
......@@ -6,20 +6,20 @@
* Time: 15:48
*/
namespace Meibuyu\Micro\Service\Interfaces;
namespace Meibuyu\Micro\Service\Interfaces\DingTalk;
interface DingUserServiceInterface
{
/**
* 通过用户id获取单个用户信息
* @param int $id
* @return array
/** 通过用户id获取单个用户信息
* @param string $ding_user_id 钉钉用户id
* @return array 钉钉用户信息
*/
public function getById(int $id): array;
public function getByDingUserId($ding_user_id): array;
/**
* 通过部门id获取部门用户列表
* @param int $departmentId
* 通过部门id获取部门分页用户列表
* @param int $departmentId 部门id
* @param int $offset
* @param int $size
* @param string|null $order
......@@ -30,7 +30,7 @@ interface DingUserServiceInterface
/**
* 通过Unionid获取用户id
* @param int $unionid
* @param int $unionid unionid
* @return int
*/
public function getUseridByUnionid(int $unionid): int;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment