aurelia-orm
Version:
Makes working with entities and calling your Rest API simple.
17 lines (15 loc) • 383 B
JavaScript
import {OrmMetadata} from '../orm-metadata';
/**
* Set the repositoryReference metadata on the entity
*
* @param {string} repositoryReference The repository reference to use
*
* @return {function}
*
* @decorator
*/
export function repository(repositoryReference) {
return function(target) {
OrmMetadata.forTarget(target).put('repository', repositoryReference);
};
}