michaelmior /
NoSE
| 1 | # frozen_string_literal: true |
||
| 2 | |||
| 3 | require_relative '../lib/nose.rb' |
||
|
0 ignored issues
–
show
introduced
by
Loading history...
|
|||
| 4 | |||
| 5 | NoSE::Schema.new do |
||
| 6 | Model 'ebay' |
||
| 7 | |||
| 8 | Index 'users_by_id' do |
||
| 9 | Hash users.UserID |
||
| 10 | Extra users['*'] |
||
| 11 | Path users.UserID |
||
| 12 | end |
||
| 13 | |||
| 14 | Index 'items_by_id' do |
||
| 15 | Hash items.ItemID |
||
| 16 | Extra items['*'] |
||
| 17 | Path items.ItemID |
||
| 18 | end |
||
| 19 | |||
| 20 | Index 'likes_by_user' do |
||
| 21 | Hash users.UserID |
||
| 22 | Ordered likes.LikedAt, likes.LikeID, items.ItemID |
||
| 23 | Path users.UserID, users.likes, likes.item |
||
| 24 | end |
||
| 25 | |||
| 26 | Index 'likes_by_item' do |
||
| 27 | Hash items.ItemID |
||
| 28 | Ordered likes.LikedAt, likes.LikeID, users.UserID |
||
| 29 | Path items.ItemID, items.likes, likes.user |
||
| 30 | end |
||
| 31 | end |
||
| 32 |