Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issue #39. Create default views. #43

Merged
merged 1 commit into from
Dec 29, 2023
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
162 changes: 162 additions & 0 deletions modules/flag_bookmark/config/views.view.flag_bookmarks.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,162 @@
{
"_config_name": "views.view.flag_bookmarks",
"name": "flag_bookmarks",
"description": "A page listing the current user's bookmarks at /bookmarks.",
"tag": "flag",
"disabled": false,
"base_table": "node",
"human_name": "Flag bookmarks",
"core": 0,
"display": {
"default": {
"display_title": "Defaults",
"display_plugin": "default",
"display_options": {
"query": {
"type": "views_query",
"options": []
},
"title": "My bookmarks",
"use_more_always": false,
"access": {
"type": "perm",
"perm": "flag bookmarks"
},
"cache": {
"type": "none"
},
"exposed_form": {
"type": "basic"
},
"pager": {
"type": "full",
"options": {
"items_per_page": "25"
}
},
"style_plugin": "table",
"style_options": {
"grouping": "",
"columns": {
"type": "type",
"title": "title",
"name": "name",
"comment_count": "comment_count",
"last_comment_timestamp": "last_comment_timestamp",
"ops": "ops"
},
"default": "last_comment_timestamp",
"info": {
"type": {
"sortable": true
},
"title": {
"sortable": true
},
"name": {
"sortable": true
},
"comment_count": {
"sortable": true
},
"last_comment_timestamp": {
"sortable": true
}
},
"override": false,
"sticky": true,
"order": "desc"
},
"empty": {
"text": {
"id": "area",
"table": "views",
"field": "area",
"content": "You have not yet bookmarked any content. Click the \"Bookmark this\" link when viewing a piece of content to add it to this list.",
"format": "plain_text"
}
},
"relationships": {
"flag_content_rel": {
"id": "flag_content_rel",
"table": "node",
"field": "flag_content_rel",
"label": "bookmarks",
"flag": "bookmarks"
},
"uid_1": {
"id": "uid_1",
"table": "node",
"field": "uid"
}
},
"fields": {
"type": {
"id": "type",
"table": "node",
"field": "type"
},
"title": {
"id": "title",
"table": "node",
"field": "title"
},
"name": {
"id": "name",
"table": "users",
"field": "name",
"relationship": "uid_1",
"label": "Author"
},
"comment_count": {
"id": "comment_count",
"table": "node_comment_statistics",
"field": "comment_count",
"label": "Replies"
},
"last_comment_timestamp": {
"id": "last_comment_timestamp",
"table": "node_comment_statistics",
"field": "last_comment_timestamp",
"label": "Last Post"
},
"ops": {
"id": "ops",
"table": "flagging",
"field": "ops",
"relationship": "flag_content_rel",
"label": "Ops"
}
},
"filters": {
"status": {
"id": "status",
"table": "node",
"field": "status",
"value": 1,
"group": "0",
"expose": {
"operator": false
}
}
}
}
},
"page": {
"display_title": "Page",
"display_plugin": "page",
"display_options": {
"query": {
"type": "views_query",
"options": []
},
"path": "bookmarks",
"menu": {
"type": "normal",
"title": "My bookmarks",
"weight": "0"
}
}
}
}
}
185 changes: 185 additions & 0 deletions modules/flag_bookmark/config/views.view.flag_bookmarks_tab.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,185 @@
{
"_config_name": "views.view.flag_bookmarks_tab",
"name": "flag_bookmarks_tab",
"description": "Provides a tab on all users' profile pages containing bookmarks for that user.",
"tag": "flag",
"disabled": false,
"base_table": "node",
"human_name": "Flag bookmarks tab",
"core": 0,
"display": {
"default": {
"display_title": "Defaults",
"display_plugin": "default",
"display_options": {
"query": {
"type": "views_query",
"options": []
},
"title": "User bookmarks",
"use_more_always": false,
"access": {
"type": "perm",
"perm": "flag bookmarks"
},
"cache": {
"type": "none"
},
"exposed_form": {
"type": "basic"
},
"pager": {
"type": "full",
"options": {
"items_per_page": "25"
}
},
"style_plugin": "table",
"style_options": {
"grouping": "",
"columns": {
"type": "type",
"title": "title",
"name": "name",
"comment_count": "comment_count",
"last_comment_timestamp": "last_comment_timestamp"
},
"default": "last_comment_timestamp",
"info": {
"type": {
"sortable": true
},
"title": {
"sortable": true
},
"name": {
"sortable": true
},
"comment_count": {
"sortable": true
},
"last_comment_timestamp": {
"sortable": true
}
},
"override": false,
"sticky": true,
"order": "desc"
},
"empty": {
"text": {
"id": "area",
"table": "views",
"field": "area",
"content": "This user has not yet bookmarked any content.",
"format": "plain_text"
}
},
"relationships": {
"flag_content_rel": {
"id": "flag_content_rel",
"table": "node",
"field": "flag_content_rel",
"label": "bookmarks",
"flag": "bookmarks",
"user_scope": "any"
},
"uid_1": {
"id": "uid_1",
"table": "node",
"field": "uid"
},
"uid": {
"id": "uid",
"table": "flagging",
"field": "uid",
"relationship": "flag_content_rel",
"label": "bookmarks_user",
"required": true
}
},
"fields": {
"type": {
"id": "type",
"table": "node",
"field": "type"
},
"title": {
"id": "title",
"table": "node",
"field": "title"
},
"name": {
"id": "name",
"table": "users",
"field": "name",
"relationship": "uid_1",
"label": "Author"
},
"comment_count": {
"id": "comment_count",
"table": "node_comment_statistics",
"field": "comment_count",
"label": "Replies"
},
"last_comment_timestamp": {
"id": "last_comment_timestamp",
"table": "node_comment_statistics",
"field": "last_comment_timestamp",
"label": "Last Post"
}
},
"arguments": {
"uid": {
"id": "uid",
"table": "users",
"field": "uid",
"relationship": "uid",
"default_action": "empty",
"exception": {
"value": ""
},
"title_enable": true,
"title": "%1's bookmarks",
"default_argument_type": "fixed",
"summary": {
"format": "default_summary"
},
"specify_validation": true,
"validate": {
"type": "flag_bookmark_plugin_owner_perm"
}
}
},
"filters": {
"status": {
"id": "status",
"table": "node",
"field": "status",
"value": 1,
"group": "0",
"expose": {
"operator": false
}
}
}
}
},
"page": {
"display_title": "Page",
"display_plugin": "page",
"display_options": {
"query": {
"type": "views_query",
"options": []
},
"path": "user/%/bookmarks",
"menu": {
"type": "tab",
"title": "Bookmarks",
"weight": "0"
}
}
}
}
}
Loading