11
This commit is contained in:
@@ -268,8 +268,7 @@
|
||||
<HintPath>..\..\派诺(1)\派诺\git\6、程序\GZ_KD_Parino\bin\Debug\log4net.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="Newtonsoft.Json, Version=13.0.0.0, Culture=neutral, PublicKeyToken=30ad4fe6b2a6aeed, processorArchitecture=MSIL">
|
||||
<SpecificVersion>False</SpecificVersion>
|
||||
<HintPath>..\..\派诺(1)\派诺\git\6、程序\GZ_KD_Parino\bin\Debug\Newtonsoft.Json.dll</HintPath>
|
||||
<HintPath>..\packages\Newtonsoft.Json.13.0.3\lib\net45\Newtonsoft.Json.dll</HintPath>
|
||||
</Reference>
|
||||
<Reference Include="NPOI">
|
||||
<HintPath>..\..\派诺(1)\派诺\git\6、程序\GZ_KD_Parino\bin\Debug\NPOI.dll</HintPath>
|
||||
@@ -335,6 +334,9 @@
|
||||
<Compile Include="SQL\SqlManage_yuyubo.cs" />
|
||||
<Compile Include="SQL\SqlManage.cs" />
|
||||
</ItemGroup>
|
||||
<ItemGroup>
|
||||
<None Include="packages.config" />
|
||||
</ItemGroup>
|
||||
<Import Project="$(MSBuildToolsPath)\Microsoft.CSharp.targets" />
|
||||
<PropertyGroup>
|
||||
<PostBuildEvent>
|
||||
|
||||
@@ -1297,253 +1297,253 @@ namespace Pilot_KD_Parino.QPHY_AutoWrire
|
||||
});
|
||||
}
|
||||
}
|
||||
#region DataChanged(单据体值更新事件)
|
||||
///// <summary>
|
||||
///// 单据体值更新事件
|
||||
///// </summary>
|
||||
///// <param name="e"></param>
|
||||
//public override void DataChanged(DataChangedEventArgs e)
|
||||
//{
|
||||
// base.DataChanged(e);
|
||||
// if (e.Field.Key.Equals("FShuaXin"))
|
||||
// {
|
||||
// //文本字段触发值更新时,模拟用户点击菜单,此处模拟点击“选项”菜单:
|
||||
// ((IDynamicFormViewService)this.View).MainBarItemClick("MBBA_tbButton_1");
|
||||
// }
|
||||
// if (e.Field.Key.Equals("FCONTRACTNUMBER2"))
|
||||
// {
|
||||
// if (INDEXNumber == 0)
|
||||
// {
|
||||
// //获取销售订单/应收单单据体数据
|
||||
// DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
|
||||
/// <summary>
|
||||
/// 单据体值更新事件
|
||||
/// </summary>
|
||||
/// <param name="e"></param>
|
||||
public override void DataChanged(DataChangedEventArgs e)
|
||||
{
|
||||
base.DataChanged(e);
|
||||
if (e.Field.Key.Equals("FShuaXin"))
|
||||
{
|
||||
//文本字段触发值更新时,模拟用户点击菜单,此处模拟点击“选项”菜单:
|
||||
((IDynamicFormViewService)this.View).MainBarItemClick("MBBA_tbButton_1");
|
||||
}
|
||||
if (e.Field.Key.Equals("FCONTRACTNUMBER2"))
|
||||
{
|
||||
if (INDEXNumber == 0)
|
||||
{
|
||||
//获取销售订单/应收单单据体数据
|
||||
DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
// SaleBILLLIS = new List<CombinaClass>();
|
||||
|
||||
SaleBILLLIS = new List<CombinaClass>();
|
||||
// foreach (var item in FEntity)
|
||||
// {
|
||||
// SaleBILLLIS.Add(new CombinaClass()
|
||||
// {
|
||||
// FBIllNO = item["FBILLNO"]?.ToString(),
|
||||
// FCONTRACTNUMBER = item["FCONTRACTNUMBER"]?.ToString(),
|
||||
// FClient = Convert.ToInt32(item["FClient_Id"]),
|
||||
// FDate = item["FDate"]?.ToString(),
|
||||
// FALLAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_c1c"]),
|
||||
// FYAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_vb1"]),
|
||||
// FDAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_emq"]),
|
||||
// FSKBIllNO = item["FSKBILLNO"]?.ToString(),
|
||||
// FCreated = Convert.ToInt32(item["FCreated_Id"]),
|
||||
// FSalesman = Convert.ToInt32(item["FSalesman_Id"]),
|
||||
// FType = item["FType"]?.ToString(),
|
||||
// FISHX = item["FISHX"]?.ToString(),
|
||||
// FWeiYi = item["FWeiYi"]?.ToString(),
|
||||
// });
|
||||
// }
|
||||
|
||||
foreach (var item in FEntity)
|
||||
{
|
||||
SaleBILLLIS.Add(new CombinaClass()
|
||||
{
|
||||
FBIllNO = item["FBILLNO"]?.ToString(),
|
||||
FCONTRACTNUMBER = item["FCONTRACTNUMBER"]?.ToString(),
|
||||
FClient = Convert.ToInt32(item["FClient_Id"]),
|
||||
FDate = item["FDate"]?.ToString(),
|
||||
FALLAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_c1c"]),
|
||||
FYAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_vb1"]),
|
||||
FDAMOUNT = Convert.ToDouble(item["F_MBBA_Decimal_emq"]),
|
||||
FSKBIllNO = item["FSKBILLNO"]?.ToString(),
|
||||
FCreated = Convert.ToInt32(item["FCreated_Id"]),
|
||||
FSalesman = Convert.ToInt32(item["FSalesman_Id"]),
|
||||
FType = item["FType"]?.ToString(),
|
||||
FISHX = item["FISHX"]?.ToString(),
|
||||
FWeiYi = item["FWeiYi"]?.ToString(),
|
||||
});
|
||||
}
|
||||
// var fBILLNO = this.Model.GetValue("FBILLNO2", e.Row);
|
||||
// var fCONTRACTNUMBER = this.Model.GetValue("FCONTRACTNUMBER2", e.Row);
|
||||
|
||||
var fBILLNO = this.Model.GetValue("FBILLNO2", e.Row);
|
||||
var fCONTRACTNUMBER = this.Model.GetValue("FCONTRACTNUMBER2", e.Row);
|
||||
// //判断是否为空
|
||||
// if (string.IsNullOrWhiteSpace(fCONTRACTNUMBER?.ToString()))
|
||||
// {
|
||||
// this.Model.SetValue("FISHX2", "", e.Row);
|
||||
|
||||
//判断是否为空
|
||||
if (string.IsNullOrWhiteSpace(fCONTRACTNUMBER?.ToString()))
|
||||
{
|
||||
this.Model.SetValue("FISHX2", "", e.Row);
|
||||
// this.Model.SetValue("F_MBBA_Decimal_qtr", 0, e.Row);
|
||||
|
||||
this.Model.SetValue("F_MBBA_Decimal_qtr", 0, e.Row);
|
||||
// //获取当前的父id
|
||||
// var fPARENTROWID = this.Model.GetValue("FPARENTROWID", e.Row)?.ToString();
|
||||
|
||||
//获取当前的父id
|
||||
var fPARENTROWID = this.Model.GetValue("FPARENTROWID", e.Row)?.ToString();
|
||||
// DynamicObjectCollection FEntity2 = this.View.Model.DataObject["FEntity2"] as DynamicObjectCollection;
|
||||
|
||||
DynamicObjectCollection FEntity2 = this.View.Model.DataObject["FEntity2"] as DynamicObjectCollection;
|
||||
// //获取行数
|
||||
// List<int> ints = new List<int>();
|
||||
|
||||
//获取行数
|
||||
List<int> ints = new List<int>();
|
||||
// foreach (var fEntity in FEntity2)
|
||||
// {
|
||||
// if (fEntity["PARENTROWID"]?.ToString() == fPARENTROWID && fEntity["F_RowNew"]?.ToString() == "0")
|
||||
// {
|
||||
// ints.Add(Convert.ToInt32(fEntity["seq"]) - 1);
|
||||
// }
|
||||
// }
|
||||
|
||||
foreach (var fEntity in FEntity2)
|
||||
{
|
||||
if (fEntity["PARENTROWID"]?.ToString() == fPARENTROWID && fEntity["F_RowNew"]?.ToString() == "0")
|
||||
{
|
||||
ints.Add(Convert.ToInt32(fEntity["seq"]) - 1);
|
||||
}
|
||||
}
|
||||
// //循环删除子项
|
||||
// for (int i = 0; i < ints.Count; i++)
|
||||
// {
|
||||
// this.View.Model.DeleteEntryRow("FEntity2", ints[0]);
|
||||
// }
|
||||
|
||||
//循环删除子项
|
||||
for (int i = 0; i < ints.Count; i++)
|
||||
{
|
||||
this.View.Model.DeleteEntryRow("FEntity2", ints[0]);
|
||||
}
|
||||
// foreach (var item in SaleBILLLIS)
|
||||
// {
|
||||
// if (!string.IsNullOrEmpty(item.FSKBIllNO))
|
||||
// {
|
||||
// string[] strings = item.FSKBIllNO?.ToString()?.Split(',');
|
||||
// //判断假如是一个收款单对应多个销售订单
|
||||
// if (strings.Contains(fBILLNO?.ToString()) && strings.Count() == 1)
|
||||
// {
|
||||
// item.FSKBIllNO = "";
|
||||
// item.FISHX = "";
|
||||
// item.FWeiYi = "";
|
||||
// }
|
||||
// //判断多个收款单对应一个销售订单
|
||||
// else if (strings.Contains(fBILLNO?.ToString()) && strings.Count() > 1)
|
||||
// {
|
||||
// List<string> strings1 = new List<string>(strings);
|
||||
// strings1.Remove(fBILLNO?.ToString());
|
||||
// string strings2 = string.Join(",", strings1);
|
||||
// item.FSKBIllNO = strings2;
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// int n = 1;
|
||||
// //判断多个销售订单对应1个收款单(只删除一个或多个但不是空的情况)
|
||||
// if (!string.IsNullOrWhiteSpace(fCONTRACTNUMBER?.ToString()))
|
||||
// {
|
||||
// double sumAmount = 0;
|
||||
// string[] strings = fCONTRACTNUMBER?.ToString()?.Split(',');
|
||||
// var FROWID = Convert.ToString(this.View.Model.GetValue("FROWID", e.Row));
|
||||
// var Rowindex = this.View.Model.GetEntryRowCount("FEntity2");
|
||||
// foreach (var item in SaleBILLLIS)
|
||||
// {
|
||||
// if (!string.IsNullOrEmpty(item.FSKBIllNO) && item.FSKBIllNO == fBILLNO?.ToString())
|
||||
// {
|
||||
// if (!strings.Contains(item.FCONTRACTNUMBER))
|
||||
// {
|
||||
// item.FSKBIllNO = "";
|
||||
// item.FISHX = "";
|
||||
// item.FWeiYi = "";
|
||||
// }
|
||||
// }
|
||||
// if (strings.Contains(item.FCONTRACTNUMBER))
|
||||
// {
|
||||
// item.FSKBIllNO = fBILLNO?.ToString();
|
||||
// item.FISHX = "已核销配对";
|
||||
// this.Model.SetValue("FISHX2", "已核销配对", e.Row);
|
||||
|
||||
foreach (var item in SaleBILLLIS)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(item.FSKBIllNO))
|
||||
{
|
||||
string[] strings = item.FSKBIllNO?.ToString()?.Split(',');
|
||||
//判断假如是一个收款单对应多个销售订单
|
||||
if (strings.Contains(fBILLNO?.ToString()) && strings.Count() == 1)
|
||||
{
|
||||
item.FSKBIllNO = "";
|
||||
item.FISHX = "";
|
||||
item.FWeiYi = "";
|
||||
}
|
||||
//判断多个收款单对应一个销售订单
|
||||
else if (strings.Contains(fBILLNO?.ToString()) && strings.Count() > 1)
|
||||
{
|
||||
List<string> strings1 = new List<string>(strings);
|
||||
strings1.Remove(fBILLNO?.ToString());
|
||||
string strings2 = string.Join(",", strings1);
|
||||
item.FSKBIllNO = strings2;
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
int n = 1;
|
||||
//判断多个销售订单对应1个收款单(只删除一个或多个但不是空的情况)
|
||||
if (!string.IsNullOrWhiteSpace(fCONTRACTNUMBER?.ToString()))
|
||||
{
|
||||
double sumAmount = 0;
|
||||
string[] strings = fCONTRACTNUMBER?.ToString()?.Split(',');
|
||||
var FROWID = Convert.ToString(this.View.Model.GetValue("FROWID", e.Row));
|
||||
var Rowindex = this.View.Model.GetEntryRowCount("FEntity2");
|
||||
foreach (var item in SaleBILLLIS)
|
||||
{
|
||||
if (!string.IsNullOrEmpty(item.FSKBIllNO) && item.FSKBIllNO == fBILLNO?.ToString())
|
||||
{
|
||||
if (!strings.Contains(item.FCONTRACTNUMBER))
|
||||
{
|
||||
item.FSKBIllNO = "";
|
||||
item.FISHX = "";
|
||||
item.FWeiYi = "";
|
||||
}
|
||||
}
|
||||
if (strings.Contains(item.FCONTRACTNUMBER))
|
||||
{
|
||||
item.FSKBIllNO = fBILLNO?.ToString();
|
||||
item.FISHX = "已核销配对";
|
||||
this.Model.SetValue("FISHX2", "已核销配对", e.Row);
|
||||
// //this.View.Model.SetValue("FPARENTROWID", FROWID, item.FRow);
|
||||
// //this.View.Model.CreateNewEntryRow("FEntity2");
|
||||
// //this.View.Model.SetValue("FROWID", SequentialGuid.NewGuid().ToString(), Rowindex);
|
||||
// //this.View.Model.SetValue("FPARENTROWID", FROWID, Rowindex);
|
||||
// //this.View.Model.SetValue("FBILLNO2", item.FBIllNO, Rowindex);
|
||||
// //if (DateTime.TryParseExact(item?.FDate, dateFormat, CultureInfo.InvariantCulture, DateTimeStyles.None, out DateTime parsedDate))
|
||||
// //{
|
||||
// // this.View.Model.SetValue("FDate2", item?.FDate, Rowindex);
|
||||
// //}
|
||||
// //else
|
||||
// //{
|
||||
// // this.View.Model.SetValue("FDate2", DateTime.Now.AddDays(-1 * Convert.ToInt32(item?.FDate)).ToString("yyyy-MM-dd"), Rowindex);
|
||||
// //}
|
||||
// //this.View.Model.SetValue("F_MBBA_Decimal_imu", item.FALLAMOUNT, Rowindex);
|
||||
// //this.View.Model.SetValue("FClient2", item.FClient, Rowindex);
|
||||
// //this.View.Model.SetValue("FCreated2", item.FCreated, Rowindex);
|
||||
// //this.View.Model.SetValue("FCONTRACTNUMBER2", item.FCONTRACTNUMBER, Rowindex);
|
||||
// //this.View.Model.SetValue("FSalesman2", item.FSalesman, Rowindex);
|
||||
// //this.View.UpdateView("FEntity2");
|
||||
|
||||
//this.View.Model.SetValue("FPARENTROWID", FROWID, item.FRow);
|
||||
//this.View.Model.CreateNewEntryRow("FEntity2");
|
||||
//this.View.Model.SetValue("FROWID", SequentialGuid.NewGuid().ToString(), Rowindex);
|
||||
//this.View.Model.SetValue("FPARENTROWID", FROWID, Rowindex);
|
||||
//this.View.Model.SetValue("FBILLNO2", item.FBIllNO, Rowindex);
|
||||
//if (DateTime.TryParseExact(item?.FDate, dateFormat, CultureInfo.InvariantCulture, DateTimeStyles.None, out DateTime parsedDate))
|
||||
//{
|
||||
// this.View.Model.SetValue("FDate2", item?.FDate, Rowindex);
|
||||
//}
|
||||
//else
|
||||
//{
|
||||
// this.View.Model.SetValue("FDate2", DateTime.Now.AddDays(-1 * Convert.ToInt32(item?.FDate)).ToString("yyyy-MM-dd"), Rowindex);
|
||||
//}
|
||||
//this.View.Model.SetValue("F_MBBA_Decimal_imu", item.FALLAMOUNT, Rowindex);
|
||||
//this.View.Model.SetValue("FClient2", item.FClient, Rowindex);
|
||||
//this.View.Model.SetValue("FCreated2", item.FCreated, Rowindex);
|
||||
//this.View.Model.SetValue("FCONTRACTNUMBER2", item.FCONTRACTNUMBER, Rowindex);
|
||||
//this.View.Model.SetValue("FSalesman2", item.FSalesman, Rowindex);
|
||||
//this.View.UpdateView("FEntity2");
|
||||
// sumAmount += item.FALLAMOUNT;
|
||||
// }
|
||||
// }
|
||||
// this.Model.SetValue("F_MBBA_Decimal_qtr", sumAmount, e.Row);
|
||||
// n = SaleBILLLIS.Count(a => strings.Contains(a.FCONTRACTNUMBER));
|
||||
// }
|
||||
|
||||
sumAmount += item.FALLAMOUNT;
|
||||
}
|
||||
}
|
||||
this.Model.SetValue("F_MBBA_Decimal_qtr", sumAmount, e.Row);
|
||||
n = SaleBILLLIS.Count(a => strings.Contains(a.FCONTRACTNUMBER));
|
||||
}
|
||||
|
||||
if (n == 0)
|
||||
{
|
||||
this.Model.SetValue("FISHX2", "", e.Row);
|
||||
}
|
||||
//删除数据
|
||||
this.View.Model.DeleteEntryData("FEntity");
|
||||
//绑定销售订单数据
|
||||
for (int i = 0; i < SaleBILLLIS.Count; i++)
|
||||
{
|
||||
int rowindex = this.View.Model.GetEntryRowCount("FEntity");
|
||||
this.View.Model.CreateNewEntryRow("FEntity");
|
||||
//单据编号
|
||||
this.View.Model.SetValue("FBILLNO", SaleBILLLIS[i].FBIllNO, i);
|
||||
//日期
|
||||
this.View.Model.SetValue("FDate", SaleBILLLIS[i].FDate, i);
|
||||
//金额
|
||||
this.View.Model.SetValue("F_MBBA_Decimal_c1c", SaleBILLLIS[i].FALLAMOUNT, i);
|
||||
//类型
|
||||
this.View.Model.SetValue("FType", SaleBILLLIS[i].FType, i);
|
||||
//纸质合同号
|
||||
this.View.Model.SetValue("FCONTRACTNUMBER", SaleBILLLIS[i].FCONTRACTNUMBER, i);
|
||||
//客户名称
|
||||
this.View.Model.SetValue("FClient", SaleBILLLIS[i].FClient, i);
|
||||
//已核销金额
|
||||
this.View.Model.SetValue("F_MBBA_Decimal_vb1", SaleBILLLIS[i].FYAMOUNT, i);
|
||||
//待核销金额
|
||||
this.View.Model.SetValue("F_MBBA_Decimal_emq", SaleBILLLIS[i].FDAMOUNT, i);
|
||||
//单据编号(收款单)
|
||||
this.View.Model.SetValue("FSKBILLNO", SaleBILLLIS[i].FSKBIllNO, i);
|
||||
//是否核销匹对
|
||||
this.View.Model.SetValue("FISHX", SaleBILLLIS[i].FISHX, i);
|
||||
//是否唯一
|
||||
this.View.Model.SetValue("FWeiYi", SaleBILLLIS[i]?.FWeiYi, i);
|
||||
//商务人员
|
||||
this.View.Model.SetValue("FCreated", SaleBILLLIS[i]?.FCreated, i);
|
||||
//销售员
|
||||
this.View.Model.SetValue("FSalesman", SaleBILLLIS[i]?.FSalesman, i);
|
||||
}
|
||||
this.View.UpdateView("FEntity");
|
||||
}
|
||||
}
|
||||
if (e.Field.Key.Equals("F_ISHX"))
|
||||
{
|
||||
//获取当前复选框的值
|
||||
var IsHX = this.Model.GetValue("F_ISHX", e.Row)?.ToString();
|
||||
var ISWeiYi = this.Model.GetValue("FWeiYi2", e.Row)?.ToString();
|
||||
//查询对应的销售订单/应收单-》勾选复选框
|
||||
var fc = this.Model.GetValue("FCONTRACTNUMBER2", e.Row)?.ToString();
|
||||
if (IsHX == "True")
|
||||
{
|
||||
//查看是否为唯一
|
||||
if (!string.IsNullOrEmpty(ISWeiYi) && ISWeiYi == "否")
|
||||
{
|
||||
//获取销售订单/应收单单据体数据
|
||||
DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
for (int i = 0; i < FEntity.Count; i++)
|
||||
{
|
||||
if (FEntity[i]["FCONTRACTNUMBER"]?.ToString() == fc)
|
||||
{
|
||||
this.Model.SetValue("F_ISGX", "True", i);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
if (IsHX == "False")
|
||||
{
|
||||
//获取销售订单/应收单单据体数据
|
||||
DynamicObjectCollection FEntity2 = this.View.Model.DataObject["FEntity2"] as DynamicObjectCollection;
|
||||
int n = 0;
|
||||
//判断其他收款单是否勾选
|
||||
foreach (var item in FEntity2)
|
||||
{
|
||||
if (item["F_ISHX"]?.ToString() == "True" && item["FCONTRACTNUMBER2"]?.ToString() == fc)
|
||||
{
|
||||
n++;
|
||||
}
|
||||
}
|
||||
|
||||
if (n == 0)
|
||||
{
|
||||
//查看是否为唯一
|
||||
if (!string.IsNullOrEmpty(ISWeiYi) && ISWeiYi == "否")
|
||||
{
|
||||
//获取销售订单/应收单单据体数据
|
||||
DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
for (int i = 0; i < FEntity.Count; i++)
|
||||
{
|
||||
if (FEntity[i]["FCONTRACTNUMBER"]?.ToString() == fc)
|
||||
{
|
||||
this.Model.SetValue("F_ISGX", "False", i);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
// if (n == 0)
|
||||
// {
|
||||
// this.Model.SetValue("FISHX2", "", e.Row);
|
||||
// }
|
||||
// //删除数据
|
||||
// this.View.Model.DeleteEntryData("FEntity");
|
||||
// //绑定销售订单数据
|
||||
// for (int i = 0; i < SaleBILLLIS.Count; i++)
|
||||
// {
|
||||
// int rowindex = this.View.Model.GetEntryRowCount("FEntity");
|
||||
// this.View.Model.CreateNewEntryRow("FEntity");
|
||||
// //单据编号
|
||||
// this.View.Model.SetValue("FBILLNO", SaleBILLLIS[i].FBIllNO, i);
|
||||
// //日期
|
||||
// this.View.Model.SetValue("FDate", SaleBILLLIS[i].FDate, i);
|
||||
// //金额
|
||||
// this.View.Model.SetValue("F_MBBA_Decimal_c1c", SaleBILLLIS[i].FALLAMOUNT, i);
|
||||
// //类型
|
||||
// this.View.Model.SetValue("FType", SaleBILLLIS[i].FType, i);
|
||||
// //纸质合同号
|
||||
// this.View.Model.SetValue("FCONTRACTNUMBER", SaleBILLLIS[i].FCONTRACTNUMBER, i);
|
||||
// //客户名称
|
||||
// this.View.Model.SetValue("FClient", SaleBILLLIS[i].FClient, i);
|
||||
// //已核销金额
|
||||
// this.View.Model.SetValue("F_MBBA_Decimal_vb1", SaleBILLLIS[i].FYAMOUNT, i);
|
||||
// //待核销金额
|
||||
// this.View.Model.SetValue("F_MBBA_Decimal_emq", SaleBILLLIS[i].FDAMOUNT, i);
|
||||
// //单据编号(收款单)
|
||||
// this.View.Model.SetValue("FSKBILLNO", SaleBILLLIS[i].FSKBIllNO, i);
|
||||
// //是否核销匹对
|
||||
// this.View.Model.SetValue("FISHX", SaleBILLLIS[i].FISHX, i);
|
||||
// //是否唯一
|
||||
// this.View.Model.SetValue("FWeiYi", SaleBILLLIS[i]?.FWeiYi, i);
|
||||
// //商务人员
|
||||
// this.View.Model.SetValue("FCreated", SaleBILLLIS[i]?.FCreated, i);
|
||||
// //销售员
|
||||
// this.View.Model.SetValue("FSalesman", SaleBILLLIS[i]?.FSalesman, i);
|
||||
// }
|
||||
// this.View.UpdateView("FEntity");
|
||||
// }
|
||||
// }
|
||||
// if (e.Field.Key.Equals("F_ISHX"))
|
||||
// {
|
||||
// //获取当前复选框的值
|
||||
// var IsHX = this.Model.GetValue("F_ISHX", e.Row)?.ToString();
|
||||
// var ISWeiYi = this.Model.GetValue("FWeiYi2", e.Row)?.ToString();
|
||||
// //查询对应的销售订单/应收单-》勾选复选框
|
||||
// var fc = this.Model.GetValue("FCONTRACTNUMBER2", e.Row)?.ToString();
|
||||
// if (IsHX == "True")
|
||||
// {
|
||||
// //查看是否为唯一
|
||||
// if (!string.IsNullOrEmpty(ISWeiYi) && ISWeiYi == "否")
|
||||
// {
|
||||
// //获取销售订单/应收单单据体数据
|
||||
// DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
// for (int i = 0; i < FEntity.Count; i++)
|
||||
// {
|
||||
// if (FEntity[i]["FCONTRACTNUMBER"]?.ToString() == fc)
|
||||
// {
|
||||
// this.Model.SetValue("F_ISGX", "True", i);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// if (IsHX == "False")
|
||||
// {
|
||||
// //获取销售订单/应收单单据体数据
|
||||
// DynamicObjectCollection FEntity2 = this.View.Model.DataObject["FEntity2"] as DynamicObjectCollection;
|
||||
// int n = 0;
|
||||
// //判断其他收款单是否勾选
|
||||
// foreach (var item in FEntity2)
|
||||
// {
|
||||
// if (item["F_ISHX"]?.ToString() == "True" && item["FCONTRACTNUMBER2"]?.ToString() == fc)
|
||||
// {
|
||||
// n++;
|
||||
// }
|
||||
// }
|
||||
|
||||
// if (n == 0)
|
||||
// {
|
||||
// //查看是否为唯一
|
||||
// if (!string.IsNullOrEmpty(ISWeiYi) && ISWeiYi == "否")
|
||||
// {
|
||||
// //获取销售订单/应收单单据体数据
|
||||
// DynamicObjectCollection FEntity = this.View.Model.DataObject["FEntity"] as DynamicObjectCollection;
|
||||
// for (int i = 0; i < FEntity.Count; i++)
|
||||
// {
|
||||
// if (FEntity[i]["FCONTRACTNUMBER"]?.ToString() == fc)
|
||||
// {
|
||||
// this.Model.SetValue("F_ISGX", "False", i);
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
// }
|
||||
//}
|
||||
#endregion
|
||||
public enum ENUM_ROWTYPE : int
|
||||
{
|
||||
Default = 0,
|
||||
|
||||
Reference in New Issue
Block a user