using InABox.Integration.Logikal; using System; using System.Collections.Generic; namespace PRSDesktop.Integrations.Logikal { public class LogikalLabour : LogikalBOMItem, ILogikalLabour { public TimeSpan Duration { get; set; } public override void ValidateQuery(string sql, List errors) { base.ValidateQuery(sql, errors); } public static String SQL = $@" select cast(t.[timetype] as text) as {nameof(Code)}, t.[name] as {nameof(Description)}, sum(t.[totalminutes]/60.0) as {nameof(Quantity)}, c.[price] as {nameof(Cost)} from labourtimes t join labourcosts c on t.[timetype] = c.[type] join elevations e on t.[elevationid] = e.[elevationid] where t.[totalminutes] > 0.0 and t.[ismain] = 1 group by t.[timetype], t.[Name], c.[price] "; } }