晚会工作人员
1.如果想显示输入vv号展示头像和昵称可以用以下方法:
显示vv号 回车显示昵称头像<body>
<label style="margin-left:20px;">用户ID: </label>
<span @blur="getUserInfo()" v-if="modifyModal.type == 2">{{editParams.userid}}</span>
<Input v-if="modifyModal.type == 1" style="width:120px;" v-model="editParams.userid" @blur="getUserInfo()" @keyup.enter.native="getUserInfo()"></Input>
:@keyup.enter.native=""(回车或者点击)
显示昵称:
<label style="margin-left:20px;">昵称: </label>
<span style="margin-left:14px;">{{editParams.nickname}}</span>
显示照片:
<label style="margin-left:20px;">用户照片:</label></br>
<img :src="(editParams.photo)" style="width:80px;height:80px;" class="img_image">
<a :href="editParams.photo" class="http_a" download='' target="_blank"> <Button type="warning" >下载图片</Button></a>
a标签链接 下载图片
js相应的地方传参数
2.传分页参数的时候要根据后台返回的传
this.totalSize = data.total || 0;
3.(新增显示用户头像以后上传裁剪图片不显示裁剪图像或者是编辑不显示裁剪头像,还有就是新增不显示用户头像只有添加裁剪头像以后才能显示裁剪后的头像)这是遇到的一个坑
if (cutImg.dom_shade_img.src == location.href && !this.editParams.photo) {
this.$Message.success('请添加照片');
return
}
if (this.editParams.photo && cutImg.dom_shade_img.src == location.href) {
this.submitData(this.editParams.photo, 1)
return
}
传参数的时候传裁剪后的图片或者是头像
photo: type == 1 ? this.editParams.photo : ('https://'+photo),
type == 1是我加了个区分 新增编辑的确定用1或2判断
<Button type="success" @click="modifySure" v-if="modifyModal&&modifyModal.type == 1">保存</Button>
<Button type="success" @click="modifySure" v-if="modifyModal&&modifyModal.type == 2">确定</Button>
4.裁剪头像的写法在晚会工作人员里
专区活动
1.把俩个跳转页面的共同table写在了一起(因为内容是一样的)
<div class="form_zuhud" v-if="recommendFlag||modifyModal">
<Table :stripe="false" border align="center" >
<thead>
<tr>
<th>专区</th>
<th>活动</th>
</tr>
</thead>
<tbody>
<tr>
<td>{{parentStractName}}</td>
<td>{{title}}</td>
</tr>
</tbody>
</Table>
</div>
-
添加工作人员的参数传错了 再添加按钮的部分添加然后接口传参用
amend(item){ this.activityid = item.activityid; this.parentStractId = item.parentStractId; this.dataDome(item.activityid,item.parentStractId) },
dataDome给添加接口赋值,(查询已添加的人展示出来),详细看代码
**粗体** _斜体_ [链接](http://example.com) `代码` - 列表 > 引用
。你还可以使用@
来通知其他用户。