0xJohnnyboy / spider-query-builder

Builds a queryparams string for interactions with API Platform based backend
GNU Affero General Public License v3.0
2 stars 0 forks source link

handle multiple SpdrParam instances in query builder #4

Closed 0xJohnnyboy closed 2 years ago

0xJohnnyboy commented 2 years ago

Version

2.x

Issue

There's no handling of multiple declarations of a param on the same property

Suggestion

const p1 = new SpdrSearch('lastname', ['Belmondo']);
const p2 = new SpdrSearch('lastname', ['Delon']);

const qb = new SpdrQueryBuilder([p1,p2]);

Several solutions to this:

0xJohnnyboy commented 2 years ago

The behavior has slightly changed since v2.x but lists of params have been implemented in v3, a feature of this type should be available soon

0xJohnnyboy commented 2 years ago

12 adds automatic replacement for sort params and pagination params.

The rest is still manual at this point.