update
This commit is contained in:
@@ -113,7 +113,7 @@
|
||||
<a class="dropdown-item" href="javascript:void(0);" onclick="mind.share_mind(${item.id})">分享</a>`
|
||||
} else if (src_page === 'share') {
|
||||
sub_btn = `<a class="dropdown-item" href="javascript:void(0);" onclick="mind.share_cancel(${item.id})">取消分享</a>
|
||||
<a class="dropdown-item" href="javascript:void(0);" onclick="">查看分享链接</a>`
|
||||
<a class="dropdown-item" href="javascript:void(0);" onclick="mind.fetch_share_info(${item.id})">查看分享链接</a>`
|
||||
}
|
||||
|
||||
const content = `<div class="card col-2" style="margin: 6px; margin-left: 20px;" id='card_${uuid}'>
|
||||
@@ -230,6 +230,26 @@
|
||||
async: false
|
||||
});
|
||||
},
|
||||
/**获得分享信息*/
|
||||
fetch_share_info: function (mind_id) {
|
||||
const me = this
|
||||
$.ajax({
|
||||
type: "get",
|
||||
url: "share",
|
||||
headers: {"X-CSRFToken": $.cookie("csrftoken")},
|
||||
data: {'coop_mind_id': mind_id},
|
||||
dataType: "json",
|
||||
success: function (resp) {
|
||||
if (me.is_success_resp(resp)) {
|
||||
const data = resp.data
|
||||
me.show_share_url(data.share_uuid, data.share_uuid_hash)
|
||||
} else {
|
||||
common_alert(resp.msg)
|
||||
}
|
||||
},
|
||||
async: false
|
||||
});
|
||||
},
|
||||
is_success_resp(resp) {
|
||||
return resp.code === 0
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user