2022-07-04 11:17:39 +00:00
|
|
|
|
using System;
|
|
|
|
|
|
using System.Data;
|
|
|
|
|
|
|
2022-09-09 14:35:49 +00:00
|
|
|
|
public class TableIAP : TableBase<TableIAP, DataIAP, string>
|
2022-07-04 11:17:39 +00:00
|
|
|
|
{
|
|
|
|
|
|
public override DataIAP GetData(string pID)
|
|
|
|
|
|
{
|
|
|
|
|
|
return mDataList.Find(pItem => pItem.ProductID.Equals(pID));
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
|
|
|
|
[Serializable]
|
|
|
|
|
|
public class DataIAP : DataBase<DataIAP>
|
|
|
|
|
|
{
|
|
|
|
|
|
public string ProductID;
|
|
|
|
|
|
public string ProductName;
|
|
|
|
|
|
public string Icon;
|
|
|
|
|
|
public int DiamondNum;
|
|
|
|
|
|
public string Price;
|
|
|
|
|
|
|
|
|
|
|
|
public override void ParseData(DataRow pCollection)
|
|
|
|
|
|
{
|
|
|
|
|
|
ProductID = pCollection[0].ToString();
|
|
|
|
|
|
ProductName = pCollection[1].ToString();
|
|
|
|
|
|
Icon = pCollection[2].ToString();
|
|
|
|
|
|
DiamondNum = 0;
|
|
|
|
|
|
int.TryParse(pCollection[3].ToString(), out DiamondNum);
|
|
|
|
|
|
Price = pCollection[4].ToString();
|
|
|
|
|
|
}
|
|
|
|
|
|
}
|