예제 #1
0
        public bool CheckPort(string PortName)
        {
            var       t  = PortName.Trim();
            DataTable dt = ImportHaulageBLL.GetAllPort(t);

            if (dt.AsEnumerable().FirstOrDefault(e => e.Field <String>("PortName") != t) != null)
            {
                return(true);
            }
            return(false);
        }
예제 #2
0
 public bool ReturnAt()
 {
     if (rdTransactionType.SelectedValue == "F")
     {
         //chk valid ReturnAt
         var       t  = txtReturn.Text.Trim();
         DataTable dt = ImportHaulageBLL.GetAllPort(t);
         if (dt.AsEnumerable().FirstOrDefault(e => e.Field <String>("PortName") != t) != null)
         {
             return(true);
         }
         return(false);
     }
     return(true);
 }
예제 #3
0
        public string[] GetCompletionList(string prefixText, int count)
        {
            DataTable dt = ImportHaulageBLL.GetAllPort(prefixText);

            string[] PortNames = new string[dt.Rows.Count];

            string s = string.Empty;

            for (int i = 0; i < dt.Rows.Count; i++)
            {
                //PortNames[i] = dt.Rows[i]["PortName"].ToString();
                s            = AjaxControlToolkit.AutoCompleteExtender.CreateAutoCompleteItem(dt.Rows[i]["PortName"].ToString(), dt.Rows[i]["PortId"].ToString());
                PortNames[i] = s;
            }
            return(PortNames);
        }