<template>
  <div class="content">
    <div class="title">
      <div class="logo">
        <img :src="logo" alt="" />
      </div>
      <div class="name">
        {{ name }}
      </div>
    </div>
    <div class="fwb" v-html="company"></div>
    <!-- <div style="width: 100%">
      <footer-share
        style="width: 100%"
        :isCollection="true"
        @collectionPages="collectionPage"
        @sharePages="sharePage"
      ></footer-share>
    </div> -->
  </div>
</template>
<script>
export default {
  onLoad(option) {
    this.getRich(option.id);
  },
  data() {
    return {
      company: "",
      logo:getApp().globalData.company_logo,
      name:getApp().globalData.company_name
    };
  },
  methods: {
    getRich(ids) {
      uni.request({
        url: `https://kiq.xazhima.com/content/company_product/${Math.floor(
          ids / 1000
        )}/${ids}.html`,
        method: "GET",
        header: {
          "content-type": "application/x-www-form-urlencoded",
        },
        success: (res) => {
          if (res.statusCode === 200) {
            this.company = res.data;
          }
        },
        fail: () => {
          console.log("连接失败");
        },
      });
    },
  },
};
</script>
<style lang="scss">
.content {
  padding: 4%;
  font-size: 30rpx;
  .title {
    display: flex;
    align-items: center;
    border-radius: 10rpx;
    margin-bottom: 50rpx;
    box-shadow: rgba(0, 0, 0, 0.35) 0rpx 5rpx 15rpx;
    .logo {
      image {
        width: 200rpx;
        height: 100rpx;
        margin: 0 30rpx;
      }
    }
  }
}
</style>