* style.css:

* UserPost.aspx:
* Estimate.cs:
* Writting.cs:
* WorkFlowController.cs:
* NpgsqlContentProvider.cs: 
* FrontOfficeApiController.cs: Fixed the GetEstimate function,
  refactoring
This commit is contained in:
Paul Schneider 2014-09-23 12:25:41 +02:00
commit 8fee293665
7 changed files with 48 additions and 35 deletions

View file

@ -22,7 +22,8 @@ namespace Yavsc.ApiControllers
[AcceptVerbs("GET")]
public Catalog Catalog ()
{
return CatalogManager.GetCatalog ();
Catalog c = CatalogManager.GetCatalog ();
return c;
}
[AcceptVerbs("GET")]
@ -65,29 +66,7 @@ namespace Yavsc.ApiControllers
return result;
}
[HttpPost]
public string ProfileImagePost(HttpPostedFile profileImage)
{
string[] extensions = { ".jpg", ".jpeg", ".gif", ".bmp", ".png" };
if (!extensions.Any(x => x.Equals(Path.GetExtension(profileImage.FileName.ToLower()), StringComparison.OrdinalIgnoreCase)))
{
throw new HttpResponseException(
new HttpResponseMessage(HttpStatusCode.BadRequest));
}
// string root = System.Web.HttpContext.Current.Server.MapPath("~/App_Data/uploads");
// Other code goes here
// profileImage.SaveAs ();
return "/path/to/image.png";
}
[HttpGet]
[Authorize]
public long CreateEstimate (string title)
{
return WFManager.CreateEstimate (
Membership.GetUser().UserName,title);
}
[HttpGet]
[Authorize]
public long AddToBasket (string title)