|
@@ -329,6 +329,100 @@
|
329
|
329
|
</span>
|
330
|
330
|
</el-dialog>
|
331
|
331
|
</el-tab-pane>
|
|
332
|
+ <el-tab-pane label="备案资源" name="备案资源">
|
|
333
|
+ <el-form class="form-wrapper" :inline="true" :model="formInline5" style="margin-bottom: 20px;">
|
|
334
|
+ <el-row>
|
|
335
|
+ <el-col :span="8">
|
|
336
|
+ <el-form-item label="车场名称:">
|
|
337
|
+ <el-select clearable v-model="formInline5.parkId" placeholder="请选择">
|
|
338
|
+ <el-option
|
|
339
|
+ v-for="(item,index) in carParkingNameOptions"
|
|
340
|
+ :key="index"
|
|
341
|
+ :label="item.parkName"
|
|
342
|
+ :value="item.id" />
|
|
343
|
+ </el-select>
|
|
344
|
+ </el-form-item>
|
|
345
|
+ </el-col>
|
|
346
|
+ <el-col :span="8">
|
|
347
|
+ <el-form-item>
|
|
348
|
+ <el-button type="primary" class="query-btn" @click="onSubmit5">查询</el-button>
|
|
349
|
+ </el-form-item>
|
|
350
|
+ <el-form-item>
|
|
351
|
+ <el-button type="success" @click="handleAdd5">添加</el-button>
|
|
352
|
+ </el-form-item>
|
|
353
|
+ </el-col>
|
|
354
|
+ </el-row>
|
|
355
|
+ </el-form>
|
|
356
|
+ <el-table :data="tableData5">
|
|
357
|
+ <el-table-column v-for="(item, index) in columns5" :key="index" :label="item.label" :prop="item.key">
|
|
358
|
+ </el-table-column>
|
|
359
|
+ <el-table-column
|
|
360
|
+ label="操作"
|
|
361
|
+ width="200">
|
|
362
|
+ <template slot-scope="scope" style="display: inline-block">
|
|
363
|
+ <el-button type="primary" @click="handleEdit5(scope.row)" slot="reference">修改</el-button>
|
|
364
|
+ <el-popconfirm title="确定删除吗?" @confirm="deleteRow5(scope.row)">
|
|
365
|
+ <el-button type="danger" slot="reference">删除</el-button>
|
|
366
|
+ </el-popconfirm>
|
|
367
|
+ </template>
|
|
368
|
+ </el-table-column>
|
|
369
|
+ </el-table>
|
|
370
|
+ <div class="table-pagination">
|
|
371
|
+ <el-pagination layout="prev, pager, next" :total="total5" @current-change="handlePageChange5"
|
|
372
|
+ :current-page.sync="pageNum5" :page-size.sync="pageSize5">
|
|
373
|
+ </el-pagination>
|
|
374
|
+ </div>
|
|
375
|
+ <el-dialog
|
|
376
|
+ :title="title5"
|
|
377
|
+ :visible.sync="dialogVisible5"
|
|
378
|
+ width="45%"
|
|
379
|
+ custom-class="audit-dialog">
|
|
380
|
+ <div class="form-div">
|
|
381
|
+ <el-form label-position="left" label-width="100px" :model="formLabelAlign5">
|
|
382
|
+ <el-form-item label="车场名称">
|
|
383
|
+ <el-select v-model="formLabelAlign5.parkId" placeholder="请选择">
|
|
384
|
+ <el-option
|
|
385
|
+ v-for="(item,index) in carParkingNameOptions"
|
|
386
|
+ :key="index"
|
|
387
|
+ :label="item.parkName"
|
|
388
|
+ :value="item.id" />
|
|
389
|
+ </el-select>
|
|
390
|
+ </el-form-item>
|
|
391
|
+ <el-form-item label="单位名称">
|
|
392
|
+ <el-input v-model="formLabelAlign5.unitName"></el-input>
|
|
393
|
+ </el-form-item>
|
|
394
|
+ <el-form-item label="资源类型">
|
|
395
|
+ <el-input v-model="formLabelAlign5.resourceType"></el-input>
|
|
396
|
+ </el-form-item>
|
|
397
|
+ <el-form-item label="有效期">
|
|
398
|
+ <el-date-picker
|
|
399
|
+ v-model="formLabelAlign5.effectiveTime"
|
|
400
|
+ type="daterange"
|
|
401
|
+ range-separator="至"
|
|
402
|
+ start-placeholder="开始日期"
|
|
403
|
+ value-format="yyyy-MM-dd"
|
|
404
|
+ end-placeholder="结束日期">
|
|
405
|
+ </el-date-picker>
|
|
406
|
+ </el-form-item>
|
|
407
|
+ <el-form-item label="上传文件">
|
|
408
|
+ <el-upload
|
|
409
|
+ class="upload-demo"
|
|
410
|
+ :multiple="false"
|
|
411
|
+ :on-success="handleSuccess"
|
|
412
|
+ :action="`${getUrl()}/opt/common/select/uploadLocalReturnUrl`"
|
|
413
|
+ :file-list="fileList">
|
|
414
|
+ <el-button size="small" type="primary">点击上传</el-button>
|
|
415
|
+ <!-- <div slot="tip" class="el-upload__tip">只能上传jpg/png文件,且不超过500kb</div> -->
|
|
416
|
+ </el-upload>
|
|
417
|
+ </el-form-item>、
|
|
418
|
+ </el-form>
|
|
419
|
+ </div>
|
|
420
|
+ <span slot="footer" class="dialog-footer">
|
|
421
|
+ <el-button @click="dialogVisible5 = false">取 消</el-button>
|
|
422
|
+ <el-button type="primary" @click="handleConfirm5">确 定</el-button>
|
|
423
|
+ </span>
|
|
424
|
+ </el-dialog>
|
|
425
|
+ </el-tab-pane>
|
332
|
426
|
</el-tabs>
|
333
|
427
|
</div>
|
334
|
428
|
</template>
|
|
@@ -336,11 +430,13 @@
|
336
|
430
|
import api from "@/api/audit.js";
|
337
|
431
|
import dictionary from "@/util/dictionary";
|
338
|
432
|
import api_z from "@/api/article_z.js";
|
|
433
|
+import config from '@/config/index';
|
339
|
434
|
|
340
|
435
|
export default {
|
341
|
436
|
components: {},
|
342
|
437
|
data() {
|
343
|
438
|
return {
|
|
439
|
+ fileList: [],
|
344
|
440
|
activeName: '停车场管理',
|
345
|
441
|
columns1: [
|
346
|
442
|
{
|
|
@@ -500,6 +596,49 @@ export default {
|
500
|
596
|
finalProcessing: '',
|
501
|
597
|
legalProceedings: '',
|
502
|
598
|
},
|
|
599
|
+ columns5: [
|
|
600
|
+ {
|
|
601
|
+ label: '停车场名称',
|
|
602
|
+ key: 'parkName'
|
|
603
|
+ },
|
|
604
|
+ {
|
|
605
|
+ label: '单位名称',
|
|
606
|
+ key: 'unitName'
|
|
607
|
+ },
|
|
608
|
+ {
|
|
609
|
+ label: '资源类型',
|
|
610
|
+ key: 'resourceType'
|
|
611
|
+ },
|
|
612
|
+ {
|
|
613
|
+ label: '文件',
|
|
614
|
+ key: 'fileUrl'
|
|
615
|
+ },
|
|
616
|
+ {
|
|
617
|
+ label: '有效期',
|
|
618
|
+ key: 'effectiveTime'
|
|
619
|
+ },
|
|
620
|
+ {
|
|
621
|
+ label: '创建时间',
|
|
622
|
+ key: 'createTime'
|
|
623
|
+ }
|
|
624
|
+ ],
|
|
625
|
+ tableData5: [],
|
|
626
|
+ total5: 0,
|
|
627
|
+ pageSize5: 10,
|
|
628
|
+ pageNum5: 1,
|
|
629
|
+ formInline5: {
|
|
630
|
+ parkId: ''
|
|
631
|
+ },
|
|
632
|
+ title5: '',
|
|
633
|
+ dialogVisible5: false,
|
|
634
|
+ formLabelAlign5: {
|
|
635
|
+ id: '',
|
|
636
|
+ parkId: '',
|
|
637
|
+ unitName: '',
|
|
638
|
+ resourceType: '',
|
|
639
|
+ effectiveTime: '',
|
|
640
|
+ },
|
|
641
|
+ fileUrl: ''
|
503
|
642
|
}
|
504
|
643
|
},
|
505
|
644
|
mounted() {
|
|
@@ -508,9 +647,16 @@ export default {
|
508
|
647
|
this.getTableData2()
|
509
|
648
|
this.getTableData3()
|
510
|
649
|
this.getTableData4()
|
|
650
|
+ this.getTableData5()
|
511
|
651
|
},
|
512
|
652
|
watch: {},
|
513
|
653
|
methods: {
|
|
654
|
+ handleSuccess(response, file, fileList) {
|
|
655
|
+ this.fileUrl = response.data
|
|
656
|
+ },
|
|
657
|
+ getUrl() {
|
|
658
|
+ return process.env.NODE_ENV !== 'development' ? config.build.BASE_API : config.dev.BASE_API;
|
|
659
|
+ },
|
514
|
660
|
onSubmit1() {
|
515
|
661
|
this.pageNum1 = 1
|
516
|
662
|
this.getTableData1()
|
|
@@ -709,6 +855,55 @@ export default {
|
709
|
855
|
})
|
710
|
856
|
}
|
711
|
857
|
},
|
|
858
|
+ onSubmit5() {
|
|
859
|
+ this.pageNum5 = 1
|
|
860
|
+ this.getTableData5()
|
|
861
|
+ },
|
|
862
|
+ handleAdd5() {
|
|
863
|
+ this.title5 = '添加'
|
|
864
|
+ this.formLabelAlign5 = {}
|
|
865
|
+ this.dialogVisible5 = true
|
|
866
|
+ },
|
|
867
|
+
|
|
868
|
+ handleEdit5(row) {
|
|
869
|
+ this.title5 = '修改'
|
|
870
|
+ this.fileUrl = ''
|
|
871
|
+ this.formLabelAlign5 = {...row, effectiveTime: row.effectiveTime ? row.effectiveTime.split('~') : []}
|
|
872
|
+ this.dialogVisible5 = true
|
|
873
|
+ },
|
|
874
|
+ deleteRow5(record) {
|
|
875
|
+ api_z.deleteBazy([{id: record.id}]).then(res => {
|
|
876
|
+ if (res.code === 200) {
|
|
877
|
+ this.$message({type: 'success', message: '删除成功!'})
|
|
878
|
+ this.getTableData5()
|
|
879
|
+ }
|
|
880
|
+ })
|
|
881
|
+ },
|
|
882
|
+ handleConfirm5() {
|
|
883
|
+ if (this.title5 === '修改') {
|
|
884
|
+ api_z.editBazy({...this.formLabelAlign5, fileUrl: this.fileUrl, effectiveTime: this.formLabelAlign5.effectiveTime ? this.formLabelAlign5.effectiveTime.join('~') : ''}).then(res => {
|
|
885
|
+ if (res.code === 200) {
|
|
886
|
+ this.dialogVisible5 = false
|
|
887
|
+ this.$message({
|
|
888
|
+ message: '修改成功!',
|
|
889
|
+ type: 'success'
|
|
890
|
+ })
|
|
891
|
+ this.getTableData5()
|
|
892
|
+ }
|
|
893
|
+ })
|
|
894
|
+ } else {
|
|
895
|
+ api_z.addBazy({...this.formLabelAlign5, fileUrl: this.fileUrl, effectiveTime: this.formLabelAlign5.effectiveTime ? this.formLabelAlign5.effectiveTime.join('-') : ''}).then(res => {
|
|
896
|
+ if (res.code === 200) {
|
|
897
|
+ this.dialogVisible5 = false
|
|
898
|
+ this.$message({
|
|
899
|
+ message: '添加成功!',
|
|
900
|
+ type: 'success'
|
|
901
|
+ })
|
|
902
|
+ this.getTableData5()
|
|
903
|
+ }
|
|
904
|
+ })
|
|
905
|
+ }
|
|
906
|
+ },
|
712
|
907
|
handlePageChange1() {
|
713
|
908
|
this.getTableData1()
|
714
|
909
|
},
|
|
@@ -749,6 +944,17 @@ export default {
|
749
|
944
|
this.total4 = res.data.total
|
750
|
945
|
})
|
751
|
946
|
},
|
|
947
|
+ handlePageChange5() {
|
|
948
|
+ this.getTableData5()
|
|
949
|
+ },
|
|
950
|
+ getTableData5() {
|
|
951
|
+ const {pageNum5, pageSize5} = this
|
|
952
|
+ api_z.queryBazyByPage({current: pageNum5, size: pageSize5, ...this.formInline5}).then(res => {
|
|
953
|
+ this.tableData5 = res.data.records || []
|
|
954
|
+ this.total5 = res.data.total
|
|
955
|
+ })
|
|
956
|
+ },
|
|
957
|
+
|
752
|
958
|
}
|
753
|
959
|
}
|
754
|
960
|
</script>
|