Subversion Repositories wimsdev

Compare Revisions

Ignore whitespace Rev 16031 → Rev 16032

/trunk/wims/public_html/modules/adm/raw/Changelog.md
1,21 → 1,23
adm/raw new features and modifications
--------------------------------------
**4.18c-r.16031 (2021-05-22) :**
- Now job addclass handle fields limits (OB)
**4.18c-r.16031 (2021-08-24) (OB):**
 
**4.18b-r.15818 (2021-05-22) :**
- add the job "getserverstat" to download server and class geoloc file and class and user number (FG)
- Now job addclass handle fields limits
- Job "getclass" can return strings with '"' in correct json
 
**4.18-r.15428 (2020-10-06) :**
- job authuser now check if user has changed his IP only if option $class_examscore_withoutip is active. (set by teacher in class params)
**4.18b-r.15818 (2021-05-22):**
Add the job "getserverstat" to download server and class geoloc file and class and user number (FG)
 
**4.17-r.14384 (2019-11-05) :**
**4.18-r.15428 (2020-10-06):**
Job authuser now check if user has changed his IP only if option `$class_examscore_withoutip` is active. (set by teacher in class params)
 
**4.17-r.14384 (2019-11-05):**
 
- add the job "changedates" (Repels the expiry date of `qclass` and all its sheets / exams)
- Jobs "listsheets" and "listexams" now display the list of expiration dates
 
 
**4.16b-r.14139 (2019-06-26) :**
**4.16b-r.14139 (2019-06-26):**
 
- add "last_detail" to getsheetscores (gives the last score for each exercice) + correct a bug on "requires"
- now getsheetscores job gives the sheet formula chosen by supervisor
22,24 → 24,24
- add "sheet_weight" in getsheetscores job + rename "weights" into "exo_weights"
 
 
**4.16a-r.13828 (2019-04-12) :**
**4.16a-r.13828 (2019-04-12):**
 
- add "allowcloning" and "cloningpwd" to class_defs showed in getclass and listclasses (only allowcloning is accessible by listclasses)
- remove debug informations displayed in case of identification failure, and connexion refused by requested class
 
 
**4.16-r.13460 (2018-12-04) :**
**4.16-r.13460 (2018-12-04):**
 
- A bunch of bugfixes, issued by Q. Coumes (thx to him) :
- **copyclass** : was not working as expected for a single class
- **getclassmodif** : was not returning a valid json when several modified files
- **getclasstgz** : HTML headers was merged with the tgz binary.
- **putcsv** : this alpha draft job now clearly indicate to avaoid using it until it's finished, instead of returning "unauthorized"
- **recuser** : more explicit message returned : "User successfully recovered"
- **repairclass** : typo corrected ('action,')
- **copyclass**: was not working as expected for a single class
- **getclassmodif**: was not returning a valid json when several modified files
- **getclasstgz**: HTML headers was merged with the tgz binary.
- **putcsv**: this alpha draft job now clearly indicate to avaoid using it until it's finished, instead of returning "unauthorized"
- **recuser**: more explicit message returned : "User successfully recovered"
- **repairclass**: typo corrected ('action,')
 
 
**4.15-r.13228 (2018-07-20) :**
**4.15-r.13228 (2018-07-20):**
 
- bugfix with the wims_sheet forbidden variable, replaced by sheet_id
- add missing addexam, addexo and putexo in the protocol doc
46,34 → 48,34
- reformat protocol doc in markdown
 
 
**4.14-r.12957 (2018-06-15) :**
**4.14-r.12957 (2018-06-15):**
 
- Job "getclass" gives some more lists (subclasses in a group, and every sub-items in the portal)
- script "check.class" accepts class portals
 
 
**4.13-r.11380 (2018-01-11) :**
**4.13-r.11380 (2018-01-11):**
 
- Job "deluser" removes also user related data (score, logs...)
- Job "recuser" recovers also user related data (score, logs...)
- Job "deluser" accepts new option "del_from_trash" to orce a real user deletion
 
**4.12a-r.11380 (2018-01-09) :**
**4.12a-r.11380 (2018-01-09):**
Job "lightpopup" now keep trace of http protocol (https)
 
**4.12-r.11380 (2017-06-14) :**
**4.12-r.11380 (2017-06-14):**
 
- Add a new job "buildexos" : it compiles (src->def) all class exercices, and refresh indexes
- Jobs "delexo" and "addexo" now accept the option "no_build", that improves the speed when there is a lot of exercices to handle at the same time. (but don't forget to call the "buildexos" job when all the deletions are done !)
- better severity definition in addsheet
 
**4.11-r.11380 (2017-03-01) :**
**4.11-r.11380 (2017-03-01):**
Bugfix in GetSheetScores : when there was more than 100 users in the class, a cmd_output_too_long error was raised. (now cuts user list every 50)
 
**4.10-r.11100 (2016-11-23) :**
**4.10-r.11100 (2016-11-23):**
Adds 2 scripts used in modexosheet job (check.worksheet & clean.worksheet). They should have been already here since r.5665 :/
 
**4.09-r.11095 (2016-10-31) :**
**4.09-r.11095 (2016-10-31):**
 
- corrects a bug introduced in r.10935 in addsheet and modsheet jobs. (!singlespace is replacing returns by simple spaces)
- introduces a new job in ALPHA state : "repairclass"
80,84 → 82,84
- corrects a small bug in getsheet
- getcsv & getclass now call "mkuserlist" script, just to be sure the userlist contains all the users.
 
**4.08-r.10935 (2016-08-29) :**
**4.08-r.10935 (2016-08-29):**
removes unwanted spaces/tabs in sheet properties in addsheet, getsheet and modsheet jobs.
 
**4.07-r.10778 (2016-07-12) :**
**4.07-r.10778 (2016-07-12):**
`./build-index` now is called on the superclass ID when present. (addclass, copyclass, delclass, modclass)
 
**4.06-r.9963 (2016-03-23) :** "delsheet" and "delexam" jobs now can't delete a sheet/exam if there is at least one more recent active of same type. (jobs still in BETA) + adjust some WIMS limits (MAX_EXOS, MAX_EXAMS, MAX_SHEETS) : now you cant add more than MAX_SHEETS sheets and MAX_EXAMS exams.
**4.06-r.9963 (2016-03-23):** "delsheet" and "delexam" jobs now can't delete a sheet/exam if there is at least one more recent active of same type. (jobs still in BETA) + adjust some WIMS limits (MAX_EXOS, MAX_EXAMS, MAX_SHEETS) : now you cant add more than MAX_SHEETS sheets and MAX_EXAMS exams.
 
**4.05-r.9912 (2016-02-08) :** "getscores" job is only calling "getcsv". The only difference between this job and getcsv, is that this one returns a usual response formatted, not a directly downloadable file. No more duplicated code : this one will also directly benefits from updates in userscore module.
**4.05-r.9912 (2016-02-08):** "getscores" job is only calling "getcsv". The only difference between this job and getcsv, is that this one returns a usual response formatted, not a directly downloadable file. No more duplicated code : this one will also directly benefits from updates in userscore module.
 
**4.04-r.9909 (2016-02-05) :** "getcsv" job calls directly scripts from "adm/class/userscore", to avoid duplicated code. + delete job "download", which was only a duplicata of "getcsv"
**4.04-r.9909 (2016-02-05):** "getcsv" job calls directly scripts from "adm/class/userscore", to avoid duplicated code. + delete job "download", which was only a duplicata of "getcsv"
 
**4.03-r.9896 (2016-01-27) :** now "getscore" and "getsheetscores" jobs send also user's bests and levels
**4.03-r.9896 (2016-01-27):** now "getscore" and "getsheetscores" jobs send also user's bests and levels
 
**4.02-r.9627 (2015-10-13) :** now "getsheetscores" and "getexamscores" jobs send also user's full names
**4.02-r.9627 (2015-10-13):** now "getsheetscores" and "getexamscores" jobs send also user's full names
 
**4.01-r.6628 (2013-05-27) :** now verify wims exam and sheet limits (64 exercices max)
**4.01-r.6628 (2013-05-27):** now verify wims exam and sheet limits (64 exercices max)
 
**4.00-r.6514 (2013-04-19) :** now cleanClass can clean a sublclass in a superclass
**4.00-r.6514 (2013-04-19):** now cleanClass can clean a sublclass in a superclass
 
**r.6364 (2013-02-12) :** getlog can now give log connexions for exams. (option = exams)
**r.6364 (2013-02-12):** getlog can now give log connexions for exams. (option = exams)
 
**r.6026 (2013-04-19) :** optimizing getlog job, now it can render more than 500 lines of a user log
**r.6026 (2013-04-19):** optimizing getlog job, now it can render more than 500 lines of a user log
 
**r.5967 (2012-11-13) :** 2 new jobs :
**r.5967 (2012-11-13):** 2 new jobs :
 
- copyclass
- and getsheetstats + multiple bugs corrections
 
**r.5802 (2012-10-18) :** Correction d'un bug empechant l'ajout d'un exercice contenant des virgules dans une feuille.
**r.5802 (2012-10-18):** Correction d'un bug empechant l'ajout d'un exercice contenant des virgules dans une feuille.
 
**r.5678 (2012-09-21) :** Adds new script "adm/urldecode" : exact opposite of "adm/codeurl" script. (converts an URI string into normal string) + Corrects a bug in adm/raw putexo : now module url is well converted if sended in URI format. nb : for urldecode/codeurl works, you have to install a perl libray (liburi-perl on debian // p5-uri on Mac)
**r.5678 (2012-09-21):** Adds new script "adm/urldecode" : exact opposite of "adm/codeurl" script. (converts an URI string into normal string) + Corrects a bug in adm/raw putexo : now module url is well converted if sended in URI format. nb : for urldecode/codeurl works, you have to install a perl libray (liburi-perl on debian // p5-uri on Mac)
 
**r.5672 (2012-09-19) :** corrections on "getlog" job
**r.5672 (2012-09-19):** corrections on "getlog" job
 
**r.5591 (2012-07-11) :** Corrects a bug causing malformed single class creation
**r.5591 (2012-07-11):** Corrects a bug causing malformed single class creation
 
**r.5305 (2012-05-25) :** Udpate "Listmodules" job in json, adding translated titles for levels. + small css update
**r.5305 (2012-05-25):** Udpate "Listmodules" job in json, adding translated titles for levels. + small css update
 
**r.5303 (2012-05-16) :** Corrects a bug causing variable `$wims_supertype` not set on user session + minor improvement on job "listmodules"
**r.5303 (2012-05-16):** Corrects a bug causing variable `$wims_supertype` not set on user session + minor improvement on job "listmodules"
 
**r.5273 (2012-04-25) :** bug correction on Json format
**r.5273 (2012-04-25):** bug correction on Json format
 
**r.5263 (2012-04-21) :** loggin when users are created (like in the standard reguser)
**r.5263 (2012-04-21):** loggin when users are created (like in the standard reguser)
 
**r.5174 (2012-03-20) :** trying to get the "class connection with other servers" working
**r.5174 (2012-03-20):** trying to get the "class connection with other servers" working
 
**r.5156 (2012-03-13) :** let authuser accept external identification
**r.5156 (2012-03-13):** let authuser accept external identification
 
**r.5142 (2012-03-13) :** adding missing variables,needed for ipd_method=php
**r.5142 (2012-03-13):** adding missing variables,needed for ipd_method=php
 
**r.5017 (2012-02-17) :** Variable names changes: cas_host becomes cas_auth. Added
**r.5017 (2012-02-17):** Variable names changes: cas_host becomes cas_auth. Added
 
**r.4999 (2012-02) :** adds auth, cas_host param for class
**r.4999 (2012-02):** adds auth, cas_host param for class
 
**r.4998 (2012-02) :** adds "external_auth" param for users
**r.4998 (2012-02):** adds "external_auth" param for users
 
**r.4794 (2011-12) :** correction bug sur addexam + ajout d'infos sur delclass
**r.4794 (2011-12):** correction bug sur addexam + ajout d'infos sur delclass
 
**r.4783 (2011-12) :** correction bug divers (doubles quotes maintenant autorisées dans getsheet et getexam)
**r.4783 (2011-12):** correction bug divers (doubles quotes maintenant autorisées dans getsheet et getexam)
 
**r.4746 (2011-11) :** correcting bug on "listmodules" export in json + html correction in oef/Main
**r.4746 (2011-11):** correcting bug on "listmodules" export in json + html correction in oef/Main
 
**r.4687 (2011-10) :** getclassesuser n'est plus lancé lorsque listclass a généré une erreur ==> messages d'erreurs plus clairs ainsi.
**r.4687 (2011-10):** getclassesuser n'est plus lancé lorsque listclass a généré une erreur ==> messages d'erreurs plus clairs ainsi.
 
**r.4668 (2011-10) :** correcting bug on "getclassesuser"
**r.4668 (2011-10):** correcting bug on "getclassesuser"
 
**r.4658 (2011-10) :** allowing for class setup via adm/raw
**r.4658 (2011-10):** allowing for class setup via adm/raw
 
**r.4653 (2011-10) :** listclasses does not need the list of participants
**r.4653 (2011-10):** listclasses does not need the list of participants
 
**3.32-r.4641 (09/2011) :** New Jobs :
**3.32-r.4641 (09/2011):** New Jobs :
 
- linksheet (adds all exercices from sheet $qsheet to exam $qexam)
- getsheetscores (gets all score from sheet $qsheet - JSON only)
- getexamscores (gets all score from exam $qexam - JSON only)
 
**3.31 (06/2011) :**
**3.31 (06/2011):**
 
- New jobs : getexosheet, modexosheet
- New script : update.exo
164,7 → 166,7
GetSheet has also been modified. to get exercise list from this Job, now you have
to make a script in the response type.
 
**3.30 (05/2011) :**
**3.30 (05/2011):**
 
- New jobs : listexos, movexo, movexos, sharecontent
- New script : check.exoclass
173,7 → 175,7
to get exercise list from this job.
Use "listexos" instead
 
**3.23 (06/2010) :**
**3.23 (06/2010):**
 
- New jobs : addexam, addexo, checkexam, delexam, delexo, download, getexam,
getexamlog, getexo, getexofile, getmodule, getscores, linkexo,
181,7 → 183,7
(some jobs are currently in beta only)
- XML format improved (still needs work)
 
**3.22 (06/2009) :**
**3.22 (06/2009):**
 
- bugs in getcvs due to !hex in scoring
- New options for getclass (program, subcourse,. ..)
188,7 → 190,7
- New job : listclasses which gives listclasses with connection with some ident
and rclass
 
**3.21 (03/2008) :**
**3.21 (03/2008):**
 
- All outputs can be formatted according to the desire of the querying software.
- few bugs corrected (i.e., a wrong expiration date on job addclass)
/trunk/wims/public_html/modules/adm/raw/types/json
158,23 → 158,23
 
:getsheet
!for i=1 to $exocnt
exo=!record $i of $qfile
exo_module=!line 1 of $exo
exo_params=!line 2 of $exo
exo_points=!line 3 of $exo
exo_weight=!line 4 of $exo
exo_title=!line 5 of $exo
exo_title=!replace internal " by \" in $exo_title
exo_description=!line 6 of $exo
exo_description=!replace internal " by \" in $exo_description
exo=!record $i of $qfile
exo_module=!line 1 of $exo
exo_params=!line 2 of $exo
exo_points=!line 3 of $exo
exo_weight=!line 4 of $exo
exo_title=!line 5 of $exo
exo_title=!replace internal " by \" in $exo_title
exo_description=!line 6 of $exo
exo_description=!replace internal " by \" in $exo_description
 
exo_defs={"module":"$exo_module","title":"$exo_title","params":"$exo_params","points":"$exo_points","weight":"$exo_weight","description":"$exo_description"}
exo_defs={"module":"$exo_module","title":"$exo_title","params":"$exo_params","points":"$exo_points","weight":"$exo_weight","description":"$exo_description"}
 
!if $exolist!=$empty
exolist=$exolist,$exo_defs
!else
exolist=$exo_defs
!endif
!if $exolist!=$empty
exolist=$exolist,$exo_defs
!else
exolist=$exo_defs
!endif
!next i
 
sheet_properties = !replace internal " by $\"$ in $sheet_properties
181,7 → 181,7
sheet_title = !replace internal " by $\"$ in $sheet_title
sheet_description = !replace internal " by $\"$ in $sheet_description
 
!shortout "query_class":"$qclass"\
!shortout "query_class":"$qclass"\
,"query_sheet":"$qsheet"\
,"exo_cnt":"$exocnt"\
,"sheet_properties":"$sheet_properties"\
212,7 → 212,7
exam_title = !replace internal " by $\"$ in $exam_title
exam_description = !replace internal " by $\"$ in $exam_description
 
!shortout "query_class":"$qclass"\
!shortout "query_class":"$qclass"\
,"query_exam":"$qexam"\
,"exam_properties":"$exam_properties"\
,"exocnt":"$exocnt"\
302,7 → 302,7
!goto footer
 
:delclass
cd=!replace internal / by _ in $qclass
cd=!replace internal / by _ in $qclass
!shortout "class_id":"$cd",\
"message":"class $cd correctly deleted",\
"log":"$log"\
310,7 → 310,7
!goto footer
 
:addclass
cd=!replace internal / by _ in $cd
cd=!replace internal / by _ in $cd
!shortout "class_id":"$cd",\
"message":"class $cd correctly added",\
"log":"$log"\
318,8 → 318,8
!goto footer
 
:getclass
!shortout "query_class":"$qclass",\
"rclass":"$rclass"\
!shortout "query_class":"$qclass",\
"rclass":"$rclass"\
,
list_cnt=!itemcnt $option
i=0
326,34 → 326,34
 
!for d in $option
 
!if $d isitemof userlist
!if $d isitemof userlist
newList=$(class_$d)
newList=!replace internal , by "," in $newList
!shortout "$d":["$newList"]
!endif
!shortout "$d":["$newList"]
!endif
 
!if $d isitemof subclasses_list,programs_list,classes_list,icourses_list,levels_list,courses_list
!if $d isitemof subclasses_list,programs_list,classes_list,icourses_list,levels_list,courses_list
newList=$(class_$d)
newList=!replace internal $\
$ by "];[" in $newList
newList=!replace internal , by "," in $newList
newList=!replace internal ; by , in $newList
!shortout "$d":[["$newList"]]
!endif
!shortout "$d":[["$newList"]]
!endif
 
!if list notin $d
!shortout "$d":"$(class_$d)"
!endif
!if list notin $d
class_$d = !replace internal " by \" in $(class_$d)
!shortout "$d":"$(class_$d)"
!endif
 
 
!advance i
!advance i
 
!if $i<$list_cnt
!shortout \
!if $i<$list_cnt
!shortout \
,
!endif
!endif
 
 
!next d
 
!goto footer
376,14 → 376,14
i=0
 
!for d in $option
!shortout "$d":"$(user_$d)"
!shortout "$d":"$(user_$d)"
 
!advance i
!advance i
 
!if $i<$list_cnt
!shortout \
!if $i<$list_cnt
!shortout \
,
!endif
!endif
 
!next d
!goto footer
414,22 → 414,22
 
:getexamscores
!for v in weights
$v=!trim $($v)
!if $v != $empty
$v=!wordstoitems $($v)
$v=[$($v)]
!else
$v=""
!endif
$v=!trim $($v)
!if $v != $empty
$v=!wordstoitems $($v)
$v=[$($v)]
!else
$v=""
!endif
!next v
 
!if $data_scores != $empty
data_scores=!replace internal $\
data_scores=!replace internal $\
$ by },{ in $data_scores
data_scores =!replace internal NaN by "NaN" in $data_scores
data_scores=[{$data_scores}]
data_scores =!replace internal NaN by "NaN" in $data_scores
data_scores=[{$data_scores}]
!else
data_scores=""
data_scores=""
!endif
 
!shortout "query_exam":$qexam,\
450,13 → 450,13
:getsheetscores
 
!for v in requires, weights
$v=!trim $($v)
!if $v != $empty
$v=!wordstoitems $($v)
$v=[$($v)]
!else
$v=""
!endif
$v=!trim $($v)
!if $v != $empty
$v=!wordstoitems $($v)
$v=[$($v)]
!else
$v=""
!endif
!next v
 
sheet_mean_percent =!replace internal NaN by "NaN" in $sheet_mean_percent
481,19 → 481,19
 
 
!if $usercnt > 0
!shortout [
!for u=1 to $usercnt
data_scores = !record $u of wimshome/sessions/$wims_session/data.scores
data_scores =!replace internal NaN by "NaN" in $data_scores
!shortout {$data_scores}
!if $u < $usercnt
!shortout ,\
!shortout [
!for u=1 to $usercnt
data_scores = !record $u of wimshome/sessions/$wims_session/data.scores
data_scores =!replace internal NaN by "NaN" in $data_scores
!shortout {$data_scores}
!if $u < $usercnt
!shortout ,\
 
!endif
!next u
!shortout ]
!endif
!next u
!shortout ]
!else
!shortout ""\
!shortout ""\
 
!endif
 
508,7 → 508,7
sheetqualitydetail=[$sheetqualitydetail]
 
!for v in sheet_mean_percent, sheet_mean_quality, sheetmeandetail, sheetgotdetail
$v = !replace internal NaN by "NaN" in $($v)
$v = !replace internal NaN by "NaN" in $($v)
!next v
 
!shortout "query_sheet":$qsheet,\
533,20 → 533,20
double_lists = examscore
 
!for v in $json_lists
$v=!trim $($v)
!if $v != $empty
$v=!replace internal $\
$v=!trim $($v)
!if $v != $empty
$v=!replace internal $\
$ by ],[ in $($v)
$v=!replace internal $ $ by , in $($v)
$v=!replace internal ,] by ] in $($v)
!if $v isitemof $double_lists or $qsheet = $empty
$v=[[$($v)]]
!else
$v=[$($v)]
!endif
!else
$v=""
!endif
$v=!replace internal $ $ by , in $($v)
$v=!replace internal ,] by ] in $($v)
!if $v isitemof $double_lists or $qsheet = $empty
$v=[[$($v)]]
!else
$v=[$($v)]
!endif
!else
$v=""
!endif
!next v
 
!if $qsheet!=$empty
568,7 → 568,7
,"score_qualities":$meandetail\
 
!if $qsheet != $empty
!shortout ,"query_sheet":"$qsheet"\
!shortout ,"query_sheet":"$qsheet"\
 
!endif
!goto footer
583,20 → 583,20
,"user_log":
 
!if $export_size > 0
!shortout [
!for i=1 to $export_size
current = !record $i of wimshome/sessions/$wims_session/user.log
current = !singlespace $current
current = !replace internal $ $ by "," in $current
!shortout ["$current"]
!if $i < $export_size
!shortout ,\
!shortout [
!for i=1 to $export_size
current = !record $i of wimshome/sessions/$wims_session/user.log
current = !singlespace $current
current = !replace internal $ $ by "," in $current
!shortout ["$current"]
!if $i < $export_size
!shortout ,\
 
!endif
!next i
!shortout ]
!endif
!next i
!shortout ]
!else
!shortout ""\
!shortout ""\
 
!endif
 
628,6 → 628,7
!shortout "server_time":"$now_year$now_month$now_day.$now_hour:$now_min:$now_sec"
!goto footer
 
 
:getexo
!shortout "query_class":"$qclass"\
,"querysheet":"$qsheet"\
651,6 → 652,7
 
!goto footer
 
 
:getcourse
!shortout "query_class":"$qprogram",\
"courses":"$wims_class"\
663,24 → 665,24
"classes_list":[\
 
!for i = 1 to $list_cnt
qclass=!item $i of $listclasses
rclass=!item $i of $list_rclasses
!read jobs/checkclass.proc
!if $error!=$empty
!exit
!endif
!readdef $classdeffile
!shortout {"qclass":"$qclass"\
qclass=!item $i of $listclasses
rclass=!item $i of $list_rclasses
!read jobs/checkclass.proc
!if $error!=$empty
!exit
!endif
!readdef $classdeffile
!shortout {"qclass":"$qclass"\
 
!for d in $options
!shortout ,"$d":"$(class_$d)"\
!for d in $options
!shortout ,"$d":"$(class_$d)"\
 
!next d
!next d
 
!if $i < $list_cnt
!shortout },\
!if $i < $list_cnt
!shortout },\
 
!endif
!endif
 
!next i
!shortout }]\
698,24 → 700,24
 
 
!for i = 1 to $list_cnt
qclass=!item $i of $listclassesuser
rclass=!item $i of $list_rclassesuser
!read jobs/checkclass.proc
!if $error!=$empty
!exit
!endif
!readdef $classdeffile
!shortout {"qclass":"$qclass"\
qclass=!item $i of $listclassesuser
rclass=!item $i of $list_rclassesuser
!read jobs/checkclass.proc
!if $error!=$empty
!exit
!endif
!readdef $classdeffile
!shortout {"qclass":"$qclass"\
 
!for d in $options
!shortout ,"$d":"$(class_$d)"\
!for d in $options
!shortout ,"$d":"$(class_$d)"\
 
!next d
!next d
 
!if $i < $list_cnt
!shortout },\
!if $i < $list_cnt
!shortout },\
 
!endif
!endif
 
!next i
!shortout }]\
730,61 → 732,60
pos = !positionof item $curent_dir in $wims_listlevel
title=!item $pos of $name_wims_listlevel
 
 
!shortout "base_directory":"$base_directory",\
"nbelement":$nb_modules,\
"lang_exists":"$lang_exists",\
"lang":"$lang",\
"title":"$title",\
"listContent":[\
"nbelement":$nb_modules,\
"lang_exists":"$lang_exists",\
"lang":"$lang",\
"title":"$title",\
"listContent":[\
 
!for i = 1 to $nb_modules
id=!item $i of $listContent
!if $base_directory notsametext /
option=$base_directory/$id
!else
option=$base_directory$id
!endif
pos = !positionof item $id in $wims_listlevel
id=!item $i of $listContent
!if $base_directory notsametext /
option=$base_directory/$id
!else
option=$base_directory$id
!endif
pos = !positionof item $id in $wims_listlevel
 
!read jobs/getmodule.proc
!read jobs/getmodule.proc
 
!default title=!item $pos of $name_wims_listlevel
!default title=!item $pos of $name_wims_listlevel
 
!shortout {"id":"$id",\
"module_path":"$option",\
"title":"$title"
!shortout {"id":"$id",\
"module_path":"$option",\
"title":"$title"
 
!if $author notsametext
!shortout ,"description":"$description",\
"index_url" : "$wims_ref_name?module=$option&lang=$language",\
"language":"$language",\
"category" : "$category",\
"domain" : "$domain",\
"level" : "$level",\
"keywords" : "$keywords",\
"require" : "$require",\
"scoring" : "$scoring",\
"copyright" : "$copyright",\
"author" : "$author",\
"author_address" : "$address",\
"version" : "$version",\
"required_wims_version" : "$required_wims_version",\
"vardef" : "$vardef",\
"translator" : "$translator",\
"translator_address" : "$translator_address",\
"data" : "$data",\
"maintainer" : "$maintainer",\
"maintainer_address" : "$maintainer_address",\
"translation_language" : "$translation_language"\
!if $author notsametext
!shortout ,"description":"$description",\
"index_url" : "$wims_ref_name?module=$option&lang=$language",\
"language":"$language",\
"category" : "$category",\
"domain" : "$domain",\
"level" : "$level",\
"keywords" : "$keywords",\
"require" : "$require",\
"scoring" : "$scoring",\
"copyright" : "$copyright",\
"author" : "$author",\
"author_address" : "$address",\
"version" : "$version",\
"required_wims_version" : "$required_wims_version",\
"vardef" : "$vardef",\
"translator" : "$translator",\
"translator_address" : "$translator_address",\
"data" : "$data",\
"maintainer" : "$maintainer",\
"maintainer_address" : "$maintainer_address",\
"translation_language" : "$translation_language"\
 
!endif
!endif
 
!shortout }
!shortout }
 
!if $i < $nb_modules
!shortout ,
!endif
!if $i < $nb_modules
!shortout ,
!endif
 
!next i
!shortout ]\
824,7 → 825,7
 
 
:modsheet
!shortout "query_class":"$qclass",\
!shortout "query_class":"$qclass",\
"querysheet":"$qsheet",\
"changes_requested":$n,\
"changes_done":$nbdefs,\
831,6 → 832,7
"message":"$nbdefs modifications done on sheet $qsheet."
!goto footer
 
 
:putexo
!shortout "message":"exercice correctly added in sheet #$sheet_id",\
"query_class":"$wims_class",\
840,6 → 842,7
 
!goto footer
 
 
:modexosheet
!shortout "query_class":"$qclass",\
"queryexo":"$qexo",\
847,6 → 850,7
"message":"$message"
!goto footer
 
 
:modexam
!shortout "query_class":"$qclass",\
"queryexam":"$qexam",\
854,6 → 858,7
"message":"$nbdefs modifications done on exam $qexam."
!goto footer
 
 
:listlinks
listlinks=!replace internal , by "," in $listlinks
!shortout "nblinks":"$nblink",\
861,6 → 866,7
 
!goto footer
 
 
:linksheet
:linkexo
!shortout "message":"$exocnt exercice(s) correctly added in exam #$qexam from sheet #$qsheet",\
873,7 → 879,6
!goto footer
 
 
 
:delexo
!shortout "message":"exercice $qexo successfully deleted",\
"exo_id":"$qexo",\
890,6 → 895,7
 
!goto footer
 
 
:delexam
cnt=!recordcnt wimshome/log/classes/$qclass/exams/.exams
!shortout "message":"Exam #$qexam of class $qclass correctly deleted",\
897,6 → 903,7
 
!goto footer
 
 
:cleanclass
suppressed_users = !eval ($usercnt_before - $usercnt_after)
!shortout "message":"class $qclass correctly cleaned",\
919,6 → 926,7
 
!goto footer
 
 
:copyclass
!!new_class=!replace internal / by _ in $new_class
!shortout "new_class":"$new_class",\
928,6 → 936,7
 
!goto footer
 
 
:putcsv
!shortout "query_class":"$qclass",\
"message":"putCSV is at very early draft state. Do not use it yet (WIP)."\
934,6 → 943,7
 
!goto footer
 
 
:footer
!shortout }
!shortout }
!exit