Commit c955ce68 authored by 陈明豪's avatar 陈明豪

bug修改

parent 948d11e9
......@@ -20,10 +20,11 @@
<el-input v-model.trim="form.title" class="form-input" maxlength="20" show-word-limit clearable disabled />
</el-form-item>
<el-form-item label="轮播图" prop="img">
<ImagePreview :src="baseUrl + form.img" :width="150" :height="150" />
<ImagePreview v-if="form.img" :src="baseUrl + form.img" :width="150" :height="150" style="box-shadow: none" />
<ImagePreview v-else :src="'123'" :width="150" :height="150" style="box-shadow: none" />
</el-form-item>
<el-form-item label="跳转地址" prop="url">
<el-input :placeholder="form.url || '-'" class="form-input" maxlength="30" show-word-limit clearable disabled />
<el-input v-model="form.url" class="form-input" maxlength="30" show-word-limit clearable disabled />
</el-form-item>
<el-form-item label="权重" prop="sort">
<el-input-number
......@@ -37,7 +38,7 @@
/>
</el-form-item>
<el-form-item label="创建日期" prop="createTime">
<el-input disabled="true" :placeholder="form.createTime" style="width: 25%" />
<el-input v-model="form.createTime" disabled="true" style="width: 25%" />
</el-form-item>
<el-form-item label="状态" prop="status">
<span style="height: 2.5rem;line-height: 2.5rem">
......@@ -52,7 +53,7 @@
</span>
</el-form-item>
<el-form-item label="备注" prop="notes">
<el-input :placeholder="form.notes || '-'" type="textarea" rows="3" disabled class="form-input" maxlength="60" clearable />
<el-input v-model="form.notes" type="textarea" rows="3" class="disText" disabled maxlength="60" clearable />
</el-form-item>
<el-form-item>
<el-button class="resetBtn" icon="el-icon-back" @click="goBack">返回</el-button>
......@@ -97,12 +98,12 @@ export default {
getBanner(this.id).then(res => {
if (res.code === 200) {
this.form = res.data
// if (this.form.url === undefined || this.form.url === null || this.form.url === '') {
// this.form.url = '暂无数据'
// }
// if (this.form.notes === undefined || this.form.notes === null || this.form.notes === '') {
// this.form.notes = '暂无数据'
// }
if (this.form.url === undefined || this.form.url === null || this.form.url === '') {
this.form.url = '-'
}
if (this.form.notes === undefined || this.form.notes === null || this.form.notes === '') {
this.form.notes = '-'
}
}
})
},
......@@ -170,4 +171,10 @@ export default {
color: #333333;
line-height: 24px;
}
::v-deep .el-textarea.is-disabled .el-textarea__inner {
color: #333 !important;
background-color: #f4f4f4 !important;
}
</style>
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment