예제 #1
0
        public async Task <int> SaveUserArea(UserAreaModel userArea)
        {
            int result = -1;

            List <SQLParam> sQLParam = new List <SQLParam>();

            sQLParam.Add(new SQLParam("@UserAreaID", userArea.UserAreaID));
            sQLParam.Add(new SQLParam("@UserArea", userArea.UserArea));

            try
            {
                SQLGetAsync objSQL = new SQLGetAsync();
                result = await objSQL.ExecuteAsScalarAsync <int>("[dbo].[usp_Asset_UserArea_Save]", sQLParam);
            }
            catch (Exception)
            {
                throw;
            }

            return(result);
        }
예제 #2
0
        public async Task <int> SaveUserArea(UserAreaModel userArea)
        {
            AssetDataprovider dataprovider = new AssetDataprovider();

            return(await dataprovider.SaveUserArea(userArea));
        }