zoujiandong 75d515fbc6 7.17
2025-07-17 17:15:28 +08:00

1134 lines
38 KiB
JavaScript
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

"use strict";
const common_vendor = require("../../common/vendor.js");
const common_assets = require("../../common/assets.js");
const api_api = require("../../api/api.js");
if (!Array) {
const _easycom_up__image2 = common_vendor.resolveComponent("up--image");
const _easycom_up_input2 = common_vendor.resolveComponent("up-input");
const _easycom_up_icon2 = common_vendor.resolveComponent("up-icon");
const _component_polyv_player = common_vendor.resolveComponent("polyv-player");
const _easycom_up_parse2 = common_vendor.resolveComponent("up-parse");
const _easycom_up_radio2 = common_vendor.resolveComponent("up-radio");
const _easycom_up_radio_group2 = common_vendor.resolveComponent("up-radio-group");
const _easycom_up_image2 = common_vendor.resolveComponent("up-image");
const _easycom_z_paging2 = common_vendor.resolveComponent("z-paging");
const _easycom_up__textarea2 = common_vendor.resolveComponent("up--textarea");
const _easycom_up_upload2 = common_vendor.resolveComponent("up-upload");
const _easycom_up_popup2 = common_vendor.resolveComponent("up-popup");
const _easycom_up_overlay2 = common_vendor.resolveComponent("up-overlay");
(_easycom_up__image2 + _easycom_up_input2 + _easycom_up_icon2 + _component_polyv_player + _easycom_up_parse2 + _easycom_up_radio2 + _easycom_up_radio_group2 + _easycom_up_image2 + _easycom_z_paging2 + _easycom_up__textarea2 + _easycom_up_upload2 + _easycom_up_popup2 + _easycom_up_overlay2)();
}
const _easycom_up__image = () => "../../node-modules/uview-plus/components/u--image/u--image.js";
const _easycom_up_input = () => "../../node-modules/uview-plus/components/u-input/u-input.js";
const _easycom_up_icon = () => "../../node-modules/uview-plus/components/u-icon/u-icon.js";
const _easycom_up_parse = () => "../../node-modules/uview-plus/components/u-parse/u-parse.js";
const _easycom_up_radio = () => "../../node-modules/uview-plus/components/u-radio/u-radio.js";
const _easycom_up_radio_group = () => "../../node-modules/uview-plus/components/u-radio-group/u-radio-group.js";
const _easycom_up_image = () => "../../node-modules/uview-plus/components/u-image/u-image.js";
const _easycom_z_paging = () => "../../uni_modules/z-paging/components/z-paging/z-paging.js";
const _easycom_up__textarea = () => "../../node-modules/uview-plus/components/u--textarea/u--textarea.js";
const _easycom_up_upload = () => "../../node-modules/uview-plus/components/u-upload/u-upload.js";
const _easycom_up_popup = () => "../../node-modules/uview-plus/components/u-popup/u-popup.js";
const _easycom_up_overlay = () => "../../node-modules/uview-plus/components/u-overlay/u-overlay.js";
if (!Math) {
(backNav + _easycom_up__image + _easycom_up_input + _easycom_up_icon + _easycom_up_parse + _easycom_up_radio + _easycom_up_radio_group + _easycom_up_image + _easycom_z_paging + _easycom_up__textarea + _easycom_up_upload + _easycom_up_popup + _easycom_up_overlay)();
}
const backNav = () => "../../components/backNav/backNav.js";
const _sfc_main = {
__name: "detail",
setup(__props) {
const isH5 = common_vendor.ref(false);
const user_id = common_vendor.ref("");
const paging = common_vendor.ref(null);
const dataList = common_vendor.ref([]);
const total = common_vendor.ref(0);
const imgList = common_vendor.ref([]);
const showCanvas = common_vendor.ref(false);
const showCommentDialog = common_vendor.ref(false);
const givePointValue = common_vendor.ref(5);
common_vendor.ref(0);
common_vendor.ref(0);
const showModal = common_vendor.ref(false);
const content = common_vendor.ref("");
const type = common_vendor.ref("");
const info = common_vendor.reactive({});
const showDeal = common_vendor.ref(false);
const showMore = common_vendor.ref(false);
const showGive = common_vendor.ref(false);
const id = common_vendor.ref("");
const parent_id = common_vendor.ref(null);
const root_id = common_vendor.ref(null);
const is_author = common_vendor.ref(false);
const reply_name = common_vendor.ref("");
const level = common_vendor.ref(1);
const placeholder = common_vendor.ref("请输入评论内容");
const mainCommentObj = common_vendor.reactive({});
const childList = common_vendor.ref([]);
const clickIndex = common_vendor.ref(0);
const is_top = common_vendor.ref(false);
const option_id = common_vendor.ref("");
const point = common_vendor.ref(0);
const comment_userId = common_vendor.ref("");
const commentTextarea = common_vendor.ref(null);
const confirmGive = () => {
showGive.value = false;
givePoint();
};
const openGivePop = () => {
showGive.value = true;
getUserPoint();
};
const formatDay = (date) => {
return common_vendor.dayjs(date).format("YYYY-MM-DD");
};
const formatDate = (date) => {
return common_vendor.dayjs(date).format("YYYY-MM-DD HH:mm");
};
const inputPoint = () => {
if (givePointValue.value < 5) {
givePointValue.value = 5;
common_vendor.index.showToast({
icon: "none",
title: "每次打赏范围5~100积分"
});
}
if (givePointValue.value > 100) {
givePointValue.value = 100;
common_vendor.index.showToast({
icon: "none",
title: "每次打赏范围5~100积分"
});
}
};
const changePoint = (type2) => {
if (type2 == "minus") {
if (givePointValue.value > 5) {
givePointValue.value = givePointValue.value - 5;
} else {
common_vendor.index.showToast({
icon: "none",
title: "每次打赏范围5~100积分"
});
}
} else {
if (givePointValue.value <= 95) {
givePointValue.value = givePointValue.value + 5;
} else {
common_vendor.index.showToast({
icon: "none",
title: "每次打赏范围5~100积分"
});
}
}
};
const openMorePop = (obj, list2, index) => {
showMore.value = true;
childList.value = list2;
Object.assign(mainCommentObj, obj);
clickIndex.value = index;
};
const getArticleDetail = (id2) => {
api_api.api.getArticleDetail(id2).then((res) => {
let result = res.data.data;
Object.assign(info, result);
});
};
const getVideoDetail = (id2) => {
api_api.api.getVideoDetail(id2).then((res) => {
let result = res.data.data;
Object.assign(info, result);
});
};
const getExchangeDetail = (id2) => {
api_api.api.getExchangeDetail(id2).then((res) => {
let result = res.data.data;
Object.assign(info, result);
});
};
const getUserPoint = () => {
api_api.api.getUserPoint().then((res) => {
common_vendor.index.__f__("log", "at pages/detail/detail.vue:722", res.data.data);
point.value = res.data.data;
});
};
const givePoint = () => {
if (point.value < givePointValue.value) {
common_vendor.index.showToast({
icon: "none",
title: "积分不足!"
});
return false;
}
let giveType = 1;
if (type.value == "article") {
giveType = 1;
} else if (type.value == "video") {
giveType = 2;
} else {
giveType = 3;
}
api_api.api.givePoint({
id: id.value,
type: giveType,
point: givePointValue.value
}).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "打赏成功!"
});
showGive.value = false;
});
};
common_vendor.onLoad((options) => {
id.value = options.id;
type.value = options.type;
if (type.value == "article") {
getArticleDetail(options.id);
} else if (type.value == "video") {
getVideoDetail(options.id);
} else {
getExchangeDetail(options.id);
}
let userInfo = common_vendor.index.getStorageSync("userInfo");
if (userInfo.user_id) {
user_id.value = userInfo.user_id;
}
readRecord();
});
const clearComment = () => {
parent_id.value = null;
imgList.value = [];
content.value = "";
root_id.value = null;
reply_name.value = "";
level.value = 1;
};
const closeDealPop = () => {
showDeal.value = false;
clearComment();
};
const showReplyPop = () => {
parent_id.value = mainCommentObj.comment_id;
root_id.value = mainCommentObj.comment_id;
is_author.value = mainCommentObj.is_author == 1 ? true : false;
reply_name.value = mainCommentObj.user_name;
level.value = 2;
if (level.value == 2 || level.value == 3) {
placeholder.value = "回复" + reply_name.value + "";
}
showCommentDialog.value = true;
};
const alertDeal = (parentId, rootId, name, top, commentLevel, userId) => {
parent_id.value = parentId;
comment_userId.value = userId;
root_id.value = rootId;
reply_name.value = name;
level.value = commentLevel;
is_top.value = top == 1 ? true : false;
if (level.value == 2 || level.value == 3) {
placeholder.value = "回复" + name + "";
}
showDeal.value = true;
};
const openCommentDialog = () => {
showCommentDialog.value = true;
showDeal.value = false;
};
const queryList = (pageNo, pageSize) => {
const params = {
page: pageNo,
page_size: pageSize
};
if (type.value == "article") {
getArticleComment(params);
} else if (type.value == "video") {
getVideoComment(params);
} else {
getExchangeComment(params);
}
};
const getArticleComment = (params) => {
const form = {
article_id: id.value,
is_have_sub_comment: 1
};
api_api.api.getArticleComment({
...form,
...params
}).then((res) => {
paging.value.complete(res.data.data.data);
total.value = res.data.data.total;
is_author.value = res.data.data.is_author == 1 ? true : false;
setTimeout(() => {
if (showMore.value) {
openMorePop(
mainCommentObj,
dataList.value[clickIndex.value].sub_comment,
clickIndex.value
);
}
}, 1500);
}).catch((res) => {
paging.value.complete(false);
});
};
const getVideoComment = (params) => {
const form = {
video_id: id.value,
is_have_sub_comment: 1
};
api_api.api.getVideoComment({
...form,
...params
}).then((res) => {
paging.value.complete(res.data.data.data);
total.value = res.data.data.total;
is_author.value = res.data.data.is_author == 1 ? true : false;
setTimeout(() => {
if (showMore.value) {
openMorePop(
mainCommentObj,
dataList.value[clickIndex.value].sub_comment,
clickIndex.value
);
}
}, 1500);
}).catch((res) => {
paging.value.complete(false);
});
};
const getExchangeComment = (params) => {
const form = {
exchange_id: id.value,
is_have_sub_comment: 1
};
api_api.api.getExchangeComment({
...form,
...params
}).then((res) => {
paging.value.complete(res.data.data.data);
total.value = res.data.data.total;
is_author.value = res.data.data.is_author == 1 ? true : false;
setTimeout(() => {
if (showMore.value) {
openMorePop(
mainCommentObj,
dataList.value[clickIndex.value].sub_comment,
clickIndex.value
);
}
}, 1500);
}).catch((res) => {
paging.value.complete(false);
});
};
const open = () => {
showCommentDialog.value = true;
};
const close = () => {
showCommentDialog.value = false;
common_vendor.index.__f__("log", "at pages/detail/detail.vue:920", "close");
};
const openDeal = () => {
showDeal.value = true;
common_vendor.index.__f__("log", "at pages/detail/detail.vue:925", "open");
};
const closeDeal = () => {
showDeal.value = false;
};
const openMore = () => {
showMore.value = true;
common_vendor.index.__f__("log", "at pages/detail/detail.vue:933", "open");
};
const closeMore = () => {
showMore.value = false;
};
const previewImg = (url) => {
common_vendor.index.previewImage({
current: url,
urls: [url]
});
};
const handleUpload = (file) => {
let File2 = file.file;
api_api.api.getOss({
scene: 1
}).then((rep) => {
let result = rep.data;
if (result.code == 200) {
let { access_id, dir, policy, signature, host } = result.data;
let time = common_vendor.dayjs().format("YYYYMMDDHHmmss");
let random = generateRandomNumber();
let filename = time + random;
let imgType = "." + getImageFormat(File2[0].url);
return new Promise((resolve, reject) => {
common_vendor.index.uploadFile({
url: host,
// 仅为示例,非真实的接口地址
filePath: File2[0].url,
name: "file",
formData: {
OSSAccessKeyId: access_id,
policy,
key: dir + time + random + imgType,
signature
},
success(res) {
if (res.statusCode === 204) {
let url = host + "/" + dir + filename + imgType;
common_vendor.index.__f__("log", "at pages/detail/detail.vue:1284", url);
imgList.value = [url];
}
},
fail: (err) => {
common_vendor.index.__f__("log", "at pages/detail/detail.vue:1289", err);
}
});
});
}
});
};
const generateRandomNumber = () => {
let randomNumber = Math.floor(1e3 + Math.random() * 9e3);
return randomNumber;
};
const getImageFormat = (imageUrl) => {
const lastDotIndex = imageUrl.lastIndexOf(".");
if (lastDotIndex !== -1) {
return imageUrl.substring(lastDotIndex + 1);
}
return "unknown";
};
const afterRead = (file, lists, name) => {
common_vendor.index.__f__("log", "at pages/detail/detail.vue:1308", lists);
common_vendor.index.__f__("log", "at pages/detail/detail.vue:1309", name);
handleUpload(file);
};
const delImg = (index) => {
imgList.value = [];
};
const collectArticle = (id2) => {
api_api.api.collectArticle(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "收藏成功"
});
getArticleDetail(id2);
});
};
const collectVideo = (id2) => {
api_api.api.collectVideo(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "收藏成功"
});
getVideoDetail(id2);
});
};
const collectExchange = (id2) => {
api_api.api.collectExchange(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "收藏成功"
});
getExchangeDetail(id2);
});
};
const cancelCollectArticle = (id2) => {
api_api.api.cancelCollectArticle(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "已取消收藏"
});
getArticleDetail(id2);
});
};
const cancelCollectVideo = (id2) => {
api_api.api.cancelCollectVideo(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "已取消收藏"
});
getVideoDetail(id2);
});
};
const cancelCollectExchange = (id2) => {
api_api.api.cancelCollectExchange(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "已取消收藏"
});
getExchangeDetail(id2);
});
};
const toggleCollect = () => {
if (type.value == "video") {
info.is_collect ? cancelCollectVideo(id.value) : collectVideo(id.value);
} else if (type.value == "article") {
info.is_collect ? cancelCollectArticle(id.value) : collectArticle(id.value);
} else {
info.is_collect ? cancelCollectExchange(id.value) : collectExchange(id.value);
}
};
const addArticleComment = (id2, data) => {
api_api.api.addArticleComment(id2, data).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "评论成功"
});
clearComment();
showCommentDialog.value = false;
paging.value.refresh();
});
};
const addVideoComment = (id2, data) => {
api_api.api.addVideoComment(id2, data).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "评论成功"
});
clearComment();
showCommentDialog.value = false;
paging.value.refresh();
});
};
const addExchangeComment = (id2, data) => {
api_api.api.addExchangeComment(id2, data).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "评论成功"
});
clearComment();
showCommentDialog.value = false;
paging.value.refresh();
});
};
const delArticleComment = (id2) => {
api_api.api.delArticleComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "删除成功"
});
paging.value.refresh();
});
};
const delVideoComment = (id2) => {
api_api.api.delVideoComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "删除成功"
});
paging.value.refresh();
});
};
const fromatImg = (val) => {
if (val) {
return val.replace(/\<img|\<\s+img/gi, '<img class="imgstyle"');
} else {
return "";
}
};
const delExchangeComment = (id2) => {
api_api.api.delExchangeComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "删除成功"
});
paging.value.refresh();
});
};
const topArticleComment = (id2) => {
api_api.api.topArticleComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const topVideoComment = (id2) => {
api_api.api.topVideoComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const topExchangeComment = (id2) => {
api_api.api.topExchangeComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const cancelTopArticleComment = (id2) => {
api_api.api.cancelTopArticleComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "取消置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const cancelTopVideoComment = (id2) => {
api_api.api.cancelTopArticleComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "取消置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const cancelTopExchangeComment = (id2) => {
api_api.api.cancelTopExchangeComment(id2).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "取消置顶成功"
});
showDeal.value = false;
paging.value.refresh();
});
};
const delComment = () => {
showModal.value = true;
showDeal.value = false;
};
const confirmDel = () => {
if (type.value == "article") {
delArticleComment(parent_id.value);
} else if (type.value == "video") {
delVideoComment(parent_id.value);
} else {
delExchangeComment(parent_id.value);
}
showModal.value = false;
};
const toggleTop = () => {
if (type.value == "article") {
is_top.value ? cancelTopArticleComment(parent_id.value) : topArticleComment(parent_id.value);
} else if (type.value == "video") {
is_top.value ? cancelTopVideoComment(parent_id.value) : topVideoComment(parent_id.value);
} else {
is_top.value ? cancelTopExchangeComment(parent_id.value) : topExchangeComment(parent_id.value);
}
};
const sendComment = () => {
if (!content.value) {
common_vendor.index.showToast({
icon: "none",
title: "请输入评论内容"
});
return false;
}
const postData = {
content: level.value == 3 ? "回复" + reply_name.value + "" + content.value : content.value
};
if (imgList.value.length > 0) {
postData.comment_image = imgList.value[0];
}
if (parent_id.value !== null) {
postData.parent_id = parent_id.value;
}
if (root_id.value !== null) {
postData.root_id = root_id.value;
}
if (type.value == "article") {
addArticleComment(id.value, postData);
} else if (type.value == "video") {
addVideoComment(id.value, postData);
} else {
addExchangeComment(id.value, postData);
}
};
const formatHtml = (val) => {
if (/^回复.+/.test(val)) {
return val.replace(
/[^回复]([^]+)/,
`<font style="color:#3CC7C0">$&</font>`
);
}
return val;
};
const addVote = () => {
if (!option_id.value) {
common_vendor.index.showToast({
icon: "none",
title: "请选择投票选项!"
});
return false;
}
api_api.api.addVote(id.value, {
option_id: option_id.value
}).then((res) => {
common_vendor.index.showToast({
icon: "none",
title: "投票成功!"
});
getExchangeDetail(id.value);
});
};
const readRecord = () => {
let flag = 1;
if (type.value == "article") {
flag = 1;
} else if (type.value == "video") {
flag = 1;
} else {
flag = 3;
}
api_api.api.readRecord({
type: flag,
id: id.value
}).then((res) => {
});
};
return (_ctx, _cache) => {
return common_vendor.e({
a: common_vendor.p({
navName: "肝胆相照临床病例库"
}),
b: common_vendor.p({
src: common_vendor.unref(common_assets.chatImg),
width: "46rpx",
height: "46rpx",
radius: "50%"
}),
c: common_vendor.o(open),
d: common_vendor.p({
disabled: true,
focus: false,
type: "text",
placeholderClass: "placeholderClass",
placeholder: "对病例发表您的看法"
}),
e: common_vendor.o(open),
f: common_vendor.o(open),
g: common_vendor.o(toggleCollect),
h: common_vendor.p({
src: info.is_collect ? common_vendor.unref(common_assets.collectonImg) : common_vendor.unref(common_assets.collectImg),
width: "38rpx",
height: "38rpx"
}),
i: common_vendor.p({
src: common_vendor.unref(common_assets.shangImg),
mode: "widthFix",
width: "169rpx",
height: "77rpx"
}),
j: common_vendor.o(openGivePop),
k: type.value == "video"
}, type.value == "video" ? {
l: common_vendor.t(info.video_title)
} : type.value == "article" ? {
n: common_vendor.t(info.article_title)
} : {
o: common_vendor.t(info.exchange_title)
}, {
m: type.value == "article",
p: common_vendor.f(info.author, (item, k0, i0) => {
return {
a: "eca06f3c-6-" + i0 + ",eca06f3c-0",
b: common_vendor.t(item.doctor_name),
c: common_vendor.t(item.hospital_name)
};
}),
q: common_vendor.p({
src: common_vendor.unref(common_assets.headImg),
mode: "widthFix",
width: "46rpx",
height: "46rpx",
radius: "50%"
}),
r: common_vendor.p({
name: "eye",
color: "#6B7280",
size: "28rpx"
}),
s: common_vendor.t(info.read_num),
t: common_vendor.p({
name: info.is_collect ? "heart-fill" : "heart",
color: info.is_collect ? "red" : "#6B7280",
size: "28rpx"
}),
v: common_vendor.t(info.collect_num),
w: common_vendor.p({
name: "clock",
color: "#6B7280",
size: "28rpx"
}),
x: common_vendor.t(formatDay(info.push_date)),
y: showCanvas.value
}, showCanvas.value ? {} : {}, {
z: type.value == "video" && !isH5.value
}, type.value == "video" && !isH5.value ? {
A: "playerContext" + info.video_no,
B: "playerId" + info.video_no,
C: info.video_no
} : {}, {
D: type.value == "video" && isH5.value
}, type.value == "video" && isH5.value ? {} : type.value == "article" ? {
F: common_vendor.p({
content: fromatImg(info.article_content)
})
} : common_vendor.e({
G: info.exchange_content
}, info.exchange_content ? {
H: common_vendor.p({
content: fromatImg(info.exchange_content)
})
} : {}, {
I: info.exchange_summary
}, info.exchange_summary ? {
J: common_vendor.p({
content: fromatImg(info.exchange_summary)
})
} : {}, {
K: info.case_exchange_vote && info.case_exchange_vote.vote_title
}, info.case_exchange_vote && info.case_exchange_vote.vote_title ? common_vendor.e({
L: info.case_exchange_vote.is_have_voted != 1
}, info.case_exchange_vote.is_have_voted != 1 ? {
M: common_vendor.t(info.case_exchange_vote.vote_title),
N: common_vendor.f(info.case_exchange_vote.case_exchange_vote_option, (item, k0, i0) => {
return {
a: "eca06f3c-15-" + i0 + ",eca06f3c-14",
b: common_vendor.p({
activeColor: "#3CC7C0",
label: item.option_value,
name: item.option_id
}),
c: item.option_id
};
}),
O: common_vendor.o(($event) => option_id.value = $event),
P: common_vendor.p({
placement: "column",
modelValue: option_id.value
}),
Q: common_vendor.o(addVote)
} : {
R: common_vendor.t(info.case_exchange_vote.vote_title),
S: common_vendor.f(info.case_exchange_vote.case_exchange_vote_option, (item, k0, i0) => {
return {
a: common_vendor.t(item.option_value),
b: common_vendor.t(item.proportion),
c: item.option_id
};
}),
T: _ctx.proportion / 100
}) : {}), {
E: type.value == "article",
U: common_vendor.p({
src: common_vendor.unref(common_assets.commentImg),
mode: "widthFix",
width: "50rpx",
height: "50rpx"
}),
V: common_vendor.t(total.value),
W: common_vendor.f(dataList.value, (item, index, i0) => {
return common_vendor.e({
a: "eca06f3c-17-" + i0 + ",eca06f3c-0",
b: common_vendor.t(item.user_name),
c: user_id.value == item.user_id
}, user_id.value == item.user_id ? {
d: "eca06f3c-18-" + i0 + ",eca06f3c-0",
e: common_vendor.p({
src: common_vendor.unref(common_assets.selfImg),
width: "69rpx",
height: "31rpx"
})
} : {}, {
f: common_vendor.o(($event) => alertDeal(item.comment_id, item.comment_id, item.user_name, item.is_top, 2, item.user_id), item.comment_id),
g: common_vendor.t(item.content),
h: item.comment_image
}, item.comment_image ? {
i: common_vendor.o(($event) => previewImg(item.comment_image), item.comment_id),
j: "eca06f3c-19-" + i0 + ",eca06f3c-0",
k: common_vendor.p({
src: item.comment_image,
radius: "16rpx",
width: "150rpx",
height: "150rpx"
})
} : {}, {
l: common_vendor.t(formatDate(item.created_at)),
m: item.sub_comment && item.sub_comment.length > 0
}, item.sub_comment && item.sub_comment.length > 0 ? {
n: common_vendor.f(item.sub_comment.slice(0, 3), (cell, index2, i1) => {
return common_vendor.e({
a: "eca06f3c-20-" + i0 + "-" + i1 + ",eca06f3c-0",
b: common_vendor.t(cell.user_name),
c: user_id.value == cell.user_id
}, user_id.value == cell.user_id ? {
d: "eca06f3c-21-" + i0 + "-" + i1 + ",eca06f3c-0",
e: common_vendor.p({
src: common_vendor.unref(common_assets.selfImg),
width: "69rpx",
height: "31rpx"
})
} : {}, {
f: common_vendor.o(($event) => alertDeal(cell.comment_id, cell.root_id, cell.user_name, cell.is_top, 3, cell.user_id), cell.comment_id),
g: formatHtml(cell.content),
h: cell.comment_image
}, cell.comment_image ? {
i: common_vendor.o(($event) => previewImg(cell.comment_image), cell.comment_id),
j: "eca06f3c-22-" + i0 + "-" + i1 + ",eca06f3c-0",
k: common_vendor.p({
src: cell.comment_image,
radius: "16rpx",
width: "150rpx",
height: "150rpx"
})
} : {}, {
l: common_vendor.t(formatDate(cell.created_at)),
m: cell.comment_id
});
}),
o: common_vendor.p({
src: common_vendor.unref(common_assets.headImg),
width: "86rpx",
height: "86rpx",
radius: "50%"
})
} : {}, {
p: item.sub_comment.length > 3
}, item.sub_comment.length > 3 ? {
q: common_vendor.o(($event) => openMorePop(item, item.sub_comment, index), item.comment_id)
} : {}, {
r: item.comment_id
});
}),
X: common_vendor.p({
src: common_vendor.unref(common_assets.headImg),
width: "86rpx",
height: "86rpx",
radius: "50%"
}),
Y: common_vendor.sr(paging, "eca06f3c-0", {
"k": "paging"
}),
Z: common_vendor.o(queryList),
aa: common_vendor.o(($event) => dataList.value = $event),
ab: common_vendor.p({
["inside-more"]: true,
["loading-more-no-more-text"]: "咱也是有底线的!",
["auto-show-back-to-top"]: false,
["empty-view-super-style"]: {
"paddingBottom": "140rpx"
},
["refresher-title-style"]: {
"paddingBottom": "60rpx",
"paddingTop": "10rpx"
},
["refresher-img-style"]: {
"paddingBottom": "60rpx",
"paddingTop": "10rpx"
},
modelValue: dataList.value
}),
ac: common_vendor.sr(commentTextarea, "eca06f3c-24,eca06f3c-23", {
"k": "commentTextarea"
}),
ad: common_vendor.o(($event) => content.value = $event),
ae: common_vendor.p({
focus: false,
height: "200",
placeholder: placeholder.value,
modelValue: content.value
}),
af: imgList.value.length > 0
}, imgList.value.length > 0 ? {
ag: common_vendor.o(($event) => previewImg(imgList.value[0])),
ah: common_vendor.p({
src: imgList.value[0],
radius: "6",
width: "150rpx",
height: "150rpx"
}),
ai: common_vendor.p({
name: "close-circle",
color: "#666",
size: "16"
}),
aj: common_vendor.o(delImg)
} : {}, {
ak: common_vendor.p({
src: common_vendor.unref(common_assets.uploadImg),
mode: "widthFix",
width: "40rpx",
height: "77rpx"
}),
al: common_vendor.o(afterRead),
am: common_vendor.p({
["show-upload-list"]: false,
name: "imgupload",
multiple: true,
maxCount: 1,
width: "40rpx",
height: "77rpx"
}),
an: common_vendor.o(sendComment),
ao: common_vendor.o(close),
ap: common_vendor.o(open),
aq: common_vendor.p({
zIndex: 99,
overlayStyle: {
zIndex: 98
},
closeOnClickOverlay: false,
show: showCommentDialog.value,
round: 10,
closeable: true,
mode: "bottom"
}),
ar: level.value == 2 && is_author.value
}, level.value == 2 && is_author.value ? {
as: common_vendor.t(is_top.value ? "取消置顶" : "置顶"),
at: common_vendor.o(toggleTop)
} : {}, {
av: common_vendor.o(openCommentDialog),
aw: is_author.value || user_id.value == comment_userId.value
}, is_author.value || user_id.value == comment_userId.value ? {
ax: common_vendor.o(delComment)
} : {}, {
ay: common_vendor.o(closeDealPop),
az: common_vendor.o(closeDeal),
aA: common_vendor.o(openDeal),
aB: common_vendor.p({
zIndex: 60,
overlayStyle: {
zIndex: 59
},
closeOnClickOverlay: false,
show: showDeal.value,
round: 10,
mode: "bottom"
}),
aC: common_vendor.p({
name: "close",
color: "#666",
size: "20"
}),
aD: common_vendor.o(closeMore),
aE: common_vendor.p({
src: common_vendor.unref(common_assets.headImg),
width: "86rpx",
height: "86rpx",
radius: "50%"
}),
aF: common_vendor.t(mainCommentObj.user_name),
aG: user_id.value == mainCommentObj.user_id
}, user_id.value == mainCommentObj.user_id ? {
aH: common_vendor.p({
src: common_vendor.unref(common_assets.selfImg),
width: "69rpx",
height: "31rpx"
})
} : {}, {
aI: common_vendor.o(($event) => alertDeal(mainCommentObj.comment_id, mainCommentObj.comment_id, mainCommentObj.user_name, mainCommentObj.is_top, 2, mainCommentObj.user_id)),
aJ: common_vendor.t(mainCommentObj.content),
aK: mainCommentObj.comment_image
}, mainCommentObj.comment_image ? {
aL: common_vendor.o(($event) => previewImg(mainCommentObj.comment_image)),
aM: common_vendor.p({
src: mainCommentObj.comment_image,
radius: "16rpx",
width: "150rpx",
height: "150rpx"
})
} : {}, {
aN: common_vendor.t(formatDate(mainCommentObj.created_at)),
aO: common_vendor.f(childList.value, (cell, index, i0) => {
return common_vendor.e({
a: "eca06f3c-35-" + i0 + ",eca06f3c-30",
b: common_vendor.t(cell.user_name),
c: user_id.value == cell.user_id
}, user_id.value == cell.user_id ? {
d: "eca06f3c-36-" + i0 + ",eca06f3c-30",
e: common_vendor.p({
src: common_vendor.unref(common_assets.selfImg),
width: "69rpx",
height: "31rpx"
})
} : {}, {
f: common_vendor.o(($event) => alertDeal(cell.comment_id, cell.root_id, cell.user_name, cell.is_top, 3, cell.user_id), cell.comment_id),
g: formatHtml(cell.content),
h: cell.comment_image
}, cell.comment_image ? {
i: common_vendor.o(($event) => previewImg(cell.comment_image), cell.comment_id),
j: "eca06f3c-37-" + i0 + ",eca06f3c-30",
k: common_vendor.p({
src: cell.comment_image,
radius: "16rpx",
width: "150rpx",
height: "150rpx"
})
} : {}, {
l: common_vendor.t(formatDate(cell.created_at)),
m: cell.comment_id
});
}),
aP: common_vendor.p({
src: common_vendor.unref(common_assets.headImg),
width: "86rpx",
height: "86rpx",
radius: "50%"
}),
aQ: common_vendor.o(($event) => _ctx.value = $event),
aR: common_vendor.p({
readonly: true,
placeholder: "@" + mainCommentObj.user_name + "",
border: "surround",
modelValue: _ctx.value
}),
aS: common_vendor.o(showReplyPop),
aT: common_vendor.o(closeMore),
aU: common_vendor.o(openMore),
aV: common_vendor.p({
zIndex: 10,
overlayStyle: {
zIndex: 9
},
closeOnClickOverlay: false,
show: showMore.value,
round: 10,
mode: "bottom"
}),
aW: common_vendor.t(point.value),
aX: common_vendor.o(($event) => changePoint("minus")),
aY: common_vendor.o(inputPoint),
aZ: common_vendor.o(($event) => givePointValue.value = $event),
ba: common_vendor.p({
placeholder: "请输入打赏积分",
type: "number",
border: "surround",
modelValue: givePointValue.value
}),
bb: common_vendor.o(($event) => changePoint("add")),
bc: common_vendor.o(($event) => showGive.value = false),
bd: common_vendor.o(confirmGive),
be: common_vendor.p({
show: showGive.value,
["mask-click-able"]: true
}),
bf: common_vendor.o(($event) => showModal.value = false),
bg: common_vendor.o(confirmDel),
bh: common_vendor.p({
show: showModal.value,
["mask-click-able"]: true
})
});
};
}
};
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-eca06f3c"]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/detail/detail.js.map