联调
改名
This commit is contained in:
parent
df55ab8ede
commit
72e67c6618
31
src/components/FormCol/index.vue
Normal file
31
src/components/FormCol/index.vue
Normal file
|
@ -0,0 +1,31 @@
|
||||||
|
<template>
|
||||||
|
<el-col :span="span">
|
||||||
|
<el-form-item :label="label" :prop="prop" :label-width="labelWidth">
|
||||||
|
<slot></slot>
|
||||||
|
</el-form-item>
|
||||||
|
</el-col>
|
||||||
|
</template>
|
||||||
|
|
||||||
|
<script>
|
||||||
|
export default {
|
||||||
|
name: 'FormCol',
|
||||||
|
props: {
|
||||||
|
span: {
|
||||||
|
type: Number,
|
||||||
|
default: 24
|
||||||
|
},
|
||||||
|
label: {
|
||||||
|
type: String,
|
||||||
|
default: null
|
||||||
|
},
|
||||||
|
prop: {
|
||||||
|
type: String,
|
||||||
|
default: null
|
||||||
|
},
|
||||||
|
labelWidth: {
|
||||||
|
type: String,
|
||||||
|
default: null
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
|
@ -37,6 +37,8 @@ import DictTag from '@/components/DictTag'
|
||||||
import VueMeta from 'vue-meta'
|
import VueMeta from 'vue-meta'
|
||||||
// 字典数据组件
|
// 字典数据组件
|
||||||
import DictData from '@/components/DictData'
|
import DictData from '@/components/DictData'
|
||||||
|
// 行内表单组件
|
||||||
|
import FormCol from '@/components/FormCol/index.vue'
|
||||||
|
|
||||||
// 全局方法挂载
|
// 全局方法挂载
|
||||||
Vue.prototype.getDicts = getDicts
|
Vue.prototype.getDicts = getDicts
|
||||||
|
@ -57,6 +59,7 @@ Vue.component('Editor', Editor)
|
||||||
Vue.component('FileUpload', FileUpload)
|
Vue.component('FileUpload', FileUpload)
|
||||||
Vue.component('ImageUpload', ImageUpload)
|
Vue.component('ImageUpload', ImageUpload)
|
||||||
Vue.component('ImagePreview', ImagePreview)
|
Vue.component('ImagePreview', ImagePreview)
|
||||||
|
Vue.component('FormCol', FormCol)
|
||||||
|
|
||||||
Vue.use(directive)
|
Vue.use(directive)
|
||||||
Vue.use(plugins)
|
Vue.use(plugins)
|
||||||
|
|
|
@ -76,14 +76,13 @@
|
||||||
<el-table-column label="满电电压(V)" align="center" prop="fullVoltage" />
|
<el-table-column label="满电电压(V)" align="center" prop="fullVoltage" />
|
||||||
<el-table-column label="亏电电压(V)" align="center" prop="lowVoltage" />
|
<el-table-column label="亏电电压(V)" align="center" prop="lowVoltage" />
|
||||||
<el-table-column label="满电续航(km)" align="center" prop="fullEndurance" />
|
<el-table-column label="满电续航(km)" align="center" prop="fullEndurance" />
|
||||||
<el-table-column label="骑行低电量提醒(%)" align="center" prop="lowBatteryReminder" />
|
<el-table-column label="押金" align="center" prop="deposit" />
|
||||||
<el-table-column label="已投放车辆" align="center" prop="deviceNum" />
|
<el-table-column label="图片" align="center" prop="picture" width="100">
|
||||||
<el-table-column label="创建时间" align="center" prop="createTime" width="180">
|
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<span>{{ parseTime(scope.row.createTime, '{y}-{m}-{d}') }}</span>
|
<image-preview :src="scope.row.picture" :width="50" :height="50"/>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
<el-table-column label="备注" align="center" prop="remark" />
|
<el-table-column label="描述" align="center" prop="description" />
|
||||||
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
<el-table-column label="操作" align="center" class-name="small-padding fixed-width">
|
||||||
<template slot-scope="scope">
|
<template slot-scope="scope">
|
||||||
<el-button
|
<el-button
|
||||||
|
@ -137,8 +136,22 @@
|
||||||
<el-form-item label="满电续航(KM)" label-width="90" prop="fullEndurance">
|
<el-form-item label="满电续航(KM)" label-width="90" prop="fullEndurance">
|
||||||
<el-input style="width: 80%" v-model="form.fullEndurance" placeholder="请输入满电续航" />
|
<el-input style="width: 80%" v-model="form.fullEndurance" placeholder="请输入满电续航" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="骑行低电量提醒(%)" label-width="120" prop="lowBatteryReminder">
|
<el-form-item label="备注" prop="remark" label-width="100px">
|
||||||
<el-input style="width: 78%" v-model="form.lowBatteryReminder" placeholder="请输入骑行低电量提醒" />
|
<el-input v-model="form.remark" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="简介" prop="intro" label-width="100px">
|
||||||
|
<el-input v-model="form.intro" type="textarea" placeholder="请输入内容" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-form-item label="押金" prop="deposit" label-width="100px">
|
||||||
|
<el-input v-model="form.deposit" placeholder="请输入押金" />
|
||||||
|
</el-form-item>
|
||||||
|
<el-table-column label="商户图片" align="center" prop="picture" width="100" label-width="100px">
|
||||||
|
<form-col label="店铺图片" prop="picture" :span="span * 2">
|
||||||
|
<image-upload v-model="form.picture" :limit="1" />
|
||||||
|
</form-col>
|
||||||
|
</el-table-column>
|
||||||
|
<el-form-item label="描述" prop="description" label-width="100px">
|
||||||
|
<el-input v-model="form.description" type="textarea" placeholder="请输入内容" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
</el-form>
|
</el-form>
|
||||||
<div slot="footer" class="dialog-footer">
|
<div slot="footer" class="dialog-footer">
|
||||||
|
|
Loading…
Reference in New Issue
Block a user