PluginProbe
Taskbuilder – Project Management & Task Management Tool With Kanban Board / 6.0.6
Taskbuilder – Project Management & Task Management Tool With Kanban Board v6.0.6
6.0.6 6.0.5 6.0.2 6.0.3 6.0.4 6.0.1 6.0.0 5.0.8 5.0.9 4.0.9 5.0.0 5.0.1 5.0.2 5.0.3 5.0.4 5.0.5 5.0.6 5.0.7 trunk 1.0.0 1.0.1 1.0.2 1.0.3 1.0.4 1.0.5 All 58 releases
← All changes | includes/admin/projects/open_project/wppm_update_archive_project.php +14 -14 6.0.26.0.6 View file →
@@ -1,15 +1,15 @@
1 -<?php
2 -if ( ! defined( 'ABSPATH' ) ) {
3 - exit; // Exit if accessed directly
4 -}
5 -global $current_user, $wppmfunction ,$wpdb;
6 -$project_id = isset($_POST['project_id']) ? absint(sanitize_text_field(wp_unslash($_POST['project_id']))) : 0 ;
7 -$project_data = $wppmfunction->get_project($project_id);
8 -$wppm_current_user_capability = get_user_meta( $current_user->ID, 'wppm_capability', true );
9 -$is_archived = (isset($_POST['is_archived']) && absint(sanitize_text_field(wp_unslash($_POST['is_archived']))) == 1) ? 0 : 1 ;
10 -if( $wppm_current_user_capability == 'wppm_admin' || $current_user->has_cap('manage_options') || $project_data['created_by']==$current_user->ID){
11 - $values=array(
12 - 'is_archived'=>$is_archived
13 - );
14 - $wpdb->update($wpdb->prefix.'wppm_project', $values, array('id'=>$project_id));
1 +<?php
2 +if ( ! defined( 'ABSPATH' ) ) {
3 + exit; // Exit if accessed directly
4 +}
5 +global $current_user, $wppmfunction ,$wpdb;
6 +$project_id = isset($_POST['project_id']) ? absint(sanitize_text_field(wp_unslash($_POST['project_id']))) : 0 ;
7 +$project_data = $wppmfunction->get_project($project_id);
8 +$wppm_current_user_capability = get_user_meta( $current_user->ID, 'wppm_capability', true );
9 +$is_archived = (isset($_POST['is_archived']) && absint(sanitize_text_field(wp_unslash($_POST['is_archived']))) == 1) ? 0 : 1 ;
10 +if( $wppm_current_user_capability == 'wppm_admin' || $current_user->has_cap('manage_options') || $project_data['created_by']==$current_user->ID){
11 + $values=array(
12 + 'is_archived'=>$is_archived
13 + );
14 + $wpdb->update($wpdb->prefix.'wppm_project', $values, array('id'=>$project_id));
15 15 }