Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
T
ty_patentSys
Overview
Overview
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
hanxiao
ty_patentSys
Commits
1a4a6395
Commit
1a4a6395
authored
Jul 25, 2023
by
liudx
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
联调企业详情、企业筛选接口
parent
9623b853
Hide whitespace changes
Inline
Side-by-side
Showing
14 changed files
with
703 additions
and
273 deletions
+703
-273
public/company.docx
+0
-0
src/App.vue
+7
-0
src/assets/fontFamily/font.css
+6
-8
src/assets/fontFamily/江城斜黑体900W.ttf
+0
-0
src/components/HeaderCon.vue
+4
-2
src/static/common/img-tx-big.svg
+2
-0
src/utils/indexApi.js
+14
-0
src/views/company/companyDetails.vue
+205
-62
src/views/company/companyProfile.vue
+24
-21
src/views/company/index.vue
+167
-107
src/views/home/index.vue
+20
-10
src/views/login/forget.vue
+60
-18
src/views/patent/index.vue
+24
-6
src/views/userset/securitySetting.vue
+170
-39
No files found.
public/company.docx
View file @
1a4a6395
No preview for this file type
src/App.vue
View file @
1a4a6395
...
...
@@ -17,6 +17,13 @@
box-sizing
:
border-box
!important
;
background-color
:
#F2F3F5
;
}
@font-face
{
font-family
:
"jiangcheng"
;
src
:
url("../src/assets/fontFamily/江城斜黑体900W.ttf")
format
(
"truetype"
);
font-weight
:
normal
;
font-style
:
normal
;
}
html
,
body
,
#app
{
//
height
:
100%
;
//
min-height
:
980px
;
...
...
src/assets/fontFamily/font.css
View file @
1a4a6395
@font-face
{
font-family
:
'jiangcheng'
;
src
:
url('./jiangcheng.ttf')
;
font-weight
:
normal
;
font-style
:
normal
;
}
\ No newline at end of file
@font-face
{
font-family
:
"jiangcheng"
;
src
:
url("./江城斜黑体900W.ttf")
format
(
"truetype"
);
font-weight
:
normal
;
font-style
:
normal
;
}
src/assets/fontFamily/
jiangcheng
.ttf
→
src/assets/fontFamily/
江城斜黑体900W
.ttf
View file @
1a4a6395
File moved
src/components/HeaderCon.vue
View file @
1a4a6395
...
...
@@ -91,7 +91,7 @@ export default {
this
.
username
=
localStorage
.
getItem
(
'login_name'
);
},
computed
:
{
...
mapState
([
"username"
]),
},
data
()
{
return
{
...
...
@@ -206,7 +206,9 @@ export default {
border-radius
:
50%
;
width
:
60px
;
height
:
60px
;
background-color
:
pink
;
//
background-color
:
pink
;
background
:
url('../static/common/img-tx-big.svg')
no-repeat
;
background-size
:
100%
100%
;
.portrait_btn
{
cursor
:
pointer
!important
;
...
...
src/static/common/img-tx-big.svg
0 → 100644
View file @
1a4a6395
<svg
xmlns=
"http://www.w3.org/2000/svg"
xmlns:xlink=
"http://www.w3.org/1999/xlink"
width=
"120"
height=
"120"
viewBox=
"0 0 120 120"
><defs><style>
.a{fill:#6aa1ff;}.b{clip-path:url(#a);}.c{fill:#f04d4e;}.d{fill:#d84850;}.e{fill:#c7928e;}.f{fill:#333;}.g{fill:#fecccb;}.h{fill:#2b2b2b;}.i{fill:#b6d5d0;}
</style><clipPath
id=
"a"
><circle
class=
"a"
cx=
"60"
cy=
"60"
r=
"60"
/></clipPath></defs><g
transform=
"translate(-1842 -13)"
><circle
class=
"a"
cx=
"60"
cy=
"60"
r=
"60"
transform=
"translate(1842 13)"
/><g
class=
"b"
transform=
"translate(1842 13)"
><g
transform=
"translate(9.886 16.628)"
><path
class=
"c"
d=
"M103.741,52.06V44.385c0-15.74-24.854-20.032-24.854-20.032H28.717s-25.2,4.293-25.2,20.032V52.06s-.058,5.788,8.053,5.984,42.292,0,42.292,0,34.007.2,42.118,0S103.741,52.06,103.741,52.06Z"
transform=
"translate(-3.515 46.384)"
/><path
class=
"d"
d=
"M62.608,24.021H53.976l-25.259.521s-25.2,4.345-25.2,18.365v6.836s-.058,5.156,8.053,5.33,8.169-.116,8.169-.116l24.68-18.771H62.608Z"
transform=
"translate(-3.515 45.731)"
/><path
class=
"e"
d=
"M15.428,19.139H45.554V37.678H15.428Z"
transform=
"translate(19.912 36.13)"
/><path
class=
"f"
d=
"M68.432,11.731s3.824,11.7-6.6,18.713V9.472Zm-57.818,0s-2.086,11.7,6.6,18.713V9.472l-6.6,2.259Z"
transform=
"translate(10.011 17.12)"
/><path
class=
"g"
d=
"M12.7,26.947V48.324s5.1,18.423,23.29,18.423S59.045,47.977,59.045,47.977V28.453S60.2.644,35.987.644,12.7,26.947,12.7,26.947Z"
transform=
"translate(14.532 -0.239)"
/><path
class=
"g"
d=
"M35.874,66.786c-17.96,0-23.174-18.423-23.174-18.423V26.985S11.541.625,35.874.625Z"
transform=
"translate(14.529 -0.277)"
/><path
class=
"h"
d=
"M30.493,15.976s3.882,15.468,39.8,15.468c0,0-.579-30.937-29.778-30.937S10.39,31.445,10.39,31.445a38.35,38.35,0,0,0,20.1-15.468Z"
transform=
"translate(10.003 -0.508)"
/><path
class=
"i"
d=
"M21.589,20.955,12.03,30.92,27.672,42.507l9.907-7.821Z"
transform=
"translate(13.229 39.702)"
/><path
class=
"i"
d=
"M36.281,20.955,45.84,30.92,30.256,42.507l-9.965-7.821Z"
transform=
"translate(29.474 39.702)"
/></g></g></g></svg>
\ No newline at end of file
src/utils/indexApi.js
View file @
1a4a6395
import
{
get
,
post
,
put
}
from
'./request'
//专利搜索接口
export
const
patents
=
p
=>
get
(
'/api/patent/patents?keyword='
+
p
.
keyword
+
'&page='
+
p
.
page
+
'&size='
+
p
.
size
);
//专利筛选接口
export
const
patentselect
=
p
=>
post
(
'/api/patent/patents'
,
p
);
//专利详情页面
export
const
patentDetail
=
p
=>
get
(
'/api/patent/patentDetail/'
+
p
.
id
);
//导出word给后端传递base64
export
const
exportword
=
p
=>
post
(
'/api/patent/patentDetail/125'
,
p
);
// 企业搜索接口
export
const
enterpriseList
=
p
=>
get
(
'/api/enterprise/list?keyword='
+
p
.
keyword
+
'&page='
+
p
.
page
+
'&size='
+
p
.
size
);
//企业国民经济行业接口
export
const
industryType
=
p
=>
get
(
'/api/common/industryType'
);
//企业筛选器接口
export
const
enterpriseSelect
=
p
=>
post
(
'/api/enterprise/list'
,
p
);
//企业详情
export
const
enterpriseDetail
=
p
=>
get
(
'/api/enterprise/detail/'
+
p
.
id
);
src/views/company/companyDetails.vue
View file @
1a4a6395
...
...
@@ -8,77 +8,103 @@
<div
class=
"back_btn"
@
click=
"backbtn"
>
返回
</div>
<div
class=
"details_title"
>
<div
class=
"company_num"
>
<span>
{{
"山西煤炭进出口集团有限公司"
}}
</span>
<a-tag
color=
"#56CA95"
>
{{
"存续(在营、开业、在册)"
}}
</a-tag>
<a-tag
color=
"#6096E6"
>
{{
"2222222"
}}
</a-tag>
<span>
{{
baseinfo
.
company_name
}}
</span>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.high_new=='1'"
>
{{
'高新技术企业'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.tbe=='1'"
>
{{
'科技型中小企业'
}}
</a-tag>
<a-tag
color=
"#6096E6"
v-if=
"baseinfo.tbe_sjmy=='1'"
>
{{
'省级民营科技企业'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.zjtx=='1'"
>
{{
'专精特新'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.zjtg_gjjxjr=='1'"
>
{{
'国家级专精特新小巨人企业'
}}
</a-tag>
<a-tag
color=
"#6096E6"
v-if=
"baseinfo.zjtg_sjxjr=='1'"
>
{{
'省级专精特新小巨人企业'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.dengl=='1'"
>
{{
'瞪羚企业'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.quoted_company=='1'"
>
{{
'上市企业'
}}
</a-tag>
<a-tag
color=
"#56CA95"
v-if=
"baseinfo.isfive=='1'"
>
{{
'中国500强'
}}
</a-tag>
<a-tag
color=
"#6096E6"
v-if=
"baseinfo.sxonhun=='1'"
>
{{
'山西100强'
}}
</a-tag>
</div>
<div
class=
"company_basic"
>
<div>
注册地址:
太原市小店区长风街115号
</div>
<div>
邮箱:
zonghebangong@sxmtcoal.cn
</div>
<div>
联系电话:
0351-4645051
</div>
<div>
官网:
http://www.shanxicoal.cn/
</div>
<div>
注册地址:
{{
baseinfo
.
address
}}
</div>
<div>
邮箱:
{{
baseinfo
.
email
}}
</div>
<div>
联系电话:
{{
baseinfo
.
telephone
}}
</div>
<div>
官网:
{{
baseinfo
.
web_site
}}
</div>
</div>
</div>
<div
class=
"btn_group"
>
<span
@
click=
"openModal"
><img
src=
"@/static/patent/icon-dc.png"
alt=
""
/>
导出
</span>
<span
style=
"cursor: pointer"
@
click=
"openModal"
><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
><img
src=
"@/static/patent/icon-gz-select.png"
alt=
""
/>
已
关注
</span
>
</div>
<a-tabs
v-model:activeKey=
"activeKey"
style=
"background: #fff
;
"
>
<a-tabs
v-model:activeKey=
"activeKey"
style=
"background: #fff"
>
<a-tab-pane
key=
"企业概况"
tab=
"企业概况"
>
<companyProfile></companyProfile>
<companyProfile
:baseinfo=
"baseinfo"
></companyProfile>
</a-tab-pane>
<a-tab-pane
key=
"研发概要"
tab=
"研发概要"
>
<overview></overview>
</a-tab-pane>
<a-tab-pane
key=
"技术合作"
tab=
"技术合作"
>
</a-tab-pane>
<a-tab-pane
key=
"技术合作"
tab=
"技术合作"
>
<cooperation></cooperation>
</a-tab-pane>
<a-tab-pane
key=
"科创能力评价"
tab=
"科创能力评价"
>
<a-tab-pane
key=
"科创能力评价"
tab=
"科创能力评价"
>
<technology></technology>
</a-tab-pane>
</a-tabs>
<a-modal
v-model:visible=
"visible"
title=
"导出"
@
ok=
"daochu(
details
)"
@
ok=
"daochu()"
cancelText=
"取消"
okText=
"确定"
@
onCancel=
"closeModal"
>
<p>
请选择报告格式,请稍后在历史记录里查看
</p>
<p>
报告格式
<span
class=
"PDF"
>
PDF
</span></p>
<a-form
:model=
"formState"
>
<a-form
:model=
"formState"
>
<a-form-item
:name=
"'email'"
label=
"发送给"
:rules=
"[
{ type: 'email',required: true, message: '请输入正确的邮箱' }]"
:rules=
"[
{ type: 'email', required: true, message: '请输入正确的邮箱' },
]"
>
<a-input
v-model:value=
"formState.email"
/>
<a-input
v-model:value=
"formState.email"
placeholder=
"请输入邮箱地址"
/>
</a-form-item>
</a-form>
</a-modal>
</div>
</
template
>
<
script
>
import
EchartsCloud
from
"../../components/EchartsCloud.vue
"
;
import
*
as
echarts
from
"echarts
"
;
import
companyProfile
from
"./companyProfile.vue"
;
import
{
enterpriseDetail
,
exportword
}
from
"../../utils/indexApi.js"
;
import
overview
from
"./overview.vue"
;
import
cooperation
from
"./cooperation.vue"
import
technology
from
"./technology.vue"
import
{
message
}
from
"ant-design-vue"
;
import
cooperation
from
"./cooperation.vue"
;
import
technology
from
"./technology.vue"
;
import
docxtemplater
from
"docxtemplater"
;
import
PizZip
from
"pizzip"
;
import
JSZipUtils
from
"jszip-utils"
;
import
{
saveAs
}
from
"file-saver"
;
import
ImageModule
from
"docxtemplater-image-module-free"
;
export
default
{
name
:
"companyDetails"
,
data
()
{
return
{
formState
:{
email
:
''
formState
:
{
email
:
""
,
},
visible
:
false
,
email
:
""
,
...
...
@@ -104,42 +130,14 @@ 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
:
"提供智能化科技服务,智能仓储,装直径单桩人工智能单钩硬件销售;机械设备研发"
,
},
],
baseinfo
:
{},
};
},
components
:
{
EchartsCloud
,
companyProfile
,
cooperation
,
overview
,
technology
technology
,
},
methods
:
{
openModal
()
{
...
...
@@ -149,11 +147,157 @@ export default {
this
.
visible
=
false
;
},
//返回上一页
backbtn
(){
this
.
$router
.
go
(
-
1
)
}
backbtn
()
{
this
.
$router
.
go
(
-
1
);
},
//页面初始化
init
(
id
)
{
enterpriseDetail
({
id
:
id
}).
then
((
res
)
=>
{
if
(
res
.
code
==
0
)
{
this
.
baseinfo
=
res
.
data
;
}
else
{
message
.
error
(
res
.
msg
);
}
});
},
daochu
()
{
var
that
=
this
;
let
date
=
new
Date
();
var
year
=
date
.
getFullYear
();
var
month
=
date
.
getMonth
()
+
1
;
var
day
=
date
.
getDate
();
month
=
month
>
9
?
month
:
"0"
+
month
;
day
=
day
<
10
?
"0"
+
day
:
day
;
var
today
=
year
+
"年"
+
month
+
"月"
+
day
+
"日"
;
// var chartDom1 = document.getElementById("techAera");
// let myChart1 = null;
// myChart1 = echarts.init(chartDom1);
// // // 第一个echrts
// myChart1.setOption({
// series: [
// {
// type: "wordCloud",
// gridSize: 10,
// sizeRange: [14, 60],
// rotationRange: [0, 0],
// //随机生成字体颜色
// // maskImage: maskImage,
// textStyle: {
// color: function () {
// return (
// "rgb(" +
// Math.round(Math.random() * 255) +
// ", " +
// Math.round(Math.random() * 255) +
// ", " +
// Math.round(Math.random() * 255) +
// ")"
// );
// },
// },
// left: "center",
// top: "center",
// right: null,
// bottom: null,
// width: "200%",
// height: "200%",
// //数据
// data: that.techArr,
// },
// ],
// });
setTimeout
(()
=>
{
// 加setTimeout是为了让echarts渲染完成后生成图片
JSZipUtils
.
getBinaryContent
(
"company.docx"
,
function
(
error
,
content
)
{
// 抛出异常
if
(
error
)
{
throw
error
;
}
const
opts
=
{
centered
:
false
,
fileType
:
"docx"
,
};
opts
.
getImage
=
function
(
tagValue
)
{
if
(
tagValue
.
size
&&
tagValue
.
data
)
{
return
base64DataURLToArrayBuffer
(
tagValue
.
data
);
}
return
base64DataURLToArrayBuffer
(
tagValue
);
};
opts
.
getSize
=
function
(
_
,
tagValue
)
{
if
(
tagValue
.
size
&&
tagValue
.
data
)
{
return
tagValue
.
size
;
}
return
[
630
,
500
];
};
// 创建一个JSZip实例,内容为模板的内容
const
zip
=
new
PizZip
(
content
);
// 创建并加载docxtemplater实例对象
const
doc
=
new
docxtemplater
().
loadZip
(
zip
);
doc
.
setOptions
({
nullGetter
:
function
()
{
//设置空值 undefined 为''
return
""
;
},
});
// 设置图片模块
doc
.
attachModule
(
new
ImageModule
(
opts
));
// 设置模板变量的值
doc
.
setData
({
...
that
.
baseinfo
,
today
,
// image1: myChart1.getDataURL({
// pixelRatio: 5, //导出的图片分辨率比率,默认是1
// backgroundColor: "#fff", //图表背景色
// excludeComponents: ["toolbox"], //忽略组件的列表
// type: "png", //图片类型支持png和jpeg
// }),
});
try
{
// 用模板变量的值替换所有模板变量
doc
.
render
();
}
catch
(
error
)
{
console
.
error
(
"导出报表失败"
);
throw
error
;
}
// 生成一个代表docxtemplater对象的zip文件(不是一个真实的文件,而是在内存中的表示)
let
out
=
doc
.
getZip
().
generate
({
type
:
"blob"
,
mimeType
:
"application/vnd.openxmlformats-officedocument.wordprocessingml.document"
,
});
//formData文件流
// that.blobToBase64(out);
// 将目标文件对象保存为目标类型的文件,并命名
saveAs
(
out
,
`公司详情报告.docx`
);
});
},
1000
);
},
blobToBase64
(
blob
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
const
fileReader
=
new
FileReader
();
fileReader
.
onload
=
(
e
)
=>
{
setTimeout
(
function
()
{
exportword
({
file
:
e
.
target
.
result
}).
then
((
res
)
=>
{});
},
300
);
};
// readAsDataURL
fileReader
.
readAsDataURL
(
blob
);
fileReader
.
onerror
=
()
=>
{
reject
(
new
Error
(
"文件流异常"
));
};
});
},
},
created
()
{
let
id
=
this
.
$route
.
query
.
id
;
this
.
init
(
id
);
},
created
()
{},
};
</
script
>
<
style
lang=
"less"
scoped
>
...
...
@@ -240,9 +384,8 @@ export default {
}
}
}
:deep
(
.ant-tabs
>
.ant-tabs-nav
)
{
:deep
(
.ant-tabs
>
.ant-tabs-nav
)
{
padding-left
:
30px
;
}
}
</
style
>
src/views/company/companyProfile.vue
View file @
1a4a6395
...
...
@@ -11,42 +11,42 @@
:labelStyle=
"
{ background: '#F2F9FC' }"
>
<a-descriptions-item
label=
"法定代表人"
>
Cloud Database
</a-descriptions-item
>
{{
baseinfo
.
legal
}}
</a-descriptions-item
>
<a-descriptions-item
label=
"经营状态"
>
Prepaid
</a-descriptions-item>
<a-descriptions-item
label=
"成立日期"
>
YES
</a-descriptions-item>
<a-descriptions-item
label=
"经营状态"
>
{{
baseinfo
.
status
}}
</a-descriptions-item>
<a-descriptions-item
label=
"成立日期"
>
{{
baseinfo
.
build_date
}}
</a-descriptions-item>
<a-descriptions-item
label=
"工商注册号"
>
2018-04-24 18:00:00
</a-descriptions-item
>
{{
baseinfo
.
register_code
}}
</a-descriptions-item
>
<a-descriptions-item
label=
"注册资本"
>
$80.00
</a-descriptions-item>
<a-descriptions-item
label=
"实缴资本"
>
授权日
</a-descriptions-item>
<a-descriptions-item
label=
"注册资本"
>
{{
baseinfo
.
capital
}}
</a-descriptions-item>
<a-descriptions-item
label=
"实缴资本"
>
{{
baseinfo
.
actual_capital
}}
</a-descriptions-item>
<a-descriptions-item
label=
"统一社会信用代码"
>
授权日
</a-descriptions-item
>
{{
baseinfo
.
social_code
}}
</a-descriptions-item
>
<a-descriptions-item
label=
"纳税人识别号"
>
授权日
</a-descriptions-item
>
{{
baseinfo
.
tax_code
}}
</a-descriptions-item
>
<a-descriptions-item
label=
"组织机构代码"
>
授权日
</a-descriptions-item
>
{{
baseinfo
.
company_code
}}
</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-item
label=
"营业期限"
>
{{
baseinfo
.
from_time
}}
-
{{
baseinfo
.
to_time
}}
</a-descriptions-item>
<a-descriptions-item
label=
"纳税人资质"
>
{{
baseinfo
.
tax_qualification
}}
</a-descriptions-item>
<a-descriptions-item
label=
"核准日期"
>
{{
baseinfo
.
approval_date
}}
</a-descriptions-item>
<a-descriptions-item
label=
"企业类型"
>
{{
baseinfo
.
entype
}}
</a-descriptions-item>
<a-descriptions-item
label=
"行业"
>
{{
baseinfo
.
company_industry
}}
</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-item
label=
"人员规模"
>
{{
baseinfo
.
staff_range
}}
</a-descriptions-item>
<a-descriptions-item
label=
"参保人数"
>
{{
baseinfo
.
bao_num
}}
</a-descriptions-item>
<a-descriptions-item
label=
"登记机关"
>
{{
baseinfo
.
register_org
}}
</a-descriptions-item>
<a-descriptions-item
label=
"曾用名"
>
{{
baseinfo
.
history_name
?
baseinfo
.
history_name
:
'无'
}}
</a-descriptions-item>
<a-descriptions-item
label=
"英文名"
>
{{
baseinfo
.
en_name
}}
</a-descriptions-item>
<a-descriptions-item
label=
""
></a-descriptions-item>
<a-descriptions-item
label=
""
></a-descriptions-item>
<a-descriptions-item
label=
"注册地址"
:span=
"3"
>
注册地址
>
{{
baseinfo
.
address
}}
</a-descriptions-item>
<a-descriptions-item
label=
"经营范围"
:span=
"3"
>
经营范围
</a-descriptions-item
>
{{
baseinfo
.
business_scope
}}
</a-descriptions-item
>
</a-descriptions>
</div>
...
...
@@ -130,6 +130,9 @@
<
script
>
export
default
{
name
:
"companyProfile"
,
props
:{
baseinfo
:
Object
,
},
data
()
{
return
{
activeKey_shareholder
:
"工商登记"
,
...
...
src/views/company/index.vue
View file @
1a4a6395
...
...
@@ -9,11 +9,13 @@
</a-select>
</
template
>
<
template
#
addonAfter
>
<img
style=
"padding-right: 5px"
src=
"@/static/home/index/icon-search.png"
alt=
""
/>
搜索
<div
@
click=
"onsearch"
>
<img
style=
"padding-right: 5px"
src=
"@/static/home/index/icon-search.png"
alt=
""
/>
搜索
</div>
</
template
>
</a-input>
</div>
...
...
@@ -50,14 +52,10 @@
placeholder=
"请选择"
></a-select>
</a-form-item>
<a-form-item
name=
"range-picker"
label=
"注册时间"
v-bind=
"rangeConfig"
>
<a-form-item
name=
"range-picker"
label=
"注册时间"
>
<a-config-provider
:locale=
"zh_CN"
>
<a-range-picker
v-model:value=
"formState['range
-picker
']"
v-model:value=
"formState['range
time1
']"
value-format=
"YYYY-MM-DD"
/>
</a-config-provider>
...
...
@@ -71,17 +69,19 @@
></a-select>
</a-form-item> -->
<a-form-item
label=
"注册资本"
>
<a-input
v-model:value=
"formState.fieldA"
style=
"width: 40%"
placeholder=
"请输入关键词"
/>
<a-input-number
v-model=
"formState.capital_nums_min"
:min=
"0"
style=
"width: 47%"
placeholder=
"请输入数值"
></a-input-number>
-
<a-input
style=
"width: 40%"
v-model:value=
"formState.fieldA"
placeholder=
"请输入关键词"
/>
<a-input-number
v-model=
"formState.capital_nums_max"
:min=
"0"
style=
"width: 47%"
placeholder=
"请输入数值"
></a-input-number>
</a-form-item>
<a-form-item
label=
"企业创新排名"
>
<a-select
...
...
@@ -125,7 +125,7 @@
class=
"card"
v-for=
"item in companylist"
:key=
"item"
@
click=
"openCompany(item.
company_name
)"
@
click=
"openCompany(item.
mysql_id
)"
>
<div
class=
"card_title"
>
{{ item.company_name }}
</div>
<!-- 关注 -->
...
...
@@ -195,7 +195,11 @@
<
script
>
import
dayjs
from
"dayjs"
;
import
arealist
from
"../../utils/map.js"
;
import
{
enterpriseList
,
industryType
}
from
"../../utils/indexApi.js"
;
import
{
enterpriseList
,
industryType
,
enterpriseSelect
,
}
from
"../../utils/indexApi.js"
;
import
"dayjs/locale/zh-cn"
;
import
zh_CN
from
"ant-design-vue/lib/locale-provider/zh_CN"
;
dayjs
.
locale
(
"zh-cn"
);
...
...
@@ -205,8 +209,9 @@ export default {
return
{
zh_CN
,
total
:
0
,
keyword
:
""
,
type
:
""
,
valueArea
:
[],
value2
:
[],
optionsArea
:
[],
valueInnovation
:
""
,
optionsInnovation
:
[
...
...
@@ -220,61 +225,24 @@ export default {
{
label
:
"专精特新小巨人"
,
value
:
"专精特新小巨人"
},
{
label
:
"上市挂牌企业"
,
value
:
"上市挂牌企业"
},
],
optionsindustry
:[],
industry
Type
:
[],
optionsindustry
:
[],
industry
value
:
[],
valueType
:
[],
formState
:
{
layout
:
"horizontal
"
,
fieldA
:
""
,
fieldB
:
""
,
capital_nums_min
:
"
"
,
capital_nums_max
:
""
,
rangetime1
:
[]
,
},
filter
:
[],
companylist
:
[
{
name
:
"山西科达自控股份有限公司"
,
status
:
"存续(在营、开业、在册)"
,
type
:
"高新技术企业"
,
legalRepresentative
:
"郭晓明"
,
registrationTime
:
"2023-6-1"
,
money
:
"222941.42万人民币"
,
code
:
"91140000110014569B"
,
industry
:
"批发和零售业>批发业"
,
address
:
"北京市海淀区西二旗产业园百度大厦28号"
,
follow
:
1
,
},
{
name
:
"山西科达自控股份有限公司"
,
status
:
"存续(在营、开业、在册)"
,
type
:
"高新技术企业"
,
legalRepresentative
:
"郭晓明"
,
registrationTime
:
"2023-6-1"
,
money
:
"222941.42万人民币"
,
code
:
"91140000110014569B"
,
industry
:
"批发和零售业>批发业"
,
address
:
"北京市海淀区西二旗产业园百度大厦28号"
,
follow
:
0
,
},
{
name
:
"山西科达自控股份有限公司"
,
status
:
"存续(在营、开业、在册)"
,
type
:
"高新技术企业"
,
legalRepresentative
:
"郭晓明"
,
registrationTime
:
"2023-6-1"
,
money
:
"222941.42万人民币"
,
code
:
"91140000110014569B"
,
industry
:
"批发和零售业>批发业"
,
address
:
"北京市海淀区西二旗产业园百度大厦28号"
,
follow
:
1
,
},
],
companylist
:
[],
};
},
components
:
{},
methods
:
{
//获取企业列表
getCompanyList
()
{
getCompanyList
(
keyword
)
{
let
params
=
{
keyword
:
this
.
$route
.
params
.
keyword
||
""
,
keyword
:
keyword
||
""
,
page
:
1
,
size
:
10
,
};
...
...
@@ -301,79 +269,171 @@ export default {
});
}
});
console
.
log
(
this
.
optionsindustry
)
});
},
//改变页码
onChange
(
page
)
{
this
.
patentdata
=
[];
//修改省份的格式
let
area
=
[];
if
(
this
.
valueArea
.
length
!=
0
)
{
this
.
valueArea
.
forEach
((
item
)
=>
{
if
(
item
.
length
==
1
)
{
area
.
push
(
item
[
0
]);
}
else
if
(
item
.
length
==
2
)
{
area
.
push
(
item
[
1
]);
}
});
}
//修改国民经济行业的格式
let
company_industry
=
[];
if
(
this
.
industryvalue
.
length
!=
0
)
{
this
.
industryvalue
.
forEach
((
item
)
=>
{
if
(
item
.
length
==
1
)
{
company_industry
.
push
(
item
[
0
]);
}
else
if
(
item
.
length
==
2
)
{
company_industry
.
push
(
item
[
1
]);
}
});
}
this
.
companylist
=
[];
let
params
=
{
page
:
page
,
size
:
10
,
keyword
:
this
.
keyword
?
this
.
keyword
:
null
,
// zl_type: this.value1,
// sqrq_start: this.formState.rangetime1
// ? this.formState.rangetime1[0]
// : null,
// sqrq_end: this.formState.rangetime1
// ? this.formState.rangetime1[1]
// : null,
// gkrq_start: this.formState.rangetime2
// ? this.formState.rangetime2[0]
// : null,
// gkrq_end: this.formState.rangetime2
// ? this.formState.rangetime2[1]
// : null,
// zl_status: this.value2,
area
:
area
,
company_industry
:
company_industry
,
qualification
:
this
.
valueType
,
start_date
:
this
.
formState
.
rangetime1
?
this
.
formState
.
rangetime1
[
0
]
:
null
,
end_date
:
this
.
formState
.
rangetime1
?
this
.
formState
.
rangetime1
[
1
]
:
null
,
capital_nums_min
:
Number
(
this
.
formState
.
capital_nums_min
),
capital_nums_max
:
Number
(
this
.
formState
.
capital_nums_max
),
innovate
:
this
.
valueInnovation
,
};
//请求接口
enterpriseSelect
({
...
params
}).
then
((
res
)
=>
{
console
.
log
(
res
);
if
(
res
.
code
==
0
)
{
this
.
companylist
=
res
.
data
.
list
;
this
.
total
=
res
.
data
.
total
;
}
});
},
//重置筛选
clearvalue
()
{
this
.
valueArea
=
[];
this
.
valueInnovation
=
[];
this
.
valueType
=
[];
this
.
formState
=
{
capital_nums_min
:
""
,
capital_nums_max
:
""
,
rangetime1
:
[],
};
this
.
industryvalue
=
[];
},
//点击筛选
Filter
()
{
this
.
filter
=
[];
//修改省份的格式
let
area
=
[];
if
(
this
.
valueArea
.
length
!=
0
)
{
this
.
valueArea
.
forEach
((
item
)
=>
{
if
(
item
.
length
==
1
)
{
area
.
push
(
item
[
0
]);
}
else
if
(
item
.
length
==
2
)
{
area
.
push
(
item
[
1
]);
}
});
}
// //将筛选条件渲染到页面上
// for (var key in parma) {
// if (key == "keyword") {
// parma.keyword ? this.filter.push(parma.keyword) : "";
// } else if (key == "zl_type") {
// if (this.value1.length != 0) {
// this.value1.forEach((item) => {
// this.filter.push(item);
// });
// }
// } else if (key == "zl_status") {
// if (this.value2.length != 0) {
// this.value2.forEach((item) => {
// this.filter.push(item);
// });
// }
// }
// }
//修改国民经济行业的格式
let
company_industry
=
[];
if
(
this
.
industryvalue
.
length
!=
0
)
{
this
.
industryvalue
.
forEach
((
item
)
=>
{
if
(
item
.
length
==
1
)
{
company_industry
.
push
(
item
[
0
]);
}
else
if
(
item
.
length
==
2
)
{
company_industry
.
push
(
item
[
1
]);
}
});
}
//企业结果
this
.
companylist
=
[];
let
params
=
{
page
:
1
,
size
:
10
,
keyword
:
this
.
keyword
?
this
.
keyword
:
null
,
area
:
area
,
company_industry
:
company_industry
,
qualification
:
this
.
valueType
,
start_date
:
this
.
formState
.
rangetime1
?
this
.
formState
.
rangetime1
[
0
]
:
null
,
end_date
:
this
.
formState
.
rangetime1
?
this
.
formState
.
rangetime1
[
1
]
:
null
,
capital_nums_min
:
Number
(
this
.
formState
.
capital_nums_min
),
capital_nums_max
:
Number
(
this
.
formState
.
capital_nums_max
),
innovate
:
this
.
valueInnovation
,
};
//将筛选条件渲染到页面上//搜索结果标签
let
filter
=
[];
this
.
filter
=
[];
for
(
var
key
in
params
)
{
filter
=
[
...
params
.
area
,
...
params
.
company_industry
,
...
params
.
qualification
,
];
if
(
key
==
"keyword"
)
{
params
.
keyword
?
filter
.
push
(
params
.
keyword
)
:
""
;
}
}
this
.
filter
=
filter
;
//请求接口
enterpriseSelect
({
...
params
}).
then
((
res
)
=>
{
console
.
log
(
res
);
if
(
res
.
code
==
0
)
{
this
.
companylist
=
res
.
data
.
list
;
this
.
total
=
res
.
data
.
total
;
}
});
},
//打开企业详情
openCompany
(
name
)
{
openCompany
(
id
)
{
this
.
$router
.
push
({
path
:
"/companyDetails"
,
query
:
{
name
:
name
,
id
:
id
,
},
});
},
onsearch
()
{
this
.
getCompanyList
(
this
.
keyword
);
},
},
created
()
{
this
.
getCompanyList
();
this
.
getindustryType
();
this
.
optionsArea
=
arealist
;
this
.
keyword
=
this
.
$route
.
query
.
keyword
;
this
.
getCompanyList
(
this
.
keyword
);
this
.
valueInnovation
=
this
.
$route
.
query
.
valueInnovation
;
this
.
type
=
"企业"
;
},
watch
:
{
type
:
function
(
newV
,
oldV
)
{
// console.log(newV)
if
(
newV
==
"专利"
)
{
this
.
$router
.
push
({
path
:
"/patent"
,
});
}
},
},
};
</
script
>
<
style
lang=
"less"
scoped
>
...
...
src/views/home/index.vue
View file @
1a4a6395
...
...
@@ -110,28 +110,26 @@ export default {
this
.
$router
.
push
({
path
:
"/company"
,
});
break
;
case
"首页"
:
this
.
$router
.
push
({
path
:
"/home"
,
});
break
;
case
"专利"
:
this
.
$router
.
push
({
path
:
"/patent"
,
});
break
;
case
"历史记录"
:
this
.
$router
.
push
({
path
:
"/history"
,
});
break
;
case
"我的关注"
:
this
.
$router
.
push
({
path
:
"/follow"
,
});
...
...
@@ -144,26 +142,38 @@ export default {
let
path
=
this
.
$route
.
path
;
switch
(
path
)
{
case
"/company"
||
"/companyDetails"
:
this
.
current
=
"企业"
;
localStorage
.
setItem
(
'current'
,
'企业'
)
this
.
current
=
localStorage
.
getItem
(
"current"
);
break
;
case
"/home"
:
this
.
current
=
"首页"
;
// this.current = "首页";
localStorage
.
setItem
(
'current'
,
'首页'
)
this
.
current
=
localStorage
.
getItem
(
"current"
);
break
;
case
"/patent"
||
"/patentDetails"
:
this
.
current
=
"专利"
;
// this.current = "专利";
localStorage
.
setItem
(
'current'
,
'专利'
)
this
.
current
=
localStorage
.
getItem
(
"current"
);
break
;
case
"/history"
:
this
.
current
=
"历史记录"
;
localStorage
.
setItem
(
'current'
,
'历史记录'
)
this
.
current
=
localStorage
.
getItem
(
"current"
);
break
;
case
"/follow"
:
this
.
current
=
"我的关注"
;
localStorage
.
setItem
(
'current'
,
'我的关注'
)
this
.
current
=
localStorage
.
getItem
(
"current"
);
break
;
}
},
},
mounted
()
{},
mounted
()
{
this
.
current
=
localStorage
.
getItem
(
"current"
);
},
created
()
{
this
.
username
=
this
.
$store
.
state
.
username
;
},
};
</
script
>
...
...
src/views/login/forget.vue
View file @
1a4a6395
...
...
@@ -31,8 +31,8 @@
:model=
"formState"
name=
"normal_login"
class=
"login-form"
@
finish=
"onFinish
"
@
finishFailed=
"onFinishFailed
"
ref=
"form
"
:rules=
"formRules
"
>
<a-form-item
name=
"phone"
...
...
@@ -161,9 +161,39 @@ export default {
password
:
""
,
repassword
:
""
,
},
formRules
:
{
phone
:
[
{
required
:
true
,
message
:
"请输入手机号!"
},
{
pattern
:
/^
(
13
[
0-9
]
|14
[
01456879
]
|15
[
0-35-9
]
|16
[
2567
]
|17
[
0-8
]
|18
[
0-9
]
|19
[
0-35-9
])\d{8}
$/
,
message
:
"手机号格式不正确!"
,
validateTrigger
:
"onBlur"
,
},
],
repassword
:
[
{
required
:
true
,
message
:
"请输入密码!"
},
{
validator
:
this
.
validateConfirmPassword
,
message
:
"两次密码不匹配"
,
},
],
code
:
[{
required
:
true
,
message
:
"请输入验证码!"
}],
password
:
[{
required
:
true
,
message
:
"请输入密码!"
}],
},
};
},
methods
:
{
//验证两次密码
validateConfirmPassword
(
rule
,
value
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
if
(
value
&&
value
!==
this
.
formState
.
newpwd
)
{
reject
(
new
Error
());
}
else
{
resolve
();
}
});
},
//发送验证码
sendCode
()
{
if
(
this
.
formState
.
phone
)
{
...
...
@@ -178,7 +208,10 @@ export default {
this
.
RemainingTime
=
TIME_COUNT
;
this
.
isSend
=
true
;
this
.
timer
=
setInterval
(()
=>
{
if
(
this
.
RemainingTime
>
0
&&
this
.
RemainingTime
<=
TIME_COUNT
)
{
if
(
this
.
RemainingTime
>
0
&&
this
.
RemainingTime
<=
TIME_COUNT
)
{
this
.
RemainingTime
--
;
}
else
{
this
.
isSend
=
false
;
...
...
@@ -197,22 +230,31 @@ export default {
},
//reset
reset
()
{
let
param
=
AES_Encrypt
(
JSON
.
stringify
({
phone
:
this
.
formState
.
phone
,
code
:
this
.
formState
.
code
,
password
:
this
.
formState
.
password
,
re_password
:
this
.
formState
.
repassword
,
this
.
$refs
.
form
.
validate
()
.
then
((
values
)
=>
{
let
param
=
AES_Encrypt
(
JSON
.
stringify
({
phone
:
this
.
formState
.
phone
,
code
:
this
.
formState
.
code
,
password
:
this
.
formState
.
password
,
re_password
:
this
.
formState
.
repassword
,
})
);
changePassword
({
param
}).
then
((
res
)
=>
{
// console.log(res)
if
(
res
.
code
==
0
)
{
this
.
resetShow
=
true
;
}
else
{
message
.
error
(
res
.
msg
);
}
});
})
);
changePassword
({
param
}).
then
((
res
)
=>
{
// console.log(res)
if
(
res
.
code
==
0
)
{
this
.
resetShow
=
true
;
}
else
{
message
.
error
(
res
.
msg
);
}
});
.
catch
((
err
)
=>
{
// console.log(err);
return
false
;
// 处理验证失败的情况
});
},
tologin
()
{
this
.
$router
.
push
({
...
...
src/views/patent/index.vue
View file @
1a4a6395
...
...
@@ -8,12 +8,15 @@
<a-select-option
value=
"专利"
>
查专利
</a-select-option>
</a-select>
</
template
>
<
template
#
addonAfter
>
<img
<
template
#
addonAfter
>
<div
@
click=
"onsearch"
>
<img
style=
"padding-right: 5px"
src=
"@/static/home/index/icon-search.png"
alt=
""
/>
搜索
</div>
</
template
>
</a-input>
</div>
...
...
@@ -131,6 +134,7 @@ export default {
data
()
{
return
{
zh_CN
,
type
:
''
,
value1
:
[],
value2
:
[],
keyword
:
""
,
...
...
@@ -188,9 +192,9 @@ export default {
components
:
{},
methods
:
{
//获取页面的表格
getList
()
{
getList
(
keyword
)
{
let
params
=
{
keyword
:
this
.
$route
.
params
.
keyword
||
""
,
keyword
:
keyword
||
this
.
$route
.
query
.
keyword
,
page
:
1
,
size
:
10
,
};
...
...
@@ -205,6 +209,9 @@ export default {
}
});
},
onsearch
(){
this
.
getList
(
this
.
keyword
)
},
//改变页码
onChange
(
page
)
{
this
.
patentdata
=
[];
...
...
@@ -246,7 +253,9 @@ export default {
},
//点击筛选
Filter
()
{
//搜索结果标签
this
.
filter
=
[];
//专利列表
this
.
patentdata
=
[];
let
parma
=
{
page
:
1
,
...
...
@@ -312,10 +321,19 @@ export default {
};
},
},
watch
:
{
type
:
function
(
newV
,
oldV
)
{
// console.log(newV)
if
(
newV
==
"企业"
)
{
this
.
$router
.
push
({
path
:
"/company"
,
});
}
},
},
created
()
{
this
.
getList
();
this
.
keyword
=
this
.
$route
.
query
.
keyword
;
this
.
getList
(
this
.
keyword
);
this
.
type
=
"专利"
;
},
computed
:
{},
...
...
src/views/userset/securitySetting.vue
View file @
1a4a6395
...
...
@@ -7,49 +7,168 @@
</a-breadcrumb>
<!-- 安全设置-->
<div
class=
"personal_set"
>
<a-form
:model=
"formState"
name=
"basic"
:label-col=
"
{ span: 2 }"
:wrapper-col="{ span: 5 }"
autocomplete="off"
>
<a-form-item
label=
"手机号"
name=
"img"
class=
"header_label"
>
<a-input
v-model:value=
"formState.phone"
/>
</a-form-item>
<a-form-item
label=
"验证码"
name=
"code"
>
<a-input
v-model:value=
"formState.code"
/>
</a-form-item>
<h2
class=
"title"
>
安全设置
</h2>
<a-form
:model=
"formState"
name=
"basic"
:label-col=
"
{ span: 2 }"
:wrapper-col="{ span: 5 }"
autocomplete="off"
ref="form"
:rules="formRules"
>
<a-form-item
label=
"手机号"
name=
"phone"
>
<a-input
v-model:value=
"formState.phone"
placeholder=
"请输入手机号"
/>
</a-form-item>
<a-form-item
label=
"验证码"
name=
"code"
>
<a-input
v-model:value=
"formState.code"
placeholder=
"请输入验证码"
>
<template
#
suffix
>
<span
v-show=
"!isSend"
class=
"code"
@
click=
"sendCode"
>
获取验证码
</span
>
<span
v-show=
"isSend"
class=
"code"
>
{{
RemainingTime
}}
秒后重新获取
</span>
</
template
>
</a-input>
</a-form-item>
<a-form-item
label=
"新密码"
name=
"newpwd"
>
<a-input
v-model:value=
"formState.newpwd"
/>
</a-form-item>
<a-form-item
label=
"确认密码"
name=
"renewpwd"
>
<a-input
v-model:value=
"formState.renewpwd"
/>
</a-form-item>
<div
class=
"save_btn"
>
<a-button
type=
"primary"
html-type=
"submit"
@
click=
"save"
>
保存
</a-button>
</div>
</a-form>
</div>
<a-form-item
label=
"新密码"
name=
"newpwd"
>
<a-input-password
v-model:value=
"formState.newpwd"
placeholder=
"请输入新密码"
/>
</a-form-item>
<a-form-item
label=
"确认密码"
name=
"renewpwd"
>
<a-input-password
v-model:value=
"formState.renewpwd"
placeholder=
"请再次输入新密码"
/>
</a-form-item>
<div
class=
"save_btn"
>
<a-button
type=
"primary"
html-type=
"submit"
@
click=
"reset"
>
保存
</a-button>
</div>
</a-form>
</div>
</div>
</template>
<
script
>
import
{
AES_Encrypt
,
AES_Decrypt
}
from
"@/utils/aes_util.js"
;
import
{
message
}
from
"ant-design-vue"
;
import
{
changePassword
,
sendSms
}
from
"@/utils/loginAPI"
;
export
default
{
name
:
"securitySetting"
,
data
(){
return
{
formState
:{
phone
:
''
,
code
:
''
,
newpwd
:
''
,
renewpwd
:
''
data
()
{
return
{
isSend
:
""
,
RemainingTime
:
0
,
formState
:
{
phone
:
""
,
code
:
""
,
newpwd
:
""
,
renewpwd
:
""
,
},
formRules
:
{
phone
:
[
{
required
:
true
,
message
:
"请输入手机号!"
},
{
pattern
:
/^
(
13
[
0-9
]
|14
[
01456879
]
|15
[
0-35-9
]
|16
[
2567
]
|17
[
0-8
]
|18
[
0-9
]
|19
[
0-35-9
])\d{8}
$/
,
message
:
"手机号格式不正确!"
,
validateTrigger
:
"onBlur"
,
},
],
renewpwd
:
[
{
required
:
true
,
message
:
"请输入密码!"
},
{
validator
:
this
.
validateConfirmPassword
,
message
:
"两次密码不匹配"
,
},
],
code
:
[{
required
:
true
,
message
:
"请输入验证码!"
}],
newpwd
:
[{
required
:
true
,
message
:
"请输入密码!"
}],
},
};
},
methods
:
{
//验证两次密码
validateConfirmPassword
(
rule
,
value
)
{
return
new
Promise
((
resolve
,
reject
)
=>
{
if
(
value
&&
value
!==
this
.
formState
.
newpwd
)
{
reject
(
new
Error
());
}
else
{
resolve
();
}
});
},
//发送验证码
sendCode
()
{
if
(
this
.
phone
)
{
sendSms
({
phone
:
this
.
phone
}).
then
((
res
)
=>
{
// console.log(res)
if
(
res
.
code
==
0
)
{
this
.
isSend
=
true
;
const
TIME_COUNT
=
60
;
message
.
success
(
res
.
msg
);
//获取验证码倒计时
if
(
!
this
.
timer
)
{
this
.
RemainingTime
=
TIME_COUNT
;
this
.
isSend
=
true
;
this
.
timer
=
setInterval
(()
=>
{
if
(
this
.
RemainingTime
>
0
&&
this
.
RemainingTime
<=
TIME_COUNT
)
{
this
.
RemainingTime
--
;
}
else
{
this
.
isSend
=
false
;
clearInterval
(
this
.
timer
);
this
.
timer
=
null
;
}
},
1000
);
}
}
else
{
message
.
error
(
res
.
msg
);
}
});
}
else
{
message
.
error
(
"请先输入手机号"
);
}
}
}
},
//reset
reset
()
{
this
.
$refs
.
form
.
validate
()
.
then
((
values
)
=>
{
let
param
=
AES_Encrypt
(
JSON
.
stringify
({
phone
:
this
.
formState
.
phone
,
code
:
this
.
formState
.
code
,
password
:
this
.
formState
.
newpwd
,
re_password
:
this
.
formState
.
renewpwd
,
})
);
changePassword
({
param
}).
then
((
res
)
=>
{
// console.log(res)
if
(
res
.
code
==
0
)
{
this
.
resetShow
=
true
;
}
else
{
message
.
error
(
res
.
msg
);
}
});
})
.
catch
((
err
)
=>
{
// console.log(err);
return
false
;
// 处理验证失败的情况
});
},
},
};
</
script
>
...
...
@@ -70,11 +189,23 @@ export default {
height
:
calc
(
100%
-
80px
);
background-color
:
#fff
;
padding
:
40px
40px
;
.title
{
color
:
#1c1c28
;
font-size
:
18px
;
font-family
:
Microsoft
YaHei
UI-Bold
,
Microsoft
YaHei
UI
;
font-weight
:
bold
;
margin-left
:
4%
;
line-height
:
28px
;
margin-bottom
:
2%
;
}
.code
{
color
:
#3e7bfa
;
cursor
:
pointer
;
}
}
.save_btn
{
padding-left
:
150px
;
padding-top
:
20px
;
}
padding-left
:
150px
;
padding-top
:
20px
;
}
}
</
style
>
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment