public void Update(string CountryRegionCode, string CurrencyCode, DateTime ModifiedDate) { CountryRegionCurrency item = new CountryRegionCurrency(); item.CountryRegionCode = CountryRegionCode; item.CurrencyCode = CurrencyCode; item.ModifiedDate = ModifiedDate; item.MarkOld(); item.Save(UserName); }
public static void SaveCountryRegionMap(string varCurrencyCode, string[] itemList) { QueryCommandCollection coll = new SubSonic.QueryCommandCollection(); //delete out the existing QueryCommand cmdDel = new QueryCommand("DELETE FROM CountryRegionCurrency WHERE CurrencyCode=@CurrencyCode", Currency.Schema.Provider.Name); cmdDel.AddParameter("@CurrencyCode", varCurrencyCode); coll.Add(cmdDel); DataService.ExecuteTransaction(coll); foreach (string item in itemList) { CountryRegionCurrency varCountryRegionCurrency = new CountryRegionCurrency(); varCountryRegionCurrency.SetColumnValue("CurrencyCode", varCurrencyCode); varCountryRegionCurrency.SetColumnValue("CountryRegionCode", item); varCountryRegionCurrency.Save(); } }
public static void SaveCurrencyMap(string varCountryRegionCode, System.Web.UI.WebControls.ListItemCollection itemList) { QueryCommandCollection coll = new SubSonic.QueryCommandCollection(); //delete out the existing QueryCommand cmdDel = new QueryCommand("DELETE FROM CountryRegionCurrency WHERE CountryRegionCode=@CountryRegionCode", CountryRegion.Schema.Provider.Name); cmdDel.AddParameter("@CountryRegionCode", varCountryRegionCode); coll.Add(cmdDel); DataService.ExecuteTransaction(coll); foreach (System.Web.UI.WebControls.ListItem l in itemList) { if (l.Selected) { CountryRegionCurrency varCountryRegionCurrency = new CountryRegionCurrency(); varCountryRegionCurrency.SetColumnValue("CountryRegionCode", varCountryRegionCode); varCountryRegionCurrency.SetColumnValue("CurrencyCode", l.Value); varCountryRegionCurrency.Save(); } } }
public bool Destroy(object CountryRegionCode) { return(CountryRegionCurrency.Destroy(CountryRegionCode) == 1); }
public bool Delete(object CountryRegionCode) { return(CountryRegionCurrency.Delete(CountryRegionCode) == 1); }