(id: string | null)
| 75 | } |
| 76 | |
| 77 | const dingtalkClientRequest = async (id: string | null) => { |
| 78 | if (!id) { |
| 79 | const clientInfoRes = await queryClientInfo(7) |
| 80 | id = clientInfoRes['corpid'] |
| 81 | } |
| 82 | const dd = window['dd'] |
| 83 | dd.ready(function () { |
| 84 | dd.runtime.permission.requestAuthCode({ |
| 85 | corpId: id, |
| 86 | onSuccess: function (info: any) { |
| 87 | const code = info.code |
| 88 | const state = `fit2cloud-dingtalk-client` |
| 89 | toUrl(`?code=${code}&state=${state}`) |
| 90 | }, |
| 91 | onFail: function (err: any) { |
| 92 | ElMessage.error(err) |
| 93 | }, |
| 94 | }) |
| 95 | }) |
| 96 | } |
| 97 | |
| 98 | const larkClientRequest = async () => { |
| 99 | if (!window['tt']) { |
no test coverage detected