文件路径: src/views/order/list/index.vue
用户信息这里修改成下面得代码:
<user-details
ref="userDetails"
:drawer="userDawer"
@closeDrawer="closeDrawer"
@changeDrawer="changeDrawer"
:uid="uid"
:isUser="false" />
data里面加上userDrawer:false
修改onUserDetails,closeDrawer,changeDrawer函数:
// 用户信息
onUserDetails(uid) {
this.uid = uid
this.userDawer = true
this.$refs.userDetails.getData(uid);
},
closeDrawer() {
this.drawer = false
this.userDawer = false
},
changeDrawer(v) {
this.drawer = v;
this.userDawer = v;
},
文件路径: src/views/user/list/userDetails.vue
添加props中添加isUser
isUser: {
type: Boolean,
default: false,
}
操作按钮这里添加判断