Beispiel #1
0
        private void GetToolsByProducts()
        {
            var query = Query.GetCategoryQuery(View.GetSelectedCategory());

            if (query == "one product")
            {
                query = Query.GetProdIdByProductName(View.GetChoosenProd());
            }
            else
            {
                query = SelectFormatter.Get("prod_id", "(" + query + ")");
            }
            var conditions = new List <string>();

            conditions.Add("time_end<=to_date('" + View.GetTimeEnd() + "','dd.mm.yyyy')");
            conditions.Add("time_begin>=to_date('" + View.GetTimeBegin() + "','dd.mm.yyyy')");
            conditions.Add(QueryFormatter.In("prod_id", query));

            query = QueryFormatter.SelectFormatter.Get("prod_id"
                                                       , "products_exps"
                                                       , conditions);

            query = Query.GetToolsByProdIdLab(query, View.GetChoosenLab());
            Controller.Run <DirectorScientistsPresenter, string>(query);
        }
        private void GetTupleMasters()
        {
            var queryListWs  = SelectFormatter.Get("name", "workshops");
            var queryListSec = SelectFormatter.Get("name", "sectors");

            Controller.Run <MastersChoosePresenter, string, string>(queryListWs, queryListSec);
        }
Beispiel #3
0
        private void ChooseSquad()
        {
            var queryListWs  = SelectFormatter.Get("name", "workshops");
            var queryListSec = SelectFormatter.Get("name", "sectors");

            Controller.Run <TeamChoosePresenter, string, string>(queryListWs, queryListSec);
        }
Beispiel #4
0
        private void ChooseProdTuple()
        {
            var queryListWs  = SelectFormatter.Get("name", "workshops");
            var queryListSec = SelectFormatter.Get("name", "sectors");

            Controller.Run <ProductionChoosePresenter, string, string>(queryListWs, queryListSec);
        }
Beispiel #5
0
        private void GetProductsByLaboratory()
        {
            var query = Query.GetProdIdByLaboratory(View.GetChoosenItem(), View.GetTimeBegin()
                                                    , View.GetTimeEnd());
            var prodQuery = Query.GetCategoryQuery(View.GetSelectedCategory());

            query = SelectFormatter.Get("*", "(" + prodQuery + ")", query, "prod_id");
            Controller.Run <DirectorScientistsPresenter, string>(query);
        }
Beispiel #6
0
        private RoleManager.RoleType GetInformation()
        {
            var conditions = new List <string> {
                "login='******'"
                , "pas='******'"
            };
            var query = SelectFormatter.Get("role", "accounts", conditions);
            var ls    = Formatter
                        .GetStringData(Model.GetData(query));

            return(RoleManager.GetType(ls[0]));
        }
Beispiel #7
0
        public static string GetProductsNames(string id)
        {
            var query = SelectFormatter.Union(new List <string> {
                "name", "prod_id"
            }, new List <string> {
                "rockets"
                , "gliders"
                , "hang_gliders"
                , "helicopters"
                , "planes"
                , "other_prods"
            });

            return(SelectFormatter.Get("name", "(" + query + ")", id, "prod_id"));
        }