常见问题
问:报名时的岗位列表设置的 JSON 有什么要求?
答:JSON模式主要为高级用户提供,可灵活自定义报名字段的灵活配置,说明如下:
岗位列表的 JSON 简单示例(节选结构)
[
{
"job_name": "2026001-舞蹈演员",
"job_desc": "主要从事舞蹈表演相关工作;\n您可以多行自主编辑。"
},
{
"job_name": "2026002-打击乐演奏员",
"job_desc": "主要从事乐器演奏(打击类乐器方向)相关工作;\n您可以多行自主编辑。"
},
{
"job_name": "2026003-弦乐类演奏员",
"job_desc": "主要从事乐器演奏(弦乐类乐器方向)相关工作;\n您可以多行自主编辑。"
}
]
问:报名时的字段设置的 JSON 有什么要求?
答:JSON模式主要为高级用户提供,可灵活自定义报名字段的灵活配置,说明如下:
报名字段的 JSON 简单示例(节选结构)
{
"sections": [
{
"id": "basic",
"title": "基本信息",
"fields": [
{ "key": "user_name", "label": "姓名", "type": "text", "required": true, "minLength": 2, "maxLength": 20 },
{ "key": "gender", "label": "性别", "type": "select", "required": true, "options": [{ "value": "1", "label": "男" }, { "value": "0", "label": "女" }] },
{ "key": "user_mobile", "label": "手机", "type": "text", "required": true, "minLength": 11, "maxLength": 11 }
]
},
{
"id": "education",
"title": "教育经历",
"type": "repeat",
"bind": "educations",
"min": 1,
"max": 5,
"itemFields": [
{ "key": "school", "label": "学校", "type": "text", "required": true, "minLength": 4, "maxLength": 30 },
{ "key": "level", "label": "学历", "type": "text", "required": true, "minLength": 2, "maxLength": 20, "hint": "如:本科、硕士研究生" }
]
},
{
"id": "attachments",
"title": "附件上传",
"fields": [
{ "key": "photo", "label": "一寸照片", "type": "file", "accept": "image/jpeg,image/png,image/jpg", "required": true, "maxFileSizeMb": 1 }
]
}
]
}
2、结构说明
不使用「可重复」时,不写 type: "repeat",在该区块对象里使用 fields 数组列出字段。
区块常用键:id(区块标识,如 basic)、title(展示标题)。
每条字段为对象,常用键包括:
key:字段名,与表单、存档中的键一致。label:展示给考生的标签文案。type:text(单行)、textarea(多行)、select(下拉)、file(附件)。required:是否必填(布尔)。minLength/maxLength:仅用于text、textarea的字符数上下限;固定长度时二者写相同(如手机 11、身份证 18)。下拉select不需要这两项,取值范围由options决定。hint(可选):填写提示,供前端作说明或占位提示。type为select时须带options:数组,每项为{ "value": "…", "label": "…" };勿写minLength/maxLength。type为file时建议带accept(允许的 MIME);并须带maxFileSizeMb,表示单个文件大小上限(单位 MB,可为小数)。
3、可重复区块(多条经历/多条记录)
与模板一致时,在该区块对象上增加 "type": "repeat",并用 itemFields 描述每一条重复记录里包含哪些子字段(写法与上面 fields 中单条字段相同)。
bind:字符串,表示该段多条数据写入报名存档 apply_fields 时对应的数组键名(如 educations、works、families),须与门户落库、展示约定一致。
min / max:允许考生填写的最少条数、最多条数(整数)。