Merge: Repository Monitor
This commit is contained in:
@@ -237,7 +237,7 @@
|
|||||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||||
<ProjectExtensions>
|
<ProjectExtensions>
|
||||||
<VisualStudio>
|
<VisualStudio>
|
||||||
<UserProperties BuildVersion_StartDate="2011/7/1" BuildVersion_BuildAction="Both" BuildVersion_DetectChanges="False" BuildVersion_UseGlobalSettings="False" BuildVersion_BuildVersioningStyle="None.DeltaBaseYear.MonthAndDayStamp.TimeStamp" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_UpdateFileVersion="True" />
|
<UserProperties BuildVersion_UpdateFileVersion="True" BuildVersion_UpdateAssemblyVersion="True" BuildVersion_BuildVersioningStyle="None.DeltaBaseYear.MonthAndDayStamp.TimeStamp" BuildVersion_UseGlobalSettings="False" BuildVersion_DetectChanges="False" BuildVersion_BuildAction="Both" BuildVersion_StartDate="2011/7/1" />
|
||||||
</VisualStudio>
|
</VisualStudio>
|
||||||
</ProjectExtensions>
|
</ProjectExtensions>
|
||||||
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
|
<Import Project="$(SolutionDir)\.nuget\nuget.targets" />
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0429.1616")]
|
[assembly: AssemblyVersion("1.2.0429.1616")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0429.1616")]
|
[assembly: AssemblyFileVersion("1.2.0429.1616")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0426.1841")]
|
[assembly: AssemblyVersion("1.2.0426.1841")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0426.1841")]
|
[assembly: AssemblyFileVersion("1.2.0426.1841")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -76,10 +76,17 @@ namespace Disco.Data.Repository
|
|||||||
// Notify before changes are committed
|
// Notify before changes are committed
|
||||||
var changes = Monitor.RepositoryMonitor.BeforeSaveChanges(this);
|
var changes = Monitor.RepositoryMonitor.BeforeSaveChanges(this);
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
changeCount = base.SaveChanges();
|
changeCount = base.SaveChanges();
|
||||||
|
|
||||||
if (changes.Length > 0)
|
if (changes.Length > 0)
|
||||||
{
|
{
|
||||||
|
=======
|
||||||
|
if (changes.Length > 0)
|
||||||
|
{
|
||||||
|
changeCount = base.SaveChanges();
|
||||||
|
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
// Notify after changes are committed
|
// Notify after changes are committed
|
||||||
Monitor.RepositoryMonitor.AfterSaveChanges(this, changes);
|
Monitor.RepositoryMonitor.AfterSaveChanges(this, changes);
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -23,6 +23,7 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
internal static RepositoryMonitorEvent[] BeforeSaveChanges(DiscoDataContext dbContext)
|
internal static RepositoryMonitorEvent[] BeforeSaveChanges(DiscoDataContext dbContext)
|
||||||
{
|
{
|
||||||
var contextStateManager = ((IObjectContextAdapter)dbContext).ObjectContext.ObjectStateManager;
|
var contextStateManager = ((IObjectContextAdapter)dbContext).ObjectContext.ObjectStateManager;
|
||||||
|
<<<<<<< HEAD
|
||||||
//var changes = contextStateManager.GetObjectStateEntries(System.Data.EntityState.Added).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Deleted)).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Modified));
|
//var changes = contextStateManager.GetObjectStateEntries(System.Data.EntityState.Added).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Deleted)).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Modified));
|
||||||
|
|
||||||
dbContext.ChangeTracker.DetectChanges();
|
dbContext.ChangeTracker.DetectChanges();
|
||||||
@@ -32,6 +33,17 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
var monitorEvent = EventFromEntryState(dbContext, entryState, contextStateManager.GetObjectStateEntry(entryState.Entity));
|
var monitorEvent = EventFromEntryState(dbContext, entryState, contextStateManager.GetObjectStateEntry(entryState.Entity));
|
||||||
// Push to Stream
|
// Push to Stream
|
||||||
streamBefore.OnNext(monitorEvent);
|
streamBefore.OnNext(monitorEvent);
|
||||||
|
=======
|
||||||
|
var changes = contextStateManager.GetObjectStateEntries(System.Data.EntityState.Added).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Deleted)).Concat(contextStateManager.GetObjectStateEntries(System.Data.EntityState.Modified));
|
||||||
|
|
||||||
|
var events = changes.Select(entryState =>
|
||||||
|
{
|
||||||
|
var monitorEvent = EventFromEntryState(entryState);
|
||||||
|
|
||||||
|
// Push to Stream
|
||||||
|
streamBefore.OnNext(monitorEvent);
|
||||||
|
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
return monitorEvent;
|
return monitorEvent;
|
||||||
}).ToArray();
|
}).ToArray();
|
||||||
|
|
||||||
@@ -79,18 +91,28 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
var entryState = stateManager.GetObjectStateEntry(monitorEvent.Entity);
|
var entryState = stateManager.GetObjectStateEntry(monitorEvent.Entity);
|
||||||
monitorEvent.EntityKey = entryState.EntityKey.EntityKeyValues.Select(kv => kv.Value).ToArray();
|
monitorEvent.EntityKey = entryState.EntityKey.EntityKeyValues.Select(kv => kv.Value).ToArray();
|
||||||
}
|
}
|
||||||
|
<<<<<<< HEAD
|
||||||
|
|
||||||
monitorEvent.afterCommit = true;
|
monitorEvent.afterCommit = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
internal static RepositoryMonitorEvent EventFromEntryState(DiscoDataContext dbContext, DbEntityEntry dbEntryState, ObjectStateEntry objectEntryState)
|
internal static RepositoryMonitorEvent EventFromEntryState(DiscoDataContext dbContext, DbEntityEntry dbEntryState, ObjectStateEntry objectEntryState)
|
||||||
|
=======
|
||||||
|
}
|
||||||
|
|
||||||
|
internal static RepositoryMonitorEvent EventFromEntryState(ObjectStateEntry entryState)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
{
|
{
|
||||||
RepositoryMonitorEventType eventType;
|
RepositoryMonitorEventType eventType;
|
||||||
string[] modifiedProperties = null;
|
string[] modifiedProperties = null;
|
||||||
object[] entityKey = null;
|
object[] entityKey = null;
|
||||||
Type entityType;
|
Type entityType;
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
switch (dbEntryState.State)
|
switch (dbEntryState.State)
|
||||||
|
=======
|
||||||
|
switch (entryState.State)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
{
|
{
|
||||||
case System.Data.EntityState.Added:
|
case System.Data.EntityState.Added:
|
||||||
eventType = RepositoryMonitorEventType.Added;
|
eventType = RepositoryMonitorEventType.Added;
|
||||||
@@ -108,6 +130,7 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
eventType = RepositoryMonitorEventType.Unchanged;
|
eventType = RepositoryMonitorEventType.Unchanged;
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
<<<<<<< HEAD
|
||||||
throw new NotSupportedException(string.Format("Database Entry State not supported: {0}", dbEntryState.State.ToString()));
|
throw new NotSupportedException(string.Format("Database Entry State not supported: {0}", dbEntryState.State.ToString()));
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -128,6 +151,25 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
dbContext = dbContext,
|
dbContext = dbContext,
|
||||||
EventType = eventType,
|
EventType = eventType,
|
||||||
Entity = dbEntryState.Entity,
|
Entity = dbEntryState.Entity,
|
||||||
|
=======
|
||||||
|
throw new NotSupportedException(string.Format("Database Entry State not supported: {0}", entryState.State.ToString()));
|
||||||
|
}
|
||||||
|
|
||||||
|
entityType = EntityTypeFromProxy(entryState.Entity.GetType());
|
||||||
|
|
||||||
|
// Only pass modified properties on Modified Event (Ignore Added/Deleted)
|
||||||
|
if (eventType == RepositoryMonitorEventType.Modified)
|
||||||
|
modifiedProperties = entryState.GetModifiedProperties().ToArray();
|
||||||
|
|
||||||
|
// Don't pass entity key when entity newly added
|
||||||
|
if (eventType != RepositoryMonitorEventType.Added)
|
||||||
|
entityKey = entryState.EntityKey.EntityKeyValues.Select(kv => kv.Value).ToArray();
|
||||||
|
|
||||||
|
return new RepositoryMonitorEvent()
|
||||||
|
{
|
||||||
|
EventType = eventType,
|
||||||
|
Entity = entryState.Entity,
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
EntityKey = entityKey,
|
EntityKey = entityKey,
|
||||||
EntityType = entityType,
|
EntityType = entityType,
|
||||||
ModifiedProperties = modifiedProperties
|
ModifiedProperties = modifiedProperties
|
||||||
|
|||||||
@@ -1,8 +1,11 @@
|
|||||||
using Newtonsoft.Json;
|
using Newtonsoft.Json;
|
||||||
using System;
|
using System;
|
||||||
using System.Collections.Generic;
|
using System.Collections.Generic;
|
||||||
|
<<<<<<< HEAD
|
||||||
using System.Data.Entity.Infrastructure;
|
using System.Data.Entity.Infrastructure;
|
||||||
using System.Data.Objects;
|
using System.Data.Objects;
|
||||||
|
=======
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
using System.Linq;
|
using System.Linq;
|
||||||
using System.Text;
|
using System.Text;
|
||||||
using System.Threading.Tasks;
|
using System.Threading.Tasks;
|
||||||
@@ -11,6 +14,7 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
{
|
{
|
||||||
public class RepositoryMonitorEvent
|
public class RepositoryMonitorEvent
|
||||||
{
|
{
|
||||||
|
<<<<<<< HEAD
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
internal ObjectStateEntry objectEntryState { get; set; }
|
internal ObjectStateEntry objectEntryState { get; set; }
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
@@ -21,6 +25,8 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
public DiscoDataContext dbContext { get; set; }
|
public DiscoDataContext dbContext { get; set; }
|
||||||
|
|
||||||
|
=======
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
public RepositoryMonitorEventType EventType { get; set; }
|
public RepositoryMonitorEventType EventType { get; set; }
|
||||||
|
|
||||||
[JsonIgnore]
|
[JsonIgnore]
|
||||||
@@ -40,6 +46,7 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
public object[] EntityKey { get; set; }
|
public object[] EntityKey { get; set; }
|
||||||
|
|
||||||
public string[] ModifiedProperties { get; set; }
|
public string[] ModifiedProperties { get; set; }
|
||||||
|
<<<<<<< HEAD
|
||||||
|
|
||||||
public T GetPreviousPropertyValue<T>(string PropertyName)
|
public T GetPreviousPropertyValue<T>(string PropertyName)
|
||||||
{
|
{
|
||||||
@@ -52,5 +59,7 @@ namespace Disco.Data.Repository.Monitor
|
|||||||
{
|
{
|
||||||
return (T)dbEntityState.CurrentValues[PropertyName];
|
return (T)dbEntityState.CurrentValues[PropertyName];
|
||||||
}
|
}
|
||||||
|
=======
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -32,5 +32,10 @@ using System.Runtime.InteropServices;
|
|||||||
// You can specify all the values or you can default the Build and Revision Numbers
|
// You can specify all the values or you can default the Build and Revision Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
// [assembly: AssemblyVersion("1.0.*")]
|
// [assembly: AssemblyVersion("1.0.*")]
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -31,5 +31,10 @@ using System.Runtime.InteropServices;
|
|||||||
//
|
//
|
||||||
// You can specify all the values or you can default the Revision and Build Numbers
|
// You can specify all the values or you can default the Revision and Build Numbers
|
||||||
// by using the '*' as shown below:
|
// by using the '*' as shown below:
|
||||||
|
<<<<<<< HEAD
|
||||||
[assembly: AssemblyVersion("1.2.0430.1219")]
|
[assembly: AssemblyVersion("1.2.0430.1219")]
|
||||||
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
[assembly: AssemblyFileVersion("1.2.0430.1219")]
|
||||||
|
=======
|
||||||
|
[assembly: AssemblyVersion("1.2.0411.1608")]
|
||||||
|
[assembly: AssemblyFileVersion("1.2.0411.1608")]
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|||||||
@@ -20,6 +20,169 @@
|
|||||||
<textarea class="commentInput" accesskey="l"></textarea>
|
<textarea class="commentInput" accesskey="l"></textarea>
|
||||||
<span class="action post commentInputPost"></span>
|
<span class="action post commentInputPost"></span>
|
||||||
</div>
|
</div>
|
||||||
|
<<<<<<< HEAD
|
||||||
|
=======
|
||||||
|
<script type="text/javascript">
|
||||||
|
$(function () {
|
||||||
|
var jobId = parseInt('@(Model.Job.Id)');
|
||||||
|
$Comments = $('#Comments');
|
||||||
|
$CommentOutput = $Comments.find('.commentOutput');
|
||||||
|
$CommentOutputContainer = $Comments.find('.commentOutputContainer');
|
||||||
|
$CommentInput = $Comments.find('textarea.commentInput');
|
||||||
|
|
||||||
|
window.setTimeout(function () {
|
||||||
|
$CommentOutput[0].scrollTop = $CommentOutput[0].scrollHeight; // Scroll to Bottom
|
||||||
|
}, 0);
|
||||||
|
$('#jobDetailTabs').on('tabsactivate', function (event, ui) {
|
||||||
|
if (ui.newPanel && ui.newPanel.is('#jobDetailTab-Resources')) {
|
||||||
|
$CommentOutput[0].scrollTop = $CommentOutput[0].scrollHeight; // Scroll to Bottom
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
$Comments.find('.commentInputPost').click(postComment);
|
||||||
|
$CommentInput.keypress(function (e) {
|
||||||
|
if (e.which == 13 && !e.shiftKey) {
|
||||||
|
postComment();
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
});
|
||||||
|
$CommentOutput.find('span.remove').click(removePost);
|
||||||
|
|
||||||
|
$dialogRemoveLog = $('#dialogRemoveLog');
|
||||||
|
$dialogRemoveLog.dialog({
|
||||||
|
resizable: false,
|
||||||
|
height: 140,
|
||||||
|
modal: true,
|
||||||
|
autoOpen: false
|
||||||
|
});
|
||||||
|
|
||||||
|
function postComment() {
|
||||||
|
var comment = $CommentInput.val();
|
||||||
|
if (comment != '') {
|
||||||
|
var data = { comment: comment }
|
||||||
|
$.ajax({
|
||||||
|
url: '@Url.Action(MVC.API.Job.CommentPost(Model.Job.Id, null))',
|
||||||
|
dataType: 'json',
|
||||||
|
data: data,
|
||||||
|
success: function (d) {
|
||||||
|
if (d.Result == 'OK') {
|
||||||
|
// Should be added via Repository Notifications
|
||||||
|
// addComment(d.Comment, false);
|
||||||
|
$CommentInput.val('').attr('disabled', false).focus();
|
||||||
|
} else {
|
||||||
|
alert('Unable to post comment: ' + d.Result);
|
||||||
|
$CommentInput.attr('disabled', false);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (jqXHR, textStatus, errorThrown) {
|
||||||
|
alert('Unable to post comment: ' + textStatus);
|
||||||
|
$CommentInput.attr('disabled', false);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
function removePost() {
|
||||||
|
$this = $(this);
|
||||||
|
var data = { id: $this.closest('div').attr('data-logid') };
|
||||||
|
|
||||||
|
$dialogRemoveLog.dialog("enable");
|
||||||
|
$dialogRemoveLog.dialog('option', 'buttons', {
|
||||||
|
"Remove": function () {
|
||||||
|
$dialogRemoveLog.dialog("disable");
|
||||||
|
$dialogRemoveLog.dialog("option", "buttons", null);
|
||||||
|
$.ajax({
|
||||||
|
url: '@Url.Action(MVC.API.Job.CommentRemove())',
|
||||||
|
dataType: 'json',
|
||||||
|
data: data,
|
||||||
|
success: function (d) {
|
||||||
|
if (d == 'OK') {
|
||||||
|
// Should be removed via Repository Notifications
|
||||||
|
//$this.closest('div').slideUp(300).delay(300).queue(function () {
|
||||||
|
// $(this).remove();
|
||||||
|
//});
|
||||||
|
} else {
|
||||||
|
alert('Unable to remove comment: ' + d);
|
||||||
|
}
|
||||||
|
$dialogRemoveLog.dialog("close");
|
||||||
|
},
|
||||||
|
error: function (jqXHR, textStatus, errorThrown) {
|
||||||
|
alert('Unable to remove comment: ' + textStatus);
|
||||||
|
$dialogRemoveLog.dialog("close");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
},
|
||||||
|
"Cancel": function () {
|
||||||
|
$dialogRemoveLog.dialog("close");
|
||||||
|
}
|
||||||
|
});
|
||||||
|
|
||||||
|
$dialogRemoveLog.dialog('open');
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}
|
||||||
|
function loadLiveComment(id) {
|
||||||
|
$.ajax({
|
||||||
|
url: '@Url.Action(MVC.API.Job.Comment())',
|
||||||
|
dataType: 'json',
|
||||||
|
data: { id: id },
|
||||||
|
success: function (d) {
|
||||||
|
if (d && d.JobId == jobId) {
|
||||||
|
addComment(d, false);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (jqXHR, textStatus, errorThrown) {
|
||||||
|
alert('Unable to load live comment ' + id + ': ' + textStatus);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function addComment(c, quick) {
|
||||||
|
var e = $('<div><span class="author" /><span class="remove" /><span class="timestamp" /><span class="comment" /></div>');
|
||||||
|
e.attr('data-logid', c.Id);
|
||||||
|
e.find('.author').text(c.Author);
|
||||||
|
e.find('.timestamp').text(c.TimestampFuzzy).attr('title', c.TimestampFull);
|
||||||
|
e.find('.remove').click(removePost);
|
||||||
|
var eComment = e.find('.comment').text(c.Comments);
|
||||||
|
var commentHtml = eComment.text().replace(/\r\n|\r|\n/g, '<br />');
|
||||||
|
commentHtml = commentHtml.replace(/\#(\d+)/g, '<a href="@Url.Action(MVC.Job.Show(null))?id=$1">#$1</a>');
|
||||||
|
eComment.html(commentHtml);
|
||||||
|
|
||||||
|
$CommentOutput.append(e);
|
||||||
|
|
||||||
|
if (!quick) {
|
||||||
|
e.animate({ backgroundColor: '#ffff99' }, 500, function () {
|
||||||
|
e.animate({ backgroundColor: '#f4f4f4' }, 500);
|
||||||
|
});
|
||||||
|
$CommentOutput.animate({ scrollTop: $CommentOutput[0].scrollHeight }, 250)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Sign up for Live Events
|
||||||
|
function liveMessageRecieved(d) {
|
||||||
|
if (d) {
|
||||||
|
switch (d.EventType) {
|
||||||
|
case 0: // Added
|
||||||
|
loadLiveComment(d.EntityKey[0]);
|
||||||
|
break;
|
||||||
|
case 1: // Removed
|
||||||
|
$CommentOutput.children('div[data-logid="' + d.EntityKey[0] + '"]').slideUp(300).delay(300).queue(function () {
|
||||||
|
$(this).remove();
|
||||||
|
});
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var liveMessagesConnection = $.connection('@(Url.Content("~/API/Repository/Notifications"))')
|
||||||
|
liveMessagesConnection.received(liveMessageRecieved);
|
||||||
|
liveMessagesConnection.error(function (e) {
|
||||||
|
alert('Error: ' + JSON.stringify(e));
|
||||||
|
});
|
||||||
|
liveMessagesConnection.start(function () {
|
||||||
|
liveMessagesConnection.send('/addToGroups:JobLog');
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
</td>
|
</td>
|
||||||
<td id="Attachments">
|
<td id="Attachments">
|
||||||
<div class="attachmentOutput">
|
<div class="attachmentOutput">
|
||||||
|
|||||||
@@ -167,7 +167,193 @@ WriteLiteral("></textarea>\r\n <span");
|
|||||||
|
|
||||||
WriteLiteral(" class=\"action post commentInputPost\"");
|
WriteLiteral(" class=\"action post commentInputPost\"");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteLiteral("></span>\r\n </div>\r\n </td>\r\n <td");
|
WriteLiteral("></span>\r\n </div>\r\n </td>\r\n <td");
|
||||||
|
=======
|
||||||
|
WriteLiteral("></span>\r\n </div>\r\n <script");
|
||||||
|
|
||||||
|
WriteLiteral(" type=\"text/javascript\"");
|
||||||
|
|
||||||
|
WriteLiteral(">\r\n $(function () {\r\n var jobId = parseInt(\'");
|
||||||
|
|
||||||
|
|
||||||
|
#line 25 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Model.Job.Id);
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral("\');\r\n $Comments = $(\'#Comments\');\r\n $Commen" +
|
||||||
|
"tOutput = $Comments.find(\'.commentOutput\');\r\n $CommentOutputC" +
|
||||||
|
"ontainer = $Comments.find(\'.commentOutputContainer\');\r\n $Comm" +
|
||||||
|
"entInput = $Comments.find(\'textarea.commentInput\');\r\n\r\n windo" +
|
||||||
|
"w.setTimeout(function () {\r\n $CommentOutput[0].scrollTop " +
|
||||||
|
"= $CommentOutput[0].scrollHeight; // Scroll to Bottom\r\n }, 0)" +
|
||||||
|
";\r\n $(\'#jobDetailTabs\').on(\'tabsactivate\', function (event, u" +
|
||||||
|
"i) {\r\n if (ui.newPanel && ui.newPanel.is(\'#jobDetailTab-R" +
|
||||||
|
"esources\')) {\r\n $CommentOutput[0].scrollTop = $Commen" +
|
||||||
|
"tOutput[0].scrollHeight; // Scroll to Bottom\r\n }\r\n " +
|
||||||
|
" });\r\n\r\n $Comments.find(\'.commentInputPost\').clic" +
|
||||||
|
"k(postComment);\r\n $CommentInput.keypress(function (e) {\r\n " +
|
||||||
|
" if (e.which == 13 && !e.shiftKey) {\r\n " +
|
||||||
|
" postComment();\r\n return false;\r\n " +
|
||||||
|
" }\r\n });\r\n $CommentOutput.find(\'spa" +
|
||||||
|
"n.remove\').click(removePost);\r\n\r\n $dialogRemoveLog = $(\'#dial" +
|
||||||
|
"ogRemoveLog\');\r\n $dialogRemoveLog.dialog({\r\n " +
|
||||||
|
" resizable: false,\r\n height: 140,\r\n " +
|
||||||
|
" modal: true,\r\n autoOpen: false\r\n " +
|
||||||
|
" });\r\n\r\n function postComment() {\r\n " +
|
||||||
|
"var comment = $CommentInput.val();\r\n if (comment != \'\') {" +
|
||||||
|
"\r\n var data = { comment: comment }\r\n " +
|
||||||
|
" $.ajax({\r\n url: \'");
|
||||||
|
|
||||||
|
|
||||||
|
#line 62 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.CommentPost(Model.Job.Id, null)));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral("\',\r\n dataType: \'json\',\r\n " +
|
||||||
|
" data: data,\r\n success: function (d) {\r\n " +
|
||||||
|
" if (d.Result == \'OK\') {\r\n " +
|
||||||
|
" // Should be added via Repository Notifications\r\n " +
|
||||||
|
" // addComment(d.Comment, false);\r\n " +
|
||||||
|
" $CommentInput.val(\'\').attr(\'disabled\', false).focus();\r\n " +
|
||||||
|
" } else {\r\n " +
|
||||||
|
" alert(\'Unable to post comment: \' + d.Result);\r\n " +
|
||||||
|
" $CommentInput.attr(\'disabled\', false);\r\n " +
|
||||||
|
" }\r\n },\r\n erro" +
|
||||||
|
"r: function (jqXHR, textStatus, errorThrown) {\r\n " +
|
||||||
|
" alert(\'Unable to post comment: \' + textStatus);\r\n " +
|
||||||
|
" $CommentInput.attr(\'disabled\', false);\r\n " +
|
||||||
|
" }\r\n });\r\n }\r\n " +
|
||||||
|
" }\r\n function removePost() {\r\n $thi" +
|
||||||
|
"s = $(this);\r\n var data = { id: $this.closest(\'div\').attr" +
|
||||||
|
"(\'data-logid\') };\r\n\r\n $dialogRemoveLog.dialog(\"enable\");\r" +
|
||||||
|
"\n $dialogRemoveLog.dialog(\'option\', \'buttons\', {\r\n " +
|
||||||
|
" \"Remove\": function () {\r\n $d" +
|
||||||
|
"ialogRemoveLog.dialog(\"disable\");\r\n $dialogRemove" +
|
||||||
|
"Log.dialog(\"option\", \"buttons\", null);\r\n $.ajax({" +
|
||||||
|
"\r\n url: \'");
|
||||||
|
|
||||||
|
|
||||||
|
#line 92 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.CommentRemove()));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral("\',\r\n dataType: \'json\',\r\n " +
|
||||||
|
" data: data,\r\n success: function" +
|
||||||
|
" (d) {\r\n if (d == \'OK\') {\r\n " +
|
||||||
|
" // Should be removed via Repository Notifications\r" +
|
||||||
|
"\n //$this.closest(\'div\').slideUp(300)" +
|
||||||
|
".delay(300).queue(function () {\r\n // " +
|
||||||
|
" $(this).remove();\r\n //});\r\n " +
|
||||||
|
" } else {\r\n " +
|
||||||
|
" alert(\'Unable to remove comment: \' + d);\r\n " +
|
||||||
|
" }\r\n $dialogRemoveLog.dialog(\"clo" +
|
||||||
|
"se\");\r\n },\r\n " +
|
||||||
|
" error: function (jqXHR, textStatus, errorThrown) {\r\n " +
|
||||||
|
" alert(\'Unable to remove comment: \' + textStatus);\r\n " +
|
||||||
|
" $dialogRemoveLog.dialog(\"close\");\r\n " +
|
||||||
|
" }\r\n });\r\n " +
|
||||||
|
" },\r\n \"Cancel\": function () {\r\n " +
|
||||||
|
" $dialogRemoveLog.dialog(\"close\");\r\n }\r\n" +
|
||||||
|
" });\r\n\r\n $dialogRemoveLog.dialog(\'" +
|
||||||
|
"open\');\r\n\r\n return false;\r\n }\r\n " +
|
||||||
|
" function loadLiveComment(id) {\r\n $.ajax({\r\n " +
|
||||||
|
" url: \'");
|
||||||
|
|
||||||
|
|
||||||
|
#line 123 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.Comment()));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral(@"',
|
||||||
|
dataType: 'json',
|
||||||
|
data: { id: id },
|
||||||
|
success: function (d) {
|
||||||
|
if (d && d.JobId == jobId) {
|
||||||
|
addComment(d, false);
|
||||||
|
}
|
||||||
|
},
|
||||||
|
error: function (jqXHR, textStatus, errorThrown) {
|
||||||
|
alert('Unable to load live comment ' + id + ': ' + textStatus);
|
||||||
|
}
|
||||||
|
});
|
||||||
|
}
|
||||||
|
function addComment(c, quick) {
|
||||||
|
var e = $('<div><span class=""author"" /><span class=""remove"" /><span class=""timestamp"" /><span class=""comment"" /></div>');
|
||||||
|
e.attr('data-logid', c.Id);
|
||||||
|
e.find('.author').text(c.Author);
|
||||||
|
e.find('.timestamp').text(c.TimestampFuzzy).attr('title', c.TimestampFull);
|
||||||
|
e.find('.remove').click(removePost);
|
||||||
|
var eComment = e.find('.comment').text(c.Comments);
|
||||||
|
var commentHtml = eComment.text().replace(/\r\n|\r|\n/g, '<br />');
|
||||||
|
commentHtml = commentHtml.replace(/\#(\d+)/g, '<a href=""");
|
||||||
|
|
||||||
|
|
||||||
|
#line 144 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.Job.Show(null)));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral(@"?id=$1"">#$1</a>');
|
||||||
|
eComment.html(commentHtml);
|
||||||
|
|
||||||
|
$CommentOutput.append(e);
|
||||||
|
|
||||||
|
if (!quick) {
|
||||||
|
e.animate({ backgroundColor: '#ffff99' }, 500, function () {
|
||||||
|
e.animate({ backgroundColor: '#f4f4f4' }, 500);
|
||||||
|
});
|
||||||
|
$CommentOutput.animate({ scrollTop: $CommentOutput[0].scrollHeight }, 250)
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
// Sign up for Live Events
|
||||||
|
function liveMessageRecieved(d) {
|
||||||
|
if (d) {
|
||||||
|
switch (d.EventType) {
|
||||||
|
case 0: // Added
|
||||||
|
loadLiveComment(d.EntityKey[0]);
|
||||||
|
break;
|
||||||
|
case 1: // Removed
|
||||||
|
$CommentOutput.children('div[data-logid=""' + d.EntityKey[0] + '""]').slideUp(300).delay(300).queue(function () {
|
||||||
|
$(this).remove();
|
||||||
|
});
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
var liveMessagesConnection = $.connection('");
|
||||||
|
|
||||||
|
|
||||||
|
#line 172 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Content("~/API/Repository/Notifications"));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral(@"')
|
||||||
|
liveMessagesConnection.received(liveMessageRecieved);
|
||||||
|
liveMessagesConnection.error(function (e) {
|
||||||
|
alert('Error: ' + JSON.stringify(e));
|
||||||
|
});
|
||||||
|
liveMessagesConnection.start(function () {
|
||||||
|
liveMessagesConnection.send('/addToGroups:JobLog');
|
||||||
|
});
|
||||||
|
|
||||||
|
});
|
||||||
|
</script>
|
||||||
|
</td>
|
||||||
|
<td");
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
WriteLiteral(" id=\"Attachments\"");
|
WriteLiteral(" id=\"Attachments\"");
|
||||||
|
|
||||||
@@ -178,13 +364,21 @@ WriteLiteral(" class=\"attachmentOutput\"");
|
|||||||
WriteLiteral(">\r\n");
|
WriteLiteral(">\r\n");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 26 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 26 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 186 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 26 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 26 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 186 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
foreach (var ja in Model.Job.JobAttachments)
|
foreach (var ja in Model.Job.JobAttachments)
|
||||||
{
|
{
|
||||||
|
|
||||||
@@ -193,6 +387,7 @@ WriteLiteral(">\r\n");
|
|||||||
#line hidden
|
#line hidden
|
||||||
WriteLiteral(" <a");
|
WriteLiteral(" <a");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteAttribute("href", Tuple.Create(" href=\"", 1245), Tuple.Create("\"", 1302)
|
WriteAttribute("href", Tuple.Create(" href=\"", 1245), Tuple.Create("\"", 1302)
|
||||||
|
|
||||||
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
@@ -201,12 +396,26 @@ WriteAttribute("href", Tuple.Create(" href=\"", 1245), Tuple.Create("\"", 1302)
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
, 1252), false)
|
, 1252), false)
|
||||||
|
=======
|
||||||
|
WriteAttribute("href", Tuple.Create(" href=\"", 9905), Tuple.Create("\"", 9962)
|
||||||
|
|
||||||
|
#line 188 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
, Tuple.Create(Tuple.Create("", 9912), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.API.Job.AttachmentDownload(ja.Id))
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
, 9912), false)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
);
|
);
|
||||||
|
|
||||||
WriteLiteral(" data-attachmentid=\"");
|
WriteLiteral(" data-attachmentid=\"");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 188 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.Id);
|
Write(ja.Id);
|
||||||
|
|
||||||
|
|
||||||
@@ -217,7 +426,11 @@ WriteLiteral("\"");
|
|||||||
WriteLiteral(" data-mimetype=\"");
|
WriteLiteral(" data-mimetype=\"");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 28 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 188 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.MimeType);
|
Write(ja.MimeType);
|
||||||
|
|
||||||
|
|
||||||
@@ -229,6 +442,7 @@ WriteLiteral(">\r\n <span");
|
|||||||
|
|
||||||
WriteLiteral(" class=\"icon\"");
|
WriteLiteral(" class=\"icon\"");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteAttribute("title", Tuple.Create(" title=\"", 1404), Tuple.Create("\"", 1424)
|
WriteAttribute("title", Tuple.Create(" title=\"", 1404), Tuple.Create("\"", 1424)
|
||||||
|
|
||||||
#line 29 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 29 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
@@ -237,12 +451,23 @@ WriteAttribute("title", Tuple.Create(" title=\"", 1404), Tuple.Create("\"", 1424
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
, 1412), false)
|
, 1412), false)
|
||||||
|
=======
|
||||||
|
WriteAttribute("title", Tuple.Create(" title=\"", 10064), Tuple.Create("\"", 10084)
|
||||||
|
|
||||||
|
#line 189 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
, Tuple.Create(Tuple.Create("", 10072), Tuple.Create<System.Object, System.Int32>(ja.Filename
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
, 10072), false)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
);
|
);
|
||||||
|
|
||||||
WriteLiteral(">\r\n <img");
|
WriteLiteral(">\r\n <img");
|
||||||
|
|
||||||
WriteLiteral(" alt=\"Attachment Thumbnail\"");
|
WriteLiteral(" alt=\"Attachment Thumbnail\"");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteAttribute("src", Tuple.Create(" src=\"", 1487), Tuple.Create("\"", 1546)
|
WriteAttribute("src", Tuple.Create(" src=\"", 1487), Tuple.Create("\"", 1546)
|
||||||
|
|
||||||
#line 30 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 30 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
@@ -251,12 +476,23 @@ WriteAttribute("src", Tuple.Create(" src=\"", 1487), Tuple.Create("\"", 1546)
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
, 1493), false)
|
, 1493), false)
|
||||||
|
=======
|
||||||
|
WriteAttribute("src", Tuple.Create(" src=\"", 10147), Tuple.Create("\"", 10206)
|
||||||
|
|
||||||
|
#line 190 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
, Tuple.Create(Tuple.Create("", 10153), Tuple.Create<System.Object, System.Int32>(Url.Action(MVC.API.Job.AttachmentThumbnail(ja.Id))
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
, 10153), false)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
);
|
);
|
||||||
|
|
||||||
WriteLiteral(" /></span>\r\n <span");
|
WriteLiteral(" /></span>\r\n <span");
|
||||||
|
|
||||||
WriteLiteral(" class=\"comments\"");
|
WriteLiteral(" class=\"comments\"");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteAttribute("title", Tuple.Create(" title=\"", 1605), Tuple.Create("\"", 1625)
|
WriteAttribute("title", Tuple.Create(" title=\"", 1605), Tuple.Create("\"", 1625)
|
||||||
|
|
||||||
#line 31 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 31 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
@@ -265,32 +501,58 @@ WriteAttribute("title", Tuple.Create(" title=\"", 1605), Tuple.Create("\"", 1625
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
, 1613), false)
|
, 1613), false)
|
||||||
|
=======
|
||||||
|
WriteAttribute("title", Tuple.Create(" title=\"", 10265), Tuple.Create("\"", 10285)
|
||||||
|
|
||||||
|
#line 191 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
, Tuple.Create(Tuple.Create("", 10273), Tuple.Create<System.Object, System.Int32>(ja.Comments
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
, 10273), false)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
);
|
);
|
||||||
|
|
||||||
WriteLiteral(">\r\n");
|
WriteLiteral(">\r\n");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 32 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 32 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 192 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 32 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 32 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 192 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
if (!string.IsNullOrEmpty(ja.DocumentTemplateId))
|
if (!string.IsNullOrEmpty(ja.DocumentTemplateId))
|
||||||
{
|
{
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 33 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 33 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 193 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.DocumentTemplate.Description);
|
Write(ja.DocumentTemplate.Description);
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 33 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 33 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 193 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
@@ -298,14 +560,22 @@ WriteLiteral(">\r\n");
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 35 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 35 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 195 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.Comments);
|
Write(ja.Comments);
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 35 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 35 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 195 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
}
|
}
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -317,7 +587,11 @@ WriteLiteral(" class=\"author\"");
|
|||||||
WriteLiteral(">");
|
WriteLiteral(">");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 196 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.TechUser.ToString());
|
Write(ja.TechUser.ToString());
|
||||||
|
|
||||||
|
|
||||||
@@ -331,6 +605,7 @@ WriteLiteral("></span><span");
|
|||||||
|
|
||||||
WriteLiteral(" class=\"timestamp\"");
|
WriteLiteral(" class=\"timestamp\"");
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
WriteAttribute("title", Tuple.Create(" title=\"", 1995), Tuple.Create("\"", 2033)
|
WriteAttribute("title", Tuple.Create(" title=\"", 1995), Tuple.Create("\"", 2033)
|
||||||
|
|
||||||
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
@@ -339,12 +614,26 @@ WriteAttribute("title", Tuple.Create(" title=\"", 1995), Tuple.Create("\"", 2033
|
|||||||
#line default
|
#line default
|
||||||
#line hidden
|
#line hidden
|
||||||
, 2003), false)
|
, 2003), false)
|
||||||
|
=======
|
||||||
|
WriteAttribute("title", Tuple.Create(" title=\"", 10655), Tuple.Create("\"", 10693)
|
||||||
|
|
||||||
|
#line 196 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
, Tuple.Create(Tuple.Create("", 10663), Tuple.Create<System.Object, System.Int32>(ja.Timestamp.ToFullDateTime()
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
, 10663), false)
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
);
|
);
|
||||||
|
|
||||||
WriteLiteral(">");
|
WriteLiteral(">");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 36 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 196 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
Write(ja.Timestamp.ToFuzzy());
|
Write(ja.Timestamp.ToFuzzy());
|
||||||
|
|
||||||
|
|
||||||
@@ -353,7 +642,11 @@ WriteLiteral(">");
|
|||||||
WriteLiteral("</span>\r\n </a> \r\n");
|
WriteLiteral("</span>\r\n </a> \r\n");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 38 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 38 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
=======
|
||||||
|
#line 198 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@@ -410,8 +703,13 @@ WriteLiteral("></span>\r\n Are you sure?\r\n </p>\r\n</div>\r\n<script
|
|||||||
"{\r\n var jobId = parseInt(\'");
|
"{\r\n var jobId = parseInt(\'");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 70 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 70 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Model.Job.Id);
|
Write(Model.Job.Id);
|
||||||
|
=======
|
||||||
|
#line 241 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Links.ClientBin.Disco_Silverlight_AttachmentUpload_xap);
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -458,8 +756,13 @@ WriteLiteral(@"');
|
|||||||
url: '");
|
url: '");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 109 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 109 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Url.Action(MVC.API.Job.CommentPost(Model.Job.Id, null)));
|
Write(Url.Action(MVC.API.Job.CommentPost(Model.Job.Id, null)));
|
||||||
|
=======
|
||||||
|
#line 253 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.AttachmentUpload(Model.Job.Id, null)));
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -497,8 +800,13 @@ WriteLiteral(@"',
|
|||||||
url: '");
|
url: '");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 139 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 139 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Url.Action(MVC.API.Job.CommentRemove()));
|
Write(Url.Action(MVC.API.Job.CommentRemove()));
|
||||||
|
=======
|
||||||
|
#line 276 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.Attachment()));
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -537,8 +845,13 @@ WriteLiteral(@"',
|
|||||||
url: '");
|
url: '");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 170 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 170 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Url.Action(MVC.API.Job.Comment()));
|
Write(Url.Action(MVC.API.Job.Comment()));
|
||||||
|
=======
|
||||||
|
#line 285 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.AttachmentDownload()));
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -567,8 +880,13 @@ WriteLiteral(@"',
|
|||||||
commentHtml = commentHtml.replace(/\#(\d+)/g, '<a href=""");
|
commentHtml = commentHtml.replace(/\#(\d+)/g, '<a href=""");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 191 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 191 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Url.Action(MVC.Job.Show(null)));
|
Write(Url.Action(MVC.Job.Show(null)));
|
||||||
|
=======
|
||||||
|
#line 286 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.AttachmentThumbnail()));
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
@@ -595,8 +913,66 @@ WriteLiteral("?id=$1\">#$1</a>\');\r\n eComment.html(commentHtml);\r\
|
|||||||
"ed = null;\r\n Silverlight.createObject(\r\n \'");
|
"ed = null;\r\n Silverlight.createObject(\r\n \'");
|
||||||
|
|
||||||
|
|
||||||
|
<<<<<<< HEAD
|
||||||
#line 240 "..\..\Views\Job\JobParts\Resources.cshtml"
|
#line 240 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
Write(Links.ClientBin.Disco_Silverlight_AttachmentUpload_xap);
|
Write(Links.ClientBin.Disco_Silverlight_AttachmentUpload_xap);
|
||||||
|
=======
|
||||||
|
#line 319 "..\..\Views\Job\JobParts\Resources.cshtml"
|
||||||
|
Write(Url.Action(MVC.API.Job.AttachmentRemove()));
|
||||||
|
|
||||||
|
|
||||||
|
#line default
|
||||||
|
#line hidden
|
||||||
|
WriteLiteral("\',\r\n dataType: \'json\',\r\n " +
|
||||||
|
" data: data,\r\n success: function" +
|
||||||
|
" (d) {\r\n if (d == \'OK\') {\r\n " +
|
||||||
|
" $this.hide(300).delay(300).queue(function () {\r\n " +
|
||||||
|
" var $this = $(this);\r\n " +
|
||||||
|
" if ($this.attr(\'data-mimetype\').toLowerCase(" +
|
||||||
|
").indexOf(\'image/\') == 0)\r\n S" +
|
||||||
|
"hadowbox.removeCache(this);\r\n $th" +
|
||||||
|
"is.remove();\r\n });\r\n " +
|
||||||
|
" } else {\r\n ale" +
|
||||||
|
"rt(\'Unable to remove attachment: \' + d);\r\n " +
|
||||||
|
" }\r\n $dialogRemoveAttachment.dialog(\"clo" +
|
||||||
|
"se\");\r\n },\r\n " +
|
||||||
|
" error: function (jqXHR, textStatus, errorThrown) {\r\n " +
|
||||||
|
" alert(\'Unable to remove attachment: \' + textStatus);\r\n " +
|
||||||
|
" $dialogRemoveAttachment.dialog(\"close\");\r\n " +
|
||||||
|
" }\r\n });\r\n " +
|
||||||
|
" },\r\n \"Cancel\": function () {\r\n " +
|
||||||
|
" $dialogRemoveAttachment.dialog(\"close\");\r\n " +
|
||||||
|
" }\r\n });\r\n\r\n $dialogR" +
|
||||||
|
"emoveAttachment.dialog(\'open\');\r\n\r\n return false;\r\n " +
|
||||||
|
" }\r\n\r\n $attachmentOutput.children(\'a\').each(func" +
|
||||||
|
"tion () {\r\n $this = $(this);\r\n if " +
|
||||||
|
"($this.attr(\'data-mimetype\').toLowerCase().indexOf(\'image/\') == 0)\r\n " +
|
||||||
|
" $this.shadowbox({ gallery: \'attachments\', player: \'img\', title: " +
|
||||||
|
"$this.find(\'.comments\').text() });\r\n });\r\n });" +
|
||||||
|
"\r\n </script>\r\n </td>\r\n </tr>\r\n</table>\r\n<div");
|
||||||
|
|
||||||
|
WriteLiteral(" id=\"dialogUpload\"");
|
||||||
|
|
||||||
|
WriteLiteral(" title=\"Upload Attachment\"");
|
||||||
|
|
||||||
|
WriteLiteral(">\r\n <div");
|
||||||
|
|
||||||
|
WriteLiteral(" id=\"silverlightHostUploadAttachment\"");
|
||||||
|
|
||||||
|
WriteLiteral(">\r\n </div>\r\n</div>\r\n<div");
|
||||||
|
|
||||||
|
WriteLiteral(" id=\"dialogRemoveLog\"");
|
||||||
|
|
||||||
|
WriteLiteral(" title=\"Remove this Comment?\"");
|
||||||
|
|
||||||
|
WriteLiteral(">\r\n <p>\r\n <span");
|
||||||
|
|
||||||
|
WriteLiteral(" class=\"ui-icon ui-icon-alert\"");
|
||||||
|
|
||||||
|
WriteLiteral(" style=\"float: left; margin: 0 7px 20px 0;\"");
|
||||||
|
|
||||||
|
WriteLiteral("></span>\r\n Are you sure?\r\n </p>\r\n</div>\r\n<div");
|
||||||
|
>>>>>>> origin/Repository-Monitor
|
||||||
|
|
||||||
|
|
||||||
#line default
|
#line default
|
||||||
|
|||||||
Reference in New Issue
Block a user