Commit 42e48b9a by tang

feat: GLN查询问题

parent 71b9983e
......@@ -6,29 +6,30 @@
<el-form label-position="left" label-width="200px" :model="search">
<el-form-item label="参与方位置编码(GLN)查询:">
<el-input
v-model="search.code"
placeholder="请输入13位GLN编码!"
class="w240"
v-model="search.code"
placeholder="请输入13位GLN编码!"
class="w240"
></el-input>
</el-form-item>
<el-form-item label="验证码:">
<div class="y-center">
<el-input
v-model="search.captcha"
placeholder="请输入验证码"
class="w160"
v-model="search.captcha"
placeholder="请输入验证码"
class="w160"
></el-input>
<div class="validate-code">
<img :src="captchaPath" @click="getCaptcha()" alt="" />
<img :src="captchaPath" @click="getCaptcha()" alt=""/>
</div>
<el-button
style="margin-left: 40px"
type="primary"
@click="handleSearch"
>查询</el-button
style="margin-left: 40px"
type="primary"
@click="handleSearch"
>查询
</el-button
>
</div>
</el-form-item>
......@@ -43,11 +44,11 @@
header-cell-class-name="search-table-hc"
style="width: 100%"
>
<el-table-column prop="gepirRequestedKey.requestedKeyValue" label="GLN" width="180"> </el-table-column>
<el-table-column prop="gepirRequestedKey.requestedKeyValue" label="GLN" width="180"></el-table-column>
<el-table-column prop="address.name" label="企业名称(含英文)" width="180">
</el-table-column>
<el-table-column prop="address.streetAddressOne" label="中文地址"></el-table-column>
<el-table-column prop="status" label="英文地址"> </el-table-column>
<el-table-column prop="status" label="英文地址"></el-table-column>
</el-table>
</template>
<span style="color: rgb(255, 59, 48)" v-else>{{ errorMsg }}</span>
......@@ -58,7 +59,7 @@
<div class="notice">
<div class="title">友情提示</div>
<div class="content-wrapper">
<img src="./img/query-external-barcode.png" align="right" alt="" />
<img src="./img/query-external-barcode.png" align="right" alt=""/>
<p>
参与方位置编码(Global Location
Number)是对参与供应链等活动的法律实体、功能实体和物理实体进行唯一标识的代码,用13位数字表示,主要应用于条码符号自动识别与数据采集和电子数据交换
......@@ -80,7 +81,7 @@
</template>
<script>
import { getUUID } from "@/utils/utils";
import {getUUID} from "@/utils/utils";
export default {
data() {
......@@ -117,15 +118,19 @@ export default {
async handleSearch() {
this.searchCodeShow = this.search.code;
this.showResult = true;
const params = { ...this.search };
const params = {...this.search};
const searchGlnRes = await this.$api.search.searchGln(params);
const { returnCode, data } = searchGlnRes;
const {returnCode, data} = searchGlnRes;
if (returnCode === "0") {
this.result = [data];
if (data.returnCode === '0') {
this.result = [data];
} else {
this.errorMsg = "暂无数据";
}
} else {
this.errorMsg =
searchGlnRes.returnMsg ||
"您输入的商品条码格式不正确,请确认后重试。";
searchGlnRes.returnMsg ||
"您输入的商品条码格式不正确,请确认后重试。";
this.result = null;
}
this.getCaptcha()
......@@ -141,6 +146,7 @@ export default {
width: 70px;
height: 40px;
margin-left: 11px;
> img {
width: 100%;
height: 100%;
......@@ -155,12 +161,14 @@ export default {
width: 240px;
}
}
.content-wrapper {
> p {
&:nth-child(2), &:nth-child(3), &:nth-child(4) {
text-indent: 28px;
}
}
> div {
margin-top: 20px;
padding: 20px;
......
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