This commit is contained in:
zoujiandong
2025-07-30 13:43:14 +08:00
parent 4ca1b9cf42
commit afc79a0f26
405 changed files with 765 additions and 27730 deletions
@@ -1,223 +0,0 @@
"use strict";
const common_vendor = require("../../common/vendor.js");
const api_api = require("../../api/api.js");
const utils_navTo = require("../../utils/navTo.js");
if (!Array) {
const _easycom_up_dropdown_item2 = common_vendor.resolveComponent("up-dropdown-item");
const _easycom_up_dropdown2 = common_vendor.resolveComponent("up-dropdown");
const _easycom_up_icon2 = common_vendor.resolveComponent("up-icon");
const _easycom_z_paging2 = common_vendor.resolveComponent("z-paging");
(_easycom_up_dropdown_item2 + _easycom_up_dropdown2 + _easycom_up_icon2 + _easycom_z_paging2)();
}
const _easycom_up_dropdown_item = () => "../../node-modules/uview-plus/components/u-dropdown-item/u-dropdown-item.js";
const _easycom_up_dropdown = () => "../../node-modules/uview-plus/components/u-dropdown/u-dropdown.js";
const _easycom_up_icon = () => "../../node-modules/uview-plus/components/u-icon/u-icon.js";
const _easycom_z_paging = () => "../../uni_modules/z-paging/components/z-paging/z-paging.js";
if (!Math) {
(navBarSearch + _easycom_up_dropdown_item + _easycom_up_dropdown + _easycom_up_icon + _easycom_z_paging)();
}
const navBarSearch = () => "../../components/navBarSearch/navBarSearch.js";
const _sfc_main = {
__name: "myCollect",
setup(__props) {
const paging = common_vendor.ref(null);
const uDropdownRef = common_vendor.ref(null);
const dataList = common_vendor.ref([]);
const total = common_vendor.ref(0);
common_vendor.ref("");
const keyWord = common_vendor.ref("");
common_vendor.ref(true);
const isSearch = common_vendor.ref(false);
const navName = common_vendor.ref("肝胆相照临床病例库");
const type1 = common_vendor.ref(0);
const type2 = common_vendor.ref(1);
const title2 = common_vendor.ref("文章病例库");
const options = common_vendor.ref([
{
label: "收藏",
value: 0
},
{
label: "浏览",
value: 1
}
]);
const options1 = common_vendor.ref([
{
label: "文章病例库",
value: 1
},
{
label: "视频病例库",
value: 2
},
{
label: "病例交流",
value: 3
}
]);
common_vendor.reactive({
read_num: "",
push_date: ""
});
common_vendor.onLoad((options2) => {
if (options2.keyWord) {
keyWord.value = options2.keyWord;
}
});
common_vendor.onShow(() => {
var _a;
(_a = paging.value) == null ? void 0 : _a.refresh();
});
const changetype1 = (e) => {
type1.value = e;
paging.value.reload();
};
const changetype2 = (e) => {
type2.value = e;
title2.value = options1.value[e - 1].label;
paging.value.reload();
};
const formatdate = (date) => {
return common_vendor.dayjs(date).format("YYYY-MM-DD");
};
const goDetail = (id) => {
common_vendor.index.__f__("log", "at pages/myCollect/myCollect.vue:135", type1.value);
common_vendor.index.__f__("log", "at pages/myCollect/myCollect.vue:136", id);
let type = "article";
if (type2.value == 1) {
type = "article";
} else if (type2.value == 2) {
type = "video";
} else if (type2.value == 3) {
type = "exchange";
}
utils_navTo.navTo({
url: `/pages/detail/detail?id=${id}&type=${type}`
});
};
const changeWord = (val) => {
isSearch.value = true;
keyWord.value = val;
paging.value.reload();
};
const searchCollect = (params) => {
let searchForm = {
keyword: keyWord.value,
type: type2.value
};
api_api.api.getMyCollect({
...searchForm,
...params
}).then((res) => {
paging.value.complete(res.data.data.data);
total.value = res.data.data.total;
}).catch((err) => {
paging.value.complete(false);
});
};
const searchRead = async (params) => {
let searchForm = {
keyword: keyWord.value,
type: type2.value
};
api_api.api.getMyRead({
...searchForm,
...params
}).then((res) => {
paging.value.complete(res.data.data.data);
total.value = res.data.data.total;
}).catch((err) => {
paging.value.complete(false);
});
};
const queryList = (pageNo, pageSize) => {
const params = {
page: pageNo,
page_size: pageSize
};
type1.value == 1 ? searchRead(params) : searchCollect(params);
};
return (_ctx, _cache) => {
return common_vendor.e({
a: common_vendor.o(changeWord),
b: common_vendor.p({
searchWord: keyWord.value,
navName: navName.value
}),
c: isSearch.value
}, isSearch.value ? common_vendor.e({
d: common_vendor.t(total.value),
e: keyWord.value
}, keyWord.value ? {
f: common_vendor.t(keyWord.value)
} : {}) : {}, {
g: common_vendor.o(changetype1),
h: common_vendor.o(($event) => type1.value = $event),
i: common_vendor.p({
title: type1.value == 0 ? "收藏" : "浏览",
options: options.value,
modelValue: type1.value
}),
j: common_vendor.o(changetype2),
k: common_vendor.o(($event) => type2.value = $event),
l: common_vendor.p({
title: title2.value,
options: options1.value,
modelValue: type2.value
}),
m: common_vendor.sr(uDropdownRef, "1cf734f5-2,1cf734f5-0", {
"k": "uDropdownRef"
}),
n: common_vendor.f(dataList.value, (item, index, i0) => {
return {
a: common_vendor.t(item.data.title),
b: common_vendor.f(item.data.author, (tag, k1, i1) => {
return {
a: common_vendor.t(tag.doctor_name),
b: tag.author_id
};
}),
c: "1cf734f5-5-" + i0 + ",1cf734f5-0",
d: common_vendor.t(item.data.read_num),
e: "1cf734f5-6-" + i0 + ",1cf734f5-0",
f: common_vendor.t(item.data.collect_num),
g: "1cf734f5-7-" + i0 + ",1cf734f5-0",
h: common_vendor.t(formatdate(item.data.push_date)),
i: common_vendor.o(($event) => goDetail(item.data.id), item.collect_id),
j: item.collect_id
};
}),
o: common_vendor.p({
name: "eye",
color: "#6B7280",
size: "28rpx"
}),
p: common_vendor.p({
name: "heart",
color: "#6B7280",
size: "28rpx"
}),
q: common_vendor.p({
name: "clock",
color: "#6B7280",
size: "28rpx"
}),
r: common_vendor.sr(paging, "1cf734f5-0", {
"k": "paging"
}),
s: common_vendor.o(queryList),
t: common_vendor.o(($event) => dataList.value = $event),
v: common_vendor.p({
["inside-more"]: true,
["loading-more-no-more-text"]: "咱也是有底线的!",
["auto-show-back-to-top"]: true,
modelValue: dataList.value
})
});
};
}
};
const MiniProgramPage = /* @__PURE__ */ common_vendor._export_sfc(_sfc_main, [["__scopeId", "data-v-1cf734f5"]]);
wx.createPage(MiniProgramPage);
//# sourceMappingURL=../../../.sourcemap/mp-weixin/pages/myCollect/myCollect.js.map
@@ -1,11 +0,0 @@
{
"navigationBarTitleText": "肝胆相照临床病例库",
"navigationStyle": "custom",
"usingComponents": {
"up-dropdown-item": "../../node-modules/uview-plus/components/u-dropdown-item/u-dropdown-item",
"up-dropdown": "../../node-modules/uview-plus/components/u-dropdown/u-dropdown",
"up-icon": "../../node-modules/uview-plus/components/u-icon/u-icon",
"z-paging": "../../uni_modules/z-paging/components/z-paging/z-paging",
"nav-bar-search": "../../components/navBarSearch/navBarSearch"
}
}
@@ -1 +0,0 @@
<view class="u-page data-v-1cf734f5"><z-paging wx:if="{{v}}" class="r data-v-1cf734f5" u-s="{{['top','d']}}" u-r="paging" bindquery="{{s}}" u-i="1cf734f5-0" bind:__l="__l" bindupdateModelValue="{{t}}" u-p="{{v}}"><view slot="top"><nav-bar-search wx:if="{{b}}" class="data-v-1cf734f5" bindchangeWord="{{a}}" u-i="1cf734f5-1,1cf734f5-0" bind:__l="__l" u-p="{{b}}"></nav-bar-search><view wx:if="{{c}}" class="detail data-v-1cf734f5"><view class="desc data-v-1cf734f5">检索到:<text class="red data-v-1cf734f5">{{d}}篇</text></view><view wx:if="{{e}}" class="desc data-v-1cf734f5">检索词:<text class="red data-v-1cf734f5">{{f}}</text></view></view><view class="filterbox data-v-1cf734f5"><up-dropdown u-s="{{['d']}}" class="u-dropdown r data-v-1cf734f5" u-r="uDropdownRef" u-i="1cf734f5-2,1cf734f5-0" bind:__l="__l"><up-dropdown-item wx:if="{{i}}" class="data-v-1cf734f5" bindchange="{{g}}" u-i="1cf734f5-3,1cf734f5-2" bind:__l="__l" bindupdateModelValue="{{h}}" u-p="{{i}}"></up-dropdown-item><up-dropdown-item wx:if="{{l}}" class="data-v-1cf734f5" bindchange="{{j}}" u-i="1cf734f5-4,1cf734f5-2" bind:__l="__l" bindupdateModelValue="{{k}}" u-p="{{l}}"></up-dropdown-item></up-dropdown></view></view><view wx:for="{{n}}" wx:for-item="item" wx:key="j" class="item data-v-1cf734f5" bindtap="{{item.i}}"><view class="title ellipsis-two-lines data-v-1cf734f5">{{item.a}}</view><view class="tagsbox data-v-1cf734f5"><view wx:for="{{item.b}}" wx:for-item="tag" wx:key="b" class="tag data-v-1cf734f5">{{tag.a}}</view></view><view class="deal data-v-1cf734f5"><view class="left data-v-1cf734f5"><view class="eyebox data-v-1cf734f5"><up-icon wx:if="{{o}}" class="data-v-1cf734f5" u-i="{{item.c}}" bind:__l="__l" u-p="{{o}}"></up-icon><view class="num data-v-1cf734f5">{{item.d}}</view></view><view class="collect data-v-1cf734f5"><up-icon wx:if="{{p}}" class="data-v-1cf734f5" u-i="{{item.e}}" bind:__l="__l" u-p="{{p}}"></up-icon><view class="num data-v-1cf734f5">{{item.f}}</view></view></view><view class="time data-v-1cf734f5"><up-icon wx:if="{{q}}" class="data-v-1cf734f5" u-i="{{item.g}}" bind:__l="__l" u-p="{{q}}"></up-icon><view class="num data-v-1cf734f5">{{item.h}}</view></view></view></view></z-paging></view>
@@ -1,152 +0,0 @@
/**
* 这里是uni-app内置的常用样式变量
*
* uni-app 官方扩展插件及插件市场(https://ext.dcloud.net.cn)上很多三方插件均使用了这些样式变量
* 如果你是插件开发者,建议你使用scss预处理,并在插件代码中直接使用这些变量(无需 import 这个文件),方便用户通过搭积木的方式开发整体风格一致的App
*
*/
/**
* 如果你是App开发者(插件使用者),你可以通过修改这些变量来定制自己的插件主题,实现自定义主题功能
*
* 如果你的项目同样使用了scss预处理,你也可以直接在你的 scss 代码中使用如下变量,同时无需 import 这个文件
*/
/* 颜色变量 */
/* 行为相关颜色 */
/* 文字基本颜色 */
/* 背景颜色 */
/* 边框颜色 */
/* 尺寸变量 */
/* 文字尺寸 */
/* 图片尺寸 */
/* Border Radius */
/* 水平间距 */
/* 垂直间距 */
/* 透明度 */
/* 文章场景相关 */
.databox.data-v-1cf734f5 {
height: 162rpx;
background: #ffffff;
display: flex;
margin-bottom: 20rpx;
justify-content: space-between;
}
.databox .cell.data-v-1cf734f5 {
flex: 1;
padding: 35rpx 0;
text-align: center;
}
.databox .cell .num.data-v-1cf734f5 {
font-size: 38rpx;
color: #3cc7c0;
}
.databox .cell .name.data-v-1cf734f5 {
margin-top: 18rpx;
font-size: 28rpx;
color: #4b5563;
}
.filterbox.data-v-1cf734f5 {
display: flex;
height: 128rpx;
align-items: center;
position: relative;
}
.filterbox .type.data-v-1cf734f5 {
position: absolute;
left: 30rpx;
top: 24rpx;
display: flex;
justify-content: center;
align-items: center;
background: #F3F4F6;
border-radius: 15rpx;
height: 74rpx;
padding: 0 25rpx;
z-index: 2;
}
.u-page.data-v-1cf734f5 .u-flex {
display: flex;
flex-direction: row;
overflow: hidden;
}
.u-page.data-v-1cf734f5 .u-dropdown__menu {
background: #fff;
z-index: 1;
margin-left: 0rpx;
}
.u-page.data-v-1cf734f5 .u-dropdown__menu__item {
height: 74rpx;
padding: 0 20rpx;
background: #F3F4F6;
border-radius: 15rpx;
flex: none;
margin-left: 30rpx;
}
.u-page.data-v-1cf734f5 .u-dropdown__menu__item__text {
font-size: 14px !important;
color: #3CC7C0 !important;
}
.u-page .deal.data-v-1cf734f5 {
margin-top: 20rpx;
display: flex;
color: #6b7280;
font-size: 24rpx;
justify-content: space-between;
}
.u-page .deal .left.data-v-1cf734f5 {
display: flex;
align-items: center;
}
.u-page .deal .collect.data-v-1cf734f5 {
display: flex;
align-items: center;
}
.u-page .deal .eyebox.data-v-1cf734f5 {
width: 160rpx;
display: flex;
align-items: center;
}
.u-page .deal .time.data-v-1cf734f5 {
display: flex;
align-items: center;
}
.u-page .deal .num.data-v-1cf734f5 {
margin-left: 8rpx;
}
.u-page .item.data-v-1cf734f5 {
border-bottom: 1rpx solid #f3f4f6;
padding: 30rpx;
}
.u-page .item .title.data-v-1cf734f5 {
font-size: 30rpx;
color: #111827;
line-height: 46rpx;
}
.u-page .tagsbox.data-v-1cf734f5 {
margin-top: 20rpx;
display: flex;
flex-wrap: wrap;
}
.u-page .tagsbox .tag.data-v-1cf734f5 {
padding: 0 10rpx;
margin-right: 16rpx;
height: 46rpx;
line-height: 46rpx;
text-align: center;
background: rgba(60, 199, 192, 0.1);
border-radius: 8rpx;
font-weight: 400;
font-size: 24rpx;
color: #3cc7c0;
}
.detail.data-v-1cf734f5 {
background: #f9f9f9;
padding: 12rpx 30rpx;
}
.detail .desc.data-v-1cf734f5 {
font-size: 26rpx;
color: #4b5563;
line-height: 40rpx;
}
.detail .red.data-v-1cf734f5 {
color: #FF0000;
}