Ejemplo n.º 1
0
        private void btnSearchFile_Click(object sender, EventArgs e)
        {
            frmAssemblyExplorer wfrmAssemblyExplorer = new frmAssemblyExplorer();

            if (wfrmAssemblyExplorer.ShowDialog() == DialogResult.OK)
            {
                if (wfrmAssemblyExplorer.SelectedServiceConfiguration != null)
                {
                    ServiceConfiguration wServiceConfiguration = wfrmAssemblyExplorer.SelectedServiceConfiguration;
                    wServiceConfiguration.IsolationLevel = Fwk.Transaction.IsolationLevel.ReadCommitted;
                    if (ctrlService1.ShowAction == Action.New)
                    {
                        //Este codigo realiza la supociciobn de que si el servicio es CRUD se realizata transaccional.-
                        if (wServiceConfiguration.Name.Contains("Update") || wServiceConfiguration.Name.Contains("Create") || wServiceConfiguration.Name.Contains("Delete"))
                        {
                            wServiceConfiguration.TransactionalBehaviour = TransactionalBehaviour.RequiresNew;
                        }
                        else
                        {
                            wServiceConfiguration.TransactionalBehaviour = TransactionalBehaviour.Suppres;
                        }
                    }
                    ctrlService1.EntityParam = wServiceConfiguration;
                    ctrlService1.Populate();
                }
            }
        }
Ejemplo n.º 2
0
        private void btnSearchFile_Click(object sender, EventArgs e)
        {
            frmAssemblyExplorer wfrmAssemblyExplorer = new frmAssemblyExplorer();
            if (wfrmAssemblyExplorer.ShowDialog() == DialogResult.OK)
            {
                if (wfrmAssemblyExplorer.SelectedServiceConfiguration != null)
                {
                    ServiceConfiguration wServiceConfiguration = wfrmAssemblyExplorer.SelectedServiceConfiguration;
                    wServiceConfiguration.IsolationLevel = Fwk.Transaction.IsolationLevel.ReadCommitted;
                    if (ctrlService1.ShowAction == Action.New)
                    {

                        //Este codigo realiza la supociciobn de que si el servicio es CRUD se realizata transaccional.-
                        if (wServiceConfiguration.Name.Contains("Update") || wServiceConfiguration.Name.Contains("Create") || wServiceConfiguration.Name.Contains("Delete"))
                        {
                            wServiceConfiguration.TransactionalBehaviour = TransactionalBehaviour.RequiresNew;
                        }
                        else
                        {
                            wServiceConfiguration.TransactionalBehaviour = TransactionalBehaviour.Suppres;
                        }
                    }
                    ctrlService1.EntityParam = wServiceConfiguration;
                    ctrlService1.Populate();
                }
            }
        }
Ejemplo n.º 3
0
        //void SetProvider()
        //{

        //    //lblConnectionType.Text = CurrentProvider.ProviderType.ToString();
        //    //txtAddres.Text = CurrentProvider.SourceInfo;
        //    //txtApplicationId.Text = CurrentProvider.ApplicationId;
        //    //cnnstring.Clear();
        //    //if (CurrentProvider.ProviderType == ServiceProviderType.xml)
        //    //{
        //    //    cnnstring.Visible = false;
        //    //    lblAddress.Text = "File :";
        //    //    btnView.Visible = true;
        //    //}
        //    //if (CurrentProvider.ProviderType == ServiceProviderType.sqldatabase)
        //    //{
        //    //    btnView.Visible = false;
        //    //    lblAddress.Text = "Connection string";
        //    //    if (System.Configuration.ConfigurationManager.ConnectionStrings[CurrentProvider.SourceInfo] != null)
        //    //    {
        //    //        Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(CurrentProvider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[CurrentProvider.SourceInfo].ConnectionString);
        //    //        cnnstring.Populate(c);
        //    //        cnnstring.Visible = true;
        //    //    }
               
        //    //}
        //} 
        private void button1_Click(object sender, EventArgs e)
        {
            frmAssemblyExplorer f = new frmAssemblyExplorer();
            f.ShowDialog();
        }
Ejemplo n.º 4
0
        //void SetProvider()
        //{

        //    //lblConnectionType.Text = CurrentProvider.ProviderType.ToString();
        //    //txtAddres.Text = CurrentProvider.SourceInfo;
        //    //txtApplicationId.Text = CurrentProvider.ApplicationId;
        //    //cnnstring.Clear();
        //    //if (CurrentProvider.ProviderType == ServiceProviderType.xml)
        //    //{
        //    //    cnnstring.Visible = false;
        //    //    lblAddress.Text = "File :";
        //    //    btnView.Visible = true;
        //    //}
        //    //if (CurrentProvider.ProviderType == ServiceProviderType.sqldatabase)
        //    //{
        //    //    btnView.Visible = false;
        //    //    lblAddress.Text = "Connection string";
        //    //    if (System.Configuration.ConfigurationManager.ConnectionStrings[CurrentProvider.SourceInfo] != null)
        //    //    {
        //    //        Fwk.DataBase.CnnString c = new Fwk.DataBase.CnnString(CurrentProvider.SourceInfo, System.Configuration.ConfigurationManager.ConnectionStrings[CurrentProvider.SourceInfo].ConnectionString);
        //    //        cnnstring.Populate(c);
        //    //        cnnstring.Visible = true;
        //    //    }

        //    //}
        //}
        private void button1_Click(object sender, EventArgs e)
        {
            frmAssemblyExplorer f = new frmAssemblyExplorer();

            f.ShowDialog();
        }