Added Basecode to Product

Added Voucher Type During Printing
Added Discount Report
Fixed Void bill table not getting cleared error
Added PAX to table
Removed Itital Setup button in MainForm as it was not doing anything
This commit is contained in:
unknown
2011-12-05 15:11:02 +05:30
parent 719dbd49d2
commit 964d0a78bf
54 changed files with 2285 additions and 1028 deletions

View File

@ -20,5 +20,10 @@ namespace Tanshu.Common.Helpers
var attribute = (DisplayAttribute)settleOption.GetType().GetField(settleOption.ToString()).GetCustomAttributes(typeof(DisplayAttribute), false)[0];
return attribute;
}
public static DisplayAttribute Attribute(this VoucherType settleOption)
{
var attribute = (DisplayAttribute)settleOption.GetType().GetField(settleOption.ToString()).GetCustomAttributes(typeof(DisplayAttribute), false)[0];
return attribute;
}
}
}

View File

@ -0,0 +1,26 @@
namespace Tanshu.Common.Helpers
{
public enum Align
{
Left = 1,
Centre = 2,
Right = 4
}
public static class StringHelper
{
public static string Center(this string input, int width)
{
if (input.Length > width)
return input;
var left = ((width - input.Length) / 2) + input.Length;
input = string.Format("{0,-" + left + "}", input);
return string.Format("{0," + width + "}", input);
}
public static string Center42(this string input)
{
return Center(input, 42);
}
}
}