page 页面
{
"template": {
"pageId": 101, // 页面ID,类型:Number
"name": "页面", // 名称,类型:String
"className": "wrapper", // class类名,类型:String
"id": "template", // id类名,必须与对象名称保持一致,类型:String
"html": "<!DOCTYPE html>\n<html lang=\"zh-cn\">\n<head>\n<meta charset=\"utf-8\">\n<meta name=\"renderer\" content=\"webkit\">\n<meta http-equiv=\"X-UA-Compatible\" content=\"IE=edge,chrome=1\" />\n<meta name=\"keywords\" content=\"{{=xq.config.keyword}}\">\n<meta name=\"description\" content=\"{{=xq.config.description}}\">\n<meta name=\"robots\" content=\"index,follow\">\n<title>{{=xq.config.title}}</title>\n{{? xq.config.favicon}}<link rel=\"shortcut icon\" type=\"image/ico\" href=\"{{! xq.config.favicon }}\" />{{?}}\n[[@@cssFiles]]\n[[@@css]]\n</head>\n<body>\n<!-- index layout -->\n<div class=\"{{=xq.className}}\"{{? xq.style}} style=\"{{!xq.style}}\"{{?}}>\n[[@@header]]\n[[@@modules]]\n[[@@footer]]\n</div>\n<!-- index layout -->\n</body>\n[[@@jsFiles]]\n[[@@javascript]]\n</html>\n</html>", // html结构文档,类型:String
"css": "", // 页面内联样式,类型:String
"javascript": "", // 页面内部调用脚本,类型:String
"cssFiles": [
"http://www.op110.com/Static/css/reset.css",
"http://www.op110.com/Static/css/short.css"
], // 外部css文件引入,类型:Array
"jsFiles": [
"http://cdn.bootcss.com/jquery/1.8.3/jquery.min.js"
], // 外部js文件引入,类型:Array
"configRules": {
"title": "网站标题"
}, // 对config 对象中的变量说明文字,用于后台上传该字段的补充说明;类型:Object
"config": {
"title": "深圳同天下科技有限公司",
"keyword": "深圳同天下科技有限公司-关键字",
"description": "深圳同天下科技有限公司-描述",
"favicon": "/favicon.ico"
}, // 配置与业务逻辑无关联的数据字段,类型:Object
"dataConfig": {}, // 对data对象中的变量说明文字,用于后台上传该字段的补充说明,类型:Object
"data": {}, // 配置与业务逻辑关联的数据字段,类型:Object
"header": {
"moduleId": 102,
"name": "",
"className": "l-header",
"id": "header",
"html": "",
"css": "",
"javascript": "",
"cssFiles": [
"http://www.op110.com/Static/css/reset.css",
"http://www.op110.com/Static/css/short.css"
],
"jsFiles": [
"http://cdn.bootcss.com/jquery/1.8.3/jquery.min.js"
],
"configRules": {},
"config": {},
"dataConfig": {},
"data": {},
"elements": {}
}, // 页面头部,类型:Object
"footer": {
"moduleId": 205,
"name": "底部",
"className": "l-footer",
"id": "footer",
"html": "",
"css": "",
"javascript": "",
"cssFiles": [],
"jsFiles": [],
"configRules": {},
"config": {},
"dataConfig": {},
"data": {}
}, // 页面尾部,类型:Object
"modules": {} // 页面中所有的(除开头部和尾部)模块集合,类型:Object
}
}
module 模块
"module": {
"moduleId": 102, // 模块ID,类型:Number
"name": "模块",
"className": "l-module",
"id": "module",
"html": "",
"css": "",
"javascript": "",
"cssFiles": [
"http://www.op110.com/Static/css/reset.css",
"http://www.op110.com/Static/css/short.css"
],
"jsFiles": [
"http://cdn.bootcss.com/jquery/1.8.3/jquery.min.js"
],
"configRules": {},
"config": {},
"dataConfig": {},
"data": {},
"elements": {} // 可选,当前模块下的所有组件集合,类型:Object
}
element 组件
"element": {
"elementId": 103, // 组件ID,类型:Number
"name": "组件",
"className": "m-element",
"id": "element",
"html": "",
"css": "",
"javascript": "",
"cssFiles": [],
"jsFiles": [],
"configRules": {},
"config": {},
"dataConfig": {},
"data": {},
"elements":{} // 可选,组件中可以继续插入组件,类型:Object
}
data 字段说明
通用字段
- 资源地址使用
src
- 链接跳转地址使用
url
- 标题名称使用
title
- 摘要描述使用
summary
- 数组循环输出项(如:列表项)使用
items
- 控制显隐
isShow
- 是否在新窗口打开
isBlank
page页面 和 module模块 background设置
"data": {
bgImage: "",
bgColor: ""
}
导航
"data": {
"items": [
"name": "",
"url": "",
"children": [{
"name": "",
"url",
"children": []
}]
]
}
线路产品
"data": {
"items": [
"title": "",
"type": "",
"src": "",
"summary": "",
"url": "",
"isBlank": false,
"cols": [1, 2, 3, 4, 5, 6],
"prices": [],
"planDates": [],
"fromCitys": [],
"tags": [],
"sales": []
]
}
产品选项卡
"data": {
"items": [
"title": "tab选项一",
"ad": "",
"listMediaItems": [{
"title": "",
"type": "",
"url": "",
"summary": "",
"url": "",
"isBlank": false,
"cols": [1, 2, 3, 4, 5, 6],
"prices": [],
"planDates": [],
"fromCitys": [],
"tags": [],
"sales": []
}],
"ad2": "",
"box": {
"title": "",
"listMixItems": [{
"title": "",
"type": "",
"src": "",
"summary": "",
"url": "",
"isBlank": false,
"cols": [1, 2, 3, 4, 5, 6],
"prices": [],
"planDates": [],
"fromCitys": [],
"tags": [],
"sale": []
}]
}
]
}