ingredient editor paginatio

This commit is contained in:
vabene1111
2022-04-23 02:28:26 +02:00
parent 78c0c5c213
commit b4ebd98ee8
3 changed files with 99 additions and 38 deletions

View File

@@ -593,6 +593,7 @@ class IngredientViewSet(viewsets.ModelViewSet):
queryset = Ingredient.objects queryset = Ingredient.objects
serializer_class = IngredientSerializer serializer_class = IngredientSerializer
permission_classes = [CustomIsUser] permission_classes = [CustomIsUser]
pagination_class = DefaultPagination
def get_serializer_class(self): def get_serializer_class(self):
if self.request and self.request.query_params.get('simple', False): if self.request and self.request.query_params.get('simple', False):

View File

@@ -49,6 +49,9 @@
</div> </div>
</div> </div>
<b-pagination pills v-model="current_page" :total-rows="total_object_count" :per-page="page_size"
@change="pageChange"></b-pagination>
<div class="row mt-2"> <div class="row mt-2">
<div class="col col-md-12"> <div class="col col-md-12">
<table class="table table-bordered"> <table class="table table-bordered">
@@ -123,6 +126,9 @@
</template> </template>
</table> </table>
<b-pagination pills v-model="current_page" :total-rows="total_object_count" :per-page="page_size"
@change="pageChange"></b-pagination>
</div> </div>
</div> </div>
@@ -158,6 +164,9 @@ export default {
generic_model: null, generic_model: null,
show_food_delete: false, show_food_delete: false,
show_unit_delete: false, show_unit_delete: false,
current_page: 1,
total_object_count: 0,
page_size: 50,
} }
}, },
computed: {}, computed: {},
@@ -186,15 +195,16 @@ export default {
} else { } else {
this.loading = true this.loading = true
let apiClient = new ApiApiFactory() let apiClient = new ApiApiFactory()
let params = {'query': {'simple': 1}} let params = {'query': {'simple': 1,}}
if (this.food !== null) { if (this.food !== null) {
params.query.food = this.food.id params.query.food = this.food.id
} }
if (this.unit !== null) { if (this.unit !== null) {
params.query.unit = this.unit.id params.query.unit = this.unit.id
} }
apiClient.listIngredients(params).then(result => { apiClient.listIngredients(this.current_page, this.page_size,params).then(result => {
this.ingredients = result.data this.ingredients = result.data.results
this.total_object_count = result.data.count
this.loading = false this.loading = false
}).catch((err) => { }).catch((err) => {
StandardToasts.makeStandardToast(this, StandardToasts.FAIL_FETCH, err) StandardToasts.makeStandardToast(this, StandardToasts.FAIL_FETCH, err)
@@ -202,6 +212,10 @@ export default {
}) })
} }
}, },
pageChange: function (page) {
this.current_page = page
this.refreshList()
},
updateIngredient: function (i) { updateIngredient: function (i) {
let update_list = [] let update_list = []
if (i === undefined) { if (i === undefined) {
@@ -235,7 +249,6 @@ export default {
} }
}, },
finishGenericAction: function (e) { finishGenericAction: function (e) {
console.log('PARAMETER ', e)
if (e !== 'cancel') { if (e !== 'cancel') {
if (this.generic_action === this.Actions.DELETE) { if (this.generic_action === this.Actions.DELETE) {
this.ingredients = [] this.ingredients = []

View File

@@ -987,9 +987,40 @@ export interface InlineResponse20010 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<ViewLog>} * @type {Array<Unit>}
* @memberof InlineResponse20010 * @memberof InlineResponse20010
*/ */
results?: Array<Unit>;
}
/**
*
* @export
* @interface InlineResponse20011
*/
export interface InlineResponse20011 {
/**
*
* @type {number}
* @memberof InlineResponse20011
*/
count?: number;
/**
*
* @type {string}
* @memberof InlineResponse20011
*/
next?: string | null;
/**
*
* @type {string}
* @memberof InlineResponse20011
*/
previous?: string | null;
/**
*
* @type {Array<ViewLog>}
* @memberof InlineResponse20011
*/
results?: Array<ViewLog>; results?: Array<ViewLog>;
} }
/** /**
@@ -1080,10 +1111,10 @@ export interface InlineResponse2004 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<Keyword>} * @type {Array<Ingredient>}
* @memberof InlineResponse2004 * @memberof InlineResponse2004
*/ */
results?: Array<Keyword>; results?: Array<Ingredient>;
} }
/** /**
* *
@@ -1111,10 +1142,10 @@ export interface InlineResponse2005 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<RecipeOverview>} * @type {Array<Keyword>}
* @memberof InlineResponse2005 * @memberof InlineResponse2005
*/ */
results?: Array<RecipeOverview>; results?: Array<Keyword>;
} }
/** /**
* *
@@ -1142,10 +1173,10 @@ export interface InlineResponse2006 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<Step>} * @type {Array<RecipeOverview>}
* @memberof InlineResponse2006 * @memberof InlineResponse2006
*/ */
results?: Array<Step>; results?: Array<RecipeOverview>;
} }
/** /**
* *
@@ -1173,10 +1204,10 @@ export interface InlineResponse2007 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<SupermarketCategoryRelation>} * @type {Array<Step>}
* @memberof InlineResponse2007 * @memberof InlineResponse2007
*/ */
results?: Array<SupermarketCategoryRelation>; results?: Array<Step>;
} }
/** /**
* *
@@ -1204,10 +1235,10 @@ export interface InlineResponse2008 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<SyncLog>} * @type {Array<SupermarketCategoryRelation>}
* @memberof InlineResponse2008 * @memberof InlineResponse2008
*/ */
results?: Array<SyncLog>; results?: Array<SupermarketCategoryRelation>;
} }
/** /**
* *
@@ -1235,10 +1266,10 @@ export interface InlineResponse2009 {
previous?: string | null; previous?: string | null;
/** /**
* *
* @type {Array<Unit>} * @type {Array<SyncLog>}
* @memberof InlineResponse2009 * @memberof InlineResponse2009
*/ */
results?: Array<Unit>; results?: Array<SyncLog>;
} }
/** /**
* *
@@ -5614,10 +5645,12 @@ export const ApiApiAxiosParamCreator = function (configuration?: Configuration)
}, },
/** /**
* *
* @param {number} [page] A page number within the paginated result set.
* @param {number} [pageSize] Number of results to return per page.
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listIngredients: async (options: any = {}): Promise<RequestArgs> => { listIngredients: async (page?: number, pageSize?: number, options: any = {}): Promise<RequestArgs> => {
const localVarPath = `/api/ingredient/`; const localVarPath = `/api/ingredient/`;
// use dummy base URL string because the URL constructor only accepts absolute URLs. // use dummy base URL string because the URL constructor only accepts absolute URLs.
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL); const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
@@ -5630,6 +5663,14 @@ export const ApiApiAxiosParamCreator = function (configuration?: Configuration)
const localVarHeaderParameter = {} as any; const localVarHeaderParameter = {} as any;
const localVarQueryParameter = {} as any; const localVarQueryParameter = {} as any;
if (page !== undefined) {
localVarQueryParameter['page'] = page;
}
if (pageSize !== undefined) {
localVarQueryParameter['page_size'] = pageSize;
}
setSearchParams(localVarUrlObj, localVarQueryParameter, options.query); setSearchParams(localVarUrlObj, localVarQueryParameter, options.query);
@@ -10494,11 +10535,13 @@ export const ApiApiFp = function(configuration?: Configuration) {
}, },
/** /**
* *
* @param {number} [page] A page number within the paginated result set.
* @param {number} [pageSize] Number of results to return per page.
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listIngredients(options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<Array<Ingredient>>> { async listIngredients(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2004>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listIngredients(options); const localVarAxiosArgs = await localVarAxiosParamCreator.listIngredients(page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
/** /**
@@ -10511,7 +10554,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listKeywords(query?: string, root?: number, tree?: number, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2004>> { async listKeywords(query?: string, root?: number, tree?: number, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2005>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listKeywords(query, root, tree, page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listKeywords(query, root, tree, page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10585,7 +10628,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listRecipes(query?: string, keywords?: number, keywordsOr?: number, keywordsAnd?: number, keywordsOrNot?: number, keywordsAndNot?: number, foods?: number, foodsOr?: number, foodsAnd?: number, foodsOrNot?: number, foodsAndNot?: number, units?: number, rating?: number, books?: string, booksOr?: number, booksAnd?: number, booksOrNot?: number, booksAndNot?: number, internal?: string, random?: string, _new?: string, timescooked?: number, cookedon?: string, createdon?: string, updatedon?: string, viewedon?: string, makenow?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2005>> { async listRecipes(query?: string, keywords?: number, keywordsOr?: number, keywordsAnd?: number, keywordsOrNot?: number, keywordsAndNot?: number, foods?: number, foodsOr?: number, foodsAnd?: number, foodsOrNot?: number, foodsAndNot?: number, units?: number, rating?: number, books?: string, booksOr?: number, booksAnd?: number, booksOrNot?: number, booksAndNot?: number, internal?: string, random?: string, _new?: string, timescooked?: number, cookedon?: string, createdon?: string, updatedon?: string, viewedon?: string, makenow?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2006>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listRecipes(query, keywords, keywordsOr, keywordsAnd, keywordsOrNot, keywordsAndNot, foods, foodsOr, foodsAnd, foodsOrNot, foodsAndNot, units, rating, books, booksOr, booksAnd, booksOrNot, booksAndNot, internal, random, _new, timescooked, cookedon, createdon, updatedon, viewedon, makenow, page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listRecipes(query, keywords, keywordsOr, keywordsAnd, keywordsOrNot, keywordsAndNot, foods, foodsOr, foodsAnd, foodsOrNot, foodsAndNot, units, rating, books, booksOr, booksAnd, booksOrNot, booksAndNot, internal, random, _new, timescooked, cookedon, createdon, updatedon, viewedon, makenow, page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10628,7 +10671,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listSteps(recipe?: number, query?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2006>> { async listSteps(recipe?: number, query?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2007>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listSteps(recipe, query, page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listSteps(recipe, query, page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10648,7 +10691,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listSupermarketCategoryRelations(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2007>> { async listSupermarketCategoryRelations(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2008>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listSupermarketCategoryRelations(page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listSupermarketCategoryRelations(page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10677,7 +10720,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listSyncLogs(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2008>> { async listSyncLogs(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2009>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listSyncLogs(page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listSyncLogs(page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10698,7 +10741,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listUnits(query?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse2009>> { async listUnits(query?: string, page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse20010>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listUnits(query, page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listUnits(query, page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -10736,7 +10779,7 @@ export const ApiApiFp = function(configuration?: Configuration) {
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
async listViewLogs(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse20010>> { async listViewLogs(page?: number, pageSize?: number, options?: any): Promise<(axios?: AxiosInstance, basePath?: string) => AxiosPromise<InlineResponse20011>> {
const localVarAxiosArgs = await localVarAxiosParamCreator.listViewLogs(page, pageSize, options); const localVarAxiosArgs = await localVarAxiosParamCreator.listViewLogs(page, pageSize, options);
return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration); return createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration);
}, },
@@ -12319,11 +12362,13 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
}, },
/** /**
* *
* @param {number} [page] A page number within the paginated result set.
* @param {number} [pageSize] Number of results to return per page.
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listIngredients(options?: any): AxiosPromise<Array<Ingredient>> { listIngredients(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2004> {
return localVarFp.listIngredients(options).then((request) => request(axios, basePath)); return localVarFp.listIngredients(page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
* *
@@ -12335,7 +12380,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listKeywords(query?: string, root?: number, tree?: number, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2004> { listKeywords(query?: string, root?: number, tree?: number, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2005> {
return localVarFp.listKeywords(query, root, tree, page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listKeywords(query, root, tree, page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12404,7 +12449,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listRecipes(query?: string, keywords?: number, keywordsOr?: number, keywordsAnd?: number, keywordsOrNot?: number, keywordsAndNot?: number, foods?: number, foodsOr?: number, foodsAnd?: number, foodsOrNot?: number, foodsAndNot?: number, units?: number, rating?: number, books?: string, booksOr?: number, booksAnd?: number, booksOrNot?: number, booksAndNot?: number, internal?: string, random?: string, _new?: string, timescooked?: number, cookedon?: string, createdon?: string, updatedon?: string, viewedon?: string, makenow?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2005> { listRecipes(query?: string, keywords?: number, keywordsOr?: number, keywordsAnd?: number, keywordsOrNot?: number, keywordsAndNot?: number, foods?: number, foodsOr?: number, foodsAnd?: number, foodsOrNot?: number, foodsAndNot?: number, units?: number, rating?: number, books?: string, booksOr?: number, booksAnd?: number, booksOrNot?: number, booksAndNot?: number, internal?: string, random?: string, _new?: string, timescooked?: number, cookedon?: string, createdon?: string, updatedon?: string, viewedon?: string, makenow?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2006> {
return localVarFp.listRecipes(query, keywords, keywordsOr, keywordsAnd, keywordsOrNot, keywordsAndNot, foods, foodsOr, foodsAnd, foodsOrNot, foodsAndNot, units, rating, books, booksOr, booksAnd, booksOrNot, booksAndNot, internal, random, _new, timescooked, cookedon, createdon, updatedon, viewedon, makenow, page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listRecipes(query, keywords, keywordsOr, keywordsAnd, keywordsOrNot, keywordsAndNot, foods, foodsOr, foodsAnd, foodsOrNot, foodsAndNot, units, rating, books, booksOr, booksAnd, booksOrNot, booksAndNot, internal, random, _new, timescooked, cookedon, createdon, updatedon, viewedon, makenow, page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12443,7 +12488,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listSteps(recipe?: number, query?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2006> { listSteps(recipe?: number, query?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2007> {
return localVarFp.listSteps(recipe, query, page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listSteps(recipe, query, page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12461,7 +12506,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listSupermarketCategoryRelations(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2007> { listSupermarketCategoryRelations(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2008> {
return localVarFp.listSupermarketCategoryRelations(page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listSupermarketCategoryRelations(page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12487,7 +12532,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listSyncLogs(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2008> { listSyncLogs(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2009> {
return localVarFp.listSyncLogs(page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listSyncLogs(page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12506,7 +12551,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listUnits(query?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse2009> { listUnits(query?: string, page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse20010> {
return localVarFp.listUnits(query, page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listUnits(query, page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -12540,7 +12585,7 @@ export const ApiApiFactory = function (configuration?: Configuration, basePath?:
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
*/ */
listViewLogs(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse20010> { listViewLogs(page?: number, pageSize?: number, options?: any): AxiosPromise<InlineResponse20011> {
return localVarFp.listViewLogs(page, pageSize, options).then((request) => request(axios, basePath)); return localVarFp.listViewLogs(page, pageSize, options).then((request) => request(axios, basePath));
}, },
/** /**
@@ -14156,12 +14201,14 @@ export class ApiApi extends BaseAPI {
/** /**
* *
* @param {number} [page] A page number within the paginated result set.
* @param {number} [pageSize] Number of results to return per page.
* @param {*} [options] Override http request option. * @param {*} [options] Override http request option.
* @throws {RequiredError} * @throws {RequiredError}
* @memberof ApiApi * @memberof ApiApi
*/ */
public listIngredients(options?: any) { public listIngredients(page?: number, pageSize?: number, options?: any) {
return ApiApiFp(this.configuration).listIngredients(options).then((request) => request(this.axios, this.basePath)); return ApiApiFp(this.configuration).listIngredients(page, pageSize, options).then((request) => request(this.axios, this.basePath));
} }
/** /**