public ApplicationManager(IUsers IUsers, IFreeDays IFreeDays, IWorkers IWorkers, ApplicationMapper applicationMapper)
 {
     mIUsers            = IUsers;
     mIWorkers          = IWorkers;
     mIFreeDays         = IFreeDays;
     mApplicationMapper = applicationMapper;
 }
 /// <summary>
 /// Get entity from adoxio_workers by key
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <MicrosoftDynamicsCRMadoxioWorker> GetByKeyAsync(this IWorkers operations, string adoxioWorkerid, IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetByKeyWithHttpMessagesAsync(adoxioWorkerid, select, expand, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Add new entity to adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='body'>
 /// New entity
 /// </param>
 /// <param name='prefer'>
 /// Required in order for the service to return a JSON representation of the
 /// object.
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <MicrosoftDynamicsCRMadoxioWorker> CreateAsync(this IWorkers operations, MicrosoftDynamicsCRMadoxioWorker body, string prefer = "return=representation", CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.CreateWithHttpMessagesAsync(body, prefer, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
 /// <summary>
 /// Get entities from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='top'>
 /// </param>
 /// <param name='skip'>
 /// </param>
 /// <param name='search'>
 /// </param>
 /// <param name='filter'>
 /// </param>
 /// <param name='count'>
 /// </param>
 /// <param name='orderby'>
 /// Order items by property values
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <WorkersGetResponseModel> GetAsync(this IWorkers operations, int?top = default(int?), int?skip = default(int?), string search = default(string), string filter = default(string), bool?count = default(bool?), IList <string> orderby = default(IList <string>), IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(top, skip, search, filter, count, orderby, select, expand, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
示例#5
0
        public void Setup(string workerType, DateTime startTime, DateTime endTime)
        {
            Worker = factory.GetWorker(workerType);
            Worker.CreateNewEvent(startTime, endTime);
            var cost = Worker.CalculatePayment();

            this.view.UpdateView(startTime, endTime, workerType, cost);
        }
 /// <summary>
 /// Delete entity from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='ifMatch'>
 /// ETag
 /// </param>
 public static void Delete(this IWorkers operations, string adoxioWorkerid, string ifMatch = default(string))
 {
     operations.DeleteAsync(adoxioWorkerid, ifMatch).GetAwaiter().GetResult();
 }
 /// <summary>
 /// Get entity from adoxio_workers by key
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 public static MicrosoftDynamicsCRMadoxioWorker GetByKey(this IWorkers operations, string adoxioWorkerid, IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>))
 {
     return(operations.GetByKeyAsync(adoxioWorkerid, select, expand).GetAwaiter().GetResult());
 }
示例#8
0
 /// <summary>
 /// Get entities from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='top'>
 /// </param>
 /// <param name='filter'>
 /// </param>
 /// <param name='count'>
 /// </param>
 /// <param name='orderby'>
 /// Order items by property values
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse <MicrosoftDynamicsCRMadoxioWorkerCollection> GetWithHttpMessages(this IWorkers operations, int?top = default(int?), string filter = default(string), bool?count = default(bool?), IList <string> orderby = default(IList <string>), IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>), Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.GetWithHttpMessagesAsync(top, filter, count, orderby, select, expand, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Update entity in adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='body'>
 /// New property values
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task UpdateAsync(this IWorkers operations, string adoxioWorkerid, MicrosoftDynamicsCRMadoxioWorker body, CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.UpdateWithHttpMessagesAsync(adoxioWorkerid, body, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
示例#10
0
 /// <summary>
 /// Get entities from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='top'>
 /// </param>
 /// <param name='filter'>
 /// </param>
 /// <param name='count'>
 /// </param>
 /// <param name='orderby'>
 /// Order items by property values
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task <MicrosoftDynamicsCRMadoxioWorkerCollection> GetAsync(this IWorkers operations, int?top = default(int?), string filter = default(string), bool?count = default(bool?), IList <string> orderby = default(IList <string>), IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>), CancellationToken cancellationToken = default(CancellationToken))
 {
     using (var _result = await operations.GetWithHttpMessagesAsync(top, filter, count, orderby, select, expand, null, cancellationToken).ConfigureAwait(false))
     {
         return(_result.Body);
     }
 }
示例#11
0
 /// <summary>
 /// Get entities from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='top'>
 /// </param>
 /// <param name='filter'>
 /// </param>
 /// <param name='count'>
 /// </param>
 /// <param name='orderby'>
 /// Order items by property values
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 public static MicrosoftDynamicsCRMadoxioWorkerCollection Get(this IWorkers operations, int?top = default(int?), string filter = default(string), bool?count = default(bool?), IList <string> orderby = default(IList <string>), IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>))
 {
     return(operations.GetAsync(top, filter, count, orderby, select, expand).GetAwaiter().GetResult());
 }
示例#12
0
 /// <summary>
 /// Delete entity from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid of adoxio_worker
 /// </param>
 /// <param name='ifMatch'>
 /// ETag
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse DeleteWithHttpMessages(this IWorkers operations, string adoxioWorkerid, string ifMatch = default(string), Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.DeleteWithHttpMessagesAsync(adoxioWorkerid, ifMatch, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }
示例#13
0
 /// <summary>
 /// Update entity in adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid of adoxio_worker
 /// </param>
 /// <param name='body'>
 /// New property values
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse UpdateWithHttpMessages(this IWorkers operations, string adoxioWorkerid, MicrosoftDynamicsCRMadoxioWorker body, Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.UpdateWithHttpMessagesAsync(adoxioWorkerid, body, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }
示例#14
0
 /// <summary>
 /// Get entity from adoxio_workers by key
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid of adoxio_worker
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse <MicrosoftDynamicsCRMadoxioWorker> GetByKeyWithHttpMessages(this IWorkers operations, string adoxioWorkerid, IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>), Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.GetByKeyWithHttpMessagesAsync(adoxioWorkerid, select, expand, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }
示例#15
0
 /// <summary>
 /// Add new entity to adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='body'>
 /// New entity
 /// </param>
 /// <param name='prefer'>
 /// Required in order for the service to return a JSON representation of the
 /// object.
 /// </param>
 /// <param name='customHeaders'>
 /// Headers that will be added to request.
 /// </param>
 public static HttpOperationResponse <MicrosoftDynamicsCRMadoxioWorker> CreateWithHttpMessages(this IWorkers operations, MicrosoftDynamicsCRMadoxioWorker body, string prefer = "return=representation", Dictionary <string, List <string> > customHeaders = null)
 {
     return(operations.CreateWithHttpMessagesAsync(body, prefer, customHeaders, CancellationToken.None).ConfigureAwait(false).GetAwaiter().GetResult());
 }
 /// <summary>
 /// Delete entity from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='ifMatch'>
 /// ETag
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task DeleteAsync(this IWorkers operations, string adoxioWorkerid, string ifMatch = default(string), CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.DeleteWithHttpMessagesAsync(adoxioWorkerid, ifMatch, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
 /// <summary>
 /// Update entity in adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='adoxioWorkerid'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='body'>
 /// New property values
 /// </param>
 public static void Update(this IWorkers operations, string adoxioWorkerid, MicrosoftDynamicsCRMadoxioWorker body)
 {
     operations.UpdateAsync(adoxioWorkerid, body).GetAwaiter().GetResult();
 }
示例#18
0
 /// <summary>
 /// Add reference to adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='workerId'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='fieldname'>
 /// key: fieldname
 /// </param>
 /// <param name='odataid'>
 /// reference value
 /// </param>
 public static void AddReference(this IWorkers operations, string workerId, string fieldname, Odataid odataid = default(Odataid))
 {
     operations.AddReferenceAsync(workerId, fieldname, odataid).GetAwaiter().GetResult();
 }
 /// <summary>
 /// Get entities from adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='top'>
 /// </param>
 /// <param name='skip'>
 /// </param>
 /// <param name='search'>
 /// </param>
 /// <param name='filter'>
 /// </param>
 /// <param name='count'>
 /// </param>
 /// <param name='orderby'>
 /// Order items by property values
 /// </param>
 /// <param name='select'>
 /// Select properties to be returned
 /// </param>
 /// <param name='expand'>
 /// Expand related entities
 /// </param>
 public static WorkersGetResponseModel Get(this IWorkers operations, int?top = default(int?), int?skip = default(int?), string search = default(string), string filter = default(string), bool?count = default(bool?), IList <string> orderby = default(IList <string>), IList <string> select = default(IList <string>), IList <string> expand = default(IList <string>))
 {
     return(operations.GetAsync(top, skip, search, filter, count, orderby, select, expand).GetAwaiter().GetResult());
 }
示例#20
0
 /// <summary>
 /// Add reference to adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='workerId'>
 /// key: adoxio_workerid
 /// </param>
 /// <param name='fieldname'>
 /// key: fieldname
 /// </param>
 /// <param name='odataid'>
 /// reference value
 /// </param>
 /// <param name='cancellationToken'>
 /// The cancellation token.
 /// </param>
 public static async Task AddReferenceAsync(this IWorkers operations, string workerId, string fieldname, Odataid odataid = default(Odataid), CancellationToken cancellationToken = default(CancellationToken))
 {
     (await operations.AddReferenceWithHttpMessagesAsync(workerId, fieldname, odataid, null, cancellationToken).ConfigureAwait(false)).Dispose();
 }
 /// <summary>
 /// Add new entity to adoxio_workers
 /// </summary>
 /// <param name='operations'>
 /// The operations group for this extension method.
 /// </param>
 /// <param name='body'>
 /// New entity
 /// </param>
 /// <param name='prefer'>
 /// Required in order for the service to return a JSON representation of the
 /// object.
 /// </param>
 public static MicrosoftDynamicsCRMadoxioWorker Create(this IWorkers operations, MicrosoftDynamicsCRMadoxioWorker body, string prefer = "return=representation")
 {
     return(operations.CreateAsync(body, prefer).GetAwaiter().GetResult());
 }
示例#22
0
 public WorkersController(IWorkers Workers) => _Workers = Workers;