本文整理汇总了C#中ASC.Projects.Core.Domain.Task.ToString方法的典型用法代码示例。如果您正苦于以下问题:C# Task.ToString方法的具体用法?C# Task.ToString怎么用?C# Task.ToString使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ASC.Projects.Core.Domain.Task
的用法示例。
在下文中一共展示了Task.ToString方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: TimeSpend
public static void TimeSpend(TimeSpend timeSpend, Project project, Task relativeTask, String actionText, int actionType, int businessValue)
{
UserActivityPublisher.Publish<TimeLinePublisher>(
new TimeLineUserActivity(actionText, actionType, businessValue)
{
ContentID = relativeTask != null ? relativeTask.ToString() : String.Empty,
ContainerID = timeSpend.Task.Project.ID.ToString(),
Title = relativeTask != null ? relativeTask.Title : timeSpend.Hours.ToString(),
URL = String.Concat(VirtualPathUtility.ToAbsolute(ConfigurationManager.BaseVirtualPath + "timeTracking.aspx"), String.Format("?prjID={0}", timeSpend.Task.Project.ID)),
AdditionalData = String.Format(AdditionalDataPattern, EntityType.TimeSpend, relativeTask != null ? relativeTask.Title : string.Empty, project.Title),
SecurityId = string.Format(SecurityDataPattern, EntityType.TimeSpend, relativeTask != null ? relativeTask.ID.ToString() : string.Empty, project.ID)
});
}
示例2: Subtask
public static void Subtask(Subtask subtask, Task task, String actionText, int actionType, int businessValue)
{
//DropProjectActivitiesCache(task.Project);
UserActivityPublisher.Publish<TimeLinePublisher>(new TimeLineUserActivity(actionText, actionType, businessValue)
{
ContentID = (task != null) ? task.ToString() : String.Empty,
ContainerID = task.Project.ID.ToString(),
Title = subtask.Title,
URL = String.Concat(VirtualPathUtility.ToAbsolute(ConfigurationManager.BaseVirtualPath + "tasks.aspx").Replace("api/", ""), String.Format("?prjID={0}&id={1}", task.Project.ID, task.ID)),
AdditionalData = String.Format(AdditionalDataPattern, EntityType.SubTask, (task != null) ? task.Title : String.Empty, task.Project.Title),
SecurityId = string.Format(SecurityDataPattern, EntityType.SubTask, task.ID, task.Project.ID),
HtmlPreview = null
});
}