Difference between revisions of "Task:Regexp"

From OPENRESEARCH th copy Wiki
Jump to navigation Jump to search
(Created page with "=Task = Create Concept:Regexp with all required pages such as Help,List of, Template and, Category. =Goal= Ability to define different Regexp that can be used in forms. Each R...")
 
 
(3 intermediate revisions by the same user not shown)
Line 25: Line 25:
 
* [[Regexp:NaturalNumber]] (Should replace the current pattern defined in [[Property:Ordinal]])
 
* [[Regexp:NaturalNumber]] (Should replace the current pattern defined in [[Property:Ordinal]])
 
* [[Regexp:Email]] (just as example)
 
* [[Regexp:Email]] (just as example)
 +
* [[Regexp:Char]] (needed for [[Property:Regexp or char]])
 +
* [[Regexp:URL]]
  
 
Update the current use of regexp in forms:
 
Update the current use of regexp in forms:
 
* Create [[Template:RegexpToFieldRegexp]]: A template to resolve a given Regexp into the field arguments of regexp
 
* Create [[Template:RegexpToFieldRegexp]]: A template to resolve a given Regexp into the field arguments of regexp
 
* Update [[Template:FieldByProperty]] to use [[Template:RegexpToFieldRegexp]]
 
* Update [[Template:FieldByProperty]] to use [[Template:RegexpToFieldRegexp]]
 +
 +
Update all Properties that use URL as [[Property:Property type]] but text as [[Property:Property inputType]] to regexp and add [[Regexp:URL]] as as [[Property:Property regex]]
 +
 +
List of Properties that need to be updated:
 +
{{#ask: [[Property type::Special:Types/URL]][[Property inputType::text]]|format=ul}}
 +
 +
=Issues=
 +
Complex regexps seem currently not to work. It might be related to the used version of the Page Forms extension.
 +
 +
[[Category:Task]]

Latest revision as of 15:36, 1 March 2021

Task

Create Concept:Regexp with all required pages such as Help,List of, Template and, Category.

Goal

Ability to define different Regexp that can be used in forms. Each Regexp should consist of

  • pattern
  • message (error message that is displayed)
  • base type
  • inverse
  • or char
  • base prefix

See https://www.mediawiki.org/wiki/Extension:Page_Forms/Input_types/Regexp


Procedure

Create the following pages

Define the following Regexp:

Update the current use of regexp in forms:

Update all Properties that use URL as Property:Property type but text as Property:Property inputType to regexp and add Regexp:URL as as Property:Property regex

List of Properties that need to be updated:

Issues

Complex regexps seem currently not to work. It might be related to the used version of the Page Forms extension.