Fixed node labels, status, sub types (#338)

This commit is contained in:
Leila Lali
2017-05-09 09:33:25 -07:00
committed by GitHub
parent 5b5c5861d8
commit 0d570fa29b
25 changed files with 1975 additions and 657 deletions

View File

@@ -0,0 +1,40 @@
//
// Copyright (c) Microsoft. All rights reserved.
// Licensed under the MIT license. See LICENSE file in the project root for full license information.
//
using Microsoft.SqlServer.Management.Smo;
namespace Microsoft.SqlTools.ServiceLayer.ObjectExplorer.SmoModel
{
/// <summary>
/// Status for triggers
/// </summary>
public class SmoTriggerCustomNode
{
internal partial class TriggersChildFactory : SmoChildFactoryBase
{
public override string GetNodeStatus(object context)
{
return TriggersCustomeNodeHelper.GetStatus(context);
}
}
}
internal static class TriggersCustomeNodeHelper
{
internal static string GetStatus(object context)
{
Trigger trigger = context as Trigger;
if (trigger != null)
{
if (!trigger.IsEnabled)
{
return "Disabled";
}
}
return string.Empty;
}
}
}