I’m wondering if your relation is setup backwards in that one applicant has many jobs? Is your project code somewhere public like on Github so I can take a look?
Ah ok. thanks for looking into this.
How do I upgrade from 3.0.0-beta.18.4 to 3.1.4?
I don’t want to lose all the content types and the modifications done relating to the different roles and permission.
[2020-09-16T12:08:41.810Z] debug Server wasn’t able to start properly.
[2020-09-16T12:08:41.812Z] error TypeError: Cannot convert undefined or null to object
at Function.values ()
at Object.load (/media/robinedwards/data/Documents/Development/workzone-app/server/node_modules/strapi-database/lib/connector-registry.js:17:39)
at DatabaseManager.initialize (/media/robinedwards/data/Documents/Development/workzone-app/server/node_modules/strapi-database/lib/database-manager.js:32:21)
at Strapi.load (/media/robinedwards/data/Documents/Development/workzone-app/server/node_modules/strapi/lib/Strapi.js:299:19)
at async Strapi.start (/media/robinedwards/data/Documents/Development/workzone-app/server/node_modules/strapi/lib/Strapi.js:158:9)
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! workzone@1.0.1 start: strapi start
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the workzone@1.0.1 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/robinedwards/.npm/_logs/2020-09-16T12_08_41_824Z-debug.log
I just tried updating it from .18 beta to .19 beta
After npm install, I ran npm start and got the following error:
obinedwards@pop-os:/media/robinedwards/data/Documents/Development/workzone-app/server$ npm start
[2020-09-25T11:43:27.896Z] debug Server wasn’t able to start properly.
[2020-09-25T11:43:27.897Z] error Error creating endpoint get /getInfos: policy.split is not a function or its return value is not iterable
npm ERR! code ELIFECYCLE
npm ERR! errno 1
npm ERR! workzone@0.1.0 start: strapi start
npm ERR! Exit status 1
npm ERR!
npm ERR! Failed at the workzone@0.1.0 start script.
npm ERR! This is probably not a problem with npm. There is likely additional logging output above.
npm ERR! A complete log of this run can be found in:
npm ERR! /home/robinedwards/.npm/_logs/2020-09-25T11_43_27_909Z-debug.log
Do you know which file is the policy.split function is and what needs to be updated?
I have four custom models and I’ve looked at all their routes but dont see getInfos. I’ve pushed the latest changes to github, you are already added as a collaborator on the repo.
Those ^ icons are what is cause the failure, as it’s likely trying to install the latest v3.1.6 but the rest of your project is still on beta.19 (FYI the beta is no longer supported)
I’ve removed and I’ve migrated it to v 3.0
Everything was working fine until beta 20. However, once I migrated it from beta 20 to stable 3, the dashboard page does not load anything. The server console is not showing any errors but the browser console has got some errors, which I paste below.
I’ve update the github repo with the latest changes. What would be causing this - I’ve tried it on different browsers but its the same. I can get to the admin login screen, and login but after that it goes to localhost:1337/dashboard and it all blank. Any help would be appreciated.
TypeError: "d.default[e.label] is undefined"
f http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
f http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Za http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
vc http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
sl http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
cl http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
$c http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Yo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
unstable_runWithPriority http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Bo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Yo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Go http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
el http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
notify http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
notifyNestedSubs http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
handleChangeWrapper http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
v http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
e http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
_invoke http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
b http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
n http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
c http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
main.59bc0076.chunk.js:1:3719398
ec http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
callback http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
fa http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
ac http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
pl http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
unstable_runWithPriority http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Bo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
fl http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
$c http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Yo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
unstable_runWithPriority http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Bo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Yo http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
Go http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
el http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
notify http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
notifyNestedSubs http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
handleChangeWrapper http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
v http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
e http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
s http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
_invoke http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
b http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
n http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
c http://localhost:1337/dashboard/main.59bc0076.chunk.js:1
You need to refactor all your config files in the ./config folder. You are still using the older beta configuration structure (.json files and the environments folder)
See the following documentation, and I recommend you read through all of the configuration section so you can get an idea of how the new structure is laid out: Strapi’s documentation | Strapi Documentation
Thanks for this. I finally managed to get to the latest stable version 3 of strapi.
However, I still have the problem of appending data to a model which has an array. This time I am trying to add onto the Employers model from Jobs
Every job has one employer and
every employer has many jobs.
I’ve attached the screenshot.
From the fontend, when a job is created, I create the following array to update employer in the mongodb. var jobValue; jobValue ={ jobs: [ newjob._id ] }
Currently no we don’t support appending like that (as Strapi doesn’t understand if you are adding a new one, or simply overwriting/deleting the others)
You will need to include existing IDs of the array + any new ones.