Пример #1
0
        public string InsertarDiscoServidorApp(int Srv_Id, int SrvD_Capacidad, string SrvD_Unidad, int SrvTA_Id, int SrvUD_Id, int idItem, string SrvD_Observaciones)
        {
            DLSoftware odlSoftware = new DLSoftware();
            string     Res         = "";

            odlSoftware.BorrarDiscosServidorApp(Srv_Id, SrvD_Unidad);

            Res = odlSoftware.InsertarDiscoServidorApp(Srv_Id, SrvD_Capacidad, SrvD_Unidad, SrvTA_Id, SrvUD_Id, idItem, SrvD_Observaciones);

            if (Res != "")
            {
                Res += "Error al insertar unidad " + SrvD_Unidad + ": " + Res.Replace(Environment.NewLine, "\t") + Environment.NewLine;
            }

            return(Res);
        }
Пример #2
0
        public string InsertarDiscosServidorApp(int Srv_Id, System.Data.DataTable Discos)
        {
            DLSoftware odlSoftware = new DLSoftware();
            string     Res         = "";
            string     ResTemp     = "";

            odlSoftware.BorrarDiscosServidorApp(Srv_Id);

            for (int w = 0; w < Discos.Rows.Count; w++)
            {
                ResTemp = odlSoftware.InsertarDiscoServidorApp(Srv_Id, Convert.ToInt32(Discos.Rows[w]["SrvD_Capacidad"].ToString()), Discos.Rows[w]["SrvD_Unidad"].ToString(), Convert.ToInt32(Discos.Rows[w]["SrvTA_Id"].ToString()), Convert.ToInt32(Discos.Rows[w]["SrvUD_Id"].ToString()), Convert.ToInt32(Discos.Rows[w]["idItem"].ToString()), Discos.Rows[w]["SrvD_Observaciones"].ToString());

                if (ResTemp != "")
                {
                    Res += "Error al insertar unidad " + Discos.Rows[w]["SrvD_Unidad"].ToString() + ": " + ResTemp.Replace(Environment.NewLine, "\t") + Environment.NewLine;
                }
            }

            return(Res);
        }
Пример #3
0
        public string BorrarDiscosServidorApp(int Srv_Id, string SrvD_Unidad)
        {
            DLSoftware odlSoftware = new DLSoftware();

            return(odlSoftware.BorrarDiscosServidorApp(Srv_Id, SrvD_Unidad));
        }