Commit 7dadbb5e by liudx

添加头部个人信息设置

parent 225627a7
......@@ -5,56 +5,107 @@
<span>专利成果转化智能推荐系统</span>
</div>
<div class="header_right">
<!-- <img src="" alt=""> -->
<span class="portrait "></span>
<span class="tel">{{ username }}</span>
<!-- <img src="" alt=""> -->
<span class="portrait"></span>
<a-popover overlayClassName="portrait_set">
<template #content>
<div class="portrait_btn" @mouseenter="hover($event, '1')">
<span v-if="hover_num == 1" @click="toset">
<img src="@/static/common/icon-yhsz-hover.png" alt="" />&nbsp;
<span :class="[hover_num == 1 ? 'active' : '']">用户设置</span>
</span>
<span v-else>
<img src="@/static/common/icon-yhsz.png" alt="" />&nbsp;
<span :class="[hover_num == 1 ? '' : 'active']">用户设置</span>
</span>
</div>
<br />
<div class="portrait_btn" @mouseenter="hover($event, '2')">
<span v-if="hover_num == 2" @click="exit">
<img src="@/static/common/icon-tcdl-hover.png" alt="" />&nbsp;
<span :class="[hover_num == 2 ? 'active' : '']">退出登录</span>
</span>
<span v-else>
<img src="@/static/common/icon-tcdl.png" alt="" />&nbsp;
<span :class="[hover_num == 2 ? '' : 'active']">退出登录</span>
</span>
</div>
</template>
<span class="tel">{{ username }}</span>
</a-popover>
</div>
</div>
</template>
<script>
export default {
name: "HeaderCon",
props:{
'username':{
type:String,
props: {
username: {
type: String,
},
},
data() {
return {
hover_num: "",
};
},
methods: {
hover(e, num) {
// console.log(num)
this.hover_num = num;
},
toset(){
},
exit(){
}
}
},
};
</script>
<style lang="less" scoped>
.header {
height: 65px;
background-color: #fff;
box-shadow: 0px 2px 4px 1px rgba(0, 0, 0, 0.1);
display: flex;
justify-content: space-between;
.header_left {
padding: 10px 29px;
span {
color: #002d70;
font-family: "jiangcheng";
padding: 0 15px;
height: 65px;
background-color: #fff;
box-shadow: 0px 2px 4px 1px rgba(0, 0, 0, 0.1);
display: flex;
justify-content: space-between;
.header_left {
padding: 10px 29px;
span {
color: #002d70;
font-family: "jiangcheng";
padding: 0 15px;
}
}
.header_right {
padding: 0 50px 30px;
// display: inline-block;
line-height: 60px;
.portrait {
display: inline-block;
border-radius: 50%;
width: 60px;
height: 60px;
background-color: pink;
.portrait_set {
.portrait_btn {
cursor: pointer !important;
.active {
color: #3e7bfa !important;
}
}
}
}
.header_right {
padding: 0 50px 30px;
// display: inline-block;
.tel {
padding: 0 15px;
color: #86909c;
font-family: "Microsoft YaHei-Bold";
line-height: 60px;
.portrait {
display: inline-block;
border-radius: 50%;
width: 60px;
height: 60px;
background-color: pink;
}
.tel {
padding: 0 15px;
color: #86909C;
font-family: "Microsoft YaHei-Bold";
line-height: 60px;
display: inline-block;
vertical-align: text-bottom;
}
display: inline-block;
vertical-align: text-bottom;
}
}
}
</style>
......@@ -2,9 +2,13 @@ import { createStore } from 'vuex'
export default createStore({
state: {
username:'123456'
username:'123456',
token:''
},
mutations: {
setTOKEN(str){
this.token = str
}
},
actions: {
},
......
import { get, post } from './request'
//示例
export const login = p => post('/api/user/get_login', p);
export const login = p => post('/api/common/login', p);
// export const sendSms = p => post('/api/common/sendSms', p);
// export const sendSms = p => get('/api/home/homeWords',{});
......@@ -2,11 +2,11 @@ import axios from 'axios';
import store from '../store/index'
// 环境的切换
axios.defaults.baseURL = 'http://192.168.110.15:5001/';
axios.defaults.baseURL = 'https://taiyuan-patent.mayanan.cn/';
// 请求超时时间
axios.defaults.timeout = 10000;
axios.defaults.timeout = 50000;
// post请求头
axios.defaults.headers.post['Content-Type'] = 'application/x-www-form-urlencoded;charset=UTF-8';
axios.defaults.headers.post['Content-Type'] = 'application/json;charset=UTF-8';
// 请求拦截器
axios.interceptors.request.use(
config => {
......@@ -14,7 +14,6 @@ axios.interceptors.request.use(
// 即使本地存在token,也有可能token是过期的,所以在响应拦截器中要对返回状态进行判断
// const token = store.state.token;
// token && (config.headers.Authorization = token);
console.log(config)
return config;
},
error => {
......
......@@ -72,6 +72,7 @@
type="primary"
html-type="submit"
class="login-form-button"
@click="login"
>
登录
</a-button>
......@@ -99,6 +100,9 @@
</div>
</template>
<script>
import { AES_Encrypt, AES_Decrypt } from "@/utils/aes_util.js";
import { login } from "@/utils/API";
import { message } from "ant-design-vue";
export default {
name: "AdminLogin",
data() {
......@@ -107,10 +111,35 @@ export default {
username: "",
password: "",
remember: true,
autologin: false,
},
};
},
methods:{
//账号登录
login(){
let param = AES_Encrypt(
JSON.stringify({
login_name:this.formState.username,
password:this.formState.password,
})
);
login({
param,
}).then((res) => {
console.log(res)
if(res.code == 0){
message.success('登录成功')
this.$store.commit('setTOKEN',res.data.token)
localStorage.setItem('token',res.data.token)
this.$router.push({
path:'/index'
})
}else{
message.error(res.msg)
}
});
},
}
};
</script>
<style lang="less" scoped>
......
......@@ -72,6 +72,14 @@
>
登录
</a-button>
<!-- <a-button
type="primary"
html-type="submit"
class="login-form-button"
@click="send"
>
发送
</a-button> -->
</a-form-item>
<a-form-item>
<div class="admin_login" style="float: left">
......@@ -107,6 +115,7 @@
<script>
import { AES_Encrypt, AES_Decrypt } from "@/utils/aes_util.js";
import { login } from "@/utils/API";
import { message } from "ant-design-vue";
export default {
name: "login",
data() {
......@@ -121,13 +130,37 @@ export default {
},
mounted() {},
methods: {
// login() {
// login({
// ...parmas
// }).then((res) => {
// });
// },
//账号登录
login(){
let param = AES_Encrypt(
JSON.stringify({
login_name:this.formState.username,
password:this.formState.password,
})
);
login({
param,
}).then((res) => {
console.log(res)
if(res.code == 0){
message.success('登录成功')
this.$store.commit('setTOKEN',res.data.token)
localStorage.setItem('token',res.data.token)
this.$router.push({
path:'/index'
})
}else{
message.error(res.msg)
}
});
},
send() {
sendSms({phone:15313067271}).then(res=>{
})
},
},
};
</script>
......
......@@ -5,19 +5,29 @@
<a-breadcrumb-item>专利</a-breadcrumb-item>
<a-breadcrumb-item>专利详情</a-breadcrumb-item>
</a-breadcrumb>
<div class="back_btn">返回</div>
<div class="details_title">
<div class="patent_num">{{ "CN109775565B" }}</div>
<div class="patent_num">{{ "一种大直径单桩单钩水下翻桩方法" }}</div>
<div class="patent_title">{{ "一种大直径单桩单钩水下翻桩方法" }}</div>
</div>
<div class="btn_group">
<span><img src="@/static/patent/icon-dc.png" alt="" />导出</span>
<span v-if="follow"
><img src="@/static/patent/icon-gz.png" alt="" />关注</span
>
<span v-else
><img src="@/static/patent/icon-gz-select.png" alt="" />关注</span
>
</div>
<div class="patent_con">
<div class="patent_con_left">
<!-- 技术摘要 -->
<div class="patent_con1" id="technicalSummary">
<!-- <div class="patent_con1" id="technicalSummary">
<h2 class="title">技术摘要</h2>
<p class="desc">
本技术解决的问题:如果是单船起吊,则起重船上一定要具备主吊钩和副吊钩,且钩头方位、各个钩的起重能力需满足要求,否则就只有采用两条起重船才能实现翻身,因此要增加船舶设备的投入,施工成本高。
</p>
</div>
</div> -->
<!-- 摘要 -->
<div class="patent_con1" id="summary">
<h2 class="title">摘要</h2>
......@@ -31,52 +41,210 @@
<EchartsCloud :id="'tech'" :dataArr="techArr"></EchartsCloud>
</div>
<!-- 应用领域 -->
<div class="patent_con1" id="appArea">
<!-- <div class="patent_con1" id="appArea">
<h2 class="title">应用领域</h2>
<EchartsCloud
:id="'applicationArea'"
:dataArr="techArr"
></EchartsCloud>
</div>
</div> -->
<!-- 主要录项 -->
<div class="patent_con1" id="mainentries">
<h2 class="title">主要录项</h2>
<h2 class="title">主著录项</h2>
<a-descriptions
bordered
:column="2"
:labelStyle="{ background: '#F2F9FC' }"
>
<a-descriptions-item label="申请号"
>Cloud Database</a-descriptions-item
>
<a-descriptions-item label="优先权号">Prepaid</a-descriptions-item>
<a-descriptions-item label="申请日">YES</a-descriptions-item>
<a-descriptions-item label="优先权日"
>2018-04-24 18:00:00</a-descriptions-item
>
<a-descriptions-item label="公开号">$80.00</a-descriptions-item>
<a-descriptions-item label="授权日">授权日</a-descriptions-item>
<a-descriptions-item label="公开日">授权日</a-descriptions-item>
<a-descriptions-item label="失效日">授权日</a-descriptions-item>
<a-descriptions-item label="专利类型">授权日</a-descriptions-item>
<a-descriptions-item label="专利维持期">授权日</a-descriptions-item>
</a-descriptions>
</div>
<!-- 相关人 -->
<div class="patent_con1" id="relatedper">
<h2 class="title">相关人</h2>
<a-descriptions
bordered
:column="2"
:labelStyle="{ background: '#F2F9FC' }"
>
<a-descriptions-item label="申请人(原始)"
>Cloud Database</a-descriptions-item
>
<a-descriptions-item label="专利权人(当前)"
>中交第三航务工程局有限公司;<br />
中交三航(厦门)工程有限公司;<br />
中交第三航务工程局有限公司厦门分公司</a-descriptions-item
>
<a-descriptions-item label="申请人"
>中交第三航务工程局有限公司; 中交三航(厦门)工程有限公司;
中交第三航务工程局有限公司厦门分公司</a-descriptions-item
>
<a-descriptions-item label="专利权人"
>中交第三航务工程局有限公司; 中交三航(厦门)工程有限公司;
中交第三航务工程局有限公司厦门分公司</a-descriptions-item
>
<a-descriptions-item label="申请人(工商)"
>$80.00</a-descriptions-item
>
<a-descriptions-item label="专利权人(机构树)"
>授权日</a-descriptions-item
>
<a-descriptions-item label="申请人(机构树)"
>授权日</a-descriptions-item
>
<a-descriptions-item label="代理人">授权日</a-descriptions-item>
<a-descriptions-item label="发明人">授权日</a-descriptions-item>
<a-descriptions-item label="代理机构">授权日</a-descriptions-item>
</a-descriptions>
</div>
<!-- 地址 -->
<div class="patent_con1" id="address">
<h2 class="title">地址</h2>
<a-descriptions
bordered
:column="2"
:labelStyle="{ background: '#F2F9FC' }"
>
<a-descriptions-item label="申请人国">授权日</a-descriptions-item>
<a-descriptions-item label="公开国">授权日</a-descriptions-item>
<a-descriptions-item label="申请人地址">授权日</a-descriptions-item>
<a-descriptions-item label="专利权人地址"
>授权日</a-descriptions-item
>
</a-descriptions>
</div>
<!-- 统计信息 -->
<div class="patent_con1" id="statistic">
<h2 class="title">统计信息</h2>
<a-descriptions
bordered
:column="2"
:labelStyle="{ background: '#F2F9FC' }"
>
<a-descriptions-item label="引用数量">授权日</a-descriptions-item>
<a-descriptions-item label="权利要求数">授权日</a-descriptions-item>
<a-descriptions-item label="被引用数量">授权日</a-descriptions-item>
<a-descriptions-item label="同族数量">授权日</a-descriptions-item>
</a-descriptions>
</div>
<!-- 分类号 -->
<div class="patent_con1" id="catenum">
<h2 class="title">分类号</h2>
<a-descriptions
bordered
:column="2"
:labelStyle="{ background: '#F2F9FC' }"
>
<a-descriptions-item label="IPC分类号">授权日</a-descriptions-item>
<a-descriptions-item label="战略新兴产业分类号"
>授权日</a-descriptions-item
>
<a-descriptions-item label="国民经济分类号"
>授权日</a-descriptions-item
>
<a-descriptions-item label="双十产业集群分类号"
>授权日</a-descriptions-item
>
</a-descriptions>
</div>
</div>
<div class="patent_con_anchor">
<a-anchor>
<a-anchor-link href="#technicalSummary" title="AI技术摘要" />
<!-- <a-anchor-link href="#technicalSummary" title="AI技术摘要" /> -->
<a-anchor-link href="#summary" title="摘要" />
<a-anchor-link href="#techAera" title="技术领域" />
<a-anchor-link href="#appAera" title="应用领域" />
<a-anchor-link href="#mainentries" title="主要录项" />
<a-anchor-link href="#technicalSummary" title="相关人" />
<a-anchor-link href="#summary" title="地址" />
<a-anchor-link href="#techAera" title="统计信息" />
<a-anchor-link href="#appAera" title="分类号" />
<a-anchor-link href="#mainentries" title="法律信息" />
<a-anchor-link href="#appAera" title="权利要求" />
<a-anchor-link href="#mainentries" title="说明书" />
<!-- <a-anchor-link href="#appAera" title="应用领域" /> -->
<a-anchor-link href="#mainentries" title="主著录项" />
<a-anchor-link href="#relatedper" title="相关人" />
<a-anchor-link href="#address" title="地址" />
<a-anchor-link href="#statistic" title="统计信息" />
<a-anchor-link href="#catenum" title="分类号" />
</a-anchor>
<div id="components-back-top-demo-custom">
<a-back-top>
<div class="ant-back-top-inner">回到顶部</div>
</a-back-top>
<div class="back">回到顶部</div>
<div class="back">回到顶部</div>
</div>
</div>
<div class="patent_con_right">
<div class="patent_con1">
<h2 class="title">智能推荐</h2>
<a-select
v-model:value="value"
show-search
placeholder="请按照企业类型筛选"
style="width: 200px"
>
<a-select-option value="1">企业1</a-select-option>
<a-select-option value="2">企业2</a-select-option>
<a-select-option value="3">企业3</a-select-option>
</a-select>
<div class="result">
推荐
<span style="color: #4079ff; font-weight: bold">{{ count }}</span
>条相关结果
</div>
<div class="card" v-for="item in list" :key="item">
<div class="card_title">{{ item.name }}</div>
<a-tag color="#56CA95">{{ item.status }}</a-tag>
<a-tag color="#6096E6">{{ item.type }}</a-tag>
<a-divider />
<div class="card_desc">
<a-descriptions layout="vertical">
<a-descriptions-item label="法定代表人">{{
item.legalRepresentative
}}</a-descriptions-item>
<a-descriptions-item label="注册时间">{{
item.registrationTime
}}</a-descriptions-item>
<a-descriptions-item label="注册资本">{{
item.money
}}</a-descriptions-item>
<a-descriptions-item label="国民经济行业">
{{ item.industry }}
</a-descriptions-item>
<a-descriptions-item :span="2" label="注册地址">{{
item.address
}}</a-descriptions-item>
<a-descriptions-item :span="3" label="专利信息">{{
item.info
}}</a-descriptions-item>
<a-descriptions-item :span="2" label="经营范围">{{
item.range
}}</a-descriptions-item>
</a-descriptions>
</div>
</div>
</div>
</div>
<div class="patent_con_right"></div>
</div>
</div>
</template>
<script>
import { DownOutlined } from "@ant-design/icons-vue";
import EchartsCloud from "../../components/EchartsCloud.vue";
export default {
name: "patentDetails",
data() {
return {
value: undefined,
count: 161,
follow: true,
techArr: [
{
name: "支架搬运车",
......@@ -95,10 +263,39 @@ export default {
value: 301,
},
],
list: [
{
name: "山西科达自控股份有限公司",
status: "存续(在营、开业、在册)",
type: "高新技术企业",
legalRepresentative: "郭晓明",
registrationTime: "2023-6-1",
money: "222941.42万人民币",
industry: "批发和零售业>批发业",
address: "北京市海淀区西二旗产业园百度大厦28号",
info: "一种基于人工智能的雷达视频数据融合方法",
range:
"提供智能化科技服务,智能仓储,装直径单桩人工智能单钩硬件销售;机械设备研发",
},
{
name: "山西科达自控股份有限公司",
status: "存续(在营、开业、在册)",
type: "高新技术企业",
legalRepresentative: "郭晓明",
registrationTime: "2023-6-1",
money: "222941.42万人民币",
industry: "批发和零售业>批发业",
address: "北京市海淀区西二旗产业园百度大厦28号",
info: "一种基于人工智能的雷达视频数据融合方法",
range:
"提供智能化科技服务,智能仓储,装直径单桩人工智能单钩硬件销售;机械设备研发",
},
],
};
},
components: {
EchartsCloud,
DownOutlined,
},
methods: {
getCurrentAnchor() {
......@@ -113,6 +310,21 @@ export default {
padding: 0 30px;
width: calc(100%);
background-color: #ebebeb;
position: relative;
.back_btn {
width: 76px;
height: 32px;
background: #ffffff;
border-radius: 8px 8px 8px 8px;
opacity: 1;
color: #3e7bfa;
text-align: center;
line-height: 32px;
position: absolute;
right: 80px;
top: 10px;
}
.nav_bread {
height: 50px;
padding: 20px 3px;
......@@ -124,13 +336,44 @@ export default {
height: 176px;
.patent_num {
font-size: 25px;
margin-top: 20px;
padding: 20px 0 15px 20px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #c7d8ec;
}
.patent_title {
font-size: 25px;
padding: 0 0 20px 20px;
font-family: Microsoft YaHei-Bold, Microsoft YaHei;
font-weight: bold;
color: #ffffff;
color: #fff;
}
}
.btn_group {
position: absolute;
top: 80px;
right: 60px;
span {
display: inline-block;
width: 100px;
height: 32px;
background: rgba(255, 255, 255, 0.3);
border-radius: 8px 8px 8px 8px;
opacity: 1;
color: #fff;
line-height: 32px;
text-align: center;
margin-right: 15px;
img {
width: 17px;
vertical-align: text-bottom;
margin-right: 5px;
}
}
}
.patent_con {
clear: both;
display: flex;
position: relative;
justify-content: space-evenly;
......@@ -187,14 +430,13 @@ export default {
#components-back-top-demo-custom .ant-back-top-inner {
margin-top: 20px;
width: 150px;
height: 60px;
background-color: #fff;
text-align: center;
line-height: 60px;
height: 60px;
background-color: #fff;
text-align: center;
line-height: 60px;
}
}
.back{
.back {
display: none;
margin-top: 20px;
width: 150px;
......@@ -209,6 +451,60 @@ export default {
width: 610px;
height: 600px;
background-color: #fff;
.patent_con1 {
// width: 949px;
// height: 175px;
background: #ffffff;
border-radius: 8px 8px 8px 8px;
opacity: 1;
padding: 20px 20px;
margin: 15px 0;
.title {
color: #1c1c28;
font-size: 18px;
font-family: Microsoft YaHei UI-Bold, Microsoft YaHei UI;
font-weight: bold;
line-height: 28px;
}
.result {
font-size: 16px;
font-family: Microsoft YaHei-Regular, Microsoft YaHei;
font-weight: 400;
}
.card {
background: #f6f7fb;
border-radius: 10px 10px 10px 10px;
opacity: 0.8;
padding: 24px;
margin-bottom: 15px;
:deep(.ant-tag-has-color) {
padding: 5px;
border-radius: 6px;
}
.card_title {
font-family: Microsoft YaHei UI-Regular, Microsoft YaHei UI;
font-weight: 400;
color: #333333;
font-size: 20px;
}
.card_desc {
:deep(.ant-descriptions-item-label) {
color: #999999;
font-family: Microsoft YaHei UI-Regular, Microsoft YaHei UI;
font-weight: 400;
}
:deep(.ant-descriptions-item-content) {
font-family: Microsoft YaHei UI-Regular, Microsoft YaHei UI;
font-weight: bold;
color: #1c1c28;
}
:deep(.ant-descriptions-row > th) {
padding-bottom: 4px;
}
}
}
}
}
}
}
......
......@@ -18,7 +18,7 @@ module.exports = {
// 配置不同的后台API地址
proxy: {
'/api': {
target: 'http://192.168.110.15:5001/api',
target: 'https://taiyuan-patent.mayanan.cn',
ws: false,
changeOrigin: true,
pathRewrite: {
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment