杜函宇 2 years ago
commit 4805083c6d

@ -16,7 +16,7 @@ VUE_APP_URL = /ggfw-api
# !后台路径
# 本地
#对外
VUE_APP_HOUTAI = /ggfw
VUE_APP_HOUTAI = /ggfw-iframe
# VUE_APP_BASE_API = 'http://192.168.0.121:9023'
VUE_APP_PREFIX='/ggfw'
VUE_APP_PREFIX='/ggfw-iframe'
# VUE_APP_PREFIX='/demo/yaopin'

@ -5,7 +5,7 @@
</template>
<script>
import { Message } from "element-ui";
import { Message, MessageBox } from "element-ui";
export default {
name: "App",
metaInfo() {
@ -35,25 +35,71 @@ export default {
// obj[key] = decodedValue;
// });
var obj = {};
window.addEventListener("message", function (event) {
console.log(event);
obj = event.data.data;
console.log(obj);
if (obj.token) {
localStorage.setItem("MSSM-LIAONING__TOKEN", obj.token);
} else {
this.$alert("token不能为空", "提示", {
confirmButtonText: "返回",
callback: (action) => {
this.$router.go(-1);
},
const params = new URLSearchParams(window.location.href.split("?")[1]);
//
const type = params.get("type");
const flag = params.get("flag");
const data = params.get("data");
const token = params.get("token");
let obj = {
type,
flag,
data,
token
}
console.log(888,obj);
if (
obj.token == undefined
) {
console.log(89);
MessageBox.confirm("token不能为空", "系统提示", {
confirmButtonText: "返回",
cancelButtonText: "取消",
type: "warning",
})
.then(() => {
this.$router.go(-1);
})
.catch(() => {
this.$router.go(-1);
});
}
} else {
console.log(111);
localStorage.setItem("MSSM-LIAONING__TOKEN", obj.token);
this.$store.commit("app/URLChange", obj);
});
}
// var obj = {};
// window.addEventListener("message", function (event) {
// console.log(888, event);
// obj = event.data.data;
// console.log(999, obj);
// if (obj?.token) {
// console.log(100, obj);
// localStorage.setItem("MSSM-LIAONING__TOKEN", obj.token);
// } else {
// this.$alert("token", "", {
// confirmButtonText: "",
// callback: (action) => {
// this.$router.go(-1);
// },
// });
// }
// this.$store.commit("app/URLChange", obj);
// });
},
};
/**
sudo mv html.zip /usr/share/nginx/html/ggfw-iframe MSSM-Dev 文件夹下 移动压缩包到 ggfw文件夹下
cd /usr/share/nginx/html/ggfw-iframe 移动到文件夹下
unzip html.zip -d . 解压
rm ./html.zip 删除当前目录下的压缩包 弹出确定删除 y 并回车
*/
</script>
<style>
::-webkit-scrollbar {

@ -1,6 +1,6 @@
import request from "@/utils/request";
let api = "/api";
// let api = location.origin
// let api = "/api";
let api = location.origin
export default {
// 分页查询企业执照列表
getEnterpriseLicenseByPage(data) {

@ -18,10 +18,10 @@ axios.defaults.headers["Content-Type"] = "application/json;charset=utf-8";
const service = axios.create({
// axios中请求配置有baseURL选项表示请求URL公共部分
// !本地使用
baseURL: process.env.VUE_APP_BASE_API,
// baseURL: process.env.VUE_APP_BASE_API,
// !外地使用
// baseURL: location.origin + process.env.VUE_APP_URL,
baseURL: location.origin + process.env.VUE_APP_URL,
// 超时
timeout: 60000,
});

@ -7,13 +7,32 @@
</div>
<div class="title--right" v-if="edit">
<div class="anniu--btn--left">
<el-button type="primary" plain size="mini" class="informant-btn" @click="sendEdit(0)">
<img :src=" clickEdit ? require('@/assets/images/home/chongzhi@2x.png') :require('@/assets/images/home/edit@2x.png')" alt="" />
{{ clickEdit ? '重置':'编辑' }}
<el-button
type="primary"
plain
size="mini"
class="informant-btn"
@click="sendEdit(0)"
>
<img
:src="
clickEdit
? require('@/assets/images/home/chongzhi@2x.png')
: require('@/assets/images/home/edit@2x.png')
"
alt=""
/>
{{ clickEdit ? "重置" : "编辑" }}
</el-button>
</div>
<div class="anniu--btn--right" v-if="clickEdit">
<el-button type="primary" plain size="mini" class="informant-btnTwo" @click="sendEdit(1)">
<el-button
type="primary"
plain
size="mini"
class="informant-btnTwo"
@click="sendEdit(1)"
>
<img src="@/assets/images/home/baocun@2x.png" alt="" />
保存
</el-button>
@ -27,43 +46,43 @@
</template>
<script>
export default {
name:'blockHeader',
props:{
title:{
type:String,
required:true
name: "blockHeader",
props: {
title: {
type: String,
required: true,
},
edit: {
type: Boolean,
default: false,
},
edit:{
type:Boolean,
default:false,
}
},
data() {
return {
clickEdit:false,
}
clickEdit: false,
};
},
methods:{
sendEdit(id){
if(id) {
methods: {
sendEdit(id) {
if (id) {
//
this.$emit('btnClick',2);
this.$emit("btnClick", 2);
this.clickEdit = false;
} else {
//
if(this.clickEdit) {
if (this.clickEdit) {
//
// this.clickEdit = false;
this.$emit('btnClick',3);
this.$emit("btnClick", 3);
} else {
//
this.clickEdit = true;
this.$emit('btnClick',1);
this.$emit("btnClick", 1);
}
}
}
},
},
}
};
</script>
<style lang="scss" scoped>
@import "@/assets/styles/utils.scss";
@ -78,14 +97,14 @@ export default {
.line {
width: vw(4);
height: vh(22);
background: #1E80EB;
background: #1e80eb;
margin-right: vw(9);
}
.title {
font-size: vw(16);
font-family: Source Han Sans CN;
font-weight: bold;
color: #1E80EB;
color: #1e80eb;
}
}
.title--right {
@ -94,28 +113,28 @@ export default {
.anniu--btn--left {
::v-deep .informant-btn {
width: vw(84);
height: vh(40);
background: #e4effd;
border: vw(1) solid #1E80EB;
border-radius: vw(4);
line-height: vh(33);
display: flex;
justify-content: center;
align-items: center;
background-color: #fff;
img {
width: vw(13);
margin-right: vw(5);
}
span {
display: inline-block;
font-size: vw(14);
font-family: Source Han Sans CN;
font-weight: 400;
color: #1E80EB;
}
width: vw(84);
height: vh(40);
background: #e4effd;
border: vw(1) solid #1e80eb;
border-radius: vw(4);
line-height: vh(33);
display: flex;
justify-content: center;
align-items: center;
background-color: #fff;
img {
width: vw(13);
margin-right: vw(5);
}
span {
display: inline-block;
font-size: vw(14);
font-family: Source Han Sans CN;
font-weight: 400;
color: #1e80eb;
}
}
}
.anniu--btn--right {
margin-left: vw(10);
@ -123,13 +142,13 @@ export default {
width: vw(84);
height: vh(40);
background: #e4effd;
border: vw(1) solid #1E80EB;
border: vw(1) solid #1e80eb;
border-radius: vw(4);
line-height: vh(33);
display: flex;
justify-content: center;
align-items: center;
background-color: #1E80EB;
background-color: #1e80eb;
img {
width: vw(13);
margin-right: vw(5);
@ -149,4 +168,7 @@ export default {
margin-top: vh(24);
}
}
::v-deep .el-descriptions--mini.is-bordered .el-descriptions-item__cell {
padding: vh(15) vw(10);
}
</style>

@ -119,4 +119,7 @@ export default {
}
}
}
::v-deep .el-descriptions--mini.is-bordered .el-descriptions-item__cell{
padding: vh(15) vw(10);
}
</style>

@ -22,8 +22,6 @@
</template>
<script>
import { stringify } from 'querystring';
export default {
name:"dialogTitle",
data() {

@ -545,13 +545,14 @@ export default {
this.form1.cybh = this.name;
this.form1.size = 10;
this.form1.current = 1;
this.listyp()
this.listyp();
} else if (this.urlA.type == "3") {
}
},
reset() {
this.name = "";
this.value = "";
this.listyp();
},
getPagination(e) {
this.form1.current = e.page;
@ -686,7 +687,7 @@ export default {
justify-content: center;
}
.informant-btn {
padding: 12px 30px;
padding: vw(13) vh(10);
width: vw(44);
height: vh(20);
background: #e4effd;
@ -706,7 +707,7 @@ export default {
}
::v-deep .el-table td {
height: vh(40);
padding: 0;
padding: vh(10);
font-size: vw(14);
font-weight: 400;
color: #292f38;
@ -810,7 +811,6 @@ export default {
}
}
.drug-input {
background: #f5f9fc;
padding: vh(40) vw(22);
display: flex;
align-items: center;

@ -125,7 +125,7 @@
<i class="el-icon-s-marketing"></i>
</span>
<div>A项目检验报告.doc</div>
<div class="file-icon" @click="uploadBG">
<div class="file-icon" @click="uploadBG">
<!-- cpjsyqlj -->
<i class="el-icon-download"></i>
下载
@ -931,4 +931,7 @@ export default {
}
}
}
::v-deep .el-descriptions--medium.is-bordered .el-descriptions-item__cell {
padding: vh(15) vw(10);
}
</style>

@ -3,31 +3,65 @@
<div class="drugInfo-top">
<div class="top-left">
<div class="drug-name">
<span>{{ pruduct.key }} </span>
<span>{{ pruduct.key }} </span>
<!-- <span class="Name">{{ 暂无 }}</span> -->
<span class="Name">{{ pruduct.value || '暂无' }}</span>
<span class="Name">{{ pruduct.value || "暂无" }}</span>
</div>
<div class="drug-tag">
<span v-for="item in tags" :key="item.id">{{ item.name }}</span>
</div>
</div>
<div>
<el-button type="primary" plain size="mini" @click="goBack"></el-button>
<el-button type="primary" plain @click="goBack"></el-button>
</div>
</div>
<div class="drugInfo-bottom">
<div class="content-tabs">
<div class="tabs">
<div class="tab" @click="actionTab(1)" :class="action == 1 ? 'actionTab':''">
<img :class="action !== 1 ? 'actionImage' : ''" :src="action == 1 ? `${require('@/assets/images/home/icon1-1@2x.png')}`:`${require('@/assets/images/home/icon1-2@2x.png')}`" alt="">
<div
class="tab"
@click="actionTab(1)"
:class="action == 1 ? 'actionTab' : ''"
>
<img
:class="action !== 1 ? 'actionImage' : ''"
:src="
action == 1
? `${require('@/assets/images/home/icon1-1@2x.png')}`
: `${require('@/assets/images/home/icon1-2@2x.png')}`
"
alt=""
/>
<span>基本信息</span>
</div>
<div class="tab" @click="actionTab(2)" :class="action == 2 ? 'actionTab':''">
<img :src="action == 2 ? `${require('@/assets/images/home/icon2-1@2x.png')}`:`${require('@/assets/images/home/icon2-2@2x.png')}`" alt="">
<div
class="tab"
@click="actionTab(2)"
:class="action == 2 ? 'actionTab' : ''"
>
<img
:src="
action == 2
? `${require('@/assets/images/home/icon2-1@2x.png')}`
: `${require('@/assets/images/home/icon2-2@2x.png')}`
"
alt=""
/>
<span>品种抽样</span>
</div>
<div class="tab" @click="actionTab(3)" :class="action == 3 ? 'actionTab':''">
<img :src="action == 3 ? `${require('@/assets/images/home/icon5-1@2x.png')}`:`${require('@/assets/images/home/icon5-2@2x.png')}`" alt="">
<div
class="tab"
@click="actionTab(3)"
:class="action == 3 ? 'actionTab' : ''"
>
<img
:src="
action == 3
? `${require('@/assets/images/home/icon5-1@2x.png')}`
: `${require('@/assets/images/home/icon5-2@2x.png')}`
"
alt=""
/>
<span>不良反应</span>
</div>
</div>
@ -65,96 +99,101 @@
</div> -->
<div class="drug-exit" :style="drugExitStyle">
<!-- <router-view></router-view> -->
<component :is="currentComponent" :transinformation="transinformation" @getCPName="getCPName"></component>
<component
:is="currentComponent"
:transinformation="transinformation"
@getCPName="getCPName"
></component>
</div>
</div>
</div>
</template>
<script>
import basicInfo from "./drugBasicInfo/drugBasicInfo"
import PZchouyang from "./PZchouyang/PZchouyang"
import adverseReaction from "./adverseReaction/adverseReaction"
import basicInfo from "./drugBasicInfo/drugBasicInfo";
import PZchouyang from "./PZchouyang/PZchouyang";
import adverseReaction from "./adverseReaction/adverseReaction";
export default {
data() {
return {
row:{},
tags:[
row: {},
tags: [
{
id:1,
name:'百年产品'
},{
id:2,
name:'疗效显著'
id: 1,
name: "百年产品",
},
{
id: 2,
name: "疗效显著",
},
],
action:1,
currentComponent:'basicInfo',
drugExitStyle:{
height:'',
action: 1,
currentComponent: "basicInfo",
drugExitStyle: {
height: "",
},
// isOne:false,
id:null,
token:null,
id: null,
token: null,
//
pruduct:{
key:'某某产品',
value:'-'
}
}
pruduct: {
key: "某某产品",
value: "-",
},
};
},
components:{
components: {
basicInfo,
PZchouyang,
adverseReaction
adverseReaction,
},
methods:{
methods: {
//
getCPName(e){
this.pruduct.key = e.key
this.pruduct.value = e.value
getCPName(e) {
this.pruduct.key = e.key;
this.pruduct.value = e.value;
},
goBack(){
this.$router.go(-1)
goBack() {
this.$router.go(-1);
},
// tabs
actionTab(id){
actionTab(id) {
this.action = id;
if(id == 1) {
this.currentComponent = 'basicInfo'
if (id == 1) {
this.currentComponent = "basicInfo";
// this.$router.push({ name:'drugBasicInfo' })
this.$nextTick(()=>{
this.$nextTick(() => {
this.getHeight();
})
} else if(id == 2) {
this.currentComponent = 'PZchouyang'
this.$nextTick(()=>{
});
} else if (id == 2) {
this.currentComponent = "PZchouyang";
this.$nextTick(() => {
this.getHeight();
})
});
// this.$router.push({ name:'PZchouyang' })
} else if(id == 3) {
this.currentComponent = 'adverseReaction'
this.$nextTick(()=>{
} else if (id == 3) {
this.currentComponent = "adverseReaction";
this.$nextTick(() => {
this.getHeight();
})
});
// this.$router.push({ name:'adverseReaction' })
}
}
},
getHeight(){
let dom = document.getElementsByClassName('drug-exit');
getHeight() {
let dom = document.getElementsByClassName("drug-exit");
let height = dom[0].getBoundingClientRect();
let windowWidth = window.innerWidth;
let windowHeight = window.innerHeight;
let relativeHeight = windowHeight - height.top - 10
this.drugExitStyle.height = relativeHeight + 'px'
let relativeHeight = windowHeight - height.top - 10;
this.drugExitStyle.height = relativeHeight + "px";
},
async getVRdgYpwhGxwz(res){
async getVRdgYpwhGxwz(res) {
let data = await this.$api.productDetails.vRdgYpwhGxwz(res);
this.name = data.data.yptymc;
},
async ylqxJnyelcp(res){
let data = await this.$api.productDetails.ylqxJnyelcp(res);
async ylqxJnyelcp(res) {
let data = await this.$api.productDetails.ylqxJnyelcp(res);
this.name = data.data.cpmc;
}
},
},
// watch: {
// $route: {
@ -165,33 +204,33 @@ export default {
// immediate: true, //
// },
// },
computed:{
transinformation(){
switch(this.currentComponent) {
case 'basicInfo':
computed: {
transinformation() {
switch (this.currentComponent) {
case "basicInfo":
return {
b:this.id,
token:this.token,
}
case 'PZchouyang':
b: this.id,
token: this.token,
};
case "PZchouyang":
return {
b:this.id,
token:this.token,
}
case 'adverseReaction':
b: this.id,
token: this.token,
};
case "adverseReaction":
return {
b:this.id,
token:this.token,
}
b: this.id,
token: this.token,
};
default:
return {
b:4,
token:'暂无'
}
b: 4,
token: "暂无",
};
}
}
},
},
mounted(){
mounted() {
// params
// console.log(this.$route.params)
// this.row = JSON.parse(this.$route.params.row)
@ -207,7 +246,6 @@ export default {
// } else if(paramsLabel == 'qxzczh') {
// this.ylqxJnyelcp(params[2].split('=')[1]);
// }
// // X
// if(this.id == '1') {
// this.goback = true;
@ -217,22 +255,22 @@ export default {
// this.$nextTick(()=>{
// this.getHeight();
// })
}
}
},
};
</script>
<style lang="scss" scoped>
@import "@/assets/styles/utils.scss";
.productinformation {
width: 100%;
height: 100%;
background: rgba(255,255,255,0.9);
box-shadow: 0px 0px vw(12) 0px rgba(194,212,226,0.64);
background: rgba(255, 255, 255, 0.9);
box-shadow: 0px 0px vw(12) 0px rgba(194, 212, 226, 0.64);
border-radius: vw(10) vw(10) 0 0;
.drugInfo-top {
display: flex;
justify-content: space-between;
padding: vh(15) vw(25);
border-bottom: vw(1) solid #EDEEF0;
border-bottom: vw(1) solid #edeef0;
.close {
cursor: pointer;
}
@ -248,12 +286,12 @@ export default {
font-size: vw(18);
font-family: Source Han Sans CN;
font-weight: 400;
color: #6A6C6F;
color: #6a6c6f;
}
.Name {
// margin-left: ;
color: #292F38;
color: #292f38;
}
}
.drug-tag {
@ -267,19 +305,18 @@ export default {
margin-right: vw(10);
font-family: Source Han Sans CN;
font-weight: 400;
color: #FFFFFF;
color: #ffffff;
padding: vh(4) vw(13);
background-color: #66C691;
background-color: #66c691;
border-radius: vw(2);
&:nth-of-type(2) {
background-color: #EABB48;
background-color: #eabb48;
}
&:last-child {
margin-right: 0;
}
}
}
}
}
@ -290,9 +327,9 @@ export default {
.tabs {
width: 100%;
display: flex;
border-bottom: vw(1) solid #DBE0E8;
border-bottom: vw(1) solid #dbe0e8;
.tab {
border: vw(1) solid #DBE0E8;
border: vw(1) solid #dbe0e8;
padding: vh(7) vw(22);
display: flex;
align-items: center;
@ -300,7 +337,7 @@ export default {
margin-right: vw(9);
cursor: pointer;
&:last-child{
&:last-child {
margin-right: 0;
}
@ -321,12 +358,12 @@ export default {
font-size: vw(16);
font-family: Source Han Sans CN;
font-weight: 400;
color: #2F3742;
color: #2f3742;
}
}
.actionTab {
background-color: #1E80EB;
background-color: #1e80eb;
span {
color: #fff;
}
@ -340,5 +377,8 @@ export default {
overflow-y: scroll;
}
}
}
::v-deep.pzChouyang .tables .el-table td{
}
</style>

Loading…
Cancel
Save