| | |
| | | namespace JVBase\managers\queue\executors; |
| | | |
| | | use JVBase\managers\CustomTable; |
| | | use JVBase\managers\NotificationManager; |
| | | use JVBase\managers\queue\Executor; |
| | | use JVBase\managers\queue\Operation; |
| | | use JVBase\managers\queue\Progress; |
| | |
| | | $term = get_term($termID, jvbCheckBase($taxonomy)); |
| | | $user = get_userdata($userID); |
| | | |
| | | foreach ($managers as $managerID) { |
| | | NotificationManager::getInstance()->addNotification( |
| | | $managerID, |
| | | //TODO: Check this |
| | | NotificationManager::getInstance()->notify( |
| | | $managers, |
| | | $notificationType, |
| | | $userID, |
| | | [ |
| | | 'user_id' => $userID, |
| | | 'user_name' => $user ? $user->display_name : 'Unknown', |
| | | 'term_id' => $termID, |
| | | 'term_name' => $term && !is_wp_error($term) ? $term->name : 'Unknown', |
| | | 'taxonomy' => $taxonomy |
| | | 'target_id' => $termID, |
| | | 'target_type' => $taxonomy |
| | | ] |
| | | ); |
| | | } |
| | | |
| | | } |
| | | } |