Commit a7e2c4cb1631e34c9cd05d41f63e2cd0b1f64436
1 parent
ed88ca6b
changed to prefill with default values if they are not retrieved from the database
git-svn-id: https://kt-dms.svn.sourceforge.net/svnroot/kt-dms/trunk@1683 c91229c3-7414-0410-bfa2-8a42b809f60b
Showing
1 changed file
with
6 additions
and
2 deletions
presentation/lookAndFeel/knowledgeTree/administration/systemsettings/systemSettingsUI.inc
| ... | ... | @@ -66,8 +66,12 @@ function getPage() { |
| 66 | 66 | $sToRender .= "<tr>\n"; |
| 67 | 67 | $sToRender .= "</tr>\n"; |
| 68 | 68 | for($i = 0; $i < count($aNames); $i++) { |
| 69 | - | |
| 70 | - $sToRender .= "<td>". ($i+1) .".</td><td>" .$aRowNames[$i] ." </td><td><input size = \"40\" type=\"text\" name=\"". $aNames[$i] ."\" value =\"". $oSystem->get(substr($aNames[$i],1)) ."\"></td>\n"; | |
| 69 | + if ($oSystem->initialised()) { | |
| 70 | + $sToRender .= "<td>". ($i+1) .".</td><td>" .$aRowNames[$i] ." </td><td><input size = \"40\" type=\"text\" name=\"". $aNames[$i] ."\" value =\"". $oSystem->get(substr($aNames[$i],1)) ."\"></td>\n"; | |
| 71 | + } else { | |
| 72 | + $sSetting = substr($aNames[$i],1); | |
| 73 | + $sToRender .= "<td>". ($i+1) .".</td><td>" .$aRowNames[$i] ." </td><td><input size = \"40\" type=\"text\" name=\"". $aNames[$i] ."\" value =\"". $default->$sSetting ."\"></td>\n"; | |
| 74 | + } | |
| 71 | 75 | $sToRender .= "</tr>\n"; |
| 72 | 76 | |
| 73 | 77 | } | ... | ... |