<!--
  Copyright (c) 2018-2999 广州市蓝海创新科技有限公司 All rights reserved.

  https://www.mall4j.com/

  未经允许，不可做商业用途！

  版权所有，侵权必究！
-->

<template>
  <view class="Mall4j page-product-overview">
    <!-- #ifdef H5 -->
    <!-- <view class="top-title">
      <view class="my-message">商品概况</view>
    </view> -->
    <!-- #endif -->

    <!-- 商品整体概况 -->
    <empty-tips
      v-if="!isAuthorities"
      :tips-list="EmptyTipsText"
    />
    <template v-if="isAuthorities&&isShow">
      <overall-overview />
      <!-- 商品整体概况 end-->

      <!-- 商品趋势分析 -->
      <commodity-trend-analysis />
    </template>
  </view>
</template>

<script setup>

const isShow = ref(false)
const isAuthorities = ref(false) // 是否有权限访问
const EmptyTipsText = [$t('niMeiYouFangWenQuanXian')]
onShow(() => {
  const _isAuthorities = util.isAuthorities
  isAuthorities.value = _isAuthorities('productOverview:view')
  isShow.value = true
  uni.setNavigationBarTitle({
    title: $t('shangPinGaiKuang-0')
  })
  util.transTabbar()
})
onHide(() => {
  isShow.value = false
})

</script>

<style lang="scss" scoped>
@use "./product-overview.scss";
</style>
