Home
Help
Search
Login
Register
OPNsense Forum
»
English Forums
»
Development and Code Review
(Moderator:
fabian
) »
Regexp in forms?
« previous
next »
Print
Pages: [
1
]
Author
Topic: Regexp in forms? (Read 4695 times)
mimugmail
Hero Member
Posts: 6766
Karma: 494
Regexp in forms?
«
on:
May 07, 2017, 08:18:34 am »
Hi,
I have to build a form where a filter-list with regexp has to be inserted.
First I choosed a text field to enter a regexp:
<as type="TextField">
<default></default>
<Required>Y</Required>
</as>
The regexp looks like ^4001$
Saving works fine, but when I create a
<match type="ModelRelationField">
<Model>
<template>
<source>OPNsense.quagga.bgp</source>
<items>aspaths.aspath</items>
<display>name</display>
</template>
</Model>
<ValidationMessage>Related item not found</ValidationMessage>
<Multiple>Y</Multiple>
<Required>N</Required>
.. the created regexp will not be listed.
If I only enter 4001 in the text field I can choose it in the dropdown list.
Problem is that I need the regexp style.
Logged
WWW:
www.routerperformance.net
Support plans:
https://www.max-it.de/en/it-services/opnsense/
Commercial Plugins (German):
https://opnsense.max-it.de/
Print
Pages: [
1
]
« previous
next »
OPNsense Forum
»
English Forums
»
Development and Code Review
(Moderator:
fabian
) »
Regexp in forms?