export const DATA_FIELD = `
    {
        slug
        url
        name
        layout
        createdOn
        createdBy {
            id
            displayName
            type
        }
    }
` ; export const ERROR_FIELD = `
    {
        code
        data
        message
    }
` ; export const CREATE_CATEGORY = `
    mutation CreateCategory($data: PbCategoryInput!) {
        pageBuilder {
            createCategory(data: $data) {
                data ${ DATA_FIELD }
                error ${ ERROR_FIELD }
            }
        }
    }
` ; export const UPDATE_CATEGORY = `
    mutation UpdateCategory($slug: String!, $data: PbCategoryInput!) {
        pageBuilder {
            updateCategory(slug: $slug, data: $data) {
                data ${ DATA_FIELD }
                error ${ ERROR_FIELD }
            }
        }
    }
` ; export const LIST_CATEGORIES = `
    query ListCategories {
        pageBuilder {
            listCategories {
                data ${ DATA_FIELD }
                error ${ ERROR_FIELD }
            }
        }
    }
` ; export const GET_CATEGORY = `
    query GetCategory($slug: String!) {
        pageBuilder {
            getCategory(slug: $slug) {
                data ${ DATA_FIELD }
                error ${ ERROR_FIELD }
            }
        }
    }
` ; export const DELETE_CATEGORY = `
    mutation DeleteCategory($slug: String!) {
        pageBuilder {
            deleteCategory(slug: $slug) {
                data ${ DATA_FIELD }
                error ${ ERROR_FIELD }
            }
        }
    }
` ;