@finema/core 2.18.1 → 2.18.3
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/module.json
CHANGED
package/dist/module.mjs
CHANGED
|
@@ -148,18 +148,6 @@ watch(
|
|
|
148
148
|
useWatchChange(() => props.options?.pageOptions?.currentPage, (value) => {
|
|
149
149
|
page.value = value;
|
|
150
150
|
});
|
|
151
|
-
useWatchChange(() => props.options?.pageOptions?.request?.params, () => {
|
|
152
|
-
if (props.options?.isPreventRouteChange) return;
|
|
153
|
-
const params = props.options?.pageOptions?.request?.params || {};
|
|
154
|
-
const cleanParams = Object.fromEntries(
|
|
155
|
-
Object.entries(params).filter(
|
|
156
|
-
([key, value]) => value !== null && value !== void 0 && value !== ""
|
|
157
|
-
)
|
|
158
|
-
);
|
|
159
|
-
router.replace({
|
|
160
|
-
query: cleanParams
|
|
161
|
-
});
|
|
162
|
-
});
|
|
163
151
|
const pageBetween = computed(() => {
|
|
164
152
|
const rawDataLength = props.options.rawData?.length;
|
|
165
153
|
const pageOpts = props.options.pageOptions;
|
|
@@ -134,14 +134,14 @@ export const apiFetchHelper = async (state, onUpdateStatus, onUpdateOptions, onU
|
|
|
134
134
|
...opts.getBaseRequestOptions?.() || {},
|
|
135
135
|
...opts.fetch?.getRequestOptions?.(page, query, opts) || {}
|
|
136
136
|
};
|
|
137
|
-
const limit = baseRequestOptions.params?.limit || config.limit_per_page;
|
|
137
|
+
const limit = Number(baseRequestOptions.params?.limit || config.limit_per_page);
|
|
138
138
|
const requestOptions = prepareRequestOptions(
|
|
139
139
|
baseRequestOptions,
|
|
140
140
|
{
|
|
141
141
|
params: {
|
|
142
142
|
limit,
|
|
143
143
|
q: (query || "").trim(),
|
|
144
|
-
page
|
|
144
|
+
page: Number(page)
|
|
145
145
|
}
|
|
146
146
|
},
|
|
147
147
|
opts.params
|