示例#1
0
        public JsonObject SaveInfoSection(string infoSectionName, string infoSectionDescription, bool isActive, bool isDeleted, long sequence, long infoSectionId, long infoPageId)
        {
            var retMessage = new JsonObject();

            string message;
            long   retSectionID = DataInfoList.SaveLtdInfoSection(infoPageId, DecodeUrl(infoSectionName), DecodeUrl(infoSectionDescription), isActive, isDeleted, sequence, infoSectionId, out message);

            if ((retSectionID > 0) && (message.Trim().Length == 0))
            {
                retMessage.Put("message", infoSectionId == 0 ? "Successfully Added Info Section" : "Successfully Updated Info Section");
            }
            else
            {
                if (message.Trim().Length == 0)
                {
                    message = "Error in Saving Info Section. Return Info Section ID is 0";
                }
                retMessage.Put("error", message);
            }

            return(retMessage);
        }