namespace YLErp.Modules.SuperviseReportModule.CFMMC.Model { public class SuperviseReportMonthlyTradeModel { /// /// 风险管理公司名称 /// public string CompanyName { get; set; } /// /// 统一社会信用代码 /// public string SuperviseMainCode { get; set; } /// /// 报告期 /// public string DataDate { get; set; } /// /// 填报日期 /// public string ReportDate { get; set; } /// /// 填表人 /// public string ReportUser { get; set; } /// /// 联系电话 /// public string Tel { get; set; } /// /// 场外商品衍生品月度交易规模统计表 /// public MonthlyTransactionSizeInfoGroup MonthlyTransactionSizeInfo { get; set; } ///// ///// 场外衍生品客户情况统计表 ///// //public TransactionScaleClientInfoType TransactionScaleClientInfo { get; set; } ///// ///// 场外商品衍生品客户交易情况统计表 ///// //public TransactionScaleClientTradeInfoGroup TransactionScaleClientTradeInfo { get; set; } ///// ///// 场外商品衍生品存量交易客户情况统计表 ///// //public TransactionScaleStockClientInfoGroup TransactionScaleStockClientInfo { get; set; } ///// ///// 场外商品衍生品履约担保情况统计表 ///// //public TransactionScaleMarginInfoModel TransactionScaleMarginInfo { get; set; } /// /// 场外商品衍生品交易月度盈亏情况统计表 /// public TransactionScalePnlInfoGroup TransactionScalePnlInfo { get; set; } } /// /// 场外商品衍生品月度交易规模统计表 /// public class MonthlyTransactionSizeInfoGroup { /// /// 名义本金 /// (单位:元) /// public TransactionScaleSizeType Notional { get; set; } = new TransactionScaleSizeType(); /// /// 交易确认书 /// (单位:笔) /// public TransactionScaleSizeType ConfirmBook { get; set; } = new TransactionScaleSizeType(); /// /// 权利金收取 /// (单位:元) /// public TransactionScaleSizeInfo2 TradePriceEarning { get; set; } = new TransactionScaleSizeInfo2(); /// /// 权利金支付 /// (单位:元) /// public TransactionScaleSizeInfo2 TradePricePay { get; set; } = new TransactionScaleSizeInfo2(); } public class TransactionScaleClientTradeInfoGroup { /// /// 是否计算合计,设置为true会计算合计,完成后该字段会变为false; /// public bool sum; /// /// 互换 /// public TransactionScaleInfoModel Swap { get; set; } = new TransactionScaleInfoModel(); /// /// 期权 /// public TransactionScaleInfoModel Option { get; set; } = new TransactionScaleInfoModel(); /// /// 远期 /// public TransactionScaleInfoModel Forward { get; set; } = new TransactionScaleInfoModel(); private TransactionScaleInfoModel _total; /// /// 合计 /// public TransactionScaleInfoModel Total { get { if (sum) { _total = new TransactionScaleInfoModel(); var stockMonthly = (Swap?.MonthlyTotal?.Stock + Option?.MonthlyTotal?.Stock + Forward?.MonthlyTotal?.Stock) ?? 0; var indexMonthly = (Swap?.MonthlyTotal?.Index + Option?.MonthlyTotal?.Index + Forward?.MonthlyTotal?.Index) ?? 0; var fundMonthly = (Swap?.MonthlyTotal?.Fund + Option?.MonthlyTotal?.Fund + Forward?.MonthlyTotal?.Fund) ?? 0; var otherMonthly = (Swap?.MonthlyTotal?.Other + Option?.MonthlyTotal?.Other + Forward?.MonthlyTotal?.Other) ?? 0; var commodityMonthly = (Swap?.MonthlyTotal?.Commodity + Option?.MonthlyTotal?.Commodity + Forward?.MonthlyTotal?.Commodity) ?? 0; _total.MonthlyTotal = new TransactionScaleItem(stockMonthly, indexMonthly, fundMonthly, otherMonthly, commodityMonthly); var stockYear = (Swap?.YearTotal?.Stock + Option?.YearTotal?.Stock + Forward?.YearTotal?.Stock) ?? 0; var indexYear = (Swap?.YearTotal?.Index + Option?.YearTotal?.Index + Forward?.YearTotal?.Index) ?? 0; var fundYear = (Swap?.YearTotal?.Fund + Option?.YearTotal?.Fund + Forward?.YearTotal?.Fund) ?? 0; var otherYear = (Swap?.YearTotal?.Other + Option?.YearTotal?.Other + Forward?.YearTotal?.Other) ?? 0; var commodityYear = (Swap?.YearTotal?.Commodity + Option?.YearTotal?.Commodity + Forward?.YearTotal?.Commodity) ?? 0; _total.YearTotal = new TransactionScaleItem(stockYear, indexYear, fundYear, otherYear, commodityYear); sum = false; } return _total; } } } public class TransactionScaleStockClientInfoGroup { /// /// 是否计算合计,设置为true会计算合计,完成后该字段会变为false; /// public bool sum; /// /// 互换 /// public TransactionScaleClientInfoType Swap { get; set; } = new TransactionScaleClientInfoType(); /// /// 期权 /// public TransactionScaleClientInfoType Option { get; set; } = new TransactionScaleClientInfoType(); /// /// 远期 /// public TransactionScaleClientInfoType Forward { get; set; } = new TransactionScaleClientInfoType(); private TransactionScaleItem _total; /// /// 合计 /// public TransactionScaleItem Total { get { if (sum) { var stockMonthly = (Swap?.Monthly?.Stock + Option?.Monthly?.Stock + Forward?.Monthly?.Stock) ?? 0; var indexMonthly = (Swap?.Monthly?.Index + Option?.Monthly?.Index + Forward?.Monthly?.Index) ?? 0; var fundMonthly = (Swap?.Monthly?.Fund + Option?.Monthly?.Fund + Forward?.Monthly?.Fund) ?? 0; var otherMonthly = (Swap?.Monthly?.Other + Option?.Monthly?.Other + Forward?.Monthly?.Other) ?? 0; var commodityMonthly = (Swap?.Monthly?.Commodity + Option?.Monthly?.Commodity + Forward?.Monthly?.Commodity) ?? 0; _total = new TransactionScaleItem(stockMonthly, indexMonthly, fundMonthly, otherMonthly, commodityMonthly); sum = false; } return _total; } } } public class TransactionScalePnlInfoGroup { /// /// 本月发生额(元) /// public TransactionScalePnlType Monthly { get; set; } = new TransactionScalePnlType(); /// /// 本年累计额(元) /// public TransactionScalePnlType Year { get; set; } = new TransactionScalePnlType(); } public class TransactionScalePnlType { /// /// 场内 /// public TransactionScalePnlItem Hedge { get; set; } = new TransactionScalePnlItem(); /// /// 期权 /// public TransactionScalePnlItem Option { get; set; } = new TransactionScalePnlItem(); /// /// 所有的 /// public TransactionScalePnlItem All { get; set; } = new TransactionScalePnlItem(); } public class TransactionScalePnlItem { private double _realizedPnl; /// /// 已实现损益 /// public double RealizedPnl { get { return _realizedPnl; } set { _realizedPnl = value.Normalize(); } } private double _pnl; /// /// 公允价值变动损益 /// public double Pnl { get { return _pnl; } set { _pnl = value.Normalize(); } } /// /// 损益合计 /// public double Sum { get { return RealizedPnl + Pnl; } } } public class TransactionScaleMarginInfoModel { /// /// 存量名义本金总额 /// (单位:元) /// public TransactionScaleMarginItem StockNotionalTotal { get; set; } = new TransactionScaleMarginItem(); /// /// 存量交易对应履约保障品价值 /// (单位:元) /// public TransactionScaleMarginItem StockClientCashTotle { get; set; } = new TransactionScaleMarginItem(); /// /// 存量交易对应履约保障品价值-现金 /// (单位:元) /// public TransactionScaleMarginItem StockClientCash { get; set; } = new TransactionScaleMarginItem(); /// /// 存量交易对应履约保障品价值-抵押品 /// (单位:元) /// public TransactionScaleMarginItem StockClientProduct { get; set; } = new TransactionScaleMarginItem(); /// /// 业务整体履约保障比例(全额) /// public TransactionScaleMarginItem StockMarginPercentFull { get; set; } = new TransactionScaleMarginItem(); /// /// 业务整体履约保障比例(净额) /// public TransactionScaleMarginItem StockMarginPercentNet { get; set; } = new TransactionScaleMarginItem(); /// /// 本月违约客户数(单位:户) /// public TransactionScaleMarginItem StockBadClientMonthly { get; set; } = new TransactionScaleMarginItem(); /// /// 本月违约交易数(单位:笔) /// public TransactionScaleMarginItem StockBadTradeMonthly { get; set; } = new TransactionScaleMarginItem(); /// /// 本年累计为约客户数(单位:户) /// public TransactionScaleMarginItem StockBadClientYear { get; set; } = new TransactionScaleMarginItem(); /// /// 本年累计违约交易数(单位:笔) /// public TransactionScaleMarginItem StockBadTradeYear { get; set; } = new TransactionScaleMarginItem(); } public class TransactionScaleMarginItem { private double _monthly; /// /// 本月末 /// public double Monthly { get { return _monthly; } set { _monthly = value.Normalize(); } } private double _preMonthly; /// /// 上月末 /// public double PreMonthly { get { return _preMonthly; } set { _preMonthly = value.Normalize(); } } } /// /// 场外衍生品客户情况统计表 /// public class TransactionScaleClientInfoType { /// /// 本月末 /// public TransactionScaleItem Monthly { get; set; } = new TransactionScaleItem(); /// /// 上月末 /// public TransactionScaleItem PreMonthly { get; set; } = new TransactionScaleItem(); } public class TransactionScaleInfoModel { /// /// 本月累计 /// public TransactionScaleItem MonthlyTotal { get; set; } = new TransactionScaleItem(); /// /// 本年累计 /// public TransactionScaleItem YearTotal { get; set; } = new TransactionScaleItem(); } public class TransactionScaleSizeType { /// /// 互换类 /// public TransactionScaleSizeInfo1 Swap { get; set; } = new TransactionScaleSizeInfo1(); /// /// 期权类 /// public TransactionScaleSizeInfo1 Option { get; set; } = new TransactionScaleSizeInfo1(); /// /// 远期类 /// public TransactionScaleSizeInfo1 Forward { get; set; } = new TransactionScaleSizeInfo1(); } public class TransactionScaleSizeInfo1 { /// /// 上月末存量 /// public TransactionScaleItem PreMonthlyCount { get; set; } = new TransactionScaleItem(); /// /// 本月新增开仓 /// public TransactionScaleItem MonthlyOpen { get; set; } = new TransactionScaleItem(); /// /// 中小微企业本月新增开仓 /// public TransactionScaleItem MonthlyOpenSmallAndMicro { get; set; } = new TransactionScaleItem(); /// /// 上市公司本月新增开仓 /// public TransactionScaleItem MonthlyOpenListed { get; set; } = new TransactionScaleItem(); /// /// 本月平仓 /// public TransactionScaleItem MonthlyUnwind { get; set; } = new TransactionScaleItem(); /// /// 本月执行/终止交易 /// public TransactionScaleItem MonthlyExecute { get; set; } = new TransactionScaleItem(); /// /// 本月末存量 /// public TransactionScaleItem MonthlyCount { get; set; } = new TransactionScaleItem(); /// /// 本月末存量 /// public TransactionScaleItem MonthlyCountSmallAndMicro { get; set; } = new TransactionScaleItem(); /// /// 本月末存量 /// public TransactionScaleItem MonthlyCountListed { get; set; } = new TransactionScaleItem(); /// /// 本年累计新增(请公司注意填写) /// 本年累计:"各交易类型年度累计新增成交量,成交名义本金及权利金收取和支付" /// public TransactionScaleItem YearCount { get; set; } = new TransactionScaleItem(); } public class TransactionScaleSizeInfo2 { /// /// 本月新增开仓 /// public TransactionScaleItem MonthlyOpen { get; set; } = new TransactionScaleItem(); /// /// 本月平仓 /// public TransactionScaleItem MonthlyUnwind { get; set; } = new TransactionScaleItem(); /// /// 本年累计新增(请公司注意填写) /// 本年累计:"各交易类型年度累计新增成交量,成交名义本金及权利金收取和支付" /// public TransactionScaleItem YearCount { get; set; } = new TransactionScaleItem(); } public class TransactionScaleItem { private double _stock; /// /// 个股 /// public double Stock { get { return _stock; } set { _stock = value.Normalize(); } } private double _index; /// /// 指数 /// public double Index { get { return _index; } set { _index = value.Normalize(); } } private double _fund; /// /// 基金 /// public double Fund { get { return _fund; } set { _fund = value.Normalize(); } } private double _other; /// /// 其他 /// public double Other { get { return _other; } set { _other = value.Normalize(); } } //private double _industrialClient; ///// ///// 产业客户 ///// //public double IndustrialClient { get { return _industrialClient; } set { _industrialClient = value.Normalize(); } } //private double _otherClient; ///// ///// 其他机构 ///// //public double OtherClient { get { return _otherClient; } set { _otherClient = value.Normalize(); } } /// /// 合计 /// public double Sum { get { return Stock + Index + Fund + Other; } } private double _commodity; /// /// 商品 /// public double Commodity { get { return _commodity; } set { _commodity = value.Normalize(); } } public TransactionScaleItem() { } public TransactionScaleItem(double stock, double index, double fund, double other, double commodity) { this.Stock = stock; this.Index = index; this.Fund = fund; this.Other = other; this.Commodity = commodity; } } }