Example #1
0
 /// -----------------------------------------------------------------------------
 /// <summary>
 /// adds an object to the database
 /// </summary>
 /// <remarks>
 /// </remarks>
 /// <param name="objATI_WorkoutBuilder">The ATI_WorkoutBuilderInfo object</param>
 /// <history>
 /// </history>
 /// -----------------------------------------------------------------------------
 public void AddATI_WorkoutBuilder(ATI_WorkoutBuilderInfo objATI_WorkoutBuilder)
 {
     if (objATI_WorkoutBuilder.Content.Trim() != "")
     {
         DataProvider.Instance().AddATI_WorkoutBuilder(objATI_WorkoutBuilder.ModuleId, objATI_WorkoutBuilder.Content, objATI_WorkoutBuilder.CreatedByUser);
     }
 }
 /// -----------------------------------------------------------------------------
 /// <summary>
 /// adds an object to the database
 /// </summary>
 /// <remarks>
 /// </remarks>
 /// <param name="objATI_WorkoutBuilder">The ATI_WorkoutBuilderInfo object</param>
 /// <history>
 /// </history>
 /// -----------------------------------------------------------------------------
 public void AddATI_WorkoutBuilder(ATI_WorkoutBuilderInfo objATI_WorkoutBuilder)
 {
     if (objATI_WorkoutBuilder.Content.Trim() != "")
     {
         DataProvider.Instance().AddATI_WorkoutBuilder(objATI_WorkoutBuilder.ModuleId, objATI_WorkoutBuilder.Content, objATI_WorkoutBuilder.CreatedByUser);
     }
 }
Example #3
0
        /// -----------------------------------------------------------------------------
        /// <summary>
        /// ImportModule implements the IPortable ImportModule Interface
        /// </summary>
        /// <remarks>
        /// </remarks>
        /// <param name="ModuleID">The Id of the module to be imported</param>
        /// <param name="Content">The content to be imported</param>
        /// <param name="Version">The version of the module to be imported</param>
        /// <param name="UserId">The Id of the user performing the import</param>
        /// <history>
        /// </history>
        /// -----------------------------------------------------------------------------
        public void ImportModule(int ModuleID, string Content, string Version, int UserId)
        {
            XmlNode xmlATI_WorkoutBuilders = Globals.GetContent(Content, "ATI_WorkoutBuilders");

            foreach (XmlNode xmlATI_WorkoutBuilder in xmlATI_WorkoutBuilders.SelectNodes("ATI_WorkoutBuilder"))
            {
                ATI_WorkoutBuilderInfo objATI_WorkoutBuilder = new ATI_WorkoutBuilderInfo();

                objATI_WorkoutBuilder.ModuleId      = ModuleID;
                objATI_WorkoutBuilder.Content       = xmlATI_WorkoutBuilder.SelectSingleNode("content").InnerText;
                objATI_WorkoutBuilder.CreatedByUser = UserId;
                AddATI_WorkoutBuilder(objATI_WorkoutBuilder);
            }
        }
        /// -----------------------------------------------------------------------------
        /// <summary>
        /// ImportModule implements the IPortable ImportModule Interface
        /// </summary>
        /// <remarks>
        /// </remarks>
        /// <param name="ModuleID">The Id of the module to be imported</param>
        /// <param name="Content">The content to be imported</param>
        /// <param name="Version">The version of the module to be imported</param>
        /// <param name="UserId">The Id of the user performing the import</param>
        /// <history>
        /// </history>
        /// -----------------------------------------------------------------------------
        public void ImportModule(int ModuleID, string Content, string Version, int UserId)
        {
            XmlNode xmlATI_WorkoutBuilders = Globals.GetContent(Content, "ATI_WorkoutBuilders");

            foreach (XmlNode xmlATI_WorkoutBuilder in xmlATI_WorkoutBuilders.SelectNodes("ATI_WorkoutBuilder"))
            {
                ATI_WorkoutBuilderInfo objATI_WorkoutBuilder = new ATI_WorkoutBuilderInfo();

                objATI_WorkoutBuilder.ModuleId = ModuleID;
                objATI_WorkoutBuilder.Content = xmlATI_WorkoutBuilder.SelectSingleNode("content").InnerText;
                objATI_WorkoutBuilder.CreatedByUser = UserId;
                AddATI_WorkoutBuilder(objATI_WorkoutBuilder);
            }
        }