Commit f6cb85a8 authored by 姬鋆屾's avatar 姬鋆屾

parent b6c8c210
......@@ -82,6 +82,7 @@
@onClose="onClose"
@showDrawer="showDrawer"
:visible="visible"
:title="'12345写信记录'"
/>
</div>
</template>
......
......@@ -93,6 +93,7 @@
ref="FormDetails"
@onClose="onClose"
@showDrawer="showDrawer"
:title="'网络理政'"
:visible="visible"
/>
</div>
......@@ -176,14 +177,12 @@ export default {
align: "center",
dataIndex: "upname",
customRender: (text, record, index) => `${record.upname || "--"}`,
},
{
title: "联系电话",
align: "center",
dataIndex: "upphone",
customRender: (text, record, index) => `${record.upphone || "--"}`,
},
{
title: "是否公开",
......@@ -205,8 +204,8 @@ export default {
title: "提交日期",
align: "center",
dataIndex: "create_time",
customRender: (text, record, index) => `${record.create_time || "--"}`,
customRender: (text, record, index) =>
`${record.create_time || "--"}`,
},
{
title: "是否回复",
......@@ -221,21 +220,19 @@ export default {
align: "center",
dataIndex: "reply_name",
customRender: (text, record, index) => `${record.reply_name || "--"}`,
},
{
title: "回复时间",
align: "center",
dataIndex: "update_time",
customRender: (text, record, index) => `${record.update_time || "--"}`,
customRender: (text, record, index) =>
`${record.update_time || "--"}`,
},
{
title: "所属部门",
align: "center",
dataIndex: "deptName",
customRender: (text, record, index) => `${record.deptName || "--"}`,
},
{
title: "操作",
......
......@@ -4,7 +4,12 @@
<div class="search">
<h1>应用服务</h1>
<div class="search-box">
<a-input placeholder="请输入API名称搜索" v-model="searchVal" @pressEnter="handleSearch" />
<a-input
placeholder="请输入应用名称搜索"
v-model="searchVal"
@pressEnter="handleSearch"
allow-clear
/>
<button class="search_btn btn" @click="handleSearch">
<span>{{ isSearch ? "重置" : "搜索" }}</span>
</button>
......@@ -15,38 +20,75 @@
<div class="stepbox" :style="{ height: contentHigh + 'px' }">
<div class="_left">
<a-steps progress-dot direction="vertical">
<a-step v-for="(item, index) in listArr" :status="active === index ? 'process' : 'wait'" :key="index">
<span slot="title" @click="handleChange(item, index)">{{ item.productName }}</span>
<a-step
v-for="(item, index) in listArr"
:status="active === index ? 'process' : 'wait'"
:key="index"
>
<span slot="title" @click="handleChange(item, index)">{{
item.productName
}}</span>
</a-step>
</a-steps>
</div>
<div class="_right">
<div class="list_box step_sign">
<div class="title-box">
<span class="list_title">{{ listArr[active] ? listArr[active].productName : '--' }}</span>
<span class="count primary">{{ listArr[active].curInfo.length }}</span>
<span class="list_title">{{
listArr[active] ? listArr[active].productName : "--"
}}</span>
<span class="count primary">{{
listArr[active].curInfo.length
}}</span>
</div>
<div v-if="listArr[active].curInfo.length > 0">
<div class="list flex aic jcb " v-for="(i, j) in listArr[active].curInfo">
<div
class="list flex aic jcb"
v-for="(i, j) in listArr[active].curInfo"
>
<div class="app-name">{{ i.appName }}</div>
<img v-if="i.deveLanguage == 1" src="@/assets/images/JAVA.png" alt />
<img v-if="i.deveLanguage == 2" src="@/assets/images/php.png" alt />
<img v-if="i.deveLanguage == 3" src="@/assets/images/Android.png" alt />
<img v-if="i.deveLanguage == 4" src="@/assets/images/Cshape.png" alt />
<img v-if="i.deveLanguage == 5" src="@/assets/images/Cjj.jpg" alt />
<img
v-if="i.deveLanguage == 1"
src="@/assets/images/JAVA.png"
alt
/>
<img
v-if="i.deveLanguage == 2"
src="@/assets/images/php.png"
alt
/>
<img
v-if="i.deveLanguage == 3"
src="@/assets/images/Android.png"
alt
/>
<img
v-if="i.deveLanguage == 4"
src="@/assets/images/Cshape.png"
alt
/>
<img
v-if="i.deveLanguage == 5"
src="@/assets/images/Cjj.jpg"
alt
/>
<div>V{{ i.versionNumber }}</div>
<div>{{ i.versionInfo }}</div>
<div v-if="i.createTime">
{{ $moment(i.createTime).format("YYYY-MM-DD") }}
</div>
<a-button type="primary" class="addclass" @click="handleDowload(api + i.appFileUrl, i.appName)">
<a-button
type="primary"
class="addclass"
@click="handleDowload(api + i.appFileUrl, i.appName)"
>
<a-icon type="download" />下载
</a-button>
</div>
</div>
<div v-else>
<div class="list flex aic jcb ">
<div class="app-name"> 暂无数据</div>
<div class="list flex aic jcb">
<div class="app-name">暂无数据</div>
</div>
</div>
</div>
......@@ -56,8 +98,8 @@
</template>
<script>
import { serviceList, } from "@/api/applService.js";
import { getProduct, } from "@/api/thePlatformIsSet.js";
import { serviceList } from "@/api/applService.js";
import { getProduct } from "@/api/thePlatformIsSet.js";
import common from "@/mixins/common";
export default {
name: "PortalAdminVueApplService",
......@@ -72,11 +114,9 @@ export default {
curInfo: {}, // 当前选中设备信息
isSearch: false,
};
},
created() {
this.getList()
this.getList();
},
mounted() {
// this.setContentHigh();
......@@ -91,31 +131,31 @@ export default {
let { code, data, dict } = res;
if (code == 1) {
if (data.data.length) {
this.listArr.forEach(i => {
let arr = []
data.data.forEach(k => {
this.listArr.forEach((i) => {
let arr = [];
data.data.forEach((k) => {
if (i.id == k.productId) {
arr.push(k)
arr.push(k);
}
})
});
i.curInfo = arr
this.$nextTick()
})
i.curInfo = arr;
this.$nextTick();
});
}
}
});
},
handleSearch() {
this.isSearch = !this.isSearch;
if (this.isSearch) {
this.getServiceList();
} else {
this.searchVal = "";
this.active = 0;
this.getServiceList();
}
this.getServiceList();
// this.isSearch = !this.isSearch;
// if (this.isSearch) {
// this.getServiceList();
// } else {
// this.searchVal = "";
// this.active = 0;
// this.getServiceList();
// }
},
// 切换设备
handleChange(row, index) {
......@@ -123,7 +163,7 @@ export default {
this.searchVal = "";
},
handleDowload(url, systemServiceName) {
console.log(systemServiceName)
console.log(systemServiceName);
const a = document.createElement("a");
a.href = url;
a.download = systemServiceName;
......@@ -131,16 +171,15 @@ export default {
},
//获取列表
getList() {
getProduct({ page: 1, size: -1 }).then(res => {
res.data.data.forEach(i => {
i.curInfo = []
})
this.listArr = [...res.data.data]
console.log(this.listArr)
getProduct({ page: 1, size: -1 }).then((res) => {
res.data.data.forEach((i) => {
i.curInfo = [];
});
this.listArr = [...res.data.data];
console.log(this.listArr);
this.getServiceList();
})
}
});
},
},
};
</script>
......@@ -148,7 +187,7 @@ export default {
<style lang="less" scoped>
@headerH: 4.5rem;
.application .stepbox ._right .list>div {
.application .stepbox ._right .list > div {
width: 15%;
text-align: center;
overflow: hidden;
......@@ -196,7 +235,9 @@ export default {
display: flex;
align-items: center;
}
/deep/.ant-input-affix-wrapper .ant-input-suffix {
right: 70px !important;
}
/deep/.ant-input {
width: 30rem !important;
margin-right: 2rem;
......@@ -223,7 +264,7 @@ export default {
padding: 0;
border: none;
&>span {
& > span {
position: relative;
display: block;
width: 100%;
......@@ -267,8 +308,8 @@ export default {
width: 100%;
}
&>span:before,
&>span:after {
& > span:before,
& > span:after {
position: absolute;
content: "";
left: 0;
......@@ -281,21 +322,21 @@ export default {
transition: all 0.3s ease;
}
&>span:before {
& > span:before {
width: 2px;
height: 0%;
}
&>span:after {
& > span:after {
height: 2px;
width: 0%;
}
&>span:hover:before {
& > span:hover:before {
height: 100%;
}
&>span:hover:after {
& > span:hover:after {
width: 100%;
}
}
......@@ -401,16 +442,22 @@ export default {
width: 100%;
height: @headerH;
background: rgb(59, 135, 255);
background: -moz-linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: -webkit-linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: -moz-linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
background: -webkit-linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
background: linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#3b87ff", endColorstr="#6c35f7", GradientType=1);
}
}
</style>
\ No newline at end of file
</style>
<template>
<a-modal :title="VisibleTitle" :centered="true" :destroyOnClose="true" :visible="Visible" @cancel="Visible = false"
width="30%">
<a-form-model :label-col="{
span: 5,
}" :wrapper-col="{
span: 19,
}" layout="horizontal" ref="appInfoFome" :model="appInfoFome" :rules="appInfoRules">
<a-modal
:title="VisibleTitle"
:centered="true"
:destroyOnClose="true"
:visible="Visible"
@cancel="Visible = false"
width="30%"
>
<a-form-model
:label-col="{
span: 5,
}"
:wrapper-col="{
span: 19,
}"
layout="horizontal"
ref="appInfoFome"
:model="appInfoFome"
:rules="appInfoRules"
>
<a-form-model-item label="产品名称" prop="productName">
<a-input placeholder="请输入产品名称" allowClear v-model="appInfoFome.productName" />
<a-input
placeholder="请输入产品名称"
allowClear
v-model="appInfoFome.productName"
/>
</a-form-model-item>
</a-form-model>
<template slot="footer">
<a-button type="primary" class="addclass" @click="Modal_Ok">确定</a-button>
<a-button type="primary" class="addclass" @click="Modal_Ok"
>确定</a-button
>
<a-button @click="resetForm">重置</a-button>
</template>
</a-modal>
......@@ -27,7 +46,7 @@ export default {
VisibleTitle: "新增产品",
appInfoFome: {
productName: undefined,
siteId: JSON.parse(localStorage.getItem("siteId"))
siteId: JSON.parse(localStorage.getItem("siteId")),
}, //页面表单信息
appInfoRules: {
productName: [
......@@ -36,28 +55,28 @@ export default {
whitespace: true, //必选时,空格是否会被视为错误
message: "请输入产品名称",
trigger: "blur",
}
},
],
},
};
},
mounted() { },
mounted() {},
methods: {
Modal_Ok() {
this.$refs.appInfoFome.validate((valid) => {
if (valid) {
saveProduct(this.appInfoFome).then(res => {
let { code, msg } = res
saveProduct(this.appInfoFome).then((res) => {
let { code, msg } = res;
if (code == 1) {
this.$message.success('保存成功');
this.$message.success("保存成功");
this.resetForm();
this.Visible = false
this.$parent.getList()
this.Visible = false;
this.$parent.getList();
} else {
this.$message.error(msg);
}
})
});
} else {
this.$message.error(`请完善表单信息!`);
return false;
......@@ -66,7 +85,7 @@ export default {
},
resetForm() {
this.$nextTick(() => {
this.appInfoFome.productName = ''
this.appInfoFome.productName = "";
});
},
},
......@@ -82,4 +101,3 @@ export default {
}
}
</style>
......@@ -61,6 +61,7 @@
</a-form-model-item>
</a-form-model>
<template slot="footer">
<a-button type="primary" class="addclass" @click="reset">重置</a-button>
<a-button type="primary" class="addclass" @click="Modal_Ok"
>确定</a-button
>
......@@ -126,6 +127,23 @@ export default {
mounted() {},
methods: {
reset() {
this.$refs.appForm.resetFields();
this.uploadInfo = {
removeFileList: [], //移除文件列表
fileList: [], //文件列表
multiple: false, //多文件
listType: "text", //text, picture 和 picture-card
prePath: "file/fileupload", //附件存放相对路径 否 不填时候默认为 file/fileupload
objAttach: {
// 其他参数 data
// test: "001",
},
verload: 300, // 单位 M
limit: 1, //限制文件上传数量
whiteFileList: ["apk", "jpg", "jpeg", "png", "gif", "bmp"], //只允许上传apk包
};
},
getInfo(id) {
getAppsInfo({ id: id }).then((res) => {
res.data.isEnable = res.data.isEnable == 1;
......
<template>
<a-modal :width="modalInfo.width" :visible="modalInfo.visible" :title="modalInfo.title"
@cancel="modalInfo.visible = false" centered destroyOnClose>
<a-form-model :label-col="{
span: 4,
}" :wrapper-col="{
span: 20,
}" layout="horizontal" ref="appForm" :model="appForm" :rules="appRules">
<a-modal
:width="modalInfo.width"
:visible="modalInfo.visible"
:title="modalInfo.title"
@cancel="modalInfo.visible = false"
centered
destroyOnClose
>
<a-form-model
:label-col="{
span: 4,
}"
:wrapper-col="{
span: 20,
}"
layout="horizontal"
ref="appForm"
:model="appForm"
:rules="appRules"
>
<a-form-model-item label="材料名称" prop="docName">
<a-input v-model="appForm.docName" placeholder="请输入" allowClear />
</a-form-model-item>
<a-form-model-item label="版本号" prop="versionNumber">
<a-input v-model="appForm.versionNumber" placeholder="请输入" allowClear />
<a-input
v-model="appForm.versionNumber"
placeholder="请输入"
allowClear
/>
</a-form-model-item>
<a-form-model-item label="版本信息" prop="versionInfo">
<a-textarea v-model="appForm.versionInfo" placeholder="请输入" :rows="4" />
<a-textarea
v-model="appForm.versionInfo"
placeholder="请输入"
:rows="4"
/>
</a-form-model-item>
<a-form-model-item label="材料文件" prop="docFileUrl">
<MyUpload v-model="appForm.docFileUrl" :uploadInfo="uploadInfo">
......@@ -23,7 +44,10 @@
</a-form-model-item>
</a-form-model>
<template slot="footer">
<a-button type="primary" class="addclass" @click="Modal_Ok">确定</a-button>
<a-button type="primary" class="addclass" @click="reset">重置</a-button>
<a-button type="primary" class="addclass" @click="Modal_Ok"
>确定</a-button
>
<a-button @click="resetForm">取消</a-button>
</template>
</a-modal>
......@@ -46,7 +70,7 @@ export default {
docName: "",
versionNumber: "",
versionInfo: "",
docFileUrl: ""
docFileUrl: "",
},
uploadInfo: {
removeFileList: [], //移除文件列表
......@@ -61,41 +85,62 @@ export default {
whiteFileList: ["doc", "docx", "pdf", "xlsx", "xls"],
},
appRules: {
docName: [{ required: true, message: "请输入材料名称", trigger: ['blur', 'change'] }],
docName: [
{
required: true,
message: "请输入材料名称",
trigger: ["blur", "change"],
},
],
},
};
},
mounted() { },
mounted() {},
methods: {
reset() {
this.$refs.appForm.resetFields();
this.uploadInfo = {
removeFileList: [], //移除文件列表
fileList: [], //文件列表
defaultFileList: [],
multiple: false, //多文件
listType: "text", //text, picture 和 picture-card
prePath: "file/fileupload", //附件存放相对路径 否 不填时候默认为 file/fileupload
objAttach: {},
verload: 300, // 单位 M
limit: 1, //限制文件上传数量
whiteFileList: ["doc", "docx", "pdf", "xlsx", "xls"],
};
},
getInfo(id) {
getDocumentInfo({ id: id }).then(res => {
this.appForm = res.data
getDocumentInfo({ id: id }).then((res) => {
this.appForm = res.data;
if (res.data.docFileUrl) {
this.uploadInfo.fileList = [
{
uid: id,
name: res.data.docFileUrl,
url: res.data.docFileUrl,
}
]
},
];
}
})
});
},
Modal_Ok() {
this.$refs.appForm.validate((valid) => {
if (valid) {
saveDocument(this.appForm).then(res => {
let { code, msg } = res
saveDocument(this.appForm).then((res) => {
let { code, msg } = res;
if (code == 1) {
this.$message.success('保存成功');
this.$message.success("保存成功");
this.resetForm();
this.modalInfo.visible = false
this.$parent.getList()
this.modalInfo.visible = false;
this.$parent.getList();
} else {
this.$message.error(msg);
}
})
});
} else {
this.$message.error(`请完善表单信息!`);
return false;
......
......@@ -3,28 +3,47 @@
<div class="search_box" ref="search_box">
<h3>产品管理</h3>
<h4>
<a-input placeholder="请输入产品名称关键字查询" v-model="searchVal" />
<a-input
placeholder="请输入产品名称关键字查询"
allow-clear
v-model="searchVal"
/>
<button class="search_btn btn" @click="getList">
<span>查询</span>
</button>
</h4>
</div>
<div class="main">
<a-button type="primary" class="addclass add_btn" ghost @click="showModal()">
<a-button
type="primary"
class="addclass add_btn"
ghost
@click="showModal()"
>
新增产品
</a-button>
<ul class="content">
<li class="list" v-for="item, index of listData" :key="index">
<li class="list" v-for="(item, index) of listData" :key="index">
<a-popover placement="leftBottom" trigger="click">
<template slot="content">
<div class="popoverContent">
<p>
<a-button type="link" size="small" style="color: #0595fd" @click="showModal(item)">
<a-button
type="link"
size="small"
style="color: #0595fd"
@click="showModal(item)"
>
编辑
</a-button>
</p>
<p>
<a-popconfirm title="确定要删除此产品吗?" ok-text="确定" cancel-text="取消" @confirm="delModal(item)">
<a-popconfirm
title="确定要删除此产品吗?"
ok-text="确定"
cancel-text="取消"
@confirm="delModal(item)"
>
<a-button type="link" size="small" style="color: #ff4d4f">
删除
</a-button>
......@@ -58,44 +77,44 @@ export default {
name: "PortalAdminVueProductManage",
data() {
return {
searchVal: '',
listData: []
searchVal: "",
listData: [],
};
},
components: {
AddEditAppName,
},
mounted() {
this.getList()
this.getList();
},
methods: {
delModal(item) {
deleteProduct({
id: item.id
id: item.id,
}).then((res) => {
let { code, msg } = res
let { code, msg } = res;
if (code == 1) {
this.$message.success('删除成功');
this.getList()
this.$message.success("删除成功");
this.getList();
} else {
this.$message.error(msg);
}
})
});
},
getList() {
getProduct({
page: 1,
size: -1,
productName: this.searchVal
productName: this.searchVal,
}).then((res) => {
this.listData = res.data.data
})
this.listData = res.data.data;
});
},
showModal(item) {
if (item) {
this.$refs.AddEditAppName.VisibleTitle = "编辑";
this.$refs.AddEditAppName.appInfoFome.id = item.id
this.$refs.AddEditAppName.appInfoFome.productName = item.productName
this.$refs.AddEditAppName.appInfoFome.id = item.id;
this.$refs.AddEditAppName.appInfoFome.productName = item.productName;
} else {
this.$refs.AddEditAppName.VisibleTitle = "新增产品";
}
......@@ -127,7 +146,7 @@ export default {
</script>
<style lang="less" scoped>
.not-data{
.not-data {
line-height: 100px;
text-align: center;
width: 100%;
......@@ -160,7 +179,9 @@ export default {
display: flex;
align-items: center;
}
/deep/.ant-input-affix-wrapper .ant-input-suffix {
right: 70px !important;
}
/deep/.ant-input {
width: 30rem !important;
margin-right: 2rem;
......@@ -187,7 +208,7 @@ export default {
padding: 0;
border: none;
&>span {
& > span {
position: relative;
display: block;
width: 100%;
......@@ -231,8 +252,8 @@ export default {
width: 100%;
}
&>span:before,
&>span:after {
& > span:before,
& > span:after {
position: absolute;
content: "";
left: 0;
......@@ -245,21 +266,21 @@ export default {
transition: all 0.3s ease;
}
&>span:before {
& > span:before {
width: 2px;
height: 0%;
}
&>span:after {
& > span:after {
height: 2px;
width: 0%;
}
&>span:hover:before {
& > span:hover:before {
height: 100%;
}
&>span:hover:after {
& > span:hover:after {
width: 100%;
}
}
......@@ -274,17 +295,17 @@ export default {
border: 1px solid #d7dae2;
overflow: hidden;
&>.add_btn {
& > .add_btn {
margin: 15px;
}
&>.content {
& > .content {
display: flex;
flex-wrap: wrap;
border-top: 1px solid #d7dae2;
border-bottom: 1px solid #d7dae2;
&>.list {
& > .list {
width: 25%;
padding: 15px;
display: flex;
......@@ -293,7 +314,7 @@ export default {
border-right: 1px solid #d7dae2;
border-bottom: 1px solid #d7dae2;
&>.app-operation {
& > .app-operation {
margin: 8px 0;
height: 25px;
width: 25px;
......@@ -304,7 +325,7 @@ export default {
cursor: pointer;
}
&>.app-img {
& > .app-img {
width: 108px;
height: 108px;
box-shadow: 0 2px 12px 0 rgba(0, 0, 0, 0.1);
......@@ -312,14 +333,14 @@ export default {
border-radius: 6px;
}
&>.app-name {
& > .app-name {
font-weight: bold;
font-size: 18px;
text-align: center;
margin: 8px 0;
}
&>.app-option {
& > .app-option {
margin: 8px 0;
color: #0595fd;
display: flex;
......@@ -327,7 +348,7 @@ export default {
align-items: center;
font-size: 14px;
&>li {
& > li {
cursor: pointer;
}
}
......@@ -341,15 +362,21 @@ export default {
width: 100%;
height: @headerH;
background: rgb(59, 135, 255);
background: -moz-linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: -webkit-linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: linear-gradient(174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%);
background: -moz-linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
background: -webkit-linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
background: linear-gradient(
174deg,
rgba(59, 135, 255, 1) 24%,
rgba(108, 53, 247, 1) 85%
);
filter: progid:DXImageTransform.Microsoft.gradient(startColorstr="#3b87ff", endColorstr="#6c35f7", GradientType=1);
}
}
......
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