新增幸运礼物区间和收礼人id条件查询
This commit is contained in:
@@ -3,7 +3,7 @@
|
||||
<!-- 查询 -->
|
||||
<div class="inquire" style="display: inline-block; margin-right: 20px">
|
||||
<span class="demonstration">选择礼物</span>
|
||||
<el-select v-model="inquire.giftId" placeholder="请选择">
|
||||
<el-select @change="selectGift" v-model="inquire.giftId" placeholder="请选择">
|
||||
<el-option
|
||||
v-for="item in inquire.gifts"
|
||||
:key="item.giftId"
|
||||
@@ -13,6 +13,23 @@
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div class="inquire" style="display: inline-block; margin-right: 20px">
|
||||
<span class="demonstration">选择礼物个数区间</span>
|
||||
<el-select
|
||||
@change="selectGift2"
|
||||
:disabled="disabledBool"
|
||||
v-model="inquire.value2"
|
||||
placeholder="请选择"
|
||||
>
|
||||
<el-option
|
||||
v-for="(item, i) in inquire.giftsNum"
|
||||
:key="i"
|
||||
:label="item.minValue + '~' + item.maxValue"
|
||||
:value="item.id"
|
||||
>
|
||||
</el-option>
|
||||
</el-select>
|
||||
</div>
|
||||
<div class="inquire" style="display: inline-block; margin-right: 20px">
|
||||
<span class="demonstration" style="display: inline-block">送礼用户ID</span>
|
||||
<el-input
|
||||
@@ -22,6 +39,15 @@
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<div class="inquire" style="display: inline-block; margin-right: 20px">
|
||||
<span class="demonstration" style="display: inline-block">收礼用户ID</span>
|
||||
<el-input
|
||||
style="display: inline-block"
|
||||
v-model="inquire.receiveErBanNo"
|
||||
placeholder=""
|
||||
class="input"
|
||||
></el-input>
|
||||
</div>
|
||||
<!-- 查询条件 -->
|
||||
<div class="inquire" style="display: inline-block; margin-right: 120px">
|
||||
<div class="block">
|
||||
@@ -109,6 +135,8 @@ import {
|
||||
getAll,
|
||||
getRewardList,
|
||||
luckyGiftRewardRecordExport,
|
||||
luckyGiftRewardList,
|
||||
luckyGiftRangeConfigList,
|
||||
} from "@/api/lucky/luckyGiftRangeConfig";
|
||||
import { dateFormat } from "@/utils/system-helper";
|
||||
import { ElMessage } from "element-plus";
|
||||
@@ -120,9 +148,12 @@ export default {
|
||||
// 查询条件
|
||||
inquire: {
|
||||
gifts: [],
|
||||
giftsNum: [],
|
||||
giftId: "",
|
||||
senUserId: "",
|
||||
receiveErBanNo: "",
|
||||
time: "",
|
||||
value2: "",
|
||||
},
|
||||
// 表格
|
||||
tableData: [],
|
||||
@@ -133,6 +164,7 @@ export default {
|
||||
// 内表格
|
||||
detailsDialog: false,
|
||||
tableDataIn: [],
|
||||
disabledBool: true,
|
||||
};
|
||||
},
|
||||
created() {
|
||||
@@ -146,6 +178,23 @@ export default {
|
||||
this.getData();
|
||||
},
|
||||
methods: {
|
||||
// 外部监听
|
||||
selectGift(e) {
|
||||
console.log(e);
|
||||
if (e) {
|
||||
this.disabledBool = false;
|
||||
} else {
|
||||
this.disabledBool = true;
|
||||
}
|
||||
this.inquire.giftId = e;
|
||||
luckyGiftRangeConfigList({ giftId: this.inquire.giftId }).then((res) => {
|
||||
this.inquire.giftsNum = res.data;
|
||||
});
|
||||
},
|
||||
// 外部监听2
|
||||
selectGift2(e) {
|
||||
this.inquire.value2 = e;
|
||||
},
|
||||
// 查询
|
||||
getData() {
|
||||
this.loading = true;
|
||||
@@ -160,6 +209,8 @@ export default {
|
||||
pageSize: this.pageSize,
|
||||
giftId: this.inquire.giftId,
|
||||
sendErBanNo: this.inquire.senUserId,
|
||||
receiveErBanNo: this.inquire.receiveErBanNo,
|
||||
rangeId: this.inquire.value2,
|
||||
startTime: startTime,
|
||||
endTime: endTime,
|
||||
}).then((res) => {
|
||||
@@ -187,15 +238,27 @@ export default {
|
||||
if (this.inquire.giftId == null || this.inquire.giftId == "null") {
|
||||
obj = {
|
||||
sendErBanNo: this.inquire.senUserId,
|
||||
startTime: dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss"),
|
||||
endTime: dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss"),
|
||||
startTime: this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss")
|
||||
: "",
|
||||
endTime: this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss")
|
||||
: "",
|
||||
receiveErBanNo: this.inquire.receiveErBanNo,
|
||||
rangeId: this.inquire.value2,
|
||||
};
|
||||
} else {
|
||||
obj = {
|
||||
giftId: this.inquire.giftId,
|
||||
sendErBanNo: this.inquire.senUserId,
|
||||
startTime: dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss"),
|
||||
endTime: dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss"),
|
||||
startTime: this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[0], "yyyy-MM-dd hh:mm:ss")
|
||||
: "",
|
||||
endTime: this.inquire.time[0]
|
||||
? dateFormat(this.inquire.time[1], "yyyy-MM-dd hh:mm:ss")
|
||||
: "",
|
||||
receiveErBanNo: this.inquire.receiveErBanNo,
|
||||
rangeId: this.inquire.value2,
|
||||
};
|
||||
}
|
||||
|
||||
@@ -223,6 +286,7 @@ export default {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
white-space: nowrap;
|
||||
margin-bottom: 20px;
|
||||
}
|
||||
.search {
|
||||
width: 100%;
|
||||
|
Reference in New Issue
Block a user