Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- {
- firstname:"Sameer"
- isActive:true
- lastname:"Mohamed"
- password:"$2a$10$i5Or69.1qRKN8.PSzybkc.2D2fPfGJCf9gwfjpE1JAF4rFUmpbC8i"
- role:"client"
- username:"ganesh"
- }
- input#Active(type='radio', value='1', ng-model='editClientData.isActive') Active
- input#Inactive(type='radio', value='0', ng-model='editClientData.isActive') Block
- table.table
- tr(style='font-size:14px;')
- th(style='display : none;') S.no
- th User Name
- th First Name
- th Role
- th Status
- th Operations
- tr(style='font-size:14px;' ng-repeat='admin in admins | filter:test' ng-if="admin.role === 'client'")
- td(style='display : none;') {{$index+1}}
- td {{admin.username}}
- td {{admin.firstname}}
- td {{admin.role}}
- td {{true == admin.isActive ? 'Active' : 'Blocked' }}
- td
- a(ng-click='editClient(admins[$index])',data-toggle='modal', data-target='#editClientModal')
- i.fa.fa-pencil
- #editClientModal.modal.fade(tabindex='-1', role='dialog', aria-labelledby='myModalLabel', aria-hidden='true')
- .modal-dialog(role='document')
- .modal-content
- .modal-header
- button.modal-close(type='button', data-dismiss='modal', aria-label='Close')
- i.font-icon-close-2
- h4#myModalLabel.modal-title Edit Client
- .modal-body
- .form-group
- label Username
- input.form-control(type='text', placeholder='',ng-model='editClientData.username')
- .form-group
- label Firstname
- input.form-control(type='text', placeholder='',ng-model='editClientData.firstname')
- .form-group
- label Lastname
- input.form-control(type='text', placeholder='',ng-model='editClientData.lastname')
- .form-group
- span.control-label Status
- span.text-danger *
- |
- input#Active(type='radio', value='1', ng-model='editClientData.isActive')
- span(for='Active') Active
- |
- input#Inactive(type='radio', value='0', ng-model='editClientData.isActive')
- span(for='Inactive') Block
- // get admins
- $http({
- method: 'GET',
- url: '/api/getadmins'
- }).then(function (response) {
- $scope.admins = response.data;
- }, function (response) {
- window.location.href = '/';
- });
Add Comment
Please, Sign In to add comment