Commit 59632fb6 authored by 黄奎's avatar 黄奎

页面修改

parent e772175f
......@@ -16,12 +16,7 @@
</span>
</li>
<li>
<input
type="button"
class="hollowFixedBtn"
:value="$t('pub.searchBtn')"
@click="resetPageIndex(),getList()"
>
<input type="button" class="hollowFixedBtn" :value="$t('pub.searchBtn')" @click="resetPageIndex(),getList()">
</li>
</ul>
</div>
......@@ -36,116 +31,97 @@
<th>{{$t('system.query_type')}}</th>
<th>{{$t('active.cl_user')}}</th>
<th>{{$t('active.cl_hdriqi')}}</th>
<!-- <th>操作</th> -->
</tr>
<tr v-for="(item,index) in DataList" v-loading="loading">
<td>
<span v-if="item.accessType == 1">{{$t('active.cl_choujiang')}}</span>
</td>
<td>{{item.acessName}}</td>
<td>
<span v-if="item.useState == 1" style="color: green">{{$t('active.cl_wsyong')}}</span>
<span v-if="item.useState == 2" style="color: gary">{{$t('active.cl_ysyong')}}</span>
<span v-if="item.useState == 3" style="color: red">{{$t('active.cl_yzfei')}}</span>
</td>
<td>
<span v-if="item.orderId === 0">{{$t('active.cl_zanwu')}}</span>
<span v-else>{{item.orderId}}</span>
</td>
<td>
<span v-if="item.orderType === 0">{{$t('active.cl_zanwu')}}</span>
<span v-else>
<span v-if="item.orderType == 1">{{$t('active.cl_team')}}</span>
<span v-if="item.orderType == 2">{{$t('active.cl_qianzheng')}}</span>
<span v-if="item.orderType == 3">{{$t('active.cl_jipiao')}}</span>
</span>
</td>
<td>{{item.useDate ? item.useDate : $t('active.cl_wsyong')}}</td>
<td>{{item.couponsType ===1 ? $t('active.cl_dyquan') : $t('active.cl_zkquan')}}</td>
<td>{{item.userPlatform === 1 ? "B2B" : $t('active.cl_qita')}}{{item.userName}}</td>
<td>{{item.acessDate}}</td>
<!-- <td>
<el-tooltip class="item" effect="dark" content="修改用户信息" placement="top">
<el-button
type="primary"
icon="el-icon-edit"
circle
@click="outerVisible=true,dialogTitle='修改用户信息',updateData(item),getCompany()"
></el-button>
</el-tooltip>
<el-tooltip class="item" effect="dark" content="删除优惠券" placement="top">
<el-button
v-if="item.couponStatus !== 3"
type="danger"
icon="iconfont icon-img_delete_small"
circle
@click="deleteItem(item)"
></el-button>
</el-tooltip>
</td> -->
</tr>
<tbody v-loading="loading">
<tr v-for="(item,index) in DataList" :key="index">
<td>
<span v-if="item.accessType == 1">{{$t('active.cl_choujiang')}}</span>
</td>
<td>{{item.acessName}}</td>
<td>
<span v-if="item.useState == 1" style="color: green">{{$t('active.cl_wsyong')}}</span>
<span v-if="item.useState == 2" style="color: gary">{{$t('active.cl_ysyong')}}</span>
<span v-if="item.useState == 3" style="color: red">{{$t('active.cl_yzfei')}}</span>
</td>
<td>
<span v-if="item.orderId === 0">{{$t('active.cl_zanwu')}}</span>
<span v-else>{{item.orderId}}</span>
</td>
<td>
<span v-if="item.orderType === 0">{{$t('active.cl_zanwu')}}</span>
<span v-else>
<span v-if="item.orderType == 1">{{$t('active.cl_team')}}</span>
<span v-if="item.orderType == 2">{{$t('active.cl_qianzheng')}}</span>
<span v-if="item.orderType == 3">{{$t('active.cl_jipiao')}}</span>
</span>
</td>
<td>{{item.useDate ? item.useDate : $t('active.cl_wsyong')}}</td>
<td>{{item.couponsType ===1 ? $t('active.cl_dyquan') : $t('active.cl_zkquan')}}</td>
<td>{{item.userPlatform === 1 ? "B2B" : $t('active.cl_qita')}}{{item.userName}}</td>
<td>{{item.acessDate}}</td>
</tr>
</tbody>
</table>
<div class="noDataNotice" v-if="DataList.length<1">
<i class="iconfont icon-kong"></i>
<p>{{$t('active.ld_noData')}}</p>
</div>
<el-pagination
background
@current-change="handleCurrentChange"
v-if="DataList.length>0"
:current-page.sync="currentPage"
layout="total,prev, pager, next, jumper"
:page-size="msg.pageSize"
:total="total"
></el-pagination>
<el-pagination background @current-change="handleCurrentChange" v-if="DataList.length>0"
:current-page.sync="currentPage" layout="total,prev, pager, next, jumper" :page-size="msg.pageSize"
:total="total"></el-pagination>
</div>
</template>
<script>
export default {
data() {
return {
loading: false,
DataList: [],
msg: {
pageIndex: 1,
pageSize: 15,
couponId: '',
useState: '',
},
currentPage: 1,
total: 0,
};
},
created(){
this.msg.couponId = this.$route.query.couponId
this.msg.useState = this.$route.query.useState
},
mounted() {
let userInfo = this.getLocalStorage();
this.getList();
},
methods: {
getList() {
//获取数据
this.loading = true
this.apiJavaPost("/api/sell/coupon/getCouponAllotList", this.msg, res => {
if (res.data.resultCode === 1) {
this.total = res.data.data.count
this.DataList = res.data.data.pageData
} else {
this.$message.error(res.data.message)
}
this.loading = false
}, null);
export default {
data() {
return {
loading: false,
DataList: [],
msg: {
pageIndex: 1,
pageSize: 15,
couponId: '',
useState: '',
},
currentPage: 1,
total: 0,
};
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
created() {
this.msg.couponId = this.$route.query.couponId
this.msg.useState = this.$route.query.useState
},
resetPageIndex() {
this.msg.pageIndex = 1;
this.currentPage = 1;
mounted() {
this.getList();
},
}
};
</script>
\ No newline at end of file
methods: {
getList() {
//获取数据
this.loading = true;
this.apipost(
"coupon_post_GetCouponAllotPage",
this.msg,
res => {
this.loading = false;
console.log("coupon_post_GetCouponAllotPage", res.data);
if (res.data.resultCode === 1) {
this.total = res.data.data.count;
this.DataList = res.data.data.pageData;
} else {
this.$message.error(res.data.message)
}
}
);
},
handleCurrentChange(val) {
this.msg.pageIndex = val;
this.getList();
},
resetPageIndex() {
this.msg.pageIndex = 1;
this.currentPage = 1;
},
}
};
</script>
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