Last modified by Anna Paul-Hasenfuss on 25.04.2024

Show last authors
1 {{layout}}
2 {{layout-section ac:type="two_right_sidebar"}}
3 {{layout-cell}}
4 Expert rules let you evaluate the assessment data of an assessable course element and thus control the visibility and access to other course sections. To do this, use the expert rules **getScore, getPassed, getMark** or **getProgress**. These rules are also used to summarize and weight the assessment data in the Structure course element.
5
6 Another possibility is to transfer the assessment data to an Onyx test. For more information, see the section [[Variables>>doc:LMS.Benutzerhandbuch OPAL.Lehren.Kursbausteine.Test.KB Test Konfiguration.KB Test - Variablen.WebHome]] on the course element Test.
7
8 {{info}}
9 All of the following example rules can be created for both the **visibility **and **access** of a course element. To simplify matters, only one scenario is described in each of the following examples. To learn more about the difference between visibility and access, see the page [[Publishing within courses (visibility and access)>>doc:LMS.Benutzerhandbuch OPAL.Lehren.Kurs.Freigabe von Kursen und Kursinhalten.Freigabe innerhalb von Kursen Sichtbarkeit und Zugang.WebHome||shape="rect"]].
10 {{/info}}
11 {{/layout-cell}}
12
13 {{layout-cell}}
14
15 {{/layout-cell}}
16 {{/layout-section}}
17
18 {{layout-section ac:type="single"}}
19 {{layout-cell}}
20 {{info}}
21 In all of the following examples, specific course elements are used. Before using these rules, note down the relevant course element IDs for your scenario and adjust them accordingly in the expert rules.
22 {{/info}}
23
24 (% class="relative-table wrapped" style="width:100.0%" %)
25 |=(% colspan="1" %)(% colspan="1" %)
26 (((
27 Syntax in general
28 )))|=(% colspan="1" %)(% colspan="1" %)
29 (((
30 Example of an expert rule
31 )))|=(% colspan="1" %)(% colspan="1" %)
32 (((
33 Result of this rule
34 )))
35 |(% colspan="1" %)(% colspan="1" %)
36 (((
37 //getScore("//[KB-ID]//")//
38 )))|(% colspan="1" %)(% colspan="1" %)
39 (((
40 getScore("84692289655276") >= 10
41 )))|(((
42 The course element is visible in the visibility tab as soon as the user has reached at least 10 points in the test (course element ID "84692289655276").
43 )))
44 |(% colspan="1" %)(% colspan="1" %)
45 (((
46 //getPassed("//[KB-ID]//")//
47 )))|(% colspan="1" %)(% colspan="1" %)
48 (((
49 getPassed("84389429397045")
50 )))|(((
51 If an entry is made in the Visibility tab, the course element is visible as soon as the user has passed the test (course element ID "84389429397045").
52 )))
53 |(% colspan="1" %)(% colspan="1" %)
54 (((
55 //getMark("[KB-ID]")//
56 )))|(% colspan="1" %)(% colspan="1" %)
57 (((
58 getAttempts("84692289655276") > 0 & getMark("84692289655276") < 4
59 )))|(((
60 If an entry is made in the Visibility tab, the course element is visible if the user's grade for the indicated element (course element ID "84692289655276") is better than 4.
61 )))
62 |(% colspan="1" %) |(% colspan="1" %)getMark("84692289655276")*0.5 + getMark("84692289655273")*0.4 + getMark("84389429397045")*0.1|When used in the Structure course element, the grade of the structure element can be determined by weighting the grades of other elements: in the example, the first course element accounts for 50% of the grade of the structure element, the second for 40% and the third for 10%.
63 |(% colspan="1" %)(% colspan="1" %)
64 (((
65 //getProgress("//[KB-ID]//")//
66 )))|(% colspan="1" %)(% colspan="1" %)
67 (((
68 getProgress("69742969114730")>=100
69 )))|(((
70 If an entry is made in the Access Tab, the course element is accessible if the user has completed the indicated course element (course element ID "69742969114730") (course progress).
71 )))
72
73 (% class="auto-cursor-target" %)
74 Create additional rules by using expert syntax. A tabular overview is provided on the page [[Expert syntax>>doc:LMS.Benutzerhandbuch OPAL.Lehren.Kurs.Freigabe von Kursen und Kursinhalten.Expertenmodus zur Freigabe innerhalb von Kursen.Expertensyntax.WebHome]].
75 {{/layout-cell}}
76 {{/layout-section}}
77
78 {{layout-section ac:type="single"}}
79 {{layout-cell}}
80 {{info}}
81 The implementation of another example on using expert rules is explained on the help page [[Learning path control by test result>>doc:LMS.Benutzerhandbuch OPAL.Lehren.Leitfäden.Lernwegsteuerung nach Testergebnis.WebHome]].
82 {{/info}}
83 {{/layout-cell}}
84 {{/layout-section}}
85 {{/layout}}