You are viewing a plain text version of this content. The canonical link for it is here.
Posted to issues@trafficcontrol.apache.org by GitBox <gi...@apache.org> on 2020/06/10 23:14:51 UTC
[GitHub] [trafficcontrol] ocket8888 opened a new pull request #4783: Update Traffic Portal ISOs form for server interfaces
ocket8888 opened a new pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783
## What does this PR (Pull Request) do?
- [x] This PR is not related to any Issue
Reworks the ISOs generation form page to work with servers that have multiple interfaces, by selecting the interfaces for its form from the server's "service address"-containing interface.
## Which Traffic Control components are affected by this PR?
- Traffic Portal
## What is the best way to verify this PR?
Start TP, go to the isos page and tell it to fill in the form from an existing server. Verify that it actually does that.
## The following criteria are ALL met by this PR
- [x] No interface change, no test change
- [x] No interface change, no docs changes
- [x] An update to CHANGELOG.md is not necessary
- [x] This PR includes any and all required license headers
- [x] This PR does not include a database migration
- [x] This PR **DOES NOT FIX A SERIOUS SECURITY VULNERABILITY**
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 commented on pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 commented on pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#issuecomment-652473051
@ocket8888 - sorry, conflicts
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 commented on a change in pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 commented on a change in pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#discussion_r450441527
##########
File path: traffic_portal/app/src/common/modules/form/iso/FormISOController.js
##########
@@ -17,36 +17,52 @@
* under the License.
*/
-var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel) {
+var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel, serverUtils) {
+
+ // This RegExp matches any valid IPv4 or IPv6 address
+ // Source: Rahul Tripathy @ https://stackoverflow.com/questions/32324614/how-to-validate-ipv6-address-in-angularjs#answer-32324868
+ // May Neptune have mercy on my soul...
+ $scope.IPPattern = /^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\:){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?|((25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)$/
Review comment:
don't you define this pattern in serverutils as well? can't you just do this?
```
$scope.IPPattern = serverUtils.IPPattern;
```
and keep the definition in one place.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 merged pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 merged pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 commented on pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 commented on pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#issuecomment-655724660
actually found a bug: https://github.com/ocket8888/trafficcontrol/pull/42
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 commented on a change in pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 commented on a change in pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#discussion_r450440622
##########
File path: traffic_portal/app/src/common/modules/form/iso/form.iso.tpl.html
##########
@@ -28,163 +28,162 @@
<br>
<form name="isoForm" class="form-horizontal form-label-left" novalidate>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.server), 'has-feedback': hasError(isoForm.server)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Copy Server Attributes From</label>
+ <label for="server" class="control-label col-md-2 col-sm-2 col-xs-12">Copy Server Attributes From</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="server" class="form-control" ng-change="copyServerAttributes()" ng-model="selectedServer" ng-options="server as fqdn(server) for server in servers">
- <option value="">Select (optional)...</option>
+ <select name="server" id="server" class="form-control" ng-change="copyServerAttributes()" ng-model="selectedServer" ng-options="server as fqdn(server) for server in servers">
+ <option selected value="">Select (optional)...</option>
</select>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.osversionDir), 'has-feedback': hasError(isoForm.osversionDir)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">OS Version *</label>
+ <label for="osversionDir" class="control-label col-md-2 col-sm-2 col-xs-12">OS Version *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="osversionDir" class="form-control" ng-model="iso.osversionDir" required>
- <option value="">Select...</option>
+ <select name="osversionDir" id="osversionDir" class="form-control" ng-model="iso.osversionDir" required>
+ <option hidden disabled selected value="">Select...</option>
<option ng-repeat="(key, value) in osversions" value="{{::value}}">{{::key}}</option>
</select>
<small class="input-error" ng-show="hasPropertyError(isoForm.osversionDir, 'required')">Required</small>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.hostName), 'has-feedback': hasError(isoForm.hostName)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Hostname *</label>
+ <label for="hostName" class="control-label col-md-2 col-sm-2 col-xs-12">Hostname *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <input name="hostName" type="text" class="form-control" ng-model="iso.hostName" required autofocus>
+ <input id="hostName" name="hostName" type="text" class="form-control" ng-model="iso.hostName" required>
<small class="input-error" ng-show="hasPropertyError(isoForm.hostName, 'required')">Required</small>
<span ng-show="hasError(isoForm.hostName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.domainName), 'has-feedback': hasError(isoForm.domainName)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Domain *</label>
+ <label for="domainName" class="control-label col-md-2 col-sm-2 col-xs-12">Domain *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <input name="domainName" type="text" class="form-control" ng-model="iso.domainName" required autofocus>
+ <input id="domainName" name="domainName" type="text" class="form-control" ng-model="iso.domainName" required>
<small class="input-error" ng-show="hasPropertyError(isoForm.domainName, 'required')">Required</small>
<span ng-show="hasError(isoForm.domainName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
</div>
</div>
- <div class="form-group" ng-class="{'has-error': hasError(isoForm.dhcp), 'has-feedback': hasError(isoForm.dhcp)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">DHCP *</label>
- <div class="col-md-10 col-sm-10 col-xs-12">
- <select name="dhcp" class="form-control" ng-model="iso.dhcp" ng-options="x.value as x.label for x in falseTrue" required>
- <option value="">Select...</option>
- </select>
- <small class="input-error" ng-show="hasPropertyError(isoForm.dhcp, 'required')">Required</small>
+ <div class="form-group">
+ <label for="dhcp" class="control-label col-md-2 col-sm-2 col-xs-12" style="padding-top: 0">DHCP</label>
+ <div class="col-md-10 col-sm-10 col-xs-12" style="width: auto">
+ <input type="checkbox" id="dhcp" name="dhcp" ng-model="iso.dhcp"/>
</div>
</div>
- <div class="form-group" ng-show="!isDHCP(iso)" ng-class="{'has-error': hasError(isoForm.ipAddress), 'has-feedback': hasError(isoForm.ipAddress)}">
+ <div class="form-group" ng-if="!iso.dhcp" ng-class="{'has-error': hasError(isoForm.ipAddress), 'has-feedback': hasError(isoForm.ipAddress)}">
Review comment:
this is getting screwed up by:
```
iso.dhcp = iso.dhcp ? "yes" : "no";
```
and yeah, really dump api design.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] mitchell852 commented on a change in pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
mitchell852 commented on a change in pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#discussion_r450441527
##########
File path: traffic_portal/app/src/common/modules/form/iso/FormISOController.js
##########
@@ -17,36 +17,52 @@
* under the License.
*/
-var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel) {
+var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel, serverUtils) {
+
+ // This RegExp matches any valid IPv4 or IPv6 address
+ // Source: Rahul Tripathy @ https://stackoverflow.com/questions/32324614/how-to-validate-ipv6-address-in-angularjs#answer-32324868
+ // May Neptune have mercy on my soul...
+ $scope.IPPattern = /^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\:){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?|((25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)$/
Review comment:
don't you define this pattern in serverutils as well? want to just import serverutils into this file?
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] ocket8888 commented on a change in pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#discussion_r450530525
##########
File path: traffic_portal/app/src/common/modules/form/iso/FormISOController.js
##########
@@ -17,36 +17,52 @@
* under the License.
*/
-var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel) {
+var FormISOController = function(servers, osversions, $scope, $anchorScroll, formUtils, toolsService, messageModel, serverUtils) {
+
+ // This RegExp matches any valid IPv4 or IPv6 address
+ // Source: Rahul Tripathy @ https://stackoverflow.com/questions/32324614/how-to-validate-ipv6-address-in-angularjs#answer-32324868
+ // May Neptune have mercy on my soul...
+ $scope.IPPattern = /^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\:){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])$|^\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)(\.(25[0-5]|2[0-4]\d|1\d\d|[1-9]?\d)){3}))|:)))(%.+)?|((25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)\.){3}(25[0-5]|2[0-4][0-9]|[0-1]?[0-9][0-9]?)$/
Review comment:
Yeah, that got messed up in the rebase.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org
[GitHub] [trafficcontrol] ocket8888 commented on a change in pull request #4783: Update Traffic Portal ISOs form for server interfaces
Posted by GitBox <gi...@apache.org>.
ocket8888 commented on a change in pull request #4783:
URL: https://github.com/apache/trafficcontrol/pull/4783#discussion_r451654560
##########
File path: traffic_portal/app/src/common/modules/form/iso/form.iso.tpl.html
##########
@@ -28,163 +28,162 @@
<br>
<form name="isoForm" class="form-horizontal form-label-left" novalidate>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.server), 'has-feedback': hasError(isoForm.server)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Copy Server Attributes From</label>
+ <label for="server" class="control-label col-md-2 col-sm-2 col-xs-12">Copy Server Attributes From</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="server" class="form-control" ng-change="copyServerAttributes()" ng-model="selectedServer" ng-options="server as fqdn(server) for server in servers">
- <option value="">Select (optional)...</option>
+ <select name="server" id="server" class="form-control" ng-change="copyServerAttributes()" ng-model="selectedServer" ng-options="server as fqdn(server) for server in servers">
+ <option selected value="">Select (optional)...</option>
</select>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.osversionDir), 'has-feedback': hasError(isoForm.osversionDir)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">OS Version *</label>
+ <label for="osversionDir" class="control-label col-md-2 col-sm-2 col-xs-12">OS Version *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <select name="osversionDir" class="form-control" ng-model="iso.osversionDir" required>
- <option value="">Select...</option>
+ <select name="osversionDir" id="osversionDir" class="form-control" ng-model="iso.osversionDir" required>
+ <option hidden disabled selected value="">Select...</option>
<option ng-repeat="(key, value) in osversions" value="{{::value}}">{{::key}}</option>
</select>
<small class="input-error" ng-show="hasPropertyError(isoForm.osversionDir, 'required')">Required</small>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.hostName), 'has-feedback': hasError(isoForm.hostName)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Hostname *</label>
+ <label for="hostName" class="control-label col-md-2 col-sm-2 col-xs-12">Hostname *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <input name="hostName" type="text" class="form-control" ng-model="iso.hostName" required autofocus>
+ <input id="hostName" name="hostName" type="text" class="form-control" ng-model="iso.hostName" required>
<small class="input-error" ng-show="hasPropertyError(isoForm.hostName, 'required')">Required</small>
<span ng-show="hasError(isoForm.hostName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
</div>
</div>
<div class="form-group" ng-class="{'has-error': hasError(isoForm.domainName), 'has-feedback': hasError(isoForm.domainName)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">Domain *</label>
+ <label for="domainName" class="control-label col-md-2 col-sm-2 col-xs-12">Domain *</label>
<div class="col-md-10 col-sm-10 col-xs-12">
- <input name="domainName" type="text" class="form-control" ng-model="iso.domainName" required autofocus>
+ <input id="domainName" name="domainName" type="text" class="form-control" ng-model="iso.domainName" required>
<small class="input-error" ng-show="hasPropertyError(isoForm.domainName, 'required')">Required</small>
<span ng-show="hasError(isoForm.domainName)" class="form-control-feedback"><i class="fa fa-times"></i></span>
</div>
</div>
- <div class="form-group" ng-class="{'has-error': hasError(isoForm.dhcp), 'has-feedback': hasError(isoForm.dhcp)}">
- <label class="control-label col-md-2 col-sm-2 col-xs-12">DHCP *</label>
- <div class="col-md-10 col-sm-10 col-xs-12">
- <select name="dhcp" class="form-control" ng-model="iso.dhcp" ng-options="x.value as x.label for x in falseTrue" required>
- <option value="">Select...</option>
- </select>
- <small class="input-error" ng-show="hasPropertyError(isoForm.dhcp, 'required')">Required</small>
+ <div class="form-group">
+ <label for="dhcp" class="control-label col-md-2 col-sm-2 col-xs-12" style="padding-top: 0">DHCP</label>
+ <div class="col-md-10 col-sm-10 col-xs-12" style="width: auto">
+ <input type="checkbox" id="dhcp" name="dhcp" ng-model="iso.dhcp"/>
</div>
</div>
- <div class="form-group" ng-show="!isDHCP(iso)" ng-class="{'has-error': hasError(isoForm.ipAddress), 'has-feedback': hasError(isoForm.ipAddress)}">
+ <div class="form-group" ng-if="!iso.dhcp" ng-class="{'has-error': hasError(isoForm.ipAddress), 'has-feedback': hasError(isoForm.ipAddress)}">
Review comment:
Should be fixed.
----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
For queries about this service, please contact Infrastructure at:
users@infra.apache.org