Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
S
source-trace-manage-go
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
JIRA
JIRA
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Registry
Registry
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
Tracing
source-trace-manage-go
Commits
659aed30
Commit
659aed30
authored
Mar 19, 2021
by
zenglun
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
修改部分代码
parent
3aa0e826
Show whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
151 additions
and
19 deletions
+151
-19
copyGoods.vue
src/entry/gs/components/copyGoods/copyGoods.vue
+131
-0
productList.vue
src/entry/gs/components/productList/productList.vue
+1
-1
editTemplate.vue
src/entry/gs/views/editTemplate/editTemplate.vue
+19
-18
No files found.
src/entry/gs/components/copyGoods/copyGoods.vue
0 → 100644
View file @
659aed30
<
template
>
<div
class=
"category-add"
>
<h2
class=
"dialog_add-title"
>
创建副本
</h2>
<dialog-input
class=
"dialog_add-form dialog_add-input_name"
v-model=
"name"
:errorShowing=
"isErrorShowing"
placeholder=
"请输入新的存证名称"
/>
<button
class=
"dialog_add-btn_confirm"
@
click=
"checkForm"
>
确定
</button>
<button
class=
"dialog_add-btn_cancel"
@
click=
"closeDialog"
>
取消
</button>
</div>
</
template
>
<
script
>
import
DialogInput
from
"@/components/DialogInput.vue"
;
import
{
GO_URLS
}
from
"@/config/URLS"
;
export
default
{
components
:
{
DialogInput
,
},
data
()
{
return
{
isErrorShowing
:
false
,
isInActive
:
false
,
name
:
""
,
};
},
props
:
[
"Copydetails"
],
methods
:
{
// 关闭弹窗
async
closeDialog
()
{
this
.
$emit
(
"close"
,
{});
},
// 确认按钮
async
checkForm
()
{
if
(
this
.
isInActive
)
return
;
this
.
isInActive
=
true
;
this
.
isErrorShowing
=
true
;
// 追加非空验证
if
(
this
.
name
.
trim
().
length
===
0
)
{
this
.
$message
.
error
(
"存证名称不可为空"
);
this
.
isInActive
=
false
;
return
null
;
}
let
newNote
=
JSON
.
parse
(
this
.
Copydetails
.
note
);
let
newDetail
=
JSON
.
parse
(
this
.
Copydetails
.
detail
);
newNote
.
evidenceName
=
this
.
name
;
for
(
let
index
=
0
;
index
<
newDetail
.
length
;
index
++
)
{
const
element
=
newDetail
[
index
];
if
(
element
.
data
&&
element
.
data
.
length
===
0
)
{
newDetail
.
splice
(
index
,
1
);
}
if
(
element
.
label
===
"ext"
)
{
element
.
data
[
0
].
data
.
value
=
this
.
name
;
}
}
let
params
=
{
note
:
JSON
.
stringify
(
newNote
),
detail
:
JSON
.
stringify
(
newDetail
),
name
:
this
.
name
,
};
const
res
=
await
this
.
$ajax
({
type
:
"post"
,
url
:
GO_URLS
.
add
,
params
:
params
,
});
if
(
res
)
{
this
.
$message
({
message
:
"创建副本成功"
,
type
:
"success"
,
});
this
.
closeDialog
();
this
.
$emit
(
"update"
);
}
this
.
isInActive
=
false
;
},
},
};
</
script
>
<
style
scoped
lang=
"less"
>
.category-add {
padding: 34px 50px 0 50px;
height: 245px; /* 325px - 34px */
width: 500px; /* 600px - 100px */
}
.dialog_add-title {
margin: 0;
color: #000;
font-size: 22px;
line-height: 30px;
}
.dialog_add-select_subject {
margin-top: 29px;
}
.dialog_add-input_name {
margin: 42px 0 34px 0;
}
.dialog_add-btn_confirm {
float: right;
width: 120px;
height: 40px;
color: #fff;
font-size: 14px;
outline: none;
background: #0CC399;
border-radius: 4px;
border: none;
cursor: pointer;
}
.dialog_add-btn_cancel {
float: right;
margin-right: 18px; /* 28 - 10 */
border: none;
width: 48px; /* 28 + 增大20 */
height: 40px;
outline: none;
background: #fff;
color: #5c6476;
font-size: 14px;
cursor: pointer;
}
</
style
>
src/entry/gs/components/productList/productList.vue
View file @
659aed30
...
...
@@ -123,7 +123,7 @@ import Increments from "../increment/increment.vue"; // 增量
import
AddGoods
from
"@/components/category/addGoods.vue"
;
// 添加存证
import
deleteGoods
from
"@/components/category/deleteGoods.vue"
;
// 删除组件
import
Uncertified
from
"@/components/Uncertified.vue"
;
// 未认证提示组件
import
copyGoods
from
"
@/components/newProductList
/copyGoods.vue"
;
import
copyGoods
from
"
../../components/copyGoods
/copyGoods.vue"
;
import
prompt
from
"../prompt/prompt.vue"
;
export
default
{
...
...
src/entry/gs/views/editTemplate/editTemplate.vue
View file @
659aed30
...
...
@@ -191,11 +191,11 @@
@
cancel=
"modifyFormsShow = false"
></modify-presentation>
</common-dialog>
<uncertified
<
!--
<
uncertified
v-if=
"showUncertified"
@
confirm=
"showUncertified = false"
@
cancel=
"UncertifiedConfirm"
></uncertified>
></uncertified>
-->
<common-dialog
v-if=
"ClassificationPopups"
@
closePopup=
"ClassificationPopups = false"
showMask
>
<choose-classification
@
successCallback=
"successCallback"
...
...
@@ -273,7 +273,7 @@ export default class editTemplate extends Vue {
public
isShowAddRootDialog
:
boolean
=
false
;
public
displayData
:
any
=
[];
public
TemplateType
:
number
=
0
;
public
showUncertified
:
Boolean
=
false
;
//
public showUncertified: Boolean = false;
public
ClassificationPopups
:
boolean
=
false
;
public
MemoryCardType
:
String
=
""
;
//存证类型
// 系统模板>建立个人模板or建立存证
...
...
@@ -691,6 +691,7 @@ export default class editTemplate extends Vue {
}
});
if
(
res
)
{
this
.
personalTemplateId
=
res
.
data
.
id
;
this
.
$message
({
message
:
"创建成功"
,
type
:
"success"
...
...
@@ -833,21 +834,21 @@ export default class editTemplate extends Vue {
this
.
isInActive
=
false
;
}
// 上链
async
UpperChain
()
{
const
res
=
await
this
.
$ajax
({
type
:
"get"
,
url
:
GO_URLS
.
user
+
`/`
+
JSON
.
parse
(
String
(
sessionStorage
.
getItem
(
"user"
))).
id
});
if
(
res
)
{
if
(
res
.
data
.
auth_suc
===
1
)
{
UpperChain
()
{
//
const res = await this.$ajax({
//
type: "get",
//
url:
//
GO_URLS.user +
//
`/` +
//
JSON.parse(String(sessionStorage.getItem("user"))).id
//
});
//
if (res) {
//
if (res.data.auth_suc === 1) {
this
.
isShowToChainDialog
=
true
;
}
else
{
this
.
showUncertified
=
true
;
}
}
//
} else {
//
this.showUncertified = true;
//
}
//
}
}
// 跳转个人中心
UncertifiedConfirm
()
{
...
...
@@ -1281,7 +1282,7 @@ export default class editTemplate extends Vue {
width: 17px;
height: 69px;
line-height: 69px;
background: #0
CC
399;
background: #0
cc
399;
border-radius: 7px 0 0 7px;
cursor: pointer;
}
...
...
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