public TransType BuildFromRow(DataRow row) { var returnRecord = TransType.BuildTransTypeFromRow(row); returnRecord = this.BuildExtraFromRow <TransType>(returnRecord, row); return(returnRecord); }
public Transaction(decimal amount, TransType type, DateTime date, string description) { _amount = amount; _type = type; _date = date; _description = description; }
//座標位置轉換 public bool PointConversion(Vector2 p, TransType t, out Vector2 output) { if (Between(p, anchor[0].position, anchor[1].position, chessRange)) { int xIndex; int yIndex; switch (t) { case TransType.任意座標轉棋盤格索引: xIndex = (int)((p.x - (anchor[1].position.x - (chessRange.x / 2))) / chessRange.x); yIndex = (int)((p.y - (anchor[1].position.y - (chessRange.y / 2))) / chessRange.y); output = new Vector2(xIndex, yIndex); return(true); case TransType.任意座標轉棋盤點座標: xIndex = (int)((p.x - (anchor[1].position.x - (chessRange.x / 2))) / chessRange.x); yIndex = (int)((p.y - (anchor[1].position.y - (chessRange.y / 2))) / chessRange.y); float xPos = anchor[1].position.x + (xIndex * chessRange.x); float yPos = anchor[1].position.y + (yIndex * chessRange.y); output = new Vector2(xPos, yPos); return(true); default: output = new Vector2(); return(false); } } else { output = new Vector2(); return(false); } }
public void InitStatic(BgStaticInfo bgInfo) { if (bgInfo == null) { return; } layerno = bgInfo.layerno; var imageRes = StageMgr.GetInstance().ImageRes; if (imageRes != null && imageRes.LoadOk) { m_Group = bgInfo.srpiteno_Group; m_Image = bgInfo.spriteno_Image; m_MaskType = bgInfo.mask; m_SceneType = SceneLayerType.Static; m_TransType = bgInfo.transType; InitSpriteRender(bgInfo.transType); var frame = imageRes.GetImageFrame((PlayerState)bgInfo.srpiteno_Group, bgInfo.spriteno_Image); UpdateImageFrame(frame, ActionFlip.afNone, ActionDrawMode.adNone, bgInfo.mask == MaskType.none); m_IsInited = true; } }
public void InitAnimated(BgAniInfo anInfo) { if (anInfo == null) { return; } layerno = anInfo.layerno; var imageRes = StageMgr.GetInstance().ImageRes; if (imageRes != null && imageRes.LoadOk) { // 处理动画层 m_Group = anInfo.actionno; m_MaskType = anInfo.mask; m_SceneType = SceneLayerType.Animation; m_TransType = anInfo.transType; InitSpriteRender(anInfo.transType); m_IsInited = true; if (StageMgr.GetInstance().HasBeginAction(m_Group)) { // 初始化动画 var ani = this.ImageAni; if (ani != null) { ani.Type = ImageAnimation.ImageAnimationType.Scene; if (ani.PlayerPlayerAni((PlayerState)m_Group, true)) { RefreshCurFrame(ani); } } } } }
private void InitSpriteRender(TransType transType) { var sp = this.SpriteRender; if (sp != null) { if (m_OrgSpMat == null || m_CurTransType != transType) { m_CurTransType = transType; if (transType == TransType.Add) { LoadMaterial(ref m_OrgSpMat, AppConfig.GetInstance().PalleetAddMatFileName); } else { LoadMaterial(ref m_OrgSpMat, AppConfig.GetInstance().PalleetMatFileName); } if (m_OrgSpMat != null) { Material mat = GameObject.Instantiate(m_OrgSpMat); AddOrSetInstanceMaterialMap(sp.GetInstanceID(), mat); sp.sharedMaterial = mat; } } } }
public TransType GetTypeById(int id) { Mapper.Initialize(cfg => cfg.CreateMap <t_type, TransType>()); t_type daltype = _unitOfWork.TypeRepository.Get(id); TransType dto = Mapper.Map <TransType>(daltype); return(dto); }
public ChangeMarkPosOrAngleCommand(Mark mk, TransType transType, Vector2 position, float rotation) { this.mk = mk; this.transType = transType; this.position = position; this.rotation = rotation; lastPosition = mk.Position; lastRotation = mk.Rotation; }
public void AddTransaction(TransType deposit, double amount) { var trans = new Transaction() { TransactionType = TransType.Deposit, Amount = amount }; m_transactionList.Add(trans); }
public TransType Insert(TransType record) { DataRow row = this.dataSet.ttbltrans_type.Newttbltrans_typeRow(); this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.dataSet.ttbltrans_type.Addttbltrans_typeRow((pdstrans_typeDataSet.ttbltrans_typeRow)row); this.SaveChanges(); return(this.dataSet.ttbltrans_type.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttbltrans_type.Rows[0]) : null); }
private async Task Create() { await TransTypeRepo.CreateTransType(_transType); ToastService.ShowSuccess($"Action successful." + $"TransType \"{_transType.Trans_Type}\" successfully added."); _transType = new TransType(); _editContext.OnValidationStateChanged += ValidationChanged; _editContext.NotifyValidationStateChanged(); }
public static void DoTransitionOut(TransType type, Texture2D tex) { Transition t = Instance; t.texture = tex; t.type = type; t.fadeState = TransState.Out; t.timer = 0; t.PickTrans(); }
public TransType GetByRowId(string rowId, string fldList) { var row = this.GetRowByRowId(rowId, fldList); TransType transType = null; if (row != null) { transType = this.BuildFromRow(row); } return(transType); }
public static void DoTransition(TransType type, Texture2D tex, float showTime) { Transition t = Instance; t.texture = tex; t.type = type; t.fadeState = TransState.In; t.timer = 0; t.showDuration = showTime; t.PickTrans(); }
protected TransType Fetch(string where, int batchsize, string fldList) { this.FetchWhere(where, batchsize, fldList); var row = this.dataSet.ttbltrans_type.AsEnumerable().SingleOrDefault(); TransType transType = null; if (row != null) { transType = this.BuildFromRow(row); } return(transType); }
void IMT4ServerConnectorHost.OnTrade( eMT4ServerType serverIndex, TradeRecord ptrTrade, TransType transType) { try { _orderManager.Value.OnTradeAsync(serverIndex, ptrTrade, transType, CancellationToken.None).Wait(); } catch (Exception exception) { m_ptrLogger.LogException(exception); } }
public void Delete(TransType record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row == null) { row = this.dataSet.ttbltrans_type.Newttbltrans_typeRow(); TransType.BuildMinimalRow(ref row, record); this.dataSet.ttbltrans_type.Addttbltrans_typeRow((pdstrans_typeDataSet.ttbltrans_typeRow)row); } row.Delete(); this.SaveChanges(); }
public TransType Update(TransType record) { var row = this.GetRowByRowId(record.rowID, string.Empty); if (row != null) { this.UpdateToRow(ref row, record); this.ExtraUpdateToRow(ref row, record); this.SaveChanges(); return(this.dataSet.ttbltrans_type.Rows.Count > 0 ? this.BuildFromRow(this.dataSet.ttbltrans_type.Rows[0]) : null); } ErrorReportingHelper.ReportErrors("global.update.doesnotexist", 421); return(null); }
public static InventoryShipmentOrderTypeEnum ToOrderType(this TransType transType) { switch (transType) { case TransType.Move: return(InventoryShipmentOrderTypeEnum.InterWarehouseOrder); case TransType.ToTrmt: return(InventoryShipmentOrderTypeEnum.TreatmentOrder); case TransType.Sale: return(InventoryShipmentOrderTypeEnum.SalesOrder); case TransType.OnConsignment: return(InventoryShipmentOrderTypeEnum.ConsignmentOrder); case TransType.MiscInvoice: return(InventoryShipmentOrderTypeEnum.MiscellaneousOrder); default: throw new ArgumentOutOfRangeException("transType"); } }
/// <summary> /// 根据指定的转换类型转换字符串 /// </summary> /// <param name="type">转换类型</param> public static string TransText(TransType type, string source) { string dest = string.Empty; switch (type) { case TransType.ASCIIToUnicode: dest = string.Empty; for (int i = 0; i < source.Length; i++) { dest += "&#" + ((int)source[i]).ToString() + ";"; } break; case TransType.UnicodeToASCII: dest = string.Empty; MatchCollection mc = Regex.Matches(source, "\\w+"); foreach (Match m in mc) { dest += ((char)int.Parse(m.Value)).ToString(); } break; case TransType.UnicodeToCN: dest = string.Empty; string[] arr = source.Replace("\\", "").Split('u'); for (int i = 1; i < arr.Length; i++) { dest += (char)int.Parse(arr[i], NumberStyles.HexNumber); } break; case TransType.CNToUnicode: dest = string.Empty; for (int i = 0; i < source.Length; i++) { dest += "\\u" + ((int)source[i]).ToString("x"); } break; case TransType.Clear: break; } return(dest); }
public void WriteLog(TransType transType, int?storeId, int?productId, string message) { string extra = (message.IndexOf("error code: 1002") == -1 ? "" : " - hourly request limit exceeded"); var log = new Log { LogDateTime = DateTimeOffset.Now, TransType = (int)transType, StoreId = storeId, ProductId = productId, Message = message }; db.InsertOrUpdateLog(log); string msg = log.LogDateTime.ToString("dd/MM/yyyy HH:mm:ss") + " " + message + extra; Console.WriteLine(msg); using (StreamWriter sw = new StreamWriter(GetLogFile(DateTimeOffset.Now), true)) { sw.WriteLine(msg); } }
public void Sync(string strKey, TransType eTrnType, SAPbobsCOM.Company oCompany, string strLogger, string strWareHouse, string[] strValues, Hashtable htCCdet) { try { switch (eTrnType) { case TransType.A: ((IArmada_Sync)this).Add(strKey, oCompany, strLogger, strWareHouse, strValues, htCCdet); break; default: break; } } catch (Exception ex) { Singleton.objSqlDataAccess.UpdateLog(strKey, TransScenerio.ARInvoice.ToString(), "0", "0", 0, "0", ex.Message.ToString(), strLogger); } }
public void Sync(string strKey, TransType eTrnType, SAPbobsCOM.Company oCompany_S, SAPbobsCOM.Company oCompany_D, string strLogger, string strFromWare, string strToWare, string[] strValues) { try { switch (eTrnType) { case TransType.A: ((IArmada_Sync)this).Add(strKey, oCompany_S, oCompany_D, strLogger, strFromWare, strToWare, strValues); break; default: break; } } catch (Exception ex) { Singleton.objSqlDataAccess.UpdateLog(strKey, TransScenerio.InventoryTransfer.ToString(), "0", "0", 0, "0", ex.Message.ToString(), strLogger); //throw; } }
public static PickedReason ToPickedReason(this TransType transType) { switch (transType) { case TransType.MnW: return(PickedReason.Production); case TransType.Batching: return(PickedReason.Production); case TransType.Move: return(PickedReason.InterWarehouseMovement); case TransType.Sale: return(PickedReason.SalesOrder); case TransType.ToTrmt: return(PickedReason.TreatmentOrder); case TransType.Rincon: return(PickedReason.IntraWarehouseMovement); case TransType.OnConsignment: return(PickedReason.ConsignmentOrder); default: throw new ArgumentOutOfRangeException(string.Format("TransType[{0}] has no associated PickedReason defined.")); } }
private void dgTransTypes_RowEditEnding(object sender, DataGridRowEditEndingEventArgs e) { if (e.EditAction == DataGridEditAction.Commit) { TransTypesDBDataContext context = new TransTypesDBDataContext(); TransType tType = e.Row.DataContext as TransType; var matchedData = (from tt in context.GetTable <TransType>() where tt.TransTypeID == tType.TransTypeID select tt).SingleOrDefault(); if (matchedData == null) { TransType trans = new TransType(); trans.Description = tType.Description; context.TransTypes.InsertOnSubmit(trans); context.SubmitChanges(); } else { matchedData.Description = tType.Description; context.SubmitChanges(); } } //var _row = e.Row.Item as DataRow; //var _transTypeId = Convert.ToInt32(_row["TransTypeID"]); //var _description = _row["Description"].ToString(); //if (IsInserting) //{ // _transTypeId = -1; // Data.Instance.EditTransTypes(_transTypeId, _description); //} //else if (IsEditing) //{ // Data.Instance.EditTransTypes(_transTypeId, _description); //} //IsEditing = false; //IsInserting = false; LoadDataGrid(); }
private void BuildWhereClause(string strLine, TransType transtype) { List <Parameter> paralist = new List <Parameter>(); if (string.IsNullOrEmpty(strLine)) { return; } var strsource = strLine.Split(' '); string[] strDest = new string[100]; int k = 0; foreach (var s in strsource) { if (s == "order") { break; } if (s != " " && s != "'" && s != "" && s != "where" && s != "WHERE" && s != "and") { strDest[k++] = s; } } for (int ii = 0; ii <= strDest.Length - 1; ii = ii + 3) { if (strDest[ii] == null || strDest[ii + 2] == null) { break; } Parameter p = new Parameter(); p.Name = strDest[ii]; p.Value = strDest[ii + 2].Replace(@".", string.Empty); p.Datatype = DbDataTypes.VarChar; p.Direction = ParameterDirection.Input; paralist.Add(p); } transtype.ParameterList = paralist; }
/// <summary> /// 上传 MonitorLog 信息接口 /// </summary> public UploadContract UploadMonitorLog(TransType transType, MonitorLogContract order, string userId, string token, string unitId) { string bizId = Utils.NewGuid(); string methodKey = "ComService.UploadMonitorLog"; string ifCode = "C001"; var data = new UploadContract(); Hashtable htLogExt = new Hashtable(); htLogExt["customer_code"] = null; htLogExt["customer_id"] = null; htLogExt["unit_code"] = null; htLogExt["unit_id"] = unitId; htLogExt["user_code"] = null; htLogExt["user_id"] = userId; htLogExt["if_code"] = ifCode; htLogExt["app_code"] = AppType.Client; try { Hashtable htParams = new Hashtable(); htParams.Add("trans_type", transType); htParams.Add("order", order); htParams.Add("user_id", userId); htParams.Add("token", token); htParams.Add("unit_id", unitId); LogService.WriteTrace(bizId, methodKey, TraceLogType.Params.ToString(), htParams, userId, htLogExt); bool statusFlag = false; Hashtable htError = null; CertInfo certInfo = null; #region 检查参数 Hashtable htResult = new Hashtable(); bool paramCheckFlag = false; htResult = ErrorService.CheckLength("用户ID", userId, 1, 32, true, false, ref paramCheckFlag); if (!paramCheckFlag) { return(ErrorConvert.Export <UploadContract>(htResult)); } //htResult = ErrorService.CheckLength("令牌", token, 1, 32, true, false, ref paramCheckFlag); //if (!paramCheckFlag) return ErrorConvert.Export<UploadContract>(htResult); //htResult = ErrorService.CheckLength("门店ID", unitId, 1, 32, true, false, ref paramCheckFlag); //if (!paramCheckFlag) return ErrorConvert.Export<UploadContract>(htResult); #endregion #region 检查权限 Dex.Services.AuthService authService = new Dex.Services.AuthService(); // 检查User和Customer certInfo = authService.GetCertByUserId(userId); if (certInfo == null) { htError = ErrorService.OutputError(ErrorCode.A006, "用户ID不存在", true); data.status = Utils.GetStatus(false); data.error_code = htError["error_code"].ToString(); data.error_full_desc = htError["error_desc"].ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); return(data); } statusFlag = true; //// 检查Token是否不匹配或过期 //statusFlag = authService.CheckCertToken(token, certInfo.CertId, userId); //if (!statusFlag) //{ // htError = ErrorService.OutputError(ErrorCode.A005, "令牌不匹配或过期", true); // data.status = Utils.GetStatus(false); // data.error_code = htError["error_code"].ToString(); // data.error_full_desc = htError["error_desc"].ToString(); // LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); // return data; //} // 查询凭证 certInfo = authService.GetCertByUserId(userId); if (certInfo == null || certInfo.CustomerId == null || certInfo.CustomerId.Length == 0) { htError = ErrorService.OutputError(ErrorCode.A007, "获取后台数据(客户ID)失败", true); data.status = Utils.GetStatus(false); data.error_code = htError["error_code"].ToString(); data.error_full_desc = htError["error_desc"].ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); return(data); } string customerId = certInfo.CustomerId; htLogExt["customer_code"] = certInfo.CustomerCode; htLogExt["customer_id"] = certInfo.CustomerId; htLogExt["user_code"] = certInfo.UserCode; #endregion #region 检查单据参数 Dex.ServicesBs.ComService orderService = new Dex.ServicesBs.ComService(); if (order.user_id == null || order.user_id.Trim().Length == 0) { order.user_id = userId; } htError = orderService.CheckMonitorLog(order); if (!Convert.ToBoolean(htError["status"])) { data.status = Utils.GetStatus(false); data.error_code = htError["error_code"].ToString(); data.error_full_desc = htError["error_desc"].ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); return(data); } #endregion // 保存 ConfigService cfgService = new ConfigService(); bool enableConnectPosBS = cfgService.GetEnableConnectPosBSCfg(); if (enableConnectPosBS) { try { orderService.SaveMonitorLog(order, customerId, unitId, userId); } catch (Exception ex) { data.status = Utils.GetStatus(false); data.error_code = ErrorCode.A018.ToString(); data.error_full_desc = ex.ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); return(data); } } else { htError = ErrorService.OutputError(ErrorCode.A012, "连接业务平台数据通道已关闭", true); data.status = Utils.GetStatus(false); data.error_code = htError["error_code"].ToString(); data.error_full_desc = htError["error_desc"].ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); return(data); } data.status = Utils.GetStatus(statusFlag); LogService.WriteTrace(bizId, methodKey, TraceLogType.Return.ToString(), data.ToString(), userId, htLogExt); } catch (Exception ex) { data.status = Utils.GetStatus(false); data.error_code = ErrorCode.A000.ToString(); data.error_full_desc = ex.ToString(); LogService.WriteError(bizId, methodKey, data.error_code, data.ToString(), userId, htLogExt); } return(data); }
public void AddTransaction(TransType deposit, double amount) { var trans = new Transaction() {TransactionType = TransType.Deposit, Amount = amount}; m_transactionList.Add(trans); }
//HTTP methods for calling the API POST, PUT, GET etc public async Task CreateTransType(TransType transType) => await _client.PostAsJsonAsync("TransType", transType);
public IHttpActionResult AddTransaction(int bankAccountId, string ownerId, int budgetItemId, TransType transactionType, float amount, string memo) { return(Ok(db.AddTransaction(bankAccountId, ownerId, budgetItemId, transactionType, amount, memo))); }
// OLD signature notice the case, this did NOT work with the deserialise // public String batch_id, myinterface, voucher_type, trans_type, client, account, dim_1, dim_2, dim_3, dim_4, // dim_5, dim_6, dim_7, tax_code, tax_system, currency, dc_flag, cur_amount, amount, number_1, // value_1, value_2, value_3, description, trans_date, voucher_date, voucher_no, period, tax_flag, ext_inv_ref, // ext_ref, due_date, disc_date, discount, commitment, order_id, kid, pay_transfer, status, apar_type, // apar_id, pay_flag, voucher_ref, sequence_ref, intrule_id, factor_short, responsible, apar_name, address, province, // place, bank_account, pay_method, vat_reg_no, zip_code, curr_licence, account2, base_amount, base_curr, pay_temp_id, // allocation_key, period_no, clearing_code, swift, arrive_id, bank_acc_type //; public String beautifyGL07() { // this function will process the NULL values and return a GL07 fixed width line // ? allows null to not give a runtime error // ?? is effectively a coalesce. do the right side of the ?? if the left side is null else do the left side PayMethod = PayMethod?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); BatchId = BatchId?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Interface = Interface?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); VoucherType = VoucherType?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); TransType = TransType?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); Client = Client?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Account = Account?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat1 = Cat1?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat2 = Cat2?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat3 = Cat3?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat4 = Cat4?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat5 = Cat5?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat6 = Cat6?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Cat7 = Cat7?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); TaxCode = TaxCode?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); TaxSystem = TaxSystem?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Currency = Currency?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); DcFlag = DcFlag?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); CurAmount = CurAmount.Trim().PadLeft(20); Amount = Amount.Trim().PadLeft(20); Number1 = Number1.Trim().PadLeft(11); Value1 = Value1.Trim().PadLeft(20); Value2 = Value2.Trim().PadLeft(20); Value3 = Value3.Trim().PadLeft(20); Description = Description?.Trim().PadRight(255).Substring(0, 255) ?? "".PadRight(255); TransDate = TransDate?.Trim().PadRight(8).Substring(0, 8) ?? "".PadRight(8); VoucherDate = VoucherDate?.Trim().PadRight(8).Substring(0, 8) ?? "".PadRight(8); VoucherNo = VoucherNo?.Trim().PadRight(15).Substring(0, 15) ?? "".PadRight(15); Period = Period?.Trim().PadRight(6).Substring(0, 6) ?? "".PadRight(6); TaxFlag = TaxFlag?.Trim().PadRight(1).Substring(0, 1) ?? "".PadRight(1); ExtInvRef = ExtInvRef?.Trim().PadRight(100).Substring(0, 100) ?? "".PadRight(100); ExtRef = ExtRef?.Trim().PadRight(255).Substring(0, 255) ?? "".PadRight(255); DueDate = DueDate?.Trim().PadRight(8).Substring(0, 8) ?? "".PadRight(8); DiscDate = DiscDate?.Trim().PadRight(8).Substring(0, 8) ?? "".PadRight(8); Discount = Discount?.Trim().PadRight(20).Substring(0, 20) ?? "".PadRight(20); Commitment = Commitment?.Trim().PadLeft(25).Substring(0, 25) ?? "".PadRight(25); OrderId = OrderId?.Trim().PadRight(15).Substring(0, 15) ?? "".PadRight(15); Kid = Kid?.Trim().PadRight(27).Substring(0, 27) ?? "".PadRight(27); PayTransfer = PayTransfer?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); Status = Status?.Trim().PadRight(1).Substring(0, 1) ?? "".PadRight(1); AparType = AparType?.Trim().PadRight(1).Substring(0, 1) ?? "".PadRight(1); AparId = AparId?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); PayFlag = PayFlag?.Trim().PadRight(1).Substring(0, 1) ?? "".PadRight(1); VoucherRef = VoucherRef?.Trim().PadRight(15).Substring(0, 15) ?? "".PadRight(15); SequenceRef = SequenceRef?.Trim().PadRight(9).Substring(0, 9) ?? "".PadRight(9); IntruleId = IntruleId?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); FactorShort = FactorShort?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); Responsible = Responsible?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); AparName = AparName?.Trim().PadRight(255).Substring(0, 255) ?? "".PadRight(255); Address = Address?.Trim().PadRight(160).Substring(0, 160) ?? "".PadRight(160); Province = Province?.Trim().PadRight(40).Substring(0, 40) ?? "".PadRight(40); Place = Place?.Trim().PadRight(40).Substring(0, 40) ?? "".PadRight(40); BankAccount = BankAccount?.Trim().PadRight(35).Substring(0, 35) ?? "".PadRight(35); PayMethod = PayMethod?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); VatRegNo = VatRegNo?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); ZipCode = ZipCode?.Trim().PadRight(15).Substring(0, 15) ?? "".PadRight(15); CurrLicence = CurrLicence?.Trim().PadRight(3).Substring(0, 3) ?? "".PadRight(3); Account2 = Account2?.Trim().PadRight(25).Substring(0, 25) ?? "".PadRight(25); BaseAmount = BaseAmount?.Trim().PadLeft(20).Substring(0, 20) ?? "".PadRight(20); BaseCurr = BaseCurr?.Trim().PadLeft(20).Substring(0, 20) ?? "".PadRight(20); PayTempId = PayTempId?.Trim().PadRight(4).Substring(0, 4) ?? "".PadRight(4); AllocationKey = AllocationKey?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); PeriodNo = PeriodNo?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); Clearingcode = Clearingcode?.Trim().PadRight(13).Substring(0, 13) ?? "".PadRight(13); Swift = Swift?.Trim().PadRight(11).Substring(0, 11) ?? "".PadRight(11); Arriveid = Arriveid?.Trim().PadRight(15).Substring(0, 15) ?? "".PadRight(15); BankAccType = BankAccType?.Trim().PadRight(2).Substring(0, 2) ?? "".PadRight(2); return(BatchId + Interface + VoucherType + TransType + Client + Account + Cat1 + Cat2 + Cat3 + Cat4 + Cat5 + Cat6 + Cat7 + TaxCode + TaxSystem + Currency + DcFlag + CurAmount + Amount + Number1 + Value1 + Value2 + Value3 + Description + TransDate + VoucherDate + VoucherNo + Period + TaxFlag + ExtInvRef + ExtRef + DueDate + DiscDate + Discount + Commitment + OrderId + Kid + PayTransfer + Status + AparType + AparId + PayFlag + VoucherRef + SequenceRef + IntruleId + FactorShort + Responsible + AparName + Address + Province + Place + BankAccount + PayMethod + VatRegNo + ZipCode + CurrLicence + Account2 + BaseAmount + BaseCurr + PayTempId + AllocationKey + PeriodNo + Clearingcode + Swift + Arriveid + BankAccType ); // String GL07Line = fw.BatchId.Trim().PadRight(25) + fw.Interface?.Trim().PadRight(25) + fw.VoucherType.Trim().PadRight(25) + fw.TransType.Trim().PadRight(2) + fw.Client.Trim().PadRight(25) //+ fw.Account.Trim().PadRight(25) + fw.Cat1.Trim().PadRight(25) + fw.Cat2.Trim().PadRight(25) + fw.Cat3.Trim().PadRight(25) + fw.Cat4.Trim().PadRight(25) //+ fw.Cat5.Trim().PadRight(25) + fw.Cat6.Trim().PadRight(25) + fw.Cat7.Trim().PadRight(25) + fw.TaxCode.Trim().PadRight(25) + fw.TaxSystem.Trim().PadRight(25) + fw.Currency.Trim().PadRight(25) //+ fw.DcFlag.Trim().PadRight(2) + fw.CurAmount.Trim().PadLeft(20) + fw.Amount.Trim().PadLeft(20) + fw.Number1.Trim().PadLeft(11) + fw.Value1.Trim().PadLeft(20) + fw.Value2.Trim().PadLeft(20) //+ fw.Value3.Trim().PadLeft(20) + fw.Description.Trim().PadRight(255) + fw.TransDate.Trim().PadRight(8) + fw.VoucherDate.Trim().PadRight(8) + fw.VoucherNo.Trim().PadRight(15) //+ fw.Period.Trim().PadRight(6) + fw.TaxFlag.Trim().PadRight(1) + fw.ExtInvRef.Trim().PadRight(100) + fw.ExtRef.Trim().PadRight(255) + fw.DueDate.Trim().PadRight(8) + fw.DiscDate.Trim().PadRight(8) //+ fw.Discount.Trim().PadRight(20) + fw.Commitment.Trim().PadLeft(25) + fw.OrderId.Trim().PadRight(15) + fw.Kid.Trim().PadRight(27) + fw.PayTransfer.Trim().PadRight(2) + fw.PayTransfer.Trim().PadRight(1) //+ fw.AparType.Trim().PadRight(1) + fw.AparId.Trim().PadRight(25) + fw.PayFlag.Trim().PadRight(1) + fw.VoucherRef.Trim().PadRight(15) + fw.SequenceRef.Trim().PadRight(9) + fw.IntruleId.Trim().PadRight(25) //+ fw.FactorShort.Trim().PadRight(25) + fw.Responsible.Trim().PadRight(25) + fw.AparName.Trim().PadRight(255) + fw.Address.Trim().PadRight(160) + fw.Province.Trim().PadRight(40) + fw.Place.Trim().PadRight(40) //+ fw.BankAccount.Trim().PadRight(35) + fw.PayMethod + fw.VatRegNo.Trim().PadRight(25) + fw.ZipCode.Trim().PadRight(15) + fw.CurrLicence.Trim().PadRight(3) + fw.Account2.Trim().PadRight(25) //+ fw.BaseAmount.Trim().PadLeft(20) + fw.BaseCurr.Trim().PadLeft(20) + fw.PayTempId.Trim().PadRight(4) + fw.AllocationKey.Trim().PadRight(2) + fw.PeriodNo.Trim().PadRight(2) + fw.Clearingcode.Trim().PadRight(13) //+ fw.Swift.Trim().PadRight(11) + fw.Arriveid.Trim().PadRight(15) + fw.BankAccType.Trim().PadRight(2) // ; }