jinlin
2023-12-18 e4db7d4a3e03ec4767a57743aef01e54461bbe9a
web/src/views/modules/contractReview/ContractReview-AddOrUpdate.vue
@@ -31,19 +31,20 @@
              <el-table ref="tableConfigItemList" class="el-software el-margin-top-bot"
                        style="width: 99%;margin-left: 5px" border :data="dataForm.reviewItemList"
                        stripe>
                <el-table-column prop="no" align="center" width="60" label="序号">
                <el-table-column prop="no" align="center" width="60" >
                  <template slot-scope="scope">
                    <span v-html="indexFormat(scope.$index)"></span>
                  </template>
                </el-table-column>
                <el-table-column prop="item" min-width="400" label="配置项名称">
                <el-table-column prop="item" min-width="400" >
                  <template v-slot="{ row }">
                    <el-input v-model="row.item" placeholder="评审项"></el-input>
                  </template>
                </el-table-column>
                <el-table-column prop="result" label="密级" width="180" align="center">
                <el-table-column prop="result"  width="180" align="center">
                  <template v-slot="{ row }">
                    <zt-dict v-model="row.result" placeholder="评审结果" dict="tristate1"></zt-dict>
                    <zt-dict v-model="row.result" placeholder="评审结果" dict="tristate1" :radio="true"
                             clearable></zt-dict>
                  </template>
                </el-table-column>
              </el-table>
@@ -112,7 +113,12 @@
          </div>
        </div>
      </div>
      <add-or-update-check ref="addOrUpdate" @recall="setCheckId"/>
      <div class="el-flex order-sc" style="height: 60px">
        <el-form-item class="marginTopAndMarginBottom" style="width: 100%">
          <config-uploader :lineHeight="true" busi-type="contract_review" model-name="dataForm" :dataForm="dataForm"
                           v-model="dataForm.files"/>
        </el-form-item>
      </div>
    </el-form>
    <template v-slot:footer>
      <el-button v-if="dataForm.disabled" type="primary" @click="print()">打印</el-button>
@@ -130,6 +136,7 @@
    return {
      dataForm: {
        id: '',
        files:'',
        contractReview: {
          code: '',
          orderCode: '',
@@ -177,21 +184,22 @@
        ...this.dataForm,
        ...res.data
      }
      if(this.dataForm.contractReview === null){
        this.dataForm.contractReview={}
      }
      if(this.dataForm.testAgencyInfo === null){
        this.dataForm.testAgencyInfo={}
      }
      console.log(this.dataForm, "getInfo this.dataForm")
    },
    setCheckId(checkId, row) {
      console.log(checkId, row, "setCheckId(checkId, row)")
      this.$set(row, 'checkId', checkId)
    },
    /*async print(){
    async print(){
      var params = qs.stringify({
        token: Cookies.get('token'),
        id:this.dataForm.id
      })
      let apiURL = `/contractReview/ContractReview/exportWarehouseOrder`
      let apiURL = `/contractReview/ContractReview/exportReview`
      window.location.href = `${window.SITE_CONFIG['apiURL']}${apiURL}?${params}`
    },*/
    },
    // 表单提交
    async formSubmit(submitType) {
      let res = await this.$http[!this.dataForm.id ? 'post' : 'put']('/contractReview/ContractReview/', this.dataForm)