简要描述:

获取首页信息

请求域名:

  • http://xx.com

请求URL:

POST/plugin.pc-terminal.api.home.index

返回参数说明:

参数名 类型 说明
set array 设置信息
set.banner1_src string Banner1图片
set.banner1_url string Banner1图片跳转链接
set.banner2_src string Banner2图片
set.banner2_url string Banner2图片跳转链接
seo array seo信息
seo.title string 标题
seo.keywords string 关键词
seo.description string 描述
twoAdvert array 两栏广告信息
twoAdvert.title string 广告标题
twoAdvert.img_src string 广告图片地址
twoAdvert.url string 广告跳转链接
threeAdvert array 三栏广告信息
threeAdvert.title string 广告标题
threeAdvert.img_src string 广告图片地址
threeAdvert.url string 广告跳转链接
recommend array 推荐商品信息(空的话此模块不显示)
recommend.id int 商品id
recommend.title string 商品名
recommend.thumb string 商品图片
recommend.market_price float 原价
hot array 热销商品信息(空的话此模块不显示)
new array 新品商品信息(空的话此模块不显示)
promotion array 促销商品信息(空的话此模块不显示)

返回示例:

正确时返回的数据:

{
	"result": 1,
	"msg": "ok",
	"data": {
		"set": {
			"banner1": null,
			"banner1_url": null,
			"banner2": null,
			"banner2_url": null,
			"logo_src": "",
			"banner_bg_src": "",
			"login_advert_src": "",
			"banner1_src": "",
			"banner2_src": ""
		},
		"twoAdvert": [
			{
				"title": "两栏广告",
				"img": "images/1/2020/02/IRH7r73628mhszr3fqiQvmQw6HQB3r.jpg",
				"url": null,
				"advert_type": 1,
				"img_src": "http://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/02/IRH7r73628mhszr3fqiQvmQw6HQB3r.jpg"
			}
		],
		"threeAdvert": [
			{
				"title": "三栏广告",
				"img": "images/1/2020/02/IRH7r73628mhszr3fqiQvmQw6HQB3r.jpg",
				"url": null,
				"advert_type": 2,
				"img_src": "http://shop-yunzshop-com.oss-cn-hangzhou.aliyuncs.com/images/1/2020/02/IRH7r73628mhszr3fqiQvmQw6HQB3r.jpg"
			}
		],
		"recommend": [
			{
				"id": 120,
				"title": "视频点播商品3",
				"thumb": "images/1/2019/12/tU0YL3L690JulB6hJ3jGM331JLLOb9.jpg",
				"market_price": "0.00",
				"price": "6.66",
				"cost_price": "3.22",
				"stock": 99,
				"real_sales": 1,
				"show_sales": 1,
				"virtual_sales": 1,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 119,
				"title": "视频点播商品2",
				"thumb": "images/1/2019/12/tU0YL3L690JulB6hJ3jGM331JLLOb9.jpg",
				"market_price": "0.00",
				"price": "6.66",
				"cost_price": "3.22",
				"stock": 99,
				"real_sales": 1,
				"show_sales": 1,
				"virtual_sales": 1,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 117,
				"title": "租赁",
				"thumb": "images/1/2019/12/pc7lmRlHEp5l4M11957lPIYC1l1e11.jpg",
				"market_price": "200.00",
				"price": "100.00",
				"cost_price": "0.00",
				"stock": 5477,
				"real_sales": 1,
				"show_sales": 1,
				"virtual_sales": 0,
				"has_option": 0,
				"plugin_id": 40,
				"status_name": null
			},
			{
				"id": 116,
				"title": "测试",
				"thumb": "newimage/fedb0f6c2fac28690a5b5dc0aefc7d0e.jpg",
				"market_price": "263.00",
				"price": "100.00",
				"cost_price": "82.00",
				"stock": 1253,
				"real_sales": 0,
				"show_sales": 0,
				"virtual_sales": 0,
				"has_option": 0,
				"plugin_id": 32,
				"status_name": null
			},
			{
				"id": 115,
				"title": "测试商品发布",
				"thumb": "/newimage/55812ff61cb4764ce2c995bdd7c37d91.jpg",
				"market_price": "200.00",
				"price": "100.00",
				"cost_price": "0.00",
				"stock": 253,
				"real_sales": 31,
				"show_sales": 31,
				"virtual_sales": 0,
				"has_option": 1,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 114,
				"title": "橘子店",
				"thumb": "images/1/2019/09/lJjMBJjL5j3ej3xELK3Gjlj3eBGMjG.jpg",
				"market_price": "1.00",
				"price": "1.00",
				"cost_price": "1.00",
				"stock": 9999999,
				"real_sales": 0,
				"show_sales": 0,
				"virtual_sales": 0,
				"has_option": 0,
				"plugin_id": 31,
				"status_name": null
			},
			{
				"id": 112,
				"title": "商品套餐测试",
				"thumb": "images/1/2019/12/tU0YL3L690JulB6hJ3jGM331JLLOb9.jpg",
				"market_price": "0.00",
				"price": "50.00",
				"cost_price": "0.00",
				"stock": 665,
				"real_sales": 1,
				"show_sales": 1,
				"virtual_sales": 0,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 111,
				"title": "栗子测试商品",
				"thumb": "images/1/2019/12/ek4mYo310uyMLLoCMa14cdC58kalu1.jpg",
				"market_price": "0.00",
				"price": "50.00",
				"cost_price": "0.00",
				"stock": 665,
				"real_sales": 1,
				"show_sales": 1,
				"virtual_sales": 0,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			}
		],
		"hot": [
			{
				"id": 4,
				"title": "卫目天下电子喷雾仪",
				"thumb": "images/1/2020/01/Kb22YH4NYbh2uV2Be2BqVvCKHB4Bz2.png",
				"market_price": "198.00",
				"price": "59.00",
				"cost_price": "12.00",
				"stock": 999,
				"real_sales": 10875,
				"show_sales": 10875,
				"virtual_sales": 200,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 3,
				"title": "卫目天下护眼喷雾董事豪华礼包",
				"thumb": "images/1/2020/02/EL9z4T271ClTJO6LU9ol2tCc2lCt13.jpg",
				"market_price": "42000.00",
				"price": "30000.00",
				"cost_price": "10815.00",
				"stock": 999,
				"real_sales": 1617,
				"show_sales": 1617,
				"virtual_sales": 300,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 2,
				"title": "卫目天下护眼喷雾总代礼包",
				"thumb": "images/1/2020/02/In0DywOSf3FKWkF4nfkWSOyKm3iKRf.jpg",
				"market_price": "8000.00",
				"price": "6000.00",
				"cost_price": "2060.00",
				"stock": 999,
				"real_sales": 1100,
				"show_sales": 1100,
				"virtual_sales": 500,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			},
			{
				"id": 1,
				"title": "卫目天下护眼喷雾创客礼包",
				"thumb": "images/1/2020/02/IRH7r73628mhszr3fqiQvmQw6HQB3r.jpg",
				"market_price": "599.00",
				"price": "400.00",
				"cost_price": "103.00",
				"stock": 999,
				"real_sales": 48539,
				"show_sales": 48539,
				"virtual_sales": 1000,
				"has_option": 0,
				"plugin_id": 0,
				"status_name": null
			}
		],
		"new": [],
		"promotion": []
	}
}

错误时返回:

{
	"result": 0,
	"msg": "",
	"data": []
}

备注:

  • 更多返回错误代码请看首页的错误代码描述