Bug Fix #87 - Scroll multiple devices on create job
This commit is contained in:
1 parent
687713428b
commit
0a67e9544d
5 files changed
+575
-554
No files matched your search
@@ -461,8 +461,10 @@
|
|||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments {
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments {
|
||||||
margin-top: 6px;
|
margin-top: 6px;
|
||||||
background-color: #fff;
|
background-color: #fff;
|
||||||
line-height: 1.3em;
|
line-height: 1.3;
|
||||||
border: 1px solid #ddd;
|
border: 1px solid #ddd;
|
||||||
|
max-height: 300px;
|
||||||
|
overflow-y: auto;
|
||||||
}
|
}
|
||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment {
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment {
|
||||||
display: block;
|
display: block;
|
||||||
@@ -475,16 +477,14 @@
|
|||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment:hover {
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment:hover {
|
||||||
background-color: #f4f4f4;
|
background-color: #f4f4f4;
|
||||||
}
|
}
|
||||||
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment tr:first-child td {
|
||||||
|
width: 68px;
|
||||||
|
}
|
||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment td:first-child {
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment td:first-child {
|
||||||
width: 90px;
|
width: 90px;
|
||||||
font-weight: 600;
|
font-weight: 600;
|
||||||
}
|
}
|
||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment img.CreateJob_Assignment_Image {
|
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment img.CreateJob_Assignment_Image {
|
||||||
float: left;
|
|
||||||
width: 64px;
|
width: 64px;
|
||||||
height: 64px;
|
height: 64px;
|
||||||
margin-right: 6px;
|
|
||||||
}
|
|
||||||
#User_Show_Details_Actions_CreateJob_Dialog #CreateJob_Assignments li.CreateJob_Assignment div.CreateJob_Assignment_Details {
|
|
||||||
float: left;
|
|
||||||
}
|
}
|
||||||
@@ -487,8 +487,10 @@
|
|||||||
#CreateJob_Assignments {
|
#CreateJob_Assignments {
|
||||||
margin-top: 6px;
|
margin-top: 6px;
|
||||||
background-color: @white;
|
background-color: @white;
|
||||||
line-height: 1.3em;
|
line-height: 1.3;
|
||||||
border: 1px solid #ddd;
|
border: 1px solid #ddd;
|
||||||
|
max-height: 300px;
|
||||||
|
overflow-y: auto;
|
||||||
|
|
||||||
li.CreateJob_Assignment {
|
li.CreateJob_Assignment {
|
||||||
display: block;
|
display: block;
|
||||||
@@ -503,20 +505,18 @@
|
|||||||
background-color: @TableDataBorderColour;
|
background-color: @TableDataBorderColour;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
tr:first-child td {
|
||||||
|
width: 68px;
|
||||||
|
}
|
||||||
|
|
||||||
td:first-child {
|
td:first-child {
|
||||||
width: 90px;
|
width: 90px;
|
||||||
font-weight: @FontWeightBodyBold;
|
font-weight: @FontWeightBodyBold;
|
||||||
}
|
}
|
||||||
|
|
||||||
img.CreateJob_Assignment_Image {
|
img.CreateJob_Assignment_Image {
|
||||||
float: left;
|
|
||||||
width: 64px;
|
width: 64px;
|
||||||
height: 64px;
|
height: 64px;
|
||||||
margin-right: 6px;
|
|
||||||
}
|
|
||||||
|
|
||||||
div.CreateJob_Assignment_Details {
|
|
||||||
float: left;
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
+1
-1
@@ -1 +1 @@
|
|||||||
.tableData{border:solid 1px #f4f4f4;border-collapse:collapse;}.tableData>tbody>tr>td{border:solid 1px #f4f4f4;background-color:#fff;}.tableData>tbody>tr:nth-child(odd)>td{background-color:#fcfcfc;}.tableData>thead>tr>th,.tableData>tbody>tr>th{background-color:#f4f4f4;border:solid 1px #f4f4f4;}.tableData>tbody>tr:hover>td{background-color:#fefefe;}.tableData>tbody>tr:hover:nth-child(odd)>td{background-color:#fafafa;}.tableData>tfoot>tr>th,.tableData>tfoot>tr>td{background-color:#f4f4f4;}.tableDataDark{border:solid 1px #d8d8d8;border-collapse:collapse;}.tableDataDark td{border:solid 1px #d8d8d8;background-color:#fff;}.tableDataDark th{background-color:#eee;border:solid 1px #d8d8d8;}.tableDataContainer{background-color:#fff;}.tableDataVertical{border:solid 1px #f4f4f4;border-collapse:collapse;}.tableDataVertical>tbody>tr:nth-child(odd){background-color:#f4f4f4;margin:0;padding:0;}.tableDataVertical>tbody>tr>th.name{width:170px;text-align:right;}.tableDataVertical table.sub>tbody>tr:not(:first-child)>th,.tableDataVertical table.sub>tbody>tr:not(:first-child)>td{border-top:1px dashed #aaa;}.tableDataVertical table.sub>tbody>tr>th{font-weight:normal;text-align:right;}.tableDataVertical table.sub>tbody>tr>th.name{text-align:right;}.icon16{display:inline-block;height:16px;width:16px;margin-left:2px;cursor:pointer;}.subtleUntilHover{-moz-opacity:.3;opacity:.3;}.subtleUntilHover:hover{-moz-opacity:1;opacity:1;}#layout_PageHeading #User_Show_Flags{display:inline-block;float:right;height:50px;font-size:.6em;}#layout_PageHeading #User_Show_Flags>i{cursor:default;}#layout_PageHeading #User_Show_Flags>i>.details{display:none;}#User_Show #User_Show_Subjects{table-layout:fixed;}#User_Show #User_Show_Subjects>tbody>tr>td{padding-top:0;height:100%;}#User_Show #User_Show_Subjects>tbody>tr>td>div{position:relative;}#User_Show #User_Show_Subjects>tbody>tr>td>div div.status{margin-top:2px;padding-top:2px;border-top:1px dashed #ddd;}#User_Show #User_Show_Subjects>tbody>tr>td>div input.discreet{margin-left:-2px;}#User_Show #User_Show_Subjects>tbody>tr>td:not(:last-child){border-right:1px dashed #aaa;}#User_Show #User_Show_Subjects #User_Show_Details{width:330px;}#User_Show #User_Show_Subjects #User_Show_Details table.verticalHeadings>tbody>tr>td:first-child{width:104px;font-weight:600;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_Details_Identity_Id{font-weight:600;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_GenerateDocument_Container{padding-top:4px;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_GenerateDocument_Container #User_Show_GenerateDocument{padding:0;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_Details_Actions{margin-top:4px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment{border-bottom:1px dashed #ddd;padding:4px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment td:first-child{width:90px;font-weight:600;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment img.User_Show_AssignedDevices_CurrentAssignment_Image{float:left;width:64px;height:64px;margin-right:6px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment div.User_Show_AssignedDevices_CurrentAssignment_Details{float:left;}#User_Show #User_Show_Subjects #User_Show_Subjects_Actions>td{padding-top:4px;}#UserDetailTabs{margin-top:10px;border-radius:0;background-image:none;background-color:#fff;border:none;padding:0;}#UserDetailTabs #UserDetailTabItems{border-radius:0;border-top:1px solid #ddd;border-right:1px solid #ddd;border-left:1px solid #ddd;border-bottom:none;padding:2px 0 0 4px;background-image:none;background-color:#eee;display:table;}#UserDetailTabs #UserDetailTabItems>li{top:0;border-radius:0;margin:0 5px 0 0;padding:0;line-height:normal;margin-right:4px;}#UserDetailTabs #UserDetailTabItems>li>a{padding:5px 8px;}#UserDetailTabs div.ui-tabs-panel{border-radius:0;padding:4px;border-right:1px solid #ddd;border-bottom:1px solid #ddd;border-left:1px solid #ddd;border-top:none;background-color:#eee;}#UserDetailTab-JobsContainer div.jobTable{margin:-1px;border:1px solid #ddd;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_filter{margin-top:-24px;-moz-opacity:1;opacity:1;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_length{margin-top:-24px;-moz-opacity:1;opacity:1;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_showStatusClosed{right:220px;margin-top:-24px;}#User_Show_Details_Actions_AddFlag_Dialog{height:400px;}#User_Show_Details_Actions_AddFlag_Dialog .flagPicker{position:absolute;width:250px;height:300px;overflow-y:auto;background-color:#fcfcfc;border:1px solid #ccc;}#User_Show_Details_Actions_AddFlag_Dialog .flagPicker>div{background-color:#fff;border-bottom:1px solid #ddd;padding:6px 0 6px 6px;cursor:pointer;}#User_Show_Details_Actions_AddFlag_Line truncated
|
.tableData{border:solid 1px #f4f4f4;border-collapse:collapse;}.tableData>tbody>tr>td{border:solid 1px #f4f4f4;background-color:#fff;}.tableData>tbody>tr:nth-child(odd)>td{background-color:#fcfcfc;}.tableData>thead>tr>th,.tableData>tbody>tr>th{background-color:#f4f4f4;border:solid 1px #f4f4f4;}.tableData>tbody>tr:hover>td{background-color:#fefefe;}.tableData>tbody>tr:hover:nth-child(odd)>td{background-color:#fafafa;}.tableData>tfoot>tr>th,.tableData>tfoot>tr>td{background-color:#f4f4f4;}.tableDataDark{border:solid 1px #d8d8d8;border-collapse:collapse;}.tableDataDark td{border:solid 1px #d8d8d8;background-color:#fff;}.tableDataDark th{background-color:#eee;border:solid 1px #d8d8d8;}.tableDataContainer{background-color:#fff;}.tableDataVertical{border:solid 1px #f4f4f4;border-collapse:collapse;}.tableDataVertical>tbody>tr:nth-child(odd){background-color:#f4f4f4;margin:0;padding:0;}.tableDataVertical>tbody>tr>th.name{width:170px;text-align:right;}.tableDataVertical table.sub>tbody>tr:not(:first-child)>th,.tableDataVertical table.sub>tbody>tr:not(:first-child)>td{border-top:1px dashed #aaa;}.tableDataVertical table.sub>tbody>tr>th{font-weight:normal;text-align:right;}.tableDataVertical table.sub>tbody>tr>th.name{text-align:right;}.icon16{display:inline-block;height:16px;width:16px;margin-left:2px;cursor:pointer;}.subtleUntilHover{-moz-opacity:.3;opacity:.3;}.subtleUntilHover:hover{-moz-opacity:1;opacity:1;}#layout_PageHeading #User_Show_Flags{display:inline-block;float:right;height:50px;font-size:.6em;}#layout_PageHeading #User_Show_Flags>i{cursor:default;}#layout_PageHeading #User_Show_Flags>i>.details{display:none;}#User_Show #User_Show_Subjects{table-layout:fixed;}#User_Show #User_Show_Subjects>tbody>tr>td{padding-top:0;height:100%;}#User_Show #User_Show_Subjects>tbody>tr>td>div{position:relative;}#User_Show #User_Show_Subjects>tbody>tr>td>div div.status{margin-top:2px;padding-top:2px;border-top:1px dashed #ddd;}#User_Show #User_Show_Subjects>tbody>tr>td>div input.discreet{margin-left:-2px;}#User_Show #User_Show_Subjects>tbody>tr>td:not(:last-child){border-right:1px dashed #aaa;}#User_Show #User_Show_Subjects #User_Show_Details{width:330px;}#User_Show #User_Show_Subjects #User_Show_Details table.verticalHeadings>tbody>tr>td:first-child{width:104px;font-weight:600;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_Details_Identity_Id{font-weight:600;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_GenerateDocument_Container{padding-top:4px;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_GenerateDocument_Container #User_Show_GenerateDocument{padding:0;}#User_Show #User_Show_Subjects #User_Show_Details #User_Show_Details_Actions{margin-top:4px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment{border-bottom:1px dashed #ddd;padding:4px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment td:first-child{width:90px;font-weight:600;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment img.User_Show_AssignedDevices_CurrentAssignment_Image{float:left;width:64px;height:64px;margin-right:6px;}#User_Show #User_Show_Subjects #User_Show_AssignedDevices .User_Show_AssignedDevices_CurrentAssignment div.User_Show_AssignedDevices_CurrentAssignment_Details{float:left;}#User_Show #User_Show_Subjects #User_Show_Subjects_Actions>td{padding-top:4px;}#UserDetailTabs{margin-top:10px;border-radius:0;background-image:none;background-color:#fff;border:none;padding:0;}#UserDetailTabs #UserDetailTabItems{border-radius:0;border-top:1px solid #ddd;border-right:1px solid #ddd;border-left:1px solid #ddd;border-bottom:none;padding:2px 0 0 4px;background-image:none;background-color:#eee;display:table;}#UserDetailTabs #UserDetailTabItems>li{top:0;border-radius:0;margin:0 5px 0 0;padding:0;line-height:normal;margin-right:4px;}#UserDetailTabs #UserDetailTabItems>li>a{padding:5px 8px;}#UserDetailTabs div.ui-tabs-panel{border-radius:0;padding:4px;border-right:1px solid #ddd;border-bottom:1px solid #ddd;border-left:1px solid #ddd;border-top:none;background-color:#eee;}#UserDetailTab-JobsContainer div.jobTable{margin:-1px;border:1px solid #ddd;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_filter{margin-top:-24px;-moz-opacity:1;opacity:1;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_length{margin-top:-24px;-moz-opacity:1;opacity:1;}#UserDetailTab-JobsContainer .dataTables_wrapper .dataTables_showStatusClosed{right:220px;margin-top:-24px;}#User_Show_Details_Actions_AddFlag_Dialog{height:400px;}#User_Show_Details_Actions_AddFlag_Dialog .flagPicker{position:absolute;width:250px;height:300px;overflow-y:auto;background-color:#fcfcfc;border:1px solid #ccc;}#User_Show_Details_Actions_AddFlag_Dialog .flagPicker>div{background-color:#fff;border-bottom:1px solid #ddd;padding:6px 0 6px 6px;cursor:pointer;}#User_Show_Details_Actions_AddFlag_Line truncated
|
||||||
@@ -12,7 +12,8 @@
|
|||||||
<div id="User_Show_Details_Identity">
|
<div id="User_Show_Details_Identity">
|
||||||
<table class="none verticalHeadings">
|
<table class="none verticalHeadings">
|
||||||
<tr>
|
<tr>
|
||||||
<td><span>Username (Id):</span>
|
<td>
|
||||||
|
<span>Username (Id):</span>
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<h4 id="User_Show_Details_Identity_Id" title="Username">@Model.User.UserId</h4>
|
<h4 id="User_Show_Details_Identity_Id" title="Username">@Model.User.UserId</h4>
|
||||||
@@ -111,114 +112,118 @@
|
|||||||
@Html.ActionLinkSmallButton("Create Job", MVC.Job.Create(Model.PrimaryDeviceSerialNumber, Model.User.UserId), "User_Show_Details_Actions_CreateJob_Button")
|
@Html.ActionLinkSmallButton("Create Job", MVC.Job.Create(Model.PrimaryDeviceSerialNumber, Model.User.UserId), "User_Show_Details_Actions_CreateJob_Button")
|
||||||
if (currentDeviceAssignments.Count > 1)
|
if (currentDeviceAssignments.Count > 1)
|
||||||
{
|
{
|
||||||
<div id="User_Show_Details_Actions_CreateJob_Dialog" class="dialog" title="Create Job for Which Device?">
|
<div id="User_Show_Details_Actions_CreateJob_Dialog" class="dialog" title="Create Job for Which Device?">
|
||||||
<div class="clearfix">
|
<div class="clearfix">
|
||||||
<i class="fa fa-info-circle information"></i> Multiple devices are assigned to this user.
|
<i class="fa fa-info-circle information"></i> Multiple devices are assigned to this user.
|
||||||
<br />
|
<br />
|
||||||
<strong>Which device should be associated with this job?
|
<strong>
|
||||||
</strong>
|
Which device should be associated with this job?
|
||||||
|
</strong>
|
||||||
|
</div>
|
||||||
|
<div>
|
||||||
|
<ul id="CreateJob_Assignments" class="none">
|
||||||
|
@foreach (var assignment in currentDeviceAssignments)
|
||||||
|
{
|
||||||
|
<li class="CreateJob_Assignment clearfix" data-createjoburl="@Url.Action(MVC.Job.Create(assignment.DeviceSerialNumber, Model.User.UserId))">
|
||||||
|
<table class="none">
|
||||||
|
<tbody>
|
||||||
|
<tr>
|
||||||
|
<td rowspan="5">
|
||||||
|
<img class="CreateJob_Assignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Serial Number:
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<span>@assignment.Device.SerialNumber</span> (<span>@assignment.Device.ComputerName</span>)
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Model:
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<span>@assignment.Device.DeviceModel.ToString()</span>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Asset:</td>
|
||||||
|
<td>
|
||||||
|
@if (!string.IsNullOrEmpty(assignment.Device.AssetNumber))
|
||||||
|
{
|
||||||
|
<span>@assignment.Device.AssetNumber</span>
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
|
<span class="smallMessage">Unknown</span>
|
||||||
|
}
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
<tr>
|
||||||
|
<td>Assigned:</td>
|
||||||
|
<td>
|
||||||
|
<span>@CommonHelpers.FriendlyDate(assignment.AssignedDate)</span>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
</tbody>
|
||||||
|
</table>
|
||||||
|
</li>}
|
||||||
|
</ul>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
<div>
|
<script>
|
||||||
<ul id="CreateJob_Assignments" class="none">
|
$(function () {
|
||||||
@foreach (var assignment in currentDeviceAssignments)
|
var button = $('#User_Show_Details_Actions_CreateJob_Button');
|
||||||
{
|
var buttonDialog = null;
|
||||||
<li class="CreateJob_Assignment clearfix" data-createjoburl="@Url.Action(MVC.Job.Create(assignment.DeviceSerialNumber, Model.User.UserId))">
|
|
||||||
<img class="CreateJob_Assignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
|
||||||
<div class="CreateJob_Assignment_Details">
|
|
||||||
<table class="none">
|
|
||||||
<tbody>
|
|
||||||
<tr>
|
|
||||||
<td>Serial Number:
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<span>@assignment.Device.SerialNumber</span> (<span>@assignment.Device.ComputerName</span>)
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>Model:
|
|
||||||
</td>
|
|
||||||
<td>
|
|
||||||
<span>@assignment.Device.DeviceModel.ToString()</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>Asset:</td>
|
|
||||||
<td>
|
|
||||||
@if (!string.IsNullOrEmpty(assignment.Device.AssetNumber))
|
|
||||||
{
|
|
||||||
<span>@assignment.Device.AssetNumber</span>
|
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
<span class="smallMessage">Unknown</span>
|
|
||||||
}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
<tr>
|
|
||||||
<td>Assigned:</td>
|
|
||||||
<td>
|
|
||||||
<span>@CommonHelpers.FriendlyDate(assignment.AssignedDate)</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
|
||||||
</li>
|
|
||||||
}
|
|
||||||
</ul>
|
|
||||||
</div>
|
|
||||||
</div>
|
|
||||||
<script>
|
|
||||||
$(function () {
|
|
||||||
var button = $('#User_Show_Details_Actions_CreateJob_Button');
|
|
||||||
var buttonDialog = null;
|
|
||||||
|
|
||||||
button.click(function () {
|
button.click(function () {
|
||||||
if (!buttonDialog) {
|
if (!buttonDialog) {
|
||||||
buttonDialog = $('#User_Show_Details_Actions_CreateJob_Dialog').dialog({
|
buttonDialog = $('#User_Show_Details_Actions_CreateJob_Dialog').dialog({
|
||||||
resizable: false,
|
resizable: false,
|
||||||
width: 400,
|
width: 400,
|
||||||
modal: true,
|
modal: true,
|
||||||
autoOpen: false,
|
autoOpen: false,
|
||||||
buttons: {
|
buttons: {
|
||||||
Cancel: function () {
|
Cancel: function () {
|
||||||
$(this).dialog("close");
|
$(this).dialog("close");
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
});
|
||||||
});
|
|
||||||
|
|
||||||
dialogItems = buttonDialog.find('li.CreateJob_Assignment');
|
dialogItems = buttonDialog.find('li.CreateJob_Assignment');
|
||||||
|
|
||||||
dialogItems.click(function () {
|
dialogItems.click(function () {
|
||||||
var $this = $(this);
|
var $this = $(this);
|
||||||
|
|
||||||
buttonDialog.dialog("close");
|
buttonDialog.dialog("close");
|
||||||
|
|
||||||
var createJobUrl = $this.attr('data-createjoburl');
|
var createJobUrl = $this.attr('data-createjoburl');
|
||||||
document.DiscoFunctions.CreateOpenJobDialog(createJobUrl);
|
document.DiscoFunctions.CreateOpenJobDialog(createJobUrl);
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
buttonDialog.dialog('open');
|
buttonDialog.dialog('open');
|
||||||
return false;
|
return false;
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
</script>
|
||||||
</script>
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
<script>
|
<script>
|
||||||
$(function () {
|
$(function () {
|
||||||
$('#User_Show_Details_Actions_CreateJob_Button').click(function () {
|
$('#User_Show_Details_Actions_CreateJob_Button').click(function () {
|
||||||
var $this = $(this);
|
var $this = $(this);
|
||||||
var href = $this.attr('href');
|
var href = $this.attr('href');
|
||||||
|
|
||||||
document.DiscoFunctions.CreateOpenJobDialog(href);
|
document.DiscoFunctions.CreateOpenJobDialog(href);
|
||||||
|
|
||||||
return false;
|
return false;
|
||||||
|
});
|
||||||
});
|
});
|
||||||
});
|
</script>
|
||||||
</script>
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
@if (Model.User.CanAddUserFlags() && Model.AvailableUserFlags != null && Model.AvailableUserFlags.Count > 0)
|
@if (Model.User.CanAddUserFlags() && Model.AvailableUserFlags != null && Model.AvailableUserFlags.Count > 0)
|
||||||
@@ -324,86 +329,90 @@
|
|||||||
{
|
{
|
||||||
foreach (var assignment in currentDeviceAssignments)
|
foreach (var assignment in currentDeviceAssignments)
|
||||||
{
|
{
|
||||||
<div class="User_Show_AssignedDevices_CurrentAssignment clearfix" data-deviceserialnumber="@assignment.DeviceSerialNumber">
|
<div class="User_Show_AssignedDevices_CurrentAssignment clearfix" data-deviceserialnumber="@assignment.DeviceSerialNumber">
|
||||||
@if (Authorization.Has(Claims.Device.Show))
|
@if (Authorization.Has(Claims.Device.Show))
|
||||||
{
|
{
|
||||||
<a href="@Url.Action(MVC.Device.Show(assignment.Device.SerialNumber))">
|
<a href="@Url.Action(MVC.Device.Show(assignment.Device.SerialNumber))">
|
||||||
|
<img class="User_Show_AssignedDevices_CurrentAssignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
||||||
|
</a>
|
||||||
|
}
|
||||||
|
else
|
||||||
|
{
|
||||||
<img class="User_Show_AssignedDevices_CurrentAssignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
<img class="User_Show_AssignedDevices_CurrentAssignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
||||||
</a>
|
}
|
||||||
}
|
<div class="User_Show_AssignedDevices_CurrentAssignment_Details">
|
||||||
else
|
<table class="none">
|
||||||
{
|
<tbody>
|
||||||
<img class="User_Show_AssignedDevices_CurrentAssignment_Image" alt="Model Image" src="@Url.Action(MVC.API.DeviceModel.Image(assignment.Device.DeviceModel.Id, assignment.Device.DeviceModel.ImageHash()))" />
|
<tr>
|
||||||
}
|
<td>
|
||||||
<div class="User_Show_AssignedDevices_CurrentAssignment_Details">
|
Serial Number:
|
||||||
<table class="none">
|
</td>
|
||||||
<tbody>
|
<td>
|
||||||
<tr>
|
<span class="User_Show_AssignedDevices_CurrentAssignment_SerialNumber">
|
||||||
<td>Serial Number:
|
@if (Authorization.Has(Claims.Device.Show))
|
||||||
</td>
|
{
|
||||||
<td>
|
@Html.ActionLink(assignment.Device.SerialNumber, MVC.Device.Show(assignment.Device.SerialNumber))
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_SerialNumber">
|
}
|
||||||
@if (Authorization.Has(Claims.Device.Show))
|
else
|
||||||
|
{
|
||||||
|
@assignment.Device.SerialNumber
|
||||||
|
}
|
||||||
|
</span>
|
||||||
|
@if (!string.IsNullOrWhiteSpace(assignment.Device.ComputerName))
|
||||||
{
|
{
|
||||||
@Html.ActionLink(assignment.Device.SerialNumber, MVC.Device.Show(assignment.Device.SerialNumber))
|
<text>(<span class="User_Show_AssignedDevices_CurrentAssignment_ComputerName">@assignment.Device.ComputerName</span>)</text>
|
||||||
}
|
}
|
||||||
else
|
|
||||||
{
|
|
||||||
@assignment.Device.SerialNumber
|
|
||||||
}
|
|
||||||
</span>
|
|
||||||
@if (!string.IsNullOrWhiteSpace(assignment.Device.ComputerName))
|
|
||||||
{
|
|
||||||
<text>(<span class="User_Show_AssignedDevices_CurrentAssignment_ComputerName">@assignment.Device.ComputerName</span>)</text>
|
|
||||||
}
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
@if (!string.IsNullOrEmpty(assignment.Device.AssetNumber))
|
|
||||||
{
|
|
||||||
<tr>
|
|
||||||
<td>Asset:</td>
|
|
||||||
<td>
|
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_Asset">@assignment.Device.AssetNumber</span>
|
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
}
|
@if (!string.IsNullOrEmpty(assignment.Device.AssetNumber))
|
||||||
@if (assignment.Device.DeviceModelId.HasValue)
|
{
|
||||||
{
|
<tr>
|
||||||
|
<td>Asset:</td>
|
||||||
|
<td>
|
||||||
|
<span class="User_Show_AssignedDevices_CurrentAssignment_Asset">@assignment.Device.AssetNumber</span>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
}
|
||||||
|
@if (assignment.Device.DeviceModelId.HasValue)
|
||||||
|
{
|
||||||
|
<tr>
|
||||||
|
<td>
|
||||||
|
Model:
|
||||||
|
</td>
|
||||||
|
<td>
|
||||||
|
<span class="User_Show_AssignedDevices_CurrentAssignment_Model">@assignment.Device.DeviceModel.ToString()</span>
|
||||||
|
</td>
|
||||||
|
</tr>
|
||||||
|
}
|
||||||
<tr>
|
<tr>
|
||||||
<td>Model:
|
<td>
|
||||||
|
Profile:
|
||||||
</td>
|
</td>
|
||||||
<td>
|
<td>
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_Model">@assignment.Device.DeviceModel.ToString()</span>
|
<span class="User_Show_AssignedDevices_CurrentAssignment_Profile">@assignment.Device.DeviceProfile.ToString()</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
}
|
@if (assignment.Device.DeviceBatchId.HasValue)
|
||||||
<tr>
|
{
|
||||||
<td>Profile:
|
<tr>
|
||||||
</td>
|
<td>
|
||||||
<td>
|
Batch:
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_Profile">@assignment.Device.DeviceProfile.ToString()</span>
|
</td>
|
||||||
</td>
|
<td>
|
||||||
</tr>
|
<span class="User_Show_AssignedDevices_CurrentAssignment_Batch">@assignment.Device.DeviceBatch.ToString()</span>
|
||||||
@if (assignment.Device.DeviceBatchId.HasValue)
|
</td>
|
||||||
{
|
</tr>
|
||||||
|
}
|
||||||
<tr>
|
<tr>
|
||||||
<td>Batch:
|
<td>Assigned:</td>
|
||||||
</td>
|
|
||||||
<td>
|
<td>
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_Batch">@assignment.Device.DeviceBatch.ToString()</span>
|
<span class="User_Show_AssignedDevices_CurrentAssignment_Assigned">@CommonHelpers.FriendlyDate(assignment.AssignedDate)</span>
|
||||||
</td>
|
</td>
|
||||||
</tr>
|
</tr>
|
||||||
}
|
</tbody>
|
||||||
<tr>
|
</table>
|
||||||
<td>Assigned:</td>
|
</div>
|
||||||
<td>
|
|
||||||
<span class="User_Show_AssignedDevices_CurrentAssignment_Assigned">@CommonHelpers.FriendlyDate(assignment.AssignedDate)</span>
|
|
||||||
</td>
|
|
||||||
</tr>
|
|
||||||
</tbody>
|
|
||||||
</table>
|
|
||||||
</div>
|
</div>
|
||||||
</div>
|
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
|
|||||||
File diff suppressed because it is too large.
Load diff
Reference in new issue
Block a user