Răsfoiți Sursa

default value

itizawa 6 ani în urmă
părinte
comite
4abbb5cca0

+ 10 - 10
src/client/js/components/Admin/Security/LdapSecuritySetting.jsx

@@ -88,7 +88,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="serverUrl"
-                  value={adminLdapSecurityContainer.state.serverUrl}
+                  defaultValue={adminLdapSecurityContainer.state.serverUrl}
                   onChange={e => adminLdapSecurityContainer.changeServerUrl(e.target.value)}
                 />
                 <small>
@@ -136,7 +136,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="bindDN"
-                  value={adminLdapSecurityContainer.state.bindDN}
+                  defaultValue={adminLdapSecurityContainer.state.ldapBindDN}
                   onChange={e => adminLdapSecurityContainer.changeBindDN(e.target.value)}
                 />
                 {(adminLdapSecurityContainer.state.isUserBind === false) ? (
@@ -169,7 +169,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control passport-ldap-managerbind"
                   type="password"
                   name="bindDNPassword"
-                  value={adminLdapSecurityContainer.state.bindDNPassword}
+                  defaultValue={adminLdapSecurityContainer.state.ldapBindDNPassword}
                   onChange={e => adminLdapSecurityContainer.changeBindDNPassword(e.target.value)}
                 />
                 {(adminLdapSecurityContainer.state.bindMode === 'manager') ? (
@@ -196,7 +196,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="searchFilter"
-                  value={adminLdapSecurityContainer.state.searchFilter}
+                  defaultValue={adminLdapSecurityContainer.state.ldapSearchFilter}
                   onChange={e => adminLdapSecurityContainer.changeSearchFilter(e.target.value)}
                 />
                 <p className="help-block">
@@ -231,7 +231,7 @@ class LdapSecuritySetting extends React.Component {
                   type="text"
                   placeholder="Default: uid"
                   name="attrMapUsername"
-                  value={adminLdapSecurityContainer.state.attrMapUsername}
+                  defaultValue={adminLdapSecurityContainer.state.ldapAttrMapUsername}
                   onChange={e => adminLdapSecurityContainer.changeAttrMapUsername(e.target.value)}
                 />
                 <p className="help-block">
@@ -271,7 +271,7 @@ class LdapSecuritySetting extends React.Component {
                   type="text"
                   placeholder="Default: mail"
                   name="attrMapMail"
-                  value={adminLdapSecurityContainer.state.attrMapMail}
+                  defaultValue={adminLdapSecurityContainer.state.ldapAttrMapMail}
                   onChange={e => adminLdapSecurityContainer.changeAttrMapMail(e.target.value)}
                 />
                 <p className="help-block">
@@ -289,7 +289,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="attrMapName"
-                  value={adminLdapSecurityContainer.state.attrMapName}
+                  defaultValue={adminLdapSecurityContainer.state.ldapAttrMapName}
                   onChange={e => adminLdapSecurityContainer.changeAttrMapName(e.target.value)}
                 />
                 <p className="help-block">
@@ -312,7 +312,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="groupSearchBase"
-                  value={adminLdapSecurityContainer.state.groupSearchBase}
+                  defaultValue={adminLdapSecurityContainer.state.ldapGroupSearchBase}
                   onChange={e => adminLdapSecurityContainer.changeGroupSearchBase(e.target.value)}
                 />
                 <p className="help-block">
@@ -332,7 +332,7 @@ class LdapSecuritySetting extends React.Component {
                   className="form-control"
                   type="text"
                   name="groupSearchFilter"
-                  value={adminLdapSecurityContainer.state.groupSearchFilter}
+                  defaultValue={adminLdapSecurityContainer.state.ldapGroupSearchFilter}
                   onChange={e => adminLdapSecurityContainer.changeGroupSearchFilter(e.target.value)}
                 />
                 <p className="help-block">
@@ -362,7 +362,7 @@ class LdapSecuritySetting extends React.Component {
                   type="text"
                   placeholder="Default: uid"
                   name="groupDnProperty"
-                  value={adminLdapSecurityContainer.state.groupDnProperty}
+                  defaultValue={adminLdapSecurityContainer.state.ldapGroupDnProperty}
                   onChange={e => adminLdapSecurityContainer.changeGroupDnProperty(e.target.value)}
                 />
                 <p className="help-block">