SnailyCAD / snaily-cadv4

💻 An open source Computer Aided Dispatch (CAD) for FiveM, this is a web based integration for communities who love police roleplaying and dispatching. Discord: https://discord.gg/eGnrPqEH7U
https://docs.snailycad.org/docs/getting-started
MIT License
140 stars 84 forks source link

Import Citizens API | Occupation not populating #1714

Closed spencerlocks closed 1 year ago

spencerlocks commented 1 year ago

What version of Node.js are you using?

v16.13.2

What operating system are you using?

Ubuntu 20.04 LTS

What version of SnailyCAD are you currently using?

v1.63.0 82cb9eb

Describe the Bug

[{ "userId": "clixqhacq00009guf9tlofdaj", "name": "Test 3", "surname": "Lockhart", "dateOfBirth": "1991-05-24", "gender": "clijqawor05ni9g7c3lvngzr1", "ethnicity": "clijqaqou05na9g7cg601fprd", "hairColor": "Black", "eyeColor": "Green", "postal": "564", "address": "Whispymound Drive", "weight": "120", "height": "5'6\"", "driversLicenseId": "clijqb61p05nq9g7ca9l99g8d", "occupation": "Testing 123" }]

The above json when posted to the import/citizens address creates a citizen correctly, but occupation is still null.

Expected Behavior

I thought that all the fields that are provided when GET a civilian would be able to be specified when importing one using POST.

To Reproduce

I used Postman to generate POST requests to my /v1/admin/import/citizens with the json you can see in the "Describe the Bug" field.

casperiv0 commented 1 year ago

Supported now!

spencerlocks commented 1 year ago

Can confirm this worked :)