Exemple #1
0
        public Setting createSetting(
            int id,
            string name,
            string label,
            string value,
            int orderBy           = 0,
            bool viewable         = true,
            string inputType      = InputTypes.Text,
            ExternalSystem system = null,
            EntityAction action   = EntityAction.InsertOnSubmit
            )
        {
            var entity = Factory.CreateSetting(id, name, label, value, orderBy, viewable, inputType, system);

            DbAction(entity, action);

            return(entity);
        }
Exemple #2
0
        public Setting createSetting(
            string name,
            string label,
            string value,
            string prefix         = null,
            int orderBy           = 0,
            bool viewable         = true,
            string inputType      = InputTypes.Text,
            ExternalSystem system = null,
            EntityAction action   = EntityAction.InsertOnSubmit
            )
        {
            if (!string.IsNullOrEmpty(prefix))
            {
                name = string.Format("{0}.{1}", prefix, name);
            }

            var entity = Factory.CreateSetting(name, label, value, orderBy, viewable, inputType, system);

            DbAction(entity, action);

            return(entity);
        }