loopbackio / loopbackio/loopback-next

Custom repository collection/table name

Đang mở
#2,844 6 bình luận 0 reaction 0 người được giao Xem trên GitHub

Chưa có ai nhận issue này.

feature good first issue Hacktoberfest Repository
Ngôn ngữ chính
TypeScript
Star
5.1k
Fork
1.1k
Merge trung bình
2 ngày 21 giờ
Pull request đã merge (30 ngày)
27

Mô tả

Currently the name of the collection is specified in the model, through the *setting* property of the *model* decorator.

I have two repositories, one storing the current version of the data, the other storing all versions of the data. Right now when I use the *create* method from those repo, they try to save into the same collection, creating errors.

I would like to store the model in different collections.

Also see [this issue](https://github.com/strongloop/loopback-next/issues/2197), probably code related.

Hướng dẫn đóng góp

Mở hướng dẫn đóng góp

Bắt đầu từ đâu

  1. Đọc hết issue, rồi đọc hướng dẫn đóng góp của dự án.
  2. Bình luận trên issue rằng bạn sẽ nhận — tránh hai người làm cùng một việc.
  3. Fork repository và làm thay đổi trên một nhánh.
  4. Mở pull request có tham chiếu số hiệu của issue.

Hướng nghiên cứu

Start with the model decorator's setting property and the repository create method described in the issue, then review related issue #2197 for implementation context. The work is done when two repositories using the same model can persist to different collections or tables without conflicts, with appropriate coverage added wherever the existing behavior is tested.

Do mô hình lập chỉ mục viết ra từ nội dung của issue.

Đánh giá

Công nghệ
typescript
Lĩnh vực
backend, database
Loại issue
Tính năng
Độ khó
4/5
Thời gian dự kiến
3-5 ngày
Mức độ hoạt động
Đình trệ
Độ rõ ràng
Khá rõ ràng
Mức phù hợp với người mới
35/100

Nhận issue mới trong hộp thư của bạn

Bản tóm tắt ngắn những issue GitHub phù hợp với người mới.