fix: BUG修改

This commit is contained in:
kun 2024-06-05 15:16:25 +08:00
parent fecca362c4
commit 13c0c5b1d5
12 changed files with 262 additions and 72 deletions

View File

@ -82,9 +82,9 @@ if (process.env.NODE_ENV == "development") {
// axios.defaults.baseURL ='http://huli.zjzhiliao.com/jxjgdapi/' //金林湾测试线上
// axios.defaults.baseURL ='http://101.43.164.214:45001/' //上海张江
// axios.defaults.baseURL ='http://101.43.164.214:45011/' //上海优益(上海建工)
// axios.defaults.baseURL = 'http://192.168.34.221:28888/' //郭圣雄本地
axios.defaults.baseURL = 'http://192.168.34.221:28888/' //郭圣雄本地
// axios.defaults.baseURL = 'http://192.168.34.221:28889/' //郭圣雄本地
axios.defaults.baseURL = "http://192.168.34.221:9111/"; //郭圣雄本地
// axios.defaults.baseURL = "http://192.168.34.221:9111/"; //郭圣雄本地
// axios.defaults.baseURL = 'http://192.168.34.155:19111/' //彭洁本地
// axios.defaults.baseURL = 'http://182.90.224.237:51234' //郭圣雄远程
// axios.defaults.baseURL = 'http://jxj.zhgdyun.com:61212/' //彭洁远程

View File

@ -13,6 +13,16 @@
<span>个人中心</span>
<div class="row-line"></div>
<div class="classify-item">
<div
@click="jumpRouter(item.modulePath)"
:class="isActive(item.modulePath) ? 'active-item' : ''"
v-for="(item,index) in moduleList"
:key="index"
>
{{item.moduleName}}
</div>
</div>
<!-- <div class="classify-item">
<div
@click="jumpRouter('/workSpace')"
:class="isActive('/workSpace') ? 'active-item' : ''"
@ -31,7 +41,7 @@
>
消息中心
</div>
</div>
</div> -->
</div>
</div>
<!-- 点击内容 -->
@ -45,15 +55,35 @@
</div>
</template>
<script>
import {
getNewUserAllModulePageApi,
} from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
visible: false,
moduleList: []
};
},
created() {},
created() {
this.getModuleList();},
mounted() {},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
if(res.result && res.result.moduleList){
this.moduleList = res.result.moduleList;
console.log(this.moduleList,123321)
} else {
this.moduleList = [];
}
});
},
isActive(val) {
return this.$route.path.indexOf(val) != -1 ? true : false;
},

View File

@ -55,7 +55,7 @@
<div class="title_near flex" v-if="![1,2].includes($store.state.userInfo.accountType)">
<userChange></userChange>
</div>
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType)">
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType) && workSpaceShow">
<div class="divider-line"></div>
<centerChange></centerChange>
</div>
@ -226,7 +226,8 @@ export default {
timer: null,
jumpToken: "",
showQrCode: false,
educationId: ""
educationId: "",
workSpaceShow: false
};
},
components: {
@ -267,6 +268,9 @@ export default {
}
this.loginData = JSON.parse(localStorage.getItem("systemInfo"));
// console.log('',this.loginData)\
if(this.$store.state.projectSn){
this.getModuleList();
}
},
mounted() {
if (localStorage.getItem("systemInfo")) {
@ -311,6 +315,22 @@ export default {
},
},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
getEduIdFn(){
let data = {
projectSn: this.$store.state.projectSn,

View File

@ -46,7 +46,7 @@
:style="{ height: groupListData.length > 4 ? '300px' : 'auto' }"
v-if="isUserList"
>
<vue-scroll style="height: 100%;" v-if="groupListData.length > 0">
<vue-scroll style="height: 100%" v-if="groupListData.length > 0">
<div
class="content-list-item"
v-for="(item, index) in groupListData"
@ -68,44 +68,47 @@
</div> -->
</div>
<div class="tree-group" v-else>
<div class="select-list" :style="{ height: selectedGroupData.length > 4 ? '300px' : 'auto' }">
<vue-scroll style="height: 100%;">
<el-input
placeholder="输入关键字进行查找"
v-model="filterText"
style="width: 98%;"
suffix-icon="el-icon-search"
size="medium"
>
</el-input>
<el-tree
:data="selectedGroupData"
:default-expanded-keys="expandKey"
:default-expand-all="false"
node-key="sn"
ref="tree"
:props="selectTreeProps"
:filter-node-method="filterNode"
:highlight-current="true"
:check-on-click-node="false"
style="margin:10px 5px;"
>
<span class="custom-tree-node" slot-scope="{ node, data }">
<span
style="
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: inline-block;
"
@click="treeClick(data)"
:class="data.projectSn ? 'projectStyle' : 'companyStyle'"
:title="node.label"
>{{ node.label }}</span
>
</span>
</el-tree>
<div
class="select-list"
:style="{ height: selectedGroupData.length > 4 ? '300px' : 'auto' }"
>
<vue-scroll style="height: 100%">
<el-input
placeholder="输入关键字进行查找"
v-model="filterText"
style="width: 98%"
suffix-icon="el-icon-search"
size="medium"
>
</el-input>
<el-tree
:data="selectedGroupData"
:default-expanded-keys="expandKey"
:default-expand-all="false"
node-key="sn"
ref="tree"
:props="selectTreeProps"
:filter-node-method="filterNode"
:highlight-current="true"
:check-on-click-node="false"
style="margin: 10px 5px"
>
<span class="custom-tree-node" slot-scope="{ node, data }">
<span
style="
width: 100%;
overflow: hidden;
text-overflow: ellipsis;
white-space: nowrap;
display: inline-block;
"
@click="treeClick(data)"
:class="data.projectSn ? 'projectStyle' : 'companyStyle'"
:title="node.label"
>{{ node.label }}</span
>
</span>
</el-tree>
</vue-scroll>
</div>
</div>
@ -132,6 +135,7 @@
<script>
import { getGroupListApi } from "@/assets/js/api/loginSign.js";
import { getComapnyStatisticsSupplierListApi } from "@/assets/js/api/company/project";
import { getNewUserAllModulePageApi } from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
@ -148,7 +152,8 @@ export default {
expandKey: [],
selectFirst: 0,
isShowGroup: false,
selectGroupFirst: 0
selectGroupFirst: 0,
workSpaceShow: false,
};
},
created() {
@ -162,9 +167,26 @@ export default {
this.expandKey = [this.selectedProjectSn];
}
this.loadData();
this.getModuleList();
},
mounted() {},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
//
loadData() {
let that = this;
@ -177,13 +199,13 @@ export default {
sn: sn,
projectType: projectType,
}).then((res) => {
console.log(res,666555444)
if(res.result && res.result.companyList){
if(res.result.companyList.length > 1){
console.log(res, 666555444);
if (res.result && res.result.companyList) {
if (res.result.companyList.length > 1) {
that.isShowGroup = true;
} else {
if(res.result.companyList.length == 1){
that.selectShowGroup(res.result.companyList[0])
if (res.result.companyList.length == 1) {
that.selectShowGroup(res.result.companyList[0]);
} else {
that.isShowGroup = false;
}
@ -262,11 +284,14 @@ export default {
this.selectedGroupData = [item];
this.$store.commit("setSelectedGroupSn", item.companySn); // Sn
this.filterTreeData(this.selectedGroupData);
if (this.$route.path.indexOf("supplier") == -1) {
this.$router.push("/workSpace");
if (this.workSpaceShow) {
if (this.$route.path.indexOf("supplier") == -1) {
this.$router.push("/workSpace");
} else {
this.$router.push("/supplierIndex");
}
} else {
this.$router.push("/supplierIndex");
this.$router.push("/projectIndex");
}
console.log(this.selectedGroupData);
} else {
@ -300,7 +325,10 @@ export default {
this.filterTreeData(this.selectedGroupData);
this.$nextTick(() => {
//
if(this.$route.path.indexOf("/supplierIndex") != -1 && !this.$store.state.projectSn){
if (
this.$route.path.indexOf("/supplierIndex") != -1 &&
!this.$store.state.projectSn
) {
this.selectProject(this.selectedGroupData[0]);
} else {
this.setTreeActive();
@ -332,10 +360,14 @@ export default {
// popover
this.visible = false;
}
if (this.$route.path.indexOf("supplier") == -1) {
this.$router.push("/workSpace");
if (this.workSpaceShow) {
if (this.$route.path.indexOf("supplier") == -1) {
this.$router.push("/workSpace");
} else {
this.$router.push("/supplierIndex");
}
} else {
this.$router.push("/supplierIndex");
this.$router.push("/projectIndex");
}
},
filterNode(value, data) {

View File

@ -15,7 +15,7 @@
<!-- <div class="title_near flex" v-if="![1,2].includes($store.state.userInfo.accountType)">
<userChange></userChange>
</div> -->
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType)">
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType) && workSpaceShow">
<div class="divider-line"></div>
<centerChange></centerChange>
</div>
@ -74,6 +74,9 @@
import account from "@/components/account.vue";
import userChange from "@/components/userChange.vue";
import centerChange from "@/components/centerChange.vue";
import {
getNewUserAllModulePageApi,
} from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
@ -101,7 +104,8 @@ export default {
"loginLogo": "",
"platformLogo": "",
"platformName": "智慧工地云平台"
}
},
workSpaceShow: false
};
},
components:{
@ -112,6 +116,9 @@ export default {
created() {
this.company = COMPANY;
console.log(COMPANY)
if(this.$store.state.projectSn){
this.getModuleList();
}
},
mounted(){
this.getAllModule()
@ -123,6 +130,22 @@ export default {
},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
hasSubMenu(list) {
//
let onoff = false;

View File

@ -137,7 +137,7 @@
</el-button>
</el-form-item>
<!-- v-if="beaconForm.supplierType!=5" -->
<el-form-item :label="$t('message.laborDev.appID')" v-if="beaconForm.supplierType!=5" prop="appId" :rules='[
<el-form-item :label="$t('message.laborDev.appID')" v-if="![5,7,9].includes(beaconForm.supplierType)" prop="appId" :rules='[
{
required: true,
message: this.$t("message.personnelPosition.required"),
@ -149,7 +149,7 @@
:placeholder="$t('message.personnelPosition.please_enter')"
></el-input>
</el-form-item>
<el-form-item v-if="beaconForm.supplierType!=4&&beaconForm.supplierType!=6&&beaconForm.supplierType!=5" :label="$t('message.laborDev.projectAppKey')" prop="appKey" :rules='[
<el-form-item v-if="![4,5,6,7,9].includes(beaconForm.supplierType)" :label="$t('message.laborDev.projectAppKey')" prop="appKey" :rules='[
{
required: true,
message: this.$t("message.personnelPosition.required"),
@ -161,7 +161,7 @@
:placeholder="$t('message.personnelPosition.please_enter')"
></el-input>
</el-form-item>
<el-form-item v-if="beaconForm.supplierType!=6&&beaconForm.supplierType!=5" :label="$t('message.laborDev.projectAppSecret')" prop="appSecret" :rules='[
<el-form-item v-if="![5,6,7,9].includes(beaconForm.supplierType)" :label="$t('message.laborDev.projectAppSecret')" prop="appSecret" :rules='[
{
required: true,
message: this.$t("message.personnelPosition.required"),

View File

@ -15,7 +15,7 @@
<!-- <div class="title_near flex" v-if="![1,2].includes($store.state.userInfo.accountType)">
<userChange></userChange>
</div> -->
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType)">
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType) && workSpaceShow">
<div class="divider-line"></div>
<centerChange></centerChange>
</div>
@ -83,6 +83,9 @@
import account from "@/components/account.vue";
import userChange from "@/components/userChange.vue";
import centerChange from "@/components/centerChange.vue";
import {
getNewUserAllModulePageApi,
} from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
@ -98,7 +101,8 @@ export default {
"loginLogo": "",
"platformLogo": "",
"platformName": "智慧工地云平台"
}
},
workSpaceShow: false
};
},
components:{
@ -109,6 +113,9 @@ export default {
created() {
this.company = COMPANY;
console.log(COMPANY)
if(this.$store.state.projectSn){
this.getModuleList();
}
},
mounted(){
// this.getAllModule()
@ -120,6 +127,22 @@ export default {
},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
backTo(){
this.$router.back();
},

View File

@ -1061,7 +1061,7 @@
</div>
</el-col>
<el-col :span="12">
<div class="grid-content">
<div class="grid-content" v-if="isIscDevice">
<span class="label">车辆下发状态</span>
<span class="value">
<span

View File

@ -57,6 +57,7 @@
>{{ $t("message.deviceManage.query") }}</el-button
>
<el-button
v-if="isIscDevice"
v-permission="{
key: 'clgl_synchronizeVchicleTrafficData',
menuPath: '/project/carManage/realTimeData',
@ -253,6 +254,9 @@ import {
getCarPassRecordListByPageApi,
pullCarDataApi
} from "@/assets/js/api/carManage";
import {
projectCarConfigInfoList
} from "@/assets/js/api/laborPerson";
export default {
name: "historyData",
data() {
@ -288,14 +292,27 @@ export default {
pageNo: 1,
pageSize: 10,
total: 0,
isIscDevice: false
};
},
created() {
this.projectSn = this.$store.state.projectSn;
this.selectNowDate()
this.onSubmit();
this.getConfig();
},
methods: {
getConfig() {
projectCarConfigInfoList({
projectSn: this.$store.state.projectSn,
}).then((result) => {
if (result.success) {
if (result.result && result.result.length) {
this.isIscDevice = result.result[0].supplierType == 9 ? true: false;
}
}
});
},
//
confirmPullData(){
if(!this.timeRange || this.timeRange.length == 0){

View File

@ -15,7 +15,7 @@
<!-- <div class="title_near flex" v-if="![1,2].includes($store.state.userInfo.accountType)">
<userChange></userChange>
</div> -->
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType)">
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType) && workSpaceShow">
<div class="divider-line"></div>
<centerChange></centerChange>
</div>
@ -107,6 +107,9 @@ import userChange from "@/components/userChange.vue";
import centerChange from "@/components/centerChange.vue";
import { getGroupListByCompanyApi, jumpLargeUserInfoApi } from "@/assets/js/api/loginSign.js";
import { getProjectDetail } from "@/assets/js/api/baseInfo.js";
import {
getNewUserAllModulePageApi,
} from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
@ -124,7 +127,7 @@ export default {
"platformLogo": "",
"platformName": "智慧工地云平台"
},
projectSn: ""
workSpaceShow: false
};
},
components:{
@ -140,6 +143,9 @@ export default {
this.getGroupTreeData();
this.company = COMPANY;
console.log(COMPANY)
if(this.$store.state.projectSn){
this.getModuleList();
}
},
mounted(){
// this.getAllModule()
@ -151,6 +157,22 @@ export default {
},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
//
getDataDateils() {
let data = {

View File

@ -15,7 +15,7 @@
<!-- <div class="title_near flex" v-if="![1,2].includes($store.state.userInfo.accountType)">
<userChange></userChange>
</div> -->
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType)">
<div class="title_near-tow flex" v-if="![11,1,2].includes($store.state.userInfo.accountType) && workSpaceShow">
<div class="divider-line"></div>
<centerChange></centerChange>
</div>
@ -83,6 +83,9 @@
import account from "@/components/account.vue";
import userChange from "@/components/userChange.vue";
import centerChange from "@/components/centerChange.vue";
import {
getNewUserAllModulePageApi,
} from "@/assets/js/api/jxjadmin.js";
export default {
data() {
return {
@ -96,7 +99,8 @@ export default {
"loginLogo": "",
"platformLogo": "",
"platformName": "智慧工地云平台"
}
},
workSpaceShow: false
};
},
components:{
@ -107,6 +111,9 @@ export default {
created() {
this.company = COMPANY;
console.log(COMPANY)
if(this.$store.state.projectSn){
this.getModuleList();
}
},
mounted(){
// this.getAllModule()
@ -115,9 +122,24 @@ export default {
}
document.title='企业后台'
console.log('mounted',this.$route.path)
},
methods: {
// ()
getModuleList() {
getNewUserAllModulePageApi({
projectSn: this.$store.state.projectSn,
moduleType: 7,
userId: this.$store.state.userInfo.userId,
}).then((res) => {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
return;
} else {
this.workSpaceShow = true;
}
});
},
backTo(){
this.$router.back();
},

View File

@ -183,6 +183,7 @@ export default {
let all = res.result.moduleList;
if (all.length == 0) {
this.workSpaceShow = false;
this.$router.push("/projectIndex")
return;
} else {
this.workSpaceShow = false;