Browse Source

优化

master
zhanyunjiu 3 years ago
parent
commit
32cddbfc63
  1. 8
      src/views/farm/discuss/index.vue
  2. 6
      src/views/farm/project/index.vue
  3. 4
      src/views/farm/task/index.vue

8
src/views/farm/discuss/index.vue

@ -5,12 +5,12 @@
<el-form :model="queryParams" ref="queryForm" size="small" :inline="true" v-show="showSearch" label-width="68px">
<el-form-item label="项目名" prop="projectId">
<el-select v-model="queryParams.projectId" filterable placeholder="请单选">
<el-option v-for="item in projectList" :key="item.id" :label="item.name" :value="item.id">
{{ item.name }}
<el-option v-for="item in projectList" :key="item.id" :label="item.id" :value="item.id">
{{ item.id }}
</el-option>
</el-select>
</el-form-item>
<el-form-item label="讨论发表时间">
<el-form-item label="创建时间">
<el-date-picker v-model="dateRangeCreateTime" style="width: 240px" value-format="yyyy-MM-dd"
type="daterange" range-separator="-" start-placeholder="开始日期" end-placeholder="结束日期" />
</el-form-item>
@ -39,7 +39,7 @@
<!-- 列表 -->
<el-table v-loading="loading" stripe :data="list">
<el-table-column label="讨论ID" align="center" prop="id" />
<el-table-column label="项目ID名" align="center" prop="projectId">
<el-table-column label="项目ID/名" align="center" prop="projectId">
<template slot-scope="scope">
<span v-if="scope.row.projectId">{{convertProject(scope.row.projectId)}}</span>
</template>

6
src/views/farm/project/index.vue

@ -183,7 +183,7 @@
</el-select>
</el-form-item> -->
<el-form-item label="育苗日期" prop="growSeedTime">
<el-date-picker clearable v-model="form.growSeedTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss" placeholder="选择" />
<el-date-picker clearable v-model="form.growSeedTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss" placeholder="决定项目状态" />
</el-form-item>
<el-form-item label="种植日期" prop="plantTime">
<el-date-picker clearable v-model="form.plantTime" type="datetime" value-format="yyyy-MM-dd HH:mm:ss" placeholder="选择" />
@ -199,8 +199,8 @@
</el-form-item>
<el-form-item label="项目状态" prop="state">
<el-radio-group v-model="form.state">
<el-radio :label="0">计划中</el-radio>
<el-radio :label="1">进行中</el-radio>
<el-radio :label="0" :disabled="true">计划中</el-radio>
<el-radio :label="1" :disabled="true">进行中</el-radio>
<el-radio :label="2">已完成</el-radio>
</el-radio-group>
</el-form-item>

4
src/views/farm/task/index.vue

@ -102,7 +102,7 @@
</el-table-column>
<el-table-column label="项目名" fixed align="center" prop="projectName">
<template slot-scope="scope">
<span>{{scope.row.projectName}}</span>
<span>{{scope.row.projectName != undefind ? scope.row.projectName : scope.row.id}}</span>
</template>
</el-table-column>
<el-table-column label="负责人" align="center" prop="mainPerson">
@ -477,7 +477,7 @@ export default {
}).then(res => {
this.projectList = res.data.list;
this.projectList.forEach(item =>{
item.name == undefined ? item.name = "暂无项目名" : item.name;
item.name == undefined ? item.name = item.id : item.name;
})
})
},

Loading…
Cancel
Save