장재혁

Add database settings

...@@ -6,10 +6,10 @@ ...@@ -6,10 +6,10 @@
6 }, 6 },
7 "scripts": { 7 "scripts": {
8 "build": "lerna run build", 8 "build": "lerna run build",
9 - "build:api" : "lerna exec --scrop @graphql-community/api --stream yarn build", 9 + "build:api" : "lerna exec --scope @graphql-community/api --stream yarn build",
10 - "build:web": "lerna exec --scrop @graphql-community/api --stream yarn build", 10 + "build:web": "lerna exec --scope @graphql-community/api --stream yarn build",
11 - "dev:web": "lerna exec --scrop @graphql-community/web --stream yarn dev", 11 + "dev:web": "lerna exec --scope @graphql-community/web --stream yarn dev",
12 - "dev:api": "lerna exec --scrop @graphql-community/api --stream yarn start:dev" 12 + "dev:api": "lerna exec --scope @graphql-community/api --stream yarn start:dev"
13 }, 13 },
14 "workspaces": [ 14 "workspaces": [
15 "packages/**" 15 "packages/**"
......
No preview for this file type
...@@ -14,9 +14,10 @@ import { MypageModule } from './mypage/mypage.module'; ...@@ -14,9 +14,10 @@ import { MypageModule } from './mypage/mypage.module';
14 }), 14 }),
15 TypeOrmModule.forRoot({ 15 TypeOrmModule.forRoot({
16 type: 'sqlite', 16 type: 'sqlite',
17 - database: ':memory:', 17 + database: 'database.db',
18 entities: ['dist/**/*.entity{.ts,.js}'], 18 entities: ['dist/**/*.entity{.ts,.js}'],
19 synchronize: true, 19 synchronize: true,
20 + logging: false,
20 }), 21 }),
21 MypageModule, 22 MypageModule,
22 ], 23 ],
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
2 import { ObjectType, Field, Int } from '@nestjs/graphql'; 2 import { ObjectType, Field, Int } from '@nestjs/graphql';
3 import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm'; 3 import { Column, Entity, PrimaryGeneratedColumn } from 'typeorm';
4 4
5 -@Entity() 5 +@Entity({ name: 'my_pagelist' })
6 @ObjectType() 6 @ObjectType()
7 export class MyPage { 7 export class MyPage {
8 @PrimaryGeneratedColumn() 8 @PrimaryGeneratedColumn()
......