103 lines
4.8 KiB
HTML
103 lines
4.8 KiB
HTML
<form class="form-horizontal" role=form>
|
|
<h2>Purchase Return Edit / New</h2>
|
|
|
|
<div class="form-group">
|
|
<label for="txtDate" class="col-md-2 control-label">Date / From</label>
|
|
|
|
<div class="col-md-4">
|
|
<div class="input-group">
|
|
<input class="form-control" id="txtDate" type="text" datepicker-popup="dd-MMM-yyyy"
|
|
ng-model="voucher.Date"/>
|
|
<span class="input-group-btn">
|
|
<button class="btn btn-default"><i class="glyphicon glyphicon-calendar"></i></button>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
<div class="col-md-6" ng-repeat="journal in voucher.Journals | journalDebit:1">
|
|
<div class="input-group">
|
|
<input type="text" class="form-control" ng-model="journal.Ledger"
|
|
typeahead="account as account.Name for account in accounts($viewValue)"
|
|
typeahead-editable="false"/><span class="input-group-addon">₹</span><input type="text"
|
|
class="form-control"
|
|
placeholder="Amount"
|
|
ng-model="journal.Amount"/>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<div class="form-group">
|
|
<label for="txtBatch" class="col-md-2 control-label">Batch</label>
|
|
|
|
<div class="col-md-6">
|
|
<input type="text" id="txtBatch" class="form-control" ng-model="batch"
|
|
typeahead="batch as batch.Name for batch in batches($viewValue)"
|
|
typeahead-editable="false"/>
|
|
</div>
|
|
<div class="col-md-4">
|
|
<div class="input-group">
|
|
<input type="text" class="form-control" placeholder="Quantity" ng-model="quantity" on-return="add()"/>
|
|
<span class="input-group-btn">
|
|
<button class="btn btn-info" ng-click="add()">Add <i class="glyphicon glyphicon-plus-sign"></i>
|
|
</button>
|
|
</span>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
<table class="table table-condensed table-bordered table-striped">
|
|
<thead>
|
|
<tr>
|
|
<th>Product</th>
|
|
<th>Quantity</th>
|
|
<th>Rate</th>
|
|
<th>Tax</th>
|
|
<th>Discount</th>
|
|
<th>Amount</th>
|
|
<th>Delete</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody id="tbodyMain">
|
|
<tr ng-repeat="inventory in voucher.Inventories">
|
|
<td>{{inventory.Product.Name}}</td>
|
|
<td class="text-right">{{inventory.Quantity | number:2}}</td>
|
|
<td class="text-right">{{inventory.Rate | currency}}</td>
|
|
<td class="text-right">{{inventory.Tax | percent}}</td>
|
|
<td class="text-right">{{inventory.Discount | percent}}</td>
|
|
<td class="text-right">{{inventory.Amount | currency}}</td>
|
|
<td>
|
|
<div class="btn-group">
|
|
<a class="btn btn-danger" ng-click="removeInventory(inventory)"><i
|
|
class="glyphicon glyphicon-trash"></i> Delete</a>
|
|
<a class="btn btn-danger dropdown-toggle" data-toggle="dropdown" href="#"><span
|
|
class="caret"></span></a>
|
|
<ul class="dropdown-menu">
|
|
<li><a ng-click="modal(inventory)"><i class="glyphicon glyphicon-pencil"></i> Edit</a></li>
|
|
</ul>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</tbody>
|
|
<tfoot id="tfootMain">
|
|
</tfoot>
|
|
</table>
|
|
<div class="form-group">
|
|
<label for="txtNarration" class="col-md-2 control-label">Narration</label>
|
|
|
|
<div class="col-md-10">
|
|
<textarea rows="3" id="txtNarration" class="form-control" ng-model="voucher.Narration"></textarea>
|
|
</div>
|
|
</div>
|
|
<div class="form-actions">
|
|
<button class="btn btn-primary" tan-click="save()"
|
|
ng-disabled="preventAlteration(voucher)">{{voucher.VoucherID | save_button}}
|
|
</button>
|
|
<button class="btn btn-inverse" tan-click="post()" ng-hide="!voucher.VoucherID"
|
|
ng-disabled="voucher.Posted || !perms['Post Vouchers']">{{voucher.Posted | posted}}
|
|
</button>
|
|
<button class="btn btn-danger" ng-hide="!voucher.VoucherID" ng-disabled="preventAlteration(voucher)"
|
|
ng-click="confirm()"> Delete
|
|
</button>
|
|
</div>
|
|
<div class="row">
|
|
Created on {{voucher.CreationDate | localTime}} and Last Edited on {{voucher.LastEditDate | localTime}} by
|
|
{{voucher.User.Name}}. Posted by {{voucher.Poster}}
|
|
</div>
|
|
</form> |