在线样例
左侧浏览样例目录,右侧查看版式预览与示例代码;点击运行即可通过 web-print-pdf 驱动本地客户端完成静默打印或 PDF 预览。使用前请先 安装并启动客户端。
客户端
若打印或预览效果与预期不符,请务必先从官网下载并安装最新版 Web打印专家客户端后再试(旧版本可能导致版式偏差)。
版式说明
版式预览与打印输出完全遵循 HTML/CSS 标准样式,没有隐藏的渲染技巧:样式写成什么样,页面就长成什么样。
80 - 新员工入职调研问卷
新员工入职调研问卷打印样例。
版式预览
示例代码
const html = `<!DOCTYPE html>
<html lang="zh-CN">
<head>
<meta charset="UTF-8">
<title>新员工入职调研问卷</title>
<style>
html, body { margin: 0; padding: 0; }
.biz-sheet {
position: relative;
width: 794px;
height: 1123px;
box-sizing: border-box;
background: #fff;
font-family: "Microsoft YaHei", "PingFang SC", sans-serif;
color: #0F172A;
overflow: hidden;
}
</style>
</head>
<body>
<div class="biz-sheet">
<div style="position:absolute;left:48px;top:52px;width:300px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;font-weight:700;color:#10B981;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">ONBOARDING SURVEY</div>
<div style="position:absolute;left:548px;top:66px;width:198px;height:18px;box-sizing:border-box;overflow:hidden;font-size:10px;font-weight:600;color:#0F172A;text-align:right;display:flex;align-items:center;justify-content:flex-end;white-space:pre-wrap">刘洋</div>
<div style="position:absolute;left:48px;top:70px;width:460px;height:34px;box-sizing:border-box;overflow:hidden;font-size:22px;font-weight:700;color:#0F172A;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">新员工入职调研问卷</div>
<div style="position:absolute;left:548px;top:88px;width:198px;height:18px;box-sizing:border-box;overflow:hidden;font-size:10px;color:#0F172A;text-align:right;display:flex;align-items:center;justify-content:flex-end;white-space:pre-wrap">产品设计部</div>
<div style="position:absolute;left:548px;top:110px;width:198px;height:18px;box-sizing:border-box;overflow:hidden;font-size:10px;color:#64748B;text-align:right;display:flex;align-items:center;justify-content:flex-end;white-space:pre-wrap">2026-09-01</div>
<div style="position:absolute;left:48px;top:140px;width:698px;height:66px;box-sizing:border-box;overflow:hidden;background:#ECFDF5"></div>
<div style="position:absolute;left:121px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;background:#10B981"></div>
<div style="position:absolute;left:121px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;font-size:10px;font-weight:700;color:#FFFFFF;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">1</div>
<div style="position:absolute;left:296px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;background:#10B981"></div>
<div style="position:absolute;left:296px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;font-size:10px;font-weight:700;color:#FFFFFF;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">2</div>
<div style="position:absolute;left:470px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;background:#10B981"></div>
<div style="position:absolute;left:470px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;font-size:10px;font-weight:700;color:#FFFFFF;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">3</div>
<div style="position:absolute;left:645px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;background:#10B981"></div>
<div style="position:absolute;left:645px;top:150px;width:28px;height:28px;box-sizing:border-box;overflow:hidden;font-size:10px;font-weight:700;color:#FFFFFF;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">4</div>
<div style="position:absolute;left:153px;top:163px;width:139px;height:1px;box-sizing:border-box;overflow:hidden;background:#6EE7B7"></div>
<div style="position:absolute;left:328px;top:163px;width:138px;height:1px;box-sizing:border-box;overflow:hidden;background:#6EE7B7"></div>
<div style="position:absolute;left:502px;top:163px;width:139px;height:1px;box-sizing:border-box;overflow:hidden;background:#6EE7B7"></div>
<div style="position:absolute;left:99px;top:184px;width:72px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#065F46;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">入职手续</div>
<div style="position:absolute;left:274px;top:184px;width:72px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#065F46;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">岗前培训</div>
<div style="position:absolute;left:448px;top:184px;width:72px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#065F46;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">团队融入</div>
<div style="position:absolute;left:623px;top:184px;width:72px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#065F46;text-align:center;display:flex;align-items:center;justify-content:center;white-space:pre-wrap">岗位适应</div>
<div style="position:absolute;left:48px;top:240px;width:330px;height:16px;box-sizing:border-box;overflow:hidden;font-size:10px;color:#0F172A;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">01 入职手续办理是否顺畅?</div>
<div style="position:absolute;left:416px;top:240px;width:330px;height:16px;box-sizing:border-box;overflow:hidden;font-size:10px;color:#0F172A;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">02 岗前培训对您帮助大吗?</div>
<div style="position:absolute;left:48px;top:262px;width:330px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#475569;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">○ 非常顺畅 ○ 顺畅 ○ 一般 ○ 繁琐</div>
<div style="position:absolute;left:416px;top:262px;width:330px;height:14px;box-sizing:border-box;overflow:hidden;font-size:8.5px;color:#475569;display:flex;align-items:center;justify-content:flex-start;white-space:pre-wrap">○ 帮助很大 ○ 有帮助 ○ 一般 ○ 很小</div>
<div style="position:absolute;left:48px;top:340px;width:330px;height:16px;box-sizing:border-box;overflow:hidde
// …
运行结果
- 若无法打印或连接客户端失败,请参阅 本地Print succeeded,上线后无法打印?(HTTP 业务系统上线后常见)。
- 客户端内置「运行示例」页(
vueApp/.../examples/index.vue)提供更多可编辑 demo,与本页样例互补。 - 工具类样例(连接检测、打印机列表等)仅返回 JSON,不触发打印。