| @@ 2315-2317 (lines=3) @@ | ||
| 2312 | if (is_string($def)) { |
|
| 2313 | $constraints[] = 'CHECK (' . $def . ')'; |
|
| 2314 | } else { |
|
| 2315 | if (isset($def['min'])) { |
|
| 2316 | $constraints[] = 'CHECK (' . $field . ' >= ' . $def['min'] . ')'; |
|
| 2317 | } |
|
| 2318 | ||
| 2319 | if (isset($def['max'])) { |
|
| 2320 | $constraints[] = 'CHECK (' . $field . ' <= ' . $def['max'] . ')'; |
|
| @@ 2319-2321 (lines=3) @@ | ||
| 2316 | $constraints[] = 'CHECK (' . $field . ' >= ' . $def['min'] . ')'; |
|
| 2317 | } |
|
| 2318 | ||
| 2319 | if (isset($def['max'])) { |
|
| 2320 | $constraints[] = 'CHECK (' . $field . ' <= ' . $def['max'] . ')'; |
|
| 2321 | } |
|
| 2322 | } |
|
| 2323 | } |
|
| 2324 | ||