应用资源组件
This commit is contained in:
parent
109b82b95d
commit
a33445afe5
|
@ -1,10 +1,7 @@
|
|||
<template>
|
||||
<el-card shadow="never" class="aui-card--fill">
|
||||
<div class="mod-ability__bsabilityai">
|
||||
<el-form
|
||||
:inline="true"
|
||||
:model="dataForm"
|
||||
>
|
||||
<el-form :inline="true" :model="dataForm">
|
||||
<el-form-item>
|
||||
<el-input
|
||||
v-model="dataForm.name"
|
||||
|
@ -13,7 +10,9 @@
|
|||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button @click="getDataList2(dataForm.name)">{{ $t("query") }}</el-button>
|
||||
<el-button @click="getDataList2(dataForm.name)">{{
|
||||
$t("query")
|
||||
}}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="info" @click="exportHandle()">{{
|
||||
|
@ -45,7 +44,7 @@
|
|||
:data="dataList"
|
||||
border
|
||||
@selection-change="dataListSelectionChangeHandle"
|
||||
style="width: 100%;"
|
||||
style="width: 100%"
|
||||
:height="qp ? '810px' : '650px'"
|
||||
>
|
||||
<el-table-column
|
||||
|
@ -70,9 +69,7 @@
|
|||
show-overflow-tooltip="true"
|
||||
>
|
||||
<template slot-scope="scope">
|
||||
{{
|
||||
findValue(scope.row.infoList, item.attrType)
|
||||
}}
|
||||
{{ findValue(scope.row.infoList, item.attrType) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
|
@ -101,7 +98,33 @@
|
|||
<el-button type="text" size="small" @click="showDetail(scope.row)"
|
||||
>展示</el-button
|
||||
>
|
||||
<el-button type="text" size="small" @click="showDocument(scope.row)">开发文档</el-button>
|
||||
<el-button type="text" size="small" @click="showDocument(scope.row)"
|
||||
>开发文档</el-button
|
||||
>
|
||||
<el-button
|
||||
type="text"
|
||||
size="small"
|
||||
@click="applyAndAssembly(scope.row)"
|
||||
>应用与组件</el-button
|
||||
>
|
||||
<el-button
|
||||
type="text"
|
||||
size="small"
|
||||
@click="applyAndDataResource(scope.row)"
|
||||
>应用与数据资源</el-button
|
||||
>
|
||||
<el-button
|
||||
type="text"
|
||||
size="small"
|
||||
@click="applyAndProject(scope.row)"
|
||||
>应用与项目</el-button
|
||||
>
|
||||
<el-button
|
||||
type="text"
|
||||
size="small"
|
||||
@click="applyAndInfrastructure(scope.row)"
|
||||
>应用与基础设施</el-button
|
||||
>
|
||||
</template>
|
||||
</el-table-column>
|
||||
</el-table>
|
||||
|
@ -122,57 +145,70 @@
|
|||
ref="addOrUpdate"
|
||||
@refreshDataList="getDataList"
|
||||
></add-or-update>
|
||||
<relate-application
|
||||
v-if="relateApplicationResourceVisible"
|
||||
ref="relateApplication"
|
||||
:relateInfo="relationData"
|
||||
@isShowRelatePopup="handleIsShowRelatePopupApply"
|
||||
></relate-application>
|
||||
</div>
|
||||
</el-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import mixinViewModule from '@/mixins/view-module'
|
||||
import AddOrUpdate from './bsabilityservice-add-or-update'
|
||||
import dictionaries from '@/utils/dictionaries'
|
||||
import qs from 'qs'
|
||||
import { type } from 'os'
|
||||
import mixinViewModule from "@/mixins/view-module";
|
||||
import AddOrUpdate from "./bsabilityservice-add-or-update";
|
||||
import dictionaries from "@/utils/dictionaries";
|
||||
import RelateApplication from "./bsabilityai-relate-application.vue";
|
||||
import qs from "qs";
|
||||
import { type } from "os";
|
||||
export default {
|
||||
mixins: [mixinViewModule],
|
||||
data() {
|
||||
return {
|
||||
mixinViewModuleOptions: {
|
||||
getDataListURL: '/resource/page',
|
||||
getDataListURL: "/resource/page",
|
||||
getDataListIsPage: true,
|
||||
exportURL: '/ability/bsabilityai/export',
|
||||
deleteURL: '/resource/delete',
|
||||
deleteIsBatch: true
|
||||
exportURL: "/ability/bsabilityai/export",
|
||||
deleteURL: "/resource/delete",
|
||||
deleteIsBatch: true,
|
||||
},
|
||||
disabled: false,
|
||||
sceneArr: dictionaries.sceneArr,
|
||||
fieldArr: dictionaries.fieldArr,
|
||||
shareFormArr: dictionaries.shareFormArr,
|
||||
dataForm: {
|
||||
name: '',
|
||||
creator: '',
|
||||
name: "",
|
||||
creator: "",
|
||||
selectType: 0,
|
||||
delFlag: 0,
|
||||
type: '应用资源'
|
||||
type: "应用资源",
|
||||
},
|
||||
qp: false
|
||||
}
|
||||
qp: false,
|
||||
relateApplicationResourceVisible: false,
|
||||
relationData: {}, //打开穿梭框时传递的参数
|
||||
};
|
||||
},
|
||||
watch: {},
|
||||
components: {
|
||||
AddOrUpdate
|
||||
AddOrUpdate,
|
||||
RelateApplication,
|
||||
},
|
||||
created() {
|
||||
this.dataForm.name = ''
|
||||
this.dataForm.type = '应用资源'
|
||||
this.dataForm.name = "";
|
||||
this.dataForm.type = "应用资源";
|
||||
},
|
||||
mounted() {
|
||||
window.addEventListener('resize', this.a)
|
||||
this.fullScreen()
|
||||
window.addEventListener("resize", this.a);
|
||||
this.fullScreen();
|
||||
},
|
||||
methods: {
|
||||
reset() {
|
||||
this.$http.get(
|
||||
this.mixinViewModuleOptions.getDataListURL + '?' + qs.stringify({
|
||||
this.$http
|
||||
.get(
|
||||
this.mixinViewModuleOptions.getDataListURL +
|
||||
"?" +
|
||||
qs.stringify({
|
||||
// order: this.order,
|
||||
// orderField: this.orderField,
|
||||
// type: '组件服务',
|
||||
|
@ -180,124 +216,227 @@ export default {
|
|||
selectType: 0,
|
||||
limit: 10,
|
||||
delFlag: 0,
|
||||
creator: '',
|
||||
type: '应用资源',
|
||||
name: ''
|
||||
creator: "",
|
||||
type: "应用资源",
|
||||
name: "",
|
||||
})
|
||||
|
||||
).then(({ data: res }) => {
|
||||
this.dataForm.name = ''
|
||||
)
|
||||
.then(({ data: res }) => {
|
||||
this.dataForm.name = "";
|
||||
if (res.code !== 0) {
|
||||
this.dataList = []
|
||||
this.total = 0
|
||||
return this.$message.error(res.msg)
|
||||
this.dataList = [];
|
||||
this.total = 0;
|
||||
return this.$message.error(res.msg);
|
||||
}
|
||||
this.dataList = this.mixinViewModuleOptions.getDataListIsPage ? res.data.list : res.data
|
||||
this.total = this.mixinViewModuleOptions.getDataListIsPage ? res.data.total : 0
|
||||
this.dataList = this.mixinViewModuleOptions.getDataListIsPage
|
||||
? res.data.list
|
||||
: res.data;
|
||||
this.total = this.mixinViewModuleOptions.getDataListIsPage
|
||||
? res.data.total
|
||||
: 0;
|
||||
if (this.mixinViewModuleOptions.requestCallback) {
|
||||
this.mixinViewModuleOptions.requestCallback(res.data)
|
||||
this.mixinViewModuleOptions.requestCallback(res.data);
|
||||
}
|
||||
this.dataListLoading = false
|
||||
}).catch(() => {
|
||||
this.dataListLoading = false
|
||||
this.dataListLoading = false;
|
||||
})
|
||||
.catch(() => {
|
||||
this.dataListLoading = false;
|
||||
});
|
||||
},
|
||||
showDetail(val) {
|
||||
this.addOrUpdateVisible = true
|
||||
this.disabled = false
|
||||
this.addOrUpdateVisible = true;
|
||||
this.disabled = false;
|
||||
this.$nextTick(() => {
|
||||
this.$refs.addOrUpdate.UpdateState = false
|
||||
this.$refs.addOrUpdate.dataFormShowDetails = val
|
||||
this.$refs.addOrUpdate.init()
|
||||
})
|
||||
this.disabled = true
|
||||
this.$refs.addOrUpdate.UpdateState = false;
|
||||
this.$refs.addOrUpdate.dataFormShowDetails = val;
|
||||
this.$refs.addOrUpdate.init();
|
||||
});
|
||||
this.disabled = true;
|
||||
},
|
||||
showDocument(val) {
|
||||
console.log(val)
|
||||
window.open(window.SITE_CONFIG.frontUrl + '?id=' + val.id + '&&type=' + val.type, '_blank')
|
||||
console.log(val);
|
||||
window.open(
|
||||
window.SITE_CONFIG.frontUrl + "?id=" + val.id + "&&type=" + val.type,
|
||||
"_blank"
|
||||
);
|
||||
},
|
||||
findValue(list, type) {
|
||||
const found = list.find(item => item.attrType === type)
|
||||
const found = list.find((item) => item.attrType === type);
|
||||
if (found) {
|
||||
return found.attrValue
|
||||
return found.attrValue;
|
||||
} else {
|
||||
return '暂无数据'
|
||||
return "暂无数据";
|
||||
}
|
||||
},
|
||||
getDataList2(names) {
|
||||
if (names != null) {
|
||||
this.$http.get(
|
||||
this.mixinViewModuleOptions.getDataListURL + '?' + qs.stringify({
|
||||
this.$http
|
||||
.get(
|
||||
this.mixinViewModuleOptions.getDataListURL +
|
||||
"?" +
|
||||
qs.stringify({
|
||||
// order: this.order,
|
||||
// orderField: this.orderField,
|
||||
// type: '组件服务',
|
||||
pageNum: 1,
|
||||
pageSize: this.limit,
|
||||
type: '应用资源',
|
||||
creator: '',
|
||||
type: "应用资源",
|
||||
creator: "",
|
||||
selectType: 0,
|
||||
delFlag: 0,
|
||||
name: names
|
||||
name: names,
|
||||
})
|
||||
)
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
this.dataList = []
|
||||
this.total = 0
|
||||
return this.$message.error(res.msg)
|
||||
this.dataList = [];
|
||||
this.total = 0;
|
||||
return this.$message.error(res.msg);
|
||||
}
|
||||
if (res.data.list.length !== 0) {
|
||||
this.dataList = res.data.list
|
||||
this.total = this.mixinViewModuleOptions.getDataListIsPage ? res.data.total : 0
|
||||
this.dataList = res.data.list;
|
||||
this.total = this.mixinViewModuleOptions.getDataListIsPage
|
||||
? res.data.total
|
||||
: 0;
|
||||
if (this.mixinViewModuleOptions.requestCallback) {
|
||||
this.mixinViewModuleOptions.requestCallback(res.data)
|
||||
this.mixinViewModuleOptions.requestCallback(res.data);
|
||||
}
|
||||
this.dataListLoading = false
|
||||
this.dataListLoading = false;
|
||||
} else {
|
||||
this.$message.error('未查询到相关信息')
|
||||
this.reset()
|
||||
this.$message.error("未查询到相关信息");
|
||||
this.reset();
|
||||
}
|
||||
}).catch(() => {
|
||||
this.dataListLoading = false
|
||||
})
|
||||
.catch(() => {
|
||||
this.dataListLoading = false;
|
||||
});
|
||||
} else {
|
||||
this.$message.error('查询不能输入为空')
|
||||
this.$message.error("查询不能输入为空");
|
||||
}
|
||||
},
|
||||
fullScreen() {
|
||||
if (window.outerHeight === screen.availHeight) {
|
||||
if (window.outerWidth === screen.availWidth) {
|
||||
console.log(
|
||||
'全屏1',
|
||||
"全屏1",
|
||||
window.outerHeight,
|
||||
screen.availHeight,
|
||||
window.outerWidth,
|
||||
screen.availWidth
|
||||
)
|
||||
this.qp = false
|
||||
);
|
||||
this.qp = false;
|
||||
} else {
|
||||
console.log(
|
||||
'不是全屏2',
|
||||
"不是全屏2",
|
||||
window.outerHeight,
|
||||
screen.availHeight,
|
||||
window.outerWidth,
|
||||
screen.availWidth
|
||||
)
|
||||
this.qp = true
|
||||
);
|
||||
this.qp = true;
|
||||
}
|
||||
} else {
|
||||
console.log(
|
||||
'不是全屏3',
|
||||
"不是全屏3",
|
||||
window.outerHeight,
|
||||
screen.availHeight,
|
||||
window.outerWidth,
|
||||
screen.availWidth
|
||||
)
|
||||
this.qp = true
|
||||
);
|
||||
this.qp = true;
|
||||
}
|
||||
},
|
||||
//应用与组件
|
||||
applyAndAssembly(val) {
|
||||
console.log("vvvv", val);
|
||||
//根据id和类型查询已关联的组件,将id,type和查出来的数据传递给组件
|
||||
let type = "组件服务";
|
||||
let id = val.id;
|
||||
this.$http
|
||||
.get(`/dataResourceRel/queryResourceRelByKeyId`, {
|
||||
params: {
|
||||
keyId: id,
|
||||
type: type,
|
||||
referenceName: "",
|
||||
},
|
||||
})
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
return this.$message.error(res.msg);
|
||||
}
|
||||
console.log("rrrrressssz", res.data);
|
||||
this.relateApplicationResourceVisible = true;
|
||||
this.relationData = {
|
||||
id: id,
|
||||
linkType: "1",
|
||||
responseData: res.data,
|
||||
};
|
||||
console.log(" this.relationData", this.relationData);
|
||||
//将数据传递给引入的组件
|
||||
});
|
||||
},
|
||||
//应用与数据资源
|
||||
applyAndDataResource(val) {
|
||||
console.log("数据资源");
|
||||
},
|
||||
//应用与项目
|
||||
applyAndProject(val) {
|
||||
let type = "项目";
|
||||
let id = val.id;
|
||||
this.$http
|
||||
.get(`/dataResourceRel/queryResourceRelByKeyId`, {
|
||||
params: {
|
||||
keyId: id,
|
||||
type: type,
|
||||
referenceName: "",
|
||||
},
|
||||
})
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
return this.$message.error(res.msg);
|
||||
}
|
||||
console.log("rrrrressssx", res.data);
|
||||
this.relateApplicationResourceVisible = true;
|
||||
this.relationData = {
|
||||
id: id,
|
||||
linkType: "1",
|
||||
responseData: res.data,
|
||||
};
|
||||
//将数据传递给引入的组件
|
||||
});
|
||||
},
|
||||
//应用与基础设施
|
||||
applyAndInfrastructure(val) {
|
||||
let type = "基础设施";
|
||||
let id = val.id;
|
||||
this.$http
|
||||
.get(`/dataResourceRel/queryResourceRelByKeyId`, {
|
||||
params: {
|
||||
keyId: id,
|
||||
type: type,
|
||||
referenceName: "",
|
||||
},
|
||||
})
|
||||
.then(({ data: res }) => {
|
||||
if (res.code !== 0) {
|
||||
return this.$message.error(res.msg);
|
||||
}
|
||||
console.log("rrrrressssj", res.data);
|
||||
this.relateApplicationResourceVisible = true;
|
||||
this.relationData = {
|
||||
id: id,
|
||||
linkType: "1",
|
||||
responseData: res.data,
|
||||
};
|
||||
//将数据传递给引入的组件
|
||||
});
|
||||
},
|
||||
// 是否展示关联应用弹窗
|
||||
handleIsShowRelatePopupApply(type) {
|
||||
this.relateApplicationResourceVisible = type;
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.el-tooltip__popper {
|
||||
|
|
|
@ -11,9 +11,7 @@
|
|||
<el-button type="primary" class="button-new" @click="flashTableData"
|
||||
>查询</el-button
|
||||
>
|
||||
<el-button type="primary" class="button-new" @click="restTableData"
|
||||
>重置</el-button
|
||||
>
|
||||
<el-button @click="restTableData">重置</el-button>
|
||||
<div style="float: right">
|
||||
<el-button
|
||||
size="mini"
|
||||
|
|
|
@ -1,85 +1,168 @@
|
|||
<template>
|
||||
<el-card shadow="never" class="aui-card--fill">
|
||||
<div class="mod-pay__order">
|
||||
<el-form :inline="true" :model="dataForm" @keyup.enter.native="getDataList()">
|
||||
<el-form-item>
|
||||
<el-input v-model="dataForm.orderId" :placeholder="$t('order.orderId')" clearable></el-input>
|
||||
<div class="mod-bscatalogue__bscatalogue">
|
||||
<el-form :inline="true">
|
||||
<el-form-item label="项目名称:">
|
||||
<el-input
|
||||
v-model="queryData.projectName"
|
||||
placeholder="请输入项目名称"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item label="应用名称:">
|
||||
<el-input
|
||||
v-model="queryData.applyName"
|
||||
placeholder="请输入应用名称"
|
||||
clearable
|
||||
></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-input v-model="dataForm.userId" :placeholder="$t('order.userId')" clearable></el-input>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<ren-select v-model="dataForm.status" dict-type="order_status" :placeholder="$t('order.status')"></ren-select>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button @click="getDataList()">{{ $t('query') }}</el-button>
|
||||
</el-form-item>
|
||||
<el-form-item>
|
||||
<el-button type="primary" @click="addOrUpdateHandle()">{{ $t('add') }}</el-button>
|
||||
<el-button type="primary" @click="searchTableData">查询</el-button>
|
||||
<el-button @click="resetTableData">重置</el-button>
|
||||
</el-form-item>
|
||||
</el-form>
|
||||
<el-table v-loading="dataListLoading" :data="dataList" border @selection-change="dataListSelectionChangeHandle" style="width: 100%;">
|
||||
<el-table-column type="selection" header-align="center" align="center" width="50"></el-table-column>
|
||||
<el-table-column prop="orderId" :label="$t('order.orderId')" header-align="center" align="center"></el-table-column>
|
||||
<el-table-column prop="productName" :label="$t('order.productName')" header-align="center" align="center"></el-table-column>
|
||||
<el-table-column prop="payAmount" :label="$t('order.payAmount')" header-align="center" align="center"></el-table-column>
|
||||
<el-table-column prop="status" :label="$t('order.status')" header-align="center" align="center">
|
||||
<template slot-scope="scope">
|
||||
{{ $getDictLabel("order_status", scope.row.status) }}
|
||||
</template>
|
||||
</el-table-column>
|
||||
<el-table-column prop="payAt" :label="$t('order.payAt')" header-align="center" align="center"></el-table-column>
|
||||
<el-table-column prop="createDate" :label="$t('order.createDate')" header-align="center" align="center"></el-table-column>
|
||||
<el-table-column :label="$t('handle')" fixed="right" header-align="center" align="center" width="150">
|
||||
<template slot-scope="scope">
|
||||
<el-button v-if="scope.row.status === 0" type="text" size="small" @click="payHandle(scope.row.orderId)">{{ $t('order.pay') }}</el-button>
|
||||
<el-button v-if="scope.row.status === 0" type="text" size="small" @click="deleteHandle(scope.row.id)">{{ $t('delete') }}</el-button>
|
||||
</template>
|
||||
<el-table row-key="id" :data="dataList" border style="width: 100%">
|
||||
<el-table-column
|
||||
prop="projectName"
|
||||
label="项目名称"
|
||||
header-align="center"
|
||||
align="center"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
prop="applyName"
|
||||
label="应用名称"
|
||||
header-align="center"
|
||||
align="center"
|
||||
>
|
||||
</el-table-column>
|
||||
<el-table-column
|
||||
prop="useAbilityName"
|
||||
label="使用能力名称"
|
||||
header-align="center"
|
||||
align="center"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
prop="capabilityType"
|
||||
label="能力类型"
|
||||
header-align="center"
|
||||
align="center"
|
||||
></el-table-column>
|
||||
<el-table-column
|
||||
prop="viewsNumber"
|
||||
label="浏览次数"
|
||||
header-align="center"
|
||||
align="center"
|
||||
></el-table-column>
|
||||
<!-- <el-table-column label="操作" header-align="center" align="center">
|
||||
</el-table-column> -->
|
||||
</el-table>
|
||||
<!-- 分页组件 -->
|
||||
<el-pagination
|
||||
:current-page="page"
|
||||
style="margin-top: 20px; text-align: right"
|
||||
@size-change="handleSizeChange"
|
||||
@current-change="handleCurrentChange"
|
||||
:current-page="queryData.pageIndex"
|
||||
:page-sizes="[10, 20, 50, 100]"
|
||||
:page-size="limit"
|
||||
:total="total"
|
||||
:page-size="queryData.pageSize"
|
||||
layout="total, sizes, prev, pager, next, jumper"
|
||||
@size-change="pageSizeChangeHandle"
|
||||
@current-change="pageCurrentChangeHandle">
|
||||
:total="queryData.total"
|
||||
>
|
||||
</el-pagination>
|
||||
<!-- 弹窗, 新增 / 修改 -->
|
||||
<!-- <add-or-update v-if="addOrUpdateVisible" ref="addOrUpdate" @refreshDataList="getDataList"></add-or-update> -->
|
||||
</div>
|
||||
</el-card>
|
||||
</template>
|
||||
|
||||
<script>
|
||||
import mixinViewModule from '@/mixins/view-module'
|
||||
import mixinViewModule from "@/mixins/view-module";
|
||||
// import AddOrUpdate from './order-add-or-update'
|
||||
import { addDynamicRoute } from "@/router";
|
||||
export default {
|
||||
mixins: [mixinViewModule],
|
||||
// mixins: [mixinViewModule],
|
||||
data() {
|
||||
return {
|
||||
mixinViewModuleOptions: {
|
||||
getDataListURL: '/pay/order/page',
|
||||
getDataListIsPage: true,
|
||||
deleteURL: '/pay/order',
|
||||
deleteIsBatch: true
|
||||
queryData: {
|
||||
projectName: "",
|
||||
applyName: "",
|
||||
pageIndex: 1,
|
||||
pageSize: 10,
|
||||
total: 0,
|
||||
},
|
||||
dataForm: {
|
||||
orderId: '',
|
||||
status: '',
|
||||
userId: ''
|
||||
}
|
||||
}
|
||||
dataList: [
|
||||
{
|
||||
projectName: "人员聚集算法任务",
|
||||
applyName: "已创建",
|
||||
useAbilityName: "人员聚集",
|
||||
capabilityType: "视频类",
|
||||
viewsNumber: "100",
|
||||
},
|
||||
],
|
||||
};
|
||||
},
|
||||
components: {
|
||||
// AddOrUpdate
|
||||
},
|
||||
mounted() {
|
||||
//this.getTableData();
|
||||
},
|
||||
methods: {
|
||||
payHandle (orderId) {
|
||||
window.open(`${window.SITE_CONFIG['apiURL']}/pay/alipay/webPay?orderId=` + orderId);
|
||||
}
|
||||
getTableData() {
|
||||
//修改查询接口
|
||||
this.$http
|
||||
.get("/taskList/tasklistcontroller/selectTaskList", {
|
||||
params: {
|
||||
page: this.queryData.pageIndex,
|
||||
pageSize: this.queryData.pageSize,
|
||||
projectName: this.queryData.projectName,
|
||||
applyName: this.queryData.applyName,
|
||||
},
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(res);
|
||||
if (res.status === 200) {
|
||||
this.dataList = res.data.taskEntityList;
|
||||
this.queryData.total = parseInt(res.data.num);
|
||||
}
|
||||
})
|
||||
.catch(() => {});
|
||||
},
|
||||
getStatusCnName(val) {
|
||||
const arr = this.statusOptions.filter((i) => {
|
||||
return i.value === val;
|
||||
});
|
||||
|
||||
if (arr.length >= 0) {
|
||||
return arr[0].label;
|
||||
}
|
||||
|
||||
return "未知状态";
|
||||
},
|
||||
|
||||
// 重置
|
||||
resetTableData() {
|
||||
this.queryData.projectName = "";
|
||||
this.queryData.applyName = "";
|
||||
this.getTableData();
|
||||
},
|
||||
|
||||
searchTableData() {
|
||||
this.queryData.pageIndex = 1;
|
||||
this.getTableData();
|
||||
},
|
||||
// 分页大小更改
|
||||
handleSizeChange(value) {
|
||||
this.queryData.pageSize = value;
|
||||
this.getTableData();
|
||||
},
|
||||
// 当前索引更改
|
||||
handleCurrentChange(val) {
|
||||
this.queryData.pageIndex = val;
|
||||
this.getTableData();
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
<style lang="scss" scoped>
|
||||
.monitoring-top {
|
||||
margin: 10px 0;
|
||||
}
|
||||
</style>
|
Loading…
Reference in New Issue