wiki:yjp/web-intf

1.首页接口---主题列表

原型  http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/ 结构类似:

{
    "total":100,
    "pageIndex":1,
    "pageSize":10,
    "topics":[
        {
            "id":10,
            "bigImg":"http:xxxx",
            "name":"topicName",
            "description":"topic descript"
        },
        {
            "id":11,
            "bigImg":"http:xxxx",
            "name":"topicName",
            "description":"topic descript"
        }
    ]
}

返回参数说明:
total:主题总数量
pageIndex:分页用页码
pageSize:分页用每页数量
topics:主题数组
id:主题的id
bigImg:主题图片
name:主题名称
description:主题描述

2.主题接口

原型  http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/

{
    "total":20,
    "pageIndex":1,
    "pageSize":10,
    "products":[
        {
            "id":10,
            "bigImg":"http:xxxx",
            "name":"productName",
            "collectCount":1234
        },
        {
            "id":11,
            "bigImg":"http:xxxx",
            "name":"productName",
            "collectCount":1234
        }
    ]
}

返回参数说明:
total:单品总数量
pageIndex:分页用页码
pageSize:分页用每页数量
products:单品数组
id:单品的id
bigImg:单品图片
name:单品名称
collectCount:单品被收藏的数量

3.单品库首页

原型  http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/

{
    "items":{
        "323":{
            "level":1,
            "seq":1,
            "name":"客厅",
            "image":"http:xxxx",
            "type":"node"
        },
        "324":{
            "level":2,
            "seq":2,
            "name":"沙发",
            "image":"http:xxxx",
            "type":"node"
        },
        "325":{
            "level":1,
            "seq":1,
            "name":"睡房",
            "image":"http:xxxx",
            "type":"node"
        },
        "326":{
            "level":2,
            "seq":2,
            "name":"床",
            "image":"http:xxxx",
            "type":"node"
        }
    },
    "relations":{
        "$node id value1":[
            323,
            324
        ],
        "$node id value2":[
            325,
            326
        ]
    }
}

返回参数说明:
id:节点ID
level:节点的层次,1表示根节点。
seq:节点的顺序,同级节点之间的显示顺序。从1开始
name:节点名称
image:图片url
type:节点类型,node表示该节点的下级还是一个节点,article表示该节点的下级已经是文章ID
$node id value:节点ID的值。以节点ID的值作为key,该节点的子节点集合作为value,建立节点之间的关联关系,实现节点的向下遍历。

4.单品库列表页-----搜索结果----猜你喜欢

 http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/

{
    "total":100,
    "pageIndex":1,
    "pageSize":10,
    "products":[
        {
            "name":"法丽莎家具 欧式床 实木床 田园婚床 双人床 1.8 1.5米",
            "price":"¥2699.00",
            "oldPrice":"¥2899.00",
            "collectCount":1234
        },
        {
            "name":"法丽莎家具 欧式床 实木床 田园婚床 双人床 1.8 1.5米",
            "price":"¥2699.00",
            "oldPrice":"¥2899.00",
            "collectCount":1234
        }
    ]
}

返回参数说明:
total:单品总数量
pageIndex:分页用页码
pageSize:分页用每页数量
products:单品数组
products:产品数组
name:产品名
price:当前价格、优惠价格
oldPrice:旧价格
collectCount:收藏数量

5.测试页

 http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/

{
    "count":6,
    "tests":[
        {
            "testId":1,
            "testDescription":"请选择上述两款产品中你较喜欢的产品",
            "MultiSelect":0,
            "selection":[
                {
                    "selectionId":11,
                    "image":"http://xxx"
                },
                {
                    "selectionId":12,
                    "image":"http://xxx"
                }
            ]
        },
        {
            "testId":2,
            "testDescription":"请选择上述两款产品中你较喜欢的产品",
            "MultiSelect":1,
            "selection":[
                {
                    "selectionId":21,
                    "image":"http://xxx"
                },
                {
                    "selectionId":22,
                    "image":"http://xxx"
                }
            ]
        }
    ]
}

返回参数说明:
count:测试页数量
tests:测试页数组
testId:测试页id
testDescription:测试页
MultiSelect?:是否多选,1是,0否
selection:选项数组
selectionId:选项id
image:图片url

6.终端页

 http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.0/

{
    "productName":"法丽莎家具 欧式床 实木床 田园婚床 双人床 1.8 1.5米",
    "price":"¥2699.00",
    "oldPrice":"¥2899.00",
    "seller":"发丽莎家居旗舰店",
    "image":[
        "http://xxxx",
        "http://xxxx",
        "http://xxxx"
    ],
    "commentCount":1234,
    "comments":[
        {
            "nickName":"b_小贝贝",
            "time":"9月3日 15:23",
            "face":"http://asdfasdf",
            "content":"她家的包包看起来还不错,有谁买过的,求推荐!"
        },
        {
            "nickName":"Blanch_213",
            "time":"9月3日 15:53",
            "face":"http://asdfasdf",
            "content":"简单,但太普遍了!"
        }
    ]
}

返回参数说明:
productName:产品名
price:价格、优惠价格
oldPrice:原价格
seller:商家
image:图片数组
commentCount:评论总数
comments:评论数组
nickName:昵称
time:评论时间
face:头像
content:评论内容

7.用户信息

http://trac.pc.com.cn/mobile/pototype/ideas/youjiapin/req1.0.1/
{
    "username":"imoveto1",
    "session":"xxxx",
    "userid":"userid",
    "remark":"坚持世上一切美好的事物,哈哈!",
    "face":"http://xxxx",
    "collectCount":34,
    "readHistory":134
}

username:用户名
session:session
userid:用户id
remark:备注
face:头像
collectCount:收藏夹数量
readHistory:浏览历史