Skip To Main Content
Begin Main Content
Methods: Source: Variables:
[All Methods | Documented Methods | Hide Methods] [Display Source | Hide Source] [Show Variables | Hide Variables]

::xo::db::CrClass[i] ::xowiki::Form

Class Hierarchy of ::xowiki::Form

  • ::xotcl::Object[i]
    Meta-class:
    ::xotcl::Class[i]
    Methods for instances:
    __api_make_doc, __api_make_forward_doc, __nextC, __timediff, abstract, ad_doc, ad_forward, ad_proc, appendC, arrayC, asHTML, autonameC, checkC, classC, cleanupC, configureC, contains, copy, db_1rowC, debug, defaultmethod, destroyC, destroy_on_cleanup, dot_append_method, dotclass, dotcode, dotquote, dotquotel, evalC, existsC, extractConfigureArg, filterC, filterguardC, filtersearchC, forwardC, hasclass, incrC, infoC, init, instvarC, invarC, isclassC, ismetaclassC, ismixinC, isobjectC, istypeC, lappendC, log, method, mixinC, mixinguardC, move, msg, noinitC, parametercmdC, procC, procsearchC, qn, requireNamespaceC, self, serialize, setC, substC, traceC, unsetC, uplevelC, upvarC, volatileC, vwaitC
    Methods to be applied on the class (in addition to the methods provided by the meta-class):
    __exitHandler, getExitHandler, setExitHandler, unsetExitHandler
    • ::xo::db::Object[i]
      Meta-class:
      ::xo::db::Class[i]
      Methods for instances:
      delete, initialize_loaded_object, insert, object_idC, object_titleC, save, save_new
      Methods to be applied on the class:
      Methods provided by the meta-class
      • ::xo::db::CrItem[i]
        Meta-class:
        ::xo::db::CrClass[i]
        Parameter for instances:
        package_id, parent_id (default "-100"), publish_status (default "ready")
        Methods for instances:
        current_user_id, delete, descriptionC, fix_content, initialize_loaded_object, item_idC, mime_typeC, nameC, nls_languageC, privilege=creator, publish_dateC, rename, revision_idC, revisions, save, save_new, set_live_revision, textC, titleC, update_attribute_from_slot, update_content, update_revision
        Methods to be applied on the class:
        Methods provided by the meta-class
        • ::xowiki::Page[i]
          Meta-class:
          ::xo::db::CrClass[i]
          Parameter for instances:
          absolute_links (default "0"), do_substitutions (default "1"), lang (default "en"), render_adp (default "1")
          Methods for instances:
          adp_subst, anchor, build_instance_attribute_map, build_name, category_export, category_import, check_adp_include_path, condition=match, condition=regexp, copy_content_vars, create-new, create_form_field, create_form_fields, create_form_fields_from_form_constraints, create_raw_form_field, creation_userC, creatorC, default_instance_attributes, delete, delete-revision, demarshall, descripionC, diff, div, edit, error_during_render, error_in_includelet, exists_form_parameterC, exists_query_parameterC, field_names, find_slot, footer, form_field_index, form_parameterC, get_content, get_description, get_form_data, get_instance_attributes, get_rich_text_spec, htmlFooter, include, include_content, include_portlet, initialize_loaded_object, instantiate_includelet, is_new_entry, last_modifiedC, list, lookup_cached_form_field, lookup_form_field, make-live-revision, map_categories, map_party, marshall, mime_typeC, nameC, nls_languageC, page_idC, page_orderC, popular-tags, publish_dateC, query_parameterC, record_last_visited, regsub_eval, render, render_includelet, resolve_included_page_name, reverse_map_party, reverse_map_party_attribute, revisions, save, save-tags, save_attributes, save_data, save_new, set_content, show_fields, substitute_markup, textC, titleC, translate, unescape, unset_temporary_instance_variables, update_references, validate=form_constraints, validate=name, validate=page_order, view
          Methods to be applied on the class (in addition to the methods provided by the meta-class):
          __render_html, container_already_rendered, get_tags, import, quoted_html_content, save_tags
          • ::xowiki::PageTemplate[i]
            Meta-class:
            ::xo::db::CrClass[i]
            Parameter for instances:
            render_adp (default "0")
            Methods for instances:
            anon_instancesC, count_usages, delete, mime_typeC, page_template_idC
            Methods to be applied on the class (in addition to the methods provided by the meta-class):
            count_usages
            • ::xowiki::Form[i]
              Meta-class:
              ::xo::db::CrClass[i]
              Methods for instances:
              demarshall, footer, formC, form_constraintsC, get_content, get_form_constraints, marshall, mime_typeC, xowiki_form_idC
              Methods to be applied on the class (in addition to the methods provided by the meta-class):
              add_dom_attribute_value, disable_input_fields, dom_disable_input_fields, requireFormCSS

Class Relations

  • superclass: ::xowiki::PageTemplate[i]
::xo::db::CrClass create ::xowiki::Form \
     -superclass ::xowiki::PageTemplate

Methods

  • proc add_dom_attribute_value

    ::xowiki::Form proc add_dom_attribute_value {dom_node attr value} {
        if {[$dom_node hasAttribute $attr]} {
          set old_value [$dom_node getAttribute $attr]
          if {[lsearch -exact $old_value $value] == -1} {
            append value " " $old_value
          } else {
            set value $old_value
          }
        }
        $dom_node setAttribute $attr $value
      }
  • proc disable_input_fields

    ::xowiki::Form proc disable_input_fields {{-with_submit 0} form} {
        dom parse -simple -html $form doc
        $doc documentElement root
        my dom_disable_input_fields -with_submit $with_submit $root
        set form [lindex [$root selectNodes //form] 0]
        Form add_dom_attribute_value $form class "margin-form"
        return [$root asHTML]
      }
  • proc dom_disable_input_fields

    ::xowiki::Form proc dom_disable_input_fields {{-with_submit 0} root} {
        set fields [$root selectNodes "//button | //input | //optgroup | //option | //select | //textarea "]
        foreach field $fields {
          set type ""
          if {[$field hasAttribute type]} {set type [$field getAttribute type]}
          if {$type eq "submit" && !$with_submit} continue
          # Disabled fields are not transmitted from the form;
          # some applications expect hidden fields to be transmitted
          # to identify the context, so don't disable it...
          if {$type eq "hidden"} continue
          $field setAttribute disabled "disabled"
        }
      }
  • proc requireFormCSS

    ::xowiki::Form proc requireFormCSS {} {
        #my msg requireFormCSS
        set css [my set extraCSS]
        if {$css ne ""} {
          ::xo::Page requireCSS $css
        }
      }
  • instproc demarshall

    ::xowiki::Form instproc demarshall args {
        # Some older versions do not have anon_instances and no slots
        if {![my exists anon_instances]} {
          my set anon_instances "t"
        }
        next
      }
  • instproc footer

    ::xowiki::Form instproc footer {} {
        return [my include [list form-menu -form_item_id [my item_id]]]
      }
  • instproc get_content

    ::xowiki::Form instproc get_content {} {
        my instvar text form
        ::xowiki::Form requireFormCSS
    
        # we assume, that the richtext is stored as 2-elem list with mime-type
        #my log "-- text='$text'"
        if {[lindex $text 0] ne ""} {
          my do_substitutions 0
          set content [my substitute_markup [my set text]]
        } elseif {[lindex $form 0] ne ""} {
          set content [[self class] disable_input_fields [lindex $form 0]]
        } else {
          set content ""
        }
        return $content
      }
  • instproc get_form_constraints

    ::xowiki::Form instproc get_form_constraints args {
        # We define it as a method to ease overloading.
        return [my form_constraints]
      }
  • instproc marshall

    ::xowiki::Form instproc marshall {} {
        #set form_fields [my create_form_fields_from_form_constraints  #                     [my get_form_constraints]]
        #my log "--ff=$form_fields"
        #my build_instance_attribute_map $form_fields
        next
      }

Methods: Source: Variables:
[All Methods | Documented Methods | Hide Methods] [Display Source | Hide Source] [Show Variables | Hide Variables]
My Calendar