jcbranch
fanluyan 1 year ago
parent 2146867f82
commit 2c4959a11b

@ -0,0 +1,77 @@
@font-face {
font-family: "iconfont"; /* Project id */
src: url('iconfont.ttf?t=1709789909096') format('truetype');
}
.iconfont {
font-family: "iconfont" !important;
font-size: 16px;
font-style: normal;
-webkit-font-smoothing: antialiased;
-moz-osx-font-smoothing: grayscale;
}
.icon-1wenhe:before {
content: "\e653";
}
.icon-paizhao:before {
content: "\e6ba";
}
.icon-paizhao-xianxing:before {
content: "\e8d1";
}
.icon-tuiguanglishitupianjinqun:before {
content: "\e613";
}
.icon-gongsi:before {
content: "\e62e";
}
.icon-shudianxianlu:before {
content: "\e60a";
}
.icon-dianli:before {
content: "\e649";
}
.icon-dianlihangye:before {
content: "\e791";
}
.icon-shexiangtoulixian:before {
content: "\e7b2";
}
.icon-video-camera:before {
content: "\e962";
}
.icon-qixiang:before {
content: "\e67c";
}
.icon-shexiangtou-lixian:before {
content: "\ef1c";
}
.icon-shexiangtou-zaixian:before {
content: "\ef1d";
}
.icon-shudianxianlu_2722010801:before {
content: "\efed";
}
.icon-tupian_normal:before {
content: "\e681";
}
.icon-fubing:before {
content: "\e7ac";
}

Binary file not shown.

@ -29,18 +29,18 @@ export default {
path: "/upgradation",
name: "上传APK/OTA",
},
// {
// path: "/upgradationOta",
// name: "Ota",
// },
// {
// path: "/upgradationOta",
// name: "Ota",
// },
{
path: "/activity",
name: "活动列表",
},
// {
// path: "/userlist",
// name: "",
// path: "/deviceConfig",
// name: "",
// },
],
};

@ -6,7 +6,7 @@ import ElementUI from "element-ui";
import "umy-ui/lib/theme-chalk/index.css"; // 引入样式
// import "element-ui/lib/theme-chalk/index.css";
import "../src/assets/css/theme/index.css"; //cac主题
import "./assets/fonts/iconfont.css"; //按钮
Vue.use(ElementUI, {
size: "small",
});

@ -4,7 +4,6 @@ import VueRouter from "vue-router";
Vue.use(VueRouter);
const routes = [
{
path: "/login",
name: "login",
@ -61,7 +60,7 @@ const routes = [
keepAlive: true,
},
},
{
path: "/activity",
component: () => import("../views/activityList/index.vue"),
@ -71,6 +70,15 @@ const routes = [
keepAlive: true,
},
},
{
path: "/deviceConfig",
component: () => import("../views/deviceConfig/index.vue"),
name: "deviceConfig",
meta: {
title: "设备配置",
keepAlive: true,
},
},
{
path: "/userlist",
component: () => import("../views/userList/index.vue"),

@ -7,6 +7,14 @@ export function loginJoggle(data) {
data,
});
}
//获取树状结构
export function getdyTreeListJoggle(data) {
return request({
url: "/xymanager/getdyTreeList",
method: "post",
data,
});
}
//获取用户装置信息
export function getTerminalJoggle(data) {
@ -21,11 +29,10 @@ export function exportTerminalApi(data) {
url: "/xymanager/terminal/exportForMaintain",
method: "get",
params: data,
responseType: 'blob'
responseType: "blob",
});
}
//获取规约
export function getProtocolList(data) {
return request({
@ -34,7 +41,7 @@ export function getProtocolList(data) {
params: data,
});
}
//获取 电压 线路 杆塔
//获取 电压 线路 杆塔
export function getSearchInfo(data) {
return request({
url: "/xymanager/getLineAndGt",
@ -106,7 +113,6 @@ export function cmdActlistApi(data) {
});
}
//查询已经下发的命令
export function cmdActHislistApi(data) {
return request({
@ -155,7 +161,6 @@ export function logDeleteApi(data) {
});
}
//获取升级列表
export function upgradeListApi(data) {
return request({
@ -196,22 +201,3 @@ export function upgradeDeleteApi(data) {
},
});
}

@ -0,0 +1,240 @@
<template>
<div class="siderBar">
<div class="searchBar">
<el-input
placeholder="输入关键字进行过滤"
v-model="filterText"
prefix-icon="el-icon-search"
clearable
>
</el-input>
</div>
<div class="radioFilter">
<el-radio-group v-model="zzradio" @input="getRadio">
<el-radio :label="-1">全部</el-radio>
<el-radio :label="1">在线</el-radio>
<el-radio :label="0">离线</el-radio>
</el-radio-group>
<el-button
class="refresh"
@click="getLineTreeStatus"
type="text"
icon="el-icon-refresh-right"
>刷新</el-button
>
</div>
<el-tree
ref="tree"
:data="treeData"
:props="defaultProps"
default-expand-all
node-key="id"
highlight-current
:filter-node-method="filterNode"
:current-node-key="currentNodekey"
@node-click="handleNodeClick"
>
<span class="custom-tree-node" slot-scope="{ node, data }">
<span>
<span
v-if="node.level === 1 && node.label !== '收藏夹'"
class="iconfont icon-dianli"
style="margin-right: 6px"
></span>
<span
v-if="node.level === 2 && data.bsManufacturer"
class="iconfont icon-dianlihangye"
style="margin-right: 6px"
>
</span>
<span v-if="!data.bsManufacturer && !data.dyValue">
<span
class="iconfont icon-shexiangtoulixian"
v-if="data.onlinestatus == 0"
:class="data.onlinestatus == 0 ? 'disconnect' : ''"
style="margin-right: 6px"
></span>
<span
class="iconfont icon-shexiangtou-lixian"
v-else
:class="data.onlinestatus == 0 ? 'disconnect' : ''"
style="margin-right: 6px"
></span>
</span>
<span :class="data.onlinestatus == 0 ? 'disconnect' : ''"
>{{ node.label }}
</span></span
>
</span>
</el-tree>
</div>
</template>
<script>
import { getdyTreeListJoggle } from "@/utils/api/index";
export default {
name: "report",
components: {},
data() {
return {
filterText: "", //
zzradio: 1, //线
treeData: [],
defaultProps: {
//
children: "list",
label: "name",
},
currentData: "",
currentNodekey: null, //
};
},
computed: {},
watch: {
filterText(newVal) {
this.handleFilter(); // filterText
},
},
created() {},
mounted() {
this.getLineTreeList();
},
methods: {
handleFilter() {
// 500
setTimeout(() => {
this.$refs.tree.filter(this.filterText);
}, 500);
},
//
filterNode(value, data, node) {
//
if (!value) return true;
this.searchName = data.name + data.cmdid;
//console.log(this.searchName);
// valuedatalabel
if (this.searchName.indexOf(value) !== -1) {
return true;
}
let nowval = data[this.defaultProps.label].toUpperCase();
return nowval.indexOf(value.toUpperCase()) !== -1;
},
getRadio() {
console.log(this.zzradio);
this.filterText = "";
this.getLineTreeStatus();
},
getLineTreeList() {
getdyTreeListJoggle({ type: this.zzradio })
.then((res) => {
this.treeData = res.data.list;
})
.catch((err) => {
console.log(err); //
});
},
//tree
getLineTreeStatus() {
console.log("点击了刷新");
if (this.filterText !== "") {
this.$refs.tree.filter(this.filterText);
} else {
getdyTreeListJoggle({ type: this.zzradio })
.then((res) => {
console.log(res);
this.treeData = res.data.list;
})
.catch((err) => {
console.log(err); //
});
}
},
//treenode
handleNodeClick(data) {},
},
beforeDestroy() {},
};
</script>
<style lang="less">
.siderBar {
width: 312px;
display: flex;
flex-direction: column;
padding: 16px 0;
border: 1px solid #dddddd;
.searchBar {
width: 94%;
margin: 0 auto;
margin-bottom: 8px;
}
.radioFilter {
width: 94%;
margin: 0 auto;
margin-bottom: 8px;
font-size: 12px;
display: flex;
justify-content: space-around;
.refresh {
}
.el-radio-group {
display: flex;
align-items: center;
justify-content: center;
.el-radio {
margin-right: 16px;
}
}
}
.el-tree {
height: 100%;
overflow-y: auto;
overflow-x: hidden;
.el-tree-node__content {
height: 32px;
font-size: 12px;
}
.custom-tree-node {
color: #333;
overflow: hidden;
span {
display: flex;
display: inline-table;
overflow: hidden;
align-items: center;
}
.num {
color: #169e8c;
}
}
}
.el-tree--highlight-current
.el-tree-node.is-current
> .el-tree-node__content {
//
color: #fff;
background: #169e8c;
.custom-tree-node {
color: #fff;
//overflow: hidden;
span {
display: flex;
//overflow: hidden;
align-items: center;
.num {
color: #fff;
}
.iconfont {
//width: 30px;
display: inline-table;
}
}
}
}
.disconnect {
color: #d3d3d3;
}
}
</style>

@ -0,0 +1,46 @@
<template>
<div class="deviceConfig">
<sideBar ref="sideTree"></sideBar>
<div class="configBox"></div>
</div>
</template>
<script>
import sideBar from "./components/sideBar";
import {} from "@/utils/api/index";
export default {
name: "report",
components: {
sideBar,
},
data() {
return {};
},
computed: {},
created() {},
mounted() {},
methods: {},
beforeDestroy() {},
};
</script>
<style lang="less">
.deviceConfig {
height: calc(100% - 24px);
width: calc(100% - 24px);
padding: 12px;
display: flex;
.configBox {
display: flex;
width: 100%;
height: 100%;
flex: 1;
overflow: hidden;
border: 1px solid #dddddd;
// border-radius: 4px;
border-left: none;
box-sizing: border-box;
}
}
</style>

@ -297,7 +297,23 @@ export default {
this.formdata = jsonSearch;
console.log(this.formdata);
} else {
this.formdata = jsonSearch;
this.formdata = {
dyId: -1,
lineId: -1,
towerId: -1,
isonline: -1,
protocol: -1,
mntn: 1,
activityId: -1,
oid: "",
oidExclude: 0,
cmdid: "",
cmdidExclude: 0,
cma: "",
cmaExclude: 0,
version: "",
versionExclude: 0,
};
}
// this.formdata =
// JSON.parse(localStorage.getItem("searchParams")) !== null

@ -8,7 +8,8 @@
v-for="item in typeOptions"
:key="item.value"
:label="item.label"
:value="item.value">
:value="item.value"
>
</el-option>
</el-select>
</div>
@ -45,7 +46,6 @@
>上传到服务器</el-button
>
</div>
</div>
<div class="uploadPressMask" v-if="progressLoading">
<div class="centerClass">
@ -70,19 +70,12 @@
></el-table-column>
<el-table-column prop="fileName" label="文件名称">
<template slot-scope="scope">
<span
>
{{ scope.row.fileName }}</span
>
<span> {{ scope.row.fileName }}</span>
</template>
</el-table-column>
<el-table-column prop="path" label="文件路径">
<template slot-scope="scope">
<span
@click="handleClick(scope.row)"
class="buttonText"
>
<span @click="handleClick(scope.row)" class="buttonText">
{{ scope.row.path }}</span
>
</template>
@ -138,7 +131,7 @@ import {
upgradeListApi,
upgradeUpLoadApi,
upgradeDeleteApi,
upgradeTitleApi
upgradeTitleApi,
} from "@/utils/api/index";
export default {
@ -150,15 +143,18 @@ export default {
fileList: [],
reportData: {
title: "",
type:0,
type: 0,
},
typeOptions:[{
typeOptions: [
{
value: 0,
label: 'APK'
}, {
value:1,
label:'OTA'
}],
label: "APK",
},
{
value: 1,
label: "OTA",
},
],
fileData: [], //
fileloading: false,
editShow: false,
@ -183,19 +179,19 @@ export default {
methods: {
//
handleClick(row) {
console.log(row)
// a
const a = document.createElement('a');
// ahrefURL
a.href = '/apk/'+row.path;
console.log(a.href)
//
a.download = row.fileName; //
//
document.body.appendChild(a);
a.click();
// a
document.body.removeChild(a);
console.log(row);
// a
const a = document.createElement("a");
// ahrefURL
a.href = "/apk/" + row.path;
console.log(a.href);
//
a.download = row.fileName; //
//
document.body.appendChild(a);
a.click();
// a
document.body.removeChild(a);
},
//
handleProgress(event, file, fileList) {
@ -212,19 +208,19 @@ export default {
beforeUpload(file) {
const fileName = file.name;
console.log(fileName);
if (fileName.toLowerCase().includes('apk')) {
this.reportData.type=0
if (fileName.toLowerCase().includes("apk")) {
this.reportData.type = 0;
}
if (fileName.toLowerCase().includes('zip')) {
this.reportData.type=1
}
if (fileName.length > 19) {
this.$message.error("文件名长度不能超过 19 个字符!");
return false; //
if (fileName.toLowerCase().includes("zip")) {
this.reportData.type = 1;
}
// if (fileName.length > 19) {
// this.$message.error(" 19 ");
// return false; //
// }
return true; //
},
//apk
submitUpload() {
//console.log();
@ -264,7 +260,6 @@ export default {
this.getUpgradeList();
this.progressLoading = false;
} else {
this.$message({
duration: 1500,
showClose: true,
@ -278,7 +273,7 @@ export default {
})
.catch((error) => {});
},
getUpgradeList() {
this.fileloading = true;
upgradeListApi()
@ -353,7 +348,7 @@ export default {
height: calc(100% - 24px);
width: calc(100% - 24px);
padding: 12px;
.upgradeBox {
height: 32px;
line-height: 32px;
@ -457,12 +452,12 @@ export default {
.el-table::before {
height: 1px !important;
}
.buttonText{
color:#169e8c;
.buttonText {
color: #169e8c;
cursor: pointer;
&:hover {
text-decoration: underline;
}
text-decoration: underline;
}
}
}
.el-dialog__headerbtn {

Loading…
Cancel
Save