|
@@ -173,7 +173,7 @@ class Index extends Component {
|
|
|
}
|
|
|
return (
|
|
|
<View className="sl-item" key={index}>
|
|
|
- <Navigator url={`/pagesQa/msg/chat?to_user_id=${item.to_user_id}`} className="sl-wrap">
|
|
|
+ <Navigator url={`/pagesQa/msg/chat?to_user_id=${item.to_user_id}`} className="sl-wrap" onLongPress={this.longPressItem.bind(this, item)}>
|
|
|
<View className="sl-img">
|
|
|
<Image className="img" src={item.avatar}></Image>
|
|
|
</View>
|
|
@@ -239,6 +239,17 @@ class Index extends Component {
|
|
|
}
|
|
|
|
|
|
|
|
|
+ longPressItem (item) {
|
|
|
+ Taro.$msgConfirm(`确定删除${item.nickname}这个客户吗?`, () => {
|
|
|
+ Taro.api.room.apiuserdialogdel({
|
|
|
+ id: item.id,
|
|
|
+ }).then(res => {
|
|
|
+ Taro.$msg('删除成功')
|
|
|
+ this.getDataList()
|
|
|
+ })
|
|
|
+ })
|
|
|
+ }
|
|
|
+
|
|
|
linkHouseDtl () {
|
|
|
const { curObj } = this.state
|
|
|
Taro.navigateTo({
|