Browse Source

new info button

andre 5 tháng trước cách đây
mục cha
commit
b08fef157f

+ 2 - 12
app/UI/Client/Setting/Forms/EditSettingForm.php

@@ -39,17 +39,7 @@ class EditSettingForm extends SortedFieldForm implements ClientArea
 
     public function initFields()
     {
-        $this->addField((new Hidden('id')));
-        $email = new InputGroup('usernameGroup');
-
-        $email->addInputComponent((new InputGroupElements\Text('name'))->addHtmlAttribute('readonly','true'));
-        $email->addInputAddon('emailSign', false, '@');
-        $email->addInputComponent((new InputGroupElements\Text('domain'))->addHtmlAttribute('readonly','true'));
-        $this->addSection($email);
-
-        $this->generateDoubleSection([new Text('description'), new Select('type')]);
-
-        $this->generateDoubleSection([new Select('manager'), new Select('status')]);
-
+        $this->addSection(new EditGeneralSection());
+        $this->addSection(new EditAdditionalSection());
     }
 }

+ 1 - 2
app/UI/Client/Setting/Forms/InfoForm.php

@@ -30,9 +30,8 @@ class InfoForm extends BaseForm implements ClientArea
 
     private function initFields()
     {
-        $this->setConfirmMessage("error: :status:");
+        $this->setConfirmMessage("DNS Information");
         $this->addField(new Hidden("seldns"));
         $this->addField(new Text("mxactive"));
-        $this->addLocalLangReplacements(["status" => null]);
     }
 }

+ 4 - 12
app/UI/Client/Setting/Sections/EditAdditionalSection.php

@@ -23,18 +23,10 @@ class EditAdditionalSection extends FreeFieldsSection
 
     public function initContent()
     {
-        $this->generateDoubleSection([new Text('contact'), new Text('site')]);
-
-        $this->generateDoubleSection([new Text('contact_mail'), new Text('contact_phone')]);
-
-        $this->generateDoubleSection([new Text('street'), new Text('building')]);
-
-        $this->generateDoubleSection([new Text('floor'), new Text('room')]);
-
-        $this->generateDoubleSection([new Text('post_code'), new Text('town')]);
-
-        $this->generateDoubleSection([new Text('state'), new Text('county')]);
-
+        $field = new Text('2FA');
+        $this->addField($field);
+        $field = new Text('AD');
+        $this->addField($field);
     }
 
 }

+ 2 - 20
app/UI/Client/Setting/Sections/EditGeneralSection.php

@@ -31,32 +31,14 @@ class EditGeneralSection extends FreeFieldsSection
         /**
          * add fields
          */
-        $field = new Hidden('id');
+        $field = new Hidden('domain');
         $this->addField($field);
 
-        $email =new InputGroup('usernameGroup');
-
-        $email->addInputComponent((new InputGroupElements\Text('username'))->addHtmlAttribute('readonly','true'));
-        $email->addInputAddon('emailSign', false, '@');
-        $email->addInputComponent((new InputGroupElements\Text('domain'))->addHtmlAttribute('readonly','true'));
-        $this->addSection($email);
-
-        $this->generateDoubleSection([new Text('display_name'), new Select('status')]);
-
-        $type = new Select('type');
-        $capacity = new Text('capacity');
-
-        $this->generateDoubleSection([$type, $capacity]);
-
-        $field = new Text('description');
+        $field = new Text('test');
         $this->addField($field);
 
         $field = new Text('notes');
         $this->addField($field);
 
-        $autoAcceptDecline = new Switcher('auto_accept');
-        $autoDeclineBusy = new Switcher('auto_busy');
-        $this->generateDoubleSection([$autoAcceptDecline, $autoDeclineBusy]);
-
     }
 }