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
<template>
<div>
<el-card class="box-card" :class="[isShowCard ? '' : 'is-show-card']" >
<c-col :span="24" v-if="isRef">
<el-form-item
:label="label.labelRef"
:prop="`${argadr.grp}.${argadr.rol}.pts.extkey`"
style="width: 100%"
>
<c-input
v-model.trim="model[argadr.grp][argadr.rol].pts.extkey"
placeholder=""
maxlength="16"
:disabled="disabledRef"
>
</c-input>
</el-form-item>
</c-col>
<c-col :span="24" v-else>
<el-form-item
:label="label.labelRef"
:prop="`${argadr.grp}.rec.${refd}`"
style="width: 100%"
>
<c-input
v-model.trim="model[argadr.grp].rec[refd]"
placeholder=""
maxlength="16"
:disabled="disabledRef"
>
</c-input>
</el-form-item>
</c-col>
<c-col :span="24">
<el-form-item
:label="label.labelNam"
:prop="`${argadr.grp}.${argadr.rol}.pts.nam`"
style="width: 100%"
>
<c-mul-row-input
type="textarea"
:rows="rows"
:cols="cols"
:charmod="charmod"
v-model="model[argadr.grp][argadr.rol].pts.nam"
placeholder=""
:disabled="disabledNam"
>
</c-mul-row-input>
</el-form-item>
</c-col>
</el-card>
</div>
</template>
<script>
export default {
inject: ["root"],
props: {
model: {
type: Object,
default: () => {}
},
argadr: {
type: Object,
default: function() {
return {
rol: "", //角色
grp: "" //所属模块
};
}
},
isRef:{
type:Boolean,
default: true
},
refd:{
type:String,
default: ''
},
label: {
type: Object,
default: function() {
return {
labelRef: "", //Ref标题
labelNam: "" //Nam标题
};
}
},
charmod: {
type: Number,
default: 0
},
isShowCard: {
type: Boolean,
default: true
},
disabledRef: {
//Ref是否灰显(true:Ref处灰显)
type: Boolean,
default: false
},
disabledNam: {
//nam是否灰显(true:nam处灰显)
type: Boolean,
default: false
},
rows: {
type: Number,
default: 4
},
cols: {
type: Number,
default: 70
},
},
data() {
return {
};
},
watch: {},
methods: {},
};
</script>
<style scoped lang="less">
.box-card {
margin-bottom: 10px;
/deep/ .el-form-item--mini.el-form-item,
.el-form-item--small.el-form-item {
margin-bottom: 10px;
}
/deep/ .el-card__body {
padding: 10px 10px 10px 0px;
}
}
.is-show-card {
border: none !important;
box-shadow: none !important;
margin-bottom: 0 !important;
/deep/ .el-card__body {
padding: 0 !important;
}
}
</style>