It is really helpful to be able to add sample data to the Courses app to show in the reference environment, especially as terms "age" out and you want to ensure that new terms and courses are added.
The good news is that creating sample data is not that difficult. It does require a little work in Github, but you do not need to write code.
Step 1: Open a Jira
This will allow whatever dev team is maintaining mod-courses to manage the work they need to do. Open a ticket in the MODCR project in Jira and title it something like "Adding new sample data on reference environments."
Step 2: Log into Github and create a fork of the mod-courses repository.
Create a fork of https://github.com/folio-org/mod-courses in your Github account. You will create the new sample data in your fork, and then create a pull request to merge the sample data into production.
Step 3: Create new sample data in your fork of mod-courses
Sample data lives in mod-courses in src/main/resources/sample-data
Here, you want to add your sample data to your forked repository. The easiest way to generate the sample data is to go to a current reference environment and create the sample data there, and then use developer tools (Intro to Developer Tools in Google Chrome) to get the json that you need.
For example, suppose you wanted to add a new term for Fall 2024. What you would do is:
- Go to https://folio-snapshot.dev.folio.org and go to Settings > Courses > Terms.
- Open Developer Tools (see Intro to Developer Tools in Google Chrome for more help with developer tools.)
- Select the New button and create the term for Fall 2024.
- When you save the term, in Developer Tools on the Network panel, you should see the API call that FOLIO sends to create the term
- In the Response tab