apollo_developers/assets/views/branchDetails.html
venbatechnologies@gmail.com 1809bcf9c9 fixed table for student details
2018-04-23 18:34:11 +05:30

329 lines
23 KiB
HTML
Executable File

<style>
b.fa {
display: inline-block;
border-radius: 60px;
box-shadow: 0px 0px 2px #007AFF;
padding: 0.5em 0.6em;
}
</style>
<!-- start: PAGE TITLE -->
<section id="page-title">
<div class="row">
<div class="col-sm-8">
<h1 class="mainTitle" translate="Branch">{{ mainTitle }}</h1>
<span class="mainDescription">Add/View Branch Details. </span>
</div>
<div ncy-breadcrumb></div>
</div>
</section>
<!-- end: PAGE TITLE -->
<!-- start: LIST GROUP -->
<div class="container-fluid container-fullw bg-white">
<div class="row" ng-controller="branchCtrl" data-ng-init="init()">
<tabset class="tabbable">
<tab heading="View Branch" id="viewbranch">
<div class="container-fluid container-fullw">
<div class="row">
<div ng-if="loader == ''" class="col-md-12" align="center">
<!--<img src="assets/images/ajax_loader_blue.gif" style="width: 5%; height: 30%">-->
<spinner name="html5spinner">
<div class="overlay"></div>
<div class="spinner">
<div class="double-bounce1"></div>
<div class="double-bounce2"></div>
</div>
<div class="please-wait">Please Wait...</div>
</spinner>
</div>
<div class="col-md-12" ng-if="emptyData == false && loader != ''" style="min-height: 281px;">
<p style="color: red;" align="center"><strong><h3 class="text-center">oops! No
records found... </h3></strong></p>
</div>
<div class="col-md-12" ng-if="emptyData == true">
<div class="row">
<div class="col-md-3">
<script>
$(function () {
$("#search").focus();
});
</script>
<input class="form-control" type="text" ng-model="search" id="search" autofocus tabindex="1" placeholder="Search" /><br><br>
</div>
</div>
<div class="table-responsive">
<fieldset>
<table class="table table-hover">
<thead>
<tr>
<th ng-click="sort('BranchCode')">Branch Code
<span class="glyphicon sort-icon" ng-show="sortKey=='BranchCode'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th>
<th ng-click="sort('BranchName')">Branch Name
<span class="glyphicon sort-icon" ng-show="sortKey=='BranchName'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th>
<!-- <th ng-click="sort('Address')">Address
<span class="glyphicon sort-icon" ng-show="sortKey=='Address'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th> -->
<th ng-click="sort('EmailID')">Email Id
<span class="glyphicon sort-icon" ng-show="sortKey=='EmailID'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th>
<th ng-click="sort('MobileNumber')">Mobile Number
<span class="glyphicon sort-icon" ng-show="sortKey=='MobileNumber'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th>
<!--<th ng-click="sort('AlternateNumber')">Alternate Mobile
<span class="glyphicon sort-icon" ng-show="sortKey=='AlternateNumber'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th> -->
<th ng-click="sort('LandlineNumber')">Landline Number
<span class="glyphicon sort-icon" ng-show="sortKey=='LandlineNumber'" ng-class="{'glyphicon-chevron-up':reverse,'glyphicon-chevron-down':!reverse}"></span>
</th>
<th>Status</th>
<th>
</th>
</tr>
</thead>
<tbody dir-paginate="p in data|orderBy:sortKey:reverse|filter:search:strict|itemsPerPage:10">
<tr>
<td>{{p.BranchCode}}</td>
<td>{{p.BranchName}}</td>
<!-- <td>{{p.Address}}</td> -->
<td>{{p.EmailID}}</td>
<td>{{p.MobileNumber}}</td>
<!-- <td>{{p.AlternateNumber}}</td>-->
<td>{{p.LandlineNumber}}</td>
<td><span ng-if="p.IsActive == 1"> Active </span><span ng-if="p.IsActive == 0">In-Active</span></td>
<td>
<a class="text-azure" id="editRowBtn{{p.BranchCode}}" ng-click="setEditId(p.BranchCode);"><b class="fa fa-hover fa-pencil " aria-hidden="true"></b>
</a></td>
</tr>
<tr ng-show="editId === p.BranchCode" ng-if="editId === p.BranchCode" style="width: ">
<td colspan="12" ng-include src="'assets/views/editBranchDetails.html'"></td>
</tr>
</tbody>
</table>
</fieldset>
<dir-pagination-controls max-size="10" direction-links="true" boundary-links="true">
</dir-pagination-controls>
</div>
</div>
</div>
</div>
<!--
view tab end
-->
</tab>
<script>
$('#addbranch').click(function () {
$('#branchcode').focus();
});
</script>
<tab heading="Add Branch" id="addbranch">
<div>
<form name="Form" id="form" novalidate ng-submit="branchForm.submit(Form, myModel, 'zoom-in')" method="post">
<div class="row">
<!--<div class="col-md-6">
<div class="padding-30">
<h2 class="StepTitle"><i
class="ti-face-smile fa-2x text-primary block margin-bottom-10"></i>
Enter Bus Stop Details</h2>
</div>
</div>-->
<div class="col-md-12">
<fieldset>
<legend>
Add New Branch Details
</legend>
<div class="row">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.branchcode.$dirty && Form.branchcode.$invalid, 'has-success':Form.branchcode.$valid}">
<label>
Branch Code <span class="symbol required"></span>
</label>
<input type="text" placeholder="Enter Branch Code" tabindex="1" class="form-control" name="branchcode" ng-model="myModel.branchCode"
ng-pattern="/^[a-zA-Z0-9.\s]*$/" required/>
<span class="error text-small block" ng-if="Form.branchcode.$dirty && Form.branchcode.$error.required">Branch code is required</span>
<span class="error text-small block" ng-if="Form.branchcode.$dirty && Form.branchcode.$error.pattern">Invalid branch code </span>
<!--<span class="success text-small"-->
<!--ng-if="Form.stopname.$valid">Thank You!</span>-->
</div>
<div class="col-md-4 form-group" ng-class="{'has-error':Form.branchname.$dirty && Form.branchname.$invalid, 'has-success':Form.branchname.$valid}">
<label>
Branch Name <span class="symbol required"></span>
</label>
<input type="text" placeholder="Enter Branch Name" tabindex="2" class="form-control" name="branchname" ng-model="myModel.branchName"
ng-pattern="/^[a-zA-Z0-9.\s]*$/" required/>
<span class="error text-small block" ng-if="Form.branchname.$dirty && Form.branchname.$error.required">Branch name is required</span>
<span class="error text-small block" ng-if="Form.branchname.$dirty && Form.branchname.$error.pattern">Invalid branch name </span>
<!--<span class="success text-small"-->
<!--ng-if="Form.stopname.$valid">Thank You!</span>-->
</div>
<div class=" col-md-4 form-group" ng-class="{'has-error':Form.Email.$dirty && Form.Email.$invalid, 'has-success':Form.Email.$valid}">
<label>
Email ID <span class="symbol required"></span>
</label>
<input type="email" tabindex="3" placeholder="Enter Email ID" class="form-control" name="Email" ng-pattern="/^[-a-z0-9~!$%^&*_=+}{\'?]+(\.[-a-z0-9~!$%^&*_=+}{\'?]+)*@([a-z0-9_][-a-z0-9_]*(\.[-a-z0-9_]+)*\.(aero|arpa|biz|com|coop|edu|gov|info|int|mil|museum|name|net|org|pro|travel|mobi|[a-z][a-z])|([0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}\.[0-9]{1,3}))(:[0-9]{1,5})?$/i"
ng-model="myModel.email" required>
<span class="error text-small block" ng-if="Form.Email.$dirty && Form.Email.$invalid" ng-hide="Form.Email.$error.email">Email is required.</span>
<span class="error text-small block" ng-if="Form.Email.$error.email">Please, enter a valid email address.</span>
<!--<span style="color:#000" class="success text-small"
ng-if="Form.primaryEmail.$valid">It's a valid e-mail!</span>-->
</div>
</div>
<div class="row">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.primaryPhone.$dirty && Form.primaryPhone.$invalid, 'has-success':Form.primaryPhone.$valid}">
<label>
Mobile Number <span
class="symbol required"></span>
</label>
<input type="text" name="primaryPhone" tabindex="4" placeholder="Enter Mobile Number" class="form-control" ng-model="myModel.primaryPhone"
ng-minlength="10" ng-maxlength="12" ng-pattern="/^[0-9]*$/" required>
<span class="error text-small block" ng-if="Form.primaryPhone.$dirty && Form.primaryPhone.$invalid" ng-hide="Form.primaryPhone.$error.maxlength || Form.primaryPhone.$error.minlength || Form.primaryPhone.$error.pattern">Phone number is required.</span>
<span class="error text-small block" ng-if="Form.primaryPhone.$error.maxlength || Form.primaryPhone.$error.minlength || Form.primaryPhone.$error.pattern">Enter a valid phone number</span>
<!-- <span class="success text-small"
ng-if="Form.primaryPhone.$valid">Thank You!</span>-->
</div>
<div class="col-md-4 form-group" ng-class="{'has-error':Form.secondaryPhone.$dirty && Form.secondaryPhone.$invalid, 'has-success':Form.secondaryPhone.$valid}">
<label class="control-label">
Alternate Mobile Number
</label>
<input type="text" name="secondaryPhone" tabindex="5" placeholder="Enter Alternate Mobile Number" class="form-control" ng-model="myModel.secondaryPhone"
ng-minlength="10" ng-maxlength="12" ng-pattern="/^[0-9]*$/" />
<span class="error text-small block" ng-if="Form.secondaryPhone.$error.maxlength || Form.secondaryPhone.$error.minlength || Form.secondaryPhone.$error.pattern">Enter a valid phone number</span>
</div>
<div class="col-md-4 form-group" ng-class="{'has-error':Form.Landline.$dirty && Form.Landline.$invalid, 'has-success':Form.Landline.$valid}">
<label class="control-label">
Landline Number
</label>
<input type="text" name="Landline" tabindex="6" placeholder="Enter Landline Number" class="form-control" ng-model="myModel.landLine"
ng-minlength="11" ng-maxlength="13" ng-pattern="/^[0-9-]*$/" />
<span class="error text-small block" ng-if="Form.Landline.$error.maxlength || Form.Landline.$error.minlength || Form.Landline.$error.pattern">Enter a valid number</span>
</div>
</div>
<div class="row">
<div class="col-md-4 form-group" ng-class="{'has-error':Form.address.$dirty && Form.address.$invalid, 'has-success':Form.address.$valid}">
<label>
Address<span class="symbol required"></span>
</label>
<textarea placeholder="Enter Address" tabindex="7" class="form-control textdsc" name="address" ng-model="myModel.address"
required></textarea>
<span class="error text-small block" ng-if="Form.address.$dirty && Form.address.$invalid">Address is required</span>
<!--<span class="success text-small"-->
<!--ng-if="Form.address.$valid">Thank You!</span>-->
</div>
<div class="col-md-4">
<label>
Active/De-Active
</label>
<div ng-switch="myModel.switchsetting">
<div ng-switch-when="true">
<switch ng-model="myModel.switchsetting" ng-init="myModel.switchsetting = true" class="green"></switch>
</div>
<div ng-switch-when="false">
<switch ng-model="myModel.switchsetting" ng-init="myModel.switchsetting = false" class="green"></switch>
</div>
<div ng-switch-default>
<switch ng-model="myModel.switchsetting" ng-init="myModel.switchsetting = true" class="green"></switch>
</div>
</div>
</div>
<div class="col-md-3">
<form name="Form" id="form1" novalidate ng-submit="form.submit(Form,myModel)" method="post">
<div class="file-upload">
<div class="row">
<div class="col-md-6">
<div class="form-group">
<div class="user-image">
<h5>Branch Logo</h5>
<div class=" margin-bottom-5">
</div>
</div>
<!--<input type="file" file-model="idProof"
accept="image/*" onchange="angular.element(this).scope().imageUpload(event)"/>-->
<div>
<div ng-repeat="step in stepsModel">
<!--<a class="close-thin"></a>-->
<img class="thumb" ng-src="{{step}}" />
<div class="col-md-12">
<div class="pull-right">
<button class="btn btn-success btn-o btn-sm margin-right-15" type="button" ng-click="resetImage()">Reset
</button>
</div>
</div>
</div>
</div>
<input type="file" accept="image/*" file-upload onchange="angular.element(this).scope().imageUpload(event)" />
<style>
.thumb {
width: 130px;
height: 140px;
margin: 18px;
float: left;
}
.uploader {
clear: both;
}
</style>
</div>
</div>
</div>
</div>
</form>
</div>
</div>
<div class="col-md-12">
<div class="pull-right">
<button type="submit" ladda="ldloading1.zoom_in" tabindex="9" class="btn btn-wide btn-success" data-style="zoom-in">
Add
</button>
<!-- <button type="submit" class="btn btn-success btn-o" tabindex="8">
Submit
</button>-->
<button type="reset" class="btn btn-warning btn-wide" tabindex="10" ng-click="branchForm.reset(Form)">
Reset
</button>
</div>
</div>
</fieldset>
</div>
</div>
</form>
</div>
</tab>
</tabset>
</div>
</div>
<!-- end: LIST GROUP -->