You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

134 lines
8.9 KiB

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<?php
/**
* 高管简历区块模板
*
* @package Nenghui_Energy_Theme
*/
// 防止直接访问
if (!defined('ABSPATH')) {
exit;
}
// 获取区块属性(支持直接调用和短代码调用)
global $executive_profiles_attributes;
// 优先使用全局变量(短代码调用),其次使用直接传入的属性
$current_attributes = !empty($executive_profiles_attributes) ? $executive_profiles_attributes : (isset($attributes) ? $attributes : array());
$block_id = isset($current_attributes['blockId']) ? $current_attributes['blockId'] : 'executive-profiles-' . uniqid();
$theme = isset($current_attributes['theme']) ? $current_attributes['theme'] : 'default';
$title = isset($current_attributes['title']) ? $current_attributes['title'] : '高管团队';
$columns = isset($current_attributes['columns']) ? intval($current_attributes['columns']) : 1;
// 加载样式和脚本
wp_enqueue_style('executive-profiles-style', get_template_directory_uri() . '/assets/css/executive-profiles.css', array(), '1.0.0');
wp_enqueue_script('executive-profiles-script', get_template_directory_uri() . '/assets/js/executive-profiles.js', array('jquery'), '1.0.0', true);
// 处理高管信息,将称谓移到姓名后面(增加函数存在性检查,避免重复声明)
if (!function_exists('format_executive_info')) {
function format_executive_info($name, $title) {
$titles_to_extract = array('博士', '女士', '先生');
$extracted_title = '';
$clean_title = $title;
foreach ($titles_to_extract as $title_prefix) {
if (strpos($title, $title_prefix) !== false) {
$extracted_title = $title_prefix;
$clean_title = trim(str_replace($title_prefix, '', $title));
break;
}
}
$formatted_name = $name . ($extracted_title ? ' ' . $extracted_title : '');
return array(
'name' => $formatted_name,
'title' => $clean_title
);
}
}
// 高管数据
$executives = array(
array(
'name' => '罗传奎',
'title' => '博士 董事长',
'bio' => '1966年9月出生清华大学环境工程专业博士高级工程师上海市普陀区工商联执委上海新沪商联合会轮值主席。1995年2月至2002年2月就职于浙江电力设计院担任设计总工及分公司总经理2002年3月至2008年9月就职于山东三融环保工程有限公司担任副总经理2009年11月至今就职于公司历任公司执行董事、总经理现任公司董事长。'
),
array(
'name' => '温鹏飞',
'title' => '先生 董事、总经理',
'bio' => '1972年9月出生上海交通大学自动化专业学士工程师。1995年9月至2002年5月就职于河南省电力勘测设计院担任设计师2002年6月至2009年1月就职于山东三融环保工程有限公司担任设计总工程师、部门经理、上海分公司总经理2009年11月至今就职于公司历任公司监事、董事、总经理。'
),
array(
'name' => '袁峻巍',
'title' => '先生 董事、副总经理',
'bio' => '1971年10月出生上海交通大学工业工程专业硕士高级工程师。1994年8月至2010年12月就职于上海电力设计院有限公司担任设计部组长2011年2月至今就职于公司现任公司董事、副总经理。'
),
array(
'name' => '张健丁',
'title' => '先生 董事',
'bio' => '1970年4月出生清华大学自动控制专业学士高级工程师。1992年8月至2003年8月就职于山东电力工程咨询院发电工程部担任设计工程师2003年9月至2008年9月就职于山东三融环保工程有限公司历任设计总工程师、上海技术研发中心副总经理2009年11月至今就职于公司历任公司主任设计师、董事、副总经理、财务负责人、董事会秘书现任公司董事。'
),
array(
'name' => '宋月月',
'title' => '女士 董事、财务总监',
'bio' => '1992年11月出生安徽财经大学财务管理专业本科学历注册会计师。2015年7月至2017年5月任大华会计师事务所特殊普通合伙审计员2017年5月至2021年5月任中汇会计师事务所特殊普通合伙审计经理2021年5月至2023年2月任上海煕软科技有限公司财务主管2023年2月至今就职于公司历任财务部经理、财务总监现任公司董事、财务总监。'
),
array(
'name' => '梁勇',
'title' => '先生 职工代表董事',
'bio' => '1979年7月出生中国石油大学华东工程管理专业本科学历。2001年7月至2014年11月任青岛海尔冷柜项目经理、负责人2014年12月至2016年2月任中融新大集团派驻山东物流集团监察部主任2016年3月至2023年2月任青岛昌盛日电太阳能有限公司审计总监、运营总监2021年11月至今任青岛宏博商通安装工程有限公司总经理2023年3月至今任公司高质量发展督导部负责人。'
),
array(
'name' => '王芳',
'title' => '女士 独立董事',
'bio' => '1962年10月出生北京大学经济学硕士日本拓殖大学国际开发博士研究生。历任电子工业部第49研究院助理工程师、黑龙江广播电视大学工程师、黑龙江省教育委员会副研究员、兵器工业部标准化所副研究员、北京国家会计学院教研中心副研究员、浙江华铁应急设备科技股份有限公司独立董事、同策房产咨询股份有限公司独立董事等现任临商银行股份有限公司独立董事、京北方信息技术股份有限公司独立董事2020年5月至今任公司独立董事。'
),
array(
'name' => '张美霞',
'title' => '女士 独立董事',
'bio' => '1969年9月出生上海财经大学会计学专业博士注册会计师。1991年7月至1997年7月就职于山东东营财校担任教师2000年3月至今于上海外国语大学国际金融贸易学院先后任教师、副教授、硕士研究生导师2015年5月至2022年10月任上海麦金地集团股份有限公司独立董事2020年5月至今任公司独立董事。'
),
array(
'name' => '王猛',
'title' => '先生 独立董事',
'bio' => '1982年10月出生北京大学法学学士曾任职于中融国际信托有限公司、北京竞天公诚律师事务所及北京中银律师事务所等现任北京嘉润律师事务所律师、高级合伙人兼任中航直升机股份有限公司独立董事、广东顺威精密塑料股份有限公司独立董事。'
),
array(
'name' => '罗联明',
'title' => '先生 副总经理、董事会秘书',
'bio' => '1971年10月出生上海交通大学安泰经济与管理学院高级管理人员工商管理硕士"上海市鄂州商会"第一届副会长。1998年1月至1999年12月任深圳市迪博企业风险管理技术有限公司咨询顾问2000年1月至2002年10月任湖北多佳股份有限公司董事长秘书2002年11月至2006年1月任武汉维豪信息技术股份有限公司上海基地及其关联公司行政负责人2006年2月至2009年3月为个人投资者2009年4月至2011年8月任上海西芙欧投资管理有限公司执行董事2011年9月至2015年10月任上海开祥幕墙有限公司常务副总经理2015年11月至2016年10月任世富光伏宝上海环保科技股份有限公司董事会秘书2016年11月至今就职于公司现任副总经理兼董事会秘书。'
)
);
?>
<div class="executive-profiles-block theme-<?php echo esc_attr($theme); ?>" id="<?php echo esc_attr($block_id); ?>">
<div class="executive-profiles-container">
<?php if (!empty($title)): ?>
<div class="section-header">
<h2 class="section-title"><?php echo esc_html($title); ?></h2>
</div>
<?php endif; ?>
<div class="executives-grid" data-columns="<?php echo esc_attr($columns); ?>">
<?php foreach ($executives as $index => $executive):
$formatted_info = format_executive_info($executive['name'], $executive['title']);
?>
<div class="executive-card" data-index="<?php echo esc_attr($index); ?>">
<div class="executive-header">
<h3 class="executive-name"><?php echo esc_html($formatted_info['name']); ?></h3>
<p class="executive-title"><?php echo esc_html($formatted_info['title']); ?></p>
</div>
<div class="executive-bio">
<div class="bio-preview">
<?php echo esc_html($executive['bio']); ?>
</div>
</div>
</div>
<?php endforeach; ?>
</div>
</div>
</div>