Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
G
gs1
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
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
吴迪
gs1
Commits
ed49a07c
Commit
ed49a07c
authored
Feb 27, 2022
by
Tang
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat: 境内码查询链接修改
parent
ae9b3cd3
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
20 additions
and
20 deletions
+20
-20
internal.vue
src/views/Search/internal.vue
+20
-20
No files found.
src/views/Search/internal.vue
View file @
ed49a07c
...
@@ -394,7 +394,7 @@ export default {
...
@@ -394,7 +394,7 @@ export default {
}
else
{
}
else
{
this
.
searchCodeShow
=
this
.
companySearch
.
address
;
this
.
searchCodeShow
=
this
.
companySearch
.
address
;
}
}
if
(
this
.
hasSpecialString
(
this
.
searchCodeShow
))
{
if
(
this
.
hasSpecialString
(
this
.
searchCodeShow
))
{
return
true
return
true
}
}
this
.
showResult
=
true
;
this
.
showResult
=
true
;
...
@@ -425,26 +425,26 @@ export default {
...
@@ -425,26 +425,26 @@ export default {
if
(
!
this
.
productSearch
.
code
)
{
if
(
!
this
.
productSearch
.
code
)
{
return
this
.
$message
.
error
(
'请输入商品条码'
);
return
this
.
$message
.
error
(
'请输入商品条码'
);
}
}
if
(
this
.
hasSpecialString
(
this
.
productSearch
.
code
))
{
if
(
this
.
hasSpecialString
(
this
.
productSearch
.
code
))
{
return
true
return
true
}
}
this
.
showResult
=
true
;
//
this.showResult = true;
this
.
resultType
=
'product'
;
//
this.resultType = 'product';
const
params
=
{
code
:
this
.
productSearch
.
code
};
//
const params = {code: this.productSearch.code};
const
searchGlnRes
=
await
this
.
$api
.
search
.
searchInternalProduct
(
params
);
//
const searchGlnRes = await this.$api.search.searchInternalProduct(params);
if
(
searchGlnRes
.
returnCode
===
"0"
)
{
//
if (searchGlnRes.returnCode === "0") {
const
a
=
document
.
createElement
(
'a'
)
//
const a = document.createElement('a')
a
.
setAttribute
(
'href'
,
searchGlnRes
.
data
)
//
a.setAttribute('href', searchGlnRes.data)
// a.setAttribute('target', '_blank')
//
// a.setAttribute('target', '_blank')
a
.
setAttribute
(
'id'
,
'cow-link-temp'
)
//
a.setAttribute('id', 'cow-link-temp')
document
.
body
.
appendChild
(
a
)
//
document.body.appendChild(a)
a
.
click
()
//
a.click()
}
else
{
//
} else {
this
.
errorMsg
=
//
this.errorMsg =
searchGlnRes
.
returnMsg
||
//
searchGlnRes.returnMsg ||
"没有符合条件的记录!"
;
//
"没有符合条件的记录!";
this
.
result
=
null
;
//
this.result = null;
}
//
}
// const a = document.createElement('a')
// const a = document.createElement('a')
// a.setAttribute('href', `/internal_code_search/searchResult2.aspx?keyword=${this.productSearch.code}`)
// a.setAttribute('href', `/internal_code_search/searchResult2.aspx?keyword=${this.productSearch.code}`)
// // a.setAttribute('target', '_blank')
// // a.setAttribute('target', '_blank')
...
@@ -452,7 +452,7 @@ export default {
...
@@ -452,7 +452,7 @@ export default {
// document.body.appendChild(a)
// document.body.appendChild(a)
// a.click()
// a.click()
// document.body.removeChild(document.getElementById('cow-link-temp'))
// document.body.removeChild(document.getElementById('cow-link-temp'))
// window.open(`http://search.anccnet.com/searchResult2.aspx?
keyword=${this.productSearch.code}`, '_blank')
window
.
open
(
`https://www.gds.org.cn/#/barcodeList/index?type=barcode&
keyword=
${
this
.
productSearch
.
code
}
`
,
'_blank'
)
}
}
// this.showResult = true;
// this.showResult = true;
...
...
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