diff --git a/includes/Capability.php b/includes/Capability.php new file mode 100644 index 00000000..342e8025 --- /dev/null +++ b/includes/Capability.php @@ -0,0 +1,47 @@ + true, + 'delete_others_docs' => true, + 'delete_private_docs' => true, + ); + + if ( wedocs_pro_exists() ) { + $permitted_roles = wedocs_get_permission_settings( 'global_permission', [ 'administrator', 'editor' ] ); + } + + $has_role = array_intersect( $user->roles, $permitted_roles ); + + if ( ! empty( $user->roles ) && ! empty( $has_role ) ) { + $all_caps = array_merge( $all_caps, $delete_caps ); + } + + return $all_caps; + } +} diff --git a/languages/wedocs.pot b/languages/wedocs.pot index cb8915da..3aee9167 100644 --- a/languages/wedocs.pot +++ b/languages/wedocs.pot @@ -2,7 +2,7 @@ # This file is distributed under the GPL2. msgid "" msgstr "" -"Project-Id-Version: weDocs 2.1.6\n" +"Project-Id-Version: weDocs 2.1.7\n" "Report-Msgid-Bugs-To: https://wordpress.org/support/plugin/wedocs-plugin\n" "Last-Translator: FULL NAME \n" "Language-Team: LANGUAGE \n" diff --git a/package.json b/package.json index 12a70d5c..09c4dbdb 100644 --- a/package.json +++ b/package.json @@ -1,6 +1,6 @@ { "name": "weDocs", - "version": "2.1.6", + "version": "2.1.7", "description": "A documentation plugin for WordPress", "author": "Tareq Hasan", "license": "GPL", diff --git a/readme.md b/readme.md index 2ee253b6..14cf8d49 100644 --- a/readme.md +++ b/readme.md @@ -2,7 +2,7 @@ The documentation plugin for WordPress. Create great looking documentation for your products. -![WordPress Plugin Version](https://img.shields.io/badge/PLUGIN_VERSION-V2.1.6-blue) ![WordPress Plugin Active Installs](https://img.shields.io/badge/ACTIVE_INSTALLS-6K-green) ![WordPress Plugin Rating](https://img.shields.io/badge/RATING-4.8/5_(61)-green) ![WordPress Plugin: Tested WP Version](https://img.shields.io/badge/WORDPRESS-V6.5_TESTED-orange) ![WordPress Plugin Last Updated](https://img.shields.io/badge/LAST_UPDATED-May_2024-orange) +![WordPress Plugin Version](https://img.shields.io/badge/PLUGIN_VERSION-V2.1.7-blue) ![WordPress Plugin Active Installs](https://img.shields.io/badge/ACTIVE_INSTALLS-6K-green) ![WordPress Plugin Rating](https://img.shields.io/badge/RATING-4.8/5_(61)-green) ![WordPress Plugin: Tested WP Version](https://img.shields.io/badge/WORDPRESS-V6.5_TESTED-orange) ![WordPress Plugin Last Updated](https://img.shields.io/badge/LAST_UPDATED-Aug_2024-orange) ## Description ## diff --git a/readme.txt b/readme.txt index bd6cfce0..0cd08321 100644 --- a/readme.txt +++ b/readme.txt @@ -1,11 +1,11 @@ -=== weDocs - Knowledgebase, Documentation, and Wiki for WP === +=== weDocs - Knowledgebase, Documentation, and Wiki Plugin for WP === Contributors: tareq1988, wedevs Donate link: http://wedocs.co/ Tags: WordPress documentation plugin, WordPress docs plugin, Documentation, Knowledge base, Wiki Requires at least: 5.6 Tested up to: 6.5.3 Requires PHP: 7.4 -Stable tag: 2.1.6 +Stable tag: 2.1.7 License: GPLv2 or later License URI: https://www.gnu.org/licenses/gpl-2.0.html Discover weDocs, the ultimate WordPress documentation plugin. Easily create, manage, and organize content with seamless integration and a user-friendly interface. @@ -20,7 +20,7 @@ Documentation has never been this fun on WordPress! Discover **weDocs**, the ult ![Screenshot of weDocs Dashboard](https://wedocs.co/wp-content/uploads/2024/02/Dashboard.png) -πŸŽ‰ ⭐ [Upgrade to weDocs Pro now!](https://wedocs.co/pricing/) πŸŽ‰ ⭐ +πŸš€ πŸ”₯ [Upgrade to weDocs Pro now and supercharge your documentation experience!](https://wedocs.co/pricing/) πŸš€ πŸ”₯ weDocs is a comprehensive knowledgebase (KB Articles) and documentation plugin for WordPress. Create great-looking documentation and organize it beautifully on your website. @@ -49,7 +49,8 @@ Let’s check out what Mr. Web shared about weDocs > πŸ‘ β€œIn one word: amazing. This plugin does what it says. I encountered no problems and found it extremely easy to work with. I recommend this to anyone who wants to set up solid product documentation.” - [Drazen Bebic](https://profiles.wordpress.org/drazenbebic/) -πŸŽ‰ ⭐ [Upgrade to weDocs Pro now!](https://wedocs.co/pricing/) πŸŽ‰ ⭐ + +πŸŽ‰ ⭐ [Upgrade to weDocs Pro now and supercharge your documentation experience!](https://wedocs.co/pricing/) πŸŽ‰ ⭐ ## 🌐 weDocs Free Features at a glance @@ -118,8 +119,17 @@ Admins can secure specific articles, ensuring exclusive editing access for thems πŸ€– An AI-assisted chatbot with ChatGPT Experience the magic of weDocs AI Chat, powered by ChatGPT. This feature unlocks a smarter, more intuitive ChatBot, leveraging ChatGPT's advanced AI with document-backed responses, quick understanding of queries, and fast, accurate answers. Enhance customer support with 24/7 availability, reduced workload on routine queries, and continuous learning for improved responses over time. + + πŸŽ‰ ⭐ [Upgrade to weDocs Pro now and supercharge your documentation experience!](https://wedocs.co/pricing/) πŸŽ‰ ⭐ + + +πŸ“‚ Smart article suggestions +Give instant access to the most relevant articles on the Assistant Widget's Explore Tab. weDocs combines manual curation and analytics to bring you the most helpful content, making your experience seamless and efficient. + + + πŸ” Instant search with the assistant widget Assist users in finding solutions promptly with our robust search feature, which promptly delivers relevant articles based on their inquiries. @@ -155,7 +165,18 @@ A. It fetches the data from your already-written articles on your WordPress site = Can I customize the URL structure of my documentation pages? = A. Yes, weDocs allows you to customize the URL structure of your documentation pages. You can set up custom permalinks and choose a URL structure that suits your requirements, making it easier for users to navigate your documentation. -# Others + + + +πŸŽ‰ ⭐ [Upgrade to weDocs Pro now and supercharge your documentation experience!](https://wedocs.co/pricing/) πŸŽ‰ ⭐ + + + +πŸš€ People behind this awesome documentation plugin + +This powerful knowledge plugin is developed by the people behind [weDevs](https://wedevs.com/), a dedicated team that creates amazing stuff with a customer happiness of more than 425k+. + +# Others: 1. Download the weDocs plugin from the WordPress.org repository or the official website. @@ -216,6 +237,10 @@ Can’t wait to join us? == Changelog == += v2.1.7 (22th Aug, 2024) = + +* **Fix:** Move To Trash option not available for users with the Editor role. + = v2.1.6 (24th May, 2024) = * **Feature:** Add search block for documentation page. diff --git a/wedocs.php b/wedocs.php index bc2aa510..635d875d 100644 --- a/wedocs.php +++ b/wedocs.php @@ -3,7 +3,7 @@ Plugin Name: weDocs Plugin URI: https://wedocs.co/ Description: A documentation plugin for WordPress -Version: 2.1.6 +Version: 2.1.7 Author: weDevs Author URI: https://wedocs.co/?utm_source=wporg&utm_medium=banner&utm_campaign=author-uri License: GPL2 @@ -39,6 +39,7 @@ // don't call the file directly use Appsero\Client; +use WeDevs\WeDocs\Capability; if ( ! defined( 'ABSPATH' ) ) { exit; @@ -58,7 +59,7 @@ final class WeDocs { * * @var string */ - const VERSION = '2.1.6'; + const VERSION = '2.1.7'; /** * The plugin url. @@ -207,6 +208,7 @@ public function init_classes() { $this->container['assets'] = new WeDevs\WeDocs\Assets(); $this->container['migrate'] = new WeDevs\WeDocs\Admin\Migrate(); $this->container['upgrader'] = new WeDevs\WeDocs\Upgrader\Upgrader(); + $this->container['capability'] = new Capability(); } /**