tijiao
This commit is contained in:
@@ -85,7 +85,7 @@
|
||||
<view
|
||||
class="home_wrap home_wrap_analysis"
|
||||
v-if="options.type != 'detail'"
|
||||
:style="`height: calc(100% - ${48 + statusBarHeight}px);`"
|
||||
:style="`height:auto;overflow-y: visible`"
|
||||
>
|
||||
<view class="home_form" style="position: relative">
|
||||
<view
|
||||
@@ -133,8 +133,8 @@
|
||||
@afterRead="addPic"
|
||||
@delete="deletePic"
|
||||
multiple
|
||||
width="120"
|
||||
height="120"
|
||||
width="110"
|
||||
height="110"
|
||||
:previewFullImage="true"
|
||||
>
|
||||
</u-upload>
|
||||
@@ -264,7 +264,7 @@
|
||||
v-if="articleInfo.createTime"
|
||||
>{{ articleInfo.createTime }}
|
||||
<uni-icons
|
||||
v-if="articleInfo.come == 0"
|
||||
|
||||
type="trash-filled"
|
||||
size="24"
|
||||
@tap="showDel = true"
|
||||
@@ -632,6 +632,7 @@ export default {
|
||||
|
||||
delArticle() {
|
||||
var that = this;
|
||||
this.showDel=false
|
||||
uni.showLoading({
|
||||
title: "加载中",
|
||||
});
|
||||
@@ -649,6 +650,7 @@ export default {
|
||||
.then((res) => {
|
||||
uni.hideLoading();
|
||||
if (res.code == 0) {
|
||||
|
||||
uni.showToast({
|
||||
title: "删除成功",
|
||||
icon: "success",
|
||||
@@ -657,6 +659,7 @@ export default {
|
||||
|
||||
this.$commonJS.refreshPrevPageData();
|
||||
} else {
|
||||
this.showDel=false
|
||||
uni.showToast({
|
||||
title: "删除失败",
|
||||
icon: "success",
|
||||
@@ -685,7 +688,7 @@ export default {
|
||||
type: 0,
|
||||
href: this.$apkUrl,
|
||||
title: `我在【太湖云医】发布了文章 “ ${this.articleInfo.title} ”`,
|
||||
// summary: `${this.productInfo.content}`,
|
||||
summary: `${this.articleInfo.content.substring(0, 50).replace(/<[^>]*>/g, '').trim()}`,
|
||||
imageUrl: image,
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
@@ -702,7 +705,7 @@ export default {
|
||||
type: 0,
|
||||
href: this.$apkUrl,
|
||||
title: `我在【太湖云医】发布了文章 “ ${this.articleInfo.title} ”`,
|
||||
// summary: `${this.taskInfo.content}`,
|
||||
summary: `${this.articleInfo.content.substring(0, 50).replace(/<[^>]*>/g, '').trim()}`,
|
||||
imageUrl: image,
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
|
||||
1853
pages/articleList/articleAdd.vue
Normal file
1853
pages/articleList/articleAdd.vue
Normal file
File diff suppressed because it is too large
Load Diff
@@ -1,7 +1,7 @@
|
||||
<template>
|
||||
<view class="richtext" style="height: 100%;">
|
||||
|
||||
<piaoyiEditor :height="height" :placeholder="placeholder" :values="values" @changes="saveContens" :readOnly="readOnly" :photoUrl="photoUrl" :api="api" :name="name"/>
|
||||
<piaoyiEditor :toolbarTop="`${48 + statusBarHeight}px`" :height="height" :placeholder="placeholder" :values="values" @changes="saveContens" :readOnly="readOnly" :photoUrl="photoUrl" :api="api" :name="name"/>
|
||||
|
||||
|
||||
</view>
|
||||
|
||||
@@ -72,7 +72,7 @@
|
||||
><text
|
||||
style="margin-right: 30rpx; color: #e38d54"
|
||||
v-if="item.come == 1"
|
||||
>医案转发</text
|
||||
>医案同步</text
|
||||
><text style="letter-spacing: 1rpx">{{
|
||||
item.createTime ? item.createTime : ""
|
||||
}}</text></view
|
||||
@@ -273,7 +273,7 @@ export default {
|
||||
|
||||
selectClick(e) {
|
||||
console.log(e.name);
|
||||
if (e.name == "删除") {
|
||||
if (e.name == "删除文章") {
|
||||
this.showDel=true;
|
||||
} else {
|
||||
uni.navigateTo({
|
||||
@@ -308,9 +308,9 @@ export default {
|
||||
|
||||
}
|
||||
|
||||
if (item.come == 1) {
|
||||
this.operateList = list;
|
||||
} else {
|
||||
// if (item.come == 1) {
|
||||
// this.operateList = list;
|
||||
// } else {
|
||||
this.operateList = [
|
||||
...list,
|
||||
{
|
||||
@@ -321,7 +321,7 @@ export default {
|
||||
fontSize: "16",
|
||||
},
|
||||
];
|
||||
}
|
||||
// }
|
||||
this.selectArticleId = item.id;
|
||||
this.showOperate = true;
|
||||
// this.$refs.commentLikePopup.showCommentPopup();
|
||||
@@ -343,7 +343,7 @@ export default {
|
||||
},
|
||||
createFolder() {
|
||||
uni.navigateTo({
|
||||
url: `/pages/articleList/article?navTitle=文章&title=文章&type=add`,
|
||||
url: `/pages/articleList/articleAdd?navTitle=文章&title=文章&type=add`,
|
||||
});
|
||||
},
|
||||
//判断显示‘上/中/下’
|
||||
@@ -386,6 +386,7 @@ export default {
|
||||
//获取列表数据
|
||||
delArticle() {
|
||||
var that = this;
|
||||
this.showDel=false;
|
||||
uni.showLoading({
|
||||
title: "加载中",
|
||||
});
|
||||
@@ -403,18 +404,27 @@ export default {
|
||||
.then((res) => {
|
||||
uni.hideLoading();
|
||||
if (res.code == 0) {
|
||||
|
||||
uni.showToast({
|
||||
title: "删除成功",
|
||||
icon: "success",
|
||||
duration: 2000,
|
||||
});
|
||||
}
|
||||
this.$nextTick(() => {
|
||||
this.$nextTick(() => {
|
||||
this.list = this.list.filter((e) => {
|
||||
return e.id != this.selectArticleId;
|
||||
});
|
||||
this.count = this.list.length;
|
||||
});
|
||||
}else {
|
||||
this.showDel=false
|
||||
uni.showToast({
|
||||
title: "删除失败",
|
||||
icon: "success",
|
||||
duration: 2000,
|
||||
});
|
||||
}
|
||||
|
||||
});
|
||||
},
|
||||
getListData(taihumedId, type) {
|
||||
|
||||
@@ -6,7 +6,7 @@
|
||||
fontColor="#fff"
|
||||
:backState="2000"
|
||||
>
|
||||
<template v-slot:right v-if="activeTab === 1">
|
||||
<template v-slot:right v-if="activeTab === 1&&showArticleButton">
|
||||
<view class="top_right" @tap="createFolder" style="margin-right: 20rpx">
|
||||
<uni-icons type="folder-add" size="17" color="#fff"></uni-icons>
|
||||
<text>发布文章</text>
|
||||
@@ -202,6 +202,7 @@
|
||||
:name="item.taihuTalent&&item.taihuTalent.name?item.taihuTalent.name:''"
|
||||
:createTime="item.createTime"
|
||||
:title="item.title"
|
||||
:id="item.id"
|
||||
:content="item.content"
|
||||
:isLike="item.likeFlag"
|
||||
:isGiveReward="item.isGiveReward"
|
||||
@@ -211,6 +212,7 @@
|
||||
:giveRewardNumber="item.giveRewardNumber"
|
||||
:commentCount="item.commentCount"
|
||||
@clickDynamic="clickDynamic(index)"
|
||||
@addRead="addRead"
|
||||
@clickUser="clickUser(item)"
|
||||
@clickFocus="clickFocus(index)"
|
||||
@clickThumbsup="(type) => clickThumbsup(item.id, type)"
|
||||
@@ -265,6 +267,7 @@ export default {
|
||||
return {
|
||||
sysNotices_list:[],
|
||||
shareId: null,
|
||||
showArticleButton: false,
|
||||
activeTab: 0,
|
||||
tabsList: [],
|
||||
currentCateIndex: 0,
|
||||
@@ -326,8 +329,34 @@ export default {
|
||||
uni.hideTabBar();
|
||||
this.getTabData();
|
||||
},
|
||||
onShow() {},
|
||||
onShow() {
|
||||
this.isShowArticleButton()
|
||||
if (this.activeTab == 0&&this.taihumedId!=null) {
|
||||
this.getListData(this.taihumedId);
|
||||
} else if (this.activeTab == 1) {
|
||||
this.getArticleListData(true);
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
async addRead(articleId){
|
||||
// common/taihuTalentArticle/addReadCount
|
||||
await $http
|
||||
.request({
|
||||
url: "common/taihuTalentArticle/addReadCount",
|
||||
method: "POST",
|
||||
data: {"articleId":articleId},
|
||||
header: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
})
|
||||
.then(async (res) => {
|
||||
if(res.code == 0){
|
||||
console.log(res)
|
||||
this.getArticleDetail(articleId);
|
||||
}
|
||||
|
||||
});
|
||||
},
|
||||
confirm2(){
|
||||
this.$refs.customModal2.close();
|
||||
this.sysNotices_list.forEach(e=>{
|
||||
@@ -358,6 +387,26 @@ readArticle(item){
|
||||
})
|
||||
.then(async (res) => {
|
||||
|
||||
});
|
||||
},
|
||||
//已读记录
|
||||
async isShowArticleButton() {
|
||||
await $http
|
||||
.request({
|
||||
url: "common/taihuTalentArticle/getArticleRoleByUser",
|
||||
method: "POST",
|
||||
data: { },
|
||||
header: {
|
||||
"Content-Type": "application/json",
|
||||
},
|
||||
})
|
||||
.then(async (res) => {
|
||||
if(res.code == 0 && res.roleFlag == 1){
|
||||
this.showArticleButton=true
|
||||
}else{
|
||||
this.showArticleButton=false
|
||||
}
|
||||
|
||||
});
|
||||
},
|
||||
async getSysNotices() {
|
||||
@@ -378,8 +427,8 @@ readArticle(item){
|
||||
}
|
||||
});
|
||||
},
|
||||
refreshData(reset) {
|
||||
if (reset) {
|
||||
refreshData() {
|
||||
this.activeTab=1;
|
||||
this.currentCateIndex = 0;
|
||||
|
||||
//重置
|
||||
@@ -389,21 +438,21 @@ readArticle(item){
|
||||
this.count = 0;
|
||||
this.current = 1;
|
||||
this.getArticleListData();
|
||||
}
|
||||
|
||||
},
|
||||
createFolder() {
|
||||
uni.navigateTo({
|
||||
url: `/pages/articleList/article?navTitle=文章&title=文章&type=add`,
|
||||
url: `/pages/articleList/articleAdd?navTitle=文章&title=文章&type=add`,
|
||||
});
|
||||
},
|
||||
newOnShare() {
|
||||
this.$refs.share.open();
|
||||
},
|
||||
haveSelected() {
|
||||
var data = this.list.find((item) => item.id == this.shareId);
|
||||
haveSelected(data) {
|
||||
var data1 = this.list.find((item) => item.id == this.shareId);
|
||||
let image = "";
|
||||
data.img && data.img != ""
|
||||
? (image = data.img.split(",")[0])
|
||||
data1.img && data1.img != ""
|
||||
? (image = data1.img.split(",")[0])
|
||||
: (image = "static/logo_zi.png");
|
||||
console.log(data, " 选择的是");
|
||||
if (data.index == 0) {
|
||||
@@ -413,8 +462,8 @@ readArticle(item){
|
||||
scene: "WXSceneSession",
|
||||
type: 0,
|
||||
href: this.$apkUrl,
|
||||
title: `我在【太湖云医】发布了文章 “ ${data.title} ”`,
|
||||
// summary: `${this.productInfo.content}`,
|
||||
title: `我在【太湖云医】发布了文章 “ ${data1.title} ”`,
|
||||
summary: `${data1.content.substring(0, 50).replace(/<[^>]*>/g, '').trim()}`,
|
||||
imageUrl: image,
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
@@ -430,8 +479,8 @@ readArticle(item){
|
||||
scene: "WXSceneTimeline",
|
||||
type: 0,
|
||||
href: this.$apkUrl,
|
||||
title: `我在【太湖云医】发布了文章 “ ${data.title} ”`,
|
||||
// summary: `${this.taskInfo.content}`,
|
||||
title: `我在【太湖云医】发布了文章 “ ${data1.title} ”`,
|
||||
summary: `${data1.content.substring(0, 50).replace(/<[^>]*>/g, '').trim()}`,
|
||||
imageUrl: image,
|
||||
success: function (res) {
|
||||
console.log("success:" + JSON.stringify(res));
|
||||
@@ -597,6 +646,7 @@ readArticle(item){
|
||||
},
|
||||
//获取列表数据
|
||||
getArticleListData(type) {
|
||||
|
||||
if (type) {
|
||||
this.current = 1;
|
||||
this.list = [];
|
||||
|
||||
@@ -173,18 +173,18 @@
|
||||
item.showFlag == 1 ? '#5188e5' : '#5e6d82'
|
||||
};display: flex;align-items: center;`"
|
||||
>
|
||||
<template @click.stop="changeShowFlag(item)">
|
||||
<text style="margin-right: 10rpx"
|
||||
<view @click.stop="changeShowFlag(item)">
|
||||
<text style="margin-right: 10rpx"
|
||||
>是否在我的医案中展示</text
|
||||
>
|
||||
<uni-icons
|
||||
<uni-icons style="margin-right: 10rpx;display: inline-block;"
|
||||
:color="item.showFlag == 1 ? '#5188e5' : '#5e6d82'"
|
||||
:type="
|
||||
item.showFlag == 0 ? 'eye-slash-filled' : 'eye-filled'
|
||||
"
|
||||
size="24"
|
||||
></uni-icons>
|
||||
</template>
|
||||
</view>
|
||||
|
||||
<view @click.stop="changeShowArticleFlag(item)"
|
||||
v-if="item.articleFlag == 0"
|
||||
|
||||
@@ -386,6 +386,10 @@ export default {
|
||||
this.$commonJS.showToast("请至少上传一张图片");
|
||||
return;
|
||||
}
|
||||
if (this.fileList1.length == 0) {
|
||||
this.$commonJS.showToast("请至少上传一张图片");
|
||||
return;
|
||||
}
|
||||
}
|
||||
if (
|
||||
["妇科", "儿科"].includes(this.medicalForm.labelTitle) &&
|
||||
|
||||
@@ -128,11 +128,11 @@ export default {
|
||||
this.payType = 1;
|
||||
}
|
||||
this.chargeOrderSn = options.orderSn;
|
||||
this.getDevName();
|
||||
|
||||
},
|
||||
//页面显示
|
||||
onShow() {
|
||||
|
||||
this.getDevName();
|
||||
},
|
||||
computed: {
|
||||
...mapState(["userInfo"]),
|
||||
@@ -373,8 +373,8 @@ export default {
|
||||
title: '加载中'
|
||||
})
|
||||
var data = {
|
||||
type: "point",
|
||||
qudao: "Android",
|
||||
type: "vip",
|
||||
qudao: "google",
|
||||
};
|
||||
$http.request({
|
||||
url: this.urlList.list,
|
||||
@@ -385,6 +385,7 @@ export default {
|
||||
},
|
||||
})
|
||||
.then((res) => {
|
||||
console.log(res,'11111111111111')
|
||||
uni.hideLoading();
|
||||
this.cjList = res.bookBuyConfigList;
|
||||
//this.stepsCj = res.bookBuyConfigList[0];
|
||||
|
||||
Reference in New Issue
Block a user