<template>
  <div id="form-1">
    <van-row>
      <van-col span="24" class="main">
        <van-col span="24" class="one">
          <van-form @submit="onSubmit">
            <van-col span="24" class="one_1"> 专利转让合同 </van-col>
            <van-col span="24" class="one_2">
              <span>甲方(转让方)：</span>
              <van-field v-model="form.contract.transfer" name="transfer" />
            </van-col>
            <van-col span="24" class="one_2">
              <span>乙方(受让方)：</span>
              <van-field v-model="form.contract.transferee" name="transferee" />
            </van-col>
            <van-col span="24" class="one_3"> 甲、乙方经过平等协商，自愿订立专利权转让合同，并共同遵照执行: </van-col>
            <van-col span="24" class="one_4">
              <span>第一条 甲方将其享有的</span>
              <van-field v-model="form.contract.patent_name" name="patent_name" />
              <span>专利权有偿转让给乙方，专利号为：</span>
              <van-field v-model="form.contract.create_number" name="create_number" />
            </van-col>
            <van-col span="24" class="one_5">
              <span>第二条 甲方向乙方转让</span>
              <van-field v-model="form.contract.patent_right" name="patent_right" />
              <span>专利权；</span>
            </van-col>
            <van-col span="24" class="one_6">
              <span>第三条 乙方为此向甲方支付专利权转让费用</span>
              <van-field v-model="form.contract.money" name="money" />
              <span>元，于本合同生效后</span>
              <van-field v-model="form.contract.days" name="days" />
              <span>天内一次付清。</span>
            </van-col>
            <van-col span="24" class="one_7">第四条 如任何一方违反本合同约定给对方造成损失，守约方可以要求对方承担违约责任；</van-col>
            <van-col span="24" class="one_7">第五条 甲方保证此转让行为不侵犯任何第三方的合法权益；</van-col>
            <van-col span="24" class="one_7">第六条 本合同于各方签字盖章后生效，未经各方同意，任何一方均无权修改或变更本合同约定；</van-col>
            <van-col span="24" class="one_8">
              <span>第七条 任何因本合同的履行而产生的争议，均应当友好协商解决，如无法协商解决，各方同意交由</span>
              <van-field v-model="form.contract.arbirate" name="arbirate" />
              <span>仲裁委员会按照该会现时有效的仲裁规则予以仲裁；</span>
            </van-col>
            <van-col span="24" class="one_7"> 第八条 本合同一式三份，双方各执一份，备案一份。 </van-col>
            <van-col span="24" class="btn">
              <van-button round block type="info" native-type="submit">提交</van-button>
            </van-col>
          </van-form>
        </van-col>
      </van-col>
    </van-row>
  </div>
</template>

<script>
import { mapState, createNamespacedHelpers } from 'vuex';
export default {
  name: 'form-1',
  props: {
    form: { type: Object },
  },
  components: {},
  data: function () {
    return {};
  },
  created() {},
  methods: {
    onSubmit(values) {
      this.$emit('onSubmit', { data: this.form });
    },
  },
  computed: {
    ...mapState(['user']),
  },
  metaInfo() {
    return { title: this.$route.meta.title };
  },
  watch: {
    test: {
      deep: true,
      immediate: true,
      handler(val) {},
    },
  },
};
</script>

<style lang="less" scoped>
.main {
  .one {
    padding: 0 5px;
    font-size: 16px;
    .one_1 {
      text-align: center;
      font-weight: bold;
      margin: 8px 0 8px 0;
    }
    .one_2 {
      margin: 0 0 8px 0;
      span {
        float: left;
        padding: 7px 0;
      }
      /deep/.van-cell {
        float: left;
        width: 68%;
        padding: 5px;
        border-bottom: 1px solid #000;
        background-color: transparent;
      }
    }
    .one_3 {
      margin: 0 0 8px 0;
    }
    .one_4 {
      margin: 0 0 8px 0;
      span {
        float: left;
        padding: 7px 0;
      }
      /deep/.van-cell {
        float: left;
        width: 50%;
        padding: 5px;
        border-bottom: 1px solid #000;
        background-color: transparent;
      }
      /deep/.van-cell:last-child {
        width: 100%;
      }
    }
    .one_5 {
      margin: 0 0 8px 0;
      span {
        float: left;
        padding: 7px 0;
      }
      /deep/.van-cell {
        float: left;
        width: 53%;
        padding: 5px;
        border-bottom: 1px solid #000;
        background-color: transparent;
      }
    }
    .one_6 {
      margin: 0 0 8px 0;
      span {
        float: left;
        padding: 7px 0;
      }
      /deep/.van-cell {
        float: left;
        width: 12%;
        padding: 5px;
        border-bottom: 1px solid #000;
        background-color: transparent;
      }
      /deep/.van-cell:last-child {
        width: 12%;
      }
    }
    .one_7 {
      margin: 0 0 8px 0;
    }
    .one_8 {
      margin: 0 0 8px 0;
      span {
        float: left;
        padding: 7px 0;
      }
      /deep/.van-cell {
        float: left;
        width: 100%;
        padding: 5px;
        border-bottom: 1px solid #000;
        background-color: transparent;
      }
    }
    .btn {
      margin: 8px 0;
    }
  }
}
</style>
