Subversion Repositories wimsdev

Rev

Rev 11170 | Rev 12498 | Go to most recent revision | Details | Compare with Previous | Last modification | View Log | RSS feed

Rev Author Line No. Line
5181 guerimand 1
!read adm/language lang/names.phtml
11405 bpr 2
!set swlist=coq, gap, graphviz, m2, maxima, octave, pari, povray, geogebra, jsxgraph
3
!set swname=COQ, Gap, Graphviz, Macaulay 2, Maxima, Octave, PARI/GP, Povray, GeoGebra, Jsxgraph
3347 bpr 4
!set year=!char 1 to 4 of $wims_now
5
 
3009 bpr 6
!readdef wimshome/log/wims.conf
3151 bpr 7
!default mu_publish_site=!defof DF_mu_publish_site in wimshome/public_html/bases/sys/defaults.conf
3009 bpr 8
 
3151 bpr 9
!! when the selection of the site is done by the developpers
3024 guerimand 10
publish_site=$submitpublish_site
3151 bpr 11
!default publish_site=$mu_publish_site
3009 bpr 12
 
3024 guerimand 13
publishsitesname=$empty
3166 bpr 14
zonelist=$empty
3305 bpr 15
levellist=$empty
3151 bpr 16
!for name in $mu_publish_site
3024 guerimand 17
 tmp=!defof publishname in wimshome/public_html/bases/sys/publishcenter/$name
18
 tmp=!replace internal , by , in $tmp
19
 publishcentersname=!append item $tmp to $publishcentersname
3151 bpr 20
 tmp=!defof zonepublish,levellist in wimshome/public_html/bases/sys/publishcenter/$name
21
 zonepublishs=!append item $tmp to $zonepublishs
3166 bpr 22
 tmp=!defof zonelist,levellist in wimshome/public_html/bases/sys/publishcenter/$name
23
 zonelist=!append item $tmp to $zonelist
3305 bpr 24
 tmp=!defof levellist in wimshome/public_html/bases/sys/publishcenter/$name
25
 levellist=!append item $tmp to $levellist
3024 guerimand 26
!next name
3166 bpr 27
zonelist=!listuniq $zonelist
3305 bpr 28
zonelist=!listuniq $zonelist
3166 bpr 29
zonepublishs=!listuniq $zonepublishs
3305 bpr 30
levellist=!listuniq $levellist
3009 bpr 31
!! read the specification of $publish_site
3151 bpr 32
!if $submitpublish_site!=$empty
33
 !read wimshome/public_html/bases/sys/publishcenter/$submitpublish_site
34
  zonepublishs=$zonepublish
35
!endif
23 reyssat 36
wims_nw=job mod existing serial_number auth_login auth_passwd \
37
	original2 originalheader empty devdir fname target
38
wims_nr=wims_sesrandom
39
 
40
#############################################################
11170 bpr 41
jobs=modname create flist index edfile showfile delfile delconfirm\
42
	backup restore copy move del publish prop diff binfile changefile changeconfirm
23 reyssat 43
maxlist=100
44
sellist=10
45
alnum=0123456789abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ
46
searchsymbol=.*+-_~\[]|()<>
47
searchchars=$alnum$searchsymbol
48
langlist=!words2items $wims_site_languages
2389 bpr 49
!read lang/langname.$modu_lang
23 reyssat 50
deflist=title, description, language, category, domain, \
51
	level, keywords, require, scoring, copyright,\
52
	author, address, version, wims_version, vardef, \
6313 bpr 53
	translator, translator_address, data, maintainer, maintainer_address
54
 
23 reyssat 55
wims_form_method=post
56
!read tabletheme
57
 
58
!if $cmd=help or robot isin $session
59
 !exit
60
!endif
61
 
62
jobreq=!word 1 of $jobreq
63
!if $jobreq!=$empty and $jobreq iswordof $jobs
64
 job=$jobreq
65
!endif
66
jobreq=
67
 
68
!if $wims_class!=$empty
69
 !read adm/class/userdef classes,$wims_class,$wims_user
70
!endif
71
!if $wims_developer=$empty and $wims_class!=$empty and $wims_user!=$empty
72
 !if $wims_user=supervisor
73
  !if $wims_sup_secure>=0
74
   wims_developer=!getdef wims_developer in $userdef
75
  !endif
76
 !else
77
  wims_developer=!getdef wims_developer in $userdef
78
 !endif
79
 !distribute item $wims_developer into wims_developer,devpass
80
 !if $devpass=$empty
81
  !reset wims_developer
82
 !endif
83
!endif
84
 
85
!if $wims_ismanager>=2 and $change=yes
86
 wims_developer=
87
!endif
88
 
89
!if $wims_developer!=$empty and $auth_login=$empty
90
 n=!recordcnt wimshome/log/.developers
91
 !for i=1 to $n
92
  r=!record $i of wimshome/log/.developers
93
  !distribute lines $r into ll,pp,nn,ee
94
  pp=!passcrypt $pp
95
  !if $devpass!=$empty
96
   devpass=!passcrypt $devpass
97
  !endif
98
  !if $ll=$wims_developer and ($devpass=$empty or $devpass=$pp)
99
   auth_login=$ll
100
   auth_passwd=$pp
101
   auth_name=$nn
102
   auth_email=$ee
103
   login=$wims_developer
104
   sesdir=!translate internal _ to $ $ in $wims_sesdir
105
   sesdir=!word 1 of $sesdir
106
   !setdef wims_developer=$login in wimshome/$sesdir/var.stat
107
   !if $original!=$empty and $job=$empty
108
    job=copy
109
   !endif
10284 bpr 110
   !if $wims_developer!=$empty and $modreq!=$empty
111
    !default job=flist
112
   !endif
23 reyssat 113
   !default job=modname
114
   !break
115
  !endif
116
 !next i
117
 !if $auth_login=$empty
118
  wims_developer=
119
  job=auth
120
 !endif
121
!endif
122
!default job=auth
123
 
124
!if $auth_login=$empty and $wims_ismanager<2
125
 job=auth
126
!endif
127
!if $auth_login!=$empty
128
 devdir=modules/devel/$auth_login
129
!endif
130
 
6326 bpr 131
!read scripts/getindex $modreq
132
!default i_translation_language=$translation_language
133
 
134
deflist1=translation_language
135
trans_lang=!words2items $i_translation_language
136
 i_translation_language=!listintersect $trans_lang and $langlist
137
 i_translation_language=!listcomplement $i_language in $i_translation_language
138
 !for l in $(i_translation_language)
139
   deflist1=!append item title_$l to $deflist1
140
   deflist1=!append item description_$l to $deflist1
141
   deflist1=!append item keywords_$l to $deflist1
142
   deflist1=!append item translator_$l to $deflist1
143
   deflist1=!append item translator_address_$l to $deflist1
144
 !next
145
 
23 reyssat 146
!read $job.proc
147
 
148
!if $(name_$job)!=$empty
10078 bpr 149
 !!module_title=$module_title - $(name_$job)
10235 bpr 150
 wims_title_title=$(name_$job)
23 reyssat 151
!endif
152
 
153
!if ~ isin $mod
154
 m=!translate internal ~ to , in $mod
155
 m1=!item 1 of $m
156
 !reset pubtit
157
 !if $m1!=test and $m1 isitemof $zonelist
158
  m=!translate internal ~ to / in $mod
159
  pubtit=!module title $m
5686 bpr 160
  pubversion=!module version $m
23 reyssat 161
 !endif
162
!endif
163
 
6348 bpr 164
!reset validate_out
165
!if $validator_address!=$empty and $validation_ask!=$empty
6609 bpr 166
  !read adm/validation/validate.proc
6348 bpr 167
!endif
10236 bpr 168
 
11170 bpr 169
!if $job iswordof showfile edfile binfile index publish diff backup move copy changefile changeconfirm
10246 bpr 170
  !set wims_ariane=!append line modcontent,1,cmd=reply&jobreq=flist\
10236 bpr 171
to $wims_ariane
172
!endif
10246 bpr 173
!if $job iswordof move copy
174
  !set wims_ariane=!append line "$name_index",1,cmd=reply&jobreq=index\
175
to $wims_ariane
10236 bpr 176
!endif