Merge pull request #108 from sgmap/pb-int-validator
Correction du validateur d'entiers (question de la durée de contrat)pull/119/head
commit
3665713b32
|
@ -7,6 +7,7 @@ import {EXPLAIN_VARIABLE} from '../actions'
|
|||
|
||||
import References from './rule/References'
|
||||
import './Aide.css'
|
||||
import {capitalise0} from '../utils'
|
||||
|
||||
@connect(
|
||||
state =>
|
||||
|
@ -39,7 +40,7 @@ export default class Aide extends Component {
|
|||
className="fa fa-times-circle"
|
||||
onClick={stopExplaining} ></i>
|
||||
<p
|
||||
dangerouslySetInnerHTML={{__html: this.renderExplanationMarkdown(text, rule.titre)}}>
|
||||
dangerouslySetInnerHTML={{__html: this.renderExplanationMarkdown(text, rule.titre || capitalise0(rule.name))}}>
|
||||
</p>
|
||||
{/* { possibilities &&
|
||||
<p>
|
||||
|
|
|
@ -9,6 +9,6 @@ export let number = {
|
|||
}
|
||||
|
||||
export let int = {
|
||||
test: v => /^[0-9]+/.test(v),
|
||||
test: v => /^[0-9]+$/.test(v),
|
||||
error: 'Vous devez entrer un entier, par ex. 16'
|
||||
}
|
||||
|
|
|
@ -45,7 +45,8 @@ export let reduceSteps = (tracker, flatRules, answerSource) => (state, action) =
|
|||
...state,
|
||||
analysedSituation,
|
||||
situationGate: situationGate,
|
||||
extraSteps: []
|
||||
extraSteps: [],
|
||||
explainedVariable: null
|
||||
}
|
||||
|
||||
if (action.type == START_CONVERSATION) {
|
||||
|
|
Loading…
Reference in New Issue