Exemple #1
0
        public void SetStatusDate(int p_oid, Nullable <DateTime> p_statusDate)
        {
            /*PROTECTED REGION ID(ChroniGenNHibernate.CEN.Chroni_Goal_setStatusDate) ENABLED START*/

            // Write here your custom code...

            GoalCAD goalCAD = new GoalCAD();
            GoalCEN goalCEN = new GoalCEN(goalCAD);

            if (p_oid > 0)
            {
                GoalEN goal = goalCEN.ReadOID(p_oid);

                if (goal != null)
                {
                    if (p_statusDate != null && p_statusDate >= goal.StatusDate)
                    {
                        goal.StatusDate = p_statusDate;
                        goalCAD.Modify(goal);
                    }
                }
            }

            /*PROTECTED REGION END*/
        }
        public void SetStatus(int p_oid, ChroniGenNHibernate.Enumerated.Chroni.GoalStatusEnum p_status)
        {
            /*PROTECTED REGION ID(ChroniGenNHibernate.CEN.Chroni_Goal_setStatus) ENABLED START*/

            // Write here your custom code...

            GoalCAD goalCAD = new GoalCAD();
            GoalCEN goalCEN = new GoalCEN(goalCAD);

            if (p_oid > 0)
            {
                GoalEN goal = goalCEN.ReadOID(p_oid);

                if (goal != null)
                {
                    if (p_status > 0)
                    {
                        goal.Status = p_status;
                        goalCAD.Modify(goal);
                    }
                }
            }

            /*PROTECTED REGION END*/
        }