コード例 #1
0
 public FrmBuscaProducto()
 {
     InitializeComponent();
     ProductoController     = new ProductoController();
     PresentacionController = new PresentacionController();
     LaboratorioController  = new LaboratorioController();
 }
コード例 #2
0
        public FrmPresentaciones(dynamic objeto)
        {
            InitializeComponent();
            presentacionController = new PresentacionController();
            this.objeto            = objeto;

            if (this.objeto != null)
            {
                objeto        = (Presentacion)this.objeto;
                TxtClave.Text = objeto.PresentacionId;
            }
        }
コード例 #3
0
 public FrmPresentaciones()
 {
     InitializeComponent();
     presentacionController = new PresentacionController();
     ModoCreate             = true;
 }
コード例 #4
0
        private void Initialize()
        {
            //Controllers
            productoSustanciaController = new ProductoSustanciaController();
            cierreInventariopController = new CierreInventariopController();
            productoImpuestoController  = new ProductoImpuestoController();
            cierreInventarioController  = new CierreInventarioController();
            migrationTableController    = new MigrationTableController();
            migrationFieldController    = new MigrationFieldController();
            presentacionController      = new PresentacionController();
            laboratorioController       = new LaboratorioController();
            categoriaController         = new CategoriaController();
            sustanciaController         = new SustanciaController();
            productoController          = new ProductoController();
            loteController   = new LoteController();
            movInvController = new MovInvController();
            //Objetos
            productoSustancia = null;
            productoImpuesto  = null;
            cierreInventario  = null;
            cierreInventariop = null;
            migrationTable    = null;
            migrationField    = null;
            presentacion      = null;
            laboratorio       = null;
            categoria         = null;
            sustancia         = null;
            producto          = null;
            lote = null;

            //Listas
            productoSustancias = new List <ProductoSustancia>();
            productoImpuestos  = new List <ProductoImpuesto>();
            migrationTables    = new List <MigrationTable>();
            migrationFields    = new List <MigrationField>();
            presentaciones     = new List <Presentacion>();
            laboratorios       = new List <Laboratorio>();
            categorias         = new List <Categoria>();
            sustancias         = new List <Sustancia>();
            productos          = new List <Producto>();
            lotes = new List <Lote>();


            try
            {
                //Conexion vfpro
                Sql              = "";
                dataTable        = new DataTable();
                connectionstring = "Provider=VFPOLEDB.1;Data Source=" + Ambiente.Empresa.MicroPvdb + ";";
                oleDbConnection  = new OleDbConnection(connectionstring);
                oleDbConnection.Open();


                //Llena combo tablas
                migrationTables        = migrationTableController.SelectAll();
                CboTabla.DataSource    = migrationTables;
                CboTabla.DisplayMember = "Tabla";
                CboTabla.ValueMember   = "MigrationTableId";
                CboTabla.SelectedIndex = 0;
            }
            catch (Exception ex)
            {
                MessageBox.Show(ex.ToString());
            }
        }