@handstudio/hce-component-schema
v1.0.132
Published
TypeORM schema component for HCE Web Services
Downloads
3
Readme
hce-component-schema
TypeORM schema component for HCE web services.
How to install
npm install @handstudio/hce-component-schema
How to use (example)
import { getRepository } from 'typeorm';
import { Agency } from '@handstudio-component-schema';
(async () => {
const repo = getRepository(Agency);
const agencies = await repo.find({});
console.log(agencies);
})();
서버 데이터 세팅
env
DB_HOST=
DB_USERNAME=
DB_PORT=
DB_PASSWORD=
cli
데이터베이스 sync
npm run demo:sync
.env 필요
제품 등록
# cli:import:basespecs가 먼저 수행되어야 함.
$ npm run cli:import:basespecs
$ npm run cli:import:products
대리점, 글로벌 네트워크 등록
$ npm run cli:import:agencies
배너 등록
hce-admin repository 배포시 - 배너
참고
INSERT INTO banner
([language], title, content, activated, base, [order], displayStart, displayEnd)
values
('ko', '제목', '내용', 1, 1, 1, '2021-01-01 00:00:00', '9999-12-31 00:00:00'),
('en', '제목', '내용', 1, 1, 1, '2021-01-01 00:00:00', '9999-12-31 00:00:00'),
('cn', '제목', '내용', 1, 1, 1, '2021-01-01 00:00:00', '9999-12-31 00:00:00');