Exemple #1
0
        public async Task <BaseResults.EmptyResult> Delete([FromQuery] string sid, [FromBody] FizetesimodDto dto)
        {
            var result = new BaseResults.EmptyResult();

            using (var tr = await _context.Database.BeginTransactionAsync())
                try
                {
                    await FizetesimodBll.DeleteAsync(_context, sid, dto);

                    tr.Commit();
                }
                catch (Exception ex)
                {
                    tr.Rollback();
                    result.Error = ex.InmostMessage();
                }

            return(result);
        }
Exemple #2
0
        public async Task <BaseResults.EmptyResult> ZoomCheck([FromQuery] string sid, [FromBody] FizetesimodZoomParameter par)
        {
            var result = new BaseResults.EmptyResult();

            using (var tr = await _context.Database.BeginTransactionAsync())
                try
                {
                    await FizetesimodBll.ZoomCheckAsync(_context, sid, par.FizetesimodKod, par.Fizetesimod);

                    tr.Commit();
                }
                catch (Exception ex)
                {
                    tr.Rollback();
                    result.Error = ex.InmostMessage();
                }

            return(result);
        }
Exemple #3
0
        public async Task <ColumnSettingsResult> GetReszletekSettings([FromQuery] string sid)
        {
            var result = new ColumnSettingsResult();

            using (var tr = await _context.Database.BeginTransactionAsync())
                try
                {
                    result.Result = FizetesimodBll.ReszletekSettings(_context, sid);

                    tr.Commit();
                }
                catch (Exception ex)
                {
                    tr.Rollback();
                    result.Error = ex.InmostMessage();
                }

            return(result);
        }
Exemple #4
0
        public async Task <FizetesimodResult> Read([FromQuery] string sid, [FromBody] string maszk)
        {
            var result = new FizetesimodResult();

            using (var tr = await _context.Database.BeginTransactionAsync())
                try
                {
                    result.Result = await FizetesimodBll.ReadAsync(_context, sid, maszk);

                    tr.Commit();
                }
                catch (Exception ex)
                {
                    tr.Rollback();
                    result.Error = ex.InmostMessage();
                }

            return(result);
        }
Exemple #5
0
        public async Task <FizetesimodResult> CreateNew([FromQuery] string sid)
        {
            var result = new FizetesimodResult();

            using (var tr = await _context.Database.BeginTransactionAsync())
                try
                {
                    result.Result = new List <FizetesimodDto> {
                        await FizetesimodBll.CreateNewAsync(_context, sid)
                    };

                    tr.Commit();
                }
                catch (Exception ex)
                {
                    tr.Rollback();
                    result.Error = ex.InmostMessage();
                }

            return(result);
        }