Changes for page Competent - iTrivio integration
Last modified by Petr Blšťák on 2024/09/18 11:55
Change comment:
There is no comment for this version
Summary
-
Page properties (1 modified, 0 added, 0 removed)
Details
- Page properties
-
- Content
-
... ... @@ -1,3 +1,8 @@ 1 +(% class="box errormessage" %) 2 +((( 3 +This section is currently under construction... please wait until is finished 4 +))) 5 + 1 1 = Software to be installed = 2 2 3 3 //Unless stated otherwise, newer stable versions of the program should work.// ... ... @@ -4,202 +4,95 @@ 4 4 5 5 ==== [[iTrivio 2.9.017>>doc:Main.Official manuals.iTrivio installation manual.WebHome]] ==== 6 6 7 -==== [[Competent 622>>doc:Main.Official manuals.Competent installation manual.WebHome]] ====12 +==== [[Competent 33>>doc:Main.Official manuals.Competent installation manual.WebHome]] ==== 8 8 14 + 9 9 = Introduction = 10 10 11 -//On this page we use the term "Course" for both :course and testin iTrivio.//17 +//On this page we use the term "Course" for both iTrivio courses and tests.// 12 12 13 - The integration of CompetentandiTrivio provides featuresfromboth softwaresmergedtogetherand accessible through Competent.19 +Integration of Competent with iTrivio provides features of both software merged and accessible through the Competent. 14 14 15 -When specific objects arecreated(and deleted)in Competent, theyareautomatically created(and deleted)in iTrivioas well. CompetentstorestheID referencesto theiTrivioobjects init's database.21 +When specific object is created in Competent, it is automatically created also in iTrivio. Competent then contains ID reference to its iTrivio counterpart. 16 16 17 -This applies to creation of :23 +This applies to creation and deletion of 18 18 19 19 * Users 20 -* Courses (Activities with the specificlaunch type iTrivio)26 +* Courses (in Competent these are Activities with launch type iTrivio) 21 21 * User-Course assignments 22 22 * User-Course attempts 23 23 24 -iTrivio application is accessible only th roughtspecific links in Competent when:30 +iTrivio application is accessible only with specific links in Competent when 25 25 26 -* editing acontent of Course27 -* playing aCourse32 +* editing content of Course 33 +* playing Course 28 28 * displaying specific User-Course reports 29 29 30 -The links to iTrivio contain a one time auto-login security token thatapproves the current user's action in iTrivio.There is no needforthe user to log into iTriviosystem manually.36 +The generated links to the iTrivio contains a one time auto-login security token which approves the current user's action in the iTrivio thus there is no need to the user to log in into the iTrivio. By default is password of an user in the iTrivio different (random) from his/hers Competent password to prevent direct access to the iTrivio. We recommend to disable iTrivio emailing and to keep iTrivio user's password secret to the user. 31 31 32 -By default the password of a user in iTrivio is different (random) from his password in Competent to prevent direct access to iTrivio. We recommend to disable iTrivio emailing and to keep iTrivio user's password secret to the user. 33 - 34 34 (% class="box warningmessage" %) 35 35 ((( 36 36 **Modifying iTrivio directly (out of Competent platform) can cause synchronization issues, especially when manipulating with Users, Courses, User-Course attempts and assignments.** 37 37 ))) 38 38 39 -Th econfigurationbelowdescribes the basic scenario where43 +This configuration describes the basic scenario where 40 40 41 41 * both iTrivio and Competent are fresh installations 42 -* login with thedefault iTrivio and Competent admin accounts were successfully tested43 -* Competent will be themain platform to handle course creation/deletion, user management and user-course management.46 +* login with default iTrivio and Competent admin accounts were successfully tested 47 +* Competent will be main platform to handle course creation/deletion, user management and user-course management. 44 44 45 -Contact Educasoft for specific configuration procedure in other ,more complex scenarios (e.g. Competent is going to use existing iTrivio application already filled with course/user data).49 +Contact Educasoft for specific configuration procedure in other more complex scenarios (e.g. Competent is going to use existing iTrivio application already filled with course/user data ) 46 46 47 -= Systemspreparation=51 += Competent part = 48 48 49 -In order for the two systems to work together, we first have to create the basic structures they will operate with - users, folders etc. 50 50 51 - ===__Competent__===54 +in application.properties, or in your own application-yourNameShortcut.properties file set the following propeties: 52 52 53 -If you have both systems as a fresh installations and you will use them only throught the Competent system, you can skip this step and go to the iTrivio preparation. 56 +* **competentItrivioIntegration.enabled=true** 57 +//(true to allow the connection between apps)// 58 +* **competentItrivioIntegration.itrivioCompanyUrlContext=/test** 59 +//(url name of the company for which you are setting the connection, leave empty if the only company is the root)// 60 +* **competentItrivioIntegration.url=http:~/~/localhost:8080/** 61 +//(url of the iTrivio app)// 62 +* **competentItrivioIntegration.linkUrl=http:~/~/127.0.0.1:8080** 63 +//(probably the same as above, this will be the url where the iTrivio courses will run, leave out the final slash! or the course address will show wrong)// 64 +* **competentItrivioIntegration.itrivioCompanyId=1** 65 +//(Id of the company you are setting it for)// 66 +* **competentItrivioIntegration.userCreatorItrivioUserId=2** 67 +//(ID of the user - existing in the system - in whos name the courses will be created. Someone with Admin roles)// 68 +* **competentItrivioIntegration.newUserSubtypeId=1** 69 +//(ID of subtype of user in Competent? - for when creating new users - probably)// 70 +* **competentItrivioIntegration.newActivitySubtypeId=2** 71 +//(ID of subtype of Activity? - when creating new activities - probably)// 72 +* **competentItrivioIntegration.newActivityTargetFolderId=20** 73 +//(ID of folder in iTrivio in which to create new Activites)// 74 +* **competentItrivioIntegration.auth.userId=2** 75 +//(ID of user in whose name the authorisation of running the course will be done?)// 76 +* **competentItrivioIntegration.auth.key=** 77 +//(secret key for JWT token)// 78 +* **competentItrivioIntegration.auth.environment=demo** 79 +//(authentication environment, used in JWT token I think)// 54 54 55 -1. We need to decide what subtypes we want to use for new Users and new Activites in the use case, when we would need to synchronize users and courses from iTrivio into Competent. This will not typically happen if you will use the systems as described above. 56 -1*. If you want new Users and Activities to be of default subtype, you don't need to create anything. 57 -1*. If you want new Users and Activities to be of some other subtype 58 -1**. Log into Competent as the admin user 59 -1**. switch to the Admin view 60 -1**. go to the page Settings, to the tab Subtypes and create new subtypes for User and Activity (click on the green plus icon, fill in the new subtype name and hit the Create button). 61 -1. Furthermore we need to create a folder, that would hold all the iTrivio courses in case of synchronization from iTrivio, so 62 -1*. Log into Competent as the admin user and switch to the Admin view (if you didn't already) 63 -1*. Go to the Competent page Activities and create a new folder named for example iTrivio Courses (click on the green plus icon, choose Folder, fill in it's name and click Save). 64 -1. If you want some other user than the default Competent admin to be able to edit the iTrivio courses, create this user. Note that this user should have appropriate admin rights. We recommend to use the default admin for now. 65 - 66 -=== __iTrivio__ === 67 - 68 -Here we need to create the users that will manipulate iTrivio courses and a folder to store them. 69 - 70 -1. Log into iTrivio as admin user and go to the **Courses & Tests** 71 -1. **Create a new folder** named for example Competent courses - this is where all your courses will be stored 72 -1. If you want the company default admin user to manage all the courses and users creation in iTrivio, skip to step 7), otherwise 73 -1. Go to **Administration **to the section **Users** 74 -1. **Create new user** that will be responsible for manipulating all objects in iTrivio (courses and users). Fill just his email, name and surename and assign him the role Administrator. 75 -1. Optionally you can create another new user that will be responsible only for creating new users in iTrivio 76 -1. Go to the **Usergroups administration** and create new usergroup (for example Competent users) - this is where all your new users will be assigned. 77 - 78 -=== __Databases info__ === 79 - 80 -Now we need to write down IDs of all the objects we just created (and some more). If you have both systems as fresh installations, you did not create any specific subtypes in Competent and users in iTrivio, you can just use the default values from brackets. 81 - 82 -1. __Competent__ database, in the table __subtype__ write down 83 -1*. **USER_SUBTYPE **(by default 1) = subtype ID of the default_user (column "name") or if you created a specific subtype, find it by its name and write down it's ID 84 -1*. **ACTIVITY_SUBTYPE **(by default 2) = subtype ID of the default_timeless_activity (column "name") that has "activity_type_id" = 1. If you created a specific subtype, find it by its name and write down it's ID 85 -1. __Competent__ database, in the table __activity_set__ write down 86 -1*. **ACTIVITY_FOLDER **(by default 1) = ID of the folder you created for new itrivio courses (find by name in the column "name") 87 -1. __iTrivio__ database, in the table __company__ write down 88 -1*. **COMPANY_ID **(by default 1) = ID of the company that will be synchronized with Competent (find by name in the column "name") 89 -1*. **COMPANY_URL **(by default empty) = value from the column "urlContext" of the company that will be synchornized with Competent (find by name in the column "name") 90 -1. __iTrivio__ database, in the table __course__ write down 91 -1*. **COURSE_FOLDER **(by default 1) = ID of the folder that you created for new courses created from Competent (find by name in the column "name") 92 -1. __iTrivio__ database, in the table __itrivio_user__ write down 93 -1*. If you skipped the steps 4) - 6) in iTrivio preparation and you are using fresh iTrivio instalation, just write down the default values 94 -1*. **ADMIN_CREATOR **(by default 2) = ID of the user that will be creating all the users and courses in iTrivio 95 -1*. **ADMIN_USER_CREATOR **(by default 2) = ID of the user that will be creating all the users in iTrivio 96 -1. __iTrivio__ database, in the table __usergroup__ write down 97 -1*. **USERGROUP **(by default 1) = ID of the usegroup that all your new users will be assigned to 98 - 99 -Beside these ids from database you might need these two optional course ids: 100 - 101 -* **COURSE_TEMPLATE_ID** - a course id that will be used as a template for newly created courses. 102 -* **TEST_TEMPLATE_ID** - a test id for newly created tests 103 - 104 -= Configuration = 105 - 106 -Now you can modify the systems configuration files, use the values written down from databases. 107 - 108 -=== __Competent__ === 109 - 110 -First we need to manually connect the first two users: 111 - 112 -* Go to the Competent database once more, to the table __user_mt__ and find either the default Competent admin (by login "admin" and typically it will be the user with ID=1) or the other user you created in the Competent preparation step (for editing your iTrivio courses). 113 -* Find the column external_id and instead of NULL fill in the **<ADMIN_CREATOR>** value. 114 -* For now, this user will be the **only one** in your company that will be able to edit the iTrivio courses. Other users with appropriate rights can only create/delete/run them. 115 - 116 -Now open the **application.properties** file and set the following propeties: 117 - 118 -{{code language="properties"}} 119 -#-# set to true if enabled 120 -competentItrivioIntegration.enabled=true 121 - 122 -#-# itrivio company url context, leave empty if company has no url context 123 -competentItrivioIntegration.itrivioCompanyUrlContext=<COMPANY_URL> 124 - 125 -#-# url of iTrivio app (for integration API communication - accessible from Competent server location) 126 -competentItrivioIntegration.url=http://localhost:8080/ 127 - 128 -#-# url of iTrivio app (for generating user links - accessible from browser of users) 129 -competentItrivioIntegration.linkUrl=http://localhost:8080 130 - 131 -#-# integrated iTrivio db company ID 132 -competentItrivioIntegration.itrivioCompanyId=<COMPANY_ID> 133 - 134 -#-# iTrivio db course ID, which will be used as a template for new test 135 -# can be null, than the test will be empty 136 -competentItrivioIntegration.itrivioTestTemplateId=<COURSE_TEMPLATE_ID or EMPTY> 137 - 138 -#-# iTrivio db course ID, which will be used as a template for new course 139 -# can be null, than the course will be empty 140 -competentItrivioIntegration.itrivioCourseTemplateId=<TEST_TEMPLATE_ID or EMPTY> 141 - 142 -#-# -------------- COMPETENT INTEGRATION ------------ 143 -#-# --- From Competent to iTrivio synchronization --- 144 - 145 -#-# iTrivio db user ID, which will be used as a creator iTrivio ID when creating new users in iTrivio 146 -competentItrivioIntegration.userCreatorItrivioUserId=<ADMIN_USER_CREATOR> 147 - 148 -#-# iTrivio db user ID, which account will be used to perform actions in iTrivio (such as creating courses and users) 149 -competentItrivioIntegration.auth.userId=<ADMIN_CREATOR> 150 - 151 -#-# need to be same as "environment.id" property in iTrivio "settings.properties" file 152 -competentItrivioIntegration.auth.environment=PROD 153 - 154 -#-# need to be same as "jwt.key" property in iTrivio "settings.properties" file 155 -competentItrivioIntegration.auth.key=SECRET_CODE_CHANGE_IT 156 - 157 -#-# -------------- COMPETENT INTEGRATION ------------ 158 -#-# --- From iTrivio to Competent synchronization --- 159 - 160 -#-# competent db subtype ID, which will be used when creating new Users in Competent 161 -competentItrivioIntegration.newUserSubtypeId=<USER_SUBTYPE> 162 - 163 -#-# competent db subtype ID, which will be used when creating new Activities in Competent 164 -competentItrivioIntegration.newActivitySubtypeId=<ACTIVITY_SUBTYPE> 165 - 166 -#-# competent db activitySet (folder) ID, which will be used when creating new Activities in Competent as parent folder ID 167 -competentItrivioIntegration.newActivityTargetFolderId=<ACTIVITY_FOLDER> 168 -{{/code}} 169 - 170 170 = iTrivio part = 171 171 172 -Run the url "http(s):~/~/<yourdomain>:<port>/(companyUrl/)setCompanyConfig.html" on the domain and port your iTrivio runs and with the companyUrl of the company you are setting this for. 173 173 174 - Fill in the settingsCOMPETENT_INTEGRATION_XXX:84 +Run the url [[http:~~/~~/localhost:8080/(companyUrl/)setCompanyConfig.html>>url:http://localhost:8080/setCompanyConfig.html?locale=cs]] of course on the domain your iTrivio runs and with the companyUrl of the comany you are setting this for. 175 175 176 -* **COMPETENT_INTEGRATION_ENABLED// //**//check the box to be set to true// 177 -* **COMPETENT_INTEGRATION_TARGET_FOLDER_ID** = <COURSE_FOLDER> 178 -* **COMPETENT_INTEGRATION_API_URL **//(url where Competent is running eg.: //[[http:~~/~~/localhost:9000/>>url:http://localhost:9000/]]//)// 179 -* **COMPETENT_INTEGRATION_USERGROUP_ID** = <USERGROUP> 180 -* **COMPETENT_INTEGRATION_COURSE_TEMPLATE** = //leave this option blank, for now it has no effect on the system// 86 +Fill in the settings COMPETENT_INTEGRATION_: 181 181 182 -Save the setting with the **Odeslat **button (nothing visible will happen, don't be worried, it was saved) 88 +* **COMPETENT_INTEGRATION_ENABLED**// (set to true)// 89 +* **COMPETENT_INTEGRATION_TARGET_FOLDER_ID **//(ID of folder in iTrivio in which to create new Activites)// 90 +* **COMPETENT_INTEGRATION_API_URL **//(url where competent is running eg.: //[[http:~~/~~/localhost:9000/>>url:http://localhost:9000/]]//)// 91 +* **COMPETENT_INTEGRATION_USERGROUP_ID **//(ID of usergroup in iTrivio in which new users will be created)// 92 +* **COMPETENT_INTEGRATION_COURSE_TEMPLATE **//(optional - ID of course template in which new courses will be created)// 183 183 184 - Now openthefile "/com.itrivio/src/main/resources/settings.properties"and set the two following properties:94 +//(Save the settings... )// 185 185 186 -{{code language="properties"}} 187 -# custom environment name, e.g. PROD,DEV,TEST... 188 -# (must match the competentItrivioIntegration.auth.environment property from Competent) 189 -environment.id=PROD 96 +Now open the file /com.itrivio/src/main/resources/settings.properties and set the two following properties: 190 190 191 -# secret part of you JWT key - used for communication with the Competent system and creating auto-login links 192 -# (must match the competentItrivioIntegration.auth.key property from Competent) 193 -jwt.key=SECRET_CODE_CHANGE_IT 194 -{{/code}} 98 +**environment.id=croco**// (must match the **competentItrivioIntegration.auth.environment** property from Competent)// 99 +**jwt.key=CCzzzQYDR1HTdfe67zoa **//(must match the **competentItrivioIntegration.auth.key** property from Competent)// 195 195 196 196 = Final setting test = 197 197 198 -* Now run (or restart) both Systems, **but from now on do not touch iTrivio **apart from making changes in the course creator tool when redirected there from Competent. 199 -* Log into Competent (as the user able to edit iTrivio courses), go to the Admin view to the Activities page. 200 -* Create an Activity (of whatever subtype) and go to it's tab Details 201 -* Edit the Launch type property, set it to iTrivio and hit the Save and Create in iTrivio button 202 -* If you get any errors, check the configuration if all is set properly 203 -* Click the Edit button, it should take you to the iTrivio course editor, so add one new slide here, save it and close the browser tab. 204 -* Click the Start button, it should launch the iTrivio course for you. 205 -* If all this works, everything is set correctly 103 +Thats it, you should be good to go. Now run both Apps, DO NOT TOUCH ITRIVIO FROM NOW ON. Go to Competent, create some Activity and in Detail, set the RUN_TYPE (Typ spouštění) to iTrivio, then select in type and hit **Save and Create in iTrivio** button. If it works, you are almost good to go. Now try to Edit the course, add one page and then try to run it. if THAT works, you are all set.