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
| <template>
| <div class="add-common">
| <el-dialog
| :title="'相关供应商'"
| :visible.sync="editConfig.visible"
| :width="dialogWidth"
| :before-close="handleClose"
| :close-on-click-modal="false"
| append-to-body
| custom-class="iframe-dialog"
| >
| <div class="table-view">
| <TableCommonView ref="tableListRef" :table-list="tableList" @selCommonClick="selCommonClick"> </TableCommonView>
| <div class="btn-pager">
| <PagerView class="page" :pager-options="pagerOptions" v-on="pagerEvents" />
| </div>
| </div>
| <div slot="footer" class="dialog-footer"></div>
| </el-dialog>
| </div>
| </template>
|
| <script>
| // import SelectClientDialog from "@/views/other/commonDialog/SelectClientDialog"
| import pageMixin from "@/components/makepager/pager/mixin/pageMixin"
| export default {
| name: "AddSupplierDialog",
| mixins: [pageMixin],
| props: {
| commonConfig: {
| type: Object,
| default: () => {
| return {
| visible: false,
| infomation: {}
| }
| }
| }
| },
| components: {},
| computed: {},
| data() {
| return {
| dialogWidth: "80%",
| editConfig: this.commonConfig,
| tableList: {}
| }
| },
| created() {
| this.setTable()
| },
| methods: {
| setTable() {
| this.tableList = {
| tableInfomation: [],
| selectIndex: true,
| tableColumn: [
| { label: "供应商编号", prop: "number", min: 190, isCommonClick: true },
| { label: "供应商名称", prop: "name", min: 130 },
| { label: "采购价格", prop: "contact_name", min: 130 },
| { label: "供货天数", prop: "contact_phone", min: 130 },
| { label: "物流时长(天)", prop: "sales_resources", min: 130 }
| ]
| }
| },
| handleClose() {
| this.editConfig.visible = false
| },
| selCommonClick(row) {
| console.log(row)
| // this.commonDetail.visible = true
| // this.commonDetail.infomation = { ...row }
| }
| }
| }
| </script>
|
| <!-- Add "scoped" attribute to limit CSS to this component only -->
| <style lang="scss" scoped>
| ::v-deep {
| .iframe-dialog .el-dialog__body {
| .table-view {
| margin: 10px;
| .btn-pager {
| display: flex;
| align-items: center;
| .page {
| margin-left: auto;
| }
| }
| }
| }
| .el-dialog__footer {
| background-color: #ffffff;
| height: 10px;
| border-top: 0px;
| }
| }
| </style>
|
|