uis
This commit is contained in:
parent
8f13725240
commit
b1fc833bb9
|
@ -30,6 +30,7 @@
|
|||
</tr>
|
||||
</table>
|
||||
<div class="card-footer bg-secondary py-1">
|
||||
<button class="btn btn-sm btn-outline-primary" data-toggle="modal" data-target="#addNewConflictModal" ng-click="prepareAddConflictModal(w)">add</button>
|
||||
<button type="button"
|
||||
class="btn btn-sm btn-primary"
|
||||
data-toggle="modal" data-target="#resolveConflictsModal"
|
||||
|
@ -38,3 +39,6 @@
|
|||
</div>
|
||||
|
||||
<resolve-conflicts-modal modal-id="resolveConflictsModal" orgs="orgs" selected-orgs="selectedOrgs"></resolve-conflicts-modal>
|
||||
|
||||
<select-org-modal modal-id="addNewConflictModal" selected-org="newConflict" filter-status="approved" on-select="addConflict()"></select-org-modal>
|
||||
|
||||
|
|
|
@ -20,10 +20,12 @@
|
|||
</tr>
|
||||
</table>
|
||||
|
||||
<div class="card-footer bg-secondary py-1" ng-if="showSaveButton && conflicts.length > 0">
|
||||
<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#resolveConflictsModal" ng-click="prepareConflictsModal()">resolve conflicts</button>
|
||||
<div class="card-footer bg-secondary py-1">
|
||||
<button class="btn btn-sm btn-outline-primary" data-toggle="modal" data-target="#addConflictModal">add</button>
|
||||
<button class="btn btn-sm btn-primary" data-toggle="modal" data-target="#resolveConflictsModal" ng-click="prepareConflictsModal()" ng-if="showSaveButton && conflicts.length > 0">resolve conflicts</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<resolve-conflicts-modal modal-id="resolveConflictsModal" orgs="candidateConflicts" selected-orgs="selectedConflicts"></resolve-conflicts-modal>
|
||||
|
||||
<select-org-modal modal-id="addConflictModal" selected-org="newConflict" filter-status="approved" on-select="addConflict()"></select-org-modal>
|
||||
|
|
|
@ -311,6 +311,17 @@ orgsModule.directive('orgConflicts', function($http, $location, $route, $q) {
|
|||
link: function(scope, element, attrs, ctrl) {
|
||||
scope.candidateConflicts = [];
|
||||
scope.selectedConflicts = [];
|
||||
scope.newConflict = {};
|
||||
|
||||
scope.addConflict = function() {
|
||||
scope.conflicts.push({
|
||||
'id' : scope.newConflict.id,
|
||||
'name' : scope.newConflict.name,
|
||||
'type' : scope.newConflict.type,
|
||||
'city' : scope.newConflict.city,
|
||||
'country': scope.newConflict.country
|
||||
});
|
||||
}
|
||||
|
||||
scope.prepareConflictsModal = function() {
|
||||
scope.candidateConflicts = [];
|
||||
|
@ -708,6 +719,22 @@ orgsModule.controller('conflictsCtrl', function ($scope, $http, $routeParams, $l
|
|||
$scope.conflicts = [];
|
||||
$scope.country = $routeParams.country;
|
||||
$scope.orgs = [];
|
||||
$scope.newConflict = {};
|
||||
$scope.currentGroup = [];
|
||||
|
||||
$scope.addConflict = function() {
|
||||
$scope.currentGroup.push({
|
||||
'id' : $scope.newConflict.id,
|
||||
'name' : $scope.newConflict.name,
|
||||
'type' : $scope.newConflict.type,
|
||||
'city' : $scope.newConflict.city,
|
||||
'country': $scope.newConflict.country
|
||||
});
|
||||
}
|
||||
|
||||
$scope.prepareAddConflictModal = function(list) {
|
||||
$scope.currentGroup = list;
|
||||
};
|
||||
|
||||
$scope.prepareConflictsModal = function(list) {
|
||||
$scope.orgs = [];
|
||||
|
|
Loading…
Reference in New Issue