Patch title: Release 86 bulk changes
Abstract:
File: /pliant/appli/forum/forum.page
Key:
    Removed line
    Added line
module "database.pli"
module "/pliant/language/context.pli"

requires "browse_configuration"

title "Forums administration"

[List of currently defined forums:]
table columns 2
  cell header
    [Forum ID]
  cell header
    [Description]
  each f forum_database:data:forum
    cell
      fixed (text keyof:f) ; eol
    cell
      button "Edit"
        read_only allowed:"administrator"
        read_only not allowed:"administrator"
        title "Forum '"+keyof:f+"'"
        table columns 3 border 0
          cell
            [Forum ID:]
          cell
            fixed (text keyof:f)
          cell
            []
          cell
            [Title:]
          cell
            input "" f:title
          cell
            [A one line description of the forum content.]
          cell
            [Abstract:]
          cell
            text_input "" f:abstract columns 60 rows 10
          cell
            [More details description, including the expected audience and posting rules.]
          cell
            [Path:]
          cell
            input "" f:path
          cell
            [Where the forum files are stored on the server disk.]
          cell
            [Site:]
          cell
            input "" f:site
          cell
            [The web site hosting this forum. An example could be]
            fixed [ helio.pliant.cx]
          cell
            [URL:]
          cell
            input "" f:url
          cell
            [The URL of the forum on the Internet]
          cell
            [From:]
          cell
            input "" f:from
          cell
            [The mailbox that will be specifyed as origin for the mails sent from this forum.]
          cell
            [Reference path:]
          cell
            input "" f:reference_path
          cell
            [If not empty, it will be abble to upload patches in the forum, that will be compared to the specifyed path content.]
          cell
            [Live path:]
          cell
            input "" f:live_path
          cell
            [If not empty, it will be abble to upload patches through checking changes applied here.] ; eol
            [In other words, it should point the tree you are modifying through your favorit editor.]
          cell
            [Patch repository servers:]
          cell
            input "" f:patch_servers
          cell
            [List of the servers that are allowed to upload or download patches.] ; eol
            ['*' is a special value meaning any server.]
          cell
            [Official path:]
          cell
            input "" f:official_path
          cell
            [If not empty, specifies the header path we should find in tarball files.]
          cell
            [Reading requires:]
          cell
            input "" f:read
          cell
            [The right a user must have to read informations on the forum.]
          cell
            [Posting requires:]
          cell
            input "" f:post
          cell
            [The right a user must have to post informations on the forum.]
          cell
            [Administrating requires:]
          cell
            input "" f:maintainer
          cell
            [The right a user must have to be a forum maintainer.]
        para
          table columns 3
            cell header [Subject ID]
            cell header [Label]
            cell header [Order]
            each su f:subject
              cell
                text keyof:su
              cell
                input "" su:label
              cell
                input "" su:order
          if allowed:"administrator"
            input "Subject ID: " (var Str suid) noeol
            button "Create the new subject" noeol
              f:subject create suid
              reload_page
            button "Delete the subject"
              f:subject delete suid
              reload_page
        para
          table columns 5
            cell header [Status ID]
            cell header [Label]
            cell header [Archive delay]
            cell header [Order]
            cell header [Display all label]
            each st f:status
              cell
                text keyof:st
              cell
                input "" st:label
              cell
                input "" st:archive_delay
              cell
                input "" st:order
              cell
                input "" st:display_all_label
          if allowed:"administrator"
            input "Status ID: " (var Str stid) noeol
            button "Create the new status" noeol
              f:status create stid
              reload_page
            button "Delete the status"
              f:status delete stid
              reload_page
        if allowed:"administrator"
          button "Update forum informations"
            goto_backward

if allowed:"administrator"
  input "Forum ID: " (var Str fid) length 30 noeol
  button "Create the new forum" noeol
    forum_database:data:forum create fid
    var Data:Forum f :> forum_database:data:forum:fid
    f path := "data:/pliant/forum/"+fid+"/"
    f site := computer_fullname
    f url := "http://"+computer_fullname+"/pliant/browse/forum/"+fid+"/"
    f from := fid+" forum <"+fid+"@"+computer_domain+">"
    f last_hourly_report := datetime
    f last_daily_report := datetime
    f last_weekly_report := datetime
    reload_page
  button "Delete the forum"
    forum_database:data:forum delete fid
    reload_page