111
This commit is contained in:
parent
4544b678d0
commit
05ef454ac8
@ -184,7 +184,13 @@ const api = {
|
|||||||
},
|
},
|
||||||
readRecord(data){
|
readRecord(data){
|
||||||
return request('/user/case/read',data,'post',false,'application/json');
|
return request('/user/case/read',data,'post',false,'application/json');
|
||||||
}
|
},
|
||||||
|
updateExchange(id,data){
|
||||||
|
return request('/exchange/'+id, data, 'put',true,'application/json');
|
||||||
|
},
|
||||||
|
delExchange(id){
|
||||||
|
return request('/exchange/'+id, {}, 'delete',true);
|
||||||
|
},
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|||||||
@ -1617,7 +1617,7 @@ const readRecord= async()=>{
|
|||||||
if(type.value=='article'){
|
if(type.value=='article'){
|
||||||
flag=1;
|
flag=1;
|
||||||
}else if(type.value=='video'){
|
}else if(type.value=='video'){
|
||||||
flag=1;
|
flag=2;
|
||||||
}else{
|
}else{
|
||||||
flag=3;
|
flag=3;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -152,6 +152,12 @@ const recommend_hospital=ref([]);
|
|||||||
const numInfo=reactive({})
|
const numInfo=reactive({})
|
||||||
const goDetail = (id,isLink,src) => {
|
const goDetail = (id,isLink,src) => {
|
||||||
if(isLink==1){
|
if(isLink==1){
|
||||||
|
api.readRecord({
|
||||||
|
type:1,
|
||||||
|
id:id
|
||||||
|
}).then(res=>{
|
||||||
|
|
||||||
|
})
|
||||||
// #ifdef MP-WEIXIN
|
// #ifdef MP-WEIXIN
|
||||||
navTo({
|
navTo({
|
||||||
url: `/pages/web/web?src=${src}`,
|
url: `/pages/web/web?src=${src}`,
|
||||||
|
|||||||
@ -262,6 +262,10 @@ const queryList = (pageNo, pageSize) => {
|
|||||||
margin-left: 30rpx;
|
margin-left: 30rpx;
|
||||||
|
|
||||||
}
|
}
|
||||||
|
:deep(.u-dropdown__menu__item__text){
|
||||||
|
font-size: 14px!important;
|
||||||
|
color:rgb(60, 156, 255)!important;
|
||||||
|
}
|
||||||
.deal {
|
.deal {
|
||||||
margin-top: 20rpx;
|
margin-top: 20rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@ -835,8 +835,8 @@ const getExchangeDetail = (id) => {
|
|||||||
});
|
});
|
||||||
form.exchange_content = exchange_content;
|
form.exchange_content = exchange_content;
|
||||||
form.exchange_title = exchange_title;
|
form.exchange_title = exchange_title;
|
||||||
form.case_exchange_label = exchange_label;
|
form.case_exchange_label = exchange_label? exchange_label:[];
|
||||||
labelList.value = exchange_label;
|
labelList.value = exchange_label?exchange_label:[];
|
||||||
form.exchange_summary = exchange_summary;
|
form.exchange_summary = exchange_summary;
|
||||||
form.case_exchange_vote = exchange_vote;
|
form.case_exchange_vote = exchange_vote;
|
||||||
editorCtxResult.value.initHtml(exchange_summary,async (videoUrl) => {
|
editorCtxResult.value.initHtml(exchange_summary,async (videoUrl) => {
|
||||||
@ -931,6 +931,7 @@ const alertSave = async () => {
|
|||||||
}
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
const publish = async () => {
|
const publish = async () => {
|
||||||
const initInfo =
|
const initInfo =
|
||||||
"<p>【患者信息】:</p><br/><p>【主诉】:</p><br/><p>【现病史及既往史】:</p><br/><p>【检查】:</p><br/><p>【临床诊断】:</p><br/><p>【治疗经过及结果】:</p>";
|
"<p>【患者信息】:</p><br/><p>【主诉】:</p><br/><p>【现病史及既往史】:</p><br/><p>【检查】:</p><br/><p>【临床诊断】:</p><br/><p>【治疗经过及结果】:</p>";
|
||||||
@ -966,6 +967,18 @@ const publish = async () => {
|
|||||||
const resContent = await editorCtxResult.value.getLastContent();
|
const resContent = await editorCtxResult.value.getLastContent();
|
||||||
let reshtml = editorCtxResult.value.exportHtml(resContent.html);
|
let reshtml = editorCtxResult.value.exportHtml(resContent.html);
|
||||||
form.exchange_summary = reshtml=="<p><br></p>"?'':reshtml;
|
form.exchange_summary = reshtml=="<p><br></p>"?'':reshtml;
|
||||||
|
if(exchange_id.value){
|
||||||
|
api.updateExchange(exchange_id.value,form).then((res) => {
|
||||||
|
uni.showToast({
|
||||||
|
title: "修改成功",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
isFlag.value = false;
|
||||||
|
isPublish.value = true;
|
||||||
|
uni.navigateBack()
|
||||||
|
});
|
||||||
|
}else{
|
||||||
api.addExchange(form).then((res) => {
|
api.addExchange(form).then((res) => {
|
||||||
uni.showToast({
|
uni.showToast({
|
||||||
title: "发布成功",
|
title: "发布成功",
|
||||||
@ -976,6 +989,8 @@ const publish = async () => {
|
|||||||
isPublish.value = true;
|
isPublish.value = true;
|
||||||
uni.navigateBack()
|
uni.navigateBack()
|
||||||
});
|
});
|
||||||
|
}
|
||||||
|
|
||||||
};
|
};
|
||||||
const handleUpload = (file) => {
|
const handleUpload = (file) => {
|
||||||
api
|
api
|
||||||
@ -1310,6 +1325,8 @@ const openLabelPop=()=>{
|
|||||||
onLoad((optoions) => {
|
onLoad((optoions) => {
|
||||||
if(optoions.exchange_id){
|
if(optoions.exchange_id){
|
||||||
exchange_id.value=optoions.exchange_id;
|
exchange_id.value=optoions.exchange_id;
|
||||||
|
console.log(1111)
|
||||||
|
console.log(exchange_id.value)
|
||||||
}
|
}
|
||||||
//getDraftList();
|
//getDraftList();
|
||||||
|
|
||||||
|
|||||||
@ -471,6 +471,12 @@ const formatdate=(date)=>{
|
|||||||
const goDetail=(id,isLink,src)=>{
|
const goDetail=(id,isLink,src)=>{
|
||||||
console.log(isLink)
|
console.log(isLink)
|
||||||
if(isLink==1){
|
if(isLink==1){
|
||||||
|
api.readRecord({
|
||||||
|
type:isArticle.value?1:2,
|
||||||
|
id:id
|
||||||
|
}).then(res=>{
|
||||||
|
|
||||||
|
})
|
||||||
// #ifdef MP-WEIXIN
|
// #ifdef MP-WEIXIN
|
||||||
navTo({
|
navTo({
|
||||||
url: `/pages/web/web?src=${src}`,
|
url: `/pages/web/web?src=${src}`,
|
||||||
|
|||||||
@ -531,7 +531,17 @@ const htmlToText=(html)=>{
|
|||||||
|
|
||||||
const confirmDel = () => {
|
const confirmDel = () => {
|
||||||
//删除
|
//删除
|
||||||
|
api.delExchange(dealId.value).then((res) => {
|
||||||
|
uni.showToast({
|
||||||
|
title: "删除成功",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2000,
|
||||||
|
});
|
||||||
|
});
|
||||||
|
let index=dataList.value.findIndex( item =>item.exchange_id=== dealId.value)
|
||||||
|
dataList.value.splice(index, 1);
|
||||||
showModal.value = false;
|
showModal.value = false;
|
||||||
|
//paging.value.refresh();
|
||||||
};
|
};
|
||||||
|
|
||||||
const closeDealPop = () => {
|
const closeDealPop = () => {
|
||||||
@ -561,7 +571,6 @@ onLoad((options) => {
|
|||||||
getCaseLabel(1,0)
|
getCaseLabel(1,0)
|
||||||
});
|
});
|
||||||
onShow(()=>{
|
onShow(()=>{
|
||||||
|
|
||||||
paging.value?.refresh();
|
paging.value?.refresh();
|
||||||
})
|
})
|
||||||
const changeDate=(e)=>{
|
const changeDate=(e)=>{
|
||||||
|
|||||||
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
File diff suppressed because one or more lines are too long
6
unpackage/dist/dev/mp-weixin/api/api.js
vendored
6
unpackage/dist/dev/mp-weixin/api/api.js
vendored
@ -180,6 +180,12 @@ const api = {
|
|||||||
},
|
},
|
||||||
readRecord(data) {
|
readRecord(data) {
|
||||||
return utils_request.request("/user/case/read", data, "post", false, "application/json");
|
return utils_request.request("/user/case/read", data, "post", false, "application/json");
|
||||||
|
},
|
||||||
|
updateExchange(id, data) {
|
||||||
|
return utils_request.request("/exchange/" + id, data, "put", true, "application/json");
|
||||||
|
},
|
||||||
|
delExchange(id) {
|
||||||
|
return utils_request.request("/exchange/" + id, {}, "delete", true);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
exports.api = api;
|
exports.api = api;
|
||||||
|
|||||||
@ -673,7 +673,7 @@ const _sfc_main = {
|
|||||||
if (type.value == "article") {
|
if (type.value == "article") {
|
||||||
flag = 1;
|
flag = 1;
|
||||||
} else if (type.value == "video") {
|
} else if (type.value == "video") {
|
||||||
flag = 1;
|
flag = 2;
|
||||||
} else {
|
} else {
|
||||||
flag = 3;
|
flag = 3;
|
||||||
}
|
}
|
||||||
|
|||||||
@ -27,6 +27,11 @@ const _sfc_main = {
|
|||||||
const numInfo = common_vendor.reactive({});
|
const numInfo = common_vendor.reactive({});
|
||||||
const goDetail = (id, isLink, src) => {
|
const goDetail = (id, isLink, src) => {
|
||||||
if (isLink == 1) {
|
if (isLink == 1) {
|
||||||
|
api_api.api.readRecord({
|
||||||
|
type: 1,
|
||||||
|
id
|
||||||
|
}).then((res) => {
|
||||||
|
});
|
||||||
utils_navTo.navTo({
|
utils_navTo.navTo({
|
||||||
url: `/pages/web/web?src=${src}`
|
url: `/pages/web/web?src=${src}`
|
||||||
});
|
});
|
||||||
|
|||||||
@ -81,6 +81,10 @@
|
|||||||
flex: none;
|
flex: none;
|
||||||
margin-left: 30rpx;
|
margin-left: 30rpx;
|
||||||
}
|
}
|
||||||
|
.u-page.data-v-1cf734f5 .u-dropdown__menu__item__text {
|
||||||
|
font-size: 14px !important;
|
||||||
|
color: #3c9cff !important;
|
||||||
|
}
|
||||||
.u-page .deal.data-v-1cf734f5 {
|
.u-page .deal.data-v-1cf734f5 {
|
||||||
margin-top: 20rpx;
|
margin-top: 20rpx;
|
||||||
display: flex;
|
display: flex;
|
||||||
|
|||||||
@ -288,8 +288,8 @@ const _sfc_main = {
|
|||||||
});
|
});
|
||||||
form.exchange_content = exchange_content;
|
form.exchange_content = exchange_content;
|
||||||
form.exchange_title = exchange_title;
|
form.exchange_title = exchange_title;
|
||||||
form.case_exchange_label = exchange_label;
|
form.case_exchange_label = exchange_label ? exchange_label : [];
|
||||||
labelList.value = exchange_label;
|
labelList.value = exchange_label ? exchange_label : [];
|
||||||
form.exchange_summary = exchange_summary;
|
form.exchange_summary = exchange_summary;
|
||||||
form.case_exchange_vote = exchange_vote;
|
form.case_exchange_vote = exchange_vote;
|
||||||
editorCtxResult.value.initHtml(exchange_summary, async (videoUrl) => {
|
editorCtxResult.value.initHtml(exchange_summary, async (videoUrl) => {
|
||||||
@ -397,6 +397,18 @@ const _sfc_main = {
|
|||||||
const resContent = await editorCtxResult.value.getLastContent();
|
const resContent = await editorCtxResult.value.getLastContent();
|
||||||
let reshtml = editorCtxResult.value.exportHtml(resContent.html);
|
let reshtml = editorCtxResult.value.exportHtml(resContent.html);
|
||||||
form.exchange_summary = reshtml == "<p><br></p>" ? "" : reshtml;
|
form.exchange_summary = reshtml == "<p><br></p>" ? "" : reshtml;
|
||||||
|
if (exchange_id.value) {
|
||||||
|
api_api.api.updateExchange(exchange_id.value, form).then((res2) => {
|
||||||
|
common_vendor.index.showToast({
|
||||||
|
title: "修改成功",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2e3
|
||||||
|
});
|
||||||
|
isFlag.value = false;
|
||||||
|
isPublish.value = true;
|
||||||
|
common_vendor.index.navigateBack();
|
||||||
|
});
|
||||||
|
} else {
|
||||||
api_api.api.addExchange(form).then((res2) => {
|
api_api.api.addExchange(form).then((res2) => {
|
||||||
common_vendor.index.showToast({
|
common_vendor.index.showToast({
|
||||||
title: "发布成功",
|
title: "发布成功",
|
||||||
@ -407,6 +419,7 @@ const _sfc_main = {
|
|||||||
isPublish.value = true;
|
isPublish.value = true;
|
||||||
common_vendor.index.navigateBack();
|
common_vendor.index.navigateBack();
|
||||||
});
|
});
|
||||||
|
}
|
||||||
};
|
};
|
||||||
const handleUpload = (file) => {
|
const handleUpload = (file) => {
|
||||||
api_api.api.getOss({
|
api_api.api.getOss({
|
||||||
@ -439,7 +452,7 @@ const _sfc_main = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: (err) => {
|
fail: (err) => {
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1013", err);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1028", err);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@ -469,7 +482,7 @@ const _sfc_main = {
|
|||||||
return randomNumber;
|
return randomNumber;
|
||||||
};
|
};
|
||||||
const getImageFormat = (imageUrl) => {
|
const getImageFormat = (imageUrl) => {
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1043", imageUrl);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1058", imageUrl);
|
||||||
const lastDotIndex = imageUrl.lastIndexOf(".");
|
const lastDotIndex = imageUrl.lastIndexOf(".");
|
||||||
if (lastDotIndex !== -1) {
|
if (lastDotIndex !== -1) {
|
||||||
return imageUrl.substring(lastDotIndex + 1);
|
return imageUrl.substring(lastDotIndex + 1);
|
||||||
@ -501,7 +514,7 @@ const _sfc_main = {
|
|||||||
//从相册选择
|
//从相册选择
|
||||||
extension: [".mp4", ".webm", ".ogg"],
|
extension: [".mp4", ".webm", ".ogg"],
|
||||||
success: function(res) {
|
success: function(res) {
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1070", res.tempFilePath);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1085", res.tempFilePath);
|
||||||
HandleAddVideo(res.tempFilePath);
|
HandleAddVideo(res.tempFilePath);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
@ -539,7 +552,7 @@ const _sfc_main = {
|
|||||||
async success(res2) {
|
async success(res2) {
|
||||||
if (res2.statusCode === 204) {
|
if (res2.statusCode === 204) {
|
||||||
let url = host + "/" + dir + filename + imgType;
|
let url = host + "/" + dir + filename + imgType;
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1112", editorCtx2);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1127", editorCtx2);
|
||||||
let imgUrl = "https://cn.bing.com//th?id=OHR.FlamingosNamibia_ZH-CN3639748956_1920x1080.jpg";
|
let imgUrl = "https://cn.bing.com//th?id=OHR.FlamingosNamibia_ZH-CN3639748956_1920x1080.jpg";
|
||||||
const fileThumbnail = await editorCtx2.createCoverThumbnail(
|
const fileThumbnail = await editorCtx2.createCoverThumbnail(
|
||||||
imgUrl
|
imgUrl
|
||||||
@ -553,7 +566,7 @@ const _sfc_main = {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
fail: (err) => {
|
fail: (err) => {
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1127", err);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1142", err);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
@ -594,7 +607,7 @@ const _sfc_main = {
|
|||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1172", caseValue1);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1187", caseValue1);
|
||||||
getCaseLabel(2, e);
|
getCaseLabel(2, e);
|
||||||
};
|
};
|
||||||
const groupChange2 = (e) => {
|
const groupChange2 = (e) => {
|
||||||
@ -693,7 +706,7 @@ const _sfc_main = {
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
labelList.value = labelList.value.filter((item, index) => labelList.value.findIndex((i) => i.app_iden === item.app_iden) === index);
|
labelList.value = labelList.value.filter((item, index) => labelList.value.findIndex((i) => i.app_iden === item.app_iden) === index);
|
||||||
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1290", labelList.value);
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1305", labelList.value);
|
||||||
showCase.value = false;
|
showCase.value = false;
|
||||||
};
|
};
|
||||||
const closeCase = () => {
|
const closeCase = () => {
|
||||||
@ -714,6 +727,8 @@ const _sfc_main = {
|
|||||||
common_vendor.onLoad((optoions) => {
|
common_vendor.onLoad((optoions) => {
|
||||||
if (optoions.exchange_id) {
|
if (optoions.exchange_id) {
|
||||||
exchange_id.value = optoions.exchange_id;
|
exchange_id.value = optoions.exchange_id;
|
||||||
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1328", 1111);
|
||||||
|
common_vendor.index.__f__("log", "at pages/publish/publish.vue:1329", exchange_id.value);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
return (_ctx, _cache) => {
|
return (_ctx, _cache) => {
|
||||||
|
|||||||
@ -265,6 +265,11 @@ const _sfc_main = {
|
|||||||
const goDetail = (id, isLink, src) => {
|
const goDetail = (id, isLink, src) => {
|
||||||
common_vendor.index.__f__("log", "at pages/search/search.vue:472", isLink);
|
common_vendor.index.__f__("log", "at pages/search/search.vue:472", isLink);
|
||||||
if (isLink == 1) {
|
if (isLink == 1) {
|
||||||
|
api_api.api.readRecord({
|
||||||
|
type: isArticle.value ? 1 : 2,
|
||||||
|
id
|
||||||
|
}).then((res) => {
|
||||||
|
});
|
||||||
utils_navTo.navTo({
|
utils_navTo.navTo({
|
||||||
url: `/pages/web/web?src=${src}`
|
url: `/pages/web/web?src=${src}`
|
||||||
});
|
});
|
||||||
@ -401,7 +406,7 @@ const _sfc_main = {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
const queryList = (pageNo, pageSize) => {
|
const queryList = (pageNo, pageSize) => {
|
||||||
common_vendor.index.__f__("log", "at pages/search/search.vue:620", 666666);
|
common_vendor.index.__f__("log", "at pages/search/search.vue:626", 666666);
|
||||||
const params = {
|
const params = {
|
||||||
page: pageNo,
|
page: pageNo,
|
||||||
page_size: pageSize
|
page_size: pageSize
|
||||||
|
|||||||
@ -227,6 +227,15 @@ const _sfc_main = {
|
|||||||
return html.replace(/<[^>]*>/g, "").replace(/ /gi, " ").replace(/<br\s*\/?>/gi, "\n").replace(/<img\s[^>]*>/gi, "").replace(/<video[^>]*>[\s\S]*?/gi, "");
|
return html.replace(/<[^>]*>/g, "").replace(/ /gi, " ").replace(/<br\s*\/?>/gi, "\n").replace(/<img\s[^>]*>/gi, "").replace(/<video[^>]*>[\s\S]*?/gi, "");
|
||||||
};
|
};
|
||||||
const confirmDel = () => {
|
const confirmDel = () => {
|
||||||
|
api_api.api.delExchange(dealId.value).then((res) => {
|
||||||
|
common_vendor.index.showToast({
|
||||||
|
title: "删除成功",
|
||||||
|
icon: "none",
|
||||||
|
duration: 2e3
|
||||||
|
});
|
||||||
|
});
|
||||||
|
let index = dataList.value.findIndex((item) => item.exchange_id === dealId.value);
|
||||||
|
dataList.value.splice(index, 1);
|
||||||
showModal.value = false;
|
showModal.value = false;
|
||||||
};
|
};
|
||||||
const closeDealPop = () => {
|
const closeDealPop = () => {
|
||||||
@ -297,7 +306,7 @@ const _sfc_main = {
|
|||||||
});
|
});
|
||||||
};
|
};
|
||||||
const queryList = (pageNo, pageSize) => {
|
const queryList = (pageNo, pageSize) => {
|
||||||
common_vendor.index.__f__("log", "at pages/specialList/specialList.vue:606", 666666);
|
common_vendor.index.__f__("log", "at pages/specialList/specialList.vue:615", 666666);
|
||||||
const params = {
|
const params = {
|
||||||
page: pageNo,
|
page: pageNo,
|
||||||
page_size: pageSize
|
page_size: pageSize
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user