using System; using System.Collections.Generic; using Yavsc.Model.FrontOffice.Catalog; using Yavsc.Model.FrontOffice; namespace Yavsc.Model.WorkFlow { /// /// Interface content provider. /// Class Assertion: Statuses.Length >= FinalStatuses.Length. /// public interface IContentProvider : IDbModule, IDisposable, IDataProvider { /// /// Gets the different status labels. /// 0 is the starting status. Each status is an integer and the 0-based index /// of a string in this array. /// /// The status labels. string [] Statuses { get; } /// /// Gets the final statuses. /// /// The final statuses. bool [] FinalStatuses { get; } string Name { get; } /// /// Creates the estimate. /// /// The estimate. /// Responsible. /// Client. /// Title. /// Description. Estimate CreateEstimate (string responsible, string client, string title, string description); /// /// Drops the writting. /// /// Wrid. void DropWritting (long wrid); /// /// Drops the estimate. /// /// Estid. void DropEstimate (long estid); /// /// Drops the tag writting. /// /// Wrid. /// Tag. void DropWrittingTag (long wrid,string tag); /// /// Finds the activity. /// /// The activity. /// Pattern. /// If set to true exerted. Activity [] FindActivity (string pattern, bool exerted); /// /// Finds the performer. /// /// The performer. /// MEA code. PerformerProfile [] FindPerformer (string MEACode); /// /// Gets the activity. /// /// The activity. /// MAE code. Activity GetActivity (string MEACode); /// /// Gets the writting status changes. /// /// The writting statuses. /// Wrid. StatusChange[] GetWrittingStatuses (long wrid); /// /// Gets the estimate status changes. /// /// The estimate statuses. /// Estid. StatusChange[] GetEstimateStatuses (long estid); /// /// /// Gets the estimates. /// /// The estimates. /// Username. Estimate [] GetEstimates(string username); /// /// Registers the activity. /// /// Activity. /// Code. void RegisterActivity (string activityName, string meacode, string comment); /// /// Gets the estimates. /// /// The estimates. /// Client. /// Responsible. Estimate [] GetEstimates(string client, string responsible); /// /// Gets the commands. /// /// The commands. /// Username. CommandSet GetCommands (string username); /// /// Gets the stock status. /// /// The stock status. /// Product reference. StockStatus GetStockStatus (string productReference); /// /// Registers the command. /// /// The command id in db. /// COM. long RegisterCommand (Command com); /// /// Sets the writting status. /// /// Wrtid. /// Status. /// Username. void SetWrittingStatus (long wrtid,int status,string username); /// /// Sets the estimate status. /// /// Estid. /// Status. /// Username. void SetEstimateStatus (long estid,int status,string username); /// /// Tags the writting. /// /// Wrid. /// Tag. void TagWritting (long wrid,string tag); /// /// Updates the writting. /// /// Wr. void UpdateWritting (Writting wr); /// Add a line to the specified estimate by id, /// using the specified desc, ucost, count and productid. /// /// Estimate identifier. /// Textual description for this line. /// Unitary cost. /// Cost multiplier. /// Product identifier. long Write (long estid, string desc, decimal ucost, int count, string productid); } }