# Conflicts:
#	src/utils/constant.js
master
王岚馨 11 months ago
commit 3635e6f2e2

@ -43,8 +43,8 @@ body {
/* 模块化背景色及透明度 */ /* 模块化背景色及透明度 */
.background-opacity { .background-opacity {
/*background: var(--background);*/ background-color: var(--background);
/*opacity: 0.88;*/ opacity: 0.88;
} }
.my-el-image { .my-el-image {

@ -41,7 +41,7 @@
<!-- 爱情买卖 --> <!-- 爱情买卖 -->
<li @click="$router.push({path: '/love'})"> <li @click="$router.push({path: '/love'})">
<div class="my-menu"> <div class="my-menu">
💋 <span>预测研发流程</span> 🥼 <span>预测研发流程</span>
</div> </div>
</li> </li>

@ -39,6 +39,10 @@
<input class="ais-SearchBox-input" type="text" <input class="ais-SearchBox-input" type="text"
v-model="queryParams.drug2" v-model="queryParams.drug2"
placeholder="请输入药品B名称" maxlength="32"> placeholder="请输入药品B名称" maxlength="32">
<div style="width: 10px"></div>
<input class="ais-SearchBox-input" type="text"
v-model="queryParams.reaction"
placeholder="请输入相互作用效果" maxlength="32">
<div class="ais-SearchBox-submit" @click="handleQuery()"> <div class="ais-SearchBox-submit" @click="handleQuery()">
<svg style="margin-top: 3.5px;margin-left: 18px" viewBox="0 0 1024 1024" width="20" height="20"> <svg style="margin-top: 3.5px;margin-left: 18px" viewBox="0 0 1024 1024" width="20" height="20">
<path <path
@ -69,60 +73,47 @@
<div class="page-container-wrap"> <div class="page-container-wrap">
<div class="page-container"> <div class="page-container">
<div class="aside-content" v-if="showAside"> <div class="aside-content" v-if="showAside">
<myAside @selectSort="selectSort" @selectArticle="selectArticle"></myAside> <myAside ref="myAsideRef" @selectSort="selectSort" @selectArticle="selectArticle"></myAside>
</div> </div>
<div class="recent-posts"> <div class="recent-posts">
<div class="announcement background-opacity"> <div class="announcement background-opacity">
<i class="fa fa-volume-up" aria-hidden="true"></i> <i class="fa fa-volume-up" aria-hidden="true"></i>
<div> <div>
<div v-for="(notice, index) in $store.state.webInfo.notices" :key="index"> <!-- <div v-for="(notice, index) in $store.state.webInfo.notices" :key="index">-->
{{ notice }} <!-- {{ notice }}-->
</div> <!-- </div>-->
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;世界上只有一种真正的英雄主义那就是看清生活的真相之后依然勇敢地热爱生活
</div> </div>
</div> </div>
<articleList :articleList="articles"></articleList> <articleList :articleList="articles"></articleList>
<!-- <div class="pagination-wrap">-->
<!-- <div @click="pageArticles()" class="pagination" v-if="pagination.total !== articles.length">-->
<!-- 下一页-->
<!-- </div>-->
<!-- <div v-else style="user-select: none">-->
<!-- ~~到底啦~~-->
<!-- </div>-->
<!-- </div>-->
<template> <template>
<div class="pagination-wrap"> <div class="shadow-box pagination-wrap background-opacity">
<el-table :data="table1List"> <el-table :data="table1List">
<el-table-column prop="drug1" label="药品A"></el-table-column> <el-table-column label="药品A">
<el-table-column prop="drug2" label="药品B"></el-table-column> <template slot-scope="{ row }">
<span @click="selectDrugDetails(row.drug1)">{{ row.drug1 }}</span>
</template>
</el-table-column>
<el-table-column label="药品B">
<template slot-scope="{ row }">
<span @click="selectDrugDetails(row.drug2)">{{ row.drug2 }}</span>
</template>
</el-table-column>
<el-table-column prop="reaction" label="相互作用效果"></el-table-column> <el-table-column prop="reaction" label="相互作用效果"></el-table-column>
</el-table> </el-table>
<!-- <div @click="pageArticles()" class="pagination" v-if="pagination.total !== articles.length">-->
<!-- 下一页-->
<!-- </div>-->
<!-- <pagination-->
<!-- v-show="total>0"-->
<!-- :total="total"-->
<!-- :page.sync="queryParams.pageNum"-->
<!-- :limit.sync="queryParams.pageSize"-->
<!-- @pagination="getList"-->
<!-- />-->
</div> </div>
<!-- <div style="user-select: none;text-align: center">-->
<!-- ~~到底啦~~-->
<!-- </div>-->
<!--分页组件--> <!--分页组件-->
<div class="block"> <div class="block background-opacity">
<el-pagination <el-pagination
@size-change="handleSizeChange" @size-change="handleSizeChange"
@current-change="handleCurrentChange" @current-change="handleCurrentChange"
:current-page="currentPage4" :current-page="currentPage1"
:page-sizes="[100, 200, 300, 400]" :page-sizes="[10, 15, 20, 15]"
:page-size="100" :page-size="10"
layout="total, sizes, prev, pager, next, jumper" layout="total, sizes, prev, pager, next, jumper"
:total="400"> :total=this.pagination.total>
</el-pagination> </el-pagination>
</div> </div>
</template> </template>
@ -141,7 +132,7 @@
</div> </div>
</template> </template>
<script> <script>
import {listTable1} from "@/utils/table1"; import {listTable1, listTotal, selectDetails} from "@/utils/table1";
const loader = () => import( "./common/loader"); const loader = () => import( "./common/loader");
const zombie = () => import( "./common/zombie"); const zombie = () => import( "./common/zombie");
@ -162,10 +153,7 @@
data() { data() {
return { return {
currentPage1: 5, currentPage1: 1,
currentPage2: 5,
currentPage3: 5,
currentPage4: 4,
loading: false, loading: false,
showAside: true, showAside: true,
printerInfo: "你看对面的青山多漂亮", printerInfo: "你看对面的青山多漂亮",
@ -201,23 +189,41 @@
created() { created() {
this.getGuShi(); this.getGuShi();
this.getArticles(); this.getArticles();
this.getList(); this.handleQuery();
}, },
mounted() { mounted() {
}, },
methods: { methods: {
selectDrugDetails(drugName) {
this.$refs.myAsideRef.updateDrugName(drugName);
},
/** 查询药品作用列表条数 */
getTotal() {
listTotal(this.queryParams).then(response => {
this.pagination.total = parseInt(response);
console.log(this.pagination.total);
});
},
handleSizeChange(val) { handleSizeChange(val) {
console.log(`每页 ${val}`); this.queryParams.pageSize = val; //
this.getList();
}, },
handleCurrentChange(val) { handleCurrentChange(val) {
console.log(`当前页: ${val}`); this.queryParams.pageNum = val; //
this.getList();
}, },
/** 搜索按钮操作 */ /** 搜索按钮操作 */
handleQuery() { handleQuery() {
this.queryParams.pageNum = 1; this.queryParams.pageNum = 1;
this.getList(); this.getList();
this.getTotal();
//
const targetElement = document.querySelector('.recent-posts');
if (targetElement) {
targetElement.scrollIntoView({ behavior: "smooth", block: "start" });
}
}, },
/** 查询药品作用管理列表 */ /** 查询药品作用管理列表 */
getList() { getList() {
@ -225,7 +231,6 @@
this.table1List = []; // this.table1List = []; //
listTable1(this.queryParams).then(response => { listTable1(this.queryParams).then(response => {
this.table1List = response; this.table1List = response;
console.log(this.table1List[0].reaction);
}); });
}, },
async selectSort(sort) { async selectSort(sort) {
@ -518,6 +523,7 @@
border-radius: 40px; border-radius: 40px;
color: var(--maxGreyFont); color: var(--maxGreyFont);
background: var(--white); background: var(--white);
opacity: 0.5;
} }
@media screen and (max-width: 1100px) { @media screen and (max-width: 1100px) {

@ -1,48 +1,42 @@
<template> <template>
<div> <div>
<!-- 封面 --> <!-- 封面 -->
<div class="card-content1 shadow-box background-opacity">
<div class="bg-wrap my-animation-slide-top"> <div class="bg-wrap my-animation-slide-top">
<!-- 背景图片 --> <el-image class="love-image my-el-image" lazy :src="love.bgCover" fit="cover" style="width: 100%; height: 100vh;">
<el-image class="love-image my-el-image"
lazy
:src="love.bgCover"
fit="cover">
<div slot="error" class="image-slot"></div> <div slot="error" class="image-slot"></div>
</el-image> </el-image>
<!-- 对象 -->
<div class="love-wrap transformCenter"> <div class="love-wrap transformCenter">
<div> <div>
<el-avatar class="love-avatar" :src="love.manCover"></el-avatar> <el-avatar class="love-avatar" :src="love.manCover"></el-avatar>
<div class="love-title"> <div class="love-title">{{love.manName}}</div>
{{love.manName}}
</div>
</div>
<div>
<img class="love-img" :src="$constant.loveLike" alt="心心">
</div> </div>
<div> <div>
<el-avatar class="love-avatar" :src="love.womanCover"></el-avatar> <el-avatar class="love-avatar" :src="love.womanCover"></el-avatar>
<div class="love-title"> <div class="love-title">{{love.womanName}}</div>
{{love.womanName}}
</div>
</div> </div>
</div> </div>
<div id="bannerWave1"></div> <div id="bannerWave1"></div>
<div id="bannerWave2"></div> <div id="bannerWave2"></div>
</div> </div>
</div>
<!-- 内容 --> <!-- 内容 -->
<div class="love-container"> <div class="love-container">
<div class="myCenter love-content"> <div class="myCenter love-content">
<!-- 时间 --> <!-- 时间 -->
<div> <div>
<!-- 计时 --> <!-- 计时 -->
<div> <div>
<div class="love-time-title1">
这是我们一起走过的
</div>
<div class="love-time1"> <div class="love-time1">
<span class="love-time1-item">{{timing.year}}</span> <span class="love-time1-item">{{timing.year}}</span>
@ -65,11 +59,12 @@
{{love.countdownTitle}}: {{countdownChange}} {{love.countdownTitle}}: {{countdownChange}}
</div> </div>
</div> </div>
</div> </div>
<div style="padding: 0 20px"> <div style="padding: 0 20px">
<div class="family-button shadow-box-mini" @click="changeCard(4)"> <div class="family-button shadow-box-mini" @click="changeCard(4)">
<span class="family-button-title">{{card === 4 ? '回到主人家' : '开往表白墙'}}</span>
<span class="family-button-car"> <span class="family-button-car">
<svg viewBox="0 0 1024 1024" width="40" height="40"> <svg viewBox="0 0 1024 1024" width="40" height="40">
<path <path
@ -108,40 +103,45 @@
</div> </div>
<div style="padding: 0 20px"> <div style="padding: 0 20px">
<!-- 卡片 -->
<div class="card-wrap" v-show="card !== 4">
<div class="card-content shadow-box-mini" @click="changeCard(1)"> <div style="width: 350px ;padding: 15px;border-radius: 10px;margin-top: 30px;animation: hideToShow 1s ease-in-out" class="card-wrap card-content shadow-box-mini background-opacity wow" v-show="card !== 4">
<div> <div style="display: flex; flex-wrap: wrap">
<el-avatar :size="100" <div style="flex-basis: 100%; margin-bottom: 10px;">
:src="$constant.loveWeiYan"> <div style="color: var(--lightGreen);font-size: 20px;font-weight: bold;margin-bottom: 10px; white-space: nowrap;">
</el-avatar> 预测DDI
</div>
<div class="card-right">
<div class="card-title">
点点滴滴
</div> </div>
<div class="card-desc">
今朝有酒今朝醉
</div> </div>
<div style="flex-basis: 100%; margin-bottom: 10px;">
<input class="ais-SearchBox-input" type="text"
v-model="smiles1"
placeholder="请输入SMILES" maxlength="32">
</div> </div>
<div style="flex-basis: 100%; margin-bottom: 10px;">
<input class="ais-SearchBox-input" type="text"
v-model="smiles2"
placeholder="请输入SMILES" maxlength="32">
</div> </div>
<div style="flex-basis: 100%; margin-bottom: 10px;">
<div class="card-content shadow-box-mini" @click="changeCard(2)"> <div class="ais-SearchBox-input" style="background-color: white; padding: 6px; border-radius: 4px;border: none; text-align: center;">
<div> {{predictResult}}
<el-avatar :size="100"
:src="$constant.lovePhoto">
</el-avatar>
</div> </div>
<div class="card-right">
<div class="card-title">
时光相册
</div> </div>
<div class="card-desc">
📸记录美好瞬间 <div class="ais-SearchBox-submit" @click="handleQuery();" style="flex-basis: 100%;display: flex; justify-content: right; align-items: center;" >
<svg style="margin-top: 3.5px;margin-left: 18px" viewBox="0 0 1024 1024" width="20" height="20">
<path d="M51.2 508.8c0 256.8 208 464.8 464.8 464.8s464.8-208 464.8-464.8-208-464.8-464.8-464.8-464.8 208-464.8 464.8z" fill="#51C492"></path>
<path d="M772.8 718.4c48-58.4 76.8-132.8 76.8-213.6 0-186.4-151.2-337.6-337.6-337.6-186.4 0-337.6 151.2-337.6 337.6 0 186.4 151.2 337.6 337.6 337.6 81.6 0 156-28.8 213.6-76.8L856 896l47.2-47.2-130.4-130.4zM512 776c-149.6 0-270.4-121.6-270.4-271.2S363.2 233.6 512 233.6c149.6 0 271.2 121.6 271.2 271.2C782.4 654.4 660.8 776 512 776z" fill="#FFFFFF"></path>
</svg>
</div> </div>
</div> </div>
</div> </div>
<!-- 卡片 -->
<div class="card-wrap" v-show="card !== 4">
<div class="card-content shadow-box-mini" @click="changeCard(3)"> <div class="card-content shadow-box-mini" @click="changeCard(3)">
<div> <div>
<el-avatar :size="100" <el-avatar :size="100"
@ -150,15 +150,28 @@
</div> </div>
<div class="card-right"> <div class="card-right">
<div class="card-title"> <div class="card-title">
祝福板 记录
</div> </div>
<div class="card-desc"> <div class="card-desc">
📋写下对我们的祝福 📋写下你的开发记录
</div> </div>
</div> </div>
</div> </div>
</div> </div>
<div class="myCenter love-content">
<!-- 时间 -->
<div>
<!-- 计时 -->
<div>
<div class="love-time-title1">
<a class="collection-btn" @click="showTip()">
<i class="el-icon-star-off" style="margin-right: 2px"></i>
</a>
</div>
</div>
</div>
</div>
<div class="card-container"> <div class="card-container">
<div v-show="card === 1 && !$common.isEmpty(treeHoleList)"> <div v-show="card === 1 && !$common.isEmpty(treeHoleList)">
<treeHole :treeHoleList="treeHoleList" <treeHole :treeHoleList="treeHoleList"
@ -239,7 +252,7 @@
</div> </div>
<div class="family-bottom" style="background-color: var(--lightGreen)" @click="addFamily()"> <div class="family-bottom" style="background-color: var(--lightGreen)" @click="addFamily()">
<span style="line-height: 50px"> <span style="line-height: 50px">
申请入住 设置
</span> </span>
<span style="vertical-align:middle"> <span style="vertical-align:middle">
<svg viewBox="0 0 1024 1024" width="30" height="30"><path <svg viewBox="0 0 1024 1024" width="30" height="30"><path
@ -256,7 +269,7 @@
</div> </div>
</div> </div>
<el-dialog title="入住表白墙" <el-dialog title="开启你的记录流程吧"
:visible.sync="loveDialogVisible" :visible.sync="loveDialogVisible"
width="40%" width="40%"
:close-on-click-modal="false" :close-on-click-modal="false"
@ -287,7 +300,7 @@
</div> </div>
<div> <div>
<div class="form-title"> <div class="form-title">
男生头像&nbsp; 头像&nbsp;
</div> </div>
<div style=" display: flex"> <div style=" display: flex">
<el-input maxlength="120" v-model="userLove.manCover"></el-input> <el-input maxlength="120" v-model="userLove.manCover"></el-input>
@ -302,12 +315,12 @@
</div> </div>
<div> <div>
<div class="form-title"> <div class="form-title">
女生头像&nbsp; 项目logo&nbsp;
</div> </div>
<div style=" display: flex"> <div style=" display: flex">
<el-input maxlength="120" v-model="userLove.womanCover"></el-input> <el-input maxlength="120" v-model="userLove.womanCover"></el-input>
<div style="margin: 3px 0 0 10px"> <div style="margin: 3px 0 0 10px">
<proButton :info="'上传头像'" <proButton :info="'上传logo'"
@click.native="openPicture('womanCover')" @click.native="openPicture('womanCover')"
:before="$constant.before_color_1" :before="$constant.before_color_1"
:after="$constant.after_color_1"> :after="$constant.after_color_1">
@ -317,7 +330,7 @@
</div> </div>
<div> <div>
<div class="form-title"> <div class="form-title">
男生昵称&nbsp; 昵称&nbsp;
</div> </div>
<div> <div>
<el-input maxlength="10" v-model="userLove.manName"></el-input> <el-input maxlength="10" v-model="userLove.manName"></el-input>
@ -325,7 +338,7 @@
</div> </div>
<div> <div>
<div class="form-title"> <div class="form-title">
女生昵称&nbsp; 项目名&nbsp;
</div> </div>
<div> <div>
<el-input maxlength="10" v-model="userLove.womanName"></el-input> <el-input maxlength="10" v-model="userLove.womanName"></el-input>
@ -369,7 +382,7 @@
</div> </div>
<div> <div>
<div class="form-title"> <div class="form-title">
告白信&nbsp;&nbsp; 简述&nbsp;&nbsp;
</div> </div>
<div> <div>
<el-input type="textarea" <el-input type="textarea"
@ -391,7 +404,7 @@
<div> <div>
<img :src="$constant.friendLetterBiLi" style="width: 100%;margin: 5px auto"/> <img :src="$constant.friendLetterBiLi" style="width: 100%;margin: 5px auto"/>
</div> </div>
<p style="font-size: 12px;text-align: center;color: #999">欢迎入住表白墙</p> <p style="font-size: 12px;text-align: center;color: #999">开启记录</p>
</div> </div>
</div> </div>
</div> </div>
@ -413,12 +426,15 @@
<!-- 页脚 --> <!-- 页脚 -->
<myFooter></myFooter> <myFooter></myFooter>
</div> </div>
</div> </div>
</div> </div>
</template> </template>
<script> <script>
import {listTable1, predictReaction} from "@/utils/table1";
const treeHole = () => import( "./common/treeHole"); const treeHole = () => import( "./common/treeHole");
const comment = () => import( "./comment/comment"); const comment = () => import( "./comment/comment");
const myFooter = () => import( "./common/myFooter"); const myFooter = () => import( "./common/myFooter");
@ -440,6 +456,9 @@
data() { data() {
return { return {
predictResult:'type预测结果',
smiles1 :'',
smiles2 :'',
userLove: { userLove: {
bgCover: "", bgCover: "",
manCover: "", manCover: "",
@ -451,6 +470,15 @@
timing: "", timing: "",
familyInfo: "" familyInfo: ""
}, },
pagination: {
current: 1,
size: 5,
recommendStatus: true
},
recommendArticles: [],
admires: [],
showAdmireDialog: false,
articleSearch: "",
loveDialogVisible: false, loveDialogVisible: false,
addPictureDialog: false, addPictureDialog: false,
pictureType: "", pictureType: "",
@ -495,7 +523,14 @@
} }
}, },
computed: {}, computed: {
webInfo() {
return this.$store.state.webInfo;
},
sortInfo() {
return this.$store.state.sortInfo;
}
},
watch: {}, watch: {},
@ -503,6 +538,8 @@
this.getAdminFamily(); this.getAdminFamily();
this.card = 1; this.card = 1;
this.getWeiYan(); this.getWeiYan();
this.getRecommendArticles();
this.getAdmire();
}, },
mounted() { mounted() {
@ -510,6 +547,65 @@
}, },
methods: { methods: {
/** 预测按钮操作 */
handleQuery() {
this.predictResult = '输入的SMILES错误请重试';
predictReaction(this.smiles1, this.smiles2)
.then(prediction => {
this.predictResult = "type:"+prediction;
})
.catch(error => {
console.error(error);
});
},
selectSort(sort) {
this.$emit("selectSort", sort);
},
selectArticle() {
this.$emit("selectArticle", this.articleSearch);
},
showAdmire() {
if (this.$common.isEmpty(this.$store.state.currentUser)) {
this.$message({
message: "请先登录!",
type: "error"
});
return;
}
this.showAdmireDialog = true;
},
getAdmire() {
this.$http.get(this.$constant.baseURL + "/webInfo/getAdmire")
.then((res) => {
if (!this.$common.isEmpty(res.data)) {
this.admires = res.data;
}
})
.catch((error) => {
this.$message({
message: error.message,
type: "error"
});
});
},
getRecommendArticles() {
this.$http.post(this.$constant.baseURL + "/article/listArticle", this.pagination)
.then((res) => {
if (!this.$common.isEmpty(res.data)) {
this.recommendArticles = res.data.records;
}
})
.catch((error) => {
this.$message({
message: error.message,
type: "error"
});
});
},
showTip() {
this.$router.push({path: '/weiYan'});
},
openPicture(type) { openPicture(type) {
this.pictureType = type; this.pictureType = type;
this.addPictureDialog = true; this.addPictureDialog = true;
@ -529,7 +625,7 @@
submitLove() { submitLove() {
if (this.userLove.bgCover.trim() === "") { if (this.userLove.bgCover.trim() === "") {
this.$message({ this.$message({
message: "你还没设置背景封面呢~", message: "你还没设置呢~",
type: "warning" type: "warning"
}); });
return; return;
@ -537,7 +633,7 @@
if (this.userLove.manCover.trim() === "") { if (this.userLove.manCover.trim() === "") {
this.$message({ this.$message({
message: "你还没设置男生头像呢~", message: "你还没设置呢~",
type: "warning" type: "warning"
}); });
return; return;
@ -545,7 +641,7 @@
if (this.userLove.womanCover.trim() === "") { if (this.userLove.womanCover.trim() === "") {
this.$message({ this.$message({
message: "你还没设置女生头像呢~", message: "你还没设置呢~",
type: "warning" type: "warning"
}); });
return; return;
@ -553,7 +649,7 @@
if (this.userLove.manName.trim() === "") { if (this.userLove.manName.trim() === "") {
this.$message({ this.$message({
message: "你还没写男生昵称呢~", message: "你还没写呢~",
type: "warning" type: "warning"
}); });
return; return;
@ -561,7 +657,7 @@
if (this.userLove.womanName.trim() === "") { if (this.userLove.womanName.trim() === "") {
this.$message({ this.$message({
message: "你还没写女生昵称呢~", message: "你还没写呢~",
type: "warning" type: "warning"
}); });
return; return;
@ -824,6 +920,19 @@
<style scoped> <style scoped>
.ais-SearchBox-input {
padding: 0 14px;
height: 30px;
width: calc(100% - 50px);
outline: 0;
border: 2px solid var(--lightGreen);
border-right: 0;
border-radius: 40px;
color: var(--maxGreyFont);
background: var(--white);
opacity: 0.5;
}
.love-container { .love-container {
background-image: linear-gradient(to right, rgba(37, 82, 110, 0.1) 1px, var(--background) 1px), linear-gradient(to bottom, rgba(37, 82, 110, 0.1) 1px, var(--background) 1px); background-image: linear-gradient(to right, rgba(37, 82, 110, 0.1) 1px, var(--background) 1px), linear-gradient(to bottom, rgba(37, 82, 110, 0.1) 1px, var(--background) 1px);
background-size: 3rem 3rem; background-size: 3rem 3rem;
@ -904,7 +1013,10 @@
} }
.love-time-title1 { .love-time-title1 {
font-size: 2rem; display: flex;
justify-content: center;
align-items: center;
font-size: 3rem;
font-weight: 600; font-weight: 600;
letter-spacing: 0.2rem; letter-spacing: 0.2rem;
line-height: 4rem; line-height: 4rem;

@ -1,27 +1,27 @@
<template> <template>
<div> <div>
<!-- 网站信息 --> <!-- 网站信息 -->
<!-- <div class="card-content1 shadow-box background-opacity">--> <div class="card-content1 shadow-box background-opacity">
<!-- <el-avatar style="margin-top: 20px" class="user-avatar" :size="120" :src="webInfo.avatar"></el-avatar>--> <el-avatar style="margin-top: 20px" class="user-avatar" :size="120" :src="webInfo.avatar"></el-avatar>
<!-- <div class="web-name">{{webInfo.webName}}</div>--> <div class="web-name">{{webInfo.webName}}</div>
<!-- <div class="web-info">--> <div class="web-info">
<!-- <div class="blog-info-box">--> <div class="blog-info-box">
<!-- <span>文章</span>--> <span>文章</span>
<!-- <span class="blog-info-num">{{ $store.getters.articleTotal }}</span>--> <span class="blog-info-num">{{ $store.getters.articleTotal }}</span>
<!-- </div>--> </div>
<!-- <div class="blog-info-box">--> <div class="blog-info-box">
<!-- <span>分类</span>--> <span>分类</span>
<!-- <span class="blog-info-num">{{ sortInfo.length }}</span>--> <span class="blog-info-num">{{ sortInfo.length }}</span>
<!-- </div>--> </div>
<!-- <div class="blog-info-box">--> <div class="blog-info-box">
<!-- <span>访问量</span>--> <span>访问量</span>
<!-- <span class="blog-info-num">{{ webInfo.historyAllCount }}</span>--> <span class="blog-info-num">{{ webInfo.historyAllCount }}</span>
<!-- </div>--> </div>
<!-- </div>--> </div>
<!-- <a class="collection-btn" @click="showTip()">--> <a class="collection-btn" @click="showTip()">
<!-- <i class="el-icon-star-off" style="margin-right: 2px"></i>朋友圈--> <i class="el-icon-star-off" style="margin-right: 2px"></i>朋友圈
<!-- </a>--> </a>
<!-- </div>--> </div>
<!-- 搜索 --> <!-- 搜索 -->
<div style="padding: 15px;border-radius: 10px;margin-top: 30px;animation: hideToShow 1s ease-in-out" <div style="padding: 15px;border-radius: 10px;margin-top: 30px;animation: hideToShow 1s ease-in-out"
@ -31,9 +31,9 @@
</div> </div>
<div style="display: flex"> <div style="display: flex">
<input class="ais-SearchBox-input" type="text" <input class="ais-SearchBox-input" type="text"
v-model="articleSearch" v-model="drugName"
placeholder="搜索药品" maxlength="32"> placeholder="搜索药品" maxlength="32">
<div class="ais-SearchBox-submit" @click="selectArticle()"> <div class="ais-SearchBox-submit" @click="selectDrugDetails()">
<svg style="margin-top: 3.5px;margin-left: 18px" viewBox="0 0 1024 1024" width="20" height="20"> <svg style="margin-top: 3.5px;margin-left: 18px" viewBox="0 0 1024 1024" width="20" height="20">
<path <path
d="M51.2 508.8c0 256.8 208 464.8 464.8 464.8s464.8-208 464.8-464.8-208-464.8-464.8-464.8-464.8 208-464.8 464.8z" d="M51.2 508.8c0 256.8 208 464.8 464.8 464.8s464.8-208 464.8-464.8-208-464.8-464.8-464.8-464.8 208-464.8 464.8z"
@ -98,64 +98,67 @@
style="margin-top: 30px;padding: 25px 25px 5px;border-radius: 10px;animation: hideToShow 1s ease-in-out"> style="margin-top: 30px;padding: 25px 25px 5px;border-radius: 10px;animation: hideToShow 1s ease-in-out">
<div class="card-content2-title"> <div class="card-content2-title">
<i class="el-icon-folder-opened card-content2-icon"></i> <i class="el-icon-folder-opened card-content2-icon"></i>
<span>分类</span> <span>药品简述</span>
</div> </div>
<div v-for="(sort, index) in sortInfo" <!-- <div v-for="(sort, index) in sortInfo"-->
:key="index" <!-- :key="index"-->
class="post-sort" <!-- class="post-sort"-->
@click="$router.push({path: '/sort', query: {sortId: sort.id}})"> <!-- @click="$router.push({path: '/sort', query: {sortId: sort.id}})">-->
<div>
<span v-for="(s, i) in sort.sortName.split('')" :key="i">{{ s }}</span>
</div>
</div>
</div>
<!-- 赞赏 -->
<!-- <div class="shadow-box-mini background-opacity wow admire-box"-->
<!-- v-if="!$common.isEmpty(admires)">-->
<!-- <div style="font-weight: bold;margin-bottom: 20px">🧨赞赏名单</div>-->
<!-- <div>--> <!-- <div>-->
<!-- <vue-seamless-scroll :data="admires" style="height: 200px;overflow: hidden">--> <!-- <span v-for="(s, i) in sort.sortName.split('')" :key="i">{{ s }}</span>-->
<!-- <div v-for="(item, i) in admires"-->
<!-- style="display: flex;justify-content: space-between"-->
<!-- :key="i">-->
<!-- <div style="display: flex">-->
<!-- <el-avatar style="margin-bottom: 10px" :size="36" :src="item.avatar"></el-avatar>-->
<!-- <div style="margin-left: 10px;height: 36px;line-height: 36px;overflow: hidden;max-width: 80px">-->
<!-- {{ item.username }}-->
<!-- </div>-->
<!-- </div>-->
<!-- <div style="height: 36px;line-height: 36px">-->
<!-- {{ item.admire }}-->
<!-- </div>-->
<!-- </div>--> <!-- </div>-->
<!-- </vue-seamless-scroll>-->
<!-- </div>--> <!-- </div>-->
<!-- <div class="admire-btn" @click="showAdmire()">--> {{drugDetails}}
</div>
<!-- 赞赏 --> <!-- 赞赏 -->
<!-- </div>--> <div class="shadow-box-mini background-opacity wow admire-box"
<!-- </div>--> v-if="!$common.isEmpty(admires)">
<div style="font-weight: bold;margin-bottom: 20px">🧨援助</div>
<div>
<vue-seamless-scroll :data="admires" style="height: 200px;overflow: hidden">
<div v-for="(item, i) in admires"
style="display: flex;justify-content: space-between"
:key="i">
<div style="display: flex">
<el-avatar style="margin-bottom: 10px" :size="36" :src="item.avatar"></el-avatar>
<div style="margin-left: 10px;height: 36px;line-height: 36px;overflow: hidden;max-width: 80px">
{{ item.username }}
</div>
</div>
<div style="height: 36px;line-height: 36px">
<!-- {{ item.admire }}-->
500
</div>
</div>
</vue-seamless-scroll>
</div>
<div class="admire-btn" @click="showAdmire()">
援助
</div>
</div>
<!-- 微信 --> <!-- 微信 -->
<!-- <el-dialog title="赞赏"--> <el-dialog title="援助"
<!-- :visible.sync="showAdmireDialog"--> :visible.sync="showAdmireDialog"
<!-- width="25%"--> width="25%"
<!-- :append-to-body="true"--> :append-to-body="true"
<!-- destroy-on-close--> destroy-on-close
<!-- center>--> center>
<!-- <div>--> <div>
<!-- <div class="admire-image"></div>--> <div class="admire-image"></div>
<!-- <div>--> <div>
<!-- <div class="admire-content">1. 感谢老铁送来的666</div>--> <div class="admire-content">1. 身处热闹人间没有谁可以保持真正的清醒不踩到生死边界活得都是一场梦</div>
<!-- <div class="admire-content">2. 申请通过后会加博客交流群不需要加群或者退群后会定期清理好友强迫症福利</div>--> <div class="admire-content">2. 如果您愿意帮助其他病友可以伸出您的援助之手我们将会将赞助全部援助到病友手中</div>
<!-- </div>--> </div>
<!-- </div>--> </div>
<!-- </el-dialog>--> </el-dialog>
</div> </div>
</template> </template>
<script> <script>
import vueSeamlessScroll from "vue-seamless-scroll"; import vueSeamlessScroll from "vue-seamless-scroll";
import {listTable1, selectDetails} from "@/utils/table1";
export default { export default {
components: { components: {
@ -171,7 +174,9 @@
recommendArticles: [], recommendArticles: [],
admires: [], admires: [],
showAdmireDialog: false, showAdmireDialog: false,
articleSearch: "" articleSearch: "",
drugDetails: '',
drugName:''
} }
}, },
computed: { computed: {
@ -187,6 +192,15 @@
this.getAdmire(); this.getAdmire();
}, },
methods: { methods: {
updateDrugName(drugName) {
this.drugName = drugName;
this.selectDrugDetails();
},
selectDrugDetails(){
selectDetails(this.drugName).then(response => {
this.drugDetails = response;
});
},
selectSort(sort) { selectSort(sort) {
this.$emit("selectSort", sort); this.$emit("selectSort", sort);
}, },

@ -5,21 +5,15 @@
<div class="travel-header my-animation-slide-top"> <div class="travel-header my-animation-slide-top">
<!-- 背景图片 --> <!-- 背景图片 -->
<video class="index-video" autoplay="autoplay" muted="muted" loop="loop" <video class="index-video" autoplay="autoplay" muted="muted" loop="loop"
:src="$constant.favoriteVideo"> :src="$constant.favoriteVideo2">
</video> </video>
<div style="position: absolute;left: 20px;top: 20px"> <div style="position: absolute;left: 20px;top: 20px">
<!-- 标题 --> <!-- 标题 -->
<div style="margin: 10px"> <div style="margin: 10px">
<div>
旅拍集
</div>
<div style="font-size: 36px;font-weight: bold;line-height: 1.5;margin-top: 20px"> <div style="font-size: 36px;font-weight: bold;line-height: 1.5;margin-top: 20px">
这里是我的旅拍哦 让照片留下医药学的足迹
</div>
</div> </div>
</div> </div>
<div style="position: absolute;left: 20px;bottom: 40px;margin: 10px">
每一张照片都是一次美好的记忆
</div> </div>
</div> </div>
@ -81,7 +75,10 @@
resourceType: "lovePhoto", resourceType: "lovePhoto",
classify: "" classify: ""
}, },
photoTitleList: [], photoTitleList: [
{ classify: "公益计划", count: 6 },
{ classify: "科研项目", count: 2 },
],
photoList: [] photoList: []
} }
}, },
@ -166,7 +163,7 @@
.travel-header { .travel-header {
margin: 60px auto 30px; margin: 60px auto 30px;
height: 300px; height: 400px;
position: relative; position: relative;
overflow: hidden; overflow: hidden;
border-radius: 20px; border-radius: 20px;

@ -8,7 +8,8 @@ import common from './utils/common'
import constant from './utils/constant' import constant from './utils/constant'
import mavonEditor from 'mavon-editor' import mavonEditor from 'mavon-editor'
//引入js //引入js
import './utils/live2d' //注释掉下面一行就取消了看板娘
// import './utils/live2d'
import './utils/title' import './utils/title'
//引入css //引入css
import './assets/css/animation.css' import './assets/css/animation.css'

@ -7,15 +7,51 @@ export function listTable1(query) {
.catch(error => console.error(error)); .catch(error => console.error(error));
} }
/**
* 查询药品总条数
* @param query
* @returns {Promise<AxiosResponse<any> | void>}
*/
export function listTotal(query) {
const url = '/system/table1/total';
return axios.get(url, { params: query })
.then(response => response.data)
.catch(error => console.error(error));
}
// 查询药品作用管理详细 /**
export function getTable1(id) { * 查询药品详细描述
return request({ * @param query
url: '/system/table1/' + id, * @returns {Promise<AxiosResponse<any> | void>}
method: 'get' */
}) export function selectDetails(drugName) {
const url = '/system/table1/details';
return axios.get(url, { params: { drugName } })
.then(response => response.data)
.catch(error => console.error(error));
}
/**
*
* @param drugName
* @returns {Promise<AxiosResponse<any> | void>}
*/
export function predictReaction(mol1, mol2) {
const url = 'http://127.0.0.1:5000/predict';
return axios.get(url, { params: { mol1, mol2 } })
.then(response => Number(response.data))
.catch(error => {console.error(error);throw new Error('请求出错');}); // 抛出错误
} }
// 查询药品作用管理详细
// export function getTable1(id) {
// return request({
// url: '/system/table1/' + id,
// method: 'get'
// })
// }
// // 新增药品作用管理 // // 新增药品作用管理
// export function addTable1(data) { // export function addTable1(data) {
// return request({ // return request({

Loading…
Cancel
Save