Commit e354d35c by 李乾广

抓拍聚类增加机位号筛选和机位号、持续时间显示

1 parent 526d1e8c
......@@ -82,6 +82,15 @@
style="width: 240px">
</a-select>
</a-form-item>
<a-form-item label="机位号:" style="padding: 5px 0">
<a-select v-model:value="queryForm.positionId"
mode="multiple"
:options="positionList"
optionFilterProp="label"
:maxTagCount="1"
style="width: 240px">
</a-select>
</a-form-item>
<a-form-item label="人员类型:" style="padding: 5px 0">
<a-select v-model:value="queryForm.personType"
mode="multiple"
......@@ -121,13 +130,13 @@
<a-date-picker v-model:value="queryForm.date" :format="'YYYY-MM-DD'" :allowClear="false" style="width: 240px"/>
</a-form-item>
<a-form-item label="选择时间:" style="padding: 5px 0">
<a-time-picker format="HH:mm:ss" valueFormat="HH:mm:ss" v-model:value="queryForm.startTime" style="width: 140px"/>
<a-time-picker format="HH:mm:ss" valueFormat="HH:mm:ss" v-model:value="queryForm.endTime" style="width: 140px"/>
<a-time-picker format="HH:mm:ss" valueFormat="HH:mm:ss" v-model:value="queryForm.startTime" style="width: 130px"/>
<a-time-picker format="HH:mm:ss" valueFormat="HH:mm:ss" v-model:value="queryForm.endTime" style="width: 130px"/>
</a-form-item>
<a-form-item label="图片数量:" style="padding: 5px 0">
<a-input v-model:value="queryForm.minPic" style="width: 129px"/>
<a-input v-model:value="queryForm.minPic" style="width: 70px"/>
<a-input v-model:value="queryForm.maxPic" style="width: 129px"/>
<a-input v-model:value="queryForm.maxPic" style="width: 70px"/>
</a-form-item>
<a-form-item style="padding: 5px 0">
<a-button type="primary" @click="clickSearch" :loading="isLoading">查询</a-button>
......@@ -226,6 +235,8 @@
<div>地点:{{ item.gate_name }}</div>
<div style="width:100%;overflow:hidden;text-overflow:ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;">商品类型:{{ formatProduct(item.productId)}}</div>
<div style="width:100%;overflow:hidden;text-overflow:ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;">机位号:{{ formatPosition(item.channelProductId)}}</div>
<div>持续时间:{{ item.duration!==null&&item.duration!==undefined&&item.duration>=0?item.duration+'秒':'--' }}</div>
</div>
</el-col>
</el-row>
......@@ -303,6 +314,7 @@ export default {
const personTypeList = ref([])
const productList = ref([])
const zoneList = ref([])
const positionList = ref([])
const gateList = ref([])
// const imgModelRef = ref();
const pagedTableDataList = computed(
......@@ -323,6 +335,7 @@ export default {
gate_id: [],
type: 0,
direction: [1, -1, 0],
positionId:[],
picType: 2,
personType: [],
date: moment(moment().format('YYYY-MM-DD'), 'YYYY-MM-DD'),
......@@ -344,6 +357,7 @@ export default {
queryForm.zone_id = searchCondition.value.zone_id;
queryForm.gate_id = searchCondition.value.gate_id;
queryForm.productId = searchCondition.value.productId;
queryForm.positionId = searchCondition.value.positionId;
queryForm.direction = searchCondition.value.direction;
queryForm.childAdult = searchCondition.value.childAdult;
queryForm.picType = searchCondition.value.picType;
......@@ -368,14 +382,13 @@ export default {
const onAccountChange = function() {
getProductList(1)
getPlazaList(1)
// getZoneList()
// getGateList()
}
const onPlazaChange = function() {
reqPersonType()
getZoneList()
getGateList()
getPositionList()
}
const onZoneChange = function() {
......@@ -434,6 +447,7 @@ export default {
reqPersonType(1)
getZoneList(1)
getGateList(1)
getPositionList(1)
}
}
}
......@@ -509,6 +523,30 @@ export default {
}
)
}
const getPositionList = function(val) {
positionList.value = []
clusterResultApi.getPositionList({plaza_id: queryForm.plaza_id}).then((res) => {
if (res.msg_code==200){
let list = res.data
for (const item of list){
positionList.value.push({
value: item.id,
label: item.name+'('+item.positionNo+')',
})
}
if(positionList.value.length){
if(val&&searchCondition.value.positionId && searchCondition.value.positionId.length>0){
queryForm.positionId = searchCondition.value.positionId
}else{
queryForm.positionId = []
}
}else{
queryForm.positionId = []
}
console.log(positionList.value)
}
})
}
......@@ -566,6 +604,7 @@ export default {
plaza_id: rawData.plaza_id,
productId: rawData.productId?rawData.productId.toString():'',
zone_id: rawData.zone_id?rawData.zone_id.toString():'',
positionId: rawData.positionId?rawData.positionId.toString():'',
gate_id: rawData.gate_id?rawData.gate_id.toString():'',
direction: rawData.direction?rawData.direction.toString():'',
picType: rawData.picType,
......@@ -589,6 +628,7 @@ export default {
plaza_id: [rawData.plaza_id],
productId: rawData.productId,
zone_id: rawData.zone_id,
positionId: rawData.positionId,
gate_id: rawData.gate_id,
direction: rawData.direction,
picType: rawData.picType,
......@@ -694,6 +734,9 @@ export default {
const formatProduct = function(val) {
return (productList.value.filter(v => v.value == val)[0] || {label:'--'}).label
}
const formatPosition = function(val) {
return (positionList.value.filter(v => v.value == val)[0] || {label:'--'}).label
}
const sortDataList = function(list) {
if(queryForm.sortType==1) {
list.sort(
......@@ -1159,6 +1202,7 @@ export default {
personTypeList,
productList,
zoneList,
positionList,
gateList,
pagedTableDataList,
dataList,
......@@ -1174,6 +1218,7 @@ export default {
confirmSearch,
formatDirection,
formatProduct,
formatPosition,
downloadFile,
getPagedList,
handleClick,
......@@ -1237,7 +1282,7 @@ export default {
.classBox{
margin: 10px 0;
border: solid 1px black;
height: 507px;
height: 570px;
overflow-y: hidden;
}
.expand{
......
......@@ -63,6 +63,19 @@ class ClusterResultApi {
}
)
}
getPositionList(data) {
return axiosInstance.request(
{
method: 'GET',
url: `/channelProduct/list`,
params: filterEmptyValueInObject(
{
mallId: data.plaza_id,
},
)
}
)
}
// 查询系统级人员类型
getPersonType(data) {
return axiosInstance.request(
......
......@@ -77,7 +77,16 @@
:options="productList"
optionFilterProp="label"
:maxTagCount="1"
style="width: 240px">
style="width: 280px">
</a-select>
</a-form-item>
<a-form-item label="机位号:" style="padding: 5px 0">
<a-select v-model:value="queryForm.positionId"
mode="multiple"
:options="positionList"
optionFilterProp="label"
:maxTagCount="1"
style="width: 280px">
</a-select>
</a-form-item>
<a-form-item label="人员类型:" style="padding: 5px 0">
......@@ -86,7 +95,7 @@
:options="personTypeList"
optionFilterProp="label"
:maxTagCount="1"
style="width: 240px">
style="width: 280px">
</a-select>
</a-form-item>
<a-form-item label="年龄类型:" style="padding: 5px 0">
......@@ -193,6 +202,8 @@
<div class="direction" :class="'direction'+item.direction">方向:{{ formatDirection(item.direction) }}</div>
<div>地点:{{ item.gate_name }}</div>
<div style="width:100%;overflow:hidden;text-overflow:ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;">商品类型:{{ formatProduct(item.productId)}}</div>
<div style="width:100%;overflow:hidden;text-overflow:ellipsis;display: -webkit-box;-webkit-line-clamp: 2;-webkit-box-orient: vertical;">机位号:{{ formatPosition(item.channelProductId)}}</div>
<div>持续时间:{{ item.duration!==null&&item.duration!==undefined&&item.duration>=0?item.duration+'秒':'--' }}</div>
</div>
</el-col>
</el-row>
......@@ -247,6 +258,7 @@ export default {
const plazaList = ref([])
const personTypeList = ref([])
const zoneList = ref([])
const positionList = ref([])
const gateList = ref([])
const imgModelRef = ref();
const currentItemId = ref()
......@@ -269,6 +281,7 @@ export default {
gate_id: [],
type: 0,
direction: [1, -1, 0],
positionId:[],
picType: 2,
personType: [],
date: moment(moment().format('YYYY-MM-DD'), 'YYYY-MM-DD'),
......@@ -285,6 +298,7 @@ export default {
queryForm.zone_id = searchCondition.value.zone_id;
queryForm.gate_id = searchCondition.value.gate_id;
queryForm.productId = searchCondition.value.productId;
queryForm.positionId = searchCondition.value.positionId;
queryForm.direction = searchCondition.value.direction;
queryForm.childAdult = searchCondition.value.childAdult;
queryForm.picType = searchCondition.value.picType;
......@@ -307,14 +321,13 @@ export default {
const onAccountChange = function() {
getPlazaList(1)
getProductList(1)
// getZoneList()
// getGateList()
}
const onPlazaChange = function() {
reqPersonType()
getZoneList()
getGateList()
getPositionList()
}
const onZoneChange = function() {
......@@ -348,6 +361,7 @@ export default {
reqPersonType(1)
getZoneList(1)
getGateList(1)
getPositionList(1)
}
}
}
......@@ -448,6 +462,30 @@ export default {
}
)
}
const getPositionList = function(val) {
positionList.value = []
snapshotRecordApi.getPositionList({plaza_id: queryForm.plaza_id}).then((res) => {
if (res.msg_code==200){
let list = res.data
for (const item of list){
positionList.value.push({
value: item.id,
label: item.name+'('+item.positionNo+')',
})
}
if(positionList.value.length){
if(val&&searchCondition.value.positionId && searchCondition.value.positionId.length>0){
queryForm.positionId = searchCondition.value.positionId
}else{
queryForm.positionId = []
}
}else{
queryForm.positionId = []
}
console.log(positionList.value)
}
})
}
const getAccountList = function() {
queryForm.account_id = ''
......@@ -512,6 +550,7 @@ export default {
plaza_id: rawData.plaza_id,
productId: rawData.productId?rawData.productId.toString():'',
zone_id: rawData.zone_id?rawData.zone_id.toString():'',
positionId: rawData.positionId?rawData.positionId.toString():'',
gate_id: rawData.gate_id?rawData.gate_id.toString():'',
direction: rawData.direction?rawData.direction.toString():'',
picType: rawData.picType,
......@@ -530,6 +569,7 @@ export default {
plaza_id: [rawData.plaza_id],
productId: rawData.productId,
zone_id: rawData.zone_id,
positionId: rawData.positionId,
gate_id: rawData.gate_id,
direction: rawData.direction,
picType: rawData.picType,
......@@ -577,6 +617,9 @@ export default {
const formatProduct = function(val) {
return (productList.value.filter(v => v.value == val)[0] || {label:'--'}).label
}
const formatPosition = function(val) {
return (positionList.value.filter(v => v.value == val)[0] || {label:'--'}).label
}
const formatGender = function(number){
switch (number)
{
......@@ -1350,7 +1393,7 @@ export default {
const imgHeight = ref(0)
const __main = function() {
getAccountList()
contentHeight.value = window.innerHeight - 280
contentHeight.value = window.innerHeight - 320
imgHeight.value = (((window.innerWidth - 240)/8)-10)*1.21
}
......@@ -1369,6 +1412,7 @@ export default {
productList,
personTypeList,
zoneList,
positionList,
gateList,
pagedTableDataList,
currentItemId,
......@@ -1401,6 +1445,7 @@ export default {
singleComparativeFun,
singleImgComparisonRef,
formatProduct,
formatPosition,
personUnidClick,
hairStyleStr,
hatStr,
......
......@@ -87,7 +87,19 @@ class SnapshotRecordApi {
}
)
}
getPositionList(data) {
return axiosInstance.request(
{
method: 'GET',
url: `/channelProduct/list`,
params: filterEmptyValueInObject(
{
mallId: data.plaza_id,
},
)
}
)
}
getGateList(data) {
return axiosInstance.request(
{
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!