找回证券业报送的逻辑,仅支持Excel模板报送
This commit is contained in:
@@ -1,4 +1,9 @@
|
||||
using System.ComponentModel;
|
||||
using System;
|
||||
using System.Collections.Generic;
|
||||
using System.ComponentModel;
|
||||
using System.Linq;
|
||||
using System.Text;
|
||||
using System.Threading.Tasks;
|
||||
using System.Xml;
|
||||
using System.Xml.Serialization;
|
||||
using YLErp.Helpers;
|
||||
@@ -58,30 +63,40 @@ namespace YLErp.Modules.SuperviseReportModule.SAC.Model
|
||||
private string check(string xml)
|
||||
{
|
||||
var result = xml;
|
||||
if (Header.BusiDataType == DataFlagsEnum.A1016)
|
||||
switch (this.Header.BusiDataType)
|
||||
{
|
||||
try
|
||||
{
|
||||
var doc = new System.Xml.XmlDocument();
|
||||
doc.LoadXml(xml);
|
||||
var body = doc.GetElementsByTagName("SwapEquityPayment");
|
||||
if (body.Count > 0)
|
||||
case DataFlagsEnum.A1016:
|
||||
try
|
||||
{
|
||||
foreach (XmlElement item in body)
|
||||
var doc = new System.Xml.XmlDocument();
|
||||
doc.LoadXml(xml);
|
||||
var body = doc.GetElementsByTagName("SwapEquityPayment");
|
||||
if (body.Count > 0)
|
||||
{
|
||||
var taget = item.GetElementsByTagName("DurationEventNO");
|
||||
var frist = item.GetElementsByTagName("SwapEquityPaymentTuple");
|
||||
if (taget.Count > 0)
|
||||
foreach (XmlElement item in body)
|
||||
{
|
||||
item.InsertAfter(taget[0], frist[frist.Count - 1]);
|
||||
var target = item.GetElementsByTagName("DurationEventNO");
|
||||
var frist = item.GetElementsByTagName("SwapEquityPaymentTuple");
|
||||
if (target.Count > 0)
|
||||
{
|
||||
item.InsertAfter(target[0], frist[frist.Count - 1]);
|
||||
}
|
||||
}
|
||||
result = XmlHelper.FormatXml(doc.OuterXml);
|
||||
}
|
||||
result = XmlHelper.FormatXml(doc.OuterXml);
|
||||
}
|
||||
}
|
||||
catch
|
||||
{
|
||||
}
|
||||
#pragma warning disable CS0168 // 声明了变量“ex”,但从未使用过
|
||||
catch (Exception ex)
|
||||
#pragma warning restore CS0168 // 声明了变量“ex”,但从未使用过
|
||||
{
|
||||
}
|
||||
break;
|
||||
case DataFlagsEnum.A1004:
|
||||
if (result.Contains("<PerformanceCollTuple />"))
|
||||
{
|
||||
result = result.Replace("<PerformanceCollTuple />", "");
|
||||
}
|
||||
break;
|
||||
}
|
||||
return result;
|
||||
}
|
||||
@@ -161,7 +176,7 @@ namespace YLErp.Modules.SuperviseReportModule.SAC.Model
|
||||
/// <para>说明:<see cref="DataFlagsEnum"/></para>
|
||||
/// </summary>
|
||||
[CheckStringInMap(Map = new[] { "A1001", "A1002","A1003","A1004", "A1005", "A1006" ,"A1007",
|
||||
"A1008", "A1009","A1010", "A1011", "A1012","A1013","A1014","A1015","A1016","A1017" })]
|
||||
"A1008", "A1009","A1010", "A1011", "A1012","A1013","A1014","A1015","A1016","A1017","A1018","A1019" })]
|
||||
[SacDescription("BusiDataType", "接口标识", "5", true, "")]
|
||||
public DataFlagsEnum BusiDataType { get; set; }
|
||||
/// <summary>
|
||||
@@ -241,11 +256,11 @@ namespace YLErp.Modules.SuperviseReportModule.SAC.Model
|
||||
[SacDescription("SwapEquityPayment", "收益互换交易权益端支付", "", false, "")]
|
||||
public List<SwapEquityPaymentModel> SwapEquityPayment { get; set; }
|
||||
/// <summary>
|
||||
/// 互换交易确认书附件
|
||||
/// 交易确认书附件
|
||||
/// </summary>
|
||||
[XmlElement]
|
||||
[SacDescription("ConfirmationAtt", "互换交易确认书附件", "", false, "")]
|
||||
public List<SwapConfirmationAttModel> ConfirmationAtt { get; set; }
|
||||
[SacDescription("ConfirmationAtt", "交易确认书附件", "", false, "")]
|
||||
public List<ConfirmationAttModel> ConfirmationAtt { get; set; }
|
||||
/// <summary>
|
||||
/// 期权交易存续期管理
|
||||
/// </summary>
|
||||
@@ -259,6 +274,12 @@ namespace YLErp.Modules.SuperviseReportModule.SAC.Model
|
||||
[SacDescription("SwapDurationManagement", "收益互换交易存续期管理", "", false, "")]
|
||||
public List<SwapDurationManagementModel> SwapDurationManagement { get; set; }
|
||||
/// <summary>
|
||||
/// 场外期权合约估值信息
|
||||
/// </summary>
|
||||
[XmlElement]
|
||||
[SacDescription("ValuationInformation", "场外期权合约估值信息", "", false, "")]
|
||||
public List<ValuationInformationModel> ValuationInformation { get; set; }
|
||||
/// <summary>
|
||||
/// 定期报告-SAC模板
|
||||
/// </summary>
|
||||
[XmlElement]
|
||||
|
||||
Reference in New Issue
Block a user