Commit 0a5eb252 authored by 张俊's avatar 张俊

Merge branch 'dev' of https://cloud.wodcloud.com/git/apaas/apaas-v3-ui into dev

parents 7693c0bd a960519e
<template> <template>
<div class="apass_table"> <div class="apass_table">
<el-table :data="data" @sort-change="sortChange"> <el-table :data="data" @sort-change="sortChange">
<el-table-column v-if="paddingLeft > 10" :width="paddingLeft - 10">{{ <el-table-column v-if="paddingLeft > 10" :width="paddingLeft - 10"></el-table-column>
paddingLeft
}}</el-table-column>
<el-table-column <el-table-column
v-for="(item, index) in header" v-for="(item, index) in header"
:label="item.label" :label="item.label"
......
...@@ -579,7 +579,9 @@ export default { ...@@ -579,7 +579,9 @@ export default {
.then(response => { .then(response => {
if (response.data.success == 1) { if (response.data.success == 1) {
this.toplistData = response.data.data; this.toplistData = response.data.data;
this.toplistTargetValue = this.toplistData[0].request_count; if (this.toplistData && this.toplistData.length != 0) {
this.toplistTargetValue = this.toplistData[0].request_count;
}
} }
}); });
}, },
...@@ -601,7 +603,9 @@ export default { ...@@ -601,7 +603,9 @@ export default {
}) })
.then(response => { .then(response => {
if (response.data.success == 1) { if (response.data.success == 1) {
this.commentlistData = response.data.data; this.commentlistData = response.data.data.concat(
this.commentlistData
);
this.last_id = this.commentlistData[0].last_id; this.last_id = this.commentlistData[0].last_id;
} }
}); });
......
...@@ -39,7 +39,7 @@ ...@@ -39,7 +39,7 @@
<div class="filter_item"> <div class="filter_item">
<span class="filter_title">推送时间:</span> <span class="filter_title">推送时间:</span>
<el-date-picker <el-date-picker
v-model="topFilter.time" v-model="topFilter.push_time"
type="daterange" type="daterange"
range-separator="至" range-separator="至"
start-placeholder="开始日期" start-placeholder="开始日期"
...@@ -102,7 +102,7 @@ export default { ...@@ -102,7 +102,7 @@ export default {
topFilter: { topFilter: {
name: "", name: "",
state: "", state: "",
time: "", push_time: "",
}, },
tempFilter: null, tempFilter: null,
}), }),
...@@ -113,7 +113,7 @@ export default { ...@@ -113,7 +113,7 @@ export default {
...this.topFilter, ...this.topFilter,
}; };
this.tempFilter = fullFilter; // filter存档,用于页面刷新 this.tempFilter = filter; // filter存档,用于页面刷新
console.log(fullFilter); console.log(fullFilter);
...@@ -242,7 +242,7 @@ export default { ...@@ -242,7 +242,7 @@ export default {
this.topFilter = { this.topFilter = {
name: "", name: "",
state: "", state: "",
time: "", push_time: "",
}; };
this.initList(this.tempFilter); this.initList(this.tempFilter);
......
<template> <template>
<div> <div class="list_container">
<el-breadcrumb separator="/" class="bread_crumb1 bread_left"> <apass-list
<el-breadcrumb-item :to="{ path: '/message' }">{{ $t("lang.message") }}</el-breadcrumb-item> ref="list"
<el-breadcrumb-item>{{ $t("lang.recommended") }}</el-breadcrumb-item> :list-header="listHeader"
</el-breadcrumb> :list-data="listData"
:list-total="listTotal"
:hide-header="true"
:list-padding-left="0"
@list-action="initList"
>
<el-breadcrumb separator="/" slot="breadcrumb">
<el-breadcrumb-item :to="{ path: '/message' }">
{{ $t("lang.message") }}
</el-breadcrumb-item>
<el-breadcrumb-item>
{{ $t("lang.recommended") }}
</el-breadcrumb-item>
</el-breadcrumb>
<template slot="top">
<div class="top_fliter">
<div class="filter_list">
<div class="filter_item">
<span class="filter_title">推荐位名称:</span>
<el-input
v-model="topFilter.name"
placeholder="请输入推荐位名称"
></el-input>
</div>
<div class="filter_item">
<span class="filter_title">状态:</span>
<el-select v-model="topFilter.state" placeholder="请选择">
<el-option label="全部" value=""> </el-option>
<el-option label="推送成功" value="1"> </el-option>
<el-option label="推送失败" value="0"> </el-option>
</el-select>
</div>
<div class="filter_item">
<span class="filter_title">最后更新时间:</span>
<el-date-picker
v-model="topFilter.time"
type="daterange"
range-separator="至"
start-placeholder="开始日期"
end-placeholder="结束日期"
value-format="yyyy-MM-dd"
>
</el-date-picker>
</div>
</div>
<div class="filter_action apass_button">
<el-button type="primary" @click="topFilterAction">
查询
</el-button>
<el-button type="defalut" @click="topFilterClear">
重置
</el-button>
</div>
</div>
</template>
</apass-list>
</div> </div>
</template> </template>
<script> <script>
import helper from "@/services/helper.js";
import apassList from "@/components/apass-list";
export default { export default {
components: {}, components: {
data: () => ({}), apassList,
mounted() {}, },
methods: {} data: () => ({
listHeader: [],
listData: [],
listTotal: 0,
topFilter: {
name: "",
state: "",
time: "",
},
tempFilter: null,
}),
methods: {
initList(filter) {
let fullFilter = {
...filter,
...this.topFilter,
};
this.tempFilter = filter; // filter存档,用于页面刷新
console.log(fullFilter);
this.listTotal = 5;
this.listData = [
{
state: 1,
name: "热门数据",
service_count: 5,
detail:
"水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况",
person: "罗治翔",
updata_time: "2020-07-18T14:25:09+08:00",
},
{
state: 1,
name: "热门数据",
service_count: 5,
detail:
"水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况",
person: "罗治翔",
updata_time: "2020-07-18T14:25:09+08:00",
},
{
state: 0,
name: "热门数据",
service_count: 5,
detail:
"水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况",
person: "罗治翔",
updata_time: "2020-07-18T14:25:09+08:00",
},
{
state: 0,
name: "热门数据",
service_count: 5,
detail:
"水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况",
person: "罗治翔",
updata_time: "2020-07-18T14:25:09+08:00",
},
{
state: 0,
name: "热门数据",
service_count: 5,
detail:
"水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况,水路货物周转量情况",
person: "罗治翔",
updata_time: "2020-07-18T14:25:09+08:00",
},
];
/* this.$http
.get("/apaas/service/v3/resource/apply/approveList", {
params: {
search: filter.keyword,
page: filter.page,
limit: filter.size,
state: filter.state,
},
})
.then(({ data }) => {
if (data.success == 1) {
this.listTotal = data.total;
this.listData = data.data;
} else {
this.$message({
message: data.errMsg || "获取列表失败",
type: "warning",
});
}
})
.catch((error) => {
console.log(error);
}); */
},
topFilterAction() {
this.initList(this.tempFilter);
},
topFilterClear() {
this.topFilter = {
name: "",
state: "",
time: "",
};
this.initList(this.tempFilter);
},
detailAction(item) {
console.log(`查看${item.name}`);
},
editAction(item) {
console.log(`编辑${item.name}`);
},
},
created() {
this.listHeader = [
{
label: "",
prop: "state",
type: "image-tooltip",
getImage(item) {
return item.state == 1
? require("@/assets/imgs/ic_true.png")
: require("@/assets/imgs/ic_failed.png");
},
getTooltip(item) {
return item.state == 1 ? "推送成功" : "推送失败";
},
align: "center",
width: 60,
},
{
label: "推荐位名称",
prop: "name",
type: "button",
callback: this.detailAction,
align: "center",
width: 100,
},
{
label: "服务个数",
prop: "service_count",
align: "center",
width: 160,
},
{
label: "服务详情",
prop: "detail",
},
{
label: "操作人",
prop: "person",
align: "center",
width: 120,
},
{
label: "最后更新 时间",
prop: "updata_time",
getText(item) {
let date = item.updata_time || "";
return helper.dateStringTransform(date);
},
align: "center",
width: 240,
},
{
label: "操作",
type: "buttons",
align: "center",
width: 160,
actionList: [
{
label: "编辑",
callback: this.editAction,
},
],
},
];
},
}; };
</script> </script>
<style scoped> <style scoped>
</style> .list_container {
\ No newline at end of file height: 100%;
}
</style>
...@@ -32,11 +32,11 @@ ...@@ -32,11 +32,11 @@
<span class="head_right_msg_item">{{ cloudData.phone }}</span> <span class="head_right_msg_item">{{ cloudData.phone }}</span>
资源申请状态: 资源申请状态:
<span <span
v-if="apply_type == 0" v-if="apploy_msg.first_level == 0"
class="head_right_msg_item apply_wait" class="head_right_msg_item apply_wait"
>待审批</span> >待审批</span>
<span v-if="apply_type == 1" class="head_right_msg_item apply_success">审批通过</span> <span v-if="apploy_msg.first_level == 1 && apploy_msg.second_level == 1" class="head_right_msg_item apply_success">审批通过</span>
<span v-if="apply_type == -1" class="head_right_msg_item apply_refuse">审批未通过</span> <span v-if="apploy_msg.first_level == -1 || (apploy_msg.first_level == 1 && apploy_msg.second_level == -1)" class="head_right_msg_item apply_refuse">审批未通过</span>
</p> </p>
<p class="head_right_msg_p"> <p class="head_right_msg_p">
业务系统名: 业务系统名:
......
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