mirror of
https://github.com/stokebob/BealeEngineering.git
synced 2026-03-19 06:37:15 +00:00
Invoice due date bug fix
This commit is contained in:
@@ -51,7 +51,7 @@ namespace BealeEngineering.Accounts
|
|||||||
{
|
{
|
||||||
if (tabControl1.SelectedTab == tabControl1.TabPages["tabClientPoAllocation"] && isDirtyInvoiceAllocation)
|
if (tabControl1.SelectedTab == tabControl1.TabPages["tabClientPoAllocation"] && isDirtyInvoiceAllocation)
|
||||||
{
|
{
|
||||||
btnRefreshInvAllocation_Click(null, null);
|
RefreshTabInvoiceAllocation();
|
||||||
}
|
}
|
||||||
else if (tabControl1.SelectedTab == tabControl1.TabPages["tabSaleInvoice"] && isDirtySaleInvoice)
|
else if (tabControl1.SelectedTab == tabControl1.TabPages["tabSaleInvoice"] && isDirtySaleInvoice)
|
||||||
{
|
{
|
||||||
|
|||||||
@@ -42,7 +42,6 @@
|
|||||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
|
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle2 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||||
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
|
System.Windows.Forms.DataGridViewCellStyle dataGridViewCellStyle1 = new System.Windows.Forms.DataGridViewCellStyle();
|
||||||
this.contactNameTextBox = new System.Windows.Forms.TextBox();
|
this.contactNameTextBox = new System.Windows.Forms.TextBox();
|
||||||
this.bsInvoice = new System.Windows.Forms.BindingSource(this.components);
|
|
||||||
this.currencyCodeTextBox = new System.Windows.Forms.TextBox();
|
this.currencyCodeTextBox = new System.Windows.Forms.TextBox();
|
||||||
this.dueDateDateTimePicker = new System.Windows.Forms.DateTimePicker();
|
this.dueDateDateTimePicker = new System.Windows.Forms.DateTimePicker();
|
||||||
this.invoiceDateDateTimePicker = new System.Windows.Forms.DateTimePicker();
|
this.invoiceDateDateTimePicker = new System.Windows.Forms.DateTimePicker();
|
||||||
@@ -53,6 +52,9 @@
|
|||||||
this.statusTextBox = new System.Windows.Forms.TextBox();
|
this.statusTextBox = new System.Windows.Forms.TextBox();
|
||||||
this.invoiceLineListBindingSource = new System.Windows.Forms.BindingSource(this.components);
|
this.invoiceLineListBindingSource = new System.Windows.Forms.BindingSource(this.components);
|
||||||
this.invoiceLineListDataGridView = new System.Windows.Forms.DataGridView();
|
this.invoiceLineListDataGridView = new System.Windows.Forms.DataGridView();
|
||||||
|
this.splitContainer1 = new System.Windows.Forms.SplitContainer();
|
||||||
|
this.taxTotalTextBox = new System.Windows.Forms.TextBox();
|
||||||
|
this.bsInvoice = new System.Windows.Forms.BindingSource(this.components);
|
||||||
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn1 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn3 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn4 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
@@ -60,8 +62,6 @@
|
|||||||
this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn7 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.dataGridViewTextBoxColumn8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn8 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
this.dataGridViewTextBoxColumn9 = new System.Windows.Forms.DataGridViewTextBoxColumn();
|
||||||
this.splitContainer1 = new System.Windows.Forms.SplitContainer();
|
|
||||||
this.taxTotalTextBox = new System.Windows.Forms.TextBox();
|
|
||||||
contactNameLabel = new System.Windows.Forms.Label();
|
contactNameLabel = new System.Windows.Forms.Label();
|
||||||
currencyCodeLabel = new System.Windows.Forms.Label();
|
currencyCodeLabel = new System.Windows.Forms.Label();
|
||||||
dueDateLabel = new System.Windows.Forms.Label();
|
dueDateLabel = new System.Windows.Forms.Label();
|
||||||
@@ -72,13 +72,13 @@
|
|||||||
saleInvoiceNumberLabel = new System.Windows.Forms.Label();
|
saleInvoiceNumberLabel = new System.Windows.Forms.Label();
|
||||||
statusLabel = new System.Windows.Forms.Label();
|
statusLabel = new System.Windows.Forms.Label();
|
||||||
taxTotalLabel = new System.Windows.Forms.Label();
|
taxTotalLabel = new System.Windows.Forms.Label();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.bsInvoice)).BeginInit();
|
|
||||||
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListBindingSource)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListBindingSource)).BeginInit();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListDataGridView)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListDataGridView)).BeginInit();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).BeginInit();
|
||||||
this.splitContainer1.Panel1.SuspendLayout();
|
this.splitContainer1.Panel1.SuspendLayout();
|
||||||
this.splitContainer1.Panel2.SuspendLayout();
|
this.splitContainer1.Panel2.SuspendLayout();
|
||||||
this.splitContainer1.SuspendLayout();
|
this.splitContainer1.SuspendLayout();
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.bsInvoice)).BeginInit();
|
||||||
this.SuspendLayout();
|
this.SuspendLayout();
|
||||||
//
|
//
|
||||||
// contactNameLabel
|
// contactNameLabel
|
||||||
@@ -179,10 +179,6 @@
|
|||||||
this.contactNameTextBox.Size = new System.Drawing.Size(200, 20);
|
this.contactNameTextBox.Size = new System.Drawing.Size(200, 20);
|
||||||
this.contactNameTextBox.TabIndex = 1;
|
this.contactNameTextBox.TabIndex = 1;
|
||||||
//
|
//
|
||||||
// bsInvoice
|
|
||||||
//
|
|
||||||
this.bsInvoice.DataSource = typeof(BealeEngineering.Core.Model.Sale.Invoice);
|
|
||||||
//
|
|
||||||
// currencyCodeTextBox
|
// currencyCodeTextBox
|
||||||
//
|
//
|
||||||
this.currencyCodeTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.bsInvoice, "CurrencyCode", true));
|
this.currencyCodeTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.bsInvoice, "CurrencyCode", true));
|
||||||
@@ -285,6 +281,57 @@
|
|||||||
this.invoiceLineListDataGridView.Size = new System.Drawing.Size(800, 296);
|
this.invoiceLineListDataGridView.Size = new System.Drawing.Size(800, 296);
|
||||||
this.invoiceLineListDataGridView.TabIndex = 18;
|
this.invoiceLineListDataGridView.TabIndex = 18;
|
||||||
//
|
//
|
||||||
|
// splitContainer1
|
||||||
|
//
|
||||||
|
this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
|
||||||
|
this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1;
|
||||||
|
this.splitContainer1.IsSplitterFixed = true;
|
||||||
|
this.splitContainer1.Location = new System.Drawing.Point(0, 0);
|
||||||
|
this.splitContainer1.Name = "splitContainer1";
|
||||||
|
this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal;
|
||||||
|
//
|
||||||
|
// splitContainer1.Panel1
|
||||||
|
//
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(taxTotalLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.taxTotalTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.saleInvoiceNumberTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.contactNameTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(statusLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(contactNameLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.statusTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.currencyCodeTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(saleInvoiceNumberLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(currencyCodeLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.dueDateDateTimePicker);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(referenceLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(dueDateLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.referenceTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.invoiceDateDateTimePicker);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(isCreditNoteLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(invoiceDateLabel);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.isCreditNoteCheckBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(this.invoiceTotalTextBox);
|
||||||
|
this.splitContainer1.Panel1.Controls.Add(invoiceTotalLabel);
|
||||||
|
//
|
||||||
|
// splitContainer1.Panel2
|
||||||
|
//
|
||||||
|
this.splitContainer1.Panel2.Controls.Add(this.invoiceLineListDataGridView);
|
||||||
|
this.splitContainer1.Size = new System.Drawing.Size(800, 475);
|
||||||
|
this.splitContainer1.SplitterDistance = 175;
|
||||||
|
this.splitContainer1.TabIndex = 19;
|
||||||
|
//
|
||||||
|
// taxTotalTextBox
|
||||||
|
//
|
||||||
|
this.taxTotalTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.bsInvoice, "TaxTotal", true));
|
||||||
|
this.taxTotalTextBox.Location = new System.Drawing.Point(578, 50);
|
||||||
|
this.taxTotalTextBox.Name = "taxTotalTextBox";
|
||||||
|
this.taxTotalTextBox.Size = new System.Drawing.Size(100, 20);
|
||||||
|
this.taxTotalTextBox.TabIndex = 19;
|
||||||
|
//
|
||||||
|
// bsInvoice
|
||||||
|
//
|
||||||
|
this.bsInvoice.DataSource = typeof(BealeEngineering.Core.Model.Sale.Invoice);
|
||||||
|
//
|
||||||
// dataGridViewTextBoxColumn1
|
// dataGridViewTextBoxColumn1
|
||||||
//
|
//
|
||||||
this.dataGridViewTextBoxColumn1.DataPropertyName = "LineNumber";
|
this.dataGridViewTextBoxColumn1.DataPropertyName = "LineNumber";
|
||||||
@@ -349,53 +396,6 @@
|
|||||||
this.dataGridViewTextBoxColumn9.ReadOnly = true;
|
this.dataGridViewTextBoxColumn9.ReadOnly = true;
|
||||||
this.dataGridViewTextBoxColumn9.Width = 50;
|
this.dataGridViewTextBoxColumn9.Width = 50;
|
||||||
//
|
//
|
||||||
// splitContainer1
|
|
||||||
//
|
|
||||||
this.splitContainer1.Dock = System.Windows.Forms.DockStyle.Fill;
|
|
||||||
this.splitContainer1.FixedPanel = System.Windows.Forms.FixedPanel.Panel1;
|
|
||||||
this.splitContainer1.IsSplitterFixed = true;
|
|
||||||
this.splitContainer1.Location = new System.Drawing.Point(0, 0);
|
|
||||||
this.splitContainer1.Name = "splitContainer1";
|
|
||||||
this.splitContainer1.Orientation = System.Windows.Forms.Orientation.Horizontal;
|
|
||||||
//
|
|
||||||
// splitContainer1.Panel1
|
|
||||||
//
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(taxTotalLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.taxTotalTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.saleInvoiceNumberTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.contactNameTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(statusLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(contactNameLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.statusTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.currencyCodeTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(saleInvoiceNumberLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(currencyCodeLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.dueDateDateTimePicker);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(referenceLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(dueDateLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.referenceTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.invoiceDateDateTimePicker);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(isCreditNoteLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(invoiceDateLabel);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.isCreditNoteCheckBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(this.invoiceTotalTextBox);
|
|
||||||
this.splitContainer1.Panel1.Controls.Add(invoiceTotalLabel);
|
|
||||||
//
|
|
||||||
// splitContainer1.Panel2
|
|
||||||
//
|
|
||||||
this.splitContainer1.Panel2.Controls.Add(this.invoiceLineListDataGridView);
|
|
||||||
this.splitContainer1.Size = new System.Drawing.Size(800, 475);
|
|
||||||
this.splitContainer1.SplitterDistance = 175;
|
|
||||||
this.splitContainer1.TabIndex = 19;
|
|
||||||
//
|
|
||||||
// taxTotalTextBox
|
|
||||||
//
|
|
||||||
this.taxTotalTextBox.DataBindings.Add(new System.Windows.Forms.Binding("Text", this.bsInvoice, "TaxTotal", true));
|
|
||||||
this.taxTotalTextBox.Location = new System.Drawing.Point(578, 50);
|
|
||||||
this.taxTotalTextBox.Name = "taxTotalTextBox";
|
|
||||||
this.taxTotalTextBox.Size = new System.Drawing.Size(100, 20);
|
|
||||||
this.taxTotalTextBox.TabIndex = 19;
|
|
||||||
//
|
|
||||||
// frmSaleInvoice
|
// frmSaleInvoice
|
||||||
//
|
//
|
||||||
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
|
||||||
@@ -407,7 +407,6 @@
|
|||||||
this.Name = "frmSaleInvoice";
|
this.Name = "frmSaleInvoice";
|
||||||
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
this.StartPosition = System.Windows.Forms.FormStartPosition.CenterParent;
|
||||||
this.Text = "SaleInvoice";
|
this.Text = "SaleInvoice";
|
||||||
((System.ComponentModel.ISupportInitialize)(this.bsInvoice)).EndInit();
|
|
||||||
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListBindingSource)).EndInit();
|
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListBindingSource)).EndInit();
|
||||||
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListDataGridView)).EndInit();
|
((System.ComponentModel.ISupportInitialize)(this.invoiceLineListDataGridView)).EndInit();
|
||||||
this.splitContainer1.Panel1.ResumeLayout(false);
|
this.splitContainer1.Panel1.ResumeLayout(false);
|
||||||
@@ -415,6 +414,7 @@
|
|||||||
this.splitContainer1.Panel2.ResumeLayout(false);
|
this.splitContainer1.Panel2.ResumeLayout(false);
|
||||||
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();
|
((System.ComponentModel.ISupportInitialize)(this.splitContainer1)).EndInit();
|
||||||
this.splitContainer1.ResumeLayout(false);
|
this.splitContainer1.ResumeLayout(false);
|
||||||
|
((System.ComponentModel.ISupportInitialize)(this.bsInvoice)).EndInit();
|
||||||
this.ResumeLayout(false);
|
this.ResumeLayout(false);
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -87,7 +87,7 @@ namespace BealeEngineering.Core.Data.Database.Sale
|
|||||||
,SaleInvoice.SaleInvoiceNumber
|
,SaleInvoice.SaleInvoiceNumber
|
||||||
,SaleInvoice.InvoiceDate
|
,SaleInvoice.InvoiceDate
|
||||||
,Contact.ContactName
|
,Contact.ContactName
|
||||||
,SaleInvoice.DateDue
|
,SaleInvoice.DateDue AS DueDate
|
||||||
,SaleInvoice.Reference
|
,SaleInvoice.Reference
|
||||||
,SaleInvoice.CurrencyCode
|
,SaleInvoice.CurrencyCode
|
||||||
,SaleInvoice.InvoiceTotal
|
,SaleInvoice.InvoiceTotal
|
||||||
|
|||||||
@@ -213,7 +213,7 @@ namespace BealeEngineering.Core.Data.Database.Sale
|
|||||||
SELECT SaleInvoice.SaleInvoiceID
|
SELECT SaleInvoice.SaleInvoiceID
|
||||||
,SaleInvoice.SaleInvoiceNumber
|
,SaleInvoice.SaleInvoiceNumber
|
||||||
,SaleInvoice.InvoiceDate
|
,SaleInvoice.InvoiceDate
|
||||||
,SaleInvoice.DateDue
|
,SaleInvoice.DateDue AS DueDate
|
||||||
,SaleInvoice.Reference
|
,SaleInvoice.Reference
|
||||||
,SaleInvoice.CurrencyCode
|
,SaleInvoice.CurrencyCode
|
||||||
,SaleInvoice.InvoiceTotal
|
,SaleInvoice.InvoiceTotal
|
||||||
|
|||||||
@@ -136,8 +136,8 @@ namespace BealeEngineering.Core.Data.Database.Sale
|
|||||||
cmd.Parameters.AddWithValue("@contactName", invoice.ContactName);
|
cmd.Parameters.AddWithValue("@contactName", invoice.ContactName);
|
||||||
cmd.Parameters.AddWithValue("@saleInvoiceNumber", invoice.SaleInvoiceNumber);
|
cmd.Parameters.AddWithValue("@saleInvoiceNumber", invoice.SaleInvoiceNumber);
|
||||||
cmd.Parameters.AddWithValue("@invoiceDate", invoice.InvoiceDate);
|
cmd.Parameters.AddWithValue("@invoiceDate", invoice.InvoiceDate);
|
||||||
if (invoice.DueDate == null) { cmd.Parameters.AddWithValue("@dateDue", DBNull.Value); }
|
if (invoice.DueDateIsSet) { cmd.Parameters.AddWithValue("@dateDue", invoice.DueDate); }
|
||||||
else { cmd.Parameters.AddWithValue("@dateDue", invoice.DueDate); }
|
else { cmd.Parameters.AddWithValue("@dateDue", DBNull.Value); }
|
||||||
cmd.Parameters.AddWithValue("@reference", invoice.Reference);
|
cmd.Parameters.AddWithValue("@reference", invoice.Reference);
|
||||||
cmd.Parameters.AddWithValue("@currencyCode", invoice.CurrencyCode);
|
cmd.Parameters.AddWithValue("@currencyCode", invoice.CurrencyCode);
|
||||||
cmd.Parameters.AddWithValue("@invoiceTotal", invoice.InvoiceTotal);
|
cmd.Parameters.AddWithValue("@invoiceTotal", invoice.InvoiceTotal);
|
||||||
|
|||||||
@@ -34,7 +34,7 @@ namespace BealeEngineering.Core.Logic.Adapter
|
|||||||
|
|
||||||
xeroInvoice.ContactName = invoiceList[i].ContactName;
|
xeroInvoice.ContactName = invoiceList[i].ContactName;
|
||||||
xeroInvoice.Currency = invoiceList[i].CurrencyCode;
|
xeroInvoice.Currency = invoiceList[i].CurrencyCode;
|
||||||
xeroInvoice.DueDate = invoiceList[i].DueDate;
|
if (invoiceList[i].DueDateIsSet) { xeroInvoice.DueDate = invoiceList[i].DueDate; }
|
||||||
xeroInvoice.InvoiceDate = invoiceList[i].InvoiceDate;
|
xeroInvoice.InvoiceDate = invoiceList[i].InvoiceDate;
|
||||||
xeroInvoice.InvoiceNumber = invoiceList[i].SaleInvoiceNumber;
|
xeroInvoice.InvoiceNumber = invoiceList[i].SaleInvoiceNumber;
|
||||||
xeroInvoice.Reference = invoiceList[i].Reference;
|
xeroInvoice.Reference = invoiceList[i].Reference;
|
||||||
|
|||||||
@@ -40,7 +40,7 @@ namespace BealeEngineering.Core.Logic.Adapter
|
|||||||
|
|
||||||
invoice.ContactName = xeroInvoiceList[i].ContactName;
|
invoice.ContactName = xeroInvoiceList[i].ContactName;
|
||||||
invoice.CurrencyCode = xeroInvoiceList[i].Currency;
|
invoice.CurrencyCode = xeroInvoiceList[i].Currency;
|
||||||
invoice.DueDate = xeroInvoiceList[i].DueDate;
|
if (xeroInvoiceList[i].DueDate != null) { invoice.DueDate = xeroInvoiceList[i].DueDate.GetValueOrDefault(); }
|
||||||
invoice.InvoiceDate = xeroInvoiceList[i].InvoiceDate;
|
invoice.InvoiceDate = xeroInvoiceList[i].InvoiceDate;
|
||||||
invoice.InvoiceTotal = xeroInvoiceList[i].Total;
|
invoice.InvoiceTotal = xeroInvoiceList[i].Total;
|
||||||
if (xeroInvoiceList[i].Type == "Sales invoice") { invoice.IsCreditNote = false; }
|
if (xeroInvoiceList[i].Type == "Sales invoice") { invoice.IsCreditNote = false; }
|
||||||
|
|||||||
@@ -9,6 +9,8 @@ namespace BealeEngineering.Core.Model.Sale
|
|||||||
{
|
{
|
||||||
public class InvoiceHeader : ValidateModel
|
public class InvoiceHeader : ValidateModel
|
||||||
{
|
{
|
||||||
|
private DateTime? dueDate = null;
|
||||||
|
|
||||||
public int SaleInvoiceID { get; set; }
|
public int SaleInvoiceID { get; set; }
|
||||||
|
|
||||||
[Required()]
|
[Required()]
|
||||||
@@ -20,7 +22,16 @@ namespace BealeEngineering.Core.Model.Sale
|
|||||||
[Required()]
|
[Required()]
|
||||||
public DateTime InvoiceDate { get; set; }
|
public DateTime InvoiceDate { get; set; }
|
||||||
|
|
||||||
public DateTime? DueDate { get; set; }
|
public DateTime DueDate
|
||||||
|
{
|
||||||
|
get { return dueDate.GetValueOrDefault(); }
|
||||||
|
set { dueDate = value; }
|
||||||
|
}
|
||||||
|
|
||||||
|
public bool DueDateIsSet
|
||||||
|
{
|
||||||
|
get { return dueDate != null; }
|
||||||
|
}
|
||||||
|
|
||||||
[StringLength(50)]
|
[StringLength(50)]
|
||||||
public string Reference { get; set; }
|
public string Reference { get; set; }
|
||||||
|
|||||||
Reference in New Issue
Block a user