📄 casherinvoice.cs
字号:
using System;
using System.Collections.Generic;
using System.Text;
using Sybase.DataWindow;
using SPRFrame;
namespace HPIResource.ShouFei
{
// 收款员发票
public class CasherInvoice : DataStore
{
string strSQl = "";
public CasherInvoice()
{
this.LibraryList = HPIR.PbdFile;
this.DataWindowObject = "dw_casherinvoice";
this.SetTransaction(SPRF.GetDB());
strSQl = this.GetSqlSelect();
}
public void ResetSQL()
{
this.SetSqlSelect(strSQl);
}
#region 属性
public int CasherID
{// 收款员编号
get
{
if (this.RowCount == 0) return -1;
try
{
return Convert.ToInt32(this.GetItemDouble(this.CurrentRow, "ActMan"));
}
catch
{
return -1;
}
}
set
{
if (this.RowCount == 0) return;
this.SetItemDouble(this.CurrentRow, "ActMan", value);
}
}
public int XH
{// 领用序号
get
{
if (this.RowCount == 0) return 0;
return Convert.ToInt32(this.GetItemDouble(this.CurrentRow, "xh"));
}
set
{
if (this.RowCount == 0) return;
this.SetItemDouble(this.CurrentRow, "xh", value);
}
}
public string InvType
{// 发票类型
get
{
if (this.RowCount == 0) return "NoData";
return this.GetItemString(this.CurrentRow, "InvType");
}
set
{
if (this.RowCount == 0) return;
this.SetItemString(this.CurrentRow, "InvType", value);
}
}
public int CurrentN0
{// 发票号码
get
{
if (this.RowCount == 0) return -1;
try
{
return Convert.ToInt32(this.GetItemDouble(this.CurrentRow, "CurrentInvoiceNo"));
}
catch
{
return 0;
}
}
set
{
if (this.RowCount == 0) return;
this.SetItemDouble(this.CurrentRow, "CurrentInvoiceNo", value);
}
}
#endregion
#region 取数据的方法
public void SetDataById(int ID)
{
this.ResetSQL();
string SqlString = this.GetSqlSelect();
SqlString += "where ActMan = " + ID.ToString();
this.SetSqlSelect(SqlString);
}
public void SetDataByCurrent(int ID,string invType)
{
this.ResetSQL();
string SqlString = this.GetSqlSelect();
SqlString += "where ActMan = " + ID.ToString() + " and xh = 0 and invType = '"+invType.ToUpper()+"'";
this.SetSqlSelect(SqlString);
}
#endregion
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -