Picture of Bob Heckmann
Creating your first course tutorial
by Bob Heckmann - Monday, 5 October 2015, 8:32 PM
 

I'm new to Adapt Learning and just starting to feel my way around. I'm trying the "Creating your first course" tutorial (https://github.com/adaptlearning/adapt_framework/wiki/Creating-your-first-course) but get a grunt build error after editing contentObjects.json - see screen shot below.

I've double- and triple-checked the json code block added to the file and validated the entire file contents with JSONLint. Thanks in advance for suggestions.

Bob

Picture of Chuck Lorenz
Re: Creating your first course tutorial
by Chuck Lorenz - Tuesday, 6 October 2015, 4:00 AM
 

Hi Bob,

Glad you're playing with Adapt. I'm sure we can help get you started. Post back if I (or others) don't suggest the help you need the first time.

"Empty ids" usually means that a piece of the content structure hasn't been fully built out. ContentObjects ("type: page") in contentObjects.json are associated with a child article in articles.json. Articles are associated with child blocks in blocks.json. And blocks are associated with child components in components.json. The association is based on the values you assign to "_id" and "_parentId". "_id" becomes the "_parentId" of the child; you must use the same value to associate the two. 

If my response is still a little is still a little hard to understand, post the JSON for co-25, and we can be more specific by referencing your code. 

I recommend checking two things:
- does co-25 have an article, block, and component as descendants?
- do you have a typo in your _id or _parentId? (They're case-sensitive.)

Chuck 

Picture of Bob Heckmann
Re: Creating your first course tutorial
by Bob Heckmann - Tuesday, 6 October 2015, 5:06 PM
 

Thanks for the quick response Chuck. Your description of the associations got me on track. 

The tutorial is actually misleading in this case, which led to my confusion. After making changes to the contentObjects.json file the tutorial reads:

"Now you will need to re-build your code and refresh the browser, should now see at the bottom of the menu a new item (it won't do anything just yet)."

The code re-build doesn't work at that point because the dependent files haven't been edited. A better instruction would be to explain the dependencies and instruct the user to continue editing the other JSON files.

Thanks again for your assistance.

Bob

 

 

Picture of Chuck Lorenz
Re: Creating your first course tutorial
by Chuck Lorenz - Tuesday, 6 October 2015, 6:51 PM
 

"The tutorial is actually misleading"

You're right, Bob.

I have updated the article as you described.

Thanks,

Chuck

Picture of Bob Heckmann
Re: Creating your first course tutorial
by Bob Heckmann - Tuesday, 6 October 2015, 8:40 PM
 

Thanks Chuck. I really appreciate the quick response.

Bob