<div ng-controller="EditLoanChargeController">
    <div>
        <ul class="breadcrumb">
            <li><a href="#/viewloanaccount/{{loanId}}">{{'label.anchor.viewloanaccount' | translate}}</a></li>
            <li class="active">{{'label.anchor.editloancharge' | translate}}</li>
        </ul>
    </div>
    <form name="loanchargeform" novalidate="" class="form-horizontal well" ng-submit="submit()">
        <api-validate></api-validate>
        <fieldset>
            <legend>{{ 'label.heading.editloancharge' | translate }}</legend>
            <div class="form-group">
                <label class="control-label col-sm-2" for="amount">{{ 'label.input.amount' | translate }}<span
                        class="required">*</span></label>

                <div class="col-sm-3">
                    <input id="amount" ng-autofocus="true" class="form-control" type="text" name="amount" ng-model="formData.amount" required
                           late-Validate/>
                    <form-validate valattributeform="loanchargeform" valattribute="amount"/>
                </div>
            </div>

            <div class="col-md-offset-3">
                <button id="cancel" type="reset" class="btn btn-default" ng-click="cancel()">{{ 'label.button.cancel' | translate
                    }}
                </button>
                <button id="save" type="submit" ng-disabled="!loanchargeform.$valid" has-permission='UPDATE_LOANCHARGE' class="btn btn-primary">{{
                    'label.button.save' | translate }}
                </button>
            </div>
        </fieldset>
    </form>
</div>