中建四局大屏跳转参数问题修复

This commit is contained in:
骆乐 2022-11-07 18:47:58 +08:00
parent ec1a22d1b1
commit 4079526950
15 changed files with 95 additions and 26 deletions

BIN
dist.zip

Binary file not shown.

View File

@ -542,6 +542,7 @@ export default {
},
parseLoginData(data) {
console.log("登录进来的data", data);
localStorage.setItem('sn',data.sn)
window._paq.push(["trackEvent", "点击", "登录", "登录账号"]);
this.$message.success(this.$t("message.login.login_success_msg")); //
this.$http.defaults.headers.common["Authorization"] =

View File

@ -33,6 +33,7 @@ export default {
components: { LeftThree },
data() {
return {
projectSn:"",
//
open: true,
//
@ -40,7 +41,7 @@ export default {
projectName: { label: '项目名称:', value: '' },
bulidStatus: { label: '项目状态:', value: '' },
constructionStage: { label: '形象进度:', value: '' },
households:{label: '项目造价:', value: ''},
households:{label: '户数:', value: ''},
// val2:{label: ':', value: ''},
projectAcreage: { label: '工程面积:', value: '', unit: '' },
constructionUnit: { label: '建设单位:', value: ''},
@ -75,12 +76,15 @@ export default {
}
},
created() {
this.projectSn=localStorage.getItem('sn')
},
mounted(){
this.getList()
},
methods: {
/** 查询数据 */
getList() {
listProjectInfo({ projectSn: this.$store.state.projectSn }).then(res => {
listProjectInfo({ projectSn: this.projectSn }).then(res => {
console.log('项目信息: ', res)
const informationForm = this.informationForm
Object.keys(informationForm).forEach(key => {

View File

@ -17,16 +17,18 @@ export default {
components: { Card },
data() {
return {
projectSn:"",
towerNumber:"",
lifterNumber:"",
}
},
mounted() {
this.projectSn=localStorage.getItem('sn')
this.getData()
},
methods: {
getData(){
getDevNumberApi({ projectSn: this.$store.state.projectSn }).then((res)=>{
getDevNumberApi({ projectSn: this.projectSn }).then((res)=>{
if(res.code == 200){
this.towerNumber = res.result.towerNumber
this.lifterNumber = res.result.lifterNumber

View File

@ -41,11 +41,14 @@ export default {
},
}),
created() {
this.projectSn=localStorage.getItem('sn')
},
mounted(){
this.getList()
},
computed: {
...mapState(['projectSn']),
},
// computed: {
// ...mapState(['projectSn']),
// },
methods: {
/** 查询列表 */
getList() {

View File

@ -45,6 +45,7 @@ export default {
components: { Card },
data() {
return {
projectSn:"",
//
leftList: {
a: { label: 'PM2.5', value: 68, unit: 'μg/m³', image: require('../assets/images/command-center/icon-pm25.png') },
@ -74,13 +75,14 @@ export default {
}
},
created() {
this.projectSn=localStorage.getItem('sn')
this.selectDustNoisePageList()
},
methods: {
selectDustNoisePageList(){
let data = {
// deviceId: this.devSn,
projectSn: this.$store.state.projectSn,
projectSn: this.projectSn,
}
getDustNoiseDataApi(data).then(res=>{
console.log('环境监测',res)

View File

@ -21,6 +21,7 @@ export default {
},
data(){
return{
projectSn:"",
projectData: {
constructionStage: 10,
},
@ -32,6 +33,7 @@ export default {
}
},
created(){
this.projectSn=localStorage.getItem('sn')
console.log('this.list',this.list)
this.getDataDateils()
},
@ -40,7 +42,7 @@ export default {
},
methods:{
getDataDateils() {
let data = { projectSn: this.$store.state.projectSn }
let data = { projectSn: this.projectSn }
getProjectDetail(data).then((res) => {
if (res.code == 200) {
console.log('查询进度',res)

View File

@ -46,6 +46,7 @@ export default {
components: { Card },
data(){
return{
projectSn:"",
statisticsCount: {
currentMonthEducationPerson: 0,
projectcount: {
@ -120,13 +121,14 @@ export default {
}
},
created(){
this.projectSn=localStorage.getItem('sn')
this.getWorkerStatisticsCount()
},
methods:{
//
getWorkerStatisticsCount() {
console.log('执行');
getWorkerStatisticsCountApi({ sn: this.$store.state.userInfo.sn }).then((res) => {
getWorkerStatisticsCountApi({ sn: this.projectSn }).then((res) => {
console.log('老区啊拉垃圾啊哈哈',res);
this.statisticsCount = res.result;
});

View File

@ -76,6 +76,7 @@ export default {
};
},
created() {
this.projectSn=localStorage.getItem('sn')
this.getData();
},
watch: {
@ -102,7 +103,7 @@ export default {
},
getData() {
windowDisplayApi({
projectSn: this.$store.state.projectSn,
projectSn: this.projectSn,
typeId: this.typeId,
}).then((res) => {
if(res.code == 200){

View File

@ -77,10 +77,11 @@ export default {
}
},
created() {
this.projectSn=localStorage.getItem('sn')
this.getList()
},
computed: {
...mapState(['projectSn']),
// ...mapState(['projectSn']),
},
methods: {
/** 查询列表 */

View File

@ -67,6 +67,7 @@ export default {
components: { Card, JNestedRingChart },
data() {
return {
projectSn:"",
tab : 2,
show:true,
recordStatus: 2, // 2 5
@ -117,10 +118,12 @@ export default {
],
};
},
created() {},
computed: {
...mapState(["projectSn"]),
created() {
this.projectSn=localStorage.getItem('sn')
},
// computed: {
// ...mapState(["projectSn"]),
// },
mounted() {
this.getQualityProblem();
this.getQuality();

View File

@ -31,7 +31,6 @@
<script>
import Card from "../components/Card.vue";
import { listProjectInfo } from '@/assets/js/api/zhongjianFourth'
export default {
components: { Card },
data(){
@ -50,12 +49,6 @@ export default {
// this.getData();
},
methods:{
// getData(){
// listProjectInfo({projectSn: this.$store.state.projectSn}).then((res)=>{
// console.log('========',res)
// this.list = res.result
// })
// }
}
};
</script>

View File

@ -122,6 +122,7 @@ export default {
components: { vhead },
data() {
return {
projectSn:"",
baseURL:"",
projectNumber:'',
projectName: "",
@ -132,6 +133,7 @@ export default {
};
},
created(){
this.projectSn = localStorage.getItem('sn')
this.baseURL = this.$http.defaults.baseURL
},
mounted() {
@ -151,7 +153,7 @@ export default {
methods: {
getSafeyHatSession(){
let data = {}
data.projectSn = this.$store.state.projectSn
data.projectSn = this.projectSn
getSafeyHatSessionApi(data).then(res=>{
console.log('安全帽跳转',res)
// {
@ -177,7 +179,7 @@ export default {
},
getProjectNumber(){
let data = {
projectSn: this.$store.state.projectSn,
projectSn: this.projectSn,
};
getProjectInfoBySn(data).then((res)=>{
console.log('------------',res.result.projectNumber)
@ -286,7 +288,7 @@ export default {
//
getDataDateils() {
let data = {
projectSn: this.$store.state.projectSn,
projectSn: this.projectSn,
};
getProjectDetail(data).then((res) => {
// console.log(res);

View File

@ -15,6 +15,7 @@ export default {
components: { Card, Process },
data() {
return {
projectSn:"",
list: [
{ endTime: '2022-01-01', subitemProjectName: '基础工程', state: true ,},
// { endTime: '2022-02-14', subitemProjectName: '', state: true, },
@ -25,6 +26,9 @@ export default {
index: 0
}
},
created(){
this.projectSn=localStorage.getItem('sn')
},
mounted() {
const progress = this.$refs.Process;
progress.scrollLeft = 48;
@ -32,7 +36,7 @@ export default {
},
methods:{
getData(){
listProgressOfTheTask({ projectSn: this.$store.state.projectSn ,isNoStart: false}).then(res => {
listProgressOfTheTask({ projectSn: this.projectSn ,isNoStart: false}).then(res => {
// state 0, 1, 2
res.result.forEach((item)=>{
if(item.state == 2){

View File

@ -167,6 +167,8 @@
<el-date-picker
@change="time1"
v-model="workerInfo.startDate"
:picker-options="dateAfter"
type="date"
placeholder="计划开始日期"
value-format="yyyy-MM-dd"
@ -181,6 +183,7 @@
<el-date-picker
@change="time2"
v-model="workerInfo.finishDate"
:picker-options="dateBefore"
type="date"
placeholder="计划完成时间"
value-format="yyyy-MM-dd"
@ -386,8 +389,53 @@ export default {
},
dialogImageUrl: "",
showBigImg: false,
times:'',
//
pickerOptions:{ //
disabledDate: (time) => {
let nowData = this.times
nowData = new Date(nowData.setDate(nowData.getDate() - 1))
return time > nowData
// return time.getTime() < Date.now()- 1 * 24 * 3600 * 1000;
}
},
};
},
computed: {
dateAfter() {
//
const startTimestamp = Date.now() * 1 - 24 * 60 * 60 * 1000;
const endTimestamp =
Date.parse(this.workerInfo.finishDate) * 1 - 24 * 60 * 60 * 1000;
return {
disabledDate(time) {
const timestamp = time.getTime();
if (endTimestamp) {
if (timestamp >= startTimestamp && timestamp <= endTimestamp) {
return false;
} else {
return true;
}
} else {
return timestamp <= startTimestamp;
}
}
};
},
dateBefore() {
//
const startTimestamp = Date.parse(this.workerInfo.startDate) * 1;
return {
disabledDate(time) {
const timestamp = time.getTime();
if (timestamp >= startTimestamp) {
return false;
}
return true;
}
};
}
},
created() {
this.projectSn = this.$store.state.projectSn;
this.createUserId = this.$store.state.userInfo.userId;
@ -398,6 +446,7 @@ export default {
methods: {
time1(val){
console.log('开始时间',val)
this.times = val
},
time2(val){
console.log('结束时间',val)