Handlepan.vue 15.6 KB
Newer Older
fukai committed
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362
<template>
  <div class="eibs-tab">
    <!-- ====================顶部==================== -->
    <c-col :span="24" style="height: 25px">
      <el-divider></el-divider>
    </c-col>
    <!-- 正常发票表格 -->
    <c-col :span="24" style="height: 24px">
      <el-form-item class="formItemLabel" label="正常发票:" label-width="72px">
      </el-form-item>
    </c-col>
    <c-col :span="24">
      <c-table style="text-align: center" highlight-current-row @row-click="handleInvrepRowClick" :row-class-name="tableInvrepRowClassName" :list="model.invchk.invrep.zcinvlst" :paginationShow="true" :border="true" :total="model.invchk.invrep.zcinvlst.length">
        <el-table-column label="替换" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.repflg'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票代码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicecode'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票号码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicenumber'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票监控状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.monstatus'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hantyp'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理时间" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.handat'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理用户" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hanusr'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="开票日期" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.billingdate'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票占用金额" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amountin'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="价税合计" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amounttax'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="" prop="det" width="150px" fixed="right">
          <template slot-scope="scope" slot="header">
            <c-button circle style="padding: 4px" class="el-icon-plus" size="mini" @click="addRowZcinvlst(scope)">
            </c-button>
            <c-button style="padding: 4px" circle class="el-icon-minus" size="mini" @click="removeRowZcinvlst(scope)">
            </c-button>
          </template>
          <template slot-scope="scoped">
            <c-button style="margin-left: 0" size="small" type="primary" icon="el-icon-info" @click="detailForeignDialog(scoped.$index, scoped.row)"></c-button>
          </template>
        </el-table-column>
      </c-table>
    </c-col>
    <!-- S0000211 : 正常发票 -->
    <!-- S0000220 : 替换 -->
    <c-col :span="24">
      <el-form-item label="替换" label-width="50px">
        <c-button size="small" type="primary">全选</c-button>
        <c-button size="small" type="primary">清空</c-button>
      </el-form-item>
    </c-col>

    <!-- 异常发票表格 -->
    <c-col :span="24" style="height: 24px">
      <el-form-item class="formItemLabel" label="异常发票:" label-width="72px">
      </el-form-item>
    </c-col>
    <c-col :span="24">
      <c-table style="text-align: center" highlight-current-row @row-click="handleInvrepRowClick" :row-class-name="tableInvrepRowClassName" :list="model.invchk.invrep.zcinvlst" :paginationShow="true" :border="true" :total="model.invchk.invrep.zcinvlst.length">
        <el-table-column label="替换" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.repflg'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="忽略" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.ignflg'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票代码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicecode'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票号码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicenumber'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票监控状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.monstatus'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hantyp'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理时间" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.handat'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理用户" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hanusr'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="开票日期" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.billingdate'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票占用金额" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amountin'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="价税合计" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amounttax'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="" prop="det" width="150px" fixed="right">
          <template slot-scope="scope" slot="header">
            <c-button circle style="padding: 4px" class="el-icon-plus" size="mini" @click="addRowZcinvlst(scope)">
            </c-button>
            <c-button style="padding: 4px" circle class="el-icon-minus" size="mini" @click="removeRowZcinvlst(scope)">
            </c-button>
          </template>
          <template slot-scope="scoped">
            <c-button style="margin-left: 0" size="small" type="primary" icon="el-icon-info" @click="detailForeignDialog(scoped.$index, scoped.row)"></c-button>
          </template>
        </el-table-column>
      </c-table>
    </c-col>
    <!-- S0000212 : 异常发票 -->
    <!-- S0000225 : 替换 -->
    <c-col :span="24">
      <el-form-item label="替换" label-width="50px">
        <c-button size="small" type="primary">全选</c-button>
        <c-button size="small" type="primary">清空</c-button>
      </el-form-item>
    </c-col>
    <!-- S0000226 : 忽略 -->
    <c-col :span="24">
      <el-form-item label="忽略" label-width="50px">
        <c-button size="small" type="primary">全选</c-button>
        <c-button size="small" type="primary">清空</c-button>
      </el-form-item>
    </c-col>

    <!-- 重复核验\重复监控表格 -->
    <c-col :span="24" style="height: 24px">
      <el-form-item class="formItemLabel" label="重复核验\重复监控:" label-width="130px">
      </el-form-item>
    </c-col>
    <c-col :span="24">
      <c-table style="text-align: center" highlight-current-row @row-click="handleInvrepRowClick" :row-class-name="tableInvrepRowClassName" :list="model.invchk.invrep.zcinvlst" :paginationShow="true" :border="true" :total="model.invchk.invrep.zcinvlst.length">
        <el-table-column label="替换" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.repflg'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="忽略" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.ignflg'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票代码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicecode'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票号码" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.invoicenumber'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票监控状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.monstatus'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理状态" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hantyp'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理时间" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.handat'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="处理用户" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.hanusr'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="开票日期" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.billingdate'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="发票占用金额" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amountin'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="价税合计" width="185px">
          <template slot-scope="scope">
            <el-form-item label-width="0" :prop="'invchk.invrep.zcinvlst.' + scope.$index + '.amounttax'">
            </el-form-item>
          </template>
        </el-table-column>
        <el-table-column label="" prop="det" width="150px" fixed="right">
          <template slot-scope="scope" slot="header">
            <c-button circle style="padding: 4px" class="el-icon-plus" size="mini" @click="addRowZcinvlst(scope)">
            </c-button>
            <c-button style="padding: 4px" circle class="el-icon-minus" size="mini" @click="removeRowZcinvlst(scope)">
            </c-button>
          </template>
          <template slot-scope="scoped">
            <c-button style="margin-left: 0" size="small" type="primary" icon="el-icon-info" @click="detailForeignDialog(scoped.$index, scoped.row)"></c-button>
          </template>
        </el-table-column>
      </c-table>
    </c-col>

    <!-- S0000213 : 重复核验\重复监控 -->
    <!-- S0000231 : 替换 -->
    <c-col :span="24">
      <el-form-item label="替换" label-width="50px">
        <c-button size="small" type="primary">全选</c-button>
        <c-button size="small" type="primary">清空</c-button>
      </el-form-item>
    </c-col>
    <!-- S0000232 : 忽略 -->
    <c-col :span="24">
      <el-form-item label="忽略" label-width="50px">
        <c-button size="small" type="primary">全选</c-button>
        <c-button size="small" type="primary">清空</c-button>
      </el-form-item>
    </c-col>
    <!-- S0000214 : 被替换发票占用总金额 -->
    <c-col :span="12">
      <el-form-item label="被替换发票占用总金额" prop="invchk.invrep.totalamountin">
        <c-input v-model="model.invchk.invrep.totalamountin" placeholder=""></c-input>
      </el-form-item>
    </c-col>

  </div>
</template>
<script>
import Event from "../event";

export default {
  inject: ["root"],
  props: ["model", "codes"],
  mixins: [Event],
  data() {
    return {
      currentZcinvlstIndex: -1
    };
  },
  methods: {
    //第一个表格
    addRowZcinvlst(row) {
      let newRow = {
        repflg: "",
        invoicecode: "",
        invoicenumber: "",
        monstatus: "",
        hantyp: "",
        handat: ""
      };
      let start = 0;
      if (this.model.invchk.invrep.zcinvlst) {
        start = this.model.invchk.invrep.zcinvlst.length;
      }
      this.model.invchk.invrep.zcinvlst.splice(start, 0, newRow);
    },
    removeRowZcinvlst() {
      console.log("选中的他行下标", this.currentZcinvlstIndex);
      if (this.currentZcinvlstIndex === -1) {
        this.$notify.error({
          title: "错误",
          message: "请选择一条数据删除!"
        });
        return;
      }
      this.model.invchk.invrep.zcinvlst.splice(this.currentZcinvlstIndex, 1);
      this.currentZcinvlstIndex = -1;
      //this.processSetpan();
    },
    tableInvrepRowClassName({ row, rowIndex }) {
      row.index = rowIndex;
    },
    handleInvrepRowClick(row) {
      this.currentZcinvlstIndex = row.index;
    }
  },
  created: function() {}
};
</script>
<style>
</style>