Exemple #1
0
        public bool SavePage(GeneralSessionInfo gsi, int PageID, IFormCollection fc)
        {
            Project OldProject = new Project(ProjectID);

            OldProject.LoadProjectFromDB(gsi, PageID);
            using (SqlConnection con = new SqlConnection(DBUtil.GetSqlConnectionString()))
            {
                FieldValueUpdateInfo UpdateInfo = new FieldValueUpdateInfo(con, gsi.retailerID, ProjectID, null, gsi.userID);
                OldProject.Page.Panels.SavePanels(fc, UpdateInfo);
            }

            return(false);
        }
Exemple #2
0
        public void SavePanels(IFormCollection fc, FieldValueUpdateInfo UpdateInfo)
        {
            StringBuilder sb = new StringBuilder();

            for (int i = 0; i < PanelList.Count; i++)
            {
                string a = PanelList[i].GetSaveSQL(fc, UpdateInfo);
                if (a != null)
                {
                    sb.Append(a);
                }
            }
            if (sb.Length != 0)
            {
                DBUtil.RunSQLQuery(UpdateInfo, sb.ToString().Trim());
            }
        }