Skip to content
GitLab
Projects
Groups
Snippets
Help
Loading...
Help
Help
Support
Keyboard shortcuts
?
Submit feedback
Sign in
Toggle navigation
Q
qk_admin
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Analytics
Analytics
CI / CD
Repository
Value Stream
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
quanku
qk_admin
Commits
bfa397f6
Commit
bfa397f6
authored
Jul 31, 2023
by
yaya
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
feat:优化合成图
parent
0a9bbef0
Changes
2
Show whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
3 additions
and
3 deletions
+3
-3
src/views/goods/components/CutEditImageDialog.vue
src/views/goods/components/CutEditImageDialog.vue
+1
-1
src/views/goods/infoSet.vue
src/views/goods/infoSet.vue
+2
-2
No files found.
src/views/goods/components/CutEditImageDialog.vue
View file @
bfa397f6
...
...
@@ -15,7 +15,7 @@
<!--
<div>
第二步:对去完水印的图片进行抠图
</div>
-->
<div
v-if=
"!imageBase64 || isCancel"
class=
"select"
>
<el-button
style=
"width: 95px"
@
click=
"handleRemoveLama"
>
去水印
</el-button>
<el-button
style=
"width:
150px;margin-top: 20px
"
@
click=
"handleCut"
>
裁剪
</el-button>
<el-button
style=
"width:
98px;margin-top: 20px;margin-left: 0
"
@
click=
"handleCut"
>
裁剪
</el-button>
</div>
<div
v-if=
"imageBase64 && !isCancel"
class=
"cut"
>
...
...
src/views/goods/infoSet.vue
View file @
bfa397f6
...
...
@@ -438,7 +438,7 @@ export default {
}
const
canvas
=
document
.
createElement
(
'
canvas
'
)
const
ctx
=
canvas
.
getContext
(
'
2d
'
)
const
imageWidth
=
8
0
0
const
imageWidth
=
8
2
0
const
imageHeight
=
400
canvas
.
width
=
imageWidth
canvas
.
height
=
imageHeight
...
...
@@ -455,7 +455,7 @@ export default {
// this.width 和 this.height 获取到的是当前图片的宽和高
// document.getElementById('canvas').width = 150
// document.getElementById('canvas').height = 150
ctx
.
drawImage
(
bgImg
,
imageHeight
,
0
,
imageHeight
,
imageHeight
)
ctx
.
drawImage
(
bgImg
,
imageHeight
+
20
,
0
,
imageHeight
,
imageHeight
)
}
}
...
...
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