Authored by QC-L

修复扫码不能扫线上商品的问题

... ... @@ -30,7 +30,7 @@
"list": []
},
"miniprogram": {
"current": 12,
"current": 13,
"list": [
{
"id": -1,
... ... @@ -110,6 +110,13 @@
"pathName": "pages/productDetail/index",
"query": "q=https%3A%2F%2Fo.yohobuy.com%2Fufo%3Fp%3D6096%2C70%26skup%3D6096",
"scene": "1011"
},
{
"id": 13,
"name": "商品详情线下店",
"pathName": "pages/productDetail/index",
"query": "q=https%3A%2F%2Fo.yohobuy.com%2Fufo%3Fp%3D6096%2C70%26productId%3D10001099",
"scene": "1011"
}
]
}
... ...
... ... @@ -103,11 +103,15 @@ export default class ProductDetail extends Component {
const p = queryObj.p;
const storeArr = p.split(',') || [];
const storeId = storeArr[1];
this.setState({
skup: queryObj.skup,
storeId
})
this.loadStoreProductInfo(queryObj.skup, storeId);
if (queryObj.skup) {
this.setState({
skup: queryObj.skup,
storeId
})
this.loadStoreProductInfo(queryObj.skup, storeId);
} else {
this.loadElement({id: queryObj.productId || queryObj.skn});
}
}
} else {
if (options && options.scene) {
... ...