Exemplo n.º 1
0
        public List <int> GetAllIDs(int aPlanID)
        {
            List <int> _tmp = new List <int>();

            auditHelperDataSet.tbl_Plan_ContentDataTable _tbl = null;

            _tbl = _adapter.GetAllIDs(aPlanID);
            foreach (auditHelperDataSet.tbl_Plan_ContentRow rw in _tbl)
            {
                _tmp.Add(rw.content_id);
            }

            return(_tmp);
        }
Exemplo n.º 2
0
        public PlanContent GetByID(int aId)
        {
            PlanContent tmp = null;

            auditHelperDataSet.tbl_Plan_ContentDataTable _tbl = null;

            _tbl = _adapter.GetDataByID(aId);

            if (_tbl.Rows.Count == 1)
            {
                tmp = new PlanContent(_tbl[0].Isparent_idNull() ? -1 : _tbl[0].parent_id,
                                      _tbl[0].vch_recomendation,
                                      _tbl[0].vch_correct_actions, _tbl[0].employee_ID,
                                      _tbl[0].dtm_expired, _tbl[0].vch_comments, _tbl[0].risk_id,
                                      _tbl[0].Isstatus_idNull() ? -1 :_tbl[0].status_id,
                                      _tbl[0].plan_id, _tbl[0].vch_number, _tbl[0].content_id);
            }

            return(tmp);
        }