This commit is contained in:
2022-07-04 17:41:02 +00:00
parent 11cfe45fef
commit f718b34280
4 changed files with 371 additions and 0 deletions

View File

@@ -205,6 +205,12 @@
<DependentUpon>Waiting.cs</DependentUpon> <DependentUpon>Waiting.cs</DependentUpon>
</Compile> </Compile>
<Compile Include="WorkOrderStatus.cs" /> <Compile Include="WorkOrderStatus.cs" />
<Compile Include="SetQBImportInventoryAccounts.cs">
<SubType>Form</SubType>
</Compile>
<Compile Include="SetQBImportInventoryAccounts.Designer.cs">
<DependentUpon>SetQBImportInventoryAccounts.cs</DependentUpon>
</Compile>
<EmbeddedResource Include="ApproveCompanyFile.resx"> <EmbeddedResource Include="ApproveCompanyFile.resx">
<DependentUpon>ApproveCompanyFile.cs</DependentUpon> <DependentUpon>ApproveCompanyFile.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
@@ -254,6 +260,9 @@
<EmbeddedResource Include="SetQBClass.resx"> <EmbeddedResource Include="SetQBClass.resx">
<DependentUpon>SetQBClass.cs</DependentUpon> <DependentUpon>SetQBClass.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>
<EmbeddedResource Include="SetQBImportInventoryAccounts.resx">
<DependentUpon>SetQBImportInventoryAccounts.cs</DependentUpon>
</EmbeddedResource>
<EmbeddedResource Include="SetQBImportServiceRateAccounts.resx"> <EmbeddedResource Include="SetQBImportServiceRateAccounts.resx">
<DependentUpon>SetQBImportServiceRateAccounts.cs</DependentUpon> <DependentUpon>SetQBImportServiceRateAccounts.cs</DependentUpon>
</EmbeddedResource> </EmbeddedResource>

View File

@@ -0,0 +1,197 @@
namespace AyaNovaQBI
{
partial class SetQBImportInventoryAccounts
{
/// <summary>
/// Required designer variable.
/// </summary>
private System.ComponentModel.IContainer components = null;
/// <summary>
/// Clean up any resources being used.
/// </summary>
/// <param name="disposing">true if managed resources should be disposed; otherwise, false.</param>
protected override void Dispose(bool disposing)
{
if (disposing && (components != null))
{
components.Dispose();
}
base.Dispose(disposing);
}
#region Windows Form Designer generated code
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.cbIncome = new System.Windows.Forms.ComboBox();
this.label2 = new System.Windows.Forms.Label();
this.label3 = new System.Windows.Forms.Label();
this.label1 = new System.Windows.Forms.Label();
this.btnOK = new System.Windows.Forms.Button();
this.btnCancel = new System.Windows.Forms.Button();
this.cbCogs = new System.Windows.Forms.ComboBox();
this.label4 = new System.Windows.Forms.Label();
this.label5 = new System.Windows.Forms.Label();
this.cbAsset = new System.Windows.Forms.ComboBox();
this.label6 = new System.Windows.Forms.Label();
this.label7 = new System.Windows.Forms.Label();
this.SuspendLayout();
//
// cbIncome
//
this.cbIncome.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cbIncome.FormattingEnabled = true;
this.cbIncome.Location = new System.Drawing.Point(12, 211);
this.cbIncome.Name = "cbIncome";
this.cbIncome.Size = new System.Drawing.Size(407, 21);
this.cbIncome.TabIndex = 27;
//
// label2
//
this.label2.Location = new System.Drawing.Point(12, 191);
this.label2.Name = "label2";
this.label2.Size = new System.Drawing.Size(407, 18);
this.label2.TabIndex = 26;
this.label2.Text = "Income account";
//
// label3
//
this.label3.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label3.Location = new System.Drawing.Point(12, 170);
this.label3.Name = "label3";
this.label3.Size = new System.Drawing.Size(407, 21);
this.label3.TabIndex = 25;
this.label3.Text = "Sales information:";
//
// label1
//
this.label1.Font = new System.Drawing.Font("Tahoma", 14.25F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label1.Location = new System.Drawing.Point(12, 16);
this.label1.Name = "label1";
this.label1.Size = new System.Drawing.Size(407, 32);
this.label1.TabIndex = 24;
this.label1.Text = "Default accounts";
//
// btnOK
//
this.btnOK.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnOK.Location = new System.Drawing.Point(350, 410);
this.btnOK.Name = "btnOK";
this.btnOK.Size = new System.Drawing.Size(75, 23);
this.btnOK.TabIndex = 23;
this.btnOK.Text = "OK";
this.btnOK.UseVisualStyleBackColor = true;
//
// btnCancel
//
this.btnCancel.Anchor = ((System.Windows.Forms.AnchorStyles)(((System.Windows.Forms.AnchorStyles.Bottom | System.Windows.Forms.AnchorStyles.Left)
| System.Windows.Forms.AnchorStyles.Right)));
this.btnCancel.DialogResult = System.Windows.Forms.DialogResult.Cancel;
this.btnCancel.Location = new System.Drawing.Point(12, 410);
this.btnCancel.Name = "btnCancel";
this.btnCancel.Size = new System.Drawing.Size(75, 23);
this.btnCancel.TabIndex = 22;
this.btnCancel.Text = "Cancel";
this.btnCancel.UseVisualStyleBackColor = true;
//
// cbCogs
//
this.cbCogs.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cbCogs.FormattingEnabled = true;
this.cbCogs.Location = new System.Drawing.Point(12, 117);
this.cbCogs.Name = "cbCogs";
this.cbCogs.Size = new System.Drawing.Size(403, 21);
this.cbCogs.TabIndex = 31;
//
// label4
//
this.label4.Location = new System.Drawing.Point(12, 94);
this.label4.Name = "label4";
this.label4.Size = new System.Drawing.Size(403, 18);
this.label4.TabIndex = 30;
this.label4.Text = "COGS account";
//
// label5
//
this.label5.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label5.Location = new System.Drawing.Point(12, 66);
this.label5.Name = "label5";
this.label5.Size = new System.Drawing.Size(403, 20);
this.label5.TabIndex = 29;
this.label5.Text = "Purchase information:";
//
// cbAsset
//
this.cbAsset.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
this.cbAsset.FormattingEnabled = true;
this.cbAsset.Location = new System.Drawing.Point(12, 316);
this.cbAsset.Name = "cbAsset";
this.cbAsset.Size = new System.Drawing.Size(407, 21);
this.cbAsset.TabIndex = 34;
//
// label6
//
this.label6.Location = new System.Drawing.Point(12, 296);
this.label6.Name = "label6";
this.label6.Size = new System.Drawing.Size(407, 18);
this.label6.TabIndex = 33;
this.label6.Text = "Asset account";
//
// label7
//
this.label7.Font = new System.Drawing.Font("Tahoma", 9F, System.Drawing.FontStyle.Bold, System.Drawing.GraphicsUnit.Point, ((byte)(0)));
this.label7.Location = new System.Drawing.Point(12, 274);
this.label7.Name = "label7";
this.label7.Size = new System.Drawing.Size(407, 20);
this.label7.TabIndex = 32;
this.label7.Text = "Inventory information:";
//
// SetQBImportInventoryAccounts
//
this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F);
this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font;
this.ClientSize = new System.Drawing.Size(435, 445);
this.ControlBox = false;
this.Controls.Add(this.cbAsset);
this.Controls.Add(this.label6);
this.Controls.Add(this.label7);
this.Controls.Add(this.cbCogs);
this.Controls.Add(this.label4);
this.Controls.Add(this.label5);
this.Controls.Add(this.cbIncome);
this.Controls.Add(this.label2);
this.Controls.Add(this.label3);
this.Controls.Add(this.label1);
this.Controls.Add(this.btnOK);
this.Controls.Add(this.btnCancel);
this.FormBorderStyle = System.Windows.Forms.FormBorderStyle.FixedDialog;
this.Name = "SetQBImportInventoryAccounts";
this.ShowInTaskbar = false;
this.Text = "Import inventory items";
this.Load += new System.EventHandler(this.SetQBImportInventoryAccounts_Load);
this.ResumeLayout(false);
}
#endregion
private System.Windows.Forms.ComboBox cbIncome;
private System.Windows.Forms.Label label2;
private System.Windows.Forms.Label label3;
private System.Windows.Forms.Label label1;
private System.Windows.Forms.Button btnOK;
private System.Windows.Forms.Button btnCancel;
private System.Windows.Forms.ComboBox cbCogs;
private System.Windows.Forms.Label label4;
private System.Windows.Forms.Label label5;
private System.Windows.Forms.ComboBox cbAsset;
private System.Windows.Forms.Label label6;
private System.Windows.Forms.Label label7;
}
}

View File

@@ -0,0 +1,45 @@
using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
using System.Windows.Forms;
namespace AyaNovaQBI
{
public partial class SetQBImportInventoryAccounts : Form
{
public SetQBImportInventoryAccounts()
{
InitializeComponent();
}
private void SetQBImportInventoryAccounts_Load(object sender, EventArgs e)
{
//Fill combo's and select defaults
cbAsset.BindingContext = new BindingContext();//Ensure unique binding context so multiple combo boxes bound to same datasource can be selected independantly
cbAsset.DisplayMember = "FullName";
cbAsset.ValueMember = "ID";
cbAsset.DataSource = util.QBAccounts;
if (!string.IsNullOrEmpty(util.QDat.QBInventoryAssetAccountRef))
cbAsset.SelectedValue = util.QDat.QBInventoryAssetAccountRef;
cbCogs.BindingContext = new BindingContext();
cbCogs.DisplayMember = "FullName";
cbCogs.ValueMember = "ID";
cbCogs.DataSource = util.QBAccounts;
if (!string.IsNullOrEmpty(util.QDat.QBInventoryCOGSAccountRef))
cbCogs.SelectedValue = util.QDat.QBInventoryCOGSAccountRef;
cbIncome.BindingContext = new BindingContext();
cbIncome.DisplayMember = "FullName";
cbIncome.ValueMember = "ID";
cbIncome.DataSource = util.QBAccounts;
if (!string.IsNullOrEmpty(util.QDat.QBInventoryIncomeAccountReference))
cbIncome.SelectedValue = util.QDat.QBInventoryIncomeAccountReference;
}
}
}

View File

@@ -0,0 +1,120 @@
<?xml version="1.0" encoding="utf-8"?>
<root>
<!--
Microsoft ResX Schema
Version 2.0
The primary goals of this format is to allow a simple XML format
that is mostly human readable. The generation and parsing of the
various data types are done through the TypeConverter classes
associated with the data types.
Example:
... ado.net/XML headers & schema ...
<resheader name="resmimetype">text/microsoft-resx</resheader>
<resheader name="version">2.0</resheader>
<resheader name="reader">System.Resources.ResXResourceReader, System.Windows.Forms, ...</resheader>
<resheader name="writer">System.Resources.ResXResourceWriter, System.Windows.Forms, ...</resheader>
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
<value>[base64 mime encoded serialized .NET Framework object]</value>
</data>
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
<comment>This is a comment</comment>
</data>
There are any number of "resheader" rows that contain simple
name/value pairs.
Each data row contains a name, and value. The row also contains a
type or mimetype. Type corresponds to a .NET class that support
text/value conversion through the TypeConverter architecture.
Classes that don't support this are serialized and stored with the
mimetype set.
The mimetype is used for serialized objects, and tells the
ResXResourceReader how to depersist the object. This is currently not
extensible. For a given mimetype the value must be set accordingly:
Note - application/x-microsoft.net.object.binary.base64 is the format
that the ResXResourceWriter will generate, however the reader can
read any of the formats listed below.
mimetype: application/x-microsoft.net.object.binary.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Binary.BinaryFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.soap.base64
value : The object must be serialized with
: System.Runtime.Serialization.Formatters.Soap.SoapFormatter
: and then encoded with base64 encoding.
mimetype: application/x-microsoft.net.object.bytearray.base64
value : The object must be serialized into a byte array
: using a System.ComponentModel.TypeConverter
: and then encoded with base64 encoding.
-->
<xsd:schema id="root" xmlns="" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:msdata="urn:schemas-microsoft-com:xml-msdata">
<xsd:import namespace="http://www.w3.org/XML/1998/namespace" />
<xsd:element name="root" msdata:IsDataSet="true">
<xsd:complexType>
<xsd:choice maxOccurs="unbounded">
<xsd:element name="metadata">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" />
</xsd:sequence>
<xsd:attribute name="name" use="required" type="xsd:string" />
<xsd:attribute name="type" type="xsd:string" />
<xsd:attribute name="mimetype" type="xsd:string" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="assembly">
<xsd:complexType>
<xsd:attribute name="alias" type="xsd:string" />
<xsd:attribute name="name" type="xsd:string" />
</xsd:complexType>
</xsd:element>
<xsd:element name="data">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
<xsd:element name="comment" type="xsd:string" minOccurs="0" msdata:Ordinal="2" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" msdata:Ordinal="1" />
<xsd:attribute name="type" type="xsd:string" msdata:Ordinal="3" />
<xsd:attribute name="mimetype" type="xsd:string" msdata:Ordinal="4" />
<xsd:attribute ref="xml:space" />
</xsd:complexType>
</xsd:element>
<xsd:element name="resheader">
<xsd:complexType>
<xsd:sequence>
<xsd:element name="value" type="xsd:string" minOccurs="0" msdata:Ordinal="1" />
</xsd:sequence>
<xsd:attribute name="name" type="xsd:string" use="required" />
</xsd:complexType>
</xsd:element>
</xsd:choice>
</xsd:complexType>
</xsd:element>
</xsd:schema>
<resheader name="resmimetype">
<value>text/microsoft-resx</value>
</resheader>
<resheader name="version">
<value>2.0</value>
</resheader>
<resheader name="reader">
<value>System.Resources.ResXResourceReader, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
<resheader name="writer">
<value>System.Resources.ResXResourceWriter, System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089</value>
</resheader>
</root>