Closed Alfa1561 closed 11 months ago
On this, I am not able to add any new categories either. When I click Add Category it does nothing. If I look at the console I see these other errors.
instrument.js:122 {
"DEBUG": {
"message": "Request failed with status code 400",
"status": 400,
"response": {
"data": {
"name": "BAD_REQUEST",
"message": "badRequest",
"status": 400,
"errors": [
{
"0": "Invalid"
}
]
},
"status": 400,
"statusText": "Bad Request",
"headers": {
"content-length": "85",
"content-type": "application/json; charset=utf-8"
},
"config": {
"transitional": {
"silentJSONParsing": true,
"forcedJSONParsing": true,
"clarifyTimeoutError": false
},
"adapter": [
"xhr",
"http"
],
"transformRequest": [
null
],
"transformResponse": [
null
],
"timeout": 0,
"xsrfCookieName": "XSRF-TOKEN",
"xsrfHeaderName": "X-XSRF-TOKEN",
"maxContentLength": -1,
"maxBodyLength": -1,
"env": {},
"headers": {
"Accept": "application/json, text/plain, */*",
"Content-Type": "application/json",
"Session": "",
"is-from-dispatch": "false"
},
"url": "https://api.enemyofthestaterp.com/v1/admin/values/driverslicense_category",
"method": "post",
"data": "{\"isDisabled\":false,\"value\":\"Seasonal Hunting License\",\"description\":\"\",\"qualificationType\":\"QUALIFICATION\",\"shouldDo\":\"\",\"color\":\"\",\"textColor\":\"\",\"type\":\"HUNTING\",\"whatPages\":[],\"pairedUnitTemplate\":\"\",\"departmentId\":\"\",\"isConfidential\":false,\"whitelisted\":false,\"defaultOfficerRankId\":null,\"isDefaultDepartment\":false,\"callsign\":\"\",\"customTemplate\":\"\",\"as\":\"\",\"trimLevels\":[],\"licenseType\":null,\"officerRankImageId\":\"\",\"postal\":\"\",\"county\":\"\",\"showPicker\":false,\"image\":\"\",\"extraFields\":null,\"departmentLinks\":[]}",
"withCredentials": true
},
"request": {
"__sentry_xhr_v2__": {
"method": "POST",
"url": "https://api.enemyofthestaterp.com/v1/admin/values/driverslicense_category",
"request_headers": {
"accept": "application/json, text/plain, */*",
"content-type": "application/json",
"session": "",
"is-from-dispatch": "false"
},
"body": "{\"isDisabled\":false,\"value\":\"Seasonal Hunting License\",\"description\":\"\",\"qualificationType\":\"QUALIFICATION\",\"shouldDo\":\"\",\"color\":\"\",\"textColor\":\"\",\"type\":\"HUNTING\",\"whatPages\":[],\"pairedUnitTemplate\":\"\",\"departmentId\":\"\",\"isConfidential\":false,\"whitelisted\":false,\"defaultOfficerRankId\":null,\"isDefaultDepartment\":false,\"callsign\":\"\",\"customTemplate\":\"\",\"as\":\"\",\"trimLevels\":[],\"licenseType\":null,\"officerRankImageId\":\"\",\"postal\":\"\",\"county\":\"\",\"showPicker\":false,\"image\":\"\",\"extraFields\":null,\"departmentLinks\":[]}",
"status_code": 400
}
}
},
"method": "post",
"data": "{\"isDisabled\":false,\"value\":\"Seasonal Hunting License\",\"description\":\"\",\"qualificationType\":\"QUALIFICATION\",\"shouldDo\":\"\",\"color\":\"\",\"textColor\":\"\",\"type\":\"HUNTING\",\"whatPages\":[],\"pairedUnitTemplate\":\"\",\"departmentId\":\"\",\"isConfidential\":false,\"whitelisted\":false,\"defaultOfficerRankId\":null,\"isDefaultDepartment\":false,\"callsign\":\"\",\"customTemplate\":\"\",\"as\":\"\",\"trimLevels\":[],\"licenseType\":null,\"officerRankImageId\":\"\",\"postal\":\"\",\"county\":\"\",\"showPicker\":false,\"image\":\"\",\"extraFields\":null,\"departmentLinks\":[]}",
"url": "https://api.enemyofthestaterp.com/v1/admin/values/driverslicense_category"
}
}
(anonymous) @ instrument.js:122
api
Same for me +1
Fixed now!
What version of Node.js are you using?
18.17.1
What operating system are you using?
Linux
What version of SnailyCAD are you currently using?
1.73.1
Describe the Bug
When trying to add a license category for hunting or fishing on the civ page, it shows the water license category options.
When trying to add new license category types on the admin panel for hunting or fishing licenses, they fail to add correctly. It simply does not add them to the list.
Expected Behavior
On the civ page, hunting & fishing license categories should display options from their own types, not the water license category.
On the admin panel, it should accept new license categories for hunting and fishing licenses.
To Reproduce
No response