Skip to content

Commit

Permalink
[fix] some detail bugs
Browse files Browse the repository at this point in the history
  • Loading branch information
TechQuery committed Sep 17, 2023
1 parent 2dc9f81 commit 8e6f25b
Show file tree
Hide file tree
Showing 4 changed files with 12 additions and 4 deletions.
1 change: 1 addition & 0 deletions .dockerignore
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
ReadMe.md
node_modules/
dist/
type/
.tmp/
start.sh
.husky/
Expand Down
4 changes: 3 additions & 1 deletion ReadMe.md
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,9 @@

### Production environment

https://service.kaiyuanshe.cn/docs/
- Entry: https://service.kaiyuanshe.cn/
- Document: https://service.kaiyuanshe.cn/docs/
- Schema: https://service.kaiyuanshe.cn/docs/spec/

### Type package

Expand Down
3 changes: 2 additions & 1 deletion src/controller/index.ts
Original file line number Diff line number Diff line change
@@ -1,11 +1,12 @@
import type {} from 'koa2-swagger-ui';
import { createAPI } from 'koagger';

import { isProduct } from '../utility';
import { CheckEventController } from './CheckEvent';
import { CrawlerController } from './Crawler';
import { SessionController } from './Session';

export const { router, swagger, mocker } = createAPI({
mock: true,
mock: !isProduct,
controllers: [SessionController, CheckEventController, CrawlerController]
});
8 changes: 6 additions & 2 deletions src/model/Base.ts
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,11 @@ import {
Min
} from 'class-validator';
import { NewData } from 'mobx-restful';
import { CreateDateColumn, PrimaryGeneratedColumn } from 'typeorm';
import {
CreateDateColumn,
PrimaryGeneratedColumn,
UpdateDateColumn
} from 'typeorm';

export abstract class Base {
@IsInt()
Expand All @@ -20,7 +24,7 @@ export abstract class Base {

@IsDateString()
@IsOptional()
@CreateDateColumn()
@UpdateDateColumn()
updatedAt?: string;
}

Expand Down

0 comments on commit 8e6f25b

Please sign in to comment.