private void Flag_Updated(object sender, FlagUpdatedEventArgs e) { int flagTypeId = e.FlagId; const string resource = "transactions.transaction_master"; const string resourceKey = "transaction_master_id"; int userId = this.UserId; TransactionGovernor.Flags.CreateFlag(this.Catalog, userId, flagTypeId, resource, resourceKey, this.GetSelectedValues()); this.BindGrid(); }
private void Flag_Updated(object sender, FlagUpdatedEventArgs e) { int flagTypeId = e.FlagId; string resource = this.DbTableName; string resourceKey = this.PrimaryKey; if (string.IsNullOrWhiteSpace(resource)) { throw new MixERPException(Warnings.CannotCreateFlagTransactionTableNull); } if (string.IsNullOrWhiteSpace(resourceKey)) { throw new MixERPException(Warnings.CannotCreateFlagTransactionTablePrimaryKeyNull); } Flags.CreateFlag(this.Catalog, this.UserId, flagTypeId, resource, resourceKey, this.GetSelectedValues().Select(t => Conversion.TryCastString(t)).ToList().ToCollection()); this.LoadGridView(); }
private void Flag_Updated(object sender, FlagUpdatedEventArgs e) { int flagTypeId = e.FlagId; const string resource = "account_statement"; const string resourceKey = "transaction_code"; int userId = AppUsers.GetCurrent().View.UserId.ToInt(); Flags.CreateFlag(AppUsers.GetCurrentUserDB(), userId, flagTypeId, resource, resourceKey, this.GetSelectedValues()); this.BindGridView(); this.CreateAccountOverviewPanel(this.accountOverviewTab); }
private void Flag_Updated(object sender, FlagUpdatedEventArgs e) { int flagTypeId = e.FlagId; const string resource = "transactions.inventory_transfer_requests"; const string resourceKey = "inventory_transfer_request_id"; if (string.IsNullOrWhiteSpace(resource)) { throw new MixERPException(Warnings.CannotCreateFlagTransactionTableNull); } Flags.CreateFlag(AppUsers.GetCurrentUserDB(), AppUsers.GetCurrent().View.UserId.ToInt(), flagTypeId, resource, resourceKey, this.GetSelectedValues().Select(t => Conversion.TryCastString(t)).ToList().ToCollection()); this.BindGridView(); }