renaming Reviewed
This commit is contained in:
parent
c74ac71b5d
commit
ee6cb34c23
9 changed files with 28 additions and 23 deletions
|
|
@ -4,7 +4,7 @@ namespace Yavsc.Abstract.Workflow
|
|||
{
|
||||
public interface IDecidableQuery: ITrackedEntity, IQuery
|
||||
{
|
||||
bool Decided { get; set; }
|
||||
bool Reviewed { get; set; }
|
||||
bool Accepted { get; set; }
|
||||
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@ namespace Yavsc.ApiControllers
|
|||
if (queryId == 0) return BadRequest("queryId");
|
||||
var billing = BillingService.GetBillable(dbContext, billingCode, queryId);
|
||||
if (billing == null) return BadRequest();
|
||||
billing.Decided = true;
|
||||
billing.Reviewed = true;
|
||||
billing.Accepted = false;
|
||||
dbContext.SaveChanges();
|
||||
return Ok();
|
||||
|
|
@ -48,7 +48,7 @@ namespace Yavsc.ApiControllers
|
|||
var billing = BillingService.GetBillable(dbContext, billingCode, queryId);
|
||||
if (billing == null) return BadRequest();
|
||||
billing.Accepted = true;
|
||||
billing.Decided = true;
|
||||
billing.Reviewed = true;
|
||||
dbContext.SaveChanges();
|
||||
return Ok();
|
||||
}
|
||||
|
|
|
|||
|
|
@ -1,7 +1,6 @@
|
|||
using Microsoft.AspNetCore.Mvc;
|
||||
using Microsoft.AspNetCore.Mvc.Rendering;
|
||||
using Microsoft.EntityFrameworkCore;
|
||||
using Yavsc.Helpers;
|
||||
using Yavsc.Models;
|
||||
using Yavsc.Models.Workflow;
|
||||
using Yavsc.Server.Helpers;
|
||||
|
|
@ -50,7 +49,13 @@ namespace Yavsc.Controllers
|
|||
private void SetViewBag(CommandForm commandForm = null)
|
||||
{
|
||||
ViewBag.ActivityCode = new SelectList(_context.Activities, "Code", "Name", commandForm?.ActivityCode);
|
||||
ViewBag.ActionName = new SelectList(_context.CommandForm, nameof(CommandForm.Id), nameof(CommandForm.Title), commandForm?.Id);
|
||||
ViewBag.ActionName = new SelectList(
|
||||
new[]{
|
||||
new SelectListItem { Value = "Create", Text = "Create" },
|
||||
new SelectListItem { Value = "Update", Text = "Update" },
|
||||
new SelectListItem { Value = "Delete", Text = "Delete" }
|
||||
});
|
||||
|
||||
}
|
||||
// POST: CommandForms/Create
|
||||
[HttpPost]
|
||||
|
|
|
|||
|
|
@ -65,14 +65,14 @@ namespace Yavsc.Controllers
|
|||
}
|
||||
|
||||
[AllowAnonymous]
|
||||
public async Task <ActionResult> HairCut(string id)
|
||||
public async Task <ActionResult> ListPerformersAsync(string activityCode)
|
||||
{
|
||||
if (id == null)
|
||||
if (activityCode == null)
|
||||
{
|
||||
throw new NotImplementedException("No Activity code");
|
||||
}
|
||||
ViewBag.Activity = await _context.Activities.FirstOrDefaultAsync(a => a.Code == id);
|
||||
var result = await _context.ListPerformersAsync(_billing, id);
|
||||
ViewBag.Activity = await _context.Activities.FirstOrDefaultAsync(a => a.Code == activityCode);
|
||||
var result = await _context.ListPerformersAsync(_billing, activityCode);
|
||||
return View(result);
|
||||
}
|
||||
|
||||
|
|
|
|||
|
|
@ -54,10 +54,10 @@
|
|||
@Html.DisplayFor(model => model.Previsional)
|
||||
</dd>
|
||||
<dt>
|
||||
@Html.DisplayNameFor(model => model.Decided)
|
||||
@Html.DisplayNameFor(model => model.Reviewed)
|
||||
</dt>
|
||||
<dd>
|
||||
@Html.DisplayFor(model => model.Decided)
|
||||
@Html.DisplayFor(model => model.Reviewed)
|
||||
</dd>
|
||||
<dt>
|
||||
@Html.DisplayNameFor(model => model.DateModified)
|
||||
|
|
|
|||
|
|
@ -59,10 +59,10 @@
|
|||
@Html.DisplayFor(model => model.Previsional)
|
||||
</dd>
|
||||
<dt>
|
||||
@Html.DisplayNameFor(model => model.Decided)
|
||||
@Html.DisplayNameFor(model => model.Reviewed)
|
||||
</dt>
|
||||
<dd>
|
||||
@Html.DisplayFor(model => model.Decided)
|
||||
@Html.DisplayFor(model => model.Reviewed)
|
||||
</dd>
|
||||
<dt>
|
||||
@Html.DisplayNameFor(model => model.DateModified)
|
||||
|
|
|
|||
|
|
@ -45,8 +45,8 @@
|
|||
<div class="form-group">
|
||||
<div class="col-md-offset-2 col-md-10">
|
||||
<div class="checkbox">
|
||||
<input asp-for="Decided" />
|
||||
<label asp-for="Decided"></label>
|
||||
<input asp-for="Reviewed" />
|
||||
<label asp-for="Reviewed"></label>
|
||||
</div>
|
||||
</div>
|
||||
</div>
|
||||
|
|
|
|||
|
|
@ -33,7 +33,7 @@
|
|||
@Html.DisplayNameFor(model => model.Previsional)
|
||||
</th>
|
||||
<th>
|
||||
@Html.DisplayNameFor(model => model.Decided)
|
||||
@Html.DisplayNameFor(model => model.Reviewed)
|
||||
</th>
|
||||
<th>
|
||||
@Html.DisplayNameFor(model => model.DateModified)
|
||||
|
|
@ -80,7 +80,7 @@
|
|||
@Html.DisplayFor(modelItem => item.Previsional)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => item.Decided)
|
||||
@Html.DisplayFor(modelItem => item.Reviewed)
|
||||
</td>
|
||||
<td>
|
||||
@Html.DisplayFor(modelItem => item.DateModified)
|
||||
|
|
|
|||
|
|
@ -78,7 +78,7 @@ namespace Yavsc.Models.Billing
|
|||
[ForeignKey("ActivityCode"),JsonIgnore,Display(Name="Domaine d'activité")]
|
||||
public virtual Activity Context { get; set ; }
|
||||
|
||||
public bool Decided { get; set; }
|
||||
public bool Reviewed { get; set; }
|
||||
|
||||
|
||||
public abstract System.Collections.Generic.List<IBillItem> GetBillItems();
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue