487 lines
20 KiB
HTML
487 lines
20 KiB
HTML
<!DOCTYPE html>
|
||
<html lang="zh-CN">
|
||
<head>
|
||
<meta charset="UTF-8">
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=no">
|
||
<title>审核详情 - OA系统</title>
|
||
<style>
|
||
* {
|
||
margin: 0;
|
||
padding: 0;
|
||
box-sizing: border-box;
|
||
}
|
||
body {
|
||
font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
|
||
background: #f5f5f5;
|
||
max-width: 414px;
|
||
margin: 0 auto;
|
||
min-height: 100vh;
|
||
padding-bottom: 80px;
|
||
}
|
||
.header {
|
||
background: #1890ff;
|
||
color: white;
|
||
padding: 12px 16px;
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
position: sticky;
|
||
top: 0;
|
||
z-index: 100;
|
||
}
|
||
.header-left {
|
||
display: flex;
|
||
align-items: center;
|
||
gap: 12px;
|
||
}
|
||
.back-btn {
|
||
background: none;
|
||
border: none;
|
||
color: white;
|
||
font-size: 18px;
|
||
cursor: pointer;
|
||
}
|
||
.header-title {
|
||
font-size: 18px;
|
||
font-weight: bold;
|
||
}
|
||
.content {
|
||
padding: 16px;
|
||
background: #ffffff;
|
||
min-height: calc(100vh - 44px - 80px);
|
||
}
|
||
.card {
|
||
background: white;
|
||
border-radius: 8px;
|
||
padding: 16px;
|
||
margin-bottom: 12px;
|
||
box-shadow: 0 2px 8px rgba(0,0,0,0.05);
|
||
}
|
||
.card-title {
|
||
font-size: 16px;
|
||
font-weight: 500;
|
||
color: #333;
|
||
margin-bottom: 12px;
|
||
padding-bottom: 12px;
|
||
border-bottom: 1px solid #f0f0f0;
|
||
}
|
||
.info-row {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
padding: 12px 0;
|
||
border-bottom: 1px solid #f5f5f5;
|
||
}
|
||
.info-row:last-child {
|
||
border-bottom: none;
|
||
}
|
||
.info-label {
|
||
color: #999;
|
||
font-size: 14px;
|
||
}
|
||
.info-value {
|
||
color: #333;
|
||
font-size: 14px;
|
||
font-weight: 500;
|
||
text-align: right;
|
||
}
|
||
.status-badge {
|
||
padding: 4px 10px;
|
||
border-radius: 4px;
|
||
font-size: 12px;
|
||
font-weight: 500;
|
||
}
|
||
.status-pending {
|
||
background: #fff7e6;
|
||
color: #d46b08;
|
||
}
|
||
.form-item {
|
||
margin-bottom: 16px;
|
||
}
|
||
.form-label {
|
||
display: block;
|
||
margin-bottom: 8px;
|
||
color: #333;
|
||
font-size: 14px;
|
||
font-weight: 500;
|
||
}
|
||
.form-textarea {
|
||
width: 100%;
|
||
padding: 12px;
|
||
border: 1px solid #e5e5e5;
|
||
border-radius: 8px;
|
||
font-size: 14px;
|
||
min-height: 100px;
|
||
font-family: inherit;
|
||
resize: vertical;
|
||
}
|
||
.form-textarea:focus {
|
||
outline: none;
|
||
border-color: #1890ff;
|
||
}
|
||
.attachment-list {
|
||
display: flex;
|
||
flex-direction: column;
|
||
gap: 8px;
|
||
}
|
||
.attachment-item {
|
||
display: flex;
|
||
align-items: center;
|
||
justify-content: space-between;
|
||
padding: 12px;
|
||
background: #f5f5f5;
|
||
border-radius: 4px;
|
||
}
|
||
.attachment-name {
|
||
flex: 1;
|
||
color: #333;
|
||
font-size: 14px;
|
||
}
|
||
.attachment-size {
|
||
color: #999;
|
||
font-size: 12px;
|
||
margin-left: 8px;
|
||
}
|
||
.btn-download {
|
||
padding: 4px 12px;
|
||
background: #1890ff;
|
||
color: white;
|
||
border: none;
|
||
border-radius: 4px;
|
||
font-size: 12px;
|
||
cursor: pointer;
|
||
}
|
||
.action-buttons {
|
||
position: fixed;
|
||
bottom: 0;
|
||
left: 50%;
|
||
transform: translateX(-50%);
|
||
width: 100%;
|
||
max-width: 414px;
|
||
padding: 12px 16px;
|
||
background: white;
|
||
border-top: 1px solid #e5e5e5;
|
||
display: flex;
|
||
gap: 12px;
|
||
z-index: 100;
|
||
}
|
||
.btn-action {
|
||
flex: 1;
|
||
padding: 14px;
|
||
border: none;
|
||
border-radius: 8px;
|
||
font-size: 16px;
|
||
font-weight: 500;
|
||
cursor: pointer;
|
||
}
|
||
.btn-approve {
|
||
background: #52c41a;
|
||
color: white;
|
||
}
|
||
.btn-reject {
|
||
background: #ff4d4f;
|
||
color: white;
|
||
}
|
||
.approval-history {
|
||
margin-top: 16px;
|
||
}
|
||
.history-item {
|
||
padding: 12px;
|
||
border-left: 2px solid #e5e5e5;
|
||
margin-bottom: 12px;
|
||
padding-left: 16px;
|
||
}
|
||
.history-header {
|
||
display: flex;
|
||
justify-content: space-between;
|
||
margin-bottom: 8px;
|
||
}
|
||
.history-user {
|
||
font-weight: 500;
|
||
color: #333;
|
||
}
|
||
.history-time {
|
||
font-size: 12px;
|
||
color: #999;
|
||
}
|
||
.history-action {
|
||
font-size: 14px;
|
||
color: #666;
|
||
margin-bottom: 4px;
|
||
}
|
||
.history-comment {
|
||
font-size: 14px;
|
||
color: #999;
|
||
font-style: italic;
|
||
}
|
||
</style>
|
||
</head>
|
||
<body>
|
||
<div class="header">
|
||
<div class="header-left">
|
||
<button class="back-btn" onclick="history.back()">←</button>
|
||
<div class="header-title">审核详情</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="content">
|
||
<div class="card">
|
||
<div class="card-title">项目信息</div>
|
||
<div class="info-row">
|
||
<span class="info-label">项目编号</span>
|
||
<span class="info-value">25-1</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">项目名称</span>
|
||
<span class="info-value">XX工程项目</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">客户名称</span>
|
||
<span class="info-value">XX公司</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">服务内容</span>
|
||
<span class="info-value">工程咨询</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">预计金额</span>
|
||
<span class="info-value">¥500,000</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">申请人</span>
|
||
<span class="info-value">张三</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">申请时间</span>
|
||
<span class="info-value">2025-01-15 14:30</span>
|
||
</div>
|
||
<div class="info-row">
|
||
<span class="info-label">当前状态</span>
|
||
<span class="info-value"><span class="status-badge status-pending">待审核</span></span>
|
||
</div>
|
||
</div>
|
||
|
||
<!-- 多人提交状态(仅成果审核显示) -->
|
||
<div class="card" id="multiSubmitStatus" style="display: none;">
|
||
<div class="card-title">多人提交状态</div>
|
||
<div style="background: #f5f7fa; padding: 12px; border-radius: 8px;">
|
||
<div style="margin-bottom: 8px; font-size: 13px;">
|
||
<strong>已分配人员:</strong>
|
||
<span id="allStaffList">张三、李四、王五</span>
|
||
</div>
|
||
<div style="margin-bottom: 8px; font-size: 13px;">
|
||
<strong>已提交人员:</strong>
|
||
<span id="submittedStaffList" style="color: #52c41a;">张三、李四</span>
|
||
</div>
|
||
<div style="margin-bottom: 12px; font-size: 13px;">
|
||
<strong>待提交人员:</strong>
|
||
<span id="pendingStaffList" style="color: #ff4d4f;">王五</span>
|
||
</div>
|
||
<div style="background: #fff7e6; padding: 8px; border-radius: 4px; font-size: 12px; color: #d46b08;">
|
||
💡 等待所有人员提交完成后,将自动进入组长审核环节
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<!-- 审核流程(成果审核显示) -->
|
||
<div class="card" id="approvalProcess" style="display: none;">
|
||
<div class="card-title">审核流程</div>
|
||
<div id="processContent"></div>
|
||
</div>
|
||
|
||
<div class="card">
|
||
<div class="card-title">项目描述</div>
|
||
<div style="color: #666; font-size: 14px; line-height: 1.6;">
|
||
本项目为XX公司的工程咨询项目,预计金额50万元,包含前期咨询、方案设计等内容。
|
||
</div>
|
||
</div>
|
||
|
||
<div class="card">
|
||
<div class="card-title">附件</div>
|
||
<div class="attachment-list">
|
||
<div class="attachment-item">
|
||
<div>
|
||
<div class="attachment-name">项目立项申请表.pdf</div>
|
||
<div class="attachment-size">2.5MB</div>
|
||
</div>
|
||
<button class="btn-download">下载</button>
|
||
</div>
|
||
<div class="attachment-item">
|
||
<div>
|
||
<div class="attachment-name">项目需求文档.doc</div>
|
||
<div class="attachment-size">1.2MB</div>
|
||
</div>
|
||
<button class="btn-download">下载</button>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="card">
|
||
<div class="card-title">审核历史</div>
|
||
<div class="approval-history">
|
||
<div class="history-item">
|
||
<div class="history-header">
|
||
<span class="history-user">张三</span>
|
||
<span class="history-time">2025-01-15 14:30</span>
|
||
</div>
|
||
<div class="history-action">提交申请</div>
|
||
<div class="history-comment">已提交立项申请,请审核</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="card">
|
||
<div class="card-title">审核意见</div>
|
||
<div class="form-item">
|
||
<textarea class="form-textarea" placeholder="请输入审核意见(可选)" id="approvalComment"></textarea>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="action-buttons">
|
||
<button class="btn-action btn-approve" onclick="approve()">通过</button>
|
||
<button class="btn-action btn-reject" onclick="reject()">驳回</button>
|
||
</div>
|
||
|
||
<script>
|
||
// 页面加载时初始化
|
||
window.onload = function() {
|
||
// 从URL参数获取审核类型(这里用模拟数据)
|
||
const urlParams = new URLSearchParams(window.location.search);
|
||
const approvalType = urlParams.get('type') || 'initiation'; // initiation, start, output
|
||
const outputType = urlParams.get('outputType') || 'draft'; // draft, reconciliation, final
|
||
|
||
// 如果是成果审核,显示多人提交状态和审核流程
|
||
if (approvalType === 'output') {
|
||
showMultiSubmitStatus();
|
||
showApprovalProcess(outputType);
|
||
}
|
||
};
|
||
|
||
// 显示多人提交状态
|
||
function showMultiSubmitStatus() {
|
||
const multiSubmitStatus = document.getElementById('multiSubmitStatus');
|
||
if (multiSubmitStatus) {
|
||
multiSubmitStatus.style.display = 'block';
|
||
// 模拟数据,实际应从后端获取
|
||
document.getElementById('allStaffList').textContent = '张三、李四、王五';
|
||
document.getElementById('submittedStaffList').textContent = '张三、李四';
|
||
document.getElementById('pendingStaffList').textContent = '王五';
|
||
}
|
||
}
|
||
|
||
// 显示审核流程
|
||
function showApprovalProcess(outputType) {
|
||
const approvalProcess = document.getElementById('approvalProcess');
|
||
const processContent = document.getElementById('processContent');
|
||
|
||
if (!approvalProcess || !processContent) return;
|
||
|
||
approvalProcess.style.display = 'block';
|
||
|
||
if (outputType === 'final') {
|
||
// 最终成果需要双领导审核
|
||
processContent.innerHTML = `
|
||
<div style="padding: 12px 0; border-bottom: 1px solid #f0f0f0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #52c41a; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">✓</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">多人提交成果</div>
|
||
<div style="font-size: 12px; color: #999; margin-top: 4px;">张三、李四、王五已全部提交</div>
|
||
<div style="font-size: 11px; color: #999; margin-top: 4px;">2025-01-15 10:30</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div style="padding: 12px 0; border-bottom: 1px solid #f0f0f0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #52c41a; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">✓</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">组长审核</div>
|
||
<div style="font-size: 12px; color: #999; margin-top: 4px;">审核人:项目组长 | 审核通过</div>
|
||
<div style="font-size: 11px; color: #999; margin-top: 4px;">2025-01-15 11:00</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div style="padding: 12px 0; border-bottom: 1px solid #f0f0f0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #1890ff; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">●</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">领导审核(王总)</div>
|
||
<div style="font-size: 12px; color: #1890ff; margin-top: 4px;">当前审核节点 | 待审核</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div style="padding: 12px 0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #d9d9d9; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">○</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">领导审核(戚总)</div>
|
||
<div style="font-size: 12px; color: #999; margin-top: 4px;">等待王总审核通过</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
`;
|
||
} else {
|
||
// 初稿/对账审核流程
|
||
processContent.innerHTML = `
|
||
<div style="padding: 12px 0; border-bottom: 1px solid #f0f0f0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #52c41a; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">✓</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">多人提交成果</div>
|
||
<div style="font-size: 12px; color: #999; margin-top: 4px;">张三、李四、王五已全部提交</div>
|
||
<div style="font-size: 11px; color: #999; margin-top: 4px;">2025-01-15 10:30</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div style="padding: 12px 0; border-bottom: 1px solid #f0f0f0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #52c41a; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">✓</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">组长审核</div>
|
||
<div style="font-size: 12px; color: #999; margin-top: 4px;">审核人:项目组长 | 审核通过</div>
|
||
<div style="font-size: 11px; color: #999; margin-top: 4px;">2025-01-15 11:00</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div style="padding: 12px 0;">
|
||
<div style="display: flex; align-items: center; margin-bottom: 8px;">
|
||
<span style="width: 24px; height: 24px; background: #1890ff; color: white; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; margin-right: 12px;">●</span>
|
||
<div style="flex: 1;">
|
||
<div style="font-weight: 500; color: #333; font-size: 14px;">总经理审核(王总)</div>
|
||
<div style="font-size: 12px; color: #1890ff; margin-top: 4px;">当前审核节点 | 待审核</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
`;
|
||
}
|
||
}
|
||
|
||
function approve() {
|
||
const comment = document.getElementById('approvalComment').value;
|
||
if (confirm('确认通过审核?')) {
|
||
alert('审核通过!');
|
||
setTimeout(() => {
|
||
window.location.href = 'todo.html';
|
||
}, 1000);
|
||
}
|
||
}
|
||
|
||
function reject() {
|
||
const comment = document.getElementById('approvalComment').value;
|
||
if (!comment.trim()) {
|
||
alert('驳回时请输入驳回原因');
|
||
document.getElementById('approvalComment').focus();
|
||
return;
|
||
}
|
||
if (confirm('确认驳回申请?')) {
|
||
alert('已驳回:' + comment);
|
||
setTimeout(() => {
|
||
window.location.href = 'todo.html';
|
||
}, 1000);
|
||
}
|
||
}
|
||
</script>
|
||
</body>
|
||
</html>
|
||
|