Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- public void AddLine(int parentID, HeadDTO headDTO) {
- Head line = new Head();
- line.Description = headDTO.Description;
- line.Min = headDTO.Min;
- line.Exp = headDTO.Exp;
- line.Max = headDTO.Max;
- line.Median = ((line.Min + (3 * line.Exp) + line.Max) / 5.0);
- line.StdDev = (line.Max - line.Min) / 5;
- line.PValue = Math.Pow((double)line.StdDev, 2);
- line.IsLine = parentID;
- line.Owner = headDTO.Owner;
- line.TeamId = headDTO.TeamId;
- try {
- db.Heads.InsertOnSubmit(line);
- db.SubmitChanges();
- } catch { } /*what error??*/
- UpdateParent(GetHeadDetails(parentID));
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement