File: gamification_badge_data_answer.xml

package info (click to toggle)
odoo 18.0.0%2Bdfsg-2
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 878,716 kB
  • sloc: javascript: 927,937; python: 685,670; xml: 388,524; sh: 1,033; sql: 415; makefile: 26
file content (256 lines) | stat: -rw-r--r-- 14,307 bytes parent folder | download | duplicates (2)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
<?xml version="1.0" encoding="utf-8"?>
<odoo>
    <data noupdate="1">

        <!-- QUALITY (VOTES) -->
        <!-- Teacher: at least 3 upvotes -->
        <record id="badge_a_1" model="gamification.badge">
            <field name="name">Teacher</field>
            <field name="description">Received at least 3 upvote for an answer for the first time</field>
            <field name="level">bronze</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_teacher">
            <field name="name">Teacher</field>
            <field name="description">Received at least 3 upvote for an answer for the first time</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 3)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_teacher">
            <field name="name">Teacher</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_1"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_teacher">
            <field name="definition_id" ref="definition_teacher"/>
            <field name="challenge_id" ref="challenge_teacher"/>
            <field name="target_goal">1</field>
        </record>
        <!-- Nice: at least 4 upvotes -->
        <record id="badge_a_2" model="gamification.badge">
            <field name="name">Nice Answer</field>
            <field name="description">Answer voted up 4 times</field>
            <field name="level">bronze</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_nice_answer">
            <field name="name">Nice Answer (4)</field>
            <field name="description">Answer voted up 4 times</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 4)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_nice_answer">
            <field name="name">Nice Answer</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_2"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_nice_answer">
            <field name="definition_id" ref="definition_nice_answer"/>
            <field name="challenge_id" ref="challenge_nice_answer"/>
            <field name="target_goal">1</field>
        </record>
        <!-- Good: at least 6 upvotes -->
        <record id="badge_a_3" model="gamification.badge">
            <field name="name">Good Answer</field>
            <field name="description">Answer voted up 6 times</field>
            <field name="level">silver</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_good_answer">
            <field name="name">Good Answer (6)</field>
            <field name="description">Answer voted up 6 times</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 6)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_good_answer">
            <field name="name">Good Answer</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_3"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_good_answer">
            <field name="definition_id" ref="definition_good_answer"/>
            <field name="challenge_id" ref="challenge_good_answer"/>
            <field name="target_goal">1</field>
        </record>
        <!-- Great: at least 15 upvotes -->
        <record id="badge_a_4" model="gamification.badge">
            <field name="name">Great Answer</field>
            <field name="description">Answer voted up 15 times</field>
            <field name="level">gold</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_great_answer">
            <field name="name">Great Answer (15)</field>
            <field name="description">Answer voted up 15 times</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 15)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_great_answer">
            <field name="name">Great Answer</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_4"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_great_answer">
            <field name="definition_id" ref="definition_great_answer"/>
            <field name="challenge_id" ref="challenge_great_answer"/>
            <field name="target_goal">1</field>
        </record>

        <!-- ACCEPTANCE -->
        <!-- Enlightened: at least 3 upvotes for an accepted answer -->
        <record id="badge_a_5" model="gamification.badge">
            <field name="name">Enlightened</field>
            <field name="description">Answer was accepted with 3 or more votes</field>
            <field name="level">silver</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_enlightened">
            <field name="name">Enlightened</field>
            <field name="description">Answer was accepted with 3 or more votes</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 3), ('is_correct', '=', True)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_enlightened">
            <field name="name">Enlightened</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_5"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_enlightened">
            <field name="definition_id" ref="definition_enlightened"/>
            <field name="challenge_id" ref="challenge_enlightened"/>
            <field name="target_goal">1</field>
        </record>
        <!-- Guru: at least 15 upvotes for an accepted answer -->
        <record id="badge_a_6" model="gamification.badge">
            <field name="name">Guru</field>
            <field name="description">Answer accepted with 15 or more votes</field>
            <field name="level">silver</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_guru">
            <field name="name">Guru (15)</field>
            <field name="description">Answer accepted with 15 or more votes</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('parent_id', '!=', False), ('vote_count', '>=', 15), ('is_correct', '=', True)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_guru">
            <field name="name">Guru</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_6"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_guru">
            <field name="definition_id" ref="definition_guru"/>
            <field name="target_goal">1</field>
            <field name="challenge_id" ref="challenge_guru"/>
        </record>

        <!-- Sealf Leaner: own question, 3+ upvotes -->
        <record id="badge_a_8" model="gamification.badge">
            <field name="name">Self-Learner</field>
            <field name="description">Answered own question with at least 4 up votes</field>
            <field name="level">gold</field>
            <field name="rule_auth">nobody</field>
        </record>
        <record model="gamification.goal.definition" id="definition_self_learner">
            <field name="name">Self-Learner</field>
            <field name="description">Answer own question with at least 4 up votes</field>
            <field name="computation_mode">count</field>
            <field name="display_mode">boolean</field>
            <field name="model_id" ref="website_forum.model_forum_post"/>
            <field name="condition">higher</field>
            <field name="domain">[('self_reply', '=', True), ('vote_count', '>=', 4)]</field>
            <field name="batch_mode">True</field>
            <field name="batch_distinctive_field" ref="website_forum.field_forum_post__create_uid"/>
            <field name="batch_user_expression">user.id</field>
        </record>
        <record model="gamification.challenge" id="challenge_self_learner">
            <field name="name">Self-Learner</field>
            <field name="period">once</field>
            <field name="visibility_mode">personal</field>
            <field name="report_message_frequency">never</field>
            <field name="reward_id" ref="badge_a_8"/>
            <field name="reward_realtime">True</field>
            <field name="user_domain">[('karma', '>', 0)]</field>
            <field name="state">inprogress</field>
            <field name="challenge_category">forum</field>
        </record>
        <record model="gamification.challenge.line" id="line_self_learner">
            <field name="definition_id" ref="definition_self_learner"/>
            <field name="target_goal">1</field>
            <field name="challenge_id" ref="challenge_self_learner"/>
        </record>

    </data>
</odoo>