Commit massif sur l'intranet
darcs-hash:20070602131029-c992d-820d228ff611f44b2a1fcb185633a65d865baad2.gz
This commit is contained in:
parent
1917896510
commit
5d71550f6b
6 changed files with 44 additions and 15 deletions
|
@ -19,12 +19,15 @@ from ClassesIntranet.ModuleBase import ModuleBase
|
|||
class main(ModuleBase):
|
||||
def title(self):
|
||||
return "Factures"
|
||||
def category(self):
|
||||
return "Services"
|
||||
def icon(self):
|
||||
return "icon.png"
|
||||
|
||||
|
||||
_club = True
|
||||
|
||||
def index(self, message = '', error = ''):
|
||||
adh = cherrypy.session['LDAP'].search('uid=' + cherrypy.session['uid'])['adherent'][0]
|
||||
adh = cherrypy.session['LDAP'].getProprio(cherrypy.session['uid'])
|
||||
t = {}
|
||||
t['message'] = message
|
||||
t['error'] = error
|
||||
|
@ -62,7 +65,7 @@ class main(ModuleBase):
|
|||
index.exposed = True
|
||||
|
||||
def historique(self, page = 1, items_per_page = 20):
|
||||
adh = cherrypy.session['LDAP'].search('uid=' + cherrypy.session['uid'])['adherent'][0]
|
||||
adh = cherrypy.session['LDAP'].getProprio(cherrypy.session['uid'])
|
||||
|
||||
lst = [ x for x in adh.historique() if x.split(u' : ',1)[1].startswith(u'credit') or x.split(u' : ',1)[1].startswith(u'debit') ]
|
||||
histLst = []
|
||||
|
|
|
@ -29,12 +29,30 @@ import crans.impression
|
|||
import crans.impression.digicode
|
||||
import crans.impression.etat_imprimante
|
||||
import crans.cp
|
||||
from threading import Thread
|
||||
FILE_UPLOAD_BASE_FOLDER = cherrypy.config.get('fileUpload.folder', "/var/impression/fichiers/")
|
||||
|
||||
class FileError(Exception):
|
||||
pass
|
||||
from ClassesIntranet.ModuleBase import ModuleBase
|
||||
|
||||
|
||||
# #############################################################
|
||||
# Classe d'impression en multithread
|
||||
# #############################################################
|
||||
class threadedImpression(Thread, crans.impression.impression):
|
||||
def __init__(self, path_to_pdf, adh = None, callback = None):
|
||||
self.tpath_to_pdf = path_to_pdf
|
||||
self.tadh = adh
|
||||
Thread.__init__(self)
|
||||
|
||||
def run():
|
||||
crans.impression.impression.__init__(self, self.tpath_to_pdf, self.tadh)
|
||||
if self.tcallback:
|
||||
self.tcallback(self)
|
||||
|
||||
|
||||
|
||||
class main(ModuleBase):
|
||||
def category(self):
|
||||
return "Services"
|
||||
|
@ -136,7 +154,9 @@ class main(ModuleBase):
|
|||
crans.cp.log("useFile : %s" % str(e), 'IMPRESSION', 1)
|
||||
return {'erreur':str(e) }
|
||||
useFile.exposed= True
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
#
|
||||
# methode pour changer les parametres
|
||||
|
|
|
@ -1,4 +1,5 @@
|
|||
#if $message != ''
|
||||
#encoding UTF-8
|
||||
#if $getVar('message',False)
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
Crans.messages.setMessage('$message.replace("\'","\\\'")')
|
||||
|
@ -6,7 +7,7 @@ Crans.messages.setMessage('$message.replace("\'","\\\'")')
|
|||
</script>
|
||||
#end if
|
||||
|
||||
#if $error != ''
|
||||
#if $getVar('error',False)
|
||||
<script type="text/javascript">
|
||||
<!--
|
||||
Crans.messages.setMessage('$error.replace("\'","\\\'")', 'errorMessage')
|
||||
|
@ -51,7 +52,7 @@ Crans.messages.setMessage('$error.replace("\'","\\\'")', 'errorMessage')
|
|||
<dt>Solde :</dt>
|
||||
<dd>
|
||||
$adherent.solde €
|
||||
<span class="actions"><a href="rechargerCompteImpression" onclick="return paypalWindow('$adherent.telephone')">modifier</a></span>
|
||||
|
||||
<div class="clear"></div>
|
||||
</dd>
|
||||
<dt>Téléphone :</dt>
|
||||
|
@ -94,7 +95,8 @@ Crans.messages.setMessage('$error.replace("\'","\\\'")', 'errorMessage')
|
|||
<input type="password" id="ancienPassword" name="ancienPassword"/><br />
|
||||
<label class="textInputLabel" for="nouveauPassword1">Nouveau mot de passe : </label>
|
||||
<input type="password" id="nouveauPassword1" name="nouveauPassword1"/><br />
|
||||
<a class="textInputNote" href="#" onclick="return GeneratePassword()">Générer un nouveau mot de passe</a><br />
|
||||
<a class="textInputNote" href="#" onclick="return
|
||||
GeneratePassword()">Générer un nouveau mot de passe</a><br />
|
||||
<label class="textInputLabel" for="nouveauPassword2">Confirmation : </label>
|
||||
<input type="password" id="nouveauPassword2" name="nouveauPassword2"/><br />
|
||||
<input type="submit" value="Modifier" />
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue