示例#1
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (!Title.Equals(""))
            {
                str += "&title=\"" + Title + "\"";
            }
            if (!MessageText.Equals(""))
            {
                str += "&messagetext=\"" + MessageText + "\"";
            }
            str += "&seen=\"" + seen.ToString() + "\"";
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#2
0
        public override string ToString()
        {
            string str = "ID: " + IDUser.ToString() + " Name: " + FullName +
                         " Lg: " + Login + " Em: " + Email;

            return(str);
        }
示例#3
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (Minutes != 0)
            {
                str += "&minutes=\"" + Minutes + "\"";
            }
            if (TrainDate != null)
            {
                str += "&traindate=\"" + TrainDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#4
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (WValue != 0)
            {
                str += "&weight=\"" + WValue.ToString() + "\"";
            }
            if (WeightDate != null)
            {
                str += "&weightdate=\"" + WeightDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#5
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (AlertTime != null)
            {
                str += "&alerttime=\"" + AlertTime /*.ToString("yyyy-MM-dd HH:mm:ss")*/ + "\"";
            }
            if (Status != -1)
            {
                str += "&status=\"" + Status.ToString() + "\"";
            }
            if (MealType != -1)
            {
                str += "&mealtype=\"" + MealType.ToString() + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#6
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver= \"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser= \"" + IDUser.ToString() + "\"";
            }
            if (Goal != 0)
            {
                str += "&goal= \"" + Goal.ToString() + "\"";
            }
            if (StartGoal != null)
            {
                str += "&startgoal= \"" + StartGoal.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate= \"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate= \"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#7
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (BeginDate != null)
            {
                str += "&begindate=\"" + BeginDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (EndDate != null)
            {
                str += "&enddate=\"" + EndDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (Price != 0)
            {
                str += "&price=\"" + Price.ToString() + "\"";
            }
            if (IsActive != 0)
            {
                str += "&isactive=\"" + IsActive.ToString() + "\"";
            }
            if (Trncode != null && !Trncode.Equals(""))
            {
                str += "&trncode=\"" + Trncode + "\"";
            }
            if (Deleted != 0)
            {
                str += "&deleted=\"" + Deleted.ToString() + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#8
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (Name != null)
            {
                str += "&name=\"" + Name + "\"";
            }
            if (!Description.Equals(""))
            {
                str += "&description=\"" + Description + "\"";
            }
            if (IDLang != -1)
            {
                str += "&idlang=\"" + IDLang.ToString() + "\"";
            }
            if (IDUser != 0)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (IsActive != -1)
            {
                str += "&isActive=\"" + IsActive.ToString() + "\"";
            }
            if (Deleted != 0)
            {
                str += "&deleted=\"" + Deleted.ToString() + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#9
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (IDCategory != 0)
            {
                str += "&idcategory=\"" + IDCategory.ToString() + "\"";
            }
            if (IDMealUnit != 0)
            {
                str += "&idmealunit=\"" + IDServerMealUnit.ToString() + "\"";
            }
            if (Qty != 0)
            {
                str += "&qty=\"" + Qty.ToString() + "\"";
            }
            if (MealDate != null)
            {
                str += "&mealdate=\"" + MealDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#10
0
        public void dbEnter(string login, string password)
        {
            command.CommandText = "SELECT [ID_Sotrudnika] FROM [INGPROMTORG].[dbo].[Sotrudniki] WHERE [Sotrudnika_Login] = '" + login + "' and [Sotrudnika_Password] = '" + password + "'";

            try
            {
                connection.Open();
                IDUser = Convert.ToInt32(command.ExecuteScalar().ToString());
                command.CommandText = "SELECT [Dolgnost_ID] FROM [INGPROMTORG].[dbo].[Sotrudniki] WHERE [ID_Sotrudnika] like '%" + IDUser.ToString() + "%'";
                Proverka            = Convert.ToInt32(command.ExecuteScalar().ToString());
                command.CommandText = "SELECT [Dostup_Dolgnost] FROM [INGPROMTORG].[dbo].[Dolgnost] WHERE [ID_Dolgnost] like '%" + Proverka.ToString() + "%'";
                Dostup = command.ExecuteScalar().ToString();
                sot    = Dostup[0].ToString();
                dol    = Dostup[1].ToString();
                pokup  = Dostup[2].ToString();
                usl    = Dostup[3].ToString();
                tovar  = Dostup[4].ToString();
                tovn   = Dostup[5].ToString();
                trann  = Dostup[6].ToString();
                dog    = Dostup[7].ToString();
            }
            catch
            {
                IDUser = 0;
            }
            finally
            {
                connection.Close();
            }
        }
示例#11
0
        public override string ToString()
        {
            string str = "";

            str += "&idserver=\"" + IDServer.ToString() + "\"";
            if (IDUnit != -1)
            {
                str += "&idunit=\"" + IDUnit.ToString() + "\"";
            }
            if (IDServerMeal != -1)
            {
                str += "&idmeal=\"" + IDServerMeal.ToString() + "\"";
            }
            if (IDUser != 0)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (Calories != -1)
            {
                str += "&calories=\"" + Calories.ToString() + "\"";
            }
            if (Protein != -1)
            {
                str += "&protein=\"" + Protein.ToString() + "\"";
            }
            if (Carb != -1)
            {
                str += "&carb=\"" + Carb.ToString() + "\"";
            }
            if (Fat != -1)
            {
                str += "&fat=\"" + Fat.ToString() + "\"";
            }
            if (SatFat != -1)
            {
                str += "&satfat=\"" + SatFat.ToString() + "\"";
            }
            if (UnSatFat != -1)
            {
                str += "&unsatfat=\"" + UnSatFat.ToString() + "\"";
            }
            if (Cholesterol != -1)
            {
                str += "&cholesterol=\"" + Cholesterol.ToString() + "\"";
            }
            if (Sugar != -1)
            {
                str += "&sugar=\"" + Sugar.ToString() + "\"";
            }
            if (Natrium != -1)
            {
                str += "&natrium=\"" + Natrium.ToString() + "\"";
            }
            if (Potassium != -1)
            {
                str += "&potassium=\"" + Potassium.ToString() + "\"";
            }
            if (Fiber != -1)
            {
                str += "&fiber=\"" + Fiber.ToString() + "\"";
            }
            if (Deleted != -1)
            {
                str += "&deleted=\"" + Deleted.ToString() + "\"";
            }
            if (InsertDate != null)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != null)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }

            return(str.Substring(1));
        }
示例#12
0
        public override string ToString()
        {
            string str = "";

            if (IDUser != -1)
            {
                str += "&iduser=\"" + IDUser.ToString() + "\"";
            }
            if (!AccessToken.Equals(""))
            {
                str += "&accesstoken=\"" + Uri.EscapeDataString(AccessToken) + "\"";
            }
            if (FacebookID != -1)
            {
                str += "&iduser=\"" + FacebookID.ToString() + "\"";
            }
            if (!FirstName.Equals(""))
            {
                str += "&firstname=\"" + Uri.EscapeDataString(FirstName) + "\"";
            }
            if (!LastName.Equals(""))
            {
                str += "&lastname=\"" + Uri.EscapeDataString(LastName) + "\"";
            }
            if (Gender != -1)
            {
                str += "&gender=\"" + Gender.ToString() + "\"";
            }
            if (!Email.Equals(""))
            {
                str += "&email=\"" + Uri.EscapeDataString(Email) + "\"";
            }
            if (!Password.Equals(""))
            {
                str += "&password=\"" + Password + "\"";
            }
            if (!Location.Equals(""))
            {
                str += "&location=\"" + Location + "\"";
            }
            if (Height != -1)
            {
                str += "&height=\"" + Height.ToString() + "\"";
            }
            if (HeightType != -1)
            {
                str += "&heighttype=\"" + HeightType.ToString() + "\"";
            }
            if (Skeleton != 0)
            {
                str += "&skeleton=\"" + Skeleton.ToString() + "\"";
            }
            if (fertility != -1)
            {
                str += "&fertility=\"" + Fertility.ToString() + "\"";
            }
            if (Birthdate != null)
            {
                str += "&birthdate=\"" + Birthdate.Value.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (RemindDate != null)
            {
                str += "&reminddate=\"" + RemindDate.Value.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (InsertDate != DateTime.MinValue)
            {
                str += "&insertdate=\"" + InsertDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (UpdateDate != DateTime.MinValue)
            {
                str += "&updatedate=\"" + UpdateDate.ToString("yyyy-MM-dd HH:mm:ss") + "\"";
            }
            if (AdjustDiet != -1)
            {
                str += "&adjustdiet=\"" + AdjustDiet.ToString() + "\"";
            }
            return(str.Substring(1));
        }