diff --git a/packages/plugins/@tachybase/plugin-dingtalk/src/server/auth.ts b/packages/plugins/@tachybase/plugin-dingtalk/src/server/dingtalk-auth.ts similarity index 95% rename from packages/plugins/@tachybase/plugin-dingtalk/src/server/auth.ts rename to packages/plugins/@tachybase/plugin-dingtalk/src/server/dingtalk-auth.ts index 25430811f..fb6f51165 100644 --- a/packages/plugins/@tachybase/plugin-dingtalk/src/server/auth.ts +++ b/packages/plugins/@tachybase/plugin-dingtalk/src/server/dingtalk-auth.ts @@ -1,9 +1,9 @@ import { BaseAuth } from '@tachybase/auth'; import { namespace } from '../constants'; -import { DingtalkClient } from './client'; +import { DingtalkClient } from './dingtalk-client'; -export class Auth extends BaseAuth { +export class DingtalkAuth extends BaseAuth { constructor(config) { const { ctx } = config; super({ diff --git a/packages/plugins/@tachybase/plugin-dingtalk/src/server/client.ts b/packages/plugins/@tachybase/plugin-dingtalk/src/server/dingtalk-client.ts similarity index 100% rename from packages/plugins/@tachybase/plugin-dingtalk/src/server/client.ts rename to packages/plugins/@tachybase/plugin-dingtalk/src/server/dingtalk-client.ts diff --git a/packages/plugins/@tachybase/plugin-dingtalk/src/server/plugin.ts b/packages/plugins/@tachybase/plugin-dingtalk/src/server/plugin.ts index c8e98a30e..2d5432901 100644 --- a/packages/plugins/@tachybase/plugin-dingtalk/src/server/plugin.ts +++ b/packages/plugins/@tachybase/plugin-dingtalk/src/server/plugin.ts @@ -1,9 +1,8 @@ -import { tval } from '@tachybase/client'; import { Gateway, Plugin } from '@tachybase/server'; -import { authType, namespace } from '../constants'; +import { authType } from '../constants'; import { getAuthUrl, redirect } from './actions/dingding'; -import { Auth } from './auth'; +import { DingtalkAuth } from './dingtalk-auth'; export class PluginDingdingServer extends Plugin { async afterAdd() {} @@ -11,10 +10,8 @@ export class PluginDingdingServer extends Plugin { async beforeLoad() {} async load() { - console.log('hello world dingding'); this.app.authManager.registerTypes(authType, { - auth: Auth, - title: tval('DingTalk', { ns: namespace }), + auth: DingtalkAuth, }); this.app.resourcer.define({ name: 'dingtalk',