Commit d0d101ba by Tang

feat: 境内条码查询完善

parent 63b6e695
<template> <template>
<div class="container marginTop20 mb-4" style="position: relative"> <div class="nav-search container marginTop20 mb-4" style="position: relative">
<breadcrumb/> <breadcrumb/>
<div class="row"> <div class="row">
<div class="col-lg-3"> <div class="col-lg-3">
......
...@@ -39,11 +39,8 @@ ...@@ -39,11 +39,8 @@
</el-form-item> </el-form-item>
<el-form-item label="验证码:"> <el-form-item label="验证码:">
<el-button type="primary" class="w240"> <el-button type="primary" class="w240" icon="gs-guard-icon">
<div style="diplay:flex;align-item:center"> 点击此处进行验证
<img style="height:14px" src="./img/guard.png" alt=""/>
点击此处进行验证
</div>
</el-button> </el-button>
<el-button style="margin-left:40px" type="primary" @click="handleSearchCompany" <el-button style="margin-left:40px" type="primary" @click="handleSearchCompany"
>查询 >查询
...@@ -76,7 +73,7 @@ ...@@ -76,7 +73,7 @@
点击此处进行验证 点击此处进行验证
</div> </div>
</el-button> </el-button>
<el-button style="margin-left:40px" type="primary" <el-button style="margin-left:40px" type="primary" @click="handleSearchProduct"
>查询 >查询
</el-button </el-button
> >
...@@ -85,11 +82,47 @@ ...@@ -85,11 +82,47 @@
</el-tab-pane> </el-tab-pane>
</el-tabs> </el-tabs>
<!--查询结果-->
<div class="result-box" v-if="showResult&&activeName==='first'"> <div class="result-box" v-if="showResult&&activeName==='first'">
<div class="result-box-title">查询 {{ searchCodeShow }} 结果</div> <div class="result-box-title">查询 {{ searchCodeShow }} 结果</div>
<div class="result-box-body"> <div class="result-box-body">
<template v-if="result"> <template v-if="result">
<!--结果表格--> <!--结果表格-->
<el-table
:data="result"
header-cell-class-name="search-table-hc"
border
style="width: 100%">
<el-table-column
prop="id"
label="厂商识别代码"
width="180">
<template slot-scope="scope">
<span type="text" class="hover" size="small">{{ scope.row.id }}</span>
</template>
</el-table-column>
<el-table-column
prop="name"
label="厂商名称"
width="180">
</el-table-column>
<el-table-column
prop="status"
label="状态">
</el-table-column>
<el-table-column
label="详细">
<template>
<span type="text" class="hover pointer" @click="handleCheck()" size="small">详情</span>
</template>
</el-table-column>
<el-table-column
label="查看">
<template>
<span type="text" class="hover pointer" @click="handleCheck()" size="small">查看</span>
</template>
</el-table-column>
</el-table>
</template> </template>
<span v-else>没有符合条件的记录!</span> <span v-else>没有符合条件的记录!</span>
</div> </div>
...@@ -142,16 +175,40 @@ export default { ...@@ -142,16 +175,40 @@ export default {
}; };
}, },
methods: { methods: {
// 查看按钮
handleCheck(row) {
console.log(row)
},
// 详情按钮
handleDetail(row) {
console.log(row)
},
handleSearchCompany() { handleSearchCompany() {
this.showResult = true; this.showResult = true;
if (this.company === CODE) { if (this.company === CODE) {
this.searchCodeShow = this.companySearch.code; this.searchCodeShow = this.companySearch.code;
if (this.companySearch.code === '1') {
this.result = [
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
{id: '6912614', name: '北京阿里巴巴食品有限公司', 状态: "已注销"},
]
}
} else if (this.company === NAME) { } else if (this.company === NAME) {
this.searchCodeShow = this.companySearch.name; this.searchCodeShow = this.companySearch.name;
} else { } else {
this.searchCodeShow = this.companySearch.address; this.searchCodeShow = this.companySearch.address;
} }
} },
handleSearchProduct() {
window.open(`http://search.anccnet.com/searchResult2.aspx?keyword=${this.productSearch.code}`)
},
}, },
}; };
</script> </script>
...@@ -160,4 +217,13 @@ export default { ...@@ -160,4 +217,13 @@ export default {
.w240 { .w240 {
width: 240px; width: 240px;
} }
.gs-guard-icon {
display: inline-block;
margin-bottom: -1px;
width: 14px;
height: 12px;
background: url("./img/guard.png") center no-repeat;
background-size: 14px 14px;
}
</style> </style>
...@@ -3,6 +3,7 @@ ...@@ -3,6 +3,7 @@
background: #ffffff; background: #ffffff;
border-radius: 4px; border-radius: 4px;
border: 1px solid #c5d8ee; border: 1px solid #c5d8ee;
> .title { > .title {
padding: 20px 30px; padding: 20px 30px;
font-size: 18px; font-size: 18px;
...@@ -15,29 +16,36 @@ ...@@ -15,29 +16,36 @@
.el-tabs__item { .el-tabs__item {
color: #454545; color: #454545;
} }
.el-form-item__label { .el-form-item__label {
color: #414345; color: #414345;
} }
.body { .body {
padding: 20px 30px; padding: 20px 30px;
} }
.notice { .notice {
padding: 20px 30px; padding: 20px 30px;
background: rgba(242, 99, 53, 0.03); background: rgba(242, 99, 53, 0.03);
border-radius: 0px 0px 2px 2px; border-radius: 0px 0px 2px 2px;
> .title { > .title {
font-size: 16px; font-size: 16px;
font-weight: 500; font-weight: 500;
color: #f26335; color: #f26335;
line-height: 22px; line-height: 22px;
} }
.content-wrapper { .content-wrapper {
margin-top: 29px; margin-top: 29px;
font-size: 14px; font-size: 14px;
font-weight: 400; font-weight: 400;
p + p { p + p {
margin-top: 30px; margin-top: 30px;
} }
img { img {
width: 113px; width: 113px;
margin-left: 30px; margin-left: 30px;
...@@ -52,6 +60,7 @@ ...@@ -52,6 +60,7 @@
color: #414345; color: #414345;
line-height: 28px; line-height: 28px;
} }
.result-box-title { .result-box-title {
height: 40px; height: 40px;
padding: 0 20px; padding: 0 20px;
...@@ -61,6 +70,7 @@ ...@@ -61,6 +70,7 @@
color: #f26335; color: #f26335;
background: #fef1ec; background: #fef1ec;
} }
.result-box-body { .result-box-body {
border: 1px solid #ebebeb; border: 1px solid #ebebeb;
border-top: none; border-top: none;
...@@ -88,3 +98,24 @@ ...@@ -88,3 +98,24 @@
} }
} }
} }
.nav-search {
.el-tabs__item.is-active {
color: #04408D;
}
.el-table .search-table-hc{
background: #F5F5F5;
padding: 0;
height: 40px;
overflow: hidden;
}
.hover{
color: #008dbd;
&:hover{
color: #008dbd;
}
}
}
...@@ -161,6 +161,7 @@ export default { ...@@ -161,6 +161,7 @@ export default {
.el-menu.gs-subnav { .el-menu.gs-subnav {
border-right: none; border-right: none;
background: $side-bg-color; background: $side-bg-color;
margin-bottom: 20px;
.el-submenu__title { .el-submenu__title {
background: $side-bg-color; background: $side-bg-color;
......
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