@escapenavigator/services 1.4.20 → 1.4.21
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/dist/api/agb-api/update.js +1 -1
- package/dist/api/agregator-api/find-cities-by-country.js +2 -2
- package/dist/api/agregator-api/find-city-by-slug.js +2 -2
- package/dist/api/agregator-api/find-current-city.js +2 -2
- package/dist/api/agregator-api/find-locations-by-coordinates.js +2 -2
- package/dist/api/agregator-api/find-popular-cities-near.js +2 -2
- package/dist/api/agregator-api/find-post-by-slug.d.ts +1 -1
- package/dist/api/agregator-api/find-post-by-slug.js +1 -1
- package/dist/api/agregator-api/find-questroom-by-slug.js +1 -1
- package/dist/api/agregator-api/find-questrooms-by-city-slug.js +1 -1
- package/dist/api/agregator-api/find-questrooms-by-location-id.js +2 -2
- package/dist/api/agregator-api/find-questrooms-by-organization-id.js +2 -2
- package/dist/api/agregator-api/find-questrooms-by-tags.js +1 -1
- package/dist/api/agregator-api/find-questrooms-by-title.js +2 -2
- package/dist/api/agregator-api/find-questrooms-for-main-page.js +2 -2
- package/dist/api/agregator-api/find-questrooms-search-count.d.ts +7 -0
- package/dist/api/agregator-api/find-questrooms-search-count.js +9 -0
- package/dist/api/agregator-api/find-questrooms-search.d.ts +7 -0
- package/dist/api/agregator-api/find-questrooms-search.js +9 -0
- package/dist/api/agregator-api/find-questrooms-with-certificates.d.ts +6 -0
- package/dist/api/agregator-api/find-questrooms-with-certificates.js +8 -0
- package/dist/api/agregator-api/find-similar-questrooms-near.d.ts +1 -1
- package/dist/api/agregator-api/find-similar-questrooms-near.js +1 -1
- package/dist/api/agregator-api/index.d.ts +12 -6
- package/dist/api/agregator-api/index.js +12 -6
- package/dist/api/cities-api/index.d.ts +1 -1
- package/dist/api/cities-api/index.js +1 -1
- package/dist/api/cities-api/query.js +1 -1
- package/dist/api/cities-api/update.d.ts +1 -1
- package/dist/api/clients-api/create-from-widget.d.ts +1 -1
- package/dist/api/locations-api/index.d.ts +1 -1
- package/dist/api/locations-api/index.js +1 -1
- package/dist/api/profiles-api/index.d.ts +1 -1
- package/dist/api/profiles-api/index.js +2 -2
- package/dist/api/profiles-api/update-current.js +1 -1
- package/dist/api/questrooms-api/index.d.ts +3 -3
- package/dist/api/questrooms-api/index.js +4 -4
- package/dist/api/widgets-openapi/create-certificate.js +2 -2
- package/dist/api/widgets-openapi/create-order.d.ts +1 -1
- package/dist/api/widgets-openapi/create-order.js +2 -2
- package/dist/api/widgets-openapi/create-review.d.ts +9 -0
- package/dist/api/widgets-openapi/create-review.js +12 -0
- package/dist/api/widgets-openapi/find-certificate.js +2 -2
- package/dist/api/widgets-openapi/find-reviews.d.ts +7 -0
- package/dist/api/widgets-openapi/find-reviews.js +9 -0
- package/dist/api/widgets-openapi/index.d.ts +7 -3
- package/dist/api/widgets-openapi/index.js +8 -4
- package/dist/utils/convert-to-options.js +6 -4
- package/dist/utils/enum-to-options.js +6 -4
- package/dist/utils/get-handled-error-message.js +3 -1
- package/package.json +3 -3
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findCitiesByCountry = void 0;
|
|
4
4
|
var findCitiesByCountry = function (country) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/cities/country/".concat(country),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findCitiesByCountry = findCitiesByCountry;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findCityBySlug = void 0;
|
|
4
4
|
var findCityBySlug = function (slug) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/city/slug/".concat(slug),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findCityBySlug = findCityBySlug;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findCurrentCity = void 0;
|
|
4
4
|
var findCurrentCity = function (ip) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/city/current/".concat(ip),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findCurrentCity = findCurrentCity;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findLocationsByCoordinates = void 0;
|
|
4
4
|
var findLocationsByCoordinates = function (latlng) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/locations/coordinates/".concat(latlng),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findLocationsByCoordinates = findLocationsByCoordinates;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findPopularCitiesNear = void 0;
|
|
4
4
|
var findPopularCitiesNear = function (slug) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/cities/near/".concat(slug),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findPopularCitiesNear = findPopularCitiesNear;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AgregatorPostBySlugDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-post-by-slug.dto';
|
|
2
1
|
import { AgregatorPostRO } from '@escapenavigator/types/dist/agregator/agregator-post.ro';
|
|
2
|
+
import { AgregatorPostBySlugDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-post-by-slug.dto';
|
|
3
3
|
import { ApiMethodDeclaration } from '..';
|
|
4
4
|
declare type ParamsData = AgregatorPostBySlugDTO;
|
|
5
5
|
declare type ResponseData = AgregatorPostRO;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findQuestroomsByLocationId = void 0;
|
|
4
4
|
var findQuestroomsByLocationId = function (locationId) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/questrooms/location/".concat(locationId),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findQuestroomsByLocationId = findQuestroomsByLocationId;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findQuestroomsByOrganizationId = void 0;
|
|
4
4
|
var findQuestroomsByOrganizationId = function (organizationSlug) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/questrooms/organization/".concat(organizationSlug),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findQuestroomsByOrganizationId = findQuestroomsByOrganizationId;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findQuestroomsByTitle = void 0;
|
|
4
4
|
var findQuestroomsByTitle = function (text) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/questrooms/title/".concat(text),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findQuestroomsByTitle = findQuestroomsByTitle;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findQuestroomsForMainPage = void 0;
|
|
4
4
|
var findQuestroomsForMainPage = function (slug) { return ({
|
|
5
|
-
url:
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/agregator/questrooms/mainpage/".concat(slug),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findQuestroomsForMainPage = findQuestroomsForMainPage;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AgregatorQuestroomByTagsRO } from '@escapenavigator/types/dist/agregator/agregator-questroom-by-tags.ro';
|
|
2
|
+
import { AgregatorQuestroomsSearchDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-questrooms-search.dto';
|
|
3
|
+
import { ApiMethodDeclaration } from '..';
|
|
4
|
+
declare type ParamsData = AgregatorQuestroomsSearchDTO;
|
|
5
|
+
declare type ResponseData = AgregatorQuestroomByTagsRO[];
|
|
6
|
+
export declare const findQuestroomsSearchCount: ApiMethodDeclaration<ParamsData, ResponseData>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.findQuestroomsSearchCount = void 0;
|
|
4
|
+
var findQuestroomsSearchCount = function (params) { return ({
|
|
5
|
+
url: '/agregator/questrooms/search/count',
|
|
6
|
+
method: 'GET',
|
|
7
|
+
params: params,
|
|
8
|
+
}); };
|
|
9
|
+
exports.findQuestroomsSearchCount = findQuestroomsSearchCount;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { AgregatorQuestroomByTagsRO } from '@escapenavigator/types/dist/agregator/agregator-questroom-by-tags.ro';
|
|
2
|
+
import { AgregatorQuestroomsSearchDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-questrooms-search.dto';
|
|
3
|
+
import { ApiMethodDeclaration } from '..';
|
|
4
|
+
declare type ParamsData = AgregatorQuestroomsSearchDTO;
|
|
5
|
+
declare type ResponseData = AgregatorQuestroomByTagsRO[];
|
|
6
|
+
export declare const findQuestroomsSearch: ApiMethodDeclaration<ParamsData, ResponseData>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.findQuestroomsSearch = void 0;
|
|
4
|
+
var findQuestroomsSearch = function (params) { return ({
|
|
5
|
+
url: '/agregator/questrooms/search',
|
|
6
|
+
method: 'GET',
|
|
7
|
+
params: params,
|
|
8
|
+
}); };
|
|
9
|
+
exports.findQuestroomsSearch = findQuestroomsSearch;
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { AgregatorCityQuestroomsRO } from '@escapenavigator/types/dist/agregator/agregator-city-questrooms.ro';
|
|
2
|
+
import { ApiMethodDeclaration } from '..';
|
|
3
|
+
declare type ParamsData = string;
|
|
4
|
+
declare type ResponseData = AgregatorCityQuestroomsRO[];
|
|
5
|
+
export declare const findQuestroomsWithCertificates: ApiMethodDeclaration<ParamsData, ResponseData>;
|
|
6
|
+
export {};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.findQuestroomsWithCertificates = void 0;
|
|
4
|
+
var findQuestroomsWithCertificates = function (slug) { return ({
|
|
5
|
+
url: "/agregator/questrooms/certificates/".concat(slug),
|
|
6
|
+
method: 'GET',
|
|
7
|
+
}); };
|
|
8
|
+
exports.findQuestroomsWithCertificates = findQuestroomsWithCertificates;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { AgregatorSimilarQuestromsNearQueryDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-similar-questrooms-near-query.dto';
|
|
2
1
|
import { AgregatorSimilarQuestroomsNearRO } from '@escapenavigator/types/dist/agregator/agregator-similar-questrooms-near.ro';
|
|
2
|
+
import { AgregatorSimilarQuestromsNearQueryDTO } from '@escapenavigator/types/dist/agregator/dto/agregator-similar-questrooms-near-query.dto';
|
|
3
3
|
import { ApiMethodDeclaration } from '..';
|
|
4
4
|
declare type ParamsData = AgregatorSimilarQuestromsNearQueryDTO;
|
|
5
5
|
declare type ResponseData = AgregatorSimilarQuestroomsNearRO[];
|
|
@@ -1,21 +1,25 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { findPopularPosts } from './find-popular-posts';
|
|
3
|
-
import { findPosts } from './find-posts';
|
|
1
|
+
import { createSubscription } from './create-subscription';
|
|
4
2
|
import { findCitiesByCountry } from './find-cities-by-country';
|
|
5
3
|
import { findCityBySlug } from './find-city-by-slug';
|
|
6
4
|
import { findCurrentCity } from './find-current-city';
|
|
7
5
|
import { findLocationsByCoordinates } from './find-locations-by-coordinates';
|
|
8
6
|
import { findPopularCitiesNear } from './find-popular-cities-near';
|
|
7
|
+
import { findPopularPosts } from './find-popular-posts';
|
|
8
|
+
import { findPostBySlug } from './find-post-by-slug';
|
|
9
|
+
import { findPosts } from './find-posts';
|
|
10
|
+
import { findQuestroomBySlug } from './find-questroom-by-slug';
|
|
9
11
|
import { findQuestroomsByCitySlug } from './find-questrooms-by-city-slug';
|
|
10
12
|
import { findQuestroomsByLocationId } from './find-questrooms-by-location-id';
|
|
11
13
|
import { findQuestroomsByOrganizationId } from './find-questrooms-by-organization-id';
|
|
12
14
|
import { findQuestroomsByTags } from './find-questrooms-by-tags';
|
|
13
15
|
import { findQuestroomsByTitle } from './find-questrooms-by-title';
|
|
14
|
-
import { findSimilaQuestroomsNear } from './find-similar-questrooms-near';
|
|
15
|
-
import { findQuestroomBySlug } from './find-questroom-by-slug';
|
|
16
16
|
import { findQuestroomsForMainPage } from './find-questrooms-for-main-page';
|
|
17
|
-
import {
|
|
17
|
+
import { findQuestroomsSearch } from './find-questrooms-search';
|
|
18
|
+
import { findQuestroomsSearchCount } from './find-questrooms-search-count';
|
|
19
|
+
import { findQuestroomsWithCertificates } from './find-questrooms-with-certificates';
|
|
20
|
+
import { findSimilaQuestroomsNear } from './find-similar-questrooms-near';
|
|
18
21
|
declare type ApiDeclaration = {
|
|
22
|
+
findQuestroomsWithCertificates: typeof findQuestroomsWithCertificates;
|
|
19
23
|
findQuestroomsForMainPage: typeof findQuestroomsForMainPage;
|
|
20
24
|
findCitiesByCountry: typeof findCitiesByCountry;
|
|
21
25
|
findQuestroomBySlug: typeof findQuestroomBySlug;
|
|
@@ -33,6 +37,8 @@ declare type ApiDeclaration = {
|
|
|
33
37
|
findPopularPosts: typeof findPopularPosts;
|
|
34
38
|
findPostBySlug: typeof findPostBySlug;
|
|
35
39
|
createSubscription: typeof createSubscription;
|
|
40
|
+
findQuestroomsSearch: typeof findQuestroomsSearch;
|
|
41
|
+
findQuestroomsSearchCount: typeof findQuestroomsSearchCount;
|
|
36
42
|
};
|
|
37
43
|
export declare const agregatorApiDeclaration: ApiDeclaration;
|
|
38
44
|
export {};
|
|
@@ -1,25 +1,29 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.agregatorApiDeclaration = void 0;
|
|
4
|
-
var
|
|
5
|
-
var find_popular_posts_1 = require("./find-popular-posts");
|
|
6
|
-
var find_posts_1 = require("./find-posts");
|
|
4
|
+
var create_subscription_1 = require("./create-subscription");
|
|
7
5
|
var find_cities_by_country_1 = require("./find-cities-by-country");
|
|
8
6
|
var find_city_by_slug_1 = require("./find-city-by-slug");
|
|
9
7
|
var find_current_city_1 = require("./find-current-city");
|
|
10
8
|
var find_locations_by_coordinates_1 = require("./find-locations-by-coordinates");
|
|
11
9
|
var find_popular_cities_near_1 = require("./find-popular-cities-near");
|
|
10
|
+
var find_popular_posts_1 = require("./find-popular-posts");
|
|
11
|
+
var find_post_by_slug_1 = require("./find-post-by-slug");
|
|
12
|
+
var find_posts_1 = require("./find-posts");
|
|
13
|
+
var find_questroom_by_slug_1 = require("./find-questroom-by-slug");
|
|
12
14
|
var find_questrooms_by_city_slug_1 = require("./find-questrooms-by-city-slug");
|
|
13
15
|
var find_questrooms_by_location_id_1 = require("./find-questrooms-by-location-id");
|
|
14
16
|
var find_questrooms_by_organization_id_1 = require("./find-questrooms-by-organization-id");
|
|
15
17
|
var find_questrooms_by_tags_1 = require("./find-questrooms-by-tags");
|
|
16
18
|
var find_questrooms_by_title_1 = require("./find-questrooms-by-title");
|
|
17
|
-
var find_similar_questrooms_near_1 = require("./find-similar-questrooms-near");
|
|
18
|
-
var find_questroom_by_slug_1 = require("./find-questroom-by-slug");
|
|
19
19
|
var find_questrooms_for_main_page_1 = require("./find-questrooms-for-main-page");
|
|
20
|
-
var
|
|
20
|
+
var find_questrooms_search_1 = require("./find-questrooms-search");
|
|
21
|
+
var find_questrooms_search_count_1 = require("./find-questrooms-search-count");
|
|
22
|
+
var find_questrooms_with_certificates_1 = require("./find-questrooms-with-certificates");
|
|
23
|
+
var find_similar_questrooms_near_1 = require("./find-similar-questrooms-near");
|
|
21
24
|
exports.agregatorApiDeclaration = {
|
|
22
25
|
findQuestroomsForMainPage: find_questrooms_for_main_page_1.findQuestroomsForMainPage,
|
|
26
|
+
findQuestroomsWithCertificates: find_questrooms_with_certificates_1.findQuestroomsWithCertificates,
|
|
23
27
|
findCitiesByCountry: find_cities_by_country_1.findCitiesByCountry,
|
|
24
28
|
findQuestroomBySlug: find_questroom_by_slug_1.findQuestroomBySlug,
|
|
25
29
|
findCityBySlug: find_city_by_slug_1.findCityBySlug,
|
|
@@ -36,4 +40,6 @@ exports.agregatorApiDeclaration = {
|
|
|
36
40
|
findPopularPosts: find_popular_posts_1.findPopularPosts,
|
|
37
41
|
findPostBySlug: find_post_by_slug_1.findPostBySlug,
|
|
38
42
|
createSubscription: create_subscription_1.createSubscription,
|
|
43
|
+
findQuestroomsSearch: find_questrooms_search_1.findQuestroomsSearch,
|
|
44
|
+
findQuestroomsSearchCount: find_questrooms_search_count_1.findQuestroomsSearchCount,
|
|
39
45
|
};
|
|
@@ -2,8 +2,8 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.citiesApiDeclaration = void 0;
|
|
4
4
|
var get_one_1 = require("./get-one");
|
|
5
|
-
var update_1 = require("./update");
|
|
6
5
|
var remove_1 = require("./remove");
|
|
6
|
+
var update_1 = require("./update");
|
|
7
7
|
exports.citiesApiDeclaration = {
|
|
8
8
|
getOne: get_one_1.getOne,
|
|
9
9
|
update: update_1.update,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { UpdateCityDto } from '@escapenavigator/types/dist/city/update-city.dto';
|
|
2
1
|
import { CityResponseObject } from '@escapenavigator/types/dist/city/city.ro';
|
|
2
|
+
import { UpdateCityDto } from '@escapenavigator/types/dist/city/update-city.dto';
|
|
3
3
|
import { ApiMethodDeclaration } from '..';
|
|
4
4
|
declare type ParamsData = {
|
|
5
5
|
id: number;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { CreateClientFromWidgetDto } from '@escapenavigator/types/dist/client/create-client-from-widget.dto';
|
|
2
1
|
import { ClientResponseObject } from '@escapenavigator/types/dist/client/client.ro';
|
|
2
|
+
import { CreateClientFromWidgetDto } from '@escapenavigator/types/dist/client/create-client-from-widget.dto';
|
|
3
3
|
import { ApiMethodDeclaration } from '..';
|
|
4
4
|
declare type ParamsData = {
|
|
5
5
|
data: CreateClientFromWidgetDto;
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { create } from './create';
|
|
2
|
+
import { getByCoordinates } from './get-by-coordinates';
|
|
2
3
|
import { getOne } from './get-one';
|
|
3
4
|
import { query } from './query';
|
|
4
5
|
import { recover } from './recover';
|
|
5
6
|
import { remove } from './remove';
|
|
6
7
|
import { update } from './update';
|
|
7
|
-
import { getByCoordinates } from './get-by-coordinates';
|
|
8
8
|
declare type ApiDeclaration = {
|
|
9
9
|
create: typeof create;
|
|
10
10
|
remove: typeof remove;
|
|
@@ -2,12 +2,12 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.locationsApiDeclaration = void 0;
|
|
4
4
|
var create_1 = require("./create");
|
|
5
|
+
var get_by_coordinates_1 = require("./get-by-coordinates");
|
|
5
6
|
var get_one_1 = require("./get-one");
|
|
6
7
|
var query_1 = require("./query");
|
|
7
8
|
var recover_1 = require("./recover");
|
|
8
9
|
var remove_1 = require("./remove");
|
|
9
10
|
var update_1 = require("./update");
|
|
10
|
-
var get_by_coordinates_1 = require("./get-by-coordinates");
|
|
11
11
|
exports.locationsApiDeclaration = {
|
|
12
12
|
create: create_1.create,
|
|
13
13
|
remove: remove_1.remove,
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import { create } from './create';
|
|
2
2
|
import { current } from './current';
|
|
3
|
+
import { getBySlug } from './get-by-slug';
|
|
3
4
|
import { getOne } from './get-one';
|
|
4
5
|
import { query } from './query';
|
|
5
6
|
import { remove } from './remove';
|
|
6
7
|
import { update } from './update';
|
|
7
|
-
import { getBySlug } from './get-by-slug';
|
|
8
8
|
declare type ApiDeclaration = {
|
|
9
9
|
create: typeof create;
|
|
10
10
|
remove: typeof remove;
|
|
@@ -3,11 +3,11 @@ Object.defineProperty(exports, "__esModule", { value: true });
|
|
|
3
3
|
exports.profilesApiDeclaration = void 0;
|
|
4
4
|
var create_1 = require("./create");
|
|
5
5
|
var current_1 = require("./current");
|
|
6
|
+
var get_by_slug_1 = require("./get-by-slug");
|
|
6
7
|
var get_one_1 = require("./get-one");
|
|
7
8
|
var query_1 = require("./query");
|
|
8
9
|
var remove_1 = require("./remove");
|
|
9
10
|
var update_1 = require("./update");
|
|
10
|
-
var get_by_slug_1 = require("./get-by-slug");
|
|
11
11
|
exports.profilesApiDeclaration = {
|
|
12
12
|
create: create_1.create,
|
|
13
13
|
remove: remove_1.remove,
|
|
@@ -15,5 +15,5 @@ exports.profilesApiDeclaration = {
|
|
|
15
15
|
query: query_1.query,
|
|
16
16
|
getOne: get_one_1.getOne,
|
|
17
17
|
current: current_1.current,
|
|
18
|
-
getBySlug: get_by_slug_1.getBySlug
|
|
18
|
+
getBySlug: get_by_slug_1.getBySlug,
|
|
19
19
|
};
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import { create } from './create';
|
|
2
|
+
import { getByCoordinates } from './get-by-coordinates';
|
|
3
|
+
import { getByLocation } from './get-by-location';
|
|
4
|
+
import { getBySlug } from './get-by-slug';
|
|
2
5
|
import { getOne } from './get-one';
|
|
3
6
|
import { query } from './query';
|
|
4
7
|
import { recover } from './recover';
|
|
5
8
|
import { remove } from './remove';
|
|
6
9
|
import { update } from './update';
|
|
7
|
-
import { getByLocation } from './get-by-location';
|
|
8
|
-
import { getByCoordinates } from './get-by-coordinates';
|
|
9
|
-
import { getBySlug } from './get-by-slug';
|
|
10
10
|
declare type ApiDeclaration = {
|
|
11
11
|
create: typeof create;
|
|
12
12
|
remove: typeof remove;
|
|
@@ -2,14 +2,14 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.questroomsApiDeclaration = void 0;
|
|
4
4
|
var create_1 = require("./create");
|
|
5
|
+
var get_by_coordinates_1 = require("./get-by-coordinates");
|
|
6
|
+
var get_by_location_1 = require("./get-by-location");
|
|
7
|
+
var get_by_slug_1 = require("./get-by-slug");
|
|
5
8
|
var get_one_1 = require("./get-one");
|
|
6
9
|
var query_1 = require("./query");
|
|
7
10
|
var recover_1 = require("./recover");
|
|
8
11
|
var remove_1 = require("./remove");
|
|
9
12
|
var update_1 = require("./update");
|
|
10
|
-
var get_by_location_1 = require("./get-by-location");
|
|
11
|
-
var get_by_coordinates_1 = require("./get-by-coordinates");
|
|
12
|
-
var get_by_slug_1 = require("./get-by-slug");
|
|
13
13
|
exports.questroomsApiDeclaration = {
|
|
14
14
|
create: create_1.create,
|
|
15
15
|
remove: remove_1.remove,
|
|
@@ -19,5 +19,5 @@ exports.questroomsApiDeclaration = {
|
|
|
19
19
|
recover: recover_1.recover,
|
|
20
20
|
getByLocation: get_by_location_1.getByLocation,
|
|
21
21
|
getByCoordinates: get_by_coordinates_1.getByCoordinates,
|
|
22
|
-
getBySlug: get_by_slug_1.getBySlug
|
|
22
|
+
getBySlug: get_by_slug_1.getBySlug,
|
|
23
23
|
};
|
|
@@ -4,9 +4,9 @@ exports.createCertificate = void 0;
|
|
|
4
4
|
var createCertificate = function (_a) {
|
|
5
5
|
var data = _a.data;
|
|
6
6
|
return ({
|
|
7
|
-
url:
|
|
7
|
+
url: '/widget/openapi/certificate',
|
|
8
8
|
method: 'POST',
|
|
9
|
-
data: data
|
|
9
|
+
data: data,
|
|
10
10
|
});
|
|
11
11
|
};
|
|
12
12
|
exports.createCertificate = createCertificate;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { WidgetOpenapiOrderResponseObject } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-order.ro';
|
|
2
1
|
import { WidgetOpenapiCreateOrderDto } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-create-order.dto';
|
|
2
|
+
import { WidgetOpenapiOrderResponseObject } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-order.ro';
|
|
3
3
|
import { ApiMethodDeclaration } from '..';
|
|
4
4
|
declare type ParamsData = {
|
|
5
5
|
data: WidgetOpenapiCreateOrderDto;
|
|
@@ -4,9 +4,9 @@ exports.createOrder = void 0;
|
|
|
4
4
|
var createOrder = function (_a) {
|
|
5
5
|
var data = _a.data;
|
|
6
6
|
return ({
|
|
7
|
-
url:
|
|
7
|
+
url: '/widget/openapi/order',
|
|
8
8
|
method: 'POST',
|
|
9
|
-
data: data
|
|
9
|
+
data: data,
|
|
10
10
|
});
|
|
11
11
|
};
|
|
12
12
|
exports.createOrder = createOrder;
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import { WidgetOpenapiCreateReviewDto } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-create-review.dto';
|
|
2
|
+
import { WigetOpenapiReviewRO } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-review.ro';
|
|
3
|
+
import { ApiMethodDeclaration } from '..';
|
|
4
|
+
declare type ParamsData = {
|
|
5
|
+
data: WidgetOpenapiCreateReviewDto;
|
|
6
|
+
};
|
|
7
|
+
declare type ResponseData = WigetOpenapiReviewRO;
|
|
8
|
+
export declare const createReview: ApiMethodDeclaration<ParamsData, ResponseData>;
|
|
9
|
+
export {};
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.createReview = void 0;
|
|
4
|
+
var createReview = function (_a) {
|
|
5
|
+
var data = _a.data;
|
|
6
|
+
return ({
|
|
7
|
+
url: '/widget/openapi/reviews',
|
|
8
|
+
method: 'POST',
|
|
9
|
+
data: data,
|
|
10
|
+
});
|
|
11
|
+
};
|
|
12
|
+
exports.createReview = createReview;
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.findCertificate = void 0;
|
|
4
4
|
var findCertificate = function (code) { return ({
|
|
5
|
-
url: "/widget/openapi/certificate/"
|
|
6
|
-
method: 'GET'
|
|
5
|
+
url: "/widget/openapi/certificate/".concat(code),
|
|
6
|
+
method: 'GET',
|
|
7
7
|
}); };
|
|
8
8
|
exports.findCertificate = findCertificate;
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { WidgetOpenapiFindReviewsDto } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-find-reviews.dto';
|
|
2
|
+
import { WigetOpenapiReviewRO } from '@escapenavigator/types/dist/widget-openapi/widget-openapi-review.ro';
|
|
3
|
+
import { ApiMethodDeclaration } from '..';
|
|
4
|
+
declare type ParamsData = WidgetOpenapiFindReviewsDto;
|
|
5
|
+
declare type ResponseData = WigetOpenapiReviewRO[];
|
|
6
|
+
export declare const findReviews: ApiMethodDeclaration<ParamsData, ResponseData>;
|
|
7
|
+
export {};
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
|
+
exports.findReviews = void 0;
|
|
4
|
+
var findReviews = function (params) { return ({
|
|
5
|
+
url: '/widget/openapi/reviews',
|
|
6
|
+
method: 'GET',
|
|
7
|
+
params: params,
|
|
8
|
+
}); };
|
|
9
|
+
exports.findReviews = findReviews;
|
|
@@ -1,10 +1,14 @@
|
|
|
1
|
+
import { createCertificate } from './create-certificate';
|
|
2
|
+
import { createOrder } from './create-order';
|
|
3
|
+
import { createReview } from './create-review';
|
|
4
|
+
import { findCertificate } from './find-certificate';
|
|
5
|
+
import { findReviews } from './find-reviews';
|
|
1
6
|
import { getWidgetInfo } from './get-widget-info';
|
|
2
7
|
import { daily } from './widget-daily';
|
|
3
8
|
import { weekly } from './widget-weekly';
|
|
4
|
-
import { createOrder } from './create-order';
|
|
5
|
-
import { createCertificate } from './create-certificate';
|
|
6
|
-
import { findCertificate } from './find-certificate';
|
|
7
9
|
declare type ApiDeclaration = {
|
|
10
|
+
createReview: typeof createReview;
|
|
11
|
+
findReviews: typeof findReviews;
|
|
8
12
|
getWidgetInfo: typeof getWidgetInfo;
|
|
9
13
|
daily: typeof daily;
|
|
10
14
|
weekly: typeof weekly;
|
|
@@ -1,17 +1,21 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.widgetsOpenApiDeclaration = void 0;
|
|
4
|
+
var create_certificate_1 = require("./create-certificate");
|
|
5
|
+
var create_order_1 = require("./create-order");
|
|
6
|
+
var create_review_1 = require("./create-review");
|
|
7
|
+
var find_certificate_1 = require("./find-certificate");
|
|
8
|
+
var find_reviews_1 = require("./find-reviews");
|
|
4
9
|
var get_widget_info_1 = require("./get-widget-info");
|
|
5
10
|
var widget_daily_1 = require("./widget-daily");
|
|
6
11
|
var widget_weekly_1 = require("./widget-weekly");
|
|
7
|
-
var create_order_1 = require("./create-order");
|
|
8
|
-
var create_certificate_1 = require("./create-certificate");
|
|
9
|
-
var find_certificate_1 = require("./find-certificate");
|
|
10
12
|
exports.widgetsOpenApiDeclaration = {
|
|
13
|
+
createReview: create_review_1.createReview,
|
|
14
|
+
findReviews: find_reviews_1.findReviews,
|
|
11
15
|
getWidgetInfo: get_widget_info_1.getWidgetInfo,
|
|
12
16
|
daily: widget_daily_1.daily,
|
|
13
17
|
weekly: widget_weekly_1.weekly,
|
|
14
18
|
createOrder: create_order_1.createOrder,
|
|
15
19
|
createCertificate: create_certificate_1.createCertificate,
|
|
16
|
-
findCertificate: find_certificate_1.findCertificate
|
|
20
|
+
findCertificate: find_certificate_1.findCertificate,
|
|
17
21
|
};
|
|
@@ -8,8 +8,10 @@ var getContentByItemField = function (item) {
|
|
|
8
8
|
return item.name;
|
|
9
9
|
return item.title;
|
|
10
10
|
};
|
|
11
|
-
var convertToOptions = function (data) {
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
11
|
+
var convertToOptions = function (data) {
|
|
12
|
+
return data.map(function (item) { return ({
|
|
13
|
+
key: item.id,
|
|
14
|
+
content: getContentByItemField(item),
|
|
15
|
+
}); });
|
|
16
|
+
};
|
|
15
17
|
exports.convertToOptions = convertToOptions;
|
|
@@ -1,8 +1,10 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.enumToOptions = void 0;
|
|
4
|
-
var enumToOptions = function (options, t, modelName) {
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
4
|
+
var enumToOptions = function (options, t, modelName) {
|
|
5
|
+
return Object.values(options).map(function (option) { return ({
|
|
6
|
+
key: option,
|
|
7
|
+
content: t("options.".concat(modelName, ".").concat(option)),
|
|
8
|
+
}); });
|
|
9
|
+
};
|
|
8
10
|
exports.enumToOptions = enumToOptions;
|
|
@@ -1,5 +1,7 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.getHandledErrorMessage = void 0;
|
|
4
|
-
var getHandledErrorMessage = function (error) {
|
|
4
|
+
var getHandledErrorMessage = function (error) {
|
|
5
|
+
return (error.response ? error.response.data.message : error.message);
|
|
6
|
+
};
|
|
5
7
|
exports.getHandledErrorMessage = getHandledErrorMessage;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@escapenavigator/services",
|
|
3
|
-
"version": "1.4.
|
|
3
|
+
"version": "1.4.21",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -12,9 +12,9 @@
|
|
|
12
12
|
"scripts": {
|
|
13
13
|
"build": "rm -rf dist && tsc --project tsconfig.json"
|
|
14
14
|
},
|
|
15
|
-
"gitHead": "
|
|
15
|
+
"gitHead": "ada7c3b5a5527ed8b81604ff4ea89ff14b08eb3b",
|
|
16
16
|
"dependencies": {
|
|
17
|
-
"@escapenavigator/types": "^1.4.
|
|
17
|
+
"@escapenavigator/types": "^1.4.21",
|
|
18
18
|
"axios": "^0.21.4",
|
|
19
19
|
"class-transformer": "^0.5.1",
|
|
20
20
|
"class-validator": "^0.13.1",
|