private void insert_nguoi_xu_ly_cap(GridView v_grv, decimal v_cap_sd)
 {
     for (int i = 0; i < v_grv.RowCount; i++)
     {
         US_HT_BO_DICH_VU v_us_bo_dv = new US_HT_BO_DICH_VU();
         v_us_bo_dv.dcID_DICH_VU       = m_us_dich_vu.dcID;
         v_us_bo_dv.dcID_NGUOI_SU_DUNG = CIPConvert.ToDecimal(v_grv.GetDataRow(i)["ID_NGUOI_SU_DUNG"].ToString());
         v_us_bo_dv.dcCAP_SU_DUNG      = v_cap_sd;
         v_us_bo_dv.strTRANG_THAI_HSD  = "N";
         v_us_bo_dv.Insert();
     }
 }
        private void delete_ht_bo_dich_vu(GridView v_grv, decimal v_cap_sd)
        {
            US_DUNG_CHUNG v_us = new US_DUNG_CHUNG();
            DataSet       v_ds = new DataSet();

            v_ds.Tables.Add(new DataTable());
            string v_query = "SELECT hbdv.ID FROM HT_BO_DICH_VU hbdv WHERE hbdv.ID_DICH_VU =" + m_us_dich_vu.dcID.ToString() + "AND hbdv.CAP_SU_DUNG=" + v_cap_sd.ToString();

            v_us.FillDatasetWithQuery(v_ds, v_query);
            for (int i = 0; i < v_ds.Tables[0].Rows.Count; i++)
            {
                US_HT_BO_DICH_VU v_us_bo_dv = new US_HT_BO_DICH_VU(CIPConvert.ToDecimal(v_ds.Tables[0].Rows[i]["ID"].ToString()));
                v_us_bo_dv.Delete();
            }
        }