* Makefile: builds the doc & htmldoc folders

* DataManager.cs: Doc generations

* T.cs:
* Global.asax.cs:
* Export.cs:
* Estim.tt:
* Estim.cs:
* TaskOutput.cs:
* FileInfoCollection.cs:
* RegisterPage.cs:
* BBCodeHelper.cs:
* MvcActionValueBinder.cs:
* YavscHelpers.cs:
* ValidateAjaxAttribute.cs:
* Entity.cs:
* IOrderInfo.cs:
* HomeController.cs:
* SimpleFormatter.cs:
* BlogsController.cs:
* AdminController.cs:
* SimpleJsonPostMethod.cs:
* WebCatalogExtensions.cs:
* GoogleController.cs:
* ModuleController.cs:
* BasketController.cs:
* AccountController.cs:
* TemplateException.cs:
* BlogsApiController.cs:
* EstimToPdfFormatter.cs:
* WorkFlowController.cs:
* FileSystemController.cs:
* BackOfficeController.cs:
* FrontOfficeController.cs:
* ThanksConfigurationSection.cs:
* ThanksConfigurationElement.cs:
* FrontOfficeApiController.cs:
* ModuleConfigurationElementCollection.cs: 

* Web.csproj: cleaning an obsolete IOrderIfno
This commit is contained in:
Paul Schneider 2015-01-27 00:41:20 +01:00
commit ae38718dd9
38 changed files with 848 additions and 277 deletions

View file

@ -7,13 +7,19 @@ using System.Text;
namespace Yavsc.Helpers
{
/// <summary>
/// BB code helper.
/// </summary>
public static class BBCodeHelper
{
static Dictionary<string,BBTag> parent = new Dictionary<string,BBTag> ();
private static string tclass="shoh";
private static string cclass="hiduh";
private static string mp4=null, ogg=null, webm=null;
/// <summary>
/// Gets or sets the BB code view class.
/// </summary>
/// <value>The BB code view class.</value>
public static string BBCodeViewClass {
get {
return cclass;
@ -22,7 +28,10 @@ namespace Yavsc.Helpers
cclass = value;
}
}
/// <summary>
/// Gets or sets the BB code case class.
/// </summary>
/// <value>The BB code case class.</value>
public static string BBCodeCaseClass {
get {
return tclass;
@ -31,7 +40,10 @@ namespace Yavsc.Helpers
tclass = value;
}
}
/// <summary>
/// Gets the BB tags usage.
/// </summary>
/// <value>The BB tags usage.</value>
public static string[] BBTagsUsage {
get {
@ -85,7 +97,9 @@ namespace Yavsc.Helpers
private static int sect2;
private static int sect3;
private static Dictionary<string,string> d = new Dictionary<string,string> ();
/// <summary>
/// Init this instance.
/// </summary>
public static void Init ()
{
sect1 = 0;
@ -263,7 +277,10 @@ namespace Yavsc.Helpers
sb.Append (cnt);
return sb.ToString();
}
/// <summary>
/// Gets the parser.
/// </summary>
/// <value>The parser.</value>
public static BBCodeParser Parser {
get {
if (parser == null) {

View file

@ -30,17 +30,25 @@ using Newtonsoft.Json;
namespace Yavsc.Helpers.Google
{
/// <summary>
/// Entity.
/// </summary>
public class Entity
{
/// <summary>
/// The I.
/// </summary>
public string ID;
/// <summary>
/// The name.
/// </summary>
public string Name;
/// <summary>
/// The type:
// AUTOMOBILE: A car or passenger vehicle.
// TRUCK: A truck or cargo vehicle.
// WATERCRAFT: A boat or other waterborne vehicle.
// PERSON: A person.
/// The type: AUTOMOBILE: A car or passenger vehicle.
/// * TRUCK: A truck or cargo vehicle.
/// * WATERCRAFT: A boat or other waterborne vehicle.
/// * PERSON: A person.
/// </summary>
public string Type;
}

View file

@ -26,6 +26,9 @@ using Newtonsoft.Json;
namespace Yavsc.Helpers
{
/// <summary>
/// Simple json post method.
/// </summary>
public class SimpleJsonPostMethod<TQuery,TAnswer>: IDisposable
{
internal HttpWebRequest request = null;
@ -36,15 +39,25 @@ namespace Yavsc.Helpers
set { Request.TransferEncoding=value;}
}
string Method { get { return Request.Method; } }
/// <summary>
/// Gets the path.
/// </summary>
/// <value>The path.</value>
public string Path {
get{ return Request.RequestUri.ToString(); }
}
/// <summary>
/// Sets the credential.
/// </summary>
/// <param name="cred">Cred.</param>
public void SetCredential(string cred) {
Request.Headers.Add(HttpRequestHeader.Authorization,cred);
}
/// <summary>
/// Initializes a new instance of the Yavsc.Helpers.SimpleJsonPostMethod class.
/// </summary>
/// <param name="pathToMethod">Path to method.</param>
public SimpleJsonPostMethod (string pathToMethod)
{
// ASSERT Request == null
@ -55,7 +68,10 @@ namespace Yavsc.Helpers
Request.ContentType = "application/json";
Request.TransferEncoding = "UTF-8";
}
/// <summary>
/// Invoke the specified query.
/// </summary>
/// <param name="query">Query.</param>
public TAnswer Invoke(TQuery query)
{
Byte[] bytes = System.Text.Encoding.UTF8.GetBytes (JsonConvert.SerializeObject(query));
@ -81,6 +97,14 @@ namespace Yavsc.Helpers
}
#region IDisposable implementation
/// <summary>
/// Releases all resource used by the <see cref="Yavsc.Helpers.SimpleJsonPostMethod`2"/> object.
/// </summary>
/// <remarks>Call <see cref="Dispose"/> when you are finished using the <see cref="Yavsc.Helpers.SimpleJsonPostMethod`2"/>. The
/// <see cref="Dispose"/> method leaves the <see cref="Yavsc.Helpers.SimpleJsonPostMethod`2"/> in an unusable state.
/// After calling <see cref="Dispose"/>, you must release all references to the
/// <see cref="Yavsc.Helpers.SimpleJsonPostMethod`2"/> so the garbage collector can reclaim the memory that the
/// <see cref="Yavsc.Helpers.SimpleJsonPostMethod`2"/> was occupying.</remarks>
public void Dispose ()
{
if (Request != null) Request.Abort ();

View file

@ -12,8 +12,16 @@ using Yavsc.Model;
namespace Yavsc.Helpers
{
/// <summary>
/// T.
/// </summary>
public class T
{
/// <summary>
/// Gets the string.
/// </summary>
/// <returns>The string.</returns>
/// <param name="msg">Message.</param>
public static string GetString(string msg)
{
string tr = LocalizedText.ResourceManager.GetString (msg.Replace (" ", "_"));

View file

@ -4,9 +4,16 @@ using System.Configuration;
namespace Yavsc.Helpers
{
/// <summary>
/// Yavsc helpers.
/// </summary>
public static class YavscHelpers
{
private static string siteName = null;
/// <summary>
/// Gets the name of the site.
/// </summary>
/// <value>The name of the site.</value>
public static string SiteName {
get {
if (siteName == null)