fanfan 8 months ago
commit 37880d00da
  1. 12
      src/views/content/maintenance/Index.vue
  2. 6
      src/views/content/maintenance/modules/AddForm.vue
  3. 7
      src/views/content/maintenance/modules/EditForm.vue

@ -18,7 +18,7 @@
>{{ item.name }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item class="search-btn">
<a-button type="primary" icon="search" html-type="submit">搜索</a-button>
</a-form-item>
@ -41,6 +41,11 @@
<span slot="name" slot-scope="text">
<p class="twoline-hide">{{ text }}</p>
</span>
<span slot="img_url" slot-scope="text">
<a v-if="text" title="点击查看原图" :href="text" target="_blank">
<img height="50" :src="text" alt="分类图片" />
</a>
</span>
<!-- 所属分类 -->
<span slot="category" slot-scope="text">{{ text.name }}</span>
<!-- 状态 -->
@ -71,6 +76,11 @@ const columns = [
title: 'ID',
dataIndex: 'id'
},
{
title: '维修图片',
dataIndex: 'img_url',
scopedSlots: { customRender: 'img_url' }
},
{
title: '维修名称',
dataIndex: 'name'

@ -27,9 +27,9 @@
>{{ item.name }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item label="维修链接" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input
v-decorator="['url', { rules: [{ required: true, min: 2, message: '请输入至少2个字符' }] }]"
<a-form-item label="维修图片" :labelCol="labelCol" :wrapperCol="wrapperCol">
<SelectImage
v-decorator="['img_id', { rules: [{ required: true, message: '请上传维修图片' }] }]"
/>
</a-form-item>
<a-form-item label="排序" :labelCol="labelCol" :wrapperCol="wrapperCol" extra="数字越小越靠前">

@ -27,9 +27,10 @@
>{{ item.name }}</a-select-option>
</a-select>
</a-form-item>
<a-form-item label="维修链接" :labelCol="labelCol" :wrapperCol="wrapperCol">
<a-input
v-decorator="['url', { rules: [{ required: true, min: 2, message: '请输入至少2个字符' }] }]"
<a-form-item label="维修图片" :labelCol="labelCol" :wrapperCol="wrapperCol">
<SelectImage
:defaultList="record.img ? [record.img] : []"
v-decorator="['img_id', { rules: [{ required: true, message: '请上传维修图片' }] }]"
/>
</a-form-item>
<a-form-item label="排序" :labelCol="labelCol" :wrapperCol="wrapperCol" extra="数字越小越靠前">

Loading…
Cancel
Save