<template>
  <div class="server-error"
       @touchmove.prevent
       v-if="show">
    <ErrorComponent :type="500"
                    :refresh="refresh">
      <div class="tc"
           v-html="slotStr">
      </div>
    </ErrorComponent>
  </div>
</template>

<script>
import ErrorComponent from '../errorComponent/index.vue';
export default {
  name: 'ServerError',
  components: { ErrorComponent },
  props: {
    show: {
      type: Boolean,
      default: false
    },

    slotStr: {
      type: String,
      default: '<p>服务器返回失败/请求接口错误</p>'
    },
    refresh: {
      type: Boolean,
      default: true
    }
  }
};
</script>

