|
|
@@ -22,9 +22,7 @@
|
|
|
</view>
|
|
|
<text class="bottom-button" @click.stop="goToOrderDetail(info.id)">销售记录</text>
|
|
|
<text class="bottom-button" @click.stop="goToStockDetail(info.id)">库存明细</text>
|
|
|
- <!-- #ifdef MP-WEIXIN -->
|
|
|
<text class="bottom-button" @click.stop="goToProduct(info.id)">分享</text>
|
|
|
- <!-- #endif -->
|
|
|
<text class="bottom-button" @click.stop="moreToDo(info)">更多</text>
|
|
|
</view>
|
|
|
</template>
|
|
|
@@ -66,8 +64,36 @@ export default {
|
|
|
// #ifdef MP-WEIXIN
|
|
|
this.$emit('goToProduct', id)
|
|
|
// #endif
|
|
|
+
|
|
|
// #ifdef APP-PLUS
|
|
|
- this.$msg('请在小程序上打开分享')
|
|
|
+ //this.$msg('请在小程序上打开分享')
|
|
|
+ uni.login({
|
|
|
+ provider: 'weixin',
|
|
|
+ success: function (loginRes) {
|
|
|
+ var sweixin
|
|
|
+
|
|
|
+ plus.share.getServices(function(s){
|
|
|
+ for (var i = 0; i < s.length; i++) {
|
|
|
+ var t = s[i];
|
|
|
+ if (t.id == 'weixin') {
|
|
|
+ sweixin = t;
|
|
|
+ }
|
|
|
+ }
|
|
|
+
|
|
|
+ if (sweixin && sweixin.nativeClient) {
|
|
|
+ sweixin.launchMiniProgram({
|
|
|
+ id: 'gh_73b8b357d19a',
|
|
|
+ path: 'admin/item/list',
|
|
|
+ type: 0
|
|
|
+ });
|
|
|
+ } else {
|
|
|
+ console.log('请确认是否安装微信');
|
|
|
+ }
|
|
|
+ }, function(e){
|
|
|
+ console.log("获取微信失败:" + e.message);
|
|
|
+ });
|
|
|
+ }
|
|
|
+ });
|
|
|
// #endif
|
|
|
},
|
|
|
addEvent() {
|
|
|
@@ -183,4 +209,4 @@ export default {
|
|
|
}
|
|
|
}
|
|
|
}
|
|
|
-</style>
|
|
|
+</style>
|