Commit 48ed0c7bb0a12432d10414ec40aaf50262eb4ade
1 parent
b1f6160d4d
Exists in
master
update company code implemented
Showing
3 changed files
with
86 additions
and
21 deletions
Show diff stats
app/partials/viewCompany/viewCompany.controller.js
1 | 1 | ||
2 | 'use strict'; | 2 | 'use strict'; |
3 | 3 | ||
4 | //Load controller | 4 | //Load controller |
5 | angular.module('acufuel') | 5 | angular.module('acufuel') |
6 | 6 | ||
7 | .controller('viewCompanyController', ['$scope','$uibModal', '$stateParams', 'ViewCompanyService', 'CustomersService', function($scope , $uibModal, $stateParams, ViewCompanyService, CustomersService) { | 7 | .controller('viewCompanyController', ['$scope','$uibModal', '$stateParams', 'ViewCompanyService', 'CustomersService', function($scope , $uibModal, $stateParams, ViewCompanyService, CustomersService) { |
8 | $scope.data = {}; | 8 | $scope.data = {}; |
9 | $scope.data.priceEmail = true; | 9 | $scope.data.priceEmail = true; |
10 | $scope.aircraft = {}; | 10 | $scope.aircraft = {}; |
11 | // $scope.open = function(){ | 11 | // $scope.open = function(){ |
12 | // $scope.editSmsModal = $uibModal.open({ | 12 | // $scope.editSmsModal = $uibModal.open({ |
13 | // templateUrl: 'partials/NewCompany/NewCompany.html', | 13 | // templateUrl: 'partials/NewCompany/NewCompany.html', |
14 | // backdrop: true, | 14 | // backdrop: true, |
15 | // scope: $scope, | 15 | // scope: $scope, |
16 | // }) | 16 | // }) |
17 | // } | 17 | // } |
18 | 18 | ||
19 | $(function() { | 19 | $(function() { |
20 | $('#toggle-one2').bootstrapToggle(); | 20 | $('#company-one2').bootstrapToggle(); |
21 | }) | 21 | }) |
22 | 22 | ||
23 | $(function() { | 23 | $(function() { |
24 | $('#toggle-one1').bootstrapToggle(); | 24 | $('#toggle-one1').bootstrapToggle(); |
25 | }) | 25 | }) |
26 | $(function() { | 26 | $(function() { |
27 | $('#toggle-two').bootstrapToggle(); | 27 | $('#toggle-two').bootstrapToggle(); |
28 | }) | 28 | }) |
29 | $(function() { | 29 | $(function() { |
30 | $('#toggle-three').bootstrapToggle(); | 30 | $('#toggle-three').bootstrapToggle(); |
31 | }) | 31 | }) |
32 | $(function() { | 32 | $(function() { |
33 | $('#toggle-four').bootstrapToggle(); | 33 | $('#toggle-four').bootstrapToggle(); |
34 | }) | 34 | }) |
35 | 35 | ||
36 | $(function() { | 36 | $(function() { |
37 | $('#price-one2').bootstrapToggle(); | 37 | $('#price-one2').bootstrapToggle(); |
38 | $('#price-one2').change(function() { | 38 | $('#price-one2').change(function() { |
39 | $('#console-event').html('Toggle: ' + $(this).prop('checked')); | 39 | $('#console-event').html('Toggle: ' + $(this).prop('checked')); |
40 | $scope.data.priceEmail = $(this).prop('checked'); | 40 | $scope.data.priceEmail = $(this).prop('checked'); |
41 | }) | 41 | }) |
42 | }) | 42 | }) |
43 | 43 | ||
44 | var value = ""; | ||
44 | var companyId = $stateParams.id; | 45 | var companyId = $stateParams.id; |
45 | ViewCompanyService.getCompany(companyId).then(function(result) { | 46 | ViewCompanyService.getCompany(companyId).then(function(result) { |
46 | $scope.companyData = result; | 47 | $scope.companyData = result; |
48 | if($scope.companyData.activate == true){ | ||
49 | value = 'on'; | ||
50 | }else{ | ||
51 | value = 'off' | ||
52 | } | ||
53 | $('#company-one2').bootstrapToggle(value) | ||
47 | }) | 54 | }) |
48 | 55 | ||
49 | ViewCompanyService.getContact(companyId).then(function(result) { | 56 | getContactList(); |
50 | $scope.companyContactList = result; | 57 | function getContactList(){ |
51 | }) | 58 | ViewCompanyService.getContact(companyId).then(function(result) { |
59 | $scope.companyContactList = result; | ||
60 | }) | ||
61 | } | ||
52 | 62 | ||
53 | getAircraftList(); | 63 | getAircraftList(); |
54 | function getAircraftList(){ | 64 | function getAircraftList(){ |
55 | ViewCompanyService.getAircraft(companyId).then(function(result) { | 65 | ViewCompanyService.getAircraft(companyId).then(function(result) { |
56 | $scope.contactAircraftList = result; | 66 | $scope.contactAircraftList = result; |
57 | }) | 67 | }) |
58 | } | 68 | } |
59 | 69 | ||
60 | 70 | ||
61 | $scope.contactData = {}; | 71 | $scope.contactData = {}; |
62 | $scope.contactData.contactList = []; | 72 | $scope.contactData.contactList = []; |
63 | $scope.addContact = function(){ | 73 | $scope.addContact = function(){ |
64 | $scope.data.companyId = companyId; | 74 | $scope.data.companyId = companyId; |
65 | $scope.contactData.contactList.push($scope.data); | 75 | $scope.contactData.contactList.push($scope.data); |
66 | ViewCompanyService.addContact($scope.contactData).then(function(result) { | 76 | ViewCompanyService.addContact($scope.contactData).then(function(result) { |
67 | if(result.success){ | 77 | if(result.success){ |
68 | toastr.success(''+result.success+'', { | 78 | toastr.success(''+result.success+'', { |
69 | closeButton: true | 79 | closeButton: true |
70 | }) | 80 | }) |
71 | $('#contact-modal-3').modal('hide'); | 81 | $('#contact-modal-3').modal('hide'); |
82 | getContactList(); | ||
72 | }else{ | 83 | }else{ |
73 | toastr.error(''+result.statusText+'', { | 84 | toastr.error(''+result.statusText+'', { |
74 | closeButton: true | 85 | closeButton: true |
75 | }) | 86 | }) |
76 | } | 87 | } |
77 | }) | 88 | }) |
78 | } | 89 | } |
79 | 90 | ||
80 | getData(); | 91 | getData(); |
81 | function getData(){ | 92 | function getData(){ |
82 | CustomersService.getAircraftMake().then(function(result) { | 93 | CustomersService.getAircraftMake().then(function(result) { |
83 | $scope.aircraftMakeList = result; | 94 | $scope.aircraftMakeList = result; |
84 | }) | 95 | }) |
85 | } | 96 | } |
86 | 97 | ||
87 | $scope.aircraftDetails = [{ | 98 | $scope.aircraftDetails = [{ |
88 | 'tail':'', | 99 | 'tail':'', |
89 | 'make': '', | 100 | 'make': '', |
90 | 'model': '', | 101 | 'model': '', |
91 | 'size' : '' | 102 | 'size' : '' |
92 | }]; | 103 | }]; |
93 | 104 | ||
94 | $scope.addNew = function(){ | 105 | $scope.addNew = function(){ |
95 | $scope.aircraftDetails.push({ | 106 | $scope.aircraftDetails.push({ |
96 | 'tail':'', | 107 | 'tail':'', |
97 | 'make': '', | 108 | 'make': '', |
98 | 'model': '', | 109 | 'model': '', |
99 | 'size' : '' | 110 | 'size' : '' |
100 | }); | 111 | }); |
101 | }; | 112 | }; |
102 | 113 | ||
103 | $scope.getModal = function(makeId, index){ | 114 | $scope.getModal = function(makeId, index){ |
104 | $scope.aircraft.make = makeId; | 115 | $scope.aircraft.make = makeId; |
105 | //var makeId = makeId; | 116 | //var makeId = makeId; |
106 | CustomersService.getModal($scope.aircraft.make).then(function(result) { | 117 | CustomersService.getModal($scope.aircraft.make).then(function(result) { |
107 | $scope.aircraftDetails[index].aircraftModalList = result; | 118 | $scope.aircraftDetails[index].aircraftModalList = result; |
108 | //$scope.aircraftDetails[index].model = $scope.aircraftModalList[0]; | 119 | //$scope.aircraftDetails[index].model = $scope.aircraftModalList[0]; |
109 | }) | 120 | }) |
110 | } | 121 | } |
111 | 122 | ||
112 | $scope.getSize = function(model, index){ | 123 | $scope.getSize = function(model, index){ |
113 | CustomersService.getAircraftSize($scope.aircraft.make, model).then(function(result) { | 124 | CustomersService.getAircraftSize($scope.aircraft.make, model).then(function(result) { |
114 | $scope.aircraftDetails[index].aircraftSizeList = result; | 125 | $scope.aircraftDetails[index].aircraftSizeList = result; |
115 | //$scope.aircraftDetails[index].size = $scope.aircraftSizeList[0]; | 126 | //$scope.aircraftDetails[index].size = $scope.aircraftSizeList[0]; |
116 | }) | 127 | }) |
117 | } | 128 | } |
118 | 129 | ||
119 | $scope.aircraftListData = {}; | 130 | $scope.aircraftListData = {}; |
120 | $scope.addData = []; | 131 | $scope.addData = []; |
121 | $scope.saveCompanyData = function(){ | 132 | $scope.saveCompanyData = function(){ |
122 | for(var i=0; i<$scope.aircraftDetails.length;i++){ | 133 | for(var i=0; i<$scope.aircraftDetails.length;i++){ |
123 | $scope.addData.push({ | 134 | $scope.addData.push({ |
124 | 'tail': $scope.aircraftDetails[i].tail, | 135 | 'tail': $scope.aircraftDetails[i].tail, |
125 | 'make': $scope.aircraftDetails[i].make, | 136 | 'make': $scope.aircraftDetails[i].make, |
126 | 'model': $scope.aircraftDetails[i].model, | 137 | 'model': $scope.aircraftDetails[i].model, |
127 | 'size' : $scope.aircraftDetails[i].size | 138 | 'size' : $scope.aircraftDetails[i].size |
128 | }); | 139 | }); |
129 | } | 140 | } |
130 | $scope.aircraftListData.aircraftList = $scope.addData; | 141 | $scope.aircraftListData.aircraftList = $scope.addData; |
131 | $scope.aircraftListData.accountId = companyId; | 142 | $scope.aircraftListData.accountId = companyId; |
132 | 143 | ||
133 | CustomersService.addAircraft($scope.aircraftListData).then(function(result) { | 144 | CustomersService.addAircraft($scope.aircraftListData).then(function(result) { |
134 | if(result != null && result.success){ | 145 | if(result != null && result.success){ |
135 | toastr.success(''+result.success+'', { | 146 | toastr.success(''+result.success+'', { |
136 | closeButton: true | 147 | closeButton: true |
137 | }) | 148 | }) |
138 | $('#aircraft-modal-3').modal('hide'); | 149 | $('#aircraft-modal-3').modal('hide'); |
139 | getAircraftList(); | 150 | getAircraftList(); |
140 | }else{ | 151 | }else{ |
141 | toastr.error(''+result.statusText+'', { | 152 | toastr.error(''+result.statusText+'', { |
142 | closeButton: true | 153 | closeButton: true |
143 | }) | 154 | }) |
144 | } | 155 | } |
145 | }); | 156 | }); |
146 | 157 | ||
147 | } | 158 | } |
148 | $scope.showNoteData = true; | 159 | $scope.showNoteData = true; |
149 | $scope.showCompanyName = true; | 160 | $scope.showCompanyName = true; |
161 | $scope.showAddress = true; | ||
150 | $scope.showNote = function(){ | 162 | $scope.showNote = function(){ |
151 | $scope.showNoteData = false; | 163 | $scope.showNoteData = false; |
152 | } | 164 | } |
153 | 165 | ||
154 | $scope.company = function(){ | 166 | $scope.company = function(){ |
155 | $scope.showCompanyName = false; | 167 | $scope.showCompanyName = false; |
156 | } | 168 | } |
157 | 169 | ||
170 | $scope.addressChange = function(){ | ||
171 | $scope.showAddress = false; | ||
172 | } | ||
173 | |||
158 | $scope.editData = function(inputName) { | 174 | $scope.editData = function(inputName) { |
175 | console.log($scope.companyData) | ||
159 | if(inputName == 'showNoteData'){ | 176 | if(inputName == 'showNoteData'){ |
160 | $scope.showNoteData = true; | 177 | $scope.showNoteData = true; |
161 | }else if(inputName == 'showCompanyName'){ | 178 | }else if(inputName == 'showCompanyName'){ |
162 | $scope.showCompanyName = true; | 179 | $scope.showCompanyName = true; |
180 | }else if(inputName == 'showAddress'){ | ||
181 | $scope.showAddress = true; | ||
163 | } | 182 | } |
183 | |||
184 | var companyData = "companyName=" + $scope.companyData.companyName + "&masterMargin=" + $scope.companyData.masterMargin | ||
185 | + "&addressOne=" + $scope.companyData.addressOne + "&addressTwo=" + $scope.companyData.addressTwo + "&city=" + $scope.companyData.city + "&state=" | ||
186 | + $scope.companyData.state + "&country=" + $scope.companyData.country + "&zipcode=" + $scope.companyData.zipcode + "&internalNote=" | ||
187 | + $scope.companyData.internalNote + "&certificateType=" + $scope.companyData.certificateType + "&baseTenant=" + $scope.companyData.baseTenant | ||
188 | + "&fuelerlinxCustomer=" + $scope.companyData.fuelerlinxCustomer + "&contractFuelVendor=" + $scope.companyData.contractFuelVendor | ||
189 | + "&activate=" + $scope.companyData.activate + "&baseIcao=" + $scope.companyData.baseIcao + "&companyId=" + companyId; | ||
190 | |||
191 | ViewCompanyService.updateContact(companyData).then(function(result) { | ||
192 | if(result != null && result.success){ | ||
193 | toastr.success(''+result.success+'', { | ||
194 | closeButton: true | ||
195 | }) | ||
196 | }else{ | ||
197 | toastr.error(''+result.statusText+'', { | ||
198 | closeButton: true | ||
199 | }) | ||
200 | } | ||
201 | }) | ||
164 | 202 | ||
165 | } | 203 | } |
166 | 204 | ||
167 | }]); | 205 | }]); |
app/partials/viewCompany/viewCompany.html
1 | <style> | 1 | <style> |
2 | .subnavbar .mainnav > li:nth-child(3) > a{ | 2 | .subnavbar .mainnav > li:nth-child(3) > a{ |
3 | color: #ff9900; | 3 | color: #ff9900; |
4 | } | 4 | } |
5 | .widget-content{ | 5 | .widget-content{ |
6 | padding: 10px !important; | 6 | padding: 10px !important; |
7 | } | 7 | } |
8 | .widget-content input[type="text"], .widget-content select{ | 8 | .widget-content input[type="text"], .widget-content select{ |
9 | height: 31px; | 9 | height: 31px; |
10 | padding: 0; | 10 | padding: 0; |
11 | } | 11 | } |
12 | .new-label span{ | 12 | .new-label span{ |
13 | float: left; | 13 | float: left; |
14 | line-height: 31px; | 14 | line-height: 31px; |
15 | } | 15 | } |
16 | .new-label span:first-child{ | 16 | .new-label span:first-child{ |
17 | margin-right: 5px; | 17 | margin-right: 5px; |
18 | font-weight: bold; | 18 | font-weight: bold; |
19 | } | 19 | } |
20 | .new-label span:last-child{ | 20 | .new-label span:last-child{ |
21 | margin-left: 5px; | 21 | margin-left: 5px; |
22 | } | 22 | } |
23 | .new-label select{ | 23 | .new-label select{ |
24 | display: -webkit-inline-box; | 24 | display: -webkit-inline-box; |
25 | display: inline-box; | 25 | display: inline-box; |
26 | float: left; | 26 | float: left; |
27 | } | 27 | } |
28 | .new-address p{ | 28 | .new-address p{ |
29 | margin-bottom: 0; | 29 | margin-bottom: 0; |
30 | } | 30 | } |
31 | .new-add-select{ | 31 | .new-add-select{ |
32 | padding-left: 15px; | 32 | padding-left: 15px; |
33 | margin: 10px 0; | 33 | margin: 10px 0; |
34 | } | 34 | } |
35 | .new-add-select select{ | 35 | .new-add-select select{ |
36 | width: 100px; | 36 | width: 100px; |
37 | } | 37 | } |
38 | .widget{ | 38 | .widget{ |
39 | -moz-box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); | 39 | -moz-box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); |
40 | -webkit-box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); | 40 | -webkit-box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); |
41 | box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); | 41 | box-shadow: 0px 3px 8px rgba(100,100,100, 0.7); |
42 | } | 42 | } |
43 | .optionclass { | 43 | .optionclass { |
44 | background: #fff; | 44 | background: #fff; |
45 | } | 45 | } |
46 | .timess { | 46 | .timess { |
47 | float: right !important; | 47 | float: right !important; |
48 | margin-top: 10px !important; | 48 | margin-top: 10px !important; |
49 | margin-right: 10px !important; | 49 | margin-right: 10px !important; |
50 | color: #999 !important; | 50 | color: #999 !important; |
51 | cursor: pointer !important; | 51 | cursor: pointer !important; |
52 | } | 52 | } |
53 | 53 | ||
54 | .button1 { | 54 | .button1 { |
55 | display: inline-block; | 55 | display: inline-block; |
56 | height: 35px; | 56 | height: 35px; |
57 | line-height: 35px; | 57 | line-height: 35px; |
58 | padding-right: 15px; | 58 | padding-right: 15px; |
59 | padding-left: 50px; | 59 | padding-left: 50px; |
60 | position: relative; | 60 | position: relative; |
61 | background-color:rgb(41,127,184); | 61 | background-color:rgb(41,127,184); |
62 | color:rgb(255,255,255); | 62 | color:rgb(255,255,255); |
63 | text-decoration: none; | 63 | text-decoration: none; |
64 | text-transform: uppercase; | 64 | text-transform: uppercase; |
65 | letter-spacing: 1px; | 65 | letter-spacing: 1px; |
66 | margin-bottom: 15px; | 66 | margin-bottom: 15px; |
67 | border: 0; | 67 | border: 0; |
68 | 68 | ||
69 | 69 | ||
70 | border-radius: 5px; | 70 | border-radius: 5px; |
71 | -moz-border-radius: 5px; | 71 | -moz-border-radius: 5px; |
72 | -webkit-border-radius: 5px; | 72 | -webkit-border-radius: 5px; |
73 | text-shadow:0px 1px 0px rgba(0,0,0,0.5); | 73 | text-shadow:0px 1px 0px rgba(0,0,0,0.5); |
74 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ff123852,Positive=true)";zoom:1; | 74 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ff123852,Positive=true)";zoom:1; |
75 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ff123852,Positive=true); | 75 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ff123852,Positive=true); |
76 | 76 | ||
77 | -moz-box-shadow:0px 2px 2px rgba(0,0,0,0.2); | 77 | -moz-box-shadow:0px 2px 2px rgba(0,0,0,0.2); |
78 | -webkit-box-shadow:0px 2px 2px rgba(0,0,0,0.2); | 78 | -webkit-box-shadow:0px 2px 2px rgba(0,0,0,0.2); |
79 | box-shadow:0px 2px 2px rgba(0,0,0,0.2); | 79 | box-shadow:0px 2px 2px rgba(0,0,0,0.2); |
80 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=2,Color=#33000000,Positive=true)"; | 80 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=2,Color=#33000000,Positive=true)"; |
81 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=2,Color=#33000000,Positive=true); | 81 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=2,Color=#33000000,Positive=true); |
82 | } | 82 | } |
83 | 83 | ||
84 | .button1 span { | 84 | .button1 span { |
85 | position: absolute; | 85 | position: absolute; |
86 | left: 0; | 86 | left: 0; |
87 | top: 0; | 87 | top: 0; |
88 | width: 35px; | 88 | width: 35px; |
89 | background-color:rgba(0,0,0,0.5); | 89 | background-color:rgba(0,0,0,0.5); |
90 | 90 | ||
91 | -webkit-border-top-left-radius: 5px; | 91 | -webkit-border-top-left-radius: 5px; |
92 | -webkit-border-bottom-left-radius: 5px; | 92 | -webkit-border-bottom-left-radius: 5px; |
93 | -moz-border-radius-topleft: 5px; | 93 | -moz-border-radius-topleft: 5px; |
94 | -moz-border-radius-bottomleft: 5px; | 94 | -moz-border-radius-bottomleft: 5px; |
95 | border-top-left-radius: 5px; | 95 | border-top-left-radius: 5px; |
96 | border-bottom-left-radius: 5px; | 96 | border-bottom-left-radius: 5px; |
97 | border-right: 1px solid rgba(0,0,0,0.15); | 97 | border-right: 1px solid rgba(0,0,0,0.15); |
98 | } | 98 | } |
99 | 99 | ||
100 | .button1:hover span, .button1.active span { | 100 | .button1:hover span, .button1.active span { |
101 | background-color:rgb(0,102,26); | 101 | background-color:rgb(0,102,26); |
102 | border-right: 1px solid rgba(0,0,0,0.3); | 102 | border-right: 1px solid rgba(0,0,0,0.3); |
103 | } | 103 | } |
104 | 104 | ||
105 | .button1:active { | 105 | .button1:active { |
106 | margin-top: 2px; | 106 | margin-top: 2px; |
107 | margin-bottom: 13px; | 107 | margin-bottom: 13px; |
108 | 108 | ||
109 | -moz-box-shadow:0px 1px 0px rgba(255,255,255,0.5); | 109 | -moz-box-shadow:0px 1px 0px rgba(255,255,255,0.5); |
110 | -webkit-box-shadow:0px 1px 0px rgba(255,255,255,0.5); | 110 | -webkit-box-shadow:0px 1px 0px rgba(255,255,255,0.5); |
111 | box-shadow:0px 1px 0px rgba(255,255,255,0.5); | 111 | box-shadow:0px 1px 0px rgba(255,255,255,0.5); |
112 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ccffffff,Positive=true)"; | 112 | -ms-filter:"progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ccffffff,Positive=true)"; |
113 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ccffffff,Positive=true); | 113 | filter:progid:DXImageTransform.Microsoft.dropshadow(OffX=0,OffY=1,Color=#ccffffff,Positive=true); |
114 | } | 114 | } |
115 | 115 | ||
116 | .button1.turquoise { | 116 | .button1.turquoise { |
117 | background: #449d44; | 117 | background: #449d44; |
118 | } | 118 | } |
119 | 119 | ||
120 | </style> | 120 | </style> |
121 | <div class="col-xs-12 col-md-11"> | 121 | <div class="col-xs-12 col-md-11"> |
122 | <div class="row" style="margin-left:0px"> | 122 | <div class="row" style="margin-left:0px"> |
123 | <div class="col-md-12"> | 123 | <div class="col-md-12"> |
124 | <div class="widget"> | 124 | <div class="widget"> |
125 | <div class="widget-header"> | 125 | <div class="widget-header"> |
126 | <i class="fa fa-building-o" aria-hidden="true"></i> | 126 | <i class="fa fa-building-o" aria-hidden="true"></i> |
127 | <h3>Antioch Flight Department</h3> | 127 | <h3>Antioch Flight Department</h3> |
128 | <i class="fa fa-times timess" ui-sref="app.customers" aria-hidden="true"></i> | 128 | <i class="fa fa-times timess" ui-sref="app.customers" aria-hidden="true"></i> |
129 | </div> | 129 | </div> |
130 | <!-- /widget-header --> | 130 | <!-- /widget-header --> |
131 | <div class="widget-content"> | 131 | <div class="widget-content"> |
132 | <div class="row" style="margin-left:0px"> | 132 | <div class="row" style="margin-left:0px"> |
133 | <div class="col-md-6"> | 133 | <div class="col-md-6"> |
134 | <div class="widget"> | 134 | <div class="widget"> |
135 | <div class="widget-header"> | 135 | <div class="widget-header"> |
136 | <i class="fa fa-building-o" aria-hidden="true"></i> | 136 | <i class="fa fa-building-o" aria-hidden="true"></i> |
137 | <h3>Company Details</h3> | 137 | <h3>Company Details</h3> |
138 | <div class="pull-right my-toggle-switch" style="margin-top: 10px; margin-right: 10px;"> | 138 | <div class="pull-right my-toggle-switch" style="margin-top: 10px; margin-right: 10px;"> |
139 | <div><input id="toggle-one2" checked type="checkbox" data-size="mini" data-width="55" data-toggle="toggle" data-on="Active" data-off="Dactive"> | 139 | <div><input id="company-one2" checked type="checkbox" data-size="mini" data-width="55" data-toggle="toggle" data-on="Active" data-off="Dactive"> |
140 | </div> | 140 | </div> |
141 | </div> | 141 | </div> |
142 | </div> | 142 | </div> |
143 | <div class="widget-content"> | 143 | <div class="widget-content"> |
144 | <div class="row" style="margin-left:0px;"> | 144 | <div class="row" style="margin-left:0px;"> |
145 | <div class="col-md-8" style="padding-left: 0;"> | 145 | <div class="col-md-7" style="padding-left: 0;"> |
146 | <h4 ng-show="showCompanyName"> | 146 | <h4 ng-show="showCompanyName"> |
147 | <b style="color:#F90;">{{companyData.companyName}}</b> <i class="fa fa-pencil-square-o" ng-click="company()" style="font-size: 14px;" aria-hidden="true"></i> | 147 | <b style="color:#F90;">{{companyData.companyName}}</b> <i class="fa fa-pencil-square-o" ng-click="company()" style="font-size: 14px;" aria-hidden="true"></i> |
148 | </h4> | 148 | </h4> |
149 | <input type="tel" ng-hide="showCompanyName" ng-model="companyData.companyName" class="form-control" ng-blur="editData('showCompanyName')"/> | 149 | <input type="tel" ng-hide="showCompanyName" ng-model="companyData.companyName" class="form-control" ng-blur="editData('showCompanyName')"/> |
150 | </div> | 150 | </div> |
151 | <div class="col-md-4"> | 151 | <div class="col-md-5"> |
152 | <select class="form-control" style="height:31px;background: #ebebeb;"> | 152 | <select class="form-control" style="padding: 4px 8px;background: #ebebeb;" ng-model="companyData.certificateType" ng-click="editData()"> |
153 | <option class="optionclass" disabled selected>Certificate Type</option> | 153 | <option class="optionclass" disabled selected>Certificate Type</option> |
154 | <option class="Corporate">Part 91 (Corporate)</option> | 154 | <option class="optionclass" value="corporate">Part 91 (Corporate)</option> |
155 | <option class="Charter">Part 135 (Charter)</option> | 155 | <option class="optionclass" value="charter">Part 135 (Charter)</option> |
156 | <option class="Scheduled">Part 121 (Scheduled)</option> | 156 | <option class="optionclass" value="scheduled">Part 121 (Scheduled)</option> |
157 | <option class="Military">Military</option> | 157 | <option class="optionclass" value="military">Military</option> |
158 | <option class="Government">Government</option> | 158 | <option class="optionclass" value="government">Government</option> |
159 | </select> | 159 | </select> |
160 | </div> | 160 | </div> |
161 | </div> | 161 | </div> |
162 | <div> | 162 | <div> |
163 | <p class="new-label"> | 163 | <p class="new-label"> |
164 | <span>Master Margin Setting </span> | 164 | <span>Master Margin Setting </span> |
165 | <select class="form-control" style="width: 100px;"> | 165 | <select class="form-control" style="width: 135px;padding: 4px 8px;" ng-model="companyData.masterMargin" ng-click="editData()"> |
166 | <option>Margin1</option> | 166 | <option value="margin1">Margin1</option> |
167 | <option>Margin2</option> | 167 | <option value="margin2">Margin2</option> |
168 | <option value="vendorsonly">Vendors Only</option> | ||
169 | <option value="margintenants">Margin Tenants</option> | ||
168 | </select> | 170 | </select> |
169 | <span> See Aircrart List</span> | 171 | <span> See Aircrart List</span> |
170 | <div class="clearfix"></div> | 172 | <div class="clearfix"></div> |
171 | </p> | 173 | </p> |
172 | </div> | 174 | </div> |
173 | <div class="row" style="margin-left:0px;"> | 175 | <div class="row" style="margin-left:0px;"> |
174 | <div class="col-md-5" style="padding-left: 0;"> | 176 | <div class="col-md-5" style="padding-left: 0;"> |
175 | <input type="checkbox" name="" ng-model="companyData.baseTenant"> Tenant/Base Customer | 177 | <input type="checkbox" name="" ng-click="editData()" ng-model="companyData.baseTenant"> Tenant/Base Customer |
176 | </div> | 178 | </div> |
177 | <div class="col-md-5" style="padding-left: 0;"> | 179 | <div class="col-md-5" style="padding-left: 0;"> |
178 | <input type="checkbox" name="" ng-model="companyData.fuelerlinxCustomer"> FuelerLinx Customer | 180 | <input type="checkbox" name="" ng-click="editData()" ng-model="companyData.fuelerlinxCustomer"> FuelerLinx Customer |
179 | </div> | 181 | </div> |
180 | </div> | 182 | </div> |
181 | <div> | 183 | <div> |
182 | <input type="checkbox" name="" ng-model="companyData.contractFuelVendor"> CAA Member | 184 | <input type="checkbox" name="" ng-click="editData()" ng-model="companyData.contractFuelVendor"> CAA Member |
183 | </div> | 185 | </div> |
184 | </br> | 186 | </br> |
185 | <div class="new-address"> | 187 | <div class="new-address"> |
186 | <p><i class="fa fa-map-marker"></i> Reviera State Rd32 <i class="fa fa-pencil-square-o" aria-hidden="true"></i> </p> | 188 | <p ng-show="showAddress"><i class="fa fa-map-marker"></i> {{companyData.addressOne}} {{companyData.addressTwo}} <i class="fa fa-pencil-square-o" ng-click="addressChange()" aria-hidden="true"></i> </p> |
189 | |||
190 | <div ng-hide="showAddress"> | ||
191 | <label>Address1</label> | ||
192 | <input type="tel" ng-hide="showAddress" ng-model="companyData.addressOne" class="form-control" ng-blur="editData('showAddress')"/> | ||
193 | <label>Address2</label> | ||
194 | <input type="tel" ng-hide="showAddress" ng-model="companyData.addressTwo" class="form-control" ng-blur="editData('showAddress')"/> | ||
195 | </div> | ||
196 | |||
187 | <p><i class="fa fa-phone"></i> (310) 2342-3433 <i class="fa fa-pencil-square-o" aria-hidden="true"></i></p> | 197 | <p><i class="fa fa-phone"></i> (310) 2342-3433 <i class="fa fa-pencil-square-o" aria-hidden="true"></i></p> |
188 | <p><i class="fa fa-envelope"></i> freed@gmail.com <i class="fa fa-pencil-square-o" aria-hidden="true"></i></p> | 198 | <p><i class="fa fa-envelope"></i> freed@gmail.com <i class="fa fa-pencil-square-o" aria-hidden="true"></i></p> |
189 | </div> | 199 | </div> |
190 | <div class="new-add-select"> | 200 | <div class="new-add-select"> |
191 | <select class="form-control" style="background: #ebebeb;"> | 201 | <select class="form-control" style="background: #ebebeb;padding: 4px 8px;width: 115px;"> |
192 | <option disabled selected>Add Field</option> | 202 | <option disabled selected>Add Field</option> |
193 | <option class="optionclass">Add Phone</option> | 203 | <option class="optionclass">Add Phone</option> |
194 | <option class="optionclass">Add Email</option> | 204 | <option class="optionclass">Add Email</option> |
195 | </select> | 205 | </select> |
196 | </div> | 206 | </div> |
197 | <div> | 207 | <div> |
198 | <p style="margin-bottom: 0;"><b>Company Notes</b> <i class="fa fa-pencil-square-o" ng-click="showNote()" aria-hidden="true"></i></p> | 208 | <p style="margin-bottom: 0;"><b>Company Notes</b> <i class="fa fa-pencil-square-o" ng-click="showNote()" aria-hidden="true"></i></p> |
199 | <p ng-show="showNoteData">{{companyData.internalNote}}</p> | 209 | <p ng-show="showNoteData">{{companyData.internalNote}}</p> |
200 | <textarea name="message" ng-hide="showNoteData" style="margin-bottom: 6px;" class="form-control" ng-model="companyData.internalNote" ng-blur="editData('showNoteData')" rows="4" cols="34"></textarea> | 210 | <textarea name="message" ng-hide="showNoteData" style="margin-bottom: 6px;" class="form-control" ng-model="companyData.internalNote" ng-blur="editData('showNoteData')" rows="4" cols="34"></textarea> |
201 | </div> | 211 | </div> |
202 | <div class="dis"> | 212 | <div class="dis"> |
203 | <button type="button" class="btn btn-primary">Distribute Price to Company Contacts</button> | 213 | <button type="button" class="btn btn-primary">Distribute Price to Company Contacts</button> |
204 | </div> | 214 | </div> |
205 | <div><button type="button" class="btn btn-info">Setup Fuel</button></div> | 215 | <div><button type="button" class="btn btn-info">Setup Fuel</button></div> |
206 | </div> | 216 | </div> |
207 | </div> | 217 | </div> |
208 | </div> | 218 | </div> |
209 | <div class="col-md-6"> | 219 | <div class="col-md-6"> |
210 | <div class="widget"> | 220 | <div class="widget"> |
211 | <div class="widget-header"> | 221 | <div class="widget-header"> |
212 | <i class="fa fa-plane"></i> | 222 | <i class="fa fa-plane"></i> |
213 | <h3>Aircraft List</h3> | 223 | <h3>Aircraft List</h3> |
214 | <div class="pull-right"> | 224 | <div class="pull-right"> |
215 | <button type="submit" class="btn btn-success btn-sm" data-toggle="modal" data-target="#aircraft-modal-3" style="margin-top: 4px; margin-right: 9px;"><i class="fa fa-plus" aria-hidden="true"></i> Add Aircraft</button> | 225 | <button type="submit" class="btn btn-success btn-sm" data-toggle="modal" data-target="#aircraft-modal-3" style="margin-top: 4px; margin-right: 9px;"><i class="fa fa-plus" aria-hidden="true"></i> Add Aircraft</button> |
216 | </div> | 226 | </div> |
217 | </div> | 227 | </div> |
218 | <div class="widget-content" style="padding:0px"> | 228 | <div class="widget-content" style="padding:0px"> |
219 | <div class="table-responsive"> | 229 | <div class="table-responsive"> |
220 | <table class="table table-bordered table-hover table-striped"> | 230 | <table class="table table-bordered table-hover table-striped"> |
221 | <thead> | 231 | <thead> |
222 | <tr> | 232 | <tr> |
223 | <th>Tail #</th> | 233 | <th>Tail #</th> |
224 | <th>Make</th> | 234 | <th>Make</th> |
225 | <th>Model</th> | 235 | <th>Model</th> |
226 | <th>JET-A</th> | 236 | <th>JET-A</th> |
227 | <th>All in</th> | 237 | <th>All in</th> |
228 | <th>AVGAS</th> | 238 | <th>AVGAS</th> |
229 | <th>All in</th> | 239 | <th>All in</th> |
230 | <th></th> | 240 | <th></th> |
231 | </tr> | 241 | </tr> |
232 | </thead> | 242 | </thead> |
233 | <tbody> | 243 | <tbody> |
234 | <tr ng-repeat="aircraft in contactAircraftList"> | 244 | <tr ng-repeat="aircraft in contactAircraftList"> |
235 | <td>{{aircraft.tail}}</td> | 245 | <td>{{aircraft.tail}}</td> |
236 | <td>{{aircraft.make}}</td> | 246 | <td>{{aircraft.make}}</td> |
237 | <td>{{aircraft.model}}</td> | 247 | <td>{{aircraft.model}}</td> |
238 | <td> | 248 | <td> |
239 | <select class="form-control" style="height:31px;"> | 249 | <select class="form-control" style="height:31px;"> |
240 | <option>Margin1</option> | 250 | <option>Margin1</option> |
241 | <option>Margin2</option> | 251 | <option>Margin2</option> |
242 | </select> | 252 | </select> |
243 | </td> | 253 | </td> |
244 | <td style="color:#55AF8B;">$3659</td> | 254 | <td style="color:#55AF8B;">$3659</td> |
245 | <td> | 255 | <td> |
246 | <select class="form-control" style="height:31px;"> | 256 | <select class="form-control" style="height:31px;"> |
247 | <option>Margin1</option> | 257 | <option>Margin1</option> |
248 | <option>Margin2</option> | 258 | <option>Margin2</option> |
249 | </select> | 259 | </select> |
250 | </td> | 260 | </td> |
251 | <td style="color:#55AF8B;">$3659</td> | 261 | <td style="color:#55AF8B;">$3659</td> |
252 | <td></td> | 262 | <td></td> |
253 | </tr> | 263 | </tr> |
254 | </tbody> | 264 | </tbody> |
255 | </table> | 265 | </table> |
256 | </div> | 266 | </div> |
257 | </div> | 267 | </div> |
258 | </div> | 268 | </div> |
259 | </div> | 269 | </div> |
260 | </div> | 270 | </div> |
261 | <div class="row" style="margin-left:0px"> | 271 | <div class="row" style="margin-left:0px"> |
262 | <div class="col-md-6"> | 272 | <div class="col-md-6"> |
263 | <div class="widget"> | 273 | <div class="widget"> |
264 | <div class="widget-header"> | 274 | <div class="widget-header"> |
265 | <i class="fa fa-user"></i> | 275 | <i class="fa fa-user"></i> |
266 | <h3>Contact List</h3> | 276 | <h3>Contact List</h3> |
267 | <div class="pull-right"> | 277 | <div class="pull-right"> |
268 | <button type="submit" data-toggle="modal" data-target="#contact-modal-3" class="btn btn-success btn-sm" style="margin-top: 4px; margin-right: 9px;"><i class="fa fa-plus" aria-hidden="true"></i> Add Contact</button> | 278 | <button type="submit" data-toggle="modal" data-target="#contact-modal-3" class="btn btn-success btn-sm" style="margin-top: 4px; margin-right: 9px;"><i class="fa fa-plus" aria-hidden="true"></i> Add Contact</button> |
269 | </div> | 279 | </div> |
270 | </div> | 280 | </div> |
271 | <div class="widget-content" style="padding:0px"> | 281 | <div class="widget-content" style="padding:0px"> |
272 | <div class="table-responsive"> | 282 | <div class="table-responsive"> |
273 | <table class="table table-bordered table-hover table-striped"> | 283 | <table class="table table-bordered table-hover table-striped"> |
274 | <thead> | 284 | <thead> |
275 | <tr> | 285 | <tr> |
276 | <th>Price Email</th> | 286 | <th>Price Email</th> |
277 | <th>First Name</th> | 287 | <th>First Name</th> |
278 | <th>Last Name</th> | 288 | <th>Last Name</th> |
279 | <th>Title</th> | 289 | <th>Title</th> |
280 | </tr> | 290 | </tr> |
281 | </thead> | 291 | </thead> |
282 | <tbody> | 292 | <tbody> |
283 | <tr ng-repeat="contact in companyContactList"> | 293 | <tr ng-repeat="contact in companyContactList"> |
284 | <td><input id="toggle-one1" ng-model="contact.priceEmail" ng-true-value="true" ng-false-value="false" checked type="checkbox" data-size="mini" data-toggle="toggle"></td> | 294 | <td><input id="toggle-one1" ng-model="contact.priceEmail" ng-true-value="true" ng-false-value="false" checked type="checkbox" data-size="mini" data-toggle="toggle"></td> |
285 | <td>{{contact.firstName}}</td> | 295 | <td>{{contact.firstName}}</td> |
286 | <td>{{contact.lastName}}</td> | 296 | <td>{{contact.lastName}}</td> |
287 | <td>{{contact.title}}</td> | 297 | <td>{{contact.title}}</td> |
288 | </tr> | 298 | </tr> |
289 | </tbody> | 299 | </tbody> |
290 | </table> | 300 | </table> |
291 | </div> | 301 | </div> |
292 | </div> | 302 | </div> |
293 | </div> | 303 | </div> |
294 | </div> | 304 | </div> |
295 | <div class="col-md-6"> | 305 | <div class="col-md-6"> |
296 | <div class="widget"> | 306 | <div class="widget"> |
297 | <div class="widget-header"> | 307 | <div class="widget-header"> |
298 | <i class="fa fa-pencil"></i> | 308 | <i class="fa fa-pencil"></i> |
299 | <h3>Price Manager Reference</h3> | 309 | <h3>Price Manager Reference</h3> |
300 | </div> | 310 | </div> |
301 | <div class="widget-content"> | 311 | <div class="widget-content"> |
302 | <div class="table-responsive"> | 312 | <div class="table-responsive"> |
303 | <table class="table table-hover table-striped"> | 313 | <table class="table table-hover table-striped"> |
304 | <thead> | 314 | <thead> |
305 | <tr> | 315 | <tr> |
306 | <th>Omit</th> | 316 | <th>Omit</th> |
307 | <th>Product</th> | 317 | <th>Product</th> |
308 | <th>Cost</th> | 318 | <th>Cost</th> |
309 | <th>PAP (Margin)</th> | 319 | <th>PAP (Margin)</th> |
310 | <th>PAP (Total)</th> | 320 | <th>PAP (Total)</th> |
311 | <th style="color:#F90">Expires</th> | 321 | <th style="color:#F90">Expires</th> |
312 | </tr> | 322 | </tr> |
313 | </thead> | 323 | </thead> |
314 | <tbody> | 324 | <tbody> |
315 | <tr> | 325 | <tr> |
316 | <td><input type="checkbox"></td> | 326 | <td><input type="checkbox"></td> |
317 | <td>Jet-A Full Service</td> | 327 | <td>Jet-A Full Service</td> |
318 | <td>$2.123</td> | 328 | <td>$2.123</td> |
319 | <td>$23000</td> | 329 | <td>$23000</td> |
320 | <td style="color:#55AF8B;">$3659</td> | 330 | <td style="color:#55AF8B;">$3659</td> |
321 | <td style="color:#F90">3/15/2017</td> | 331 | <td style="color:#F90">3/15/2017</td> |
322 | </tr> | 332 | </tr> |
323 | <tr> | 333 | <tr> |
324 | <td><input type="checkbox"></td> | 334 | <td><input type="checkbox"></td> |
325 | <td>Jet-A Full Service</td> | 335 | <td>Jet-A Full Service</td> |
326 | <td>$2.123</td> | 336 | <td>$2.123</td> |
327 | <td>$23000</td> | 337 | <td>$23000</td> |
328 | <td style="color:#55AF8B;">$3659</td> | 338 | <td style="color:#55AF8B;">$3659</td> |
329 | <td style="color:#F90">3/15/2017</td> | 339 | <td style="color:#F90">3/15/2017</td> |
330 | </tr> | 340 | </tr> |
331 | <tr> | 341 | <tr> |
332 | <tr> | 342 | <tr> |
333 | <td><input type="checkbox"></td> | 343 | <td><input type="checkbox"></td> |
334 | <td>Jet-A Full Service</td> | 344 | <td>Jet-A Full Service</td> |
335 | <td>$2.123</td> | 345 | <td>$2.123</td> |
336 | <td>$23000</td> | 346 | <td>$23000</td> |
337 | <td style="color:#55AF8B;">$3659</td> | 347 | <td style="color:#55AF8B;">$3659</td> |
338 | <td style="color:#F90">3/15/2017</td> | 348 | <td style="color:#F90">3/15/2017</td> |
339 | </tr> | 349 | </tr> |
340 | <tr> | 350 | <tr> |
341 | <td><input type="checkbox"></td> | 351 | <td><input type="checkbox"></td> |
342 | <td>Jet-A Full Service</td> | 352 | <td>Jet-A Full Service</td> |
343 | <td>$2.123</td> | 353 | <td>$2.123</td> |
344 | <td>$23000</td> | 354 | <td>$23000</td> |
345 | <td style="color:#55AF8B;">$3659</td> | 355 | <td style="color:#55AF8B;">$3659</td> |
346 | <td style="color:#F90">3/15/2017</td> | 356 | <td style="color:#F90">3/15/2017</td> |
347 | </tr> | 357 | </tr> |
348 | </tbody> | 358 | </tbody> |
349 | </table> | 359 | </table> |
350 | </div> | 360 | </div> |
351 | </div> | 361 | </div> |
352 | </div> | 362 | </div> |
353 | </div> | 363 | </div> |
354 | </div> | 364 | </div> |
355 | </div> | 365 | </div> |
356 | <!-- /widget-content --> | 366 | <!-- /widget-content --> |
357 | </div> | 367 | </div> |
358 | <!-- /widget --> | 368 | <!-- /widget --> |
359 | </div> | 369 | </div> |
360 | <!-- /span6 --> | 370 | <!-- /span6 --> |
361 | </div> | 371 | </div> |
362 | <!-- /widget --> | 372 | <!-- /widget --> |
363 | </div> | 373 | </div> |
364 | <!-- /container --> | 374 | <!-- /container --> |
365 | <form class="modal multi-step" id="contact-modal-3" name="companyForm"> | 375 | <form class="modal multi-step" id="contact-modal-3" name="companyForm"> |
366 | <div class="modal-dialog modal-lg"> | 376 | <div class="modal-dialog modal-lg"> |
367 | <div class="modal-content"> | 377 | <div class="modal-content"> |
368 | <div class="modal-body step-1" data-step="1" style="padding: 0;"> | 378 | <div class="modal-body step-1" data-step="1" style="padding: 0;"> |
369 | <div> | 379 | <div> |
370 | <div class="row" style="margin: 0;"> | 380 | <div class="row" style="margin: 0;"> |
371 | <div> | 381 | <div> |
372 | <div class="widget" style="margin-bottom: 0; box-shadow: none;"> | 382 | <div class="widget" style="margin-bottom: 0; box-shadow: none;"> |
373 | <div class="widget-header"> | 383 | <div class="widget-header"> |
374 | <i class="icon-pencil"></i> | 384 | <i class="icon-pencil"></i> |
375 | <i class="fa fa-tasks" aria-hidden="true"></i> | 385 | <i class="fa fa-tasks" aria-hidden="true"></i> |
376 | <h3>Add a New Contact</h3> | 386 | <h3>Add a New Contact</h3> |
377 | <div class="clearfix"></div> | 387 | <div class="clearfix"></div> |
378 | </div> | 388 | </div> |
379 | <div class="widget-content" style="padding-left: 0; padding-right: 0; border-bottom: 0;"> | 389 | <div class="widget-content" style="padding-left: 0; padding-right: 0; border-bottom: 0;"> |
380 | <div class="col-xs-12"> | 390 | <div class="col-xs-12"> |
381 | <div class="col-md-6"> | 391 | <div class="col-md-6"> |
382 | <div class="pull-left" style="width: 110px;"> | 392 | <div class="pull-left" style="width: 110px;"> |
383 | <label class="new-input-label"><b>First Name</b></label> | 393 | <label class="new-input-label"><b>First Name</b></label> |
384 | </div> | 394 | </div> |
385 | <div class="pull-left" style="margin-left: 15px;"> | 395 | <div class="pull-left" style="margin-left: 15px;"> |
386 | <input type="tel" ng-model="data.firstName" class="form-control" placeholder=""> | 396 | <input type="tel" ng-model="data.firstName" class="form-control" placeholder=""> |
387 | </div> | 397 | </div> |
388 | <div class="clearfix"></div> | 398 | <div class="clearfix"></div> |
389 | </div> | 399 | </div> |
390 | <div class="col-md-6"> | 400 | <div class="col-md-6"> |
391 | 401 | ||
392 | <div class="pull-left" style="width: 110px;"> | 402 | <div class="pull-left" style="width: 110px;"> |
393 | <label class="new-input-label"><b>Last Name</b></label> | 403 | <label class="new-input-label"><b>Last Name</b></label> |
394 | </div> | 404 | </div> |
395 | <div class="pull-left" style="margin-left: 15px;"> | 405 | <div class="pull-left" style="margin-left: 15px;"> |
396 | <input type="tel" ng-model="data.lastName" class="form-control" id="Address" placeholder=""> | 406 | <input type="tel" ng-model="data.lastName" class="form-control" id="Address" placeholder=""> |
397 | </div> | 407 | </div> |
398 | <div class="clearfix"></div> | 408 | <div class="clearfix"></div> |
399 | </div> | 409 | </div> |
400 | </div> | 410 | </div> |
401 | <div class="clearfix"></div><br> | 411 | <div class="clearfix"></div><br> |
402 | <div class="col-xs-12"> | 412 | <div class="col-xs-12"> |
403 | <div class="col-md-6"> | 413 | <div class="col-md-6"> |
404 | <div class="pull-left" style="width: 110px;"> | 414 | <div class="pull-left" style="width: 110px;"> |
405 | <label class="new-input-label"><b>Title</b></label> | 415 | <label class="new-input-label"><b>Title</b></label> |
406 | </div> | 416 | </div> |
407 | <div class="pull-left" style="margin-left: 15px;"> | 417 | <div class="pull-left" style="margin-left: 15px;"> |
408 | <input type="tel" ng-model="data.title" class="form-control" id="Address" placeholder=""> | 418 | <input type="tel" ng-model="data.title" class="form-control" id="Address" placeholder=""> |
409 | </div> | 419 | </div> |
410 | <div class="clearfix"></div> | 420 | <div class="clearfix"></div> |
411 | </div> | 421 | </div> |
412 | <div class="col-md-6"> | 422 | <div class="col-md-6"> |
413 | 423 | ||
414 | <div class="pull-left" style="width: 110px;"> | 424 | <div class="pull-left" style="width: 110px;"> |
415 | <label class="new-input-label"><b>Email</b></label> | 425 | <label class="new-input-label"><b>Email</b></label> |
416 | </div> | 426 | </div> |
417 | <div class="pull-left" style="margin-left: 15px;"> | 427 | <div class="pull-left" style="margin-left: 15px;"> |
418 | <input type="email" ng-model="data.email" class="form-control" id="Address" placeholder=""> | 428 | <input type="email" ng-model="data.email" class="form-control" id="Address" placeholder=""> |
419 | </div> | 429 | </div> |
420 | <div class="clearfix"></div> | 430 | <div class="clearfix"></div> |
421 | </div> | 431 | </div> |
422 | </div> | 432 | </div> |
423 | <div class="clearfix"></div><br> | 433 | <div class="clearfix"></div><br> |
424 | <div class="col-xs-12"> | 434 | <div class="col-xs-12"> |
425 | <div class="col-md-6"> | 435 | <div class="col-md-6"> |
426 | <div class="pull-left" style="width: 110px;"> | 436 | <div class="pull-left" style="width: 110px;"> |
427 | <label class="new-input-label"><b>Username</b></label> | 437 | <label class="new-input-label"><b>Username</b></label> |
428 | </div> | 438 | </div> |
429 | <div class="pull-left" style="margin-left: 15px;"> | 439 | <div class="pull-left" style="margin-left: 15px;"> |
430 | <input type="tel" ng-model="data.userName" class="form-control" id="Address" placeholder=""> | 440 | <input type="tel" ng-model="data.userName" class="form-control" id="Address" placeholder=""> |
431 | </div> | 441 | </div> |
432 | <div class="clearfix"></div> | 442 | <div class="clearfix"></div> |
433 | </div> | 443 | </div> |
434 | <div class="col-md-6"> | 444 | <div class="col-md-6"> |
435 | 445 | ||
436 | <div class="pull-left" style="width: 110px;"> | 446 | <div class="pull-left" style="width: 110px;"> |
437 | <label class="new-input-label"><b>Password</b></label> | 447 | <label class="new-input-label"><b>Password</b></label> |
438 | </div> | 448 | </div> |
439 | <div class="pull-left" style="margin-left: 15px;"> | 449 | <div class="pull-left" style="margin-left: 15px;"> |
440 | <input type="password" ng-model="data.password" class="form-control" id="Address" placeholder=""> | 450 | <input type="password" ng-model="data.password" class="form-control" id="Address" placeholder=""> |
441 | </div> | 451 | </div> |
442 | <div class="clearfix"></div> | 452 | <div class="clearfix"></div> |
443 | </div> | 453 | </div> |
444 | </div> | 454 | </div> |
445 | <div class="clearfix"></div><br> | 455 | <div class="clearfix"></div><br> |
446 | <div class="col-xs-12"> | 456 | <div class="col-xs-12"> |
447 | <div class="col-md-6"> | 457 | <div class="col-md-6"> |
448 | <div class="pull-left" style="width: 110px;"> | 458 | <div class="pull-left" style="width: 110px;"> |
449 | <label class="new-input-label"><b>Work Phone</b></label> | 459 | <label class="new-input-label"><b>Work Phone</b></label> |
450 | </div> | 460 | </div> |
451 | <div class="pull-left" style="margin-left: 15px;"> | 461 | <div class="pull-left" style="margin-left: 15px;"> |
452 | <input type="tel" ng-model="data.workPhone" class="form-control" id="Address" placeholder=""> | 462 | <input type="tel" ng-model="data.workPhone" class="form-control" id="Address" placeholder=""> |
453 | </div> | 463 | </div> |
454 | <div class="clearfix"></div> | 464 | <div class="clearfix"></div> |
455 | </div> | 465 | </div> |
456 | <div class="col-md-6"> | 466 | <div class="col-md-6"> |
457 | 467 | ||
458 | <div class="pull-left" style="width: 110px;"> | 468 | <div class="pull-left" style="width: 110px;"> |
459 | <label class="new-input-label"><b>Mobile Phone</b></label> | 469 | <label class="new-input-label"><b>Mobile Phone</b></label> |
460 | </div> | 470 | </div> |
461 | <div class="pull-left" style="margin-left: 15px;"> | 471 | <div class="pull-left" style="margin-left: 15px;"> |
462 | <input type="tel" ng-model="data.mobilePhone" class="form-control" id="Address" placeholder=""> | 472 | <input type="tel" ng-model="data.mobilePhone" class="form-control" id="Address" placeholder=""> |
463 | </div> | 473 | </div> |
464 | <div class="clearfix"></div> | 474 | <div class="clearfix"></div> |
465 | </div> | 475 | </div> |
466 | </div> | 476 | </div> |
467 | <div class="clearfix"></div><br> | 477 | <div class="clearfix"></div><br> |
468 | <div class="col-xs-12"> | 478 | <div class="col-xs-12"> |
469 | <div class="col-md-12"> | 479 | <div class="col-md-12"> |
470 | <div class="pull-left" style="width: 110px;"> | 480 | <div class="pull-left" style="width: 110px;"> |
471 | <label class="new-input-label"><b>Address</b></label> | 481 | <label class="new-input-label"><b>Address</b></label> |
472 | </div> | 482 | </div> |
473 | <div class="pull-right" style="width: calc(100% - 123px);"> | 483 | <div class="pull-right" style="width: calc(100% - 123px);"> |
474 | <input type="tel" class="form-control" ng-model="data.address" id="Address" placeholder=""> | 484 | <input type="tel" class="form-control" ng-model="data.address" id="Address" placeholder=""> |
475 | </div> | 485 | </div> |
476 | <div class="clearfix"></div> | 486 | <div class="clearfix"></div> |
477 | </div> | 487 | </div> |
478 | </div> | 488 | </div> |
479 | <div class="clearfix"></div> | 489 | <div class="clearfix"></div> |
480 | <br/> | 490 | <br/> |
481 | <div class="col-xs-12"> | 491 | <div class="col-xs-12"> |
482 | <div class="col-md-3"> | 492 | <div class="col-md-3"> |
483 | <div class="pull-left my-toggle-switch"> | 493 | <div class="pull-left my-toggle-switch"> |
484 | <div style="color: #ff9a01;">Price Email     | 494 | <div style="color: #ff9a01;">Price Email     |
485 | <input id="price-one2" checked type="checkbox" data-size="mini" data-width="55" data-toggle="toggle" data-on="On" data-off="Off"> | 495 | <input id="price-one2" checked type="checkbox" data-size="mini" data-width="55" data-toggle="toggle" data-on="On" data-off="Off"> |
486 | </div> | 496 | </div> |
487 | </div> | 497 | </div> |
488 | <div class="clearfix"></div> | 498 | <div class="clearfix"></div> |
489 | </div> | 499 | </div> |
490 | <div class="col-md-3"> | 500 | <div class="col-md-3"> |
491 | <div class="pull-left my-toggle-switch"> | 501 | <div class="pull-left my-toggle-switch"> |
492 | <div style="color: #ff9a01;">Primary Contact     | 502 | <div style="color: #ff9a01;">Primary Contact     |
493 | <input type="checkbox" ng-model="data.primaryContact"> | 503 | <input type="checkbox" ng-model="data.primaryContact"> |
494 | </div> | 504 | </div> |
495 | </div> | 505 | </div> |
496 | <div class="clearfix"></div> | 506 | <div class="clearfix"></div> |
497 | </div> | 507 | </div> |
498 | <div class="col-md-6"> | 508 | <div class="col-md-6"> |
499 | <div class="pull-left" style="width: 110px;"> | 509 | <div class="pull-left" style="width: 110px;"> |
500 | <label class="new-input-label"><b>Internal Note</b></label> | 510 | <label class="new-input-label"><b>Internal Note</b></label> |
501 | </div> | 511 | </div> |
502 | <div class="pull-left" style="width: calc(100% - 110px);"> | 512 | <div class="pull-left" style="width: calc(100% - 110px);"> |
503 | <textarea name="message" ng-model="data.note" rows="4" cols="34"></textarea> | 513 | <textarea name="message" ng-model="data.note" rows="4" cols="34"></textarea> |
504 | </div> | 514 | </div> |
505 | </div> | 515 | </div> |
506 | <div class="clearfix"></div> | 516 | <div class="clearfix"></div> |
507 | </div> | 517 | </div> |
508 | <div class="clearfix"></div><br> | 518 | <div class="clearfix"></div><br> |
509 | </div> | 519 | </div> |
510 | </div> | 520 | </div> |
511 | <div class="clearfix"></div> | 521 | <div class="clearfix"></div> |
512 | </div> | 522 | </div> |
513 | </div> | 523 | </div> |
514 | </div> | 524 | </div> |
515 | </div> | 525 | </div> |
516 | <div class="modal-footer" style="border-top: 0;"> | 526 | <div class="modal-footer" style="border-top: 0;"> |
517 | <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button> | 527 | <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button> |
518 | <button type="button" class="btn btn-primary step step-1" data-step="1" ng-click="addContact()">Save</button> | 528 | <button type="button" class="btn btn-primary step step-1" data-step="1" ng-click="addContact()">Save</button> |
519 | </div> | 529 | </div> |
520 | </div> | 530 | </div> |
521 | </div> | 531 | </div> |
522 | </form> | 532 | </form> |
523 | <div class="clearfix"></div> | 533 | <div class="clearfix"></div> |
524 | 534 | ||
525 | <form class="modal multi-step" id="aircraft-modal-3" name="aircraftForm"> | 535 | <form class="modal multi-step" id="aircraft-modal-3" name="aircraftForm"> |
526 | <div class="modal-dialog modal-lg"> | 536 | <div class="modal-dialog modal-lg"> |
527 | <div class="modal-content"> | 537 | <div class="modal-content"> |
528 | <div class="modal-body step-2" data-step="2" style="padding: 0;"> | 538 | <div class="modal-body step-2" data-step="2" style="padding: 0;"> |
529 | <div> | 539 | <div> |
530 | <div class="row" style="margin: 0;"> | 540 | <div class="row" style="margin: 0;"> |
531 | <div> | 541 | <div> |
532 | <div class="widget" style="margin-bottom: 0;box-shadow: none;"> | 542 | <div class="widget" style="margin-bottom: 0;box-shadow: none;"> |
533 | <div class="widget-header"> | 543 | <div class="widget-header"> |
534 | <i class="icon-pencil"></i> | 544 | <i class="icon-pencil"></i> |
535 | <i class="fa fa-tasks" aria-hidden="true"></i> | 545 | <i class="fa fa-tasks" aria-hidden="true"></i> |
536 | <h3>Add a New Aircraft</h3> | 546 | <h3>Add a New Aircraft</h3> |
537 | <div class="clearfix"></div> | 547 | <div class="clearfix"></div> |
538 | </div> | 548 | </div> |
539 | <div class="widget-content" style="padding-left: 0; padding-right: 0; border-bottom: 0;"> | 549 | <div class="widget-content" style="padding-left: 0; padding-right: 0; border-bottom: 0;"> |
540 | <div class="col-xs-12"> | 550 | <div class="col-xs-12"> |
541 | <div class="widget-header"> | 551 | <div class="widget-header"> |
542 | <i class="fa fa-list"></i> | 552 | <i class="fa fa-list"></i> |
543 | <h3>Aircraft List</h3> | 553 | <h3>Aircraft List</h3> |
544 | </div> | 554 | </div> |
545 | <div class="widget-content" style="padding:0px;border: 0px; padding: 0px !important;"> | 555 | <div class="widget-content" style="padding:0px;border: 0px; padding: 0px !important;"> |
546 | <div class="table-responsive"> | 556 | <div class="table-responsive"> |
547 | <table class="table table-striped table-bordered"> | 557 | <table class="table table-striped table-bordered"> |
548 | <thead> | 558 | <thead> |
549 | <tr> | 559 | <tr> |
550 | <!-- <th><input type="checkbox" ng-model="selectedAll" ng-click="checkAll()" /></th> --> | 560 | <!-- <th><input type="checkbox" ng-model="selectedAll" ng-click="checkAll()" /></th> --> |
551 | <th>Tail</th> | 561 | <th>Tail</th> |
552 | <th>Make</th> | 562 | <th>Make</th> |
553 | <th>Model</th> | 563 | <th>Model</th> |
554 | <th>Size</th> | 564 | <th>Size</th> |
555 | </tr> | 565 | </tr> |
556 | </thead> | 566 | </thead> |
557 | <tbody> | 567 | <tbody> |
558 | <tr ng-repeat="aircraftData in aircraftDetails track by $index"> | 568 | <tr ng-repeat="aircraftData in aircraftDetails track by $index"> |
559 | <!-- <td> | 569 | <!-- <td> |
560 | <input type="checkbox" ng-model="aircraftData.selected"/> | 570 | <input type="checkbox" ng-model="aircraftData.selected"/> |
561 | </td> --> | 571 | </td> --> |
562 | <td style="width: 20%"> | 572 | <td style="width: 20%"> |
563 | <input type="tel" class="form-control" ng-model="aircraftData.tail" required/> | 573 | <input type="tel" class="form-control" ng-model="aircraftData.tail" required/> |
564 | </td> | 574 | </td> |
565 | <td style="width: 20%"> | 575 | <td style="width: 20%"> |
566 | <select class="form-control" ng-model="aircraftData.make" ng-change="getModal(aircraftData.make, $index)"> | 576 | <select class="form-control" ng-model="aircraftData.make" ng-change="getModal(aircraftData.make, $index)"> |
567 | <option ng-repeat="make in aircraftMakeList">{{make}}</option> | 577 | <option ng-repeat="make in aircraftMakeList">{{make}}</option> |
568 | </select> | 578 | </select> |
569 | </td> | 579 | </td> |
570 | <td style="width: 20%"> | 580 | <td style="width: 20%"> |
571 | <select class="form-control" ng-model="aircraftData.model" ng-change="getSize(aircraftData.model, $index)"> | 581 | <select class="form-control" ng-model="aircraftData.model" ng-change="getSize(aircraftData.model, $index)"> |
572 | <option ng-repeat="model in aircraftData.aircraftModalList">{{model}}</option> | 582 | <option ng-repeat="model in aircraftData.aircraftModalList">{{model}}</option> |
573 | </select> | 583 | </select> |
574 | </td> | 584 | </td> |
575 | <td style="width: 20%"> | 585 | <td style="width: 20%"> |
576 | <select class="form-control" ng-model="aircraftData.size"> | 586 | <select class="form-control" ng-model="aircraftData.size"> |
577 | <option ng-repeat="size in aircraftData.aircraftSizeList">{{size}}</option> | 587 | <option ng-repeat="size in aircraftData.aircraftSizeList">{{size}}</option> |
578 | </select> | 588 | </select> |
579 | </td> | 589 | </td> |
580 | </tr> | 590 | </tr> |
581 | </tbody> | 591 | </tbody> |
582 | </table> | 592 | </table> |
583 | </div> | 593 | </div> |
584 | <div class="clearfix"></div> | 594 | <div class="clearfix"></div> |
585 | </div> | 595 | </div> |
586 | </div> | 596 | </div> |
587 | <div class="clearfix"></div> | 597 | <div class="clearfix"></div> |
588 | <div class="col-xs-12" style="margin-bottom: 50px;margin-top: 10px;"> | 598 | <div class="col-xs-12" style="margin-bottom: 50px;margin-top: 10px;"> |
589 | <button ng-click="addNew()" class="button1 turquoise pull-right"><span>+</span>Add Aircraft</button> | 599 | <button ng-click="addNew()" class="button1 turquoise pull-right"><span>+</span>Add Aircraft</button> |
590 | </div> | 600 | </div> |
591 | </div> | 601 | </div> |
592 | </div> | 602 | </div> |
593 | <div class="clearfix"></div> | 603 | <div class="clearfix"></div> |
594 | </div> | 604 | </div> |
595 | </div> | 605 | </div> |
596 | </div> | 606 | </div> |
597 | </div> | 607 | </div> |
598 | <div class="modal-footer" style="border-top: 0;"> | 608 | <div class="modal-footer" style="border-top: 0;"> |
599 | <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button> | 609 | <button type="button" class="btn btn-default" data-dismiss="modal">Cancel</button> |
600 | <button type="button" class="btn btn-primary step step-1" data-step="1" ng-click="saveCompanyData()">Save</button> | 610 | <button type="button" class="btn btn-primary step step-1" data-step="1" ng-click="saveCompanyData()">Save</button> |
601 | </div> | 611 | </div> |
602 | </div> | 612 | </div> |
603 | </div> | 613 | </div> |
604 | </form> | 614 | </form> |
605 | <!-- Le javascript | 615 | <!-- Le javascript |
606 | ================================================== --> | 616 | ================================================== --> |
607 | <!-- Placed at the end of the document so the pages load faster --> | 617 | <!-- Placed at the end of the document so the pages load faster --> |
608 | <!-- <script | 618 | <!-- <script |
609 | CKEDITOR.replace( 'editor2', { | 619 | CKEDITOR.replace( 'editor2', { |
610 | height: 250, | 620 | height: 250, |
611 | extraPlugins: 'divarea' | 621 | extraPlugins: 'divarea' |
612 | } ); | 622 | } ); |
613 | </script> --> | 623 | </script> --> |
614 | 624 |
app/partials/viewCompany/viewCompany.service.js
1 | (function(){ | 1 | (function(){ |
2 | 'use strict'; | 2 | 'use strict'; |
3 | angular.module('acufuel') | 3 | angular.module('acufuel') |
4 | .service('ViewCompanyService', ['$q', '$http', 'BASE_URL', ViewCompanyService]); | 4 | .service('ViewCompanyService', ['$q', '$http', 'BASE_URL', ViewCompanyService]); |
5 | 5 | ||
6 | function ViewCompanyService($q, $http, BASE_URL) { | 6 | function ViewCompanyService($q, $http, BASE_URL) { |
7 | 7 | ||
8 | this.getCompany = function(id) { | 8 | this.getCompany = function(id) { |
9 | 9 | ||
10 | var deferred = $q.defer(); | 10 | var deferred = $q.defer(); |
11 | $http({ | 11 | $http({ |
12 | method : 'GET', | 12 | method : 'GET', |
13 | url : BASE_URL.url +'/company/'+id, | 13 | url : BASE_URL.url +'/company/'+id, |
14 | headers : {'Content-Type': 'application/json'}, | 14 | headers : {'Content-Type': 'application/json'}, |
15 | }) | 15 | }) |
16 | .then(function (result){ | 16 | .then(function (result){ |
17 | deferred.resolve(result.data); | 17 | deferred.resolve(result.data); |
18 | },function (result){ | 18 | },function (result){ |
19 | deferred.resolve(result.data); | 19 | deferred.resolve(result.data); |
20 | }) | 20 | }) |
21 | return deferred.promise; | 21 | return deferred.promise; |
22 | } | 22 | } |
23 | 23 | ||
24 | this.getContact = function(id) { | 24 | this.getContact = function(id) { |
25 | 25 | ||
26 | var deferred = $q.defer(); | 26 | var deferred = $q.defer(); |
27 | $http({ | 27 | $http({ |
28 | method : 'GET', | 28 | method : 'GET', |
29 | url : BASE_URL.url +'/company/contact/'+id, | 29 | url : BASE_URL.url +'/company/contact/'+id, |
30 | headers : {'Content-Type': 'application/json'}, | 30 | headers : {'Content-Type': 'application/json'}, |
31 | }) | 31 | }) |
32 | .then(function (result){ | 32 | .then(function (result){ |
33 | deferred.resolve(result.data); | 33 | deferred.resolve(result.data); |
34 | },function (result){ | 34 | },function (result){ |
35 | deferred.resolve(result.data); | 35 | deferred.resolve(result.data); |
36 | }) | 36 | }) |
37 | return deferred.promise; | 37 | return deferred.promise; |
38 | } | 38 | } |
39 | 39 | ||
40 | this.addContact = function(data) { | 40 | this.addContact = function(data) { |
41 | 41 | ||
42 | var deferred = $q.defer(); | 42 | var deferred = $q.defer(); |
43 | $http({ | 43 | $http({ |
44 | method : 'POST', | 44 | method : 'POST', |
45 | url : BASE_URL.url +'/company/add/contact', | 45 | url : BASE_URL.url +'/company/add/contact', |
46 | data : data, | 46 | data : data, |
47 | headers : {'Content-Type': 'application/json'}, | 47 | headers : {'Content-Type': 'application/json'}, |
48 | }) | 48 | }) |
49 | .then(function (result){ | 49 | .then(function (result){ |
50 | deferred.resolve(result.data); | 50 | deferred.resolve(result.data); |
51 | },function (result){ | 51 | },function (result){ |
52 | deferred.resolve(result.data); | 52 | deferred.resolve(result.data); |
53 | }) | 53 | }) |
54 | return deferred.promise; | 54 | return deferred.promise; |
55 | } | 55 | } |
56 | 56 | ||
57 | this.updateContact = function(data) { | ||
58 | |||
59 | var deferred = $q.defer(); | ||
60 | $http({ | ||
61 | method : 'PUT', | ||
62 | url : BASE_URL.url +'/company', | ||
63 | data : data, | ||
64 | headers : {'Content-Type': 'application/json'}, | ||
65 | }) | ||
66 | .then(function (result){ | ||
67 | deferred.resolve(result.data); | ||
68 | },function (result){ | ||
69 | deferred.resolve(result.data); | ||
70 | }) | ||
71 | return deferred.promise; | ||
72 | } | ||
73 | |||
57 | this.getAircraft = function(id) { | 74 | this.getAircraft = function(id) { |
58 | 75 | ||
59 | var deferred = $q.defer(); | 76 | var deferred = $q.defer(); |
60 | $http({ | 77 | $http({ |
61 | method : 'GET', | 78 | method : 'GET', |
62 | url : BASE_URL.url +'/company/aircrafts/'+id, | 79 | url : BASE_URL.url +'/company/aircrafts/'+id, |
63 | headers : {'Content-Type': 'application/json'}, | 80 | headers : {'Content-Type': 'application/json'}, |
64 | }) | 81 | }) |
65 | .then(function (result){ | 82 | .then(function (result){ |
66 | deferred.resolve(result.data); | 83 | deferred.resolve(result.data); |
67 | },function (result){ | 84 | },function (result){ |
68 | deferred.resolve(result.data); | 85 | deferred.resolve(result.data); |
69 | }) | 86 | }) |
70 | return deferred.promise; | 87 | return deferred.promise; |
71 | } | 88 | } |
72 | 89 | ||
73 | } | 90 | } |
74 | 91 | ||
75 | })(); | 92 | })(); |