public Images AccurateSearch(string imageNumber) //精确查找 { ///throw new NotImplementedException(); if (imageNumber == String.Empty) //如果数据库中没有该图号,则查找为空 { throw new Exception("不存在该图号,请重新输入查询!"); } else //通过ui中填写的内容 返回来相应的数据 { Images image = iDAO.SelectImage(imageNumber); return(image); } }
public bool AddConnect1(List <Connect1> c1List) { bool flag = false; for (int i = 0; i < c1List.Count; i++) { if (iDAO.SelectImage(c1List[i].ImageNumber) != null && pDAO.SelectProduct(c1List[i].ProductType) != null) { if (c1DAO.SelectConnect1(c1List[i]) == null) { c1DAO.AddConnect1(c1List[i]); flag = true; } } else { flag = false; } } return(flag); }
public bool AddConnect2(List <Connect2> c2List) { bool flag = false; for (int i = 0; i < c2List.Count; i++) { if (iDAO.SelectImage(c2List[i].ImageNumber) != null && cDAO.SelectCompany(c2List[i].CompanyNumber) != null) { if (c2DAO.SelectConnect2(c2List[i]) == null) { c2DAO.AddConnect2(c2List[i]); flag = true; } } else { flag = false; } } return(flag); }
public bool AddConnect3(List <Connect3> c3List) { bool flag = false; for (int i = 0; i < c3List.Count; i++) { if (iDAO.SelectImage(c3List[i].ImageNumber) != null && dDAO.SelectDepartment(c3List[i].DepartmentNumber) != null) { if (c3DAO.SelectConnect3(c3List[i]) == null) { c3DAO.AddConnect3(c3List[i]); flag = true; } } else { flag = false; } } return(flag); }