Commit d35a0ca8 authored by 黄奎's avatar 黄奎

yemian

parent 85a77aaf
......@@ -8,6 +8,9 @@
<div class="col-3">
<q-input @input="resetSearch" clearable filled v-model="msg.CustomerName" label="客户名称" />
</div>
<div class="col-3">
<q-input @input="resetSearch" clearable filled v-model="msg.ExchangeCode" label="兑换码" />
</div>
<div class="col-3">
<q-select @input="resetSearch" option-value="Id" option-label="Name" clearable filled
v-model="msg.ExchangeStatus" :options="StatusList" emit-value map-options label="状态" />
......@@ -35,8 +38,9 @@
</template>
<template v-slot:body-cell-optioned="props">
<q-td>
<q-btn v-if="props.row.ExchangeStatus==1" flat size="xs" icon="iconfont icon-view" style="font-weight:400" label="兑换"
@click="exchangeKudo(props.row)" />
@click="exchangeKudo(props.row)" />
<q-btn flat size="xs" icon="iconfont icon-view" style="font-weight:400" label="详情"
@click="goToDetail(props.row)" />
</q-td>
......@@ -121,6 +125,7 @@
TaskName: "", //任务
CustomerName: "", //客户名称
ExchangeStatus: "", //领取状态
ExchangeCode: "", //兑换码
},
StatusList: [{
Id: 1,
......@@ -149,24 +154,20 @@
CustomerId: item.CustomerId,
ExchangeCode: item.ExchangeCode
};
saveExchangeKudo(postMsg).then(res => {
if (res.Code == 1) {
this.$q.notify({
icon: "iconfont icon-chenggong",
color: "accent",
timeout: 2000,
message: "兑换成功!",
position: "top",
});
this.getList();
} else {
this.$q.notify({
type: "negative",
message: "兑换失败!",
position: "top",
timeout: 2000,
});
}
var that = this;
this.$confirm('是否要兑换此奖品?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(() => {
saveExchangeKudo(postMsg).then(res => {
if (res.Code == 1) {
that.$message.success("兑换成功!")
that.getList();
} else {
that.$message.error("兑换失败!");
}
})
})
},
goToDetail(item) {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment