@unchainedshop/api 2.0.0-beta6 → 2.0.0-beta8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/api-index.d.ts +4 -7
- package/lib/api-index.js +24 -14
- package/lib/api-index.js.map +1 -1
- package/lib/context.d.ts +0 -1
- package/lib/context.js +0 -11
- package/lib/context.js.map +1 -1
- package/lib/createGraphQLServer.d.ts +2 -2
- package/lib/createGraphQLServer.js +12 -53
- package/lib/createGraphQLServer.js.map +1 -1
- package/lib/errors.js +8 -3
- package/lib/errors.js.map +1 -1
- package/lib/express/createApolloMiddleware.d.ts +4 -0
- package/lib/express/createApolloMiddleware.js +34 -0
- package/lib/express/createApolloMiddleware.js.map +1 -0
- package/lib/express/createBulkImportMiddleware.d.ts +2 -0
- package/lib/express/createBulkImportMiddleware.js +79 -0
- package/lib/express/createBulkImportMiddleware.js.map +1 -0
- package/lib/express/createERCMetadataMiddleware.d.ts +3 -0
- package/lib/express/createERCMetadataMiddleware.js +56 -0
- package/lib/express/createERCMetadataMiddleware.js.map +1 -0
- package/lib/express/createSingleSignOnMiddleware.d.ts +6 -0
- package/lib/express/createSingleSignOnMiddleware.js +71 -0
- package/lib/express/createSingleSignOnMiddleware.js.map +1 -0
- package/lib/express/index.d.ts +6 -0
- package/lib/express/index.js +27 -0
- package/lib/express/index.js.map +1 -0
- package/lib/loaders/index.js +50 -0
- package/lib/loaders/index.js.map +1 -1
- package/lib/resolvers/index.js +1 -1
- package/lib/resolvers/index.js.map +1 -1
- package/lib/resolvers/mutations/accounts/changePassword.d.ts +0 -2
- package/lib/resolvers/mutations/accounts/changePassword.js +2 -2
- package/lib/resolvers/mutations/accounts/changePassword.js.map +1 -1
- package/lib/resolvers/mutations/accounts/createUser.js +2 -2
- package/lib/resolvers/mutations/accounts/createUser.js.map +1 -1
- package/lib/resolvers/mutations/accounts/enrollUser.js +1 -1
- package/lib/resolvers/mutations/accounts/enrollUser.js.map +1 -1
- package/lib/resolvers/mutations/accounts/loginWithPassword.d.ts +0 -1
- package/lib/resolvers/mutations/accounts/loginWithPassword.js +3 -3
- package/lib/resolvers/mutations/accounts/loginWithPassword.js.map +1 -1
- package/lib/resolvers/mutations/accounts/resetPassword.d.ts +0 -1
- package/lib/resolvers/mutations/accounts/resetPassword.js +1 -1
- package/lib/resolvers/mutations/accounts/resetPassword.js.map +1 -1
- package/lib/resolvers/mutations/accounts/setPassword.d.ts +0 -1
- package/lib/resolvers/mutations/accounts/setPassword.js +1 -1
- package/lib/resolvers/mutations/accounts/setPassword.js.map +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortment.js +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortment.js.map +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentFilter.js +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentFilter.js.map +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentLink.js +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentLink.js.map +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentProduct.js +1 -1
- package/lib/resolvers/mutations/assortments/removeAssortmentProduct.js.map +1 -1
- package/lib/resolvers/mutations/enrollments/updateEnrollment.d.ts +1 -1
- package/lib/resolvers/mutations/filters/removeFilter.js +1 -1
- package/lib/resolvers/mutations/filters/removeFilter.js.map +1 -1
- package/lib/resolvers/mutations/filters/updateFilter.js +2 -1
- package/lib/resolvers/mutations/filters/updateFilter.js.map +1 -1
- package/lib/resolvers/mutations/index.d.ts +1 -1
- package/lib/resolvers/mutations/pageView.d.ts +1 -1
- package/lib/resolvers/mutations/pageView.js +2 -2
- package/lib/resolvers/mutations/pageView.js.map +1 -1
- package/lib/resolvers/mutations/products/removeProduct.d.ts +1 -1
- package/lib/resolvers/mutations/products/removeProduct.js +5 -8
- package/lib/resolvers/mutations/products/removeProduct.js.map +1 -1
- package/lib/resolvers/queries/products/product.js +1 -1
- package/lib/resolvers/queries/products/productCatalogPrices.d.ts +1 -1
- package/lib/resolvers/queries/products/productCatalogPrices.js +5 -2
- package/lib/resolvers/queries/products/productCatalogPrices.js.map +1 -1
- package/lib/resolvers/queries/products/products.js +1 -1
- package/lib/resolvers/queries/products/products.js.map +1 -1
- package/lib/resolvers/scalars/LowerCaseString.d.ts +1 -1
- package/lib/resolvers/scalars/index.d.ts +1 -1
- package/lib/resolvers/type/assortment/assortment-filter-types.d.ts +2 -2
- package/lib/resolvers/type/assortment/assortment-filter-types.js +13 -6
- package/lib/resolvers/type/assortment/assortment-filter-types.js.map +1 -1
- package/lib/resolvers/type/assortment/assortment-link-types.d.ts +2 -2
- package/lib/resolvers/type/assortment/assortment-link-types.js +14 -6
- package/lib/resolvers/type/assortment/assortment-link-types.js.map +1 -1
- package/lib/resolvers/type/assortment/assortment-media-types.d.ts +1 -1
- package/lib/resolvers/type/assortment/assortment-path-link-types.d.ts +1 -4
- package/lib/resolvers/type/assortment/assortment-path-link-types.js +0 -7
- package/lib/resolvers/type/assortment/assortment-path-link-types.js.map +1 -1
- package/lib/resolvers/type/assortment/assortment-product-types.d.ts +2 -2
- package/lib/resolvers/type/assortment/assortment-product-types.js +14 -6
- package/lib/resolvers/type/assortment/assortment-product-types.js.map +1 -1
- package/lib/resolvers/type/assortment/assortment-types.d.ts +1 -1
- package/lib/resolvers/type/bookmark-types.d.ts +1 -1
- package/lib/resolvers/type/bookmark-types.js +6 -2
- package/lib/resolvers/type/bookmark-types.js.map +1 -1
- package/lib/resolvers/type/country-types.d.ts +1 -1
- package/lib/resolvers/type/delivery-provider-types.d.ts +1 -1
- package/lib/resolvers/type/enrollment/enrollment-delivery-types.d.ts +2 -2
- package/lib/resolvers/type/enrollment/enrollment-payment-types.d.ts +2 -2
- package/lib/resolvers/type/enrollment/enrollment-period-types.d.ts +2 -2
- package/lib/resolvers/type/enrollment/enrollment-plan-tyes.d.ts +2 -2
- package/lib/resolvers/type/enrollment/enrollment-plan-tyes.js +6 -2
- package/lib/resolvers/type/enrollment/enrollment-plan-tyes.js.map +1 -1
- package/lib/resolvers/type/enrollment/enrollment-types.d.ts +2 -2
- package/lib/resolvers/type/event-types.d.ts +1 -1
- package/lib/resolvers/type/filter/filter-option-types.d.ts +2 -2
- package/lib/resolvers/type/filter/filter-types.d.ts +2 -2
- package/lib/resolvers/type/order/order-delivery-discount-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-delivery-pickup-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-delivery-shipping-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-discount-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-global-discount-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-item-discount-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-item-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-item-types.js +13 -6
- package/lib/resolvers/type/order/order-item-types.js.map +1 -1
- package/lib/resolvers/type/order/order-payment-card-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-payment-discount-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-payment-generic-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-payment-invoice-types.d.ts +1 -1
- package/lib/resolvers/type/order/order-types.d.ts +1 -1
- package/lib/resolvers/type/price-types.d.ts +1 -1
- package/lib/resolvers/type/product/product-bundle-item-types.js +4 -2
- package/lib/resolvers/type/product/product-bundle-item-types.js.map +1 -1
- package/lib/resolvers/type/product/product-discount.d.ts +1 -1
- package/lib/resolvers/type/product/product-review-types.d.ts +1 -1
- package/lib/resolvers/type/product/product-review-types.js +6 -2
- package/lib/resolvers/type/product/product-review-types.js.map +1 -1
- package/lib/resolvers/type/product/product-tokenized-types.js +1 -0
- package/lib/resolvers/type/product/product-tokenized-types.js.map +1 -1
- package/lib/resolvers/type/product/product-variation-assignment-types.js +4 -2
- package/lib/resolvers/type/product/product-variation-assignment-types.js.map +1 -1
- package/lib/resolvers/type/quotation-types.d.ts +2 -2
- package/lib/resolvers/type/quotation-types.js +7 -3
- package/lib/resolvers/type/quotation-types.js.map +1 -1
- package/lib/resolvers/type/shop-types.d.ts +1 -1
- package/lib/resolvers/type/token-types.d.ts +1 -1
- package/lib/resolvers/type/user-types.d.ts +1 -3
- package/lib/resolvers/type/user-types.js +0 -12
- package/lib/resolvers/type/user-types.js.map +1 -1
- package/lib/resolvers/type/webauthn-credentials-types.d.ts +1 -1
- package/lib/resolvers/type/work-types.d.ts +1 -1
- package/lib/schema/{types/log.d.ts → directives.d.ts} +0 -0
- package/lib/schema/directives.js +15 -0
- package/lib/schema/directives.js.map +1 -0
- package/lib/schema/index.js +2 -1
- package/lib/schema/index.js.map +1 -1
- package/lib/schema/inputTypes.js +0 -15
- package/lib/schema/inputTypes.js.map +1 -1
- package/lib/schema/mutation.js +4 -23
- package/lib/schema/mutation.js.map +1 -1
- package/lib/schema/query.js +28 -10
- package/lib/schema/query.js.map +1 -1
- package/lib/schema/types/assortment.js +9 -10
- package/lib/schema/types/assortment.js.map +1 -1
- package/lib/schema/types/color.js +1 -1
- package/lib/schema/types/country.js +1 -1
- package/lib/schema/types/currency.js +1 -1
- package/lib/schema/types/delivery.js +3 -2
- package/lib/schema/types/delivery.js.map +1 -1
- package/lib/schema/types/dimensions.js +1 -1
- package/lib/schema/types/discount.js +1 -1
- package/lib/schema/types/dispatch.js +1 -0
- package/lib/schema/types/dispatch.js.map +1 -1
- package/lib/schema/types/filter.js +5 -8
- package/lib/schema/types/filter.js.map +1 -1
- package/lib/schema/types/geo-position.js +1 -1
- package/lib/schema/types/language.js +1 -1
- package/lib/schema/types/media.js +1 -1
- package/lib/schema/types/payment.js +3 -3
- package/lib/schema/types/price.js +2 -2
- package/lib/schema/types/product/bundle-product.js +2 -3
- package/lib/schema/types/product/bundle-product.js.map +1 -1
- package/lib/schema/types/product/configurable-product.js +7 -7
- package/lib/schema/types/product/plan-product.js +4 -3
- package/lib/schema/types/product/plan-product.js.map +1 -1
- package/lib/schema/types/product/product.js +11 -11
- package/lib/schema/types/product/simple-product.js +5 -4
- package/lib/schema/types/product/simple-product.js.map +1 -1
- package/lib/schema/types/product/tokenized-product.js +6 -3
- package/lib/schema/types/product/tokenized-product.js.map +1 -1
- package/lib/schema/types/search.js +3 -8
- package/lib/schema/types/search.js.map +1 -1
- package/lib/schema/types/shop.js +2 -2
- package/lib/schema/types/stock.js +1 -0
- package/lib/schema/types/stock.js.map +1 -1
- package/lib/schema/types/types.js +1 -1
- package/lib/schema/types/user.js +1 -3
- package/lib/schema/types/user.js.map +1 -1
- package/lib/schema/types/warehousing.js +3 -3
- package/package.json +31 -19
- package/src/api-index.ts +25 -29
- package/src/context.ts +0 -19
- package/src/createGraphQLServer.ts +11 -56
- package/src/errors.ts +8 -3
- package/src/express/createApolloMiddleware.ts +40 -0
- package/src/express/createBulkImportMiddleware.ts +90 -0
- package/src/express/createERCMetadataMiddleware.ts +72 -0
- package/src/express/createSingleSignOnMiddleware.ts +83 -0
- package/src/express/index.ts +48 -0
- package/src/loaders/index.ts +63 -3
- package/src/resolvers/index.ts +1 -1
- package/src/resolvers/mutations/accounts/changePassword.ts +2 -4
- package/src/resolvers/mutations/accounts/createUser.ts +2 -2
- package/src/resolvers/mutations/accounts/enrollUser.ts +1 -1
- package/src/resolvers/mutations/accounts/loginWithPassword.ts +3 -4
- package/src/resolvers/mutations/accounts/resetPassword.ts +2 -2
- package/src/resolvers/mutations/accounts/setPassword.ts +2 -2
- package/src/resolvers/mutations/assortments/removeAssortment.ts +1 -1
- package/src/resolvers/mutations/assortments/removeAssortmentFilter.ts +1 -1
- package/src/resolvers/mutations/assortments/removeAssortmentLink.ts +1 -1
- package/src/resolvers/mutations/assortments/removeAssortmentProduct.ts +1 -1
- package/src/resolvers/mutations/filters/removeFilter.ts +1 -1
- package/src/resolvers/mutations/filters/updateFilter.ts +3 -1
- package/src/resolvers/mutations/pageView.ts +2 -2
- package/src/resolvers/mutations/products/removeProduct.ts +6 -8
- package/src/resolvers/queries/products/product.ts +1 -1
- package/src/resolvers/queries/products/productCatalogPrices.ts +5 -2
- package/src/resolvers/queries/products/products.ts +1 -1
- package/src/resolvers/type/assortment/assortment-filter-types.ts +11 -6
- package/src/resolvers/type/assortment/assortment-link-types.ts +12 -6
- package/src/resolvers/type/assortment/assortment-path-link-types.ts +0 -11
- package/src/resolvers/type/assortment/assortment-product-types.ts +12 -6
- package/src/resolvers/type/bookmark-types.ts +7 -2
- package/src/resolvers/type/enrollment/enrollment-plan-tyes.ts +6 -2
- package/src/resolvers/type/order/order-item-types.ts +13 -6
- package/src/resolvers/type/product/product-bundle-item-types.ts +4 -2
- package/src/resolvers/type/product/product-review-types.ts +6 -2
- package/src/resolvers/type/product/product-tokenized-types.ts +1 -0
- package/src/resolvers/type/product/product-variation-assignment-types.ts +4 -2
- package/src/resolvers/type/quotation-types.ts +6 -3
- package/src/resolvers/type/user-types.ts +0 -15
- package/src/schema/directives.js +14 -0
- package/src/schema/index.js +2 -1
- package/src/schema/inputTypes.js +0 -15
- package/src/schema/mutation.js +4 -23
- package/src/schema/query.js +28 -10
- package/src/schema/types/assortment.js +9 -10
- package/src/schema/types/color.js +1 -1
- package/src/schema/types/country.js +1 -1
- package/src/schema/types/currency.js +1 -1
- package/src/schema/types/delivery.js +3 -2
- package/src/schema/types/dimensions.js +1 -1
- package/src/schema/types/discount.js +1 -1
- package/src/schema/types/dispatch.js +1 -0
- package/src/schema/types/filter.js +5 -8
- package/src/schema/types/geo-position.js +1 -1
- package/src/schema/types/language.js +1 -1
- package/src/schema/types/media.js +1 -1
- package/src/schema/types/payment.js +3 -3
- package/src/schema/types/price.js +2 -2
- package/src/schema/types/product/bundle-product.js +2 -3
- package/src/schema/types/product/configurable-product.js +7 -7
- package/src/schema/types/product/plan-product.js +4 -3
- package/src/schema/types/product/product.js +11 -11
- package/src/schema/types/product/simple-product.js +5 -4
- package/src/schema/types/product/tokenized-product.js +6 -3
- package/src/schema/types/search.js +3 -8
- package/src/schema/types/shop.js +2 -2
- package/src/schema/types/stock.js +1 -0
- package/src/schema/types/types.js +1 -1
- package/src/schema/types/user.js +1 -3
- package/src/schema/types/warehousing.js +3 -3
- package/tsconfig.json +1 -0
- package/lib/createBulkImportServer.d.ts +0 -2
- package/lib/createBulkImportServer.js +0 -81
- package/lib/createBulkImportServer.js.map +0 -1
- package/lib/createERCMetadataServer.d.ts +0 -2
- package/lib/createERCMetadataServer.js +0 -59
- package/lib/createERCMetadataServer.js.map +0 -1
- package/lib/schema/types/log.js +0 -16
- package/lib/schema/types/log.js.map +0 -1
- package/src/createBulkImportServer.ts +0 -95
- package/src/createERCMetadataServer.ts +0 -78
- package/src/schema/types/log.js +0 -15
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"product-variation-assignment-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/product/product-variation-assignment-types.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,0BAA0B,GAA0C;IAC/E,GAAG,EAAE,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,EAAE,EAAE;QAC/B,OAAO,GAAG,OAAO,CAAC,GAAG,IAAI,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;IACxE,CAAC;IACD,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,EAAE;QACnC,OAAO,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;YACxD,GAAG;YACH,KAAK,EAAE,UAAU,CAAC,MAAM,CAAC,GAAG,CAAC;YAC7B,OAAO;SACR,CAAC,CAAC,CAAC;IACN,CAAC;IACD,OAAO,EAAE,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QAChD,OAAO,OAAO,CAAC,
|
|
1
|
+
{"version":3,"file":"product-variation-assignment-types.js","sourceRoot":"","sources":["../../../../src/resolvers/type/product/product-variation-assignment-types.ts"],"names":[],"mappings":"AAEA,MAAM,CAAC,MAAM,0BAA0B,GAA0C;IAC/E,GAAG,EAAE,CAAC,EAAE,OAAO,EAAE,UAAU,EAAE,EAAE,EAAE;QAC/B,OAAO,GAAG,OAAO,CAAC,GAAG,IAAI,MAAM,CAAC,MAAM,CAAC,UAAU,CAAC,MAAM,CAAC,CAAC,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC;IACxE,CAAC;IACD,OAAO,EAAE,CAAC,EAAE,UAAU,EAAE,OAAO,EAAE,EAAE,EAAE;QACnC,OAAO,MAAM,CAAC,IAAI,CAAC,UAAU,CAAC,MAAM,IAAI,EAAE,CAAC,CAAC,GAAG,CAAC,CAAC,GAAG,EAAE,EAAE,CAAC,CAAC;YACxD,GAAG;YACH,KAAK,EAAE,UAAU,CAAC,MAAM,CAAC,GAAG,CAAC;YAC7B,OAAO;SACR,CAAC,CAAC,CAAC;IACN,CAAC;IACD,OAAO,EAAE,KAAK,EAAE,EAAE,UAAU,EAAE,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE;QAChD,MAAM,OAAO,GAAG,MAAM,OAAO,CAAC,aAAa,CAAC,IAAI,CAAC;YAC/C,SAAS,EAAE,UAAU,CAAC,SAAS;YAC/B,aAAa,EAAE,IAAI;SACpB,CAAC,CAAC;QACH,OAAO,OAAO,CAAC;IACjB,CAAC;CACF,CAAC"}
|
|
@@ -4,8 +4,8 @@ import { User } from '@unchainedshop/types/user';
|
|
|
4
4
|
import { Product } from '@unchainedshop/types/products';
|
|
5
5
|
import { Country } from '@unchainedshop/types/countries';
|
|
6
6
|
import { Currency } from '@unchainedshop/types/currencies';
|
|
7
|
-
|
|
8
|
-
|
|
7
|
+
type HelperType<P, T> = (quotation: QuotationType, params: P, context: Context) => T;
|
|
8
|
+
type QuotationHelperTypes = {
|
|
9
9
|
country: HelperType<never, Promise<Country>>;
|
|
10
10
|
currency: HelperType<never, Promise<Currency>>;
|
|
11
11
|
isExpired: HelperType<{
|
|
@@ -2,9 +2,13 @@ export const Quotation = {
|
|
|
2
2
|
country: async (obj, _, { modules }) => modules.countries.findCountry({ isoCode: obj.countryCode }),
|
|
3
3
|
currency: async (obj, _, { modules }) => modules.currencies.findCurrency({ isoCode: obj.currency }),
|
|
4
4
|
isExpired: (obj, { referenceDate }, { modules }) => modules.quotations.isExpired(obj, { referenceDate }),
|
|
5
|
-
product: (obj, _, {
|
|
6
|
-
|
|
7
|
-
|
|
5
|
+
product: async (obj, _, { loaders }) => {
|
|
6
|
+
const product = await loaders.productLoader.load({
|
|
7
|
+
productId: obj.productId,
|
|
8
|
+
includeDrafts: true,
|
|
9
|
+
});
|
|
10
|
+
return product;
|
|
11
|
+
},
|
|
8
12
|
status: (obj, _, { modules }) => modules.quotations.normalizedStatus(obj),
|
|
9
13
|
user: (obj, _, { modules }) => modules.users.findUserById(obj.userId),
|
|
10
14
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"quotation-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/quotation-types.ts"],"names":[],"mappings":"AAkBA,MAAM,CAAC,MAAM,SAAS,GAAyB;IAC7C,OAAO,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,OAAO,CAAC,SAAS,CAAC,WAAW,CAAC,EAAE,OAAO,EAAE,GAAG,CAAC,WAAW,EAAE,CAAC;IAEnG,QAAQ,EAAE,KAAK,EAAE,GAAG,EAAE,CAAC,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CAAC,OAAO,CAAC,UAAU,CAAC,YAAY,CAAC,EAAE,OAAO,EAAE,GAAG,CAAC,QAAQ,EAAE,CAAC;IAEnG,SAAS,EAAE,CAAC,GAAG,EAAE,EAAE,aAAa,EAAE,EAAE,EAAE,OAAO,EAAE,EAAE,EAAE,CACjD,OAAO,CAAC,UAAU,CAAC,SAAS,CAAC,GAAG,EAAE,EAAE,aAAa,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E,CAAC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { Context } from '@unchainedshop/types/api';
|
|
2
2
|
import { Country } from '@unchainedshop/types/countries';
|
|
3
3
|
import { Language } from '@unchainedshop/types/languages';
|
|
4
|
-
|
|
4
|
+
type HelperType<T> = (root: never, params: never, context: Context) => Promise<T>;
|
|
5
5
|
export interface ShopHelperTypes {
|
|
6
6
|
_id: () => string;
|
|
7
7
|
country: HelperType<Country>;
|
|
@@ -2,7 +2,7 @@ import { Context } from '@unchainedshop/types/api';
|
|
|
2
2
|
import { Product } from '@unchainedshop/types/products';
|
|
3
3
|
import { User } from '@unchainedshop/types/user';
|
|
4
4
|
import { TokenStatus, TokenSurrogate } from '@unchainedshop/types/warehousing';
|
|
5
|
-
|
|
5
|
+
type HelperType<T> = (root: TokenSurrogate, params: never, context: Context) => Promise<T>;
|
|
6
6
|
export interface TokenHelperTypes {
|
|
7
7
|
product: HelperType<Product>;
|
|
8
8
|
status: HelperType<TokenStatus>;
|
|
@@ -11,7 +11,7 @@ import { Quotation } from '@unchainedshop/types/quotations';
|
|
|
11
11
|
import { Email, User as UserType, UserProfile, Web3Address, WebAuthnCredentials } from '@unchainedshop/types/user';
|
|
12
12
|
import type { Locale } from 'locale';
|
|
13
13
|
import { TokenSurrogate } from '@unchainedshop/types/warehousing';
|
|
14
|
-
|
|
14
|
+
type HelperType<P, T> = (user: UserType, params: P, context: Context) => Promise<T>;
|
|
15
15
|
export interface UserHelperTypes {
|
|
16
16
|
_id: HelperType<any, boolean>;
|
|
17
17
|
avatar: HelperType<{
|
|
@@ -24,13 +24,11 @@ export interface UserHelperTypes {
|
|
|
24
24
|
country: HelperType<{
|
|
25
25
|
localeContext: Locale;
|
|
26
26
|
}, Country>;
|
|
27
|
-
email: HelperType<any, string>;
|
|
28
27
|
emails: HelperType<any, Array<string>>;
|
|
29
28
|
enrollments: HelperType<{
|
|
30
29
|
sort?: Array<SortOption>;
|
|
31
30
|
queryString?: string;
|
|
32
31
|
}, Array<Enrollment>>;
|
|
33
|
-
isEmailVerified: HelperType<any, boolean>;
|
|
34
32
|
isGuest: HelperType<any, boolean>;
|
|
35
33
|
isInitialPassword: HelperType<any, boolean>;
|
|
36
34
|
isTwoFactorEnabled: HelperType<any, boolean>;
|
|
@@ -1,4 +1,3 @@
|
|
|
1
|
-
import { log, LogLevel } from '@unchainedshop/logger';
|
|
2
1
|
import { checkAction, checkTypeResolver } from '../../acl';
|
|
3
2
|
import { actions } from '../../roles';
|
|
4
3
|
const { viewUserPrivateInfos, viewUserPublicInfos, viewUserOrders, viewUserEnrollments, viewUserQuotations, } = actions;
|
|
@@ -27,17 +26,6 @@ export const User = {
|
|
|
27
26
|
await checkAction(context, viewUserPrivateInfos, [user, params]);
|
|
28
27
|
return getPrimaryEmail(user);
|
|
29
28
|
},
|
|
30
|
-
email: async (user, params, context) => {
|
|
31
|
-
await checkAction(context, viewUserPrivateInfos, [user, params]);
|
|
32
|
-
return getPrimaryEmail(user)?.address;
|
|
33
|
-
},
|
|
34
|
-
isEmailVerified: async (user, params, context) => {
|
|
35
|
-
await checkAction(context, viewUserPrivateInfos, [user, params]);
|
|
36
|
-
log('user.isEmailVerified is deprecated, please use user.primaryEmail.verified', {
|
|
37
|
-
level: LogLevel.Warning,
|
|
38
|
-
});
|
|
39
|
-
return !!getPrimaryEmail(user)?.verified;
|
|
40
|
-
},
|
|
41
29
|
isInitialPassword: async (user, params, context) => {
|
|
42
30
|
await checkAction(context, viewUserPrivateInfos, [user, params]);
|
|
43
31
|
const { password: { initial } = { initial: undefined } } = user.services || {};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"user-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/user-types.ts"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"user-types.js","sourceRoot":"","sources":["../../../src/resolvers/type/user-types.ts"],"names":[],"mappings":"AAmBA,OAAO,EAAE,WAAW,EAAE,iBAAiB,EAAE,MAAM,WAAW,CAAC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AAC,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC;QACjE,OAAO,IAAI,CAAC,QAAQ,CAAC,IAAI,IAAI,EAAE,CAAC;IAClC,CAAC;IAED,UAAU,EAAE,KAAK,EAAE,IAAI,EAAE,MAAM,EAAE,OAAO,EAAE,EAAE;QAC1C,MAAM,WAAW,CAAC,OAAO,EAAE,kBAAkB,EAAE,CAAC,IAAI,EAAE,MAAM,CAAC,CAAC,CAAC;QAC/D,OAAO,OAAO,CAAC,OAAO,CAAC,UAAU,CAAC,cAAc,CAAC;YAC/C,MAAM,EAAE,IAAI,CAAC,GAAG;YAChB,IAAI,EAAE,MAAM,CAAC,IAAI;YACjB,WAAW,EAAE,MAAM,CAAC,WAAW;SAChC,CAAC,CAAC;IACL,CAAC;CACF,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Context } from '@unchainedshop/types/api';
|
|
2
2
|
import { WebAuthnCredentials as WebAuthnCredentialsTypes } from '@unchainedshop/types/user';
|
|
3
|
-
|
|
3
|
+
type HelperType<P, T> = (credentials: WebAuthnCredentialsTypes, params: P, context: Context) => Promise<T>;
|
|
4
4
|
export interface WebAuthnCredentialsHelperTypes {
|
|
5
5
|
_id: HelperType<any, string>;
|
|
6
6
|
created: HelperType<any, Date>;
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { Context } from '@unchainedshop/types/api';
|
|
2
2
|
import { Work as WorkType } from '@unchainedshop/types/worker';
|
|
3
|
-
|
|
3
|
+
type HelperType<P, T> = (work: WorkType, params: P, context: Context) => T;
|
|
4
4
|
export interface WorkHelperTypes {
|
|
5
5
|
status: HelperType<never, string>;
|
|
6
6
|
type: HelperType<never, string>;
|
|
File without changes
|
|
@@ -0,0 +1,15 @@
|
|
|
1
|
+
export default [
|
|
2
|
+
/* GraphQL */ `
|
|
3
|
+
enum CacheControlScope {
|
|
4
|
+
PUBLIC
|
|
5
|
+
PRIVATE
|
|
6
|
+
}
|
|
7
|
+
|
|
8
|
+
directive @cacheControl(
|
|
9
|
+
maxAge: Int
|
|
10
|
+
scope: CacheControlScope
|
|
11
|
+
inheritMaxAge: Boolean
|
|
12
|
+
) on FIELD_DEFINITION | OBJECT | INTERFACE | UNION
|
|
13
|
+
`,
|
|
14
|
+
];
|
|
15
|
+
//# sourceMappingURL=directives.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"directives.js","sourceRoot":"","sources":["../../src/schema/directives.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;GAWb;CACF,CAAC"}
|
package/lib/schema/index.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import scalars from './scalars';
|
|
2
|
+
import directives from './directives';
|
|
2
3
|
import types from './types';
|
|
3
4
|
import inputTypes from './inputTypes';
|
|
4
5
|
import query from './query';
|
|
5
6
|
import mutation from './mutation';
|
|
6
|
-
export default [...scalars, ...types, ...inputTypes, ...query, ...mutation];
|
|
7
|
+
export default [...scalars, ...directives, ...types, ...inputTypes, ...query, ...mutation];
|
|
7
8
|
//# sourceMappingURL=index.js.map
|
package/lib/schema/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schema/index.js"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,WAAW,CAAC;AAChC,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,eAAe,CAAC,GAAG,OAAO,EAAE,GAAG,KAAK,EAAE,GAAG,UAAU,EAAE,GAAG,KAAK,EAAE,GAAG,QAAQ,CAAC,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/schema/index.js"],"names":[],"mappings":"AAAA,OAAO,OAAO,MAAM,WAAW,CAAC;AAChC,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,UAAU,MAAM,cAAc,CAAC;AACtC,OAAO,KAAK,MAAM,SAAS,CAAC;AAC5B,OAAO,QAAQ,MAAM,YAAY,CAAC;AAElC,eAAe,CAAC,GAAG,OAAO,EAAE,GAAG,UAAU,EAAE,GAAG,KAAK,EAAE,GAAG,UAAU,EAAE,GAAG,KAAK,EAAE,GAAG,QAAQ,CAAC,CAAC"}
|
package/lib/schema/inputTypes.js
CHANGED
|
@@ -1,20 +1,5 @@
|
|
|
1
1
|
export default [
|
|
2
2
|
/* GraphQL */ `
|
|
3
|
-
"""
|
|
4
|
-
A hashed password
|
|
5
|
-
"""
|
|
6
|
-
input HashedPasswordInput {
|
|
7
|
-
"""
|
|
8
|
-
The hashed password
|
|
9
|
-
"""
|
|
10
|
-
digest: String!
|
|
11
|
-
|
|
12
|
-
"""
|
|
13
|
-
Algorithm used to hash the password
|
|
14
|
-
"""
|
|
15
|
-
algorithm: String!
|
|
16
|
-
}
|
|
17
|
-
|
|
18
3
|
input SortOptionInput {
|
|
19
4
|
key: String!
|
|
20
5
|
value: SortDirection!
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"inputTypes.js","sourceRoot":"","sources":["../../src/schema/inputTypes.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"inputTypes.js","sourceRoot":"","sources":["../../src/schema/inputTypes.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAqRb;CACF,CAAC"}
|
package/lib/schema/mutation.js
CHANGED
|
@@ -8,7 +8,6 @@ export default [
|
|
|
8
8
|
loginWithPassword(
|
|
9
9
|
username: String
|
|
10
10
|
email: String
|
|
11
|
-
password: HashedPasswordInput
|
|
12
11
|
plainPassword: String
|
|
13
12
|
totpCode: String
|
|
14
13
|
): LoginMethodResponse
|
|
@@ -31,10 +30,6 @@ export default [
|
|
|
31
30
|
createUser(
|
|
32
31
|
username: String
|
|
33
32
|
email: String
|
|
34
|
-
password: HashedPasswordInput
|
|
35
|
-
@deprecated(
|
|
36
|
-
reason: "Use plainPassword, there is not a lot of added security by hashing on the client"
|
|
37
|
-
)
|
|
38
33
|
webAuthnPublicKeyCredentials: JSON
|
|
39
34
|
plainPassword: String
|
|
40
35
|
profile: UserProfileInput
|
|
@@ -50,12 +45,7 @@ export default [
|
|
|
50
45
|
"""
|
|
51
46
|
Change the current user's password. Must be logged in.
|
|
52
47
|
"""
|
|
53
|
-
changePassword(
|
|
54
|
-
oldPassword: HashedPasswordInput
|
|
55
|
-
oldPlainPassword: String
|
|
56
|
-
newPassword: HashedPasswordInput
|
|
57
|
-
newPlainPassword: String
|
|
58
|
-
): SuccessResponse
|
|
48
|
+
changePassword(oldPlainPassword: String, newPlainPassword: String): SuccessResponse
|
|
59
49
|
|
|
60
50
|
"""
|
|
61
51
|
Request a forgot password email.
|
|
@@ -65,11 +55,7 @@ export default [
|
|
|
65
55
|
"""
|
|
66
56
|
Reset the password for a user using a token received in email. Logs the user in afterwards.
|
|
67
57
|
"""
|
|
68
|
-
resetPassword(
|
|
69
|
-
newPlainPassword: String
|
|
70
|
-
newPassword: HashedPasswordInput
|
|
71
|
-
token: String!
|
|
72
|
-
): LoginMethodResponse
|
|
58
|
+
resetPassword(newPlainPassword: String, token: String!): LoginMethodResponse
|
|
73
59
|
|
|
74
60
|
"""
|
|
75
61
|
Log the user out.
|
|
@@ -348,12 +334,7 @@ export default [
|
|
|
348
334
|
"""
|
|
349
335
|
Enroll a new user, setting enroll to true will let the user choose his password (e-mail gets sent)
|
|
350
336
|
"""
|
|
351
|
-
enrollUser(
|
|
352
|
-
profile: UserProfileInput!
|
|
353
|
-
email: String!
|
|
354
|
-
password: HashedPasswordInput
|
|
355
|
-
plainPassword: String
|
|
356
|
-
): User
|
|
337
|
+
enrollUser(profile: UserProfileInput!, email: String!, plainPassword: String): User
|
|
357
338
|
|
|
358
339
|
"""
|
|
359
340
|
Forcefully trigger an enrollment email for already added users by e-mail
|
|
@@ -368,7 +349,7 @@ export default [
|
|
|
368
349
|
"""
|
|
369
350
|
Set a new password for a specific user
|
|
370
351
|
"""
|
|
371
|
-
setPassword(
|
|
352
|
+
setPassword(newPlainPassword: String, userId: ID!): User
|
|
372
353
|
|
|
373
354
|
"""
|
|
374
355
|
Set roles of a user
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"mutation.js","sourceRoot":"","sources":["../../src/schema/mutation.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"mutation.js","sourceRoot":"","sources":["../../src/schema/mutation.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAk3Bb;CACF,CAAC"}
|
package/lib/schema/query.js
CHANGED
|
@@ -35,7 +35,7 @@ export default [
|
|
|
35
35
|
slugs: [String!]
|
|
36
36
|
includeDrafts: Boolean = false
|
|
37
37
|
queryString: String
|
|
38
|
-
): Int!
|
|
38
|
+
): Int! @cacheControl(maxAge: 180)
|
|
39
39
|
|
|
40
40
|
"""
|
|
41
41
|
Simple list of published products filtered either by tags or explicit slugs
|
|
@@ -60,16 +60,18 @@ export default [
|
|
|
60
60
|
List products specified prices
|
|
61
61
|
"""
|
|
62
62
|
productCatalogPrices(productId: ID!): [ProductCatalogPrice!]!
|
|
63
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
63
64
|
|
|
64
65
|
"""
|
|
65
66
|
Localization: Meta data for product
|
|
66
67
|
"""
|
|
67
|
-
translatedProductTexts(productId: ID!): [ProductTexts!]!
|
|
68
|
+
translatedProductTexts(productId: ID!): [ProductTexts!]! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
68
69
|
|
|
69
70
|
"""
|
|
70
71
|
Localization: Media title/subtitle of a media that is attached to a product
|
|
71
72
|
"""
|
|
72
73
|
translatedProductMediaTexts(productMediaId: ID!): [ProductMediaTexts!]!
|
|
74
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
73
75
|
|
|
74
76
|
"""
|
|
75
77
|
Localization: Variations and Variation Options
|
|
@@ -77,12 +79,13 @@ export default [
|
|
|
77
79
|
translatedProductVariationTexts(
|
|
78
80
|
productVariationId: ID!
|
|
79
81
|
productVariationOptionValue: String
|
|
80
|
-
): [ProductVariationTexts!]!
|
|
82
|
+
): [ProductVariationTexts!]! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
81
83
|
|
|
82
84
|
"""
|
|
83
85
|
Returns total number languages
|
|
84
86
|
"""
|
|
85
87
|
languagesCount(includeInactive: Boolean = false, queryString: String): Int!
|
|
88
|
+
@cacheControl(maxAge: 180)
|
|
86
89
|
|
|
87
90
|
"""
|
|
88
91
|
Get all languages
|
|
@@ -115,6 +118,7 @@ export default [
|
|
|
115
118
|
Returns total number of countries
|
|
116
119
|
"""
|
|
117
120
|
countriesCount(includeInactive: Boolean = false, queryString: String): Int!
|
|
121
|
+
@cacheControl(maxAge: 180)
|
|
118
122
|
|
|
119
123
|
"""
|
|
120
124
|
Get a specific country by ID
|
|
@@ -125,6 +129,7 @@ export default [
|
|
|
125
129
|
Returns total number of currencies
|
|
126
130
|
"""
|
|
127
131
|
currenciesCount(includeInactive: Boolean = false, queryString: String): Int!
|
|
132
|
+
@cacheControl(maxAge: 180)
|
|
128
133
|
|
|
129
134
|
"""
|
|
130
135
|
Get all currencies
|
|
@@ -145,42 +150,49 @@ export default [
|
|
|
145
150
|
"""
|
|
146
151
|
Returns total number of delivery providers, optionally filtered by type
|
|
147
152
|
"""
|
|
148
|
-
deliveryProvidersCount(type: DeliveryProviderType): Int!
|
|
153
|
+
deliveryProvidersCount(type: DeliveryProviderType): Int! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
149
154
|
|
|
150
155
|
"""
|
|
151
156
|
Get all delivery providers, optionally filtered by type
|
|
152
157
|
"""
|
|
153
158
|
deliveryProviders(type: DeliveryProviderType): [DeliveryProvider!]!
|
|
159
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
154
160
|
|
|
155
161
|
"""
|
|
156
162
|
Get a specific delivery provider by ID
|
|
157
163
|
"""
|
|
158
164
|
deliveryProvider(deliveryProviderId: ID!): DeliveryProvider
|
|
165
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
159
166
|
|
|
160
167
|
"""
|
|
161
168
|
Get all delivery interfaces filtered by type
|
|
162
169
|
"""
|
|
163
170
|
deliveryInterfaces(type: DeliveryProviderType!): [DeliveryInterface!]!
|
|
171
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
164
172
|
|
|
165
173
|
"""
|
|
166
174
|
Returns total number of delivery providers, optionally filtered by type
|
|
167
175
|
"""
|
|
168
176
|
warehousingProvidersCount(type: WarehousingProviderType): Int!
|
|
177
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
169
178
|
|
|
170
179
|
"""
|
|
171
180
|
Get all warehousing providers, optionally filtered by type
|
|
172
181
|
"""
|
|
173
182
|
warehousingProviders(type: WarehousingProviderType): [WarehousingProvider!]!
|
|
183
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
174
184
|
|
|
175
185
|
"""
|
|
176
186
|
Get a specific warehousing provider by ID
|
|
177
187
|
"""
|
|
178
188
|
warehousingProvider(warehousingProviderId: ID!): WarehousingProvider
|
|
189
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
179
190
|
|
|
180
191
|
"""
|
|
181
192
|
Get all warehousing interfaces filtered by type
|
|
182
193
|
"""
|
|
183
194
|
warehousingInterfaces(type: WarehousingProviderType!): [WarehousingInterface!]!
|
|
195
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
184
196
|
|
|
185
197
|
"""
|
|
186
198
|
Get token
|
|
@@ -190,22 +202,24 @@ export default [
|
|
|
190
202
|
"""
|
|
191
203
|
Returns total number of payment providers, optionally filtered by type
|
|
192
204
|
"""
|
|
193
|
-
paymentProvidersCount(type: PaymentProviderType): Int!
|
|
205
|
+
paymentProvidersCount(type: PaymentProviderType): Int! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
194
206
|
|
|
195
207
|
"""
|
|
196
208
|
Get all payment providers, optionally filtered by type
|
|
197
209
|
"""
|
|
198
210
|
paymentProviders(type: PaymentProviderType): [PaymentProvider!]!
|
|
211
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
199
212
|
|
|
200
213
|
"""
|
|
201
214
|
Get a specific payment provider by ID
|
|
202
215
|
"""
|
|
203
|
-
paymentProvider(paymentProviderId: ID!): PaymentProvider
|
|
216
|
+
paymentProvider(paymentProviderId: ID!): PaymentProvider @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
204
217
|
|
|
205
218
|
"""
|
|
206
219
|
Get all payment interfaces filtered by type
|
|
207
220
|
"""
|
|
208
221
|
paymentInterfaces(type: PaymentProviderType!): [PaymentInterface!]!
|
|
222
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
209
223
|
|
|
210
224
|
"""
|
|
211
225
|
Returns total number of orders
|
|
@@ -256,7 +270,7 @@ export default [
|
|
|
256
270
|
includeInactive: Boolean = false
|
|
257
271
|
includeLeaves: Boolean = false
|
|
258
272
|
queryString: String
|
|
259
|
-
): Int!
|
|
273
|
+
): Int! @cacheControl(maxAge: 180)
|
|
260
274
|
|
|
261
275
|
"""
|
|
262
276
|
Get a specific assortment by ID
|
|
@@ -267,21 +281,25 @@ export default [
|
|
|
267
281
|
Localization: Meta data for assortments
|
|
268
282
|
"""
|
|
269
283
|
translatedAssortmentTexts(assortmentId: ID!): [AssortmentTexts!]!
|
|
284
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
270
285
|
|
|
271
286
|
"""
|
|
272
287
|
Localization: Media title/subtitle of a media that is attached to a assortment
|
|
273
288
|
"""
|
|
274
289
|
translatedAssortmentMediaTexts(assortmentMediaId: ID!): [AssortmentMediaTexts!]!
|
|
290
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
275
291
|
|
|
276
292
|
"""
|
|
277
293
|
Localization: Filters and Filter Options
|
|
278
294
|
"""
|
|
279
295
|
translatedFilterTexts(filterId: ID!, filterOptionValue: String): [FilterTexts!]!
|
|
296
|
+
@cacheControl(scope: PRIVATE, maxAge: 0)
|
|
280
297
|
|
|
281
298
|
"""
|
|
282
299
|
Returns total number of filters
|
|
283
300
|
"""
|
|
284
301
|
filtersCount(includeInactive: Boolean = false, queryString: String): Int!
|
|
302
|
+
@cacheControl(maxAge: 180)
|
|
285
303
|
|
|
286
304
|
"""
|
|
287
305
|
Get all filters
|
|
@@ -302,7 +320,7 @@ export default [
|
|
|
302
320
|
"""
|
|
303
321
|
Returns total number of product reviews
|
|
304
322
|
"""
|
|
305
|
-
productReviewsCount(queryString: String): Int!
|
|
323
|
+
productReviewsCount(queryString: String): Int! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
306
324
|
|
|
307
325
|
"""
|
|
308
326
|
Get all product reviews
|
|
@@ -312,12 +330,12 @@ export default [
|
|
|
312
330
|
offset: Int = 0
|
|
313
331
|
sort: [SortOptionInput!]
|
|
314
332
|
queryString: String
|
|
315
|
-
): [ProductReview!]!
|
|
333
|
+
): [ProductReview!]! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
316
334
|
|
|
317
335
|
"""
|
|
318
336
|
Get a specific product review by ID
|
|
319
337
|
"""
|
|
320
|
-
productReview(productReviewId: ID!): ProductReview!
|
|
338
|
+
productReview(productReviewId: ID!): ProductReview! @cacheControl(scope: PRIVATE, maxAge: 0)
|
|
321
339
|
|
|
322
340
|
"""
|
|
323
341
|
Returns total number of quotations
|
package/lib/schema/query.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"query.js","sourceRoot":"","sources":["../../src/schema/query.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"query.js","sourceRoot":"","sources":["../../src/schema/query.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAucb;CACF,CAAC"}
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
export default [
|
|
2
2
|
/* GraphQL */ `
|
|
3
|
-
type AssortmentMediaTexts {
|
|
3
|
+
type AssortmentMediaTexts @cacheControl(maxAge: 180) {
|
|
4
4
|
_id: ID!
|
|
5
5
|
locale: String
|
|
6
6
|
title: String
|
|
7
7
|
subtitle: String
|
|
8
8
|
}
|
|
9
9
|
|
|
10
|
-
type AssortmentMedia {
|
|
10
|
+
type AssortmentMedia @cacheControl(maxAge: 180) {
|
|
11
11
|
_id: ID!
|
|
12
12
|
tags: [LowerCaseString!]
|
|
13
13
|
file: Media!
|
|
@@ -18,7 +18,7 @@ export default [
|
|
|
18
18
|
"""
|
|
19
19
|
Assortment
|
|
20
20
|
"""
|
|
21
|
-
type Assortment {
|
|
21
|
+
type Assortment @cacheControl(maxAge: 180) {
|
|
22
22
|
_id: ID!
|
|
23
23
|
created: DateTime
|
|
24
24
|
updated: DateTime
|
|
@@ -47,7 +47,7 @@ export default [
|
|
|
47
47
|
"""
|
|
48
48
|
Directed assortment to product paths (breadcrumbs)
|
|
49
49
|
"""
|
|
50
|
-
type AssortmentPath {
|
|
50
|
+
type AssortmentPath @cacheControl(maxAge: 180) {
|
|
51
51
|
links: [AssortmentPathLink!]!
|
|
52
52
|
}
|
|
53
53
|
|
|
@@ -56,14 +56,13 @@ export default [
|
|
|
56
56
|
assortmentId and assortmentTexts are there for convenience
|
|
57
57
|
to short-circuit breadcrumb lookups
|
|
58
58
|
"""
|
|
59
|
-
type AssortmentPathLink {
|
|
59
|
+
type AssortmentPathLink @cacheControl(maxAge: 180) {
|
|
60
60
|
assortmentId: ID!
|
|
61
|
-
assortmentSlug: String! @deprecated(reason: "Please use assortmentTexts")
|
|
62
61
|
assortmentTexts(forceLocale: String): AssortmentTexts!
|
|
63
62
|
link: AssortmentLink
|
|
64
63
|
}
|
|
65
64
|
|
|
66
|
-
type AssortmentProduct {
|
|
65
|
+
type AssortmentProduct @cacheControl(maxAge: 180) {
|
|
67
66
|
_id: ID!
|
|
68
67
|
sortKey: Int!
|
|
69
68
|
tags: [LowerCaseString!]
|
|
@@ -71,7 +70,7 @@ export default [
|
|
|
71
70
|
product: Product!
|
|
72
71
|
}
|
|
73
72
|
|
|
74
|
-
type AssortmentFilter {
|
|
73
|
+
type AssortmentFilter @cacheControl(maxAge: 180) {
|
|
75
74
|
_id: ID!
|
|
76
75
|
sortKey: Int!
|
|
77
76
|
tags: [LowerCaseString!]
|
|
@@ -79,7 +78,7 @@ export default [
|
|
|
79
78
|
filter: Filter!
|
|
80
79
|
}
|
|
81
80
|
|
|
82
|
-
type AssortmentLink {
|
|
81
|
+
type AssortmentLink @cacheControl(maxAge: 180) {
|
|
83
82
|
_id: ID!
|
|
84
83
|
sortKey: Int!
|
|
85
84
|
tags: [LowerCaseString!]
|
|
@@ -87,7 +86,7 @@ export default [
|
|
|
87
86
|
child: Assortment!
|
|
88
87
|
}
|
|
89
88
|
|
|
90
|
-
type AssortmentTexts {
|
|
89
|
+
type AssortmentTexts @cacheControl(maxAge: 180) {
|
|
91
90
|
_id: ID!
|
|
92
91
|
locale: String
|
|
93
92
|
slug: String
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"assortment.js","sourceRoot":"","sources":["../../../src/schema/types/assortment.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"assortment.js","sourceRoot":"","sources":["../../../src/schema/types/assortment.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA+Fb;CACF,CAAC"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
export default [
|
|
2
2
|
/* GraphQL */ `
|
|
3
|
-
type DeliveryInterface {
|
|
3
|
+
type DeliveryInterface @cacheControl(maxAge: 180) {
|
|
4
4
|
_id: ID!
|
|
5
5
|
label: String
|
|
6
6
|
version: String
|
|
@@ -25,7 +25,7 @@ export default [
|
|
|
25
25
|
WRONG_CREDENTIALS
|
|
26
26
|
}
|
|
27
27
|
|
|
28
|
-
type DeliveryProvider {
|
|
28
|
+
type DeliveryProvider @cacheControl(maxAge: 60) {
|
|
29
29
|
_id: ID!
|
|
30
30
|
created: DateTime
|
|
31
31
|
updated: DateTime
|
|
@@ -36,6 +36,7 @@ export default [
|
|
|
36
36
|
configurationError: DeliveryProviderError
|
|
37
37
|
isActive: Boolean
|
|
38
38
|
simulatedPrice(currency: String, useNetPrice: Boolean = false, orderId: ID, context: JSON): Price
|
|
39
|
+
@cacheControl(scope: PRIVATE, maxAge: 10)
|
|
39
40
|
}
|
|
40
41
|
`,
|
|
41
42
|
];
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"delivery.js","sourceRoot":"","sources":["../../../src/schema/types/delivery.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC
|
|
1
|
+
{"version":3,"file":"delivery.js","sourceRoot":"","sources":["../../../src/schema/types/delivery.js"],"names":[],"mappings":"AAAA,eAAe;IACb,aAAa,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAuCb;CACF,CAAC"}
|