Commit 562e8008 authored by 石盼盼's avatar 石盼盼

查看评价页面+接口

parent 681e8318
......@@ -33,4 +33,8 @@
height: 1px;
background: #F1F1F1;
margin-bottom: 0.4rem;
}
.content{
color: #727272;
font-size: 0.3rem;
}
\ No newline at end of file
......@@ -101,8 +101,18 @@
background: #f1f1f1;
margin-bottom: 0.4rem;
}
.tc_line{
width: 100%;
height: 0.01rem;
background: #f1f1f1;
margin: 0 auto 0.4rem;
}
.ma-item {
margin-top: 0.3rem;
// margin-top: 0.3rem;
height: 0.6rem;
}
.bz-title{
margin-bottom: 0.2rem;
}
.one {
color: #727272;
......@@ -112,6 +122,9 @@
margin-left: 0.3rem;
margin-right: 0.3rem;
}
.btn{
margin-top: 0.2rem;
}
.btn-item {
width: 1.8rem;
height: 0.7rem;
......@@ -210,6 +223,7 @@
color: #000000;
font-size: 0.26rem;
margin-left: 0.3rem;
margin-top: 0.4rem;
}
.sure-btn {
width: 3.12rem;
......
......@@ -19,6 +19,7 @@
<div class="line"></div>
<div class="comments">
<div class="title">评价内容</div>
<div class="content">{{comment.content}}</div>
</div>
</div>
</div>
......@@ -28,18 +29,42 @@
export default {
data(){
return{
totalStar: 4,
speedStar: 2,
qualityStar: 3,
attitudeStar: 1,
totalStar: '',
speedStar: '',
qualityStar: '',
attitudeStar: '',
repair_order_id: '',
comment: '',
}
},
created () {
console.log('接收的id啊',this.$route.query.id);
this.repair_order_id = this.$route.query.id
this.look_comment()
// this.getStatus()
},
methods: {
onChange(event) {
this.setData({
value: event.detail,
});
},
// 查看评论
look_comment (item) {
const curParams = {
repair_order_id: this.repair_order_id
}
this.$http
.get(this.$myApi.REPAIR_APPRAISAL, curParams)
.then((data) => {
this.comment = data
this.speedStar = data.speed_stars
this.qualityStar = data.quality_stars
this.attitudeStar = data.attitude_stars
this.totalStar = data.stars
})
.catch(() => {})
},
}
}
</script>
......
......@@ -2,7 +2,7 @@
<div class="cont">
<div class="top flex-h flex-vc">
<div class="point"></div>
<div class="status">工作中</div>
<div class="status">{{user.online_status_display}}</div>
</div>
<div class="menu flex-h flex-hb">
<div class="hc_total">{{count}}个工单</div>
......@@ -69,6 +69,14 @@
</div>
</div>
<div class="line"></div>
<div class="material" v-if="item.free_material_order && item.order_status_display !== '已完成'" >
<div class="item-title bz-title">备注耗材</div>
<div class="ma-item flex-h flex-hb" v-for="(child, index) in item.free_material_order.goods" :key="index">
<div class="one">免费</div>
<div class="one">{{child.goods_name}}*{{child.number}}</div>
<div class="one">¥0</div>
</div>
</div>
<div class="btn flex-h flex-hr">
<div v-if="item.is_can_remark_material==1" class="btn-item bz-btn" @click="bz_click(item)" >备注耗材</div>
<div
......@@ -139,6 +147,7 @@
<!-- 查看耗材弹窗 -->
<van-popup v-model="lookShow" close-icon="close">
<div class="pop_title">查看耗材</div>
<div class="tc_line"></div>
<div class="ma-item one-item flex-h flex-hb" v-for="(item, index) in expend_detail.list" :key="index">
<div class="one">{{item.parent_detail ? item.parent_detail.goods_name : '其它'}}</div>
<div class="one">{{item.goods_name}}*{{item.number}}</div>
......@@ -195,12 +204,13 @@ export default {
], // 添加的备注耗材数据
hcShow: false, // 耗材弹窗
lookShow: false, // 查看耗材弹窗
expend_detail: {} // 耗材详情
expend_detail: {},// 耗材详情
user: '',
}
},
created () {
this.getList()
// this.getStatus()
this.getUserInfo()
},
methods: {
// 初始化
......@@ -220,6 +230,14 @@ export default {
})
.catch(() => {})
},
getUserInfo () {
this.$http
.get(this.$myApi.USERINFO)
.then((res) => {
this.user = res
})
.catch(() => {})
},
// 获取工单列表
getList () {
if (this.more && !this.isloading) {
......@@ -385,6 +403,14 @@ export default {
.catch(() => {})
},
// 查看评论
look_comment (item) {
this.$router.push({
name: 'lookEvaluate',
query: {
id: item.id
}
})
},
// look_comment (item) {
// const curParams = {
// repair_order_id: item.id
......
......@@ -11,7 +11,7 @@
alt
/>
</div>
<div class="btn">工作中</div>
<div class="btn">{{user.online_status_display}}</div>
<div class="name">{{user.name}}</div>
<div class="group">{{user.department.name}}</div>
<div class="tel flex-h">
......
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