Added product admin features
This commit is contained in:
@@ -0,0 +1,15 @@
|
||||
import { IResolverObject } from 'graphql-tools';
|
||||
import { InteriorAPI } from '../datasources/interior-api';
|
||||
import { InteriorsFilterInput } from '../types/interior-types';
|
||||
|
||||
const Interior: IResolverObject = {};
|
||||
|
||||
async function getInteriors(_, args: InteriorsFilterInput, { dataSources }) {
|
||||
return (<InteriorAPI>dataSources.interiorApi).getInteriors(args.filter);
|
||||
}
|
||||
|
||||
export const interiorTypeDefs = { Interior };
|
||||
|
||||
export const interiorsQueryTypeDefs = {
|
||||
interiors: getInteriors,
|
||||
};
|
||||
Reference in New Issue
Block a user