Esempio n. 1
0
        public async Task <viewModel.TaskView> Add([FromBody] transModel.TaskAdd add)
        {
            var addTrans = new trans.TaskTransactions();
            var result   = await addTrans.Add(add);

            return((viewModel.TaskView)result);
        }
Esempio n. 2
0
        public async Task <viewModel.TaskView> Update([FromRoute] int taskId, [FromBody] transModel.TaskUpdate update)
        {
            update.TaskId = taskId;
            var updateTrans = new trans.TaskTransactions();
            var result      = await updateTrans.Update(update);

            return((viewModel.TaskView)result);
        }
Esempio n. 3
0
 public async Task Delete([FromRoute] int taskId)
 {
     var deleteTrans = new trans.TaskTransactions();
     var taskDelete  = new transModel.TaskDelete()
     {
         TaskId = taskId
     };
     await deleteTrans.Delete(taskDelete);
 }