<!-- Faraday Penetration Test IDE -->
<!-- Copyright (C) 2013  Infobyte LLC (http://www.infobytesec.com/) -->
<!-- See the file 'doc/LICENSE' for the license information -->

<form name="form" novalidate>
    <div class="modal-header">
        <div class="modal-button">
            <button class="btn btn-success" ng-click="ok()" ng-disabled="form.$invalid">OK</button>
            <button class="btn btn-danger" ng-click="cancel()">Cancel</button>
        </div>
        <h3 class="modal-title">New service</h3>
    </div>
    <div class="modal-body">
        <div class="form-horizontal">
            <div class="form-group" ng-class="{'has-error': form.name.$invalid }">
                <div class="col-md-12">
                    <label class="sr-only" for="service">Name</label>
                    <input type="text" class="form-control" id="service" name="name" placeholder="Name" ng-model="service.name" required/>
                </div>
            </div><!-- .form-group -->
            <div class="form-group">
                <div class="col-md-12">
                    <label class="sr-only" for="description">Description</label>
                    <textarea class="form-control" id="description" placeholder="Description" ng-model="service.description"></textarea>
                </div>
            </div><!-- .form-group -->
            <div class="form-group">
                <div class="col-md-12">
                    <div class="checkbox">
                        <label>
                            <input type="checkbox" id="owned" ng-model="service.owned"/>
                            <span class="normal-size">Owned</span>
                        </label>
                    </div><!-- .checkbox -->
                </div>
            </div><!-- .form-group -->
            <div class="form-group">
                <div class="col-md-3">
                    <h5>Port</h5>
                    <div class="input-margin" ng-class="{'has-error': form.ports.$invalid }">
                        <label class="sr-only" for="ports">Port</label>
                        <input type="number" class="form-control" id="ports" name="ports" placeholder="Port" ng-model="service.ports" required/>
                    </div>
                </div>
                <div class="col-md-3 protocol" ng-class="{'has-error': form.protocol.$invalid }">
                    <h5>Protocol</h5>
                    <label class="sr-only" for="protocol">Protocol</label>
                    <input type="text" class="form-control" id="protocol" name="protocol" placeholder="Protocol" ng-model="service.protocol" required/>
                </div>
                <div class="col-md-3">
                    <h5>Version</h5>
                    <label class="sr-only" for="version">Version</label>
                    <input type="text" class="form-control" id="version" placeholder="Version" ng-model="service.version"/>
                </div>
                <div class="col-md-3">
                    <h5>Status</h5>
                    <label class="sr-only" for="status">Status</label>
                    <input type="text" class="form-control" id="status" placeholder="Status" ng-model="service.status"/>
                </div>
            </div><!-- .form-group -->
        </div>
    </div><!-- .modal-body -->
    <div class="modal-footer">
        <div class="modal-button">
            <button class="btn btn-success" ng-disabled="form.$invalid" ng-click="ok()">OK</button>
            <button class="btn btn-danger" ng-click="cancel()">Cancel</button>
        </div>
    </div>
</form>
