update
This commit is contained in:
parent
00830de89a
commit
ec023ecfc0
|
@ -2,38 +2,6 @@
|
||||||
<div>
|
<div>
|
||||||
<el-card class="!border-none mb-4" shadow="never">
|
<el-card class="!border-none mb-4" shadow="never">
|
||||||
<el-form class="mb-[-16px]" :model="queryParams" inline>
|
<el-form class="mb-[-16px]" :model="queryParams" inline>
|
||||||
<el-form-item label="用户ID" prop="user_id">
|
|
||||||
<el-input
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.user_id"
|
|
||||||
clearable
|
|
||||||
placeholder="请输入用户ID"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="土地ID" prop="land_id">
|
|
||||||
<el-input
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.land_id"
|
|
||||||
clearable
|
|
||||||
placeholder="请输入土地ID"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="产品ID" prop="product_id">
|
|
||||||
<el-input
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.product_id"
|
|
||||||
clearable
|
|
||||||
placeholder="请输入产品ID"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="设备编码" prop="code">
|
|
||||||
<el-input
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.code"
|
|
||||||
clearable
|
|
||||||
placeholder="请输入设备编码"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="设备名称" prop="name">
|
<el-form-item label="设备名称" prop="name">
|
||||||
<el-input
|
<el-input
|
||||||
class="w-[280px]"
|
class="w-[280px]"
|
||||||
|
@ -42,54 +10,7 @@
|
||||||
placeholder="请输入设备名称"
|
placeholder="请输入设备名称"
|
||||||
/>
|
/>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="设备类型" prop="type">
|
|
||||||
<el-select
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.type"
|
|
||||||
clearable
|
|
||||||
placeholder="请选择设备类型"
|
|
||||||
>
|
|
||||||
<el-option label="全部" value=""></el-option>
|
|
||||||
<el-option
|
|
||||||
v-for="(item, index) in dictData.device_type"
|
|
||||||
:key="index"
|
|
||||||
:label="item.name"
|
|
||||||
:value="item.value"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="设备状态" prop="status">
|
|
||||||
<el-select
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.status"
|
|
||||||
clearable
|
|
||||||
placeholder="请选择设备状态"
|
|
||||||
>
|
|
||||||
<el-option label="全部" value=""></el-option>
|
|
||||||
<el-option
|
|
||||||
v-for="(item, index) in dictData.device_status"
|
|
||||||
:key="index"
|
|
||||||
:label="item.name"
|
|
||||||
:value="item.value"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="是否在线" prop="is_online">
|
|
||||||
<el-select
|
|
||||||
class="w-[280px]"
|
|
||||||
v-model="queryParams.is_online"
|
|
||||||
clearable
|
|
||||||
placeholder="请选择是否在线"
|
|
||||||
>
|
|
||||||
<el-option label="全部" value=""></el-option>
|
|
||||||
<el-option
|
|
||||||
v-for="(item, index) in dictData.device_online_status"
|
|
||||||
:key="index"
|
|
||||||
:label="item.name"
|
|
||||||
:value="item.value"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="resetPage">查询</el-button>
|
<el-button type="primary" @click="resetPage">查询</el-button>
|
||||||
<el-button @click="resetParams">重置</el-button>
|
<el-button @click="resetParams">重置</el-button>
|
||||||
|
@ -130,18 +51,14 @@
|
||||||
prop="name"
|
prop="name"
|
||||||
show-overflow-tooltip
|
show-overflow-tooltip
|
||||||
/>
|
/>
|
||||||
<el-table-column label="设备类型" width="150" prop="type">
|
|
||||||
|
<el-table-column label="所属养殖基地" width="200">
|
||||||
<template #default="{ row }">
|
<template #default="{ row }">
|
||||||
<dict-value :options="dictData.device_type" :value="row.type" />
|
<el-tag class="mr-2" v-if="row.farm_id != null" type="info"
|
||||||
</template>
|
>ID: {{ row.farm_id }}</el-tag
|
||||||
</el-table-column>
|
|
||||||
<el-table-column label="所属土地" width="200">
|
|
||||||
<template #default="{ row }">
|
|
||||||
<el-tag class="mr-2" v-if="row.land_id != null" type="info"
|
|
||||||
>ID: {{ row.land_id }}</el-tag
|
|
||||||
>
|
>
|
||||||
<el-tag class="mr-2" v-if="row.land_title != null" type="info"
|
<el-tag class="mr-2" v-if="row.farm_name != null" type="info"
|
||||||
>名称: {{ row.land_title }}</el-tag
|
>名称: {{ row.farm_name }}</el-tag
|
||||||
>
|
>
|
||||||
</template>
|
</template>
|
||||||
</el-table-column>
|
</el-table-column>
|
||||||
|
@ -266,7 +183,7 @@ if (typeof product_id == 'undefined') {
|
||||||
// 查询条件
|
// 查询条件
|
||||||
const queryParams = reactive({
|
const queryParams = reactive({
|
||||||
user_id: '',
|
user_id: '',
|
||||||
land_id: '',
|
farm_id: '',
|
||||||
product_id: product_id,
|
product_id: product_id,
|
||||||
code: '',
|
code: '',
|
||||||
name: '',
|
name: '',
|
||||||
|
|
|
@ -62,12 +62,12 @@
|
||||||
</el-select>
|
</el-select>
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
|
|
||||||
<el-form-item label="所属土地" prop="land_id">
|
<el-form-item label="所属养殖基地" prop="farm_id">
|
||||||
<el-select
|
<el-select
|
||||||
v-model="formData.land_id"
|
v-model="formData.farm_id"
|
||||||
remote
|
remote
|
||||||
filterable
|
filterable
|
||||||
placeholder="请输入土地信息"
|
placeholder="请选择"
|
||||||
:remote-method="queryLand"
|
:remote-method="queryLand"
|
||||||
:loading="loading"
|
:loading="loading"
|
||||||
>
|
>
|
||||||
|
@ -131,7 +131,7 @@ const formData = reactive({
|
||||||
id: '',
|
id: '',
|
||||||
user_id: '',
|
user_id: '',
|
||||||
root: 0,
|
root: 0,
|
||||||
land_id: '',
|
farm_id: '',
|
||||||
code: '',
|
code: '',
|
||||||
name: '',
|
name: '',
|
||||||
desc: '',
|
desc: '',
|
||||||
|
|
|
@ -6,35 +6,9 @@
|
||||||
:model="queryParams"
|
:model="queryParams"
|
||||||
inline
|
inline
|
||||||
>
|
>
|
||||||
<el-form-item label="用户ID" prop="user_id">
|
|
||||||
<el-input class="w-[280px]" v-model="queryParams.user_id" clearable placeholder="请输入用户ID" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="土地ID" prop="land_id">
|
|
||||||
<el-input class="w-[280px]" v-model="queryParams.land_id" clearable placeholder="请输入土地ID" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="产品编号" prop="code">
|
|
||||||
<el-input class="w-[280px]" v-model="queryParams.code" clearable placeholder="请输入产品编号" />
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="产品名称" prop="name">
|
<el-form-item label="产品名称" prop="name">
|
||||||
<el-input class="w-[280px]" v-model="queryParams.name" clearable placeholder="请输入产品名称" />
|
<el-input class="w-[280px]" v-model="queryParams.name" clearable placeholder="请输入产品名称" />
|
||||||
</el-form-item>
|
</el-form-item>
|
||||||
<el-form-item label="产品状态" prop="status">
|
|
||||||
<el-select class="w-[280px]" v-model="queryParams.status" clearable placeholder="请选择产品状态">
|
|
||||||
<el-option label="全部" value=""></el-option>
|
|
||||||
<el-option
|
|
||||||
v-for="(item, index) in dictData.product_status"
|
|
||||||
:key="index"
|
|
||||||
:label="item.name"
|
|
||||||
:value="item.value"
|
|
||||||
/>
|
|
||||||
</el-select>
|
|
||||||
</el-form-item>
|
|
||||||
<el-form-item label="创建时间" prop="create_time">
|
|
||||||
<daterange-picker
|
|
||||||
v-model:startTime="queryParams.start_time"
|
|
||||||
v-model:endTime="queryParams.end_time"
|
|
||||||
/>
|
|
||||||
</el-form-item>
|
|
||||||
|
|
||||||
<el-form-item>
|
<el-form-item>
|
||||||
<el-button type="primary" @click="resetPage">查询</el-button>
|
<el-button type="primary" @click="resetPage">查询</el-button>
|
||||||
|
|
Loading…
Reference in New Issue