Add Inventory Management Form
Add Inventory Management Form
pc)-------------------------------------------------------
<!-- <script type="text/ng-template" id="[Link]">
<div class="modal-header">
<button type="button" class="close" data-dismiss="modal" aria-
label="Close" ng-click="[Link]()"><span
aria-hidden="true">×</span></button>
<h3 class="modal-title" id="modal-title">Inventory</h3>
</div>
<div class="modal-body immigrantModalBody" id="modal-body">
<div class="row">
<div class="col-sm-12">
<form name = "addInventory" >
<div class="form-group required">
<label for="device" class="col-sm-12 col-xs-12 plr0">Select
Device</label>
<ui-select ng-model="[Link]"
class="col-sm-12 col-xs-12 plr0" theme="select2"
style="min-width: 300px;" on-select
="[Link]($item)" ng-disabled = "[Link]">
<ui-select-match placeholder="Select Device">
{{[Link]}}</ui-select-match>
<ui-select-choices repeat="option in devices |
filter : $[Link]">
<div class="signupTeamDropdown" ng-bind-
html="[Link] | highlight: $[Link]">
</div>
</ui-select-choices>
</ui-select>
<div class="clearfix"></div>
</div>
<div class="form-group required">
<label for="companyName">Company Name</label>
<input type="text" class="form-control" name="companyName"
placeholder="Company Name" maxlength="100" ng-
model="[Link]" required>
</div>
<div class="form-group required">
<label for="SerialNo.">Serial No.</label>
<input type="text" class="form-control" name="serialNo"
placeholder="Inventory Serial No." maxlength="50" ng-
model="[Link]">
</div>
<div class="form-group">
<label for="purchasedDate" class="col-sm-12 col-xs-12
plr0">Purchased Date</label>
<p class="input-group">
<input type="text" class="form-control" uib-datepicker-
popup="{{[Link]}}" ng-model="[Link]"
is-open="[Link]"
datepicker-options="[Link]" ng-required="true" placeholder="Purchased Date"
/>
<span class="input-group-btn">
<button type="button" class="btn btn-default
signupCalendarBtn" ng-click="[Link]($event, 'purchasedDate')">
<i class="glyphicon
glyphicon-calendar"></i></button>
</span>
</p>
</div>
<div class="form-group">
<label for="purchasedDate" class="col-sm-12 col-xs-12
plr0">Warranty End Date</label>
<p class="input-group">
<input type="text" class="form-control" disable-key
uib-datepicker-popup="{{[Link]}}" ng-model="[Link]" is-
open="[Link]" datepicker-
options="[Link]" ng-required="true" placeholder="Warranty End Date" />
<span class="input-group-btn">
<button type="button" class="btn btn-default
signupCalendarBtn" ng-click="[Link]($event, 'warrantyDate')"><i
class="glyphicon glyphicon-calendar"></i></button>
</span>
</p>
</div>
<div class="form-group">
<label for="price">Price</label>
<input type="text" class="form-control" ng-
model="[Link]" placeholder="Price" valid-decimal-number max-
length="1000" maxlength="10">
</div>
<div class="form-group" ng-if="[Link] ==
'System' || [Link] == 'Internal System'">
<div>
<label for="config">Configurations : </label>
</div>
<div class="form-group required col-sm-6 col-xs-12 pl0
plr0Small" ng-if="[Link] == 'System' ||
[Link] == 'Internal System'">
<label for="[Link]" ng-if ="[Link]
== 'RAM' || [Link] == 'System'">Ram</label>
<input type="text" class="form-control" ng-
model="[Link]" placeholder="Ram"
ng-if ="[Link] == 'RAM' ||
[Link] == 'System'"><br>
<label for="[Link]" ng-if ="[Link]
== 'HDD' || [Link] == 'System'">Hard Disk</label>
<input type="text" class="form-control" ng-
model="[Link]" placeholder="Hard Disk"
ng-if ="[Link] == 'HDD' ||
[Link] == 'System'"><br>
</div>
<div class="form-group required col-sm-6 col-xs-12 pl0
plr0Small" ng-if="[Link] == 'System'">
<label for="[Link]">Model No.</label>
<input type="text" class="form-control" ng-
model="[Link]" placeholder="Model Number"><br>
<label for="[Link]">Processor</label>
<input type="text" class="form-control" ng-
model="[Link]" placeholder="Processor"><br>
</div>
</div>
</form>
</div>
</div>
</div>
<div class="modal-footer">
<button class="btn btn-primary" type="button"
ng-click="[Link]()">Save</button>
<button class="btn btn-warning" type="button" ng-
click="[Link]()">Cancel</button>
</div>
</script> -->
// [Link] = {
// formatYear: 'yy',
// showWeeks: false,
// startingDay: 0
// };
// [Link] = {
// warrantyDate: {
// value: false
// },
// purchasedDate: {
// value: false
// }
// };
// [Link] = function ($event, val) {
// [Link][val].value = true;
// };
// [Link] = function () {
// $[Link]();
// };
// [Link] = {};
// [Link] = row;
// [Link]([Link], "row . configs");
// [Link] = function (item) {
// [Link] = [Link];
// [Link] = [Link];
// }
// // $[Link] = {};
// [Link] = moment([Link],
"DD/MM/YYYY").format("DD-MMM-YYYY");
// [Link] = moment([Link],
"DD/MM/YYYY").format("DD-MMM-YYYY");
// [Link] = moment([Link],
$[Link]).toDate();
// [Link] =
moment([Link],
$[Link]).toDate();
// [Link] = function () {
// if (
// [Link] == undefined ||
// [Link] == undefined ||
[Link] == undefined
// ) {
// [Link]("Please fill the required
fields");
// } else {
// // $[Link] = row._id;
// let reqObject = {};
// [Link] = row._id;
// let obj = {};
// // [Link] = $[Link];
// // [Link] = $[Link];
// // [Link] =
$[Link];
// // [Link] =
$[Link];
// // [Link] =
moment($[Link]).format("YYYY-MM-DD");
// // [Link] =
moment($[Link]).format("YYYY-MM-DD");
// // [Link] = $[Link];
// // [Link] = $[Link];
// // if ($[Link] == true) {
// // let configs = {};
// // [Link] =
$[Link];
// // [Link] =
$[Link];
// // [Link] =
$[Link];
// // [Link] =
$[Link];
// // [Link] = configs
// // } else if ([Link] == "Internal System")
{
// // let configs = {};
// // [Link] =
$[Link];
// // [Link] = configs;
// // }
// [Link] = [Link];
// [Link]("edit object", obj);
// //
[Link]($[Link], function (data) {
// [Link](reqObject, function
(data) {
// if (data) {
// [Link]("Updated
successfully!")
// [Link]();
// }
// }, function (err) {
// [Link]("Error occurred!")
// })
// }
// }
// },
// controllerAs: 'pc',
// size: 'md',
// scope: $scope,
// });
// [Link](function (result) {
// [Link]();
// });
// }
----------------------------------assignInventory(in
ManageInvrequestCTrl)------------------------------
// $[Link] = function (row) {
// var modalInstance = $[Link]({
// animation: true,
// ariaLabelledBy: "modal-title",
// ariaDescribedBy: "modal-body",
// templateUrl: "[Link]",
// backdrop: 'static',
// keyboard: false,
// controller: function ($scope, $uibModalInstance, InventoryFactory,
notificationService, EmployeeFactory) {
// $[Link] = false;
// $[Link] = {
// formatYear: 'yy',
// showWeeks: false,
// startingDay: 0
// };
// $[Link] = {
// warrantyDate: {
// value: false
// },
// purchasedDate: {
// value: false
// }
// };
// $[Link] = function ($event, val) {
// $[Link][val].value = true;
// };
// $[Link] = function () {
// $[Link]();
// };
// $[Link] = [];
// [Link]({ employeeId: 0 },
function (data) {
// if (data && [Link] && [Link] > 0) {
// $[Link] = [Link];
// }
// });
// function getassignDetails() {
// $[Link] = [];
// let obj = {}
// [Link] = row._id
// [Link](obj, function
(data) {
// $[Link] = [];
// [Link](element => {
// [Link] =
moment([Link]).format($[Link][1]);
// [Link] =
moment([Link]).format($[Link][1]);
// $[Link](element);
// });
// }, function (err) {
// [Link]("Error Occurred!")
// })
// }
// getassignDetails();
// let object = {}
// [Link] = row._id;
// [Link](object, function
(data) {
// if ([Link] == 0 || data[0].returnDate != null) {
// $[Link] = true;
// let assignObj = {}
// [Link](assignObj, function (data) {
// [Link]("Assigned successfully!")
// getassignDetails();
// }, function (err) {
// [Link]("Error in assigning!")
// })
// }
// }, function (err) {
// [Link]("Error occurred!")
// })
// },
// controllerAs: 'pc',
// size: 'md',
// scope: $scope,
// });
// [Link](function (result) {
// // [Link]();
// });
// }
// [Link] = [];