Skip to content

Relationship conditions #25

@davidguttman

Description

@davidguttman

Could be useful to add conditions to a relationship:

relationships: {
  recentAlbums: {
    type: 'hasMany',
    local: 'id',
    foreign: { table: 'album', key: 'bandId' },
    conditions: {
      released: {
        operation: '>=',
        value: 2012
      }
    }
  }

Thoughts?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions