mirror of
http://112.124.100.131/GFRS/ebiz-h5.git
synced 2025-12-11 15:36:43 +08:00
img路径拼接
This commit is contained in:
@@ -40,4 +40,12 @@ export function getBaseAgentInfo(data) {
|
|||||||
method: 'post',
|
method: 'post',
|
||||||
data
|
data
|
||||||
})
|
})
|
||||||
|
}
|
||||||
|
//转code
|
||||||
|
export function getCode(data) {
|
||||||
|
return request({
|
||||||
|
url: getUrl(`/agent/Performance/getGroupCodeByName`, 1),
|
||||||
|
method: 'post',
|
||||||
|
data
|
||||||
|
})
|
||||||
}
|
}
|
||||||
@@ -163,7 +163,7 @@ export default {
|
|||||||
parmas.date = this.dateTime
|
parmas.date = this.dateTime
|
||||||
parmas.mask = '1'
|
parmas.mask = '1'
|
||||||
parmas.agentCode=this.list[i].code
|
parmas.agentCode=this.list[i].code
|
||||||
parmas.Name = this.list[i].name
|
parmas.Name = this.list[i].name.split("部")[1]
|
||||||
parmas.buName=this.unitName
|
parmas.buName=this.unitName
|
||||||
localStorage.parmas2 = JSON.stringify(parmas)
|
localStorage.parmas2 = JSON.stringify(parmas)
|
||||||
this.$jump({
|
this.$jump({
|
||||||
|
|||||||
@@ -38,9 +38,13 @@
|
|||||||
v-for="(item, index) in headerList"
|
v-for="(item, index) in headerList"
|
||||||
:key="index"
|
:key="index"
|
||||||
>
|
>
|
||||||
<div @click="(InfoDetails(index))">
|
<div @click="(InfoDetails(index))" class="w40 h60">
|
||||||
<!-- <img v-if="item.agentHeadUrl!==null" class="h40 w40" :src="item.agentHeadUrl" alt /> -->
|
<div style="width:40px; height:42px;border-radius: 20px; margin-top: 2px;margin-left: 2px;" v-if="item.agentHeadUrl!==null">
|
||||||
<img class="h40 w40" src="@/assets/images/u188.png" alt />
|
<img style="width:40px; height:40px;border-radius: 20px" :src="item.agentHeadUrl | urlFormat" alt />
|
||||||
|
</div>
|
||||||
|
<div class="h40 w40" v-else>
|
||||||
|
<img class="h40 w40" src="@/assets/images/u188.png" alt />
|
||||||
|
</div>
|
||||||
<div class="absolute fs12 white captain" v-if="String(item.agentName)==String(Name).split('组')[0] ||String(item.agentName)==String(unitName).split('组')[0]">团队长</div>
|
<div class="absolute fs12 white captain" v-if="String(item.agentName)==String(Name).split('组')[0] ||String(item.agentName)==String(unitName).split('组')[0]">团队长</div>
|
||||||
<div :class="[item.isShowImg?'active':'']"></div>
|
<div :class="[item.isShowImg?'active':'']"></div>
|
||||||
<div class="fs13">{{item.agentName}}</div>
|
<div class="fs13">{{item.agentName}}</div>
|
||||||
@@ -94,9 +98,10 @@
|
|||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
<script>
|
<script>
|
||||||
import { getBaseAgentInfo, getPerformanceHeader, getPerformanceDetail, getHeader } from '@/api/ebiz/performance/performance'
|
import { getBaseAgentInfo, getPerformanceHeader, getPerformanceDetail, getHeader,getCode } from '@/api/ebiz/performance/performance'
|
||||||
import utils from '@/assets/js/utils/date-utils'
|
import utils from '@/assets/js/utils/date-utils'
|
||||||
import { Popup, DatetimePicker } from 'vant'
|
import { Popup, DatetimePicker } from 'vant'
|
||||||
|
import config from '@/config'
|
||||||
export default {
|
export default {
|
||||||
name: 'performance',
|
name: 'performance',
|
||||||
components: {
|
components: {
|
||||||
@@ -136,7 +141,7 @@ export default {
|
|||||||
},
|
},
|
||||||
created() {
|
created() {
|
||||||
// console.log('=======' + this.$route.params.parmas)
|
// console.log('=======' + this.$route.params.parmas)
|
||||||
console.log("+++++++++++"+JSON.parse(window.localStorage.getItem('parmas')))
|
console.log(JSON.parse(window.localStorage.getItem('parmas2')))
|
||||||
if (window.localStorage.getItem('parmas') !== null) {
|
if (window.localStorage.getItem('parmas') !== null) {
|
||||||
this.mask = JSON.parse(window.localStorage.getItem('parmas')).mask
|
this.mask = JSON.parse(window.localStorage.getItem('parmas')).mask
|
||||||
;(this.titleTime = JSON.parse(window.localStorage.getItem('parmas')).date.slice(0, 7)),
|
;(this.titleTime = JSON.parse(window.localStorage.getItem('parmas')).date.slice(0, 7)),
|
||||||
@@ -159,23 +164,24 @@ export default {
|
|||||||
;(this.titleTime = JSON.parse(window.localStorage.getItem('parmas1')).date.slice(0, 7)),
|
;(this.titleTime = JSON.parse(window.localStorage.getItem('parmas1')).date.slice(0, 7)),
|
||||||
(this.dateTime = JSON.parse(window.localStorage.getItem('parmas1')).date),
|
(this.dateTime = JSON.parse(window.localStorage.getItem('parmas1')).date),
|
||||||
(this.unitName = JSON.parse(window.localStorage.getItem('parmas1')).unitName),
|
(this.unitName = JSON.parse(window.localStorage.getItem('parmas1')).unitName),
|
||||||
(this.Name = JSON.parse(window.localStorage.getItem('parmas1')).Name),
|
|
||||||
(this.code = JSON.parse(window.localStorage.getItem('parmas1')).code),
|
(this.code = JSON.parse(window.localStorage.getItem('parmas1')).code),
|
||||||
this.buName=JSON.parse(window.localStorage.getItem('parmas1')).buName
|
this.buName=JSON.parse(window.localStorage.getItem('parmas1')).buName
|
||||||
// window.localStorage.removeItem('parmas1');
|
// window.localStorage.removeItem('parmas1');
|
||||||
}
|
}
|
||||||
|
|
||||||
// this.performanceData()
|
// this.performanceData()
|
||||||
if (this.code == '') {
|
if (JSON.parse(window.localStorage.getItem('obj')).agentGrade.slice(0, 2) == 'A2') {
|
||||||
this.getPerformanceHeader1()
|
this.getPerformanceHeader1()
|
||||||
|
}else{
|
||||||
|
this.getCode1()
|
||||||
}
|
}
|
||||||
if(this.mask=="1"){
|
if(this.mask=="1"){
|
||||||
this.getPerformanceDetailC()
|
// this.getPerformanceDetailC()
|
||||||
}
|
}
|
||||||
this.formatDate1()
|
this.formatDate1()
|
||||||
this.getBaseAgentInfo1()
|
this.getBaseAgentInfo1()
|
||||||
if (this.code !== '') {
|
if (this.code !== '') {
|
||||||
this.getHeader1()
|
// this.getHeader1()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
mounted() {
|
mounted() {
|
||||||
@@ -218,7 +224,7 @@ export default {
|
|||||||
getBaseAgentInfo1() {
|
getBaseAgentInfo1() {
|
||||||
let date = {}
|
let date = {}
|
||||||
getBaseAgentInfo(date).then((res) => {
|
getBaseAgentInfo(date).then((res) => {
|
||||||
console.log(res)
|
// console.log(res)
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
;(this.agentGrade = res.agentGrade),
|
;(this.agentGrade = res.agentGrade),
|
||||||
(this.unitName = res.unitName),
|
(this.unitName = res.unitName),
|
||||||
@@ -251,11 +257,11 @@ export default {
|
|||||||
getPerformanceHeader1() {
|
getPerformanceHeader1() {
|
||||||
let date = {}
|
let date = {}
|
||||||
getPerformanceHeader(date).then((res) => {
|
getPerformanceHeader(date).then((res) => {
|
||||||
console.log('==' + res)
|
// console.log( res)
|
||||||
if (res.result == 0) {
|
if (res.result == 0) {
|
||||||
for (let i = 0; i < res.content.length; i++) {
|
for (let i = 0; i < res.content.length; i++) {
|
||||||
res.content[i].isShowImg = true
|
res.content[i].isShowImg = true
|
||||||
res.content[i].imgUrl=encodeURIComponent(config.imgDomain + '/returnDirectStream?imgPath=' +res.content[i].imgUrl)
|
// res.content[i].agentHeadUrl=encodeURIComponent(config.imgDomain + '/returnDirectStream?imgPath=' +res.content[i].imgUrl)
|
||||||
}
|
}
|
||||||
this.headerList = res.content
|
this.headerList = res.content
|
||||||
console.log(this.headerList)
|
console.log(this.headerList)
|
||||||
@@ -263,7 +269,7 @@ export default {
|
|||||||
})
|
})
|
||||||
},
|
},
|
||||||
getHeader1() {
|
getHeader1() {
|
||||||
console.log(1111)
|
console.log(this.code)
|
||||||
let code = {
|
let code = {
|
||||||
agentgroup: this.code,
|
agentgroup: this.code,
|
||||||
}
|
}
|
||||||
@@ -295,6 +301,20 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
getCode1(){
|
||||||
|
console.log("=========="+this.Name)
|
||||||
|
let code={
|
||||||
|
groupCode:this.Name
|
||||||
|
}
|
||||||
|
getCode(code).then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
if (res.result == 0) {
|
||||||
|
this.code=res.content.groupCode
|
||||||
|
}
|
||||||
|
console.log(this.code)
|
||||||
|
this.getHeader1()
|
||||||
|
})
|
||||||
|
},
|
||||||
//点击头像
|
//点击头像
|
||||||
InfoDetails(item) {
|
InfoDetails(item) {
|
||||||
console.log(item)
|
console.log(item)
|
||||||
@@ -318,6 +338,11 @@ export default {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
},
|
||||||
|
filters: {
|
||||||
|
urlFormat(url) {
|
||||||
|
return (config.imgDomain + `/returnImageStream?a=b.jpg&imgPath=${url}`).replace(/\+/g, '%2B')
|
||||||
|
}
|
||||||
},
|
},
|
||||||
destroyed: function () {
|
destroyed: function () {
|
||||||
console.log("我已经离开了!");
|
console.log("我已经离开了!");
|
||||||
@@ -352,8 +377,8 @@ export default {
|
|||||||
overflow-x: scroll;
|
overflow-x: scroll;
|
||||||
}
|
}
|
||||||
.active {
|
.active {
|
||||||
width: 40px;
|
width: 40px !important;
|
||||||
height: 40px;
|
height: 40px !important;
|
||||||
z-index: 100;
|
z-index: 100;
|
||||||
background: #ccc;
|
background: #ccc;
|
||||||
opacity: 0.5;
|
opacity: 0.5;
|
||||||
|
|||||||
Reference in New Issue
Block a user