Changeset 541

Show
Ignore:
Timestamp:
2007-05-19 20:41:43 (2 years ago)
Author:
gaspard
Message:

[fix] lots of bug fixes related to looping redirects and complex zafu inclusions. Implemented '_edit' modes to update nodes with custom forms. Also added can='write', can='drive' test conditions

Files:

Legend:

Unmodified
Added
Removed
Modified
Copied
Moved
  • trunk/app/controllers/application.rb

    r537 r541  
    181181        end 
    182182        @skin_names = [@skin_name, @skin.keys].flatten.uniq 
    183          
    184183        @expire_with_ids = [] 
    185184         
     
    204203    # tested in MainControllerTest 
    205204    def get_template_text(opts) 
    206       return nil unless doc = find_template_document(opts) 
     205      return nil unless res = find_template_document(opts) 
     206      doc, url = *res 
    207207      @expire_with_ids << doc[:id] 
    208        
    209208      # FIXME: implement a link to set/remove 'dev' mode. 
    210209      # session[:dev] ? doc.version.text : doc.version(:pub).text 
    211       doc.version.text 
     210      return doc.version.text, url 
    212211    end 
    213212 
    214213    # TODO: implement 
    215214    def template_url_for_asset(opts) 
    216       return nil unless asset = find_template_document(opts) 
     215      return nil unless asset = (find_template_document(opts) || [])[0] 
    217216      if asset.public? && !current_site.authentication? 
    218217        # force the use of a cacheable path for the data, even when navigating in '/oo' 
     
    243242        skin_names << url.shift if url.size > 1 
    244243      end 
    245       document = nil 
     244      document = skin_name = nil 
    246245       
    247246      skin_names.uniq.each do |skin_name| 
     
    253252        break if document = secure(TextDocument) { TextDocument.find_by_path(path) } rescue nil 
    254253      end 
    255       document 
     254      return document ? [document, ([skin_name] + url).join('/')] : nil 
    256255    end 
    257256   
     
    303302    # Choose best language to display content. 
    304303    # 1. 'test.host/oo?lang=en' use 'lang', redirect without lang 
    305     # 2. 'test.host/oo' use session[:lang], do not redirect 
    306     # 3. 'test.host/fr' use the request prefix, do not redirect 
     304    # 2. 'test.host/oo' use session[:lang] 
     305    # 3. 'test.host/fr' use the request prefix 
    307306    # 4. 'test.host/'   use current session lang if any 
    308307    # 5. 'test.host/'   use HTTP_ACCEPT_LANGUAGE 
    309308    # 6. 'test.host/'   use default language 
    310309    def set_lang 
    311       new_lang = nil 
    312       if params[:lang] 
    313         new_lang = params[:lang] 
    314       elsif params[:prefix] == AUTHENTICATED_PREFIX 
    315         session[:lang] ||= visitor.lang    # ok 
    316       elsif current_site.lang_list.include?(params[:prefix]) 
    317         session[:lang] = params[:prefix] # ok 
    318       elsif session[:lang] 
    319         new_lang = session[:lang] 
    320       elsif choices = request.headers['HTTP_ACCEPT_LANGUAGE'] 
    321         choices = choices.split(',').sort {|a,b| (b.split(';q=')[1] || 1.0).to_f <=> (a.split(';q=')[1] || 1.0).to_f} 
    322         choices.each do |l| 
    323           l = l.split(';')[0].split('-')[0] 
    324           if current_site.lang_list.include?(l) 
    325             new_lang = l 
    326             break 
    327           end 
    328         end 
    329         new_lang ||= current_site[:default_lang] 
    330       else 
    331         new_lang = current_site[:default_lang] 
    332       end 
    333        
    334       if new_lang 
    335         if current_site.lang_list.include?(new_lang) 
    336           session[:lang] = new_lang 
    337         else 
    338           flash[:notice] = _("The requested language is not available.") 
    339           session[:lang] = current_site.lang_list.include?(request.headers['HTTP_ACCEPT_LANGUAGE']) ? request.headers['HTTP_ACCEPT_LANGUAGE'] : current_site[:default_lang] 
    340         end 
    341          
    342         # path is only used by nodes controller's show action 
    343         if (params[:controller] == 'nodes' && ['index', 'show'].include?(params[:action])) || params[:lang] 
    344           req = request.parameters 
    345           req.delete(:lang) 
    346           req[:prefix] = req[:prefix] ? (visitor.is_anon? ? session[:lang] : AUTHENTICATED_PREFIX) : nil 
    347           redirect_to req and return false 
    348         end 
    349       end 
     310      [ 
     311        params[:lang],  
     312        params[:prefix] == AUTHENTICATED_PREFIX ? nil : params[:prefix], 
     313        session[:lang], 
     314        (request.headers['HTTP_ACCEPT_LANGUAGE'] || '').split(',').sort {|a,b| (b.split(';q=')[1] || 1.0).to_f <=> (a.split(';q=')[1] || 1.0).to_f }.map {|l| l.split(';')[0].split('-')[0] } 
     315      ].compact.flatten.uniq.each do |l| 
     316        if current_site.lang_list.include?(l) 
     317          session[:lang] = l 
     318          break 
     319        end 
     320      end 
     321       
     322      session[:lang] ||= current_site[:default_lang] 
    350323       
    351324      visitor.lang = session[:lang] # FIXME: this should not be needed, use global GetText.get_locale... 
  • trunk/app/controllers/nodes_controller.rb

    r540 r541  
    1919=end 
    2020class NodesController < ApplicationController 
     21  before_filter :clean_url, :only   => [:index, :show] 
    2122  before_filter :find_node, :except => [:index, :not_found, :search, :attribute] 
    2223  layout :popup_layout,     :only   => [:edit ] 
     
    190191     
    191192    respond_to do |format| 
    192       format.html { redirect_to edit_version_url(:node_id => @node[:zip], :id=>(@node.v_number || 0)) } 
     193      format.html do 
     194        if params[:edit] == 'popup' 
     195          redirect_to edit_version_url(:node_id => @node[:zip], :id=>(@node.v_number || 0))  
     196        else 
     197          redirect_to zen_path(@node) 
     198        end 
     199      end 
    193200      format.js   { @flash = flash } 
    194201    end 
     
    312319   
    313320  protected 
     321    # Make sure the url is correct. Redirect if necessary. 
     322    def clean_url 
     323      case params[:action] 
     324      when 'index' 
     325        redirect_url = "/#{prefix}" if params[:prefix] != prefix || params[:lang] 
     326      when 'show' 
     327        redirect_url = if !params[:path] || params[:prefix] != prefix || params[:lang] 
     328          if params[:id] 
     329            zen_path(secure(Node) { Node.find_by_zip(params[:id]) }) 
     330          else 
     331            request.parameters.merge(:prefix => prefix).delete(:lang) 
     332          end 
     333        end  
     334      end 
     335 
     336      if redirect_url 
     337        redirect_to redirect_url 
     338        return false 
     339      end 
     340    end 
     341 
     342 
     343     
    314344    def find_node 
    315345      if path = params[:path] 
     
    329359        if params[:format] == '' || (params[:format] == 'html' && ( (zip != '' && @node.custom_base) || basepath != @node.basepath(true))) 
    330360          redirect_to zen_path(@node, :mode => params[:mode]) 
     361        elsif params[:mode] =~ /_edit/ && !@node.can_write? 
     362          redirect_to zen_path(@node) 
    331363        end 
    332364      elsif params[:id] 
  • trunk/app/models/comment.rb

    r513 r541  
    44belong to the user _anon_ (see #User) and must have the 'athor_name' field set. 
    55 
    6 If ZENA_ENV[:moderate_anonymous_comments] is set, all public comments are set to 'prop' and are not directly seen on the site. 
     6If anonymous is moderated (User#moderated?), all public comments are set to 'prop' and are not directly seen on the site. 
    77=end 
    88class Comment < ActiveRecord::Base 
  • trunk/app/models/node.rb

    r530 r541  
    462462  # Same as fullpath, but the path includes the root node. 
    463463  def rootpath 
    464     ZENA_ENV[:site_name] + (fullpath != "" ? "/#{fullpath}" : "") 
     464    visitor.site.name + (fullpath != "" ? "/#{fullpath}" : "") 
    465465  end 
    466466   
  • trunk/app/models/template.rb

    r478 r541  
    2626  end 
    2727   
    28   # Find the 
    29   # TODO: test 
    30   def sweep_cache 
    31     super 
    32     if self.kind_of?(Skin) 
    33       tmpl = "#{name}/any" 
    34     else 
    35       tmpl = "#{parent(:secure=>false)[:name]}/#{name}" 
    36     end 
    37     ZENA_ENV[:languages].each do |lang| 
    38       filepath = File.join(RAILS_ROOT,'app', 'views', 'templates', 'compiled') 
    39       filepath = "#{filepath}/#{tmpl}_#{lang}.rhtml" 
    40       if File.exist?(filepath) 
    41         File.delete(filepath) 
    42       end 
    43     end 
    44   end 
    45    
    4628  private 
    4729   
  • trunk/app/models/template_content.rb

    r537 r541  
    4242      self[:skin_name] = node.section.name 
    4343      self[:mode] = nil if self[:mode] == '' 
     44      self[:klass] = nil if self[:klass] == '' 
    4445    end 
    4546   
  • trunk/app/views/discussions/_form.rhtml

    r512 r541  
    1212  </div> 
    1313  <div class='lang'> 
    14     <%= select('discussion', 'lang', ZENA_ENV[:languages]) %> 
     14    <%= select('discussion', 'lang', visitor.site.lang_list) %> 
    1515  </div> 
    1616  <div class='action'> 
  • trunk/app/views/versions/edit.rhtml

    r517 r541  
    88<div class='tab'> 
    99  <% form_tag( node_path(@node[:zip]), :method => :put, :multipart => @node.kind_of?(Document), :id => 'node_form') do -%> 
    10   <%= hidden_field 'node', 'v_lang', :value=>@node.v_lang %> 
     10  <div class='hidden'> 
     11    <%= hidden_field 'node', 'v_lang', :value=>@node.v_lang %> 
     12    <input type='hidden' name='edit' value='popup'/> 
     13  </div> 
    1114  <div class='validate'> 
    1215    <div><input type="submit" onclick="$('loader').style.visibility = 'visible';" value='<%= _('validate') %>'/></div> 
  • trunk/db/init/base/skins/default/Node.html

    r540 r541  
    1515  </r:with> 
    1616  <r:with part='body/container/content/main'> 
    17     <div class='header'> 
    18       <h1 do='title' class='s30' status='true' actions='all'>this is the title</h1> 
    19       <div class='subtitle'> 
    20         <r:case> 
    21           <r:when test='[user_id] == [v_user_id]'> 
    22             <r:trans>posted by</r:trans> <b do='author' do='show' attr='fullname'>Super Man</b> 
    23           </r:when> 
    24           <r:else> 
    25             <r:trans>original by</r:trans> <b do='show' attr='fullname'>Platon</b> 
    26             <r:trans>modified by</r:trans> <b do='version' do='author' do='show' attr='fullname'>Socrate</b> 
    27           </r:else> 
    28         </r:case> 
    29       </div> 
    30     </div> 
     17    <r:include template='title.html'/> 
    3118     
    3219    <r:summary text=''/> 
  • trunk/db/init/base/skins/default/Project.html

    r540 r541  
    1313     
    1414    <r:home> 
    15       <div class='header'> 
    16         <h1 do='title' class='s30' status='true' actions='all'>this is the title</h1> 
    17         <div class='subtitle'> 
    18           <r:case> 
    19             <r:when test='[user_id] == [v_user_id]'> 
    20               <r:trans>posted by</r:trans> <b do='author' do='show' attr='fullname'>Super Man</b> 
    21             </r:when> 
    22             <r:else> 
    23               <r:trans>original by</r:trans> <b do='show' attr='fullname'>Platon</b> 
    24               <r:trans>modified by</r:trans> <b do='version' do='author' do='show' attr='fullname'>Socrate</b> 
    25             </r:else> 
    26           </r:case> 
    27         </div> 
    28       </div> 
    29  
     15      <r:include template='title.html'/> 
    3016      <r:summary text=''/> 
    3117      <r:text/> 
    3218      <r:else> 
    33         <h1 do='title' class='s30' status='true' actions='all'>this is the title</h1
     19        <r:include template='title.html'/
    3420      </r:else> 
    3521    </r:home> 
  • trunk/db/init/base/skins/default/layout.html

    r540 r541  
    2626    </div> 
    2727 
    28     <div id='nav_menu' do='node' name='menu' select='root'> 
    29       <ul do='pages'> 
     28    <div id='nav_menu' do='void' name='menu'> 
     29      <ul do='root' do='pages'> 
    3030        <li do='each'><r:link attr='name'/> 
    3131          <ul do='pages'> 
     
    3535      </ul> 
    3636    </div> 
    37     <div id='branding' do='link' name='branding' href='root'><img src='/img/logo.png' width='220' height='100'/></div> 
     37    <r:void name='branding'> 
     38      <div id='branding' do='root' do='link' href='root'><r:icon><r:img mode='full'/><r:else><img src='/img/logo.png' width='220' height='100' alt='logo'/></r:else></r:icon></div> 
     39    </r:void> 
    3840  </div> 
    3941 
  • trunk/lib/gettext_strings.rb

    r532 r541  
    6363     
    6464    N_('no result found')   # search template 
     65    N_('search results')    # search template 
    6566     
    6667    N_('btn_unplublish')    # version action 
  • trunk/lib/parser/lib/parser.rb

    r499 r541  
    1616       
    1717      if test = @strings[url] 
    18         test['src'] 
     18        return test['src'], url.split('_').join('/') 
    1919      else 
    2020        nil 
     
    7171      end 
    7272       
    73       text = helper.send(:get_template_text, :src=>url, :current_folder=>'') || "<span class='parser_error'>template '#{url}' not found</span>" 
     73      text, url = helper.send(:get_template_text, :src=>url, :current_folder=>'') || ["<span class='parser_error'>template '#{url}' not found</span>", url] 
    7474      url = "/#{url}" unless url[0..0] == '/' # has to be an absolute path 
    7575      return [text, url] 
     
    165165    expand_with(:preflight=>true) 
    166166    if @parts != {} 
    167       expand_with(:parts  => (@context[:parts] || {}).merge(@parts), :blocks => @included_blocks) 
     167      # first definitions in inclusion history have precedence 
     168      expand_with(:parts  => (@parts).merge(@context[:parts] || {}), :blocks => @included_blocks) 
    168169    else 
    169170      expand_with(:blocks => @included_blocks) 
     
    198199        return false if replacer.empty? 
    199200        replace_with(replacer) 
     201        @params[:name] = name # in case replaced again 
    200202      end 
    201203    end 
  • trunk/lib/parser/lib/rules/code_syntax.rb

    r540 r541  
    102102  def step 
    103103    if ztag = scan(/\A<\/?r:[^>]+>/)   
    104       ztag =~ /<(\/?)r:([^> ]+)([^>]*)(\/?)>/ 
     104      ztag =~ /<(\/?)r:([^> ]+)([^>]*?)(\/?)>/ 
    105105      start_group :tag, "<#{$1}r:" 
    106106      start_group :ztag, $2 
  • trunk/lib/parser/lib/rules/zafu.rb

    r540 r541  
    210210          eat $& 
    211211          if $1 != @end_tag 
    212             puts [@end_tag, $1].inspect 
    213212            # error bad closing ztag 
    214213            store "<span class='parser_error'>#{$&.gsub('<', '&lt;').gsub('>','&gt;')}</span>" 
  • trunk/lib/parser/lib/rules/zena.rb

    r540 r541  
    10821082      elsif lang = @params[:lang] 
    10831083        "#{node}.version.lang == #{lang.inspect}" 
     1084      elsif can  = @params[:can] 
     1085        # TODO: test 
     1086        case can 
     1087        when 'write' 
     1088          "#{node}.can_write?" 
     1089        when 'drive' 
     1090          "#{node}.can_drive?" 
     1091        end 
    10841092      elsif test = @params[:test] 
    10851093        value1, op, value2 = test.split(/\s+/) 
  • trunk/lib/parser/test/parser_test.rb

    r497 r541  
    3636  testfile :zafu, :zafu_asset, :zafu_insight, :zazen 
    3737  def test_single 
    38     do_test('zafu', 'ztag_same_name_as_tag') 
     38    do_test('zafu', 'include_replace_same') 
    3939  end 
    4040   
  • trunk/lib/parser/test/zafu.yml

    r540 r541  
    3333very_messy: 
    3434  src: "this <r: blah> </r:truc> whak" 
    35   res: "this <r: blah> <span class='parser_error'>&lt;/z:truc&gt;</span> whak" 
     35  res: "this <r: blah> <span class='parser_error'>&lt;/r:truc&gt;</span> whak" 
    3636 
    3737bad_closing_tag: 
    3838  src: "this <r:test>looks </r:truc> ok" 
    39   res: "this [test]looks <span class='parser_error'>&lt;/z:truc&gt;</span>[/test] ok" 
     39  res: "this [test]looks <span class='parser_error'>&lt;/r:truc&gt;</span>[/test] ok" 
    4040 
    4141do_tag: 
     
    214214 
    215215name_title: 
    216   src: "title: <h1 do='void' name='title' do='text' text='dummy'>blah</h1>" 
     216  src: "title: <h1 do='void' name='title' do='text' text='dummy'>blah <b do='void' name='comment'>nothing</b></h1>" 
    217217  res: "title: <h1>dummy</h1>" 
    218218 
     
    224224  src: "include_with: <r:include template='/name/title'><h1 do='with' part='title' do='hello'/></r:include>" 
    225225  res: "include_with: title: <h1>hello world!</h1>" 
     226 
     227include_with_keep_name: 
     228  src: "keep name: <r:include template='/name/title'><h1 do='with' part='title'><r:hello/> <i do='void' name='comment'>none</i></h1></r:include>" 
     229  res: "keep name: title: <h1>hello world! <i>none</i></h1>" 
     230   
     231include_include: 
     232  src: "from ii: <r:include template='/include/with/keep/name'><r:with part='title/comment'>rabbit</r:with></r:include>" 
     233  res: "from ii: keep name: title: <h1>hello world! <i>rabbit</i></h1>" 
     234 
     235include_for_reverse: 
     236  src: "from ifr: <r:include template='/name'><r:with part='super/comment'>IFR</r:with></r:include>" 
     237  res: "from ifr: super: hey ho" 
     238 
     239include_replace_same: 
     240  src: "from IRS: <r:include template='/include/super/man'><span do='with' part='super/man'>goldorak</span></r:include>" 
     241  res: "from IRS: include_super: super: hey <span>goldorak</span>" 
     242 
     243include_reverse: 
     244  src: "from ir: <r:include template='/include/for/reverse'><h1 do='with' part='super'><i do='void' name='comment'>none</i> <r:hello/></h1></r:include>" 
     245  res: "from ir: from ifr: super: <h1><i>IFR</i> hello world!</h1>" 
    226246 
    227247include_empty: 
  • trunk/po/en/zena.po

    r532 r541  
    22msgstr "" 
    33"Project-Id-Version: 0.8.2\n" 
    4 "POT-Creation-Date: 2007-05-18 12:26-0000\n" 
     4"POT-Creation-Date: 2007-05-19 18:28-0000\n" 
    55"PO-Revision-Date: 2007-05-14 15:18+0100\n" 
    66"Last-Translator: Gaspard Bucher <gaspard@teti.ch>\n" 
     
    1414"X-Poedit-Basepath: /Users/gaspard/svk/zena\n" 
    1515 
    16 #: app/controllers/application.rb:277 
     16#: app/controllers/application.rb:285 
    1717msgid "Please log in" 
    1818msgstr "Please log in." 
    1919 
    20 #: app/controllers/application.rb:329 
    21 msgid "The requested language is not available." 
    22 msgstr "" 
    23  
    24 #: app/controllers/application.rb:356 app/controllers/application.rb:384 
     20#: app/controllers/application.rb:338 app/controllers/application.rb:366 
    2521msgid "datetime" 
    2622msgstr "%Y-%m-%d %H:%M" 
     
    3834msgstr "Invalid role." 
    3935 
    40 #: app/controllers/nodes_controller.rb:150 
     36#: app/controllers/nodes_controller.rb:152 
    4137msgid "Backup created." 
    4238msgstr "" 
    4339 
    44 #: app/controllers/nodes_controller.rb:152 
     40#: app/controllers/nodes_controller.rb:154 
    4541msgid "Could not create backup." 
    4642msgstr "" 
    4743 
    48 #: app/controllers/nodes_controller.rb:185 
     44#: app/controllers/nodes_controller.rb:187 
    4945msgid "node updated" 
    5046msgstr "Node successfully updated." 
    5147 
    52 #: app/controllers/nodes_controller.rb:187 
     48#: app/controllers/nodes_controller.rb:189 
    5349msgid "could not update" 
    5450msgstr "The node could not be updated." 
    5551 
    56 #: app/controllers/nodes_controller.rb:280 
     52#: app/controllers/nodes_controller.rb:288 
    5753msgid "node not found" 
    5854msgstr "Node not found." 
    5955 
    60 #: app/controllers/nodes_controller.rb:304 
     56#: app/controllers/nodes_controller.rb:312 
    6157msgid "Order updated" 
    6258msgstr "Order updated." 
    6359 
    64 #: app/controllers/nodes_controller.rb:306 
     60#: app/controllers/nodes_controller.rb:314 
    6561msgid "Could not update order." 
    6662msgstr "" 
     
    9591msgstr "" 
    9692 
    97 #: app/controllers/versions_controller.rb:123 
     93#: app/controllers/versions_controller.rb:124 
    9894msgid "Redaction proposed for publication." 
    9995msgstr "" 
    10096 
    101 #: app/controllers/versions_controller.rb:125 
     97#: app/controllers/versions_controller.rb:126 
    10298msgid "Could not propose redaction." 
    10399msgstr "" 
    104100 
    105 #: app/controllers/versions_controller.rb:132 
     101#: app/controllers/versions_controller.rb:133 
    106102msgid "Proposition refused." 
    107103msgstr "" 
    108104 
    109 #: app/controllers/versions_controller.rb:135 
     105#: app/controllers/versions_controller.rb:136 
    110106msgid "Could not refuse proposition." 
    111107msgstr "" 
     
    669665#: app/views/templates/document_create_tabs/_template.rhtml:3 
    670666#: app/views/templates/document_create_tabs/_text_doc.rhtml:3 
    671 #: app/views/users/_form.rhtml:45 app/views/versions/edit.rhtml:12 
     667#: app/views/users/_form.rhtml:45 app/views/versions/edit.rhtml:15 
    672668msgid "validate" 
    673669msgstr " validate " 
     
    965961msgstr "" 
    966962 
    967 #: app/views/versions/edit.rhtml:13 
     963#: app/views/versions/edit.rhtml:16 
    968964msgid "save" 
    969965msgstr " save " 
    970966 
    971 #: app/views/versions/edit.rhtml:17 
     967#: app/views/versions/edit.rhtml:20 
    972968msgid "btn_add_document" 
    973969msgstr "<img src='/images/picture_add.png' alt='add documents'/>" 
     
    11871183msgstr "Node not found." 
    11881184 
    1189 #: lib/gettext_strings.rb:66 
     1185#: lib/gettext_strings.rb:65 
     1186msgid "search results" 
     1187msgstr "" 
     1188 
     1189#: lib/gettext_strings.rb:67 
    11901190#, fuzzy 
    11911191msgid "btn_unplublish" 
    11921192msgstr "<img src='/images/wand.png' alt='publish'/>" 
    11931193 
    1194 #: lib/gettext_strings.rb:68 
     1194#: lib/gettext_strings.rb:69 
    11951195msgid "status_50" 
    11961196msgstr "" 
    11971197 
    1198 #: lib/gettext_strings.rb:69 
     1198#: lib/gettext_strings.rb:70 
    11991199msgid "status_40" 
    12001200msgstr "" 
    12011201 
    1202 #: lib/gettext_strings.rb:70 
     1202#: lib/gettext_strings.rb:71 
    12031203msgid "status_35" 
    12041204msgstr "" 
    12051205 
    1206 #: lib/gettext_strings.rb:71 
     1206#: lib/gettext_strings.rb:72 
    12071207msgid "status_33" 
    12081208msgstr "" 
    12091209 
    1210 #: lib/gettext_strings.rb:72 
     1210#: lib/gettext_strings.rb:73 
    12111211msgid "status_30" 
    12121212msgstr "" 
    12131213 
    1214 #: lib/gettext_strings.rb:73 
     1214#: lib/gettext_strings.rb:74 
    12151215msgid "status_20" 
    12161216msgstr "" 
    12171217 
    1218 #: lib/gettext_strings.rb:74 
     1218#: lib/gettext_strings.rb:75 
    12191219msgid "status_10" 
    12201220msgstr "" 
    12211221 
    1222 #: lib/gettext_strings.rb:75 
     1222#: lib/gettext_strings.rb:76 
    12231223msgid "status_0" 
    12241224msgstr "" 
    12251225 
    1226 #: lib/gettext_strings.rb:77 
     1226#: lib/gettext_strings.rb:78 
    12271227msgid "en" 
    12281228msgstr "" 
    12291229 
    1230 #: lib/gettext_strings.rb:78 
     1230#: lib/gettext_strings.rb:79 
    12311231msgid "fr" 
    12321232msgstr "" 
    12331233 
    1234 #: lib/gettext_strings.rb:79 
     1234#: lib/gettext_strings.rb:80 
    12351235msgid "de" 
    12361236msgstr "" 
    12371237 
    1238 #: lib/gettext_strings.rb:80 
     1238#: lib/gettext_strings.rb:81 
    12391239msgid "Monday" 
    12401240msgstr "" 
    12411241 
    1242 #: lib/gettext_strings.rb:81 
     1242#: lib/gettext_strings.rb:82 
    12431243msgid "Tuesday" 
    12441244msgstr "" 
    12451245 
    1246 #: lib/gettext_strings.rb:82 
     1246#: lib/gettext_strings.rb:83 
    12471247msgid "Wednesday" 
    12481248msgstr "" 
    12491249 
    1250 #: lib/gettext_strings.rb:83 
     1250#: lib/gettext_strings.rb:84 
    12511251msgid "Thursday" 
    12521252msgstr "" 
    12531253 
    1254 #: lib/gettext_strings.rb:84 
     1254#: lib/gettext_strings.rb:85 
    12551255msgid "Friday" 
    12561256msgstr "" 
    12571257 
    1258 #: lib/gettext_strings.rb:85 
     1258#: lib/gettext_strings.rb:86 
    12591259msgid "Saturday" 
    12601260msgstr "" 
    12611261 
    1262 #: lib/gettext_strings.rb:86 
     1262#: lib/gettext_strings.rb:87 
    12631263msgid "Sunday" 
    12641264msgstr "" 
    12651265 
    1266 #: lib/gettext_strings.rb:88 
     1266#: lib/gettext_strings.rb:89 
    12671267msgid "mon" 
    12681268msgstr "" 
    12691269 
    1270 #: lib/gettext_strings.rb:89 
     1270#: lib/gettext_strings.rb:90 
    12711271msgid "tue" 
    12721272msgstr "" 
    12731273 
    1274 #: lib/gettext_strings.rb:90 
     1274#: lib/gettext_strings.rb:91 
    12751275msgid "wed" 
    12761276msgstr "" 
    12771277 
    1278 #: lib/gettext_strings.rb:91 
     1278#: lib/gettext_strings.rb:92 
    12791279msgid "thu" 
    12801280msgstr "" 
    12811281 
    1282 #: lib/gettext_strings.rb:92 
     1282#: lib/gettext_strings.rb:93 
    12831283msgid "fri" 
    12841284msgstr "" 
    12851285 
    1286 #: lib/gettext_strings.rb:93 
     1286#: lib/gettext_strings.rb:94 
    12871287msgid "sat" 
    12881288msgstr "" 
    12891289 
    1290 #: lib/gettext_strings.rb:94 
     1290#: lib/gettext_strings.rb:95 
    12911291msgid "sun" 
    12921292msgstr "" 
    12931293 
    1294 #: lib/gettext_strings.rb:96 
     1294#: lib/gettext_strings.rb:97 
    12951295msgid "January" 
    12961296msgstr "" 
    12971297 
    1298 #: lib/gettext_strings.rb:97 
     1298#: lib/gettext_strings.rb:98 
    12991299msgid "February" 
    13001300msgstr "" 
    13011301 
    1302 #: lib/gettext_strings.rb:98 
     1302#: lib/gettext_strings.rb:99 
    13031303msgid "March" 
    13041304msgstr "" 
    13051305 
    1306 #: lib/gettext_strings.rb:99 
     1306#: lib/gettext_strings.rb:100 
    13071307msgid "April" 
    13081308msgstr "" 
    13091309 
    1310 #: lib/gettext_strings.rb:100 
     1310#: lib/gettext_strings.rb:101 
    13111311msgid "May" 
    13121312msgstr "" 
    13131313 
    1314 #: lib/gettext_strings.rb:101 
     1314#: lib/gettext_strings.rb:102 
    13151315msgid "June" 
    13161316msgstr "" 
    13171317 
    1318 #: lib/gettext_strings.rb:102 
     1318#: lib/gettext_strings.rb:103 
    13191319msgid "July" 
    13201320msgstr "" 
    13211321 
    1322 #: lib/gettext_strings.rb:103 
     1322#: lib/gettext_strings.rb:104 
    13231323msgid "August" 
    13241324msgstr "" 
    13251325 
    1326 #: lib/gettext_strings.rb:104 
     1326#: lib/gettext_strings.rb:105 
    13271327msgid "September" 
    13281328msgstr "" 
    13291329 
    1330 #: lib/gettext_strings.rb:105 
     1330#: lib/gettext_strings.rb:106 
    13311331msgid "October" 
    13321332msgstr "" 
    13331333 
    1334 #: lib/gettext_strings.rb:106 
     1334#: lib/gettext_strings.rb:107 
    13351335msgid "November" 
    13361336msgstr "" 
    13371337 
    1338 #: lib/gettext_strings.rb:107 
     1338#: lib/gettext_strings.rb:108 
    13391339msgid "December" 
    13401340msgstr "" 
    13411341 
    1342 #: lib/gettext_strings.rb:109 
     1342#: lib/gettext_strings.rb:110 
    13431343msgid "User name:" 
    13441344msgstr "" 
    13451345 
    1346 #: lib/gettext_strings.rb:110 
     1346#: lib/gettext_strings.rb:111 
    13471347msgid "Password:" 
    13481348msgstr "" 
    13491349 
    1350 #: lib/gettext_strings.rb:113 
     1350#: lib/gettext_strings.rb:114 
    13511351msgid "you are editing the original" 
    13521352msgstr "" 
    13531353 
    1354 #: lib/gettext_strings.rb:114 
     1354#: lib/gettext_strings.rb:115 
    13551355msgid "redaction saved" 
    13561356msgstr "" 
  • trunk/po/fr/zena.po

    r532 r541  
    22msgstr "" 
    33"Project-Id-Version: 0.8.2\n" 
    4 "POT-Creation-Date: 2007-05-18 12:26-0000\n" 
    5 "PO-Revision-Date: 2007-05-18 14:28+0100\n" 
     4"POT-Creation-Date: 2007-05-19 18:28-0000\n" 
     5"PO-Revision-Date: 2007-05-19 20:37+0100\n" 
    66"Last-Translator: Gaspard Bucher <gaspard@teti.ch>\n" 
    77"Language-Team: fr <gaspard@teti.ch>\n" 
     
    1414"X-Poedit-Basepath: /Users/gaspard/svk/zena\n" 
    1515 
    16 #: app/controllers/application.rb:277 
     16#: app/controllers/application.rb:285 
    1717msgid "Please log in" 
    1818msgstr "Veuillez vous authentifier." 
    1919 
    20 #: app/controllers/application.rb:329 
    21 msgid "The requested language is not available." 
    22 msgstr "La langue demandée n'est pas disponible." 
    23  
    24 #: app/controllers/application.rb:356 
    25 #: app/controllers/application.rb:384 
     20#: app/controllers/application.rb:338 
     21#: app/controllers/application.rb:366 
    2622msgid "datetime" 
    2723msgstr "%d.%m.%Y %H:%M" 
     
    3935msgstr "Role non-valable." 
    4036 
    41 #: app/controllers/nodes_controller.rb:150 
     37#: app/controllers/nodes_controller.rb:152 
    4238msgid "Backup created." 
    4339msgstr "Copie de sauvegarde effectuée." 
    4440 
    45 #: app/controllers/nodes_controller.rb:152 
     41#: app/controllers/nodes_controller.rb:154 
    4642msgid "Could not create backup." 
    4743msgstr "La sauvegarde n'a pas pu être créée." 
    4844 
    49 #: app/controllers/nodes_controller.rb:185 
     45#: app/controllers/nodes_controller.rb:187 
    5046msgid "node updated" 
    5147msgstr "Objet mis à jour." 
    5248 
    53 #: app/controllers/nodes_controller.rb:187 
     49#: app/controllers/nodes_controller.rb:189 
    5450msgid "could not update" 
    5551msgstr "L'objet n'a pas pu être mis à jour." 
    5652 
    57 #: app/controllers/nodes_controller.rb:280 
     53#: app/controllers/nodes_controller.rb:288 
    5854msgid "node not found" 
    5955msgstr "objet non trouvé" 
    6056 
    61 #: app/controllers/nodes_controller.rb:304 
     57#: app/controllers/nodes_controller.rb:312 
    6258msgid "Order updated" 
    6359msgstr "Ordre mis à jour." 
    6460 
    65 #: app/controllers/nodes_controller.rb:306 
     61#: app/controllers/nodes_controller.rb:314 
    6662msgid "Could not update order." 
    6763msgstr "L'ordre n'a pas pu être mis à jour." 
     
    9692msgstr "La version n'a pas pu être éditée." 
    9793 
    98 #: app/controllers/versions_controller.rb:123 
     94#: app/controllers/versions_controller.rb:124 
    9995msgid "Redaction proposed for publication." 
    10096msgstr "La rédaction a été proposée pour la publication." 
    10197 
    102 #: app/controllers/versions_controller.rb:125 
     98#: app/controllers/versions_controller.rb:126 
    10399msgid "Could not propose redaction." 
    104100msgstr "La rédaction n'a pas pu être proposée pour la publication." 
    105101 
    106 #: app/controllers/versions_controller.rb:132 
     102#: app/controllers/versions_controller.rb:133 
    107103msgid "Proposition refused." 
    108104msgstr "La proposition a été refusée." 
    109105 
    110 #: app/controllers/versions_controller.rb:135 
     106#: app/controllers/versions_controller.rb:136 
    111107msgid "Could not refuse proposition." 
    112108msgstr "La proposition n'a pas pu être refusée." 
     
    751747#: app/views/templates/document_create_tabs/_text_doc.rhtml:3 
    752748#: app/views/users/_form.rhtml:45 
    753 #: app/views/versions/edit.rhtml:12 
     749#: app/views/versions/edit.rhtml:15 
    754750msgid "validate" 
    755751msgstr " valider " 
     
    10541050msgstr "choisir les versions et visualiser les changements" 
    10551051 
    1056 #: app/views/versions/edit.rhtml:13 
     1052#: app/views/versions/edit.rhtml:16 
    10571053msgid "save" 
    10581054msgstr " enregistrer " 
    10591055 
    1060 #: app/views/versions/edit.rhtml:17 
     1056#: app/views/versions/edit.rhtml:20 
    10611057msgid "btn_add_document" 
    10621058msgstr "<img src='/images/picture_add.png' alt='ajouter des documents'/>" 
     
    12111207 
    12121208#: lib/gettext_strings.rb:51 
    1213 #, fuzzy 
    12141209msgid "original by" 
    1215 msgstr "original
     1210msgstr "premiÚre version par
    12161211 
    12171212#: lib/gettext_strings.rb:52 
     
    12471242msgstr "la recherche n'a donné aucun résultat" 
    12481243 
    1249 #: lib/gettext_strings.rb:66 
     1244#: lib/gettext_strings.rb:65 
     1245msgid "search results" 
     1246msgstr "résultats de la recherche" 
     1247 
     1248#: lib/gettext_strings.rb:67 
    12501249msgid "btn_unplublish" 
    12511250msgstr "<img src='/images/delete.png' alt='dépublier'/>" 
    12521251 
    1253 #: lib/gettext_strings.rb:68 
     1252#: lib/gettext_strings.rb:69 
    12541253msgid "status_50" 
    12551254msgstr "publié" 
    12561255 
    1257 #: lib/gettext_strings.rb:69 
     1256#: lib/gettext_strings.rb:70 
    12581257msgid "status_40" 
    12591258msgstr "proposé" 
    12601259 
    1261 #: lib/gettext_strings.rb:70 
     1260#: lib/gettext_strings.rb:71 
    12621261msgid "status_35" 
    12631262msgstr "proposé avec" 
    12641263 
    1265 #: lib/gettext_strings.rb:71 
     1264#: lib/gettext_strings.rb:72 
    12661265msgid "status_33" 
    12671266msgstr "rédaction visible" 
    12681267 
    1269 #: lib/gettext_strings.rb:72 
     1268#: lib/gettext_strings.rb:73 
    12701269msgid "status_30" 
    12711270msgstr "rédaction" 
    12721271 
    1273 #: lib/gettext_strings.rb:73 
     1272#: lib/gettext_strings.rb:74 
    12741273msgid "status_20" 
    12751274msgstr "remplacé" 
    12761275 
    1277 #: lib/gettext_strings.rb:74 
     1276#: lib/gettext_strings.rb:75 
    12781277msgid "status_10" 
    12791278msgstr "enlevé" 
    12801279 
    1281 #: lib/gettext_strings.rb:75 
     1280#: lib/gettext_strings.rb:76 
    12821281msgid "status_0" 
    12831282msgstr "effacé" 
    12841283 
    1285 #: lib/gettext_strings.rb:77 
     1284#: lib/gettext_strings.rb:78 
    12861285msgid "en" 
    12871286msgstr "anglais" 
    12881287 
    1289 #: lib/gettext_strings.rb:78 
     1288#: lib/gettext_strings.rb:79 
    12901289msgid "fr" 
    12911290msgstr "français" 
    12921291 
    1293 #: lib/gettext_strings.rb:79 
     1292#: lib/gettext_strings.rb:80 
    12941293msgid "de" 
    12951294msgstr "allemand" 
    12961295 
    1297 #: lib/gettext_strings.rb:80 
     1296#: lib/gettext_strings.rb:81 
    12981297msgid "Monday" 
    12991298msgstr "lundi" 
    13001299 
    1301 #: lib/gettext_strings.rb:81 
     1300#: lib/gettext_strings.rb:82 
    13021301msgid "Tuesday" 
    13031302msgstr "mardi" 
    13041303 
    1305 #: lib/gettext_strings.rb:82