Esempio n. 1
0
        /// <summary>
        /// Generates the person full name with departament.
        /// </summary>
        /// <param name="row">The row.</param>
        /// <param name="table">The table.</param>
        /// <returns></returns>
        private string GeneratePersonFullNameWithDepartament(DataRow row, Dlv005DataSet.BD06_ORG_EINHEIT_TBLDataTable table)
        {
            string totalValue = string.Empty;

            totalValue += row["Name"].ToString() + ", " + row["Vorname"].ToString() + ", " + GetSection(row["Department"].ToString(), table);

            return(totalValue);
        }
Esempio n. 2
0
        /// <summary>
        /// Gets the section.
        /// </summary>
        /// <param name="v">The v.</param>
        /// <param name="table">The table.</param>
        /// <returns></returns>
        private string GetSection(string departament, Dlv005DataSet.BD06_ORG_EINHEIT_TBLDataTable table)
        {
            string str = string.Empty;

            foreach (DataRow row in table)
            {
                if (row[1].ToString() == departament || row[0].ToString() == departament)
                {
                    str = row[0].ToString();
                    break;
                }
            }
            return(str);
        }
Esempio n. 3
0
 /// <summary>
 /// Validates the engineering.
 /// </summary>
 /// <param name="valueFromBox">The value from box.</param>
 /// <param name="table">The table.</param>
 /// <param name="BD06Table">The b D06 table.</param>
 /// <returns></returns>
 public bool ValidateCustomerAndChiefAndEngineering(string valueFromBox, Dlv005DataSet.BD09_PERSONDataTable table, Dlv005DataSet.BD06_ORG_EINHEIT_TBLDataTable BD06Table)
 {
     foreach (DataRow row in table)
     {
         if (GeneratePersonFullNameWithDepartament(row, BD06Table).Equals(valueFromBox, StringComparison.OrdinalIgnoreCase))
         {
             return(true);
         }
     }
     return(false);
 }