HPW_ERD
Tables (13)
COMMENT
- cmtId — serial — Primary key — NOT NULL
- userId — serial — Foreign key → USER.userId — NOT NULL — 유저
- parentId — serial — Foreign key → COMMENT.cmtId — NOT NULL
- postId — serial — Foreign key → POST.postId — NOT NULL — 게시글
- content — text
- createdAt — timestamp
- updatedAt — timestamp
- deletedAt (deletedAtl) — timestamp
PINNED
- pinId — serial — Primary key — NOT NULL
- userId — serial — Foreign key → USER.userId — NOT NULL — 유저
- postId — serial — Foreign key → POST.postId — NOT NULL — 게시글
- createdAt — timestamp
POST
- postId — serial — Primary key — NOT NULL — 게시글
- userId — serial — Foreign key → USER.userId — NOT NULL — 유저
- title — varchar(64) — NOT NULL — 제목
- thumbnail — text — 썸네일
- view — int — NOT NULL — 조회수
- category — smallint — NOT NULL — 아카이브
- categoryName — varchar(50)
- content — text — NOT NULL — 게시글
- createdAt — timestamp — NOT NULL
- updatedAt — timestamp — NOT NULL
- invisibleAt — timestamp
- deletedAt — timestamp
- contact_insta — varchar(50)
- contact_email — varchar(50)
POST-TAG
- postId — serial — Foreign key → POST.postId — NOT NULL — 게시글
- tagId — serial — Foreign key → TAG.tagId — NOT NULL
- createdAt — timestamp — NOT NULL
REPORT
- reportId — serial — Primary key — NOT NULL — 신고
- userId — serial — Foreign key → USER.userId — NOT NULL — 피신고자
- postId — serial — Foreign key → POST.postId — 게시글
- content — text — NOT NULL — 신고
- progress — smallint — NOT NULL — 처리
- createdAt — timestamp — NOT NULL
- updatedAt — timestamp — NOT NULL
- deletedAt — timestamp
- cmtId — serial — Foreign key → COMMENT.cmtId — NOT NULL
RESERVATION
- resId — serial — Primary key — NOT NULL — 예약
- userId — serial — Foreign key → USER.userId — NOT NULL — 유저
- toolId (toolId2) — serial — Foreign key → TOOL.toolId — NOT NULL — 기자재
- time — timestamp — NOT NULL — 예약
- memo — text — NOT NULL — 요청
- file — text — 첨부
- tel — varchar(24) — NOT NULL — 전화번호
- createdAt — timestamp — NOT NULL
- updatedAt — timestamp — NOT NULL
- deletedAt — timestamp
- sheetIId — serial — Foreign key → SCHEDULE_MANAGE.sheetIId — NOT NULL — 예약
RESTRICTION
- rstrcId — serial — Primary key — NOT NULL — 규제
- type — smallint — NOT NULL — 제재
- createdAt — timestamp — NOT NULL
- updatedAt — timestamp — NOT NULL
- freeAt — timestamp
- userId (userId2) — serial — Foreign key → USER.userId — NOT NULL — 유저
RES_TEMPLITE
- policyId — serial — Primary key — NOT NULL — 예약
- periodStart — timestamp — NOT NULL — 기간
- periodEnd — timestamp — NOT NULL — 기간
- availToolIds — text — 사용가능
- createdAt — timestamp — NOT NULL
- fileDeadLine — timestamp — NOT NULL — 파일
- res_max_week — smallint — NOT NULL — 주간
- res_max_day — smallint — NOT NULL — 일간
- availGrade — int — NOT NULL — 예약
SCHEDULE_MANAGE
- sheetIId — serial — Primary key — NOT NULL — 예약
- policyId — serial — Foreign key → RES_TEMPLITE.policyId — NOT NULL — 예약
- periodStart — timestamp — NOT NULL — 기간
- periodEnd — timestamp — NOT NULL — 기간
- createdAt — timestamp — NOT NULL
TAG
- tagId — serial — Primary key — NOT NULL
- name — varchar(24) — NOT NULL
- tagType — smallint — 작업종류/사용기자재;
- createdAt — timestamp — NOT NULL
TOOL
- toolId — serial — Primary key — NOT NULL — 기자재
- name — text — NOT NULL — 기자재
- order_num — numeric — 기자재
- color — varchar(20) — NOT NULL — 기자재
- content — text — NOT NULL
- opt_lim — numeric — 옵션
- createdAt — timestamp — NOT NULL
- updatedAt — timestamp — NOT NULL
- invisibleAt — timestamp
- deactive — boolean — 기자재
TOOL_OPTION
- optId — serial — NOT NULL — 세부옵션
- toolId — serial — Foreign key → TOOL.toolId — NOT NULL — 기자재
- order_num — numeric — 옵션
- name — varchar(20) — NOT NULL — 세부옵션
- content — text — NOT NULL — 세부옵션
- createdAt — timestamp — NOT NULL
USER
- userId — serial — Primary key — NOT NULL — 유저
- stuId — varchar(10) — NOT NULL — 학번
- name — varchar(24) — NOT NULL — 이름
- nickname — varchar(24) — 닉네임
- grade — smallint — NOT NULL — 학년
- createdAt — timestamp — NOT NULL — 생성일시
- updatedAt — timestamp — NOT NULL
- deletedAt — timestamp
- authority — integer — 권한