Exemple #1
0
        public Planner getPlanDetails(string planIdDet)
        {
            PlannerDAO dao = new PlannerDAO();

            return(dao.getByPlanId(planIdDet));
            //return dao.getByPlanId(planIdDet);
        }
Exemple #2
0
        private void btnDone_Click(object sender, EventArgs e)
        {
            PlannerDAO plannerDAO = PlannerDAO.getInstance();

            //for (int i = 0; i < Form1.DayPlan.Count-1; i++)
            //{
            //    for (int j = 0; j < Form1.DayPlan[i].Count; i++)
            //    {
            //        Planner plan = new Planner(i + 1, Form1.DayPlan[i][j].Name, Form1.DayPlan[i][j].MapX, Form1.DayPlan[i][j].MapY, Form1.DayPlan[i][j].Loc, Form1.DayPlan[i][j].Tel, Form1.DayPlan[i][j].Image);
            //        plannerDAO.InsertPlanner(plan);
            //    }
            //}
            foreach (var item in Form1.DayPlan)
            {
                for (int i = 0; i < item.Count; i++)
                {
                    Planner plan = new Planner(i + 1, item[i].Name, item[i].MapX, item[i].MapY, item[i].Loc, item[i].Tel, item[i].Image);
                    plannerDAO.InsertPlanner(plan);
                }
            }

            //Form1.DayPlan.Clear();
            //Form1.TempPlan.Clear();
            MessageBox.Show("저장되었습니다");
            planDateControl1.BringToFront();
            btnpre.Location = new Point(666, 369);
            btnpre.Enabled  = false;
            btnNext.Visible = true;
            btnDone.Visible = false;
            PageNumber      = 0;
        }
Exemple #3
0
        public int addPlanner()
        {
            PlannerDAO dao = new PlannerDAO();

            return(dao.Insert(this));
        }