@kengic/uni 0.6.3-beta.24 → 0.6.3-beta.25

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.
@@ -214,12 +214,34 @@ const _httpClient: IHttpClient = {
214
214
  if (options?.dynamicQueryOperatorModel) {
215
215
  let params: any = {};
216
216
 
217
- if (config.method === 'GET') {
218
- params = config.params;
219
- } else if (config.method === 'POST' && !config.data && config.params) {
220
- params = config.params;
221
- } else if (config.method === 'POST' && config.data) {
222
- params = config.data;
217
+ switch (config.method) {
218
+ case 'GET': {
219
+ if (config.params) {
220
+ params = config.params;
221
+ break;
222
+ }
223
+
224
+ if (config.data && !config.params) {
225
+ params = config.data;
226
+ break;
227
+ }
228
+
229
+ break;
230
+ }
231
+
232
+ case 'POST': {
233
+ if (config.data) {
234
+ params = config.data;
235
+ break;
236
+ }
237
+
238
+ if (!config.data && config.params) {
239
+ params = config.params;
240
+ break;
241
+ }
242
+
243
+ break;
244
+ }
223
245
  }
224
246
 
225
247
  const { sql, whereSql, orderBySql, offsetSql, operatorJSON } = Kg.getQueryHeaders({
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@kengic/uni",
3
- "version": "0.6.3-beta.24",
3
+ "version": "0.6.3-beta.25",
4
4
  "scripts": {
5
5
  "build": "npm run use-node && rimraf dist && vue-tsc && vite build",
6
6
  "------ -------------------------------------------": "",