import Taro, { Component } from '@tarojs/taro'
import { View, RichText } from '@tarojs/components'
import Statement from '../../components/Statement'
import ContactConsultant from '../../components/ContactConsultant'

import './index.scss'

export default class Protocol extends Component {
  config = {
    navigationBarTitleText: '线上选房协议',
  }

  state = {

  }

  render() {

    const { agreement, buildingId } = this.$router.params

    return (
      <View className="protocal-box">
        <View className="content">
          <RichText nodes={agreement} />
        </View>
        <View className="contact">
          <ContactConsultant text="如有问题，请联系置业顾问" buildingId={buildingId} />
        </View>
        <Statement />
      </View>
    )
  }
}
