MaxKey пре 3 година
родитељ
комит
e74b13eaf8

+ 3 - 0
maxkey-core/src/main/java/org/maxkey/constants/ConstsOperateAction.java

@@ -37,6 +37,8 @@ public final class ConstsOperateAction {
     
     public static final String DISABLE 			= "disable";
     
+    public static final String INACTIVE 		= "inactive";
+    
     public static final String LOCK 			= "lock";
     
     public static final String UNLOCK 			= "unlock";
@@ -49,6 +51,7 @@ public final class ConstsOperateAction {
     	statusActon= new ConcurrentHashMap<Integer,String>();
     	statusActon.put(ConstsStatus.ACTIVE, ENABLE);
     	statusActon.put(ConstsStatus.DISABLED, DISABLE);
+    	statusActon.put(ConstsStatus.INACTIVE, INACTIVE);
     	statusActon.put(ConstsStatus.LOCK, LOCK);
     	statusActon.put(ConstsStatus.UNLOCK, UNLOCK);
     	statusActon.put(ConstsStatus.DELETE, DELETE);

+ 5 - 4
maxkey-web-frontend/maxkey-web-app/src/app/entity/BaseEntity.ts

@@ -1,19 +1,18 @@
 /*
  * Copyright [2022] [MaxKey of copyright http://www.maxkey.top]
- * 
+ *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
- * 
+ *
  *     http://www.apache.org/licenses/LICENSE-2.0
- * 
+ *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
- 
 
 export class BaseEntity {
     id!: String;
@@ -23,6 +22,7 @@ export class BaseEntity {
     status!: Number;
     description!: String;
     switch_status: boolean = false;
+    str_status!: String;
 
     constructor() {
         this.status = 1;
@@ -31,6 +31,7 @@ export class BaseEntity {
         Object.assign(this, data);
         if (this.status == 1) {
             this.switch_status = true;
+            this.str_status = `${this.status}`;
         }
     }
     trans(): void {

+ 13 - 5
maxkey-web-frontend/maxkey-web-app/src/app/entity/Users.ts

@@ -1,19 +1,18 @@
 /*
  * Copyright [2022] [MaxKey of copyright http://www.maxkey.top]
- * 
+ *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
- * 
+ *
  *     http://www.apache.org/licenses/LICENSE-2.0
- * 
+ *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
- 
 
 import { BaseEntity } from './BaseEntity';
 
@@ -143,7 +142,8 @@ export class Users extends BaseEntity {
     switch_dynamic: boolean = false;
 
     gender_select!: String;
-
+    str_married!: String;
+    str_idType!: String;
     constructor() {
         super();
         this.status = 1;
@@ -152,6 +152,8 @@ export class Users extends BaseEntity {
         this.userType = 'EMPLOYEE';
         this.userState = 'RESIDENT';
         this.gender_select = '1';
+        this.str_married = '0';
+        this.str_idType = '0';
     }
 
     override init(data: any): void {
@@ -164,6 +166,9 @@ export class Users extends BaseEntity {
         } else {
             this.gender_select = '2';
         }
+        this.str_status = `${this.status}`;
+        this.str_married = `${this.married}`;
+        this.str_idType = `${this.idType}`;
     }
     override trans(): void {
         if (this.switch_status) {
@@ -177,5 +182,8 @@ export class Users extends BaseEntity {
         } else {
             this.gender = 2;
         }
+        this.status = Number.parseInt(`${this.str_status}`);
+        this.married = Number.parseInt(`${this.str_married}`);
+        this.idType = Number.parseInt(`${this.str_idType}`);
     }
 }

+ 319 - 402
maxkey-web-frontend/maxkey-web-app/src/app/routes/config/profile/profile.component.html

@@ -10,47 +10,36 @@
                 <nz-form-item style="display: none">
                   <nz-form-label [nzMd]="8" nzFor="id">{{ 'mxk.text.id' | i18n }}</nz-form-label>
                   <nz-form-control [nzMd]="16" nzErrorTip="The input is not valid id!">
-                    <input [(ngModel)]="form.model.id" [ngModelOptions]="{ standalone: true }" nz-input name="id" id="id" />
-                    <input
-                      [(ngModel)]="form.model.pictureId"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="pictureId"
-                      id="pictureId"
-                    />
+                    <input [(ngModel)]="form.model.id" [ngModelOptions]="{ standalone: true }" nz-input name="id"
+                      id="id" />
+                    <input [(ngModel)]="form.model.pictureId" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="pictureId" id="pictureId" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
                   <div nz-row style="width: 100%; margin-bottom: 18px">
-                    <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="displayName">{{ 'mxk.users.displayName' | i18n }}</nz-form-label>
-                    <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid displayName!">
-                      <input
-                        readonly
-                        [(ngModel)]="form.model.displayName"
-                        [ngModelOptions]="{ standalone: true }"
-                        nz-input
-                        name="displayName"
-                        id="displayName"
-                      />
+                    <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="name">{{ 'mxk.users.displayName' | i18n }}
+                    </nz-form-label>
+                    <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                      nzErrorTip="The input is not valid displayName!">
+                      <input [(ngModel)]="form.model.displayName" [ngModelOptions]="{ standalone: true }" nz-input
+                        name="displayName" id="displayName" />
                     </nz-form-control>
                   </div>
                   <div nz-row style="width: 100%; margin-bottom: 18px">
-                    <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="username">{{ 'mxk.users.username' | i18n }}</nz-form-label>
-                    <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid username!">
-                      <input
-                        disabled="true"
-                        [(ngModel)]="form.model.username"
-                        [ngModelOptions]="{ standalone: true }"
-                        nz-input
-                        name="username"
-                        id="username"
-                      />
+                    <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="username">{{ 'mxk.users.username' | i18n }}
+                    </nz-form-label>
+                    <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                      nzErrorTip="The input is not valid username!">
+                      <input [(ngModel)]="form.model.username" [ngModelOptions]="{ standalone: true }" nz-input
+                        name="username" id="username" />
                     </nz-form-control>
                   </div>
                   <div nz-row style="width: 100%">
                     <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="gender">{{ 'mxk.users.gender' | i18n }}</nz-form-label>
                     <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid gender!">
-                      <nz-radio-group [(ngModel)]="form.model.gender_select" [ngModelOptions]="{ standalone: true }" nzButtonStyle="solid">
+                      <nz-radio-group [(ngModel)]="form.model.gender_select" [ngModelOptions]="{ standalone: true }"
+                        nzButtonStyle="solid">
                         <label nz-radio-button nzValue="2">{{ 'mxk.users.gender.male' | i18n }}</label>
                         <label nz-radio-button nzValue="1">{{ 'mxk.users.gender.female' | i18n }}</label>
                       </nz-radio-group>
@@ -59,28 +48,19 @@
                 </nz-form-item>
 
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="uploadFile">{{ 'mxk.users.picture' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="uploadFile">{{ 'mxk.users.picture' | i18n }}
+                  </nz-form-label>
                   <div nz-col class="clearfix" nzSm="16" nzXs="24">
-                    <nz-upload
-                      nzAction="file/upload/"
-                      nzListType="picture-card"
-                      [(nzFileList)]="fileList"
-                      nzName="uploadFile"
-                      [nzShowButton]="fileList.length < 1"
-                      [nzPreview]="handlePreview"
-                      (nzChange)="uploadImageChange($event)"
-                    >
+                    <nz-upload nzAction="file/upload/" nzListType="picture-card" [(nzFileList)]="fileList"
+                      nzName="uploadFile" [nzShowButton]="fileList.length < 1" [nzPreview]="handlePreview"
+                      (nzChange)="uploadImageChange($event)">
                       <div>
                         <i nz-icon nzType="plus"></i>
                         <div style="margin-top: 8px">Upload</div>
                       </div>
                     </nz-upload>
-                    <nz-modal
-                      [nzVisible]="previewVisible"
-                      [nzContent]="modalContent"
-                      [nzFooter]="null"
-                      (nzOnCancel)="previewVisible = false"
-                    >
+                    <nz-modal [nzVisible]="previewVisible" [nzContent]="modalContent" [nzFooter]="null"
+                      (nzOnCancel)="previewVisible = false">
                       <ng-template #modalContent>
                         <img [src]="previewImage" [ngStyle]="{ width: '100%' }" />
                       </ng-template>
@@ -90,72 +70,103 @@
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="employeeNumber">{{ 'mxk.users.employeeNumber' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid employeeNumber!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.employeeNumber"
-                      readonly
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="employeeNumber"
-                      id="employeeNumber"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="employeeNumber">{{ 'mxk.users.employeeNumber' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid employeeNumber!">
+                    <input [(ngModel)]="form.model.employeeNumber" readonly [ngModelOptions]="{ standalone: true }"
+                      nz-input name="employeeNumber" id="employeeNumber" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="windowsAccount">{{ 'mxk.users.windowsAccount' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="windowsAccount">{{ 'mxk.users.windowsAccount' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid status!">
-                    <input
-                      [(ngModel)]="form.model.windowsAccount"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      readonly
-                      name="windowsAccount"
-                      id="windowsAccount"
-                    />
+                    <input [(ngModel)]="form.model.windowsAccount" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="windowsAccount" id="windowsAccount" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label nzRequired [nzSm]="8" [nzXs]="24" nzFor="mobile">{{ 'mxk.users.mobile' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid mobile!">
-                    <input [(ngModel)]="form.model.mobile" [ngModelOptions]="{ standalone: true }" nz-input name="mobile" id="mobile" />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="mobile">{{ 'mxk.users.mobile' | i18n }}</nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid mobile!">
+                    <input [(ngModel)]="form.model.mobile" readonly [ngModelOptions]="{ standalone: true }" nz-input
+                      name="mobile" id="mobile" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label nzRequired [nzSm]="8" [nzXs]="24" nzFor="email">{{ 'mxk.users.email' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid email!">
-                    <input [(ngModel)]="form.model.email" [ngModelOptions]="{ standalone: true }" nz-input name="email" id="email" />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="email">{{ 'mxk.users.email' | i18n }}</nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid email!">
+                    <input [(ngModel)]="form.model.email" [ngModelOptions]="{ standalone: true }" nz-input name="email"
+                      id="email" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
+
+              <div nz-row>
+                <nz-form-item>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="userType">{{ 'mxk.users.userType' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid userType!">
+                    <nz-select [(ngModel)]="form.model.userType" [ngModelOptions]="{ standalone: true }" name="userType"
+                      id="userType">
+                      <nz-option nzValue="EMPLOYEE" nzLabel="{{ 'mxk.users.userType.employee' | i18n }}"> </nz-option>
+                      <nz-option nzValue="SUPPLIER" nzLabel="{{ 'mxk.users.userType.supplier' | i18n }}"> </nz-option>
+                      <nz-option nzValue="CUSTOMER" nzLabel="{{ 'mxk.users.userType.customer' | i18n }}"> </nz-option>
+                      <nz-option nzValue="CONTRACTOR" nzLabel="{{ 'mxk.users.userType.contractor' | i18n }}">
+                      </nz-option>
+                      <nz-option nzValue="DEALER" nzLabel="{{ 'mxk.users.userType.dealer' | i18n }}"></nz-option>
+                      <nz-option nzValue="PARTNER" nzLabel="{{ 'mxk.users.userType.partner' | i18n }}"></nz-option>
+                      <nz-option nzValue="EXTERNAL" nzLabel="{{ 'mxk.users.userType.external' | i18n }}"></nz-option>
+                      <nz-option nzValue="INTERN" nzLabel="{{ 'mxk.users.userType.intern' | i18n }}"></nz-option>
+                      <nz-option nzValue="TEMP" nzLabel="{{ 'mxk.users.userType.temp' | i18n }}"></nz-option>
+                    </nz-select>
+                  </nz-form-control>
+                </nz-form-item>
+                <nz-form-item>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="userState">{{ 'mxk.users.userstate' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid userState!">
+                    <nz-select [(ngModel)]="form.model.userState" [ngModelOptions]="{ standalone: true }"
+                      name="userState" id="userState">
+                      <nz-option nzValue="RESIDENT" nzLabel="{{ 'mxk.users.userstate.resident' | i18n }}"> </nz-option>
+                      <nz-option nzValue="WITHDRAWN" nzLabel="{{ 'mxk.users.userstate.withdrawn' | i18n }}">
+                      </nz-option>
+                      <nz-option nzValue="INACTIVE" nzLabel="{{ 'mxk.users.userstate.inactive' | i18n }}"> </nz-option>
+                      <nz-option nzValue="RETIREE" nzLabel="{{ 'mxk.users.userstate.retiree' | i18n }}"></nz-option>
+                    </nz-select>
+                  </nz-form-control>
+                </nz-form-item>
+              </div>
+
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="userType">{{ 'mxk.users.userType' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid userType!">
-                    <input
-                      [(ngModel)]="form.model.userType"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      readonly
-                      name="userType"
-                      id="userType"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="sortIndex">{{ 'mxk.text.sortIndex' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid sortIndex!">
+                    <nz-input-number [(ngModel)]="form.model.sortIndex" [ngModelOptions]="{ standalone: true }"
+                      [nzMin]="1" [nzMax]="100000" [nzStep]="1"></nz-input-number>
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="userState">{{ 'mxk.users.userstate' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid userState!">
-                    <input
-                      [(ngModel)]="form.model.userState"
-                      readonly
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="userState"
-                      id="userState"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzRequired nzFor="status">{{ 'mxk.text.status' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid status!">
+                    <nz-select [(ngModel)]="form.model.str_status" [ngModelOptions]="{ standalone: true }" name="status"
+                      id="status">
+                      <nz-option nzValue="1" nzLabel="{{ 'mxk.users.status.active' | i18n }}"></nz-option>
+                      <nz-option nzValue="2" nzLabel="{{ 'mxk.users.status.inactive' | i18n }}"></nz-option>
+                      <nz-option nzValue="4" nzLabel="{{ 'mxk.users.status.forbidden' | i18n }}"></nz-option>
+                      <nz-option nzValue="5" nzLabel="{{ 'mxk.users.status.lock' | i18n }}"></nz-option>
+                      <nz-option nzValue="9" nzLabel="{{ 'mxk.users.status.delete' | i18n }}"></nz-option>
+                    </nz-select>
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -163,53 +174,37 @@
             <nz-tab nzTitle="{{ 'mxk.users.tab.personal' | i18n }}">
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="familyName">{{ 'mxk.users.familyName' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="familyName">{{ 'mxk.users.familyName' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="16" nzErrorTip="The input is not valid familyName!">
-                    <input
-                      [(ngModel)]="form.model.familyName"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="familyName"
-                      id="familyName"
-                    />
+                    <input [(ngModel)]="form.model.familyName" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="familyName" id="familyName" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="middleName">{{ 'mxk.users.middleName' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="middleName">{{ 'mxk.users.middleName' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid middleName!">
-                    <input
-                      [(ngModel)]="form.model.middleName"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="middleName"
-                      id="middleName"
-                    />
+                    <input [(ngModel)]="form.model.middleName" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="middleName" id="middleName" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="givenName">{{ 'mxk.users.givenName' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="givenName">{{ 'mxk.users.givenName' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid givenName!">
-                    <input
-                      [(ngModel)]="form.model.givenName"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="givenName"
-                      id="givenName"
-                    />
+                    <input [(ngModel)]="form.model.givenName" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="givenName" id="givenName" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="nickName">{{ 'mxk.users.nickName' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="nickName">{{ 'mxk.users.nickName' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid nickName!">
-                    <input
-                      [(ngModel)]="form.model.nickName"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="nickName"
-                      id="nickName"
-                    />
+                    <input [(ngModel)]="form.model.nickName" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="nickName" id="nickName" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -217,19 +212,22 @@
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="idType">{{ 'mxk.users.idtype' | i18n }}</nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid idType!">
-                    <input [(ngModel)]="form.model.idType" [ngModelOptions]="{ standalone: true }" nz-input name="idType" id="idType" />
+                    <nz-select [(ngModel)]="form.model.str_idType" [ngModelOptions]="{ standalone: true }" name="idType"
+                      id="idType">
+                      <nz-option nzValue="0" nzLabel="{{ 'mxk.users.idtype.unknown' | i18n }}"></nz-option>
+                      <nz-option nzValue="1" nzLabel="{{ 'mxk.users.idtype.idcard' | i18n }}"></nz-option>
+                      <nz-option nzValue="2" nzLabel="{{ 'mxk.users.idtype.passport' | i18n }}"></nz-option>
+                      <nz-option nzValue="3" nzLabel="{{ 'mxk.users.idtype.studentcard' | i18n }}"></nz-option>
+                      <nz-option nzValue="4" nzLabel="{{ 'mxk.users.idtype.militarycard' | i18n }}"></nz-option>
+                    </nz-select>
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="idCardNo">{{ 'mxk.users.idCardNo' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="idCardNo">{{ 'mxk.users.idCardNo' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid idCardNo!">
-                    <input
-                      [(ngModel)]="form.model.idCardNo"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="idCardNo"
-                      id="idCardNo"
-                    />
+                    <input [(ngModel)]="form.model.idCardNo" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="idCardNo" id="idCardNo" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -237,45 +235,41 @@
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="married">{{ 'mxk.users.married' | i18n }}</nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid married!">
-                    <input [(ngModel)]="form.model.married" [ngModelOptions]="{ standalone: true }" nz-input name="married" id="married" />
+                    <nz-select [(ngModel)]="form.model.str_married" [ngModelOptions]="{ standalone: true }"
+                      name="married" id="married">
+                      <nz-option nzValue="0" nzLabel="{{ 'mxk.users.married.unknown' | i18n }}"></nz-option>
+                      <nz-option nzValue="1" nzLabel="{{ 'mxk.users.married.single' | i18n }}"></nz-option>
+                      <nz-option nzValue="2" nzLabel="{{ 'mxk.users.married.married' | i18n }}"></nz-option>
+                      <nz-option nzValue="3" nzLabel="{{ 'mxk.users.married.divorce' | i18n }}"></nz-option>
+                      <nz-option nzValue="4" nzLabel="{{ 'mxk.users.married.widowed' | i18n }}"></nz-option>
+                    </nz-select>
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="birthDate">{{ 'mxk.users.birthDate' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="birthDate">{{ 'mxk.users.birthDate' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid birthDate!">
-                    <input
-                      [(ngModel)]="form.model.birthDate"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="birthDate"
-                      id="birthDate"
-                    />
+                    <input [(ngModel)]="form.model.birthDate" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="birthDate" id="birthDate" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="preferredLanguage">{{ 'mxk.users.preferredLanguage' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="preferredLanguage">{{ 'mxk.users.preferredLanguage' |
+                    i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid preferredLanguage!">
-                    <input
-                      [(ngModel)]="form.model.preferredLanguage"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="preferredLanguage"
-                      id="preferredLanguage"
-                    />
+                    <input [(ngModel)]="form.model.preferredLanguage" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="preferredLanguage" id="preferredLanguage" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="startWorkDate">{{ 'mxk.users.startWorkDate' | i18n }}</nz-form-label>
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="startWorkDate">{{ 'mxk.users.startWorkDate' | i18n }}
+                  </nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid startWorkDate!">
-                    <input
-                      [(ngModel)]="form.model.startWorkDate"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="startWorkDate"
-                      id="startWorkDate"
-                    />
+                    <input [(ngModel)]="form.model.startWorkDate" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="startWorkDate" id="startWorkDate" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -283,19 +277,15 @@
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="webSite">{{ 'mxk.users.website' | i18n }}</nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid webSite!">
-                    <input [(ngModel)]="form.model.webSite" [ngModelOptions]="{ standalone: true }" nz-input name="webSite" id="webSite" />
+                    <input [(ngModel)]="form.model.webSite" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="webSite" id="webSite" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="defineIm">{{ 'mxk.users.ims' | i18n }}</nz-form-label>
                   <nz-form-control [nzSm]="16" [nzXs]="24" nzErrorTip="The input is not valid defineIm!">
-                    <input
-                      [(ngModel)]="form.model.defineIm"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="defineIm"
-                      id="defineIm"
-                    />
+                    <input [(ngModel)]="form.model.defineIm" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="defineIm" id="defineIm" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -303,168 +293,120 @@
             <nz-tab nzTitle="{{ 'mxk.users.tab.business' | i18n }}">
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="organization">{{ 'mxk.users.organization' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid organization!">
-                    <input
-                      [(ngModel)]="form.model.organization"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      readonly
-                      name="organization"
-                      id="organization"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="organization">{{ 'mxk.users.organization' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid organization!">
+                    <input [(ngModel)]="form.model.organization" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="organization" id="organization" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="division">{{ 'mxk.users.division' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid division!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.division"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="division"
-                      id="division"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="division">{{ 'mxk.users.division' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid division!">
+                    <input [(ngModel)]="form.model.division" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="division" id="division" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="departmentId">{{ 'mxk.users.departmentId' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid departmentId!">
-                    <input
-                      disabled="true"
-                      [(ngModel)]="form.model.departmentId"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="departmentId"
-                      id="departmentId"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="departmentId">{{ 'mxk.users.departmentId' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid departmentId!">
+                    <input [(ngModel)]="form.model.departmentId" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="departmentId" id="departmentId" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="department">{{ 'mxk.users.department' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid department!">
-                    <input
-                      disabled="true"
-                      [(ngModel)]="form.model.department"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="department"
-                      id="department"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="department">{{ 'mxk.users.department' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid department!">
+                    <input [(ngModel)]="form.model.department" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="department" id="department" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="costCenter">{{ 'mxk.users.costCenter' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid departmentId!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.costCenter"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="costCenter"
-                      id="costCenter"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="costCenter">{{ 'mxk.users.costCenter' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid departmentId!">
+                    <input [(ngModel)]="form.model.costCenter" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="costCenter" id="costCenter" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="jobLevel">{{ 'mxk.users.jobLevel' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid jobLevel!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.jobLevel"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="jobLevel"
-                      id="jobLevel"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="jobLevel">{{ 'mxk.users.jobLevel' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid jobLevel!">
+                    <input [(ngModel)]="form.model.jobLevel" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="jobLevel" id="jobLevel" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="jobTitle">{{ 'mxk.users.jobTitle' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid jobTitle!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.jobTitle"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="jobTitle"
-                      id="jobTitle"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="jobTitle">{{ 'mxk.users.jobTitle' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid jobTitle!">
+                    <input [(ngModel)]="form.model.jobTitle" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="jobTitle" id="jobTitle" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="manager">{{ 'mxk.users.manager' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid manager!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.manager"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="manager"
-                      id="manager"
-                    />
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid manager!">
+                    <input [(ngModel)]="form.model.manager" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="manager" id="manager" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="assistant">{{ 'mxk.users.assistant' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid assistant!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.assistant"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="assistant"
-                      id="assistant"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="assistant">{{ 'mxk.users.assistant' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid assistant!">
+                    <input [(ngModel)]="form.model.assistant" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="assistant" id="assistant" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workOfficeName">{{ 'mxk.users.workOfficeName' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid workOfficeName!">
-                    <input
-                      [(ngModel)]="form.model.workOfficeName"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="workOfficeName"
-                      id="workOfficeName"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workOfficeName">{{ 'mxk.users.workOfficeName' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid workOfficeName!">
+                    <input [(ngModel)]="form.model.workOfficeName" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="workOfficeName" id="workOfficeName" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="entryDate">{{ 'mxk.users.entryDate' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid entryDate!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.entryDate"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="entryDate"
-                      id="entryDate"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="entryDate">{{ 'mxk.users.entryDate' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid entryDate!">
+                    <input [(ngModel)]="form.model.entryDate" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="entryDate" id="entryDate" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="quitDate">{{ 'mxk.users.quitDate' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid quitDate!">
-                    <input
-                      readonly
-                      [(ngModel)]="form.model.quitDate"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="quitDate"
-                      id="quitDate"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="quitDate">{{ 'mxk.users.quitDate' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid quitDate!">
+                    <input [(ngModel)]="form.model.quitDate" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="quitDate" id="quitDate" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -472,93 +414,80 @@
             <nz-tab nzTitle="{{ 'mxk.users.tab.business.extra' | i18n }}">
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workPhoneNumber">{{ 'mxk.users.workPhoneNumber' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid workPhoneNumber!">
-                    <input
-                      [(ngModel)]="form.model.workPhoneNumber"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="workPhoneNumber"
-                      id="workPhoneNumber"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workPhoneNumber">{{ 'mxk.users.workPhoneNumber' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid workPhoneNumber!">
+                    <input [(ngModel)]="form.model.workPhoneNumber" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="workPhoneNumber" id="workPhoneNumber" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workEmail">{{ 'mxk.users.workEmail' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid workEmail!">
-                    <input
-                      [(ngModel)]="form.model.workEmail"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="workEmail"
-                      id="workEmail"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workEmail">{{ 'mxk.users.workEmail' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid workEmail!">
+                    <input [(ngModel)]="form.model.workEmail" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="workEmail" id="workEmail" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workCountry">{{ 'mxk.users.workCountry' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid workCountry!">
-                    <input
-                      [(ngModel)]="form.model.workCountry"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="workCountry"
-                      id="workCountry"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workCountry">{{ 'mxk.users.workCountry' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid workCountry!">
+                    <input [(ngModel)]="form.model.workCountry" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="workCountry" id="workCountry" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="region">{{ 'mxk.users.workRegion' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid region!">
-                    <input [(ngModel)]="form.model.workRegion" [ngModelOptions]="{ standalone: true }" nz-input name="region" id="region" />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="region">{{ 'mxk.users.workRegion' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid region!">
+                    <input [(ngModel)]="form.model.workRegion" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="region" id="region" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="locality">{{ 'mxk.users.workLocality' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid locality!">
-                    <input
-                      [(ngModel)]="form.model.workLocality"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="locality"
-                      id="locality"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="locality">{{ 'mxk.users.workLocality' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid locality!">
+                    <input [(ngModel)]="form.model.workLocality" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="locality" id="locality" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="street">{{ 'mxk.users.workStreetAddress' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid street!">
-                    <input
-                      [(ngModel)]="form.model.workStreetAddress"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="street"
-                      id="street"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="street">{{ 'mxk.users.workStreetAddress' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid street!">
+                    <input [(ngModel)]="form.model.workStreetAddress" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="street" id="street" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="postalCode">{{ 'mxk.users.workPostalCode' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid postalCode!">
-                    <input
-                      [(ngModel)]="form.model.workPostalCode"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="postalCode"
-                      id="postalCode"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="postalCode">{{ 'mxk.users.workPostalCode' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid postalCode!">
+                    <input [(ngModel)]="form.model.workPostalCode" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="postalCode" id="postalCode" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="workFax">{{ 'mxk.users.workFax' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid workFax!">
-                    <input [(ngModel)]="form.model.workFax" [ngModelOptions]="{ standalone: true }" nz-input name="workFax" id="workFax" />
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid workFax!">
+                    <input [(ngModel)]="form.model.workFax" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="workFax" id="workFax" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -566,93 +495,81 @@
             <nz-tab nzTitle="{{ 'mxk.users.tab.home' | i18n }}">
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeEmail">{{ 'mxk.users.homeEmail' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid homeEmail!">
-                    <input
-                      [(ngModel)]="form.model.homeEmail"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="homeEmail"
-                      id="homeEmail"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeEmail">{{ 'mxk.users.homeEmail' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid homeEmail!">
+                    <input [(ngModel)]="form.model.homeEmail" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="homeEmail" id="homeEmail" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homePhoneNumber">{{ 'mxk.users.homePhoneNumber' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid homePhoneNumber!">
-                    <input
-                      [(ngModel)]="form.model.homePhoneNumber"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="homePhoneNumber"
-                      id="homePhoneNumber"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homePhoneNumber">{{ 'mxk.users.homePhoneNumber' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid homePhoneNumber!">
+                    <input [(ngModel)]="form.model.homePhoneNumber" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="homePhoneNumber" id="homePhoneNumber" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
                   <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeFax">{{ 'mxk.users.homeFax' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid homeFax!">
-                    <input [(ngModel)]="form.model.homeFax" [ngModelOptions]="{ standalone: true }" nz-input name="homeFax" id="homeFax" />
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid homeFax!">
+                    <input [(ngModel)]="form.model.homeFax" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="homeFax" id="homeFax" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homePostalCode">{{ 'mxk.users.homePostalCode' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid postalCode!">
-                    <input
-                      [(ngModel)]="form.model.homePostalCode"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="homePostalCode"
-                      id="homePostalCode"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homePostalCode">{{ 'mxk.users.homePostalCode' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid postalCode!">
+                    <input [(ngModel)]="form.model.homePostalCode" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="homePostalCode" id="homePostalCode" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeCountry">{{ 'mxk.users.homeCountry' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid homeCountry!">
-                    <input
-                      [(ngModel)]="form.model.homeCountry"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="homeCountry"
-                      id="homeCountry"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeCountry">{{ 'mxk.users.homeCountry' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid homeCountry!">
+                    <input [(ngModel)]="form.model.homeCountry" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="homeCountry" id="homeCountry" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="region">{{ 'mxk.users.homeRegion' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid region!">
-                    <input [(ngModel)]="form.model.homeRegion" [ngModelOptions]="{ standalone: true }" nz-input name="region" id="region" />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="region">{{ 'mxk.users.homeRegion' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid region!">
+                    <input [(ngModel)]="form.model.homeRegion" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="region" id="region" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
               <div nz-row>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="locality">{{ 'mxk.users.homeLocality' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid locality!">
-                    <input
-                      [(ngModel)]="form.model.homeLocality"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="locality"
-                      id="locality"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="locality">{{ 'mxk.users.homeLocality' | i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid locality!">
+                    <input [(ngModel)]="form.model.homeLocality" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="locality" id="locality" />
                   </nz-form-control>
                 </nz-form-item>
                 <nz-form-item>
-                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeStreetAddress">{{ 'mxk.users.homeStreetAddress' | i18n }}</nz-form-label>
-                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48" nzErrorTip="The input is not valid street!">
-                    <input
-                      [(ngModel)]="form.model.homeStreetAddress"
-                      [ngModelOptions]="{ standalone: true }"
-                      nz-input
-                      name="street"
-                      id="street"
-                    />
+                  <nz-form-label [nzSm]="8" [nzXs]="24" nzFor="homeStreetAddress">{{ 'mxk.users.homeStreetAddress' |
+                    i18n }}
+                  </nz-form-label>
+                  <nz-form-control [nzSm]="16" [nzMd]="16" [nzXs]="36" [nzXl]="48"
+                    nzErrorTip="The input is not valid street!">
+                    <input [(ngModel)]="form.model.homeStreetAddress" [ngModelOptions]="{ standalone: true }" nz-input
+                      name="street" id="street" />
                   </nz-form-control>
                 </nz-form-item>
               </div>
@@ -671,4 +588,4 @@
     </div>
     <div nz-col nzMd="3"></div>
   </div>
-</nz-card>
+</nz-card>

+ 3 - 4
maxkey-web-frontend/maxkey-web-app/src/app/routes/config/profile/profile.component.ts

@@ -1,19 +1,18 @@
 /*
  * Copyright [2022] [MaxKey of copyright http://www.maxkey.top]
- * 
+ *
  * Licensed under the Apache License, Version 2.0 (the "License");
  * you may not use this file except in compliance with the License.
  * You may obtain a copy of the License at
- * 
+ *
  *     http://www.apache.org/licenses/LICENSE-2.0
- * 
+ *
  * Unless required by applicable law or agreed to in writing, software
  * distributed under the License is distributed on an "AS IS" BASIS,
  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
  * See the License for the specific language governing permissions and
  * limitations under the License.
  */
- 
 
 import { Component, ChangeDetectorRef, Input, OnInit } from '@angular/core';
 import { FormBuilder, FormGroup, Validators } from '@angular/forms';

+ 1 - 0
maxkey-web-frontend/maxkey-web-app/src/assets/i18n/en-US.json

@@ -153,6 +153,7 @@
       "status.lock":"Locked",
       "status.inactive":"Inactive",
       "status.delete":"Deleted",
+      "status.forbidden":"Forbidden",
       "userstate":"UserState",
       "userstate.resident":"Resident",
       "userstate.withdrawn":"Withdrawn",

+ 3 - 2
maxkey-web-frontend/maxkey-web-app/src/assets/i18n/zh-CN.json

@@ -50,8 +50,8 @@
       },
       "audit" : {
         "": "审计",
-        "logins": "登录日志",
-        "loginapps": "应用登录日志",
+        "logins": "系统登录日志",
+        "loginapps": "应用访问日志",
         "synchronizer": "同步器日志",
         "connector": "连接器日志",
         "operate": "管理日志"
@@ -157,6 +157,7 @@
       "status.lock":"锁定",
       "status.inactive":"不活动",
       "status.delete":"已删除",
+      "status.forbidden":"禁用",
       "userstate":"用户状态",
       "userstate.resident":"在职",
       "userstate.withdrawn":"离职",

+ 7 - 2
maxkey-web-frontend/maxkey-web-mgt-app/src/app/routes/accounts/accounts.component.html

@@ -75,7 +75,8 @@
         <td nzAlign="left" nzBreakWord="false">{{ data.relatedUsername }}</td>
         <td nzAlign="center">
           <i *ngIf="data.status == 1" nz-icon nzType="check-circle" nzTheme="fill" style="color: green"></i>
-          <i *ngIf="data.status == 2" nz-icon nzType="stop" nzTheme="fill" style="color: gray"></i>
+          <i *ngIf="data.status == 2" nz-icon nzType="warning" nzTheme="fill" style="color: gray"></i>
+          <i *ngIf="data.status == 4" nz-icon nzType="stop" nzTheme="fill" style="color: gray"></i>
         </td>
         <td nzAlign="left" nzBreakWord="false">
           <div nz-col>
@@ -83,7 +84,11 @@
               style="float: left">{{
               'mxk.text.enable' | i18n
               }}</button>
-            <button *ngIf="data.status == 1" nz-button type="button" (click)="onUpdateStatus($event, data.id, 2)"
+            <button *ngIf="data.status == 4" nz-button type="button" (click)="onUpdateStatus($event, data.id, 1)"
+              style="float: left">{{
+              'mxk.text.enable' | i18n
+              }}</button>
+            <button *ngIf="data.status == 1" nz-button type="button" (click)="onUpdateStatus($event, data.id, 4)"
               style="float: left">{{
               'mxk.text.disable' | i18n
               }}</button>

+ 1 - 0
maxkey-web-frontend/maxkey-web-mgt-app/src/app/routes/users/user-editer/user-editer.component.html

@@ -164,6 +164,7 @@
                 id="status">
                 <nz-option nzValue="1" nzLabel="{{ 'mxk.users.status.active' | i18n }}"></nz-option>
                 <nz-option nzValue="2" nzLabel="{{ 'mxk.users.status.inactive' | i18n }}"></nz-option>
+                <nz-option nzValue="4" nzLabel="{{ 'mxk.users.status.forbidden' | i18n }}"></nz-option>
                 <nz-option nzValue="5" nzLabel="{{ 'mxk.users.status.lock' | i18n }}"></nz-option>
                 <nz-option nzValue="9" nzLabel="{{ 'mxk.users.status.delete' | i18n }}"></nz-option>
               </nz-select>

+ 6 - 2
maxkey-web-frontend/maxkey-web-mgt-app/src/app/routes/users/users.component.html

@@ -95,7 +95,8 @@
               i18n) }}</td>
             <td nzAlign="center">
               <i *ngIf="data.status == 1" nz-icon nzType="check-circle" nzTheme="fill" style="color: green"> </i>
-              <i *ngIf="data.status == 2" nz-icon nzType="stop" nzTheme="fill" style="color: gray"></i>
+              <i *ngIf="data.status == 2" nz-icon nzType="warning" nzTheme="fill" style="color: gray"></i>
+              <i *ngIf="data.status == 4" nz-icon nzType="stop" nzTheme="fill" style="color: gray"></i>
               <i *ngIf="data.status == 5" nz-icon nzType="lock" nzTheme="fill" style="color: orange"></i>
               <i *ngIf="data.status == 9" nz-icon nzType="close-circle" nzTheme="fill" style="color: red"></i>
             </td>
@@ -127,12 +128,15 @@
                       }}</li>
                     <li nz-menu-item *ngIf="data.status == 1" (click)="onUpdateStatus($event, data.id, 5)">{{
                       'mxk.text.lock' | i18n }}</li>
-                    <li nz-menu-item *ngIf="data.status == 1" (click)="onUpdateStatus($event, data.id, 2)">{{
+                    <li nz-menu-item *ngIf="data.status == 1" (click)="onUpdateStatus($event, data.id, 4)">{{
                       'mxk.text.disable' | i18n
                       }}</li>
                     <li nz-menu-item *ngIf="data.status == 2" (click)="onUpdateStatus($event, data.id, 1)">{{
                       'mxk.text.enable' | i18n
                       }}</li>
+                    <li nz-menu-item *ngIf="data.status == 4" (click)="onUpdateStatus($event, data.id, 1)">{{
+                      'mxk.text.enable' | i18n
+                      }}</li>
                     <li nz-menu-item *ngIf="data.status == 5" (click)="onUpdateStatus($event, data.id, 1)">{{
                       'mxk.text.unlock' | i18n
                       }}</li>

+ 1 - 0
maxkey-web-frontend/maxkey-web-mgt-app/src/assets/i18n/en-US.json

@@ -163,6 +163,7 @@
       "status.lock":"Locked",
       "status.inactive":"Inactive",
       "status.delete":"Deleted",
+      "status.forbidden":"Forbidden",
       "userstate":"UserState",
       "userstate.resident":"Resident",
       "userstate.withdrawn":"Withdrawn",

+ 1 - 0
maxkey-web-frontend/maxkey-web-mgt-app/src/assets/i18n/zh-CN.json

@@ -162,6 +162,7 @@
       "status.active":"活动",
       "status.lock":"锁定",
       "status.inactive":"不活动",
+      "status.forbidden":"禁用",
       "status.delete":"已删除",
       "userstate":"用户状态",
       "userstate.resident":"在职",

+ 5 - 0
maxkey-web-frontend/maxkey-web-mgt-app/src/style-icons-auto.ts

@@ -33,6 +33,7 @@ import {
   CloudOutline,
   CopyrightOutline,
   CustomerServiceOutline,
+  ClockCircleFill,
   DashboardOutline,
   DatabaseOutline,
   DingdingOutline,
@@ -103,6 +104,7 @@ import {
   SendOutline,
   SmallDashOutline,
   DashOutline,
+  WarningFill,
   FileProtectOutline,
   HistoryOutline,
   AuditOutline
@@ -118,6 +120,8 @@ export const ICONS_AUTO = [
   BorderRightOutline,
   CloudOutline,
   CopyrightOutline,
+  ClockCircleFill,
+
   CustomerServiceOutline,
   DashboardOutline,
   DatabaseOutline,
@@ -194,5 +198,6 @@ export const ICONS_AUTO = [
   DashOutline,
   FileProtectOutline,
   HistoryOutline,
+  WarningFill,
   AuditOutline
 ];

+ 7 - 0
maxkey-webs/maxkey-web-mgt/src/main/java/org/maxkey/web/contorller/AccountsController.java

@@ -137,7 +137,14 @@ public class AccountsController {
 	@ResponseBody
 	public ResponseEntity<?> updateStatus(@ModelAttribute Accounts accounts,@CurrentUser UserInfo currentUser) {
 		_logger.debug(""+accounts);
+		Accounts loadAccount = accountsService.get(accounts.getId());
 		accounts.setInstId(currentUser.getInstId());
+		accounts.setAppId(loadAccount.getAppId());
+		accounts.setAppName(loadAccount.getAppName());
+		accounts.setUserId(loadAccount.getUserId());
+		accounts.setUsername(loadAccount.getUsername());
+		accounts.setDisplayName(loadAccount.getDisplayName());
+		accounts.setRelatedUsername(loadAccount.getRelatedUsername());
 		if (accountsService.updateStatus(accounts)) {
 			systemLog.insert(
 					ConstsEntryType.ACCOUNT, 

+ 3 - 0
maxkey-webs/maxkey-web-mgt/src/main/java/org/maxkey/web/contorller/UserInfoController.java

@@ -238,7 +238,10 @@ public class UserInfoController {
 	@ResponseBody
 	public ResponseEntity<?> updateStatus(@ModelAttribute UserInfo userInfo,@CurrentUser UserInfo currentUser) {
 		_logger.debug(""+userInfo);
+		UserInfo loadUserInfo = userInfoService.get(userInfo.getId());
 		userInfo.setInstId(currentUser.getInstId());
+		userInfo.setUsername(loadUserInfo.getUsername());
+		userInfo.setDisplayName(loadUserInfo.getDisplayName());
 		if(userInfoService.updateStatus(userInfo)) {
 			systemLog.insert(
 					ConstsEntryType.USERINFO,