电子档案
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

93 lines
4.5 KiB

  1. <div class="modal" ng-controller="IdmCreateUserPopupController">
  2. <div class="modal-dialog">
  3. <div class="modal-content">
  4. <div class="modal-header-wrapper">
  5. <div class="modal-header">
  6. <button type="button" class="close" ng-click="$hide()">&times;</button>
  7. <h2 class="modal-title" ng-if="model.mode == 'create'">
  8. {{'IDM.USER-MGMT.POPUP.CREATE-TITLE' | translate}}
  9. </h2>
  10. <h2 class="modal-title" ng-if="model.mode == 'edit'">
  11. {{'IDM.USER-MGMT.POPUP.EDIT-TITLE' | translate}}
  12. </h2>
  13. </div>
  14. </div>
  15. <div class="modal-body">
  16. <form name="newUserForm" class="row">
  17. <div class="col-xs-12" ng-if="model.mode == 'create'">
  18. <div class="form-group">
  19. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-ID' | translate}}</label>
  20. <input name="idInput" type="text" class="form-control" auto-focus ng-model="model.user.id">
  21. </div>
  22. </div>
  23. <div class="col-xs-12">
  24. <div class="form-group">
  25. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-EMAIL' | translate}}</label>
  26. <span style="color:white; background-color: red; padding: 0 5px 0 5px" ng-show="newUserForm.emailInput.$error.email">
  27. {{'IDM.USER-MGMT.POPUP.CREATE-INVALID-EMAIL' | translate}}
  28. </span>
  29. <input name="emailInput" type="email" class="form-control" ng-model="model.user.email">
  30. </div>
  31. </div>
  32. <div class="col-xs-12" ng-if="model.mode == 'create'">
  33. <div class="form-group">
  34. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-PASSWORD' | translate}}</label>
  35. <input type="password" class="form-control" ng-model="model.user.password">
  36. </div>
  37. </div>
  38. <div class="col-xs-6">
  39. <div class="form-group">
  40. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-FIRSTNAME' | translate}}</label>
  41. <input type="text" class="form-control" ng-model="model.user.firstName">
  42. </div>
  43. </div>
  44. <div class="col-xs-6">
  45. <div class="form-group">
  46. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-LASTNAME' | translate}}</label>
  47. <input type="text" class="form-control" ng-model="model.user.lastName">
  48. </div>
  49. </div>
  50. <div class="col-xs-12">
  51. <div class="form-group">
  52. <label class="control-label">{{'IDM.USER-MGMT.POPUP.CREATE-TENANT' | translate}}</label>
  53. <input type="text" class="form-control" ng-model="model.user.tenantId">
  54. </div>
  55. </div>
  56. </form>
  57. <div class="alert error" ng-if="model.errorMessage">
  58. {{model.errorMessage}}
  59. </div>
  60. </div>
  61. <div class="modal-footer-wrapper">
  62. <div class="modal-footer">
  63. <button type="button" class="btn btn-default" ng-click="$hide()">{{'IDM.GENERAL.ACTION.CANCEL' | translate}}</button>
  64. <button ng-if="model.mode == 'create'"
  65. type="button"
  66. class="btn btn-primary"
  67. ng-disabled="model.loading || !model.user.id || !model.user.password || !model.user.firstName"
  68. ng-click="createNewUser();">{{'IDM.GENERAL.ACTION.SAVE' | translate}}
  69. </button>
  70. <button ng-if="model.mode == 'edit'"
  71. type="button"
  72. class="btn btn-primary"
  73. ng-disabled="model.loading || !model.user.id || !model.user.lastName"
  74. ng-click="editUserDetails();">{{'IDM.GENERAL.ACTION.SAVE' | translate}}
  75. </button>
  76. </div>
  77. </div>
  78. </div>
  79. </div>
  80. </div>