[Scodoc-devel] [SVN] Scolar : [1284] - Modified logo and version;

eviennet at lipn.univ-paris13.fr eviennet at lipn.univ-paris13.fr
Mar 19 Nov 16:25:26 CET 2013


Une pièce jointe HTML a été nettoyée...
URL: <https://www-rt.iutv.univ-paris13.fr/pipermail/scodoc-devel/attachments/20131119/dd790de9/attachment-0001.html>
-------------- section suivante --------------
Modified: branches/ScoDoc7/VERSION.py
===================================================================
--- branches/ScoDoc7/VERSION.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/VERSION.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -1,14 +1,14 @@
 # -*- mode: python -*-
 # -*- coding: utf-8 -*-
 
-SCOVERSION = "7.0a2"
+SCOVERSION = "7.0a3"
 
 SCONAME = "ScoDoc"
 
 SCONEWS = """
 <h4>Année 2013</h4>
 <ul>
-<li>Modernisation de certains de composants logiciels</li>
+<li>Modernisation de nombreux composants logiciels (ScoDoc 7)</li>
 <li>Saisie des absences par matières</li>
 </ul>
 <h4>Année 2012</h4>

Modified: branches/ScoDoc7/ZEntreprises.py
===================================================================
--- branches/ScoDoc7/ZEntreprises.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/ZEntreprises.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -267,7 +267,7 @@
                 H.append('</ul></div>')
 
         #
-        H.append("""<br/><br/>%s""" % context.icons.entreprise_side_img.tag() )
+        H.append("""<br/><br/>%s""" % icontag('entreprise_side_img'))
         if REQUEST['_read_only']:
             H.append("""<br/><em>(Lecture seule)</em>""")
         H.append("""</div> </div> <!-- end of sidebar -->""")
@@ -555,7 +555,7 @@
                 args={ 'entreprise_id' : F['entreprise_id'] })
             Cts = self.do_entreprise_contact_list( args={ 'entreprise_id' : F['entreprise_id'] })
             if not readonly:
-                H.append("""<p>%s <a class="entreprise_delete" href="entreprise_delete?entreprise_id=%s">Supprimer cette entreprise</a> </p>""" % (self.icons.delete_img.tag(title='delete', border='0'), F['entreprise_id']))
+                H.append("""<p>%s <a class="entreprise_delete" href="entreprise_delete?entreprise_id=%s">Supprimer cette entreprise</a> </p>""" % (icontag('delete_img', title='delete', border='0'), F['entreprise_id']))
             if len(Cl):
                 H.append("""<h3>%d correspondants dans l'entreprise %s (<a href="entreprise_correspondant_list?entreprise_id=%s">liste complète</a>) :</h3>
 <ul>""" % (len(Cl), F['nom'], F['entreprise_id']))

Modified: branches/ScoDoc7/ZNotes.py
===================================================================
--- branches/ScoDoc7/ZNotes.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/ZNotes.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -290,11 +290,10 @@
     security.declareProtected(ScoView, 'index_html')
     def index_html(self, REQUEST=None):
         "Page accueil formations"
-        sco_groups.checkLastIcon(self, REQUEST)
-        lockicon = self.icons.lock32_img.tag(title="Comporte des semestres verrouillés", border='0')
-        suppricon= self.icons.delete_small_img.tag(border='0', alt='supprimer', title='Supprimer')
-        editicon = self.icons.edit_img.tag(border='0', alt='modifier', title='Modifier titres et code')
-
+        lockicon = icontag('lock32_img', title="Comporte des semestres verrouillés", border='0')
+        suppricon= icontag('delete_small_img', border='0', alt='supprimer', title='Supprimer')
+        editicon = icontag('edit_img', border='0', alt='modifier', title='Modifier titres et code')
+        
         editable = REQUEST.AUTHENTICATED_USER.has_permission(ScoChangeFormation,self)
 
         H = [ self.sco_header(REQUEST, page_title="Programmes formations"),

Modified: branches/ScoDoc7/ZScoDoc.py
===================================================================
--- branches/ScoDoc7/ZScoDoc.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/ZScoDoc.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -421,7 +421,7 @@
               """</head><body>""",
               CUSTOM_HTML_HEADER_CNX,
               self._check_users_folder(REQUEST=REQUEST), # ensure setup is done
-              self._check_icons_folder(REQUEST=REQUEST) ]
+        ]
         if message:
             H.append('<div id="message">%s</div>' % message )
         
@@ -467,9 +467,9 @@
             H.append('<p><a href="%s/force_admin_authentication">Se connecter comme administrateur</a></p>' % REQUEST.BASE0)
 
         try:
-            img = self.icons.firefox_fr.tag(border='0')
+            img = icontag('firefox_fr', border='0')
         except:
-            img = '' # icons folder not yet available
+            img = '' # logo not available (?)
         H.append("""
 <div id="scodoc_attribution">
 <p><a href="%s">ScoDoc</a> est un logiciel libre de suivi de la scolarité des étudiants conçu par 
@@ -531,7 +531,7 @@
 <a href="http://www.mozilla-europe.org/fr/products/firefox/">%s</a>
 
 </div>
-""" % (deptfoldername, self.icons.firefox_fr.tag(border='0')),
+""" % (deptfoldername, icontag('firefox_fr', border='0')),
               self.standard_html_footer(self)]
         return '\n'.join(H)
 
@@ -822,14 +822,6 @@
 
 </form>""")
 
-        # Autres opérations
-        H.append("""<h4>Autres opérations</h4>
-<ul>
-<li><a href="build_icons_folder">Reconstruire les icônes</a></li>
-</ul>
-""")
-
-
         H.append("""</body></html>""")
         return '\n'.join(H)
 
@@ -841,60 +833,6 @@
         ids = [ os.path.split(os.path.splitext(f)[0])[1] for f in filenames ]
         return ids
     
-    def _check_icons_folder(self,REQUEST=None): # not published
-        """Vérifie icons folder Zope et le crée s'il le faut
-        XXX deprecated: on utilisera maintenant les images statiques via sco_utils.icontag()
-        """
-        try:
-            icons = self.icons
-            plus = self.icons.plus_img # upgrade jul 2008
-            arrow_up = self.icons.arrow_up # nov 2009
-            return '<!-- icons ok -->'
-        except:
-            e = self._check_admin_perm(REQUEST)
-            if not e: # admin permissions:
-                self.build_icons_folder(REQUEST)
-                return '<div class="head_message">Création du dossier icons réussie</div>'
-            else:
-                return """<div class="head_message">Installation non terminée: connectez vous avec les droits d'administrateur</div>"""
-
-    security.declareProtected('View', 'build_icons_folder')
-    def build_icons_folder(self,REQUEST=None): 
-        """Build folder with Zope images
-        """
-        e = self._check_admin_perm(REQUEST)
-        if e:
-            return e
-        return self.do_build_icons_folder(REQUEST=REQUEST)
-    
-    security.declareProtected('View', 'do_build_icons_folder')
-    def do_build_icons_folder(self,REQUEST=None): # not published
-        # Build folder with Zope images
-        id = 'icons'
-        try:
-            o = self[id]
-            exists = True
-        except:
-            exists = False
-        # If folder exists, destroy it !
-        if exists:
-            log('build_image_folder: destroying existing folder !')
-            self.manage_delObjects(ids=[ id ])
-        # Create Zope folder
-        log('build_image_folder: building new %s folder' % id )
-        self.manage_addProduct['OFSP'].manage_addFolder(id, title='ScoDoc icons')
-        folder = self[id]
-        # Create Zope images instances for each file in .../static/icons/*
-        path = self.file_path + '/static/icons/'
-        add_method = folder.manage_addProduct['OFSP'].manage_addImage
-        for filename in os.listdir(path):
-            if filename != '.svn':
-                iid = os.path.splitext(filename)[0]
-                log('adding image %s as %s' % (filename,iid))
-                add_method( iid, open(path+'/'+filename) )
-        
-        return 'ok'
-
     security.declareProtected('View', 'http_expiration_date')
     def http_expiration_date(self):
         "http expiration date for cachable elements (css, ...)"

Modified: branches/ScoDoc7/ZScolar.py
===================================================================
--- branches/ScoDoc7/ZScolar.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/ZScolar.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -378,7 +378,7 @@
         """ % (SCOVERSION, get_svn_version(file_path)) ]
         H.append('<p>Logiciel libre écrit en <a href="http://www.python.org">Python</a>.</p><p>Utilise <a href="http://www.reportlab.org/">ReportLab</a> pour générer les documents PDF, et <a href="http://sourceforge.net/projects/pyexcelerator">pyExcelerator</a> pour le traitement des documents Excel.</p>')
         H.append( "<h2>Dernières évolutions</h2>" + SCONEWS )
-        H.append( '<div class="about-logo">' + self.icons.borgne_img.tag() + ' <em>Au pays des aveugles...</em></div>' )
+        H.append( '<div class="about-logo">' + icontag('borgne_img') + ' <em>Au pays des aveugles...</em></div>' )
         d = ''
         # debug
         #import locale
@@ -572,7 +572,7 @@
         H = []
 
         # News:
-        rssicon = self.icons.rssicon_img.tag(title='Flux RSS', border='0') 
+        rssicon = icontag('rssicon_img', title='Flux RSS', border='0') 
         H.append( sco_news.scolar_news_summary_html(self, rssicon=rssicon) )
 
         # Avertissement de mise à jour:
@@ -585,11 +585,9 @@
         cursems = []   # semestres "courants"
         othersems = [] # autres (verrouillés)
         # icon image:
-        groupicon = self.icons.groupicon_img.tag(title="Inscrits",
-                                               border='0') 
-        emptygroupicon = self.icons.emptygroupicon_img.tag(title="Pas d'inscrits",
-                                                           border='0')
-        lockicon = self.icons.lock32_img.tag(title="verrouillé", border='0')
+        groupicon = icontag('groupicon_img', title="Inscrits", border='0') 
+        emptygroupicon = icontag('emptygroupicon_img', title="Pas d'inscrits", border='0')
+        lockicon = icontag('lock32_img', title="verrouillé", border='0')
         # selection sur l'etat du semestre
         for sem in sems:
             if sem['etat'] == '1':

Modified: branches/ScoDoc7/html_sidebar.py
===================================================================
--- branches/ScoDoc7/html_sidebar.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/html_sidebar.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -76,10 +76,10 @@
     H = [ '<div class="sidebar">',
           sidebar_common(context, REQUEST) ]
     
-    H.append("""Chercher étudiant:<br/>
+    H.append("""<div class="box-chercheetud">Chercher étudiant:<br/>
 <form action="%(ScoURL)s/chercheEtud">
 <div><input type="text" size="12" name="expnom"></input></div>
-</form>
+</form></div>
 <div class="etud-insidebar">
 """ % params )
     # ---- s'il y a un etudiant selectionné:
@@ -121,7 +121,7 @@
     # ---------
     H.append('</div><br/> ') # /etud-insidebar
     # Logo
-    scologo_img = context.icons.scologo_img.tag()
+    scologo_img = icontag('scologo_img')
     H.append('<div class="logo-insidebar">%s<br/>' % scologo_img)
     H.append("""<a href="%(ScoURL)s/about" class="sidebar">A propos</a><br/>
 <a href="%(SCO_WEBSITE)s" class="sidebar">Aide</a><br/>

Modified: branches/ScoDoc7/sco_bulletins_legacy.py
===================================================================
--- branches/ScoDoc7/sco_bulletins_legacy.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_bulletins_legacy.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -88,8 +88,8 @@
             bgcolor = 'background-color: rgb(255,255,240)'
         
         linktmpl  = '<span onclick="toggle_vis_ue(this);" class="toggle_ue">%s</span>'
-        minuslink = linktmpl % context.icons.minus_img.tag(border="0", alt="-")
-        pluslink  = linktmpl % context.icons.plus_img.tag(border="0", alt="+")
+        minuslink = linktmpl % icontag('minus_img', border="0", alt="-")
+        pluslink  = linktmpl % icontag('plus_img', border="0", alt="+")
 
         H = [ '<table class="notes_bulletin" style="background-color: %s;">' % bgcolor  ]
 

Modified: branches/ScoDoc7/sco_bulletins_standard.py
===================================================================
--- branches/ScoDoc7/sco_bulletins_standard.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_bulletins_standard.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -243,8 +243,8 @@
                       'coef' : 1.5*cm, 'abs' : 2.0*cm }
         # HTML specific
         linktmpl  = '<span onclick="toggle_vis_ue(this);" class="toggle_ue">%s</span> '
-        minuslink = linktmpl % context.icons.minus_img.tag(border="0", alt="-")
-        pluslink  = linktmpl % context.icons.plus_img.tag(border="0", alt="+")
+        minuslink = linktmpl % icontag('minus_img', border="0", alt="-")
+        pluslink  = linktmpl % icontag('plus_img', border="0", alt="+")
 
         # 1er ligne titres
         t = { 'min': 'Promotion', 'max' : '', 'rang' : 'Rang',

Modified: branches/ScoDoc7/sco_formsemestre_edit.py
===================================================================
--- branches/ScoDoc7/sco_formsemestre_edit.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_formsemestre_edit.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -69,7 +69,7 @@
                                   ) ]
     if sem['etat'] != '1':
         H.append("""<p>%s<b>Ce semestre est verrouillé.</b></p>""" %
-                 context.icons.lock_img.tag(border='0',title='Semestre verrouillé'))
+                 icontag('lock_img', border='0', title='Semestre verrouillé'))
     else:
         H.append(do_formsemestre_createwithmodules(context, REQUEST=REQUEST, edit=1 ))
         if not REQUEST.get('tf-submitted',False):

Modified: branches/ScoDoc7/sco_formsemestre_status.py
===================================================================
--- branches/ScoDoc7/sco_formsemestre_status.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_formsemestre_status.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -370,7 +370,7 @@
     sem['notes_url'] = notes_url
     formsemestre_id = sem['formsemestre_id']
     if sem['etat'] != '1':
-        sem['locklink'] = """<a href="%s/formsemestre_change_lock?formsemestre_id=%s">%s</a>""" % (notes_url, sem['formsemestre_id'], context.icons.lock_img.tag(border='0',title='Semestre verrouillé'))
+        sem['locklink'] = """<a href="%s/formsemestre_change_lock?formsemestre_id=%s">%s</a>""" % (notes_url, sem['formsemestre_id'], icontag('lock_img', border='0', title='Semestre verrouillé'))
     else:
         sem['locklink'] = ''
     F = context.Notes.formation_list( args={ 'formation_id' : sem['formation_id'] } )[0]

Modified: branches/ScoDoc7/sco_formsemestre_validation.py
===================================================================
--- branches/ScoDoc7/sco_formsemestre_validation.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_formsemestre_validation.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -371,8 +371,8 @@
     """
     H = []
     linktmpl  = '<span onclick="toggle_vis(this);" class="toggle_sem">%s</span>'
-    minuslink = linktmpl % context.icons.minus_img.tag(border="0", alt="-")
-    pluslink  = linktmpl % context.icons.plus_img.tag(border="0", alt="+")
+    minuslink = linktmpl % icontag('minus_img', border="0", alt="-")
+    pluslink  = linktmpl % icontag('plus_img', border="0", alt="+")
     if show_details:
         sd = ' recap_show_details'
         plusminus = minuslink
@@ -460,7 +460,7 @@
         else:
             default_sem_info = ''
         if sem['etat'] != '1': # locked
-            lockicon = context.icons.lock32_img.tag(title="verrouillé", border='0')
+            lockicon = icontag('lock32_img', title="verrouillé", border='0')
             default_sem_info += lockicon
         H.append('<td class="datefin">%s</td><td class="sem_info">%s</td>'
                  % (sem['mois_fin'], 

Modified: branches/ScoDoc7/sco_groups.py
===================================================================
--- branches/ScoDoc7/sco_groups.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_groups.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -541,20 +541,9 @@
     else:
         return partition_id 
 
-def checkLastIcon(context, REQUEST):
-    """Check that most recent icon is installed.
-    If not, rebuild icons in Zope.
-    XXX now unnecessary (was for Zope icons), we now use icontag() from sco_utils.py
-    """
-    try: 
-        a = context.icons.delete_small_img
-    except:
-        context.do_build_icons_folder(REQUEST)
 
 def getArrowIconsTags(context, REQUEST):
     """returns html tags for arrows"""
-    # check that we have new icons:
-    checkLastIcon(context,REQUEST)
     #
     arrow_up   = icontag('arrow_up', title='remonter')
     arrow_down = icontag('arrow_down', title='descendre')
@@ -568,7 +557,7 @@
     canedit = context.Notes.can_change_groups(REQUEST, formsemestre_id)
     partitions = get_partitions_list(context, formsemestre_id)
     arrow_up, arrow_down, arrow_none = getArrowIconsTags(context, REQUEST)
-    suppricon= context.icons.delete_small_img.tag(border='0', alt='supprimer', title='Supprimer')
+    suppricon= icontag('delete_small_img', border='0', alt='supprimer', title='Supprimer')
     #
     H = [ context.sco_header(REQUEST, page_title="Partitions...",
                              init_jquery_ui=True,

Modified: branches/ScoDoc7/sco_page_etud.py
===================================================================
--- branches/ScoDoc7/sco_page_etud.py	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/sco_page_etud.py	2013-11-19 15:25:26 UTC (rev 1284)
@@ -50,7 +50,7 @@
     """
     locked = (sem['etat'] != '1')
     if locked: 
-        lockicon = context.icons.lock32_img.tag(title="verrouillé", border='0')
+        lockicon = icontag('lock32_img', title="verrouillé", border='0')
         return lockicon # no menu
     if not authuser.has_permission(ScoEtudInscrit,context) and not authuser.has_permission(ScoEtudChangeGroups,context):
         return '' # no menu
@@ -198,7 +198,7 @@
         if not context.canSuppressAnnotation(a['id'], REQUEST):
             a['dellink'] = ''
         else:
-            a['dellink'] = '<td bgcolor="%s" class="annodel"><a href="doSuppressAnnotation?etudid=%s&annotation_id=%s">%s</a></td>' % (a['bgcolor'], etudid, a['id'], context.icons.delete_img.tag(border="0", alt="suppress", title="Supprimer cette annotation"))
+            a['dellink'] = '<td bgcolor="%s" class="annodel"><a href="doSuppressAnnotation?etudid=%s&annotation_id=%s">%s</a></td>' % (a['bgcolor'], etudid, a['id'], icontag('delete_img', border="0", alt="suppress", title="Supprimer cette annotation"))
         alist.append('<tr><td bgcolor="%(bgcolor)s">Le %(date)s par <b>%(author)s</b> (%(zope_authenticated_user)s) :<br/>%(comment)s</td>%(dellink)s</tr>' % a )
     info['liste_annotations'] = '\n'.join(alist)
     # fiche admission

Modified: branches/ScoDoc7/static/css/scodoc.css
===================================================================
--- branches/ScoDoc7/static/css/scodoc.css	2013-11-19 13:01:36 UTC (rev 1283)
+++ branches/ScoDoc7/static/css/scodoc.css	2013-11-19 15:25:26 UTC (rev 1284)
@@ -6,7 +6,9 @@
   margin:0;
   padding:0;
   width: 100%;
-  background-color: rgb(238,238,255);
+  background-color: rgb(242,242,238);
+  font-family: "Times New Roman", Times, serif;
+  font-size: 12pt;
 }
 
 a:link { color:  #008080 }
@@ -116,6 +118,7 @@
   width: 130px;
   border: black 1px;
   /* debug background-color: rgb(245,245,245); */
+   border-right: 1px solid rgb(210,210,210);
 }
 @media print {
 div.sidebar {
@@ -123,11 +126,11 @@
 }
 }
 a.sidebar:link { 
-  color:#358;
+  color: rgb(4,16,159);
   text-decoration:none;
 } 
 a.sidebar:visited { 
-   color: #358; 
+   color: rgb(4,16,159);
    text-decoration: none;
 }
 a.sidebar:hover {
@@ -163,6 +166,9 @@
   list-style: circle;
 }
 
+div.box-chercheetud {
+  margin-top: 12px;
+}
 
 .etud-insidebar {
    font-size: small;
@@ -185,7 +191,7 @@
 }
 
 div.logo-insidebar {
-   padding-left: 1em;
+   padding-left: 0;
 }
 
 div.etud_info_div {
@@ -240,6 +246,7 @@
 }
 
 h2.listesems { 
+  padding-top: 10px;
   padding-bottom: 0px;
   margin-bottom: 0px;
 }
@@ -247,19 +254,20 @@
 /* ----- Liste des news ----- */
 
 div.news {
+   font-family :  "Helvetica Neue",Helvetica,Arial,sans-serif;
+   font-size: 10pt;
    margin-top: 1em;
    margin-bottom: 0px;
    margin-right: 16px;
    margin-left: 16px;
    padding:  0.5em;
-   background-color: #ffff93;
+   background-color: rgb(255,235,170);
    -moz-border-radius: 8px;
    -khtml-border-radius: 8px;
    border-radius: 8px;
 }
 
 span.newstitle {
-   font-family : arial, verdana, sans-serif ;
    font-weight: bold;
 }
 
@@ -271,10 +279,11 @@
 
 span.newsdate {
   padding-right: 2em;
+  font-family : monospace;
 }
 
 span.newstext {
-    font-style: italic; 
+    font-style: normal; 
 }
 
 /* --- infos sur premiere page Sco --- */

Modified: branches/ScoDoc7/static/icons/scologo_img.png
===================================================================
(Binary files differ)


Plus d'informations sur la liste de diffusion Scodoc-devel