将 consts 整理到几个文件中

This commit is contained in:
liangtongchuan
2020-12-15 16:02:59 +08:00
parent 3a78f667c3
commit e877b0190d
61 changed files with 402 additions and 69 deletions

View File

@@ -1,4 +1,4 @@
import { STATUS } from '@consts/statusCode';
import { STATUS } from '@consts';
import { GameModel } from '@db/Game';
import { Controller } from 'egg';

View File

@@ -1,4 +1,4 @@
import { ENCRYPT_KEY, ENCRYPT_IV } from '@consts/consts';
import { ENCRYPT_KEY, ENCRYPT_IV } from '@consts';
import { Context } from 'egg';
const crypto = require('crypto');
const isJSON = require('koa-is-json');

View File

@@ -1,4 +1,4 @@
import { STATUS } from '@consts/statusCode';
import { STATUS } from '@consts';
import { UserModel } from '@db/User';
module.exports = () => {

View File

@@ -1,9 +1,9 @@
import { FIX_SMS_CODE_TELS, COUNTER } from '@consts/consts';
import { DEFAULT_HEROES } from '@consts/consts';
import { FIX_SMS_CODE_TELS, COUNTER } from '@consts';
import { DEFAULT_HEROES } from '@consts';
import { HeroModel } from '@db/Hero';
import { RoleModel } from '@db/Role';
import { UserModel } from '@db/User';
import { STATUS } from '@consts/statusCode';
import { STATUS } from '@consts';
import { smsModel } from '@db/Sms';
import { Service } from 'egg';
import Counter from '@db/Counter';

View File

@@ -1,4 +1,4 @@
import { TURBO_CORE_URL, APP_ID, TURBO_PARM_SECRET } from '@consts/consts';
import { TURBO_CORE_URL, APP_ID, TURBO_PARM_SECRET } from '@consts';
import { Service } from 'egg';
const crypto = require('crypto');
/**

View File

@@ -24,7 +24,7 @@
"baseUrl": ".",
"paths": {
"@db/*": ["app/db/*"],
"@consts/*": ["app/consts/*"]
"@consts": ["app/consts"]
},
},
"exclude": [