An extension to GoBlender that allows for delivery of video based online courses.
- Video lectures
- Create as many courses as needed
- Static page lectures
- Drag & drop page creation
- Track student progress
- All for submission of assignments
- Allow for grading of assignments
- Integration with MS Teams
First, install GoBlender.
All client specific code lives in ./client/clienthandlers
, and is its own
git repository. When working in JetBrains Goland, you must create
(or clone) a git repository in this location, and then add the directory
in Preferences -> Version Control.
Change update.sh
in GoBlender root folder so as to enable git pull of client:
# uncomment if using custom client code
#cd ./client/clienthandlers
#git pull
#cd ../..
# run migrations for pg
# soda migrate -c ../../migrations-pg/database.yml
After changing, it should look like this (assuming you want to run postgres migrations):
# uncomment if using custom client code
cd ./client/clienthandlers
git pull
cd ../..
# run migrations for pg
soda migrate -c ../../migrations-pg/database.yml
#run client migrations for mariadb
# soda migrate -c ../../database.yml
Inside of clientviews
there are two folders: public
and private
. If you wish to use the base templates
from GoBlender to create templates, do it like this:
For public pages:
{{template "base" .}}
{{define "title"}}Some title{{end}}
{{define "body"}}
<p>Put whatever you want here</p>
{{end}}
For admin pages:
{{template "admin-base" .}}
{{define "title"}}Some Title - vMaintain Admin{{end}}
{{define "admin-title"}}Some title{{end}}
{{define "content-title"}}Some title{{end}}
{{define "content"}}
<p>Some content</p>
{{end}}
Note
You can override anything in the base templates, or specific pages/partials, by putting a file in
client/clientviews/public
, client/clientviews/public/partials
, client/clientviews/admin
, or
client/clientviews/admin/partials
.
Migrations live in client/migrations
. To run them, add the -c flag to soda, e.g.:
To generate Postgres migrations:
cd client/clienthandlers
soda -c ../../migrations-pg/database.yml generate fizz SomeMigrationName
To run Postgres migrations:
cd client/clienthandlers
soda -c ../../migrations-pg/database.yml migrate
To generate MariaDB/MySQL migrations:
cd client/clienthandlers
soda -c ../../database.yml generate fizz SomeMigration
To run MariaDB/MySQL migrations:
cd client/clienthandlers
soda -c ../../database.yml migrate
Add custom middleware to ./client/clienthandlers/client-middleware.go
, e.g.:
// SomeMiddleware is sample middleware
func SomeMiddleware(next http.Handler) http.Handler {
return http.HandlerFunc(func(w http.ResponseWriter, r *http.Request) {
ok := true
// perform some logic to set ok
if ok {
next.ServeHTTP(w, r)
} else {
helpers.ClientError(w, http.StatusUnauthorized)
}
})
}