Exemple #1
0
        // Updates the options for a given campaign and query
        private bool updateOption()
        {
            DataManagerOption dmo = DataManagerOption.GetInstance(campaignID, queryID, true);

            dmo.RowLimit   = rowLimit;
            dmo.SortActive = sortOn;
            if (sortColumn < 1)
            {
                sortColumn = 1;
            }
            dmo.SortColumn     = sortColumn;
            dmo.SortDirection  = sortDirection;
            dmo.ShowCSVHeaders = showCSVHeaders;
            dmo.save();
            return(true);
        }
Exemple #2
0
        private bool createNamedSettings(string name)
        {
            DataManagerOption dmo = DataManagerOption.GetInstance(campaignID, queryID, false);

            if (dmo != null)
            {
                dmo              = dmo.copy();
                dmo.QueryId      = 0;
                dmo.Name         = name;
                dmo.IsNamedQuery = 1;
                dmo.save();
                //getNamedSettingsList((int)dmo.Id);
                getNamedSettingsList(0);
                ajaxResponse.message = "Created Name Settings";
            }
            return(true);
        }
Exemple #3
0
        private bool loadSettings(int id)
        {
            DataManagerOption dmo = DataManagerOption.GetInstance(campaignID, queryID, false);

            if (dmo != null)
            {
                dmo.delete();
                dmo              = DataManagerOption.GetInstance(id);
                dmo              = dmo.copy();
                dmo.QueryId      = queryID;
                dmo.Name         = "";
                dmo.IsNamedQuery = 0;
                dmo.save();
                getNamedSettingsList((int)dmo.Id);
                ajaxResponse.message = "Loaded Name Settings";
            }
            return(true);
        }