WeChat Mini Programs: how to achieve voice like Wechat, played to delete the little red dot (online help! )

because the view is rendered in a loop, it doesn"t get it right for a long time

clipboard.png

clipboard.png

use ternary operation to judge the id currently clicked, and then display:none
thought is completely wrong
circular rendering list, all are unified variables
there is no way to modify the attribute
according to id as js does. I really can"t figure it out!

<view class="weike-body-dian" id="{{item.id}}"  style="display:{{ item.id== record[mesgid].id ? record[mesgid].display : "" }}"> <view></view></view>

starts with the data source, and if the temporary array of playlists on the current page is empty, it is read from API and assigned to the temporary array. List binds a temporary array. Change the identification status of the corresponding data in the temporary array after each broadcast.


item cannot add an attribute to identify whether it has been played?


isn't this similar to a shopping cart? click on one and select it. You just click here and make the red dot disappear. You first give each audio a field to determine whether there is a red dot, and then cycle it out. Your this must cycle with the red dot at the same time, so, when you click, change the value of the field you just used to judge, and then re-render it

.
MySQL Query : SELECT * FROM `codeshelper`.`v9_news` WHERE status=99 AND catid='6' ORDER BY rand() LIMIT 5
MySQL Error : Disk full (/tmp/#sql-temptable-64f5-1bc6343-307cc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
MySQL Errno : 1021
Message : Disk full (/tmp/#sql-temptable-64f5-1bc6343-307cc.MAI); waiting for someone to free some space... (errno: 28 "No space left on device")
Need Help?