Example #1
0
        public JsonResult GetChildList([FromBody] ChildListQuery query)
        {
            query.Parser = _parser;
            var data = EntityObjectService.GetEntityTreeItems(query);

            return(Json(data));
        }
Example #2
0
 public JsonResult AutosaveRestoringCheck([FromBody] AutoSaveData data)
 {
     return(Json(new
     {
         success = true,
         approvedRecordIDs = EntityObjectService.AutosaveRestoringCheck(data.RecordHeaders)
     }));
 }
Example #3
0
        public JsonNetResult <IList <EntityTreeItem> > GetChildList(
            string entityTypeCode,
            int?parentEntityId,
            int?entityId,
            bool returnSelf,
            string filter,
            string hostFilter,
            string selectItemIDs,
            [ModelBinder(typeof(JsonStringModelBinder <ArticleSearchQueryParam[]>))] ArticleSearchQueryParam[] searchQuery,
            [ModelBinder(typeof(JsonStringModelBinder <ArticleContextQueryParam[]>))] ArticleContextQueryParam[] contextQuery)
        {
            var ftsParser = DependencyResolver.Current.GetService <ArticleFullTextSearchQueryParser>();
            var data      = EntityObjectService.GetEntityTreeItems(entityTypeCode, parentEntityId, entityId, returnSelf, filter, hostFilter, selectItemIDs, searchQuery, contextQuery, ftsParser);

            return(new JsonNetResult <IList <EntityTreeItem> >(data));
        }
Example #4
0
 public JsonNetResult <EntityTreeItem> GetByTypeAndIdForTree(string entityTypeCode, int entityId, bool loadChilds, string filter) => EntityObjectService.GetByTypeAndIdForTree(entityTypeCode, entityId, loadChilds, filter);
Example #5
0
 public JsonResult GetParentInfo(string entityTypeCode, long entityId, long?parentEntityId)
 {
     return(Json(EntityObjectService.GetParentInfo(entityTypeCode, entityId, parentEntityId)?.ToList()));
 }
Example #6
0
 public JsonNetResult <object> UnlockAllEntities()
 {
     EntityObjectService.UnlockAllEntitiesLockedByCurrentUser();
     return(null);
 }
Example #7
0
 public JsonResult CheckForVariations(string entityTypeCode, int entityId)
 {
     return(Json(EntityObjectService.CheckForVariations(entityTypeCode, entityId)));
 }
Example #8
0
 public JsonNetResult <string> GetArticleFieldValue(int contentId, string fieldName, int articleId) => EntityObjectService.GetArticleFieldValue(contentId, fieldName, articleId);
Example #9
0
 public JsonNetResult <string> GetArticleLinkedItems(int linkId, int articleId) => EntityObjectService.GetArticleLinkedItems(linkId, articleId);
Example #10
0
 public JsonNetResult <int?> GetParentId(string entityTypeCode, int entityId) => EntityObjectService.GetParentId(entityTypeCode, entityId);
Example #11
0
 public JsonNetResult <IEnumerable <EntityInfo> > GetBreadCrumbsList(string entityTypeCode, long entityId, long?parentEntityId, string actionCode) => EntityObjectService.GetBreadCrumbsList(entityTypeCode, entityId, parentEntityId, actionCode).ToList();
Example #12
0
 public JsonResult GetBreadCrumbsList(string entityTypeCode, long entityId, long?parentEntityId, string actionCode)
 {
     return(Json(EntityObjectService.GetBreadCrumbsList(entityTypeCode, entityId, parentEntityId, actionCode)?.ToList()));
 }
Example #13
0
 public JsonNetResult <IList <ListItem> > GetSimpleList(string entityTypeCode, int parentEntityId, int?entityId, int?listId, int selectionMode, int[] selectedEntitiesIDs, string filter, int testEntityId = 0) => EntityObjectService.SimpleList(
     entityTypeCode,
     parentEntityId,
     entityId > 0 ? entityId : null,
     listId > 0 ? listId : null,
     (ListSelectionMode)Enum.Parse(typeof(ListSelectionMode), selectionMode.ToString()),
     selectedEntitiesIDs,
     filter,
     testEntityId
     );
Example #14
0
 public JsonResult GetParentIdsForTree([FromBody] ParentIdsForTreeQuery query)
 {
     return(Json(EntityObjectService.GetParentIdsForTree(query)));
 }
Example #15
0
 public JsonResult GetParentId(string entityTypeCode, int entityId)
 {
     return(Json(EntityObjectService.GetParentId(entityTypeCode, entityId)));
 }
Example #16
0
 public JsonResult GetName(string entityTypeCode, int entityId, int?parentEntityId)
 {
     return(Json(EntityObjectService.GetName(entityTypeCode, entityId, parentEntityId ?? 0)));
 }
Example #17
0
 public JsonResult GetSimpleList([FromBody] SimpleListQuery query)
 {
     return(Json(EntityObjectService.SimpleList(query)));
 }
Example #18
0
 public JsonResult GetByTypeAndIdForTree(string entityTypeCode, int entityId, bool loadChilds, string filter)
 {
     return(Json(EntityObjectService.GetByTypeAndIdForTree(entityTypeCode, entityId, loadChilds, filter)));
 }
Example #19
0
 public JsonNetResult <string> GetName(string entityTypeCode, int entityId, int?parentEntityId) => EntityObjectService.GetName(entityTypeCode, entityId, parentEntityId ?? 0);
Example #20
0
 public JsonResult GetContentFieldValues(int contentId, string fieldName)
 {
     return(Json(EntityObjectService.GetContentFieldValues(contentId, fieldName)));
 }
Example #21
0
 public JsonNetResult <int[]> GetParentIdsForTree(string entityTypeCode, int[] ids) => EntityObjectService.GetParentIdsForTree(entityTypeCode, ids);
Example #22
0
 public JsonResult GetArticleLinkedItems(int linkId, int articleId)
 {
     return(Json(EntityObjectService.GetArticleLinkedItems(linkId, articleId)));
 }
Example #23
0
 public JsonNetResult <IEnumerable <EntityInfo> > GetParentInfo(string entityTypeCode, long entityId, long?parentEntityId) => EntityObjectService.GetParentInfo(entityTypeCode, entityId, parentEntityId).ToList();
Example #24
0
 public JsonResult GetArticleIdByFieldValue(int contentId, string fieldName, string fieldValue)
 {
     return(Json(EntityObjectService.GetArticleIdByFieldValue(contentId, fieldName, fieldValue)));
 }
Example #25
0
 public JsonNetResult <Dictionary <int, string> > GetContentFieldValues(int contentId, string fieldName) => EntityObjectService.GetContentFieldValues(contentId, fieldName);
Example #26
0
 public JsonNetResult <bool> CheckExistence(string entityTypeCode, int entityId) => EntityObjectService.CheckExistence(entityTypeCode, entityId);
Example #27
0
 public JsonNetResult <int> GetArticleIdByFieldValue(int contentId, string fieldName, string fieldValue) => EntityObjectService.GetArticleIdByFieldValue(contentId, fieldName, fieldValue);
Example #28
0
 public JsonNetResult <bool> CheckPresenceSelfRelations(string entityTypeCode, int entityId) => EntityObjectService.CheckPresenceSelfRelations(entityTypeCode, entityId);
Example #29
0
 public JsonNetResult <object> AutosaveRestoringCheck([ModelBinder(typeof(JsonStringModelBinder <AutosavedEntityRecordHeader[]>))] AutosavedEntityRecordHeader[] recordHeaders) => new
 {
     success           = true,
     approvedRecordIDs = EntityObjectService.AutosaveRestoringCheck(recordHeaders)
 };
Example #30
0
 public JsonNetResult <bool> CheckForVariations(string entityTypeCode, int entityId) => EntityObjectService.CheckForVariations(entityTypeCode, entityId);