From 48721c85ebcfa973ee81719d2467ca80e4253dc9 Mon Sep 17 00:00:00 2001
From: Jake Vanderwerf <get@jakevanderwerf.ca>
Date: Fri, 01 May 2026 17:30:03 +0000
Subject: [PATCH] =Edmonton Ink hard test begins! Real testing of the managers and reset routes will commence. So far, just ensuring our classes are all loaded correctly: Site() and its sub-classes Membership, Login, etc. Care should be taken to load conditionally on 'init', as we finish defining most settings by 'plugins_loaded' at priority 5

---
 inc/ui/CRUDSkeleton.php |   18 ++++++++++++++----
 1 files changed, 14 insertions(+), 4 deletions(-)

diff --git a/inc/ui/CRUDSkeleton.php b/inc/ui/CRUDSkeleton.php
index 5bb76e4..c62f3a4 100644
--- a/inc/ui/CRUDSkeleton.php
+++ b/inc/ui/CRUDSkeleton.php
@@ -1,6 +1,7 @@
 <?php
 namespace JVBase\ui;
 
+use JVBase\base\Site;
 use JVBase\managers\UserTermsManager;
 use JVBase\meta\Form;
 use JVBase\registrar\Registrar;
@@ -216,7 +217,6 @@
 	 */
 	public function addTaxonomyFilter(array $taxonomies, ?string $limit = null): self {
 		foreach($taxonomies as $taxonomy) {
-			error_log('Fetchinig taxonomy: '.print_r($taxonomy, true));
 			$registrar = Registrar::getInstance($taxonomy);
 
 			if ($registrar) {
@@ -235,7 +235,7 @@
 
 	protected function taxConfig(string $taxonomy, string $label = ''):array
 	{
-		$isVerified = jvbUserIsVerified();
+		$isVerified = $this->userIsVerified();
 		$label = ($label === '') ? Registrar::getInstance($taxonomy)->getPlural() : $label;
 		return [
 			'type'		=> 'taxonomy',
@@ -247,6 +247,13 @@
 		];
 	}
 
+	protected function userIsVerified():bool
+	{
+		$membership = Site::membership();
+
+		return !($membership && $membership->has('member_verified')) || current_user_can('skip_moderation');
+	}
+
 	public function addSearch():self
 	{
 		$this->hasSearch = true;
@@ -902,7 +909,7 @@
 		if ($limit) {
 			if ($limit === 'user') {
 				$manager = new UserTermsManager();
-				return $manager->getUserTerms($this->user_id, $taxonomy);
+				return $manager->fetchUserTerms($this->user_id, $taxonomy);
 			} else {
 				$limit = (int)$limit;
 			}
@@ -1555,7 +1562,10 @@
 			<input type="hidden" name="content" value="<?=$this->dataType?>" />
 			<div class="fields">
 				<?php
-				echo Form::render('post_status', '', $this->getStatusFieldConfig('edit-'));
+				if (!empty($this->statuses)) {
+					echo Form::render('post_status', '', $this->getStatusFieldConfig('edit-'));
+				}
+
 
 
 				if (!empty($this->sections)) {

--
Gitblit v1.10.0