Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
E
electron-printer
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
zhuzhequan
electron-printer
Commits
f580dede
Commit
f580dede
authored
Mar 27, 2026
by
linjinhong
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fix:修改问题
parent
8c24a6ce
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
4 additions
and
1 deletions
+4
-1
src/server/utils/setImage.js
+3
-0
src/views/design/main/index.vue
+1
-1
No files found.
src/server/utils/setImage.js
View file @
f580dede
...
...
@@ -496,7 +496,10 @@ async function checkImageOutsideGrid() {
}
// ===================== 第二步:Sharp 读取图片原始像素 =====================
let
imgSource
=
imgDom
.
src
;
console
.
log
(
"imgSource"
,
imgSource
);
if
(
imgSource
.
startsWith
(
"file://"
))
{
imgSource
=
new
URL
(
imgSource
).
pathname
;
if
(
process
.
platform
===
"win32"
)
{
...
...
src/views/design/main/index.vue
View file @
f580dede
...
...
@@ -4,7 +4,7 @@ const { ipcRenderer } = require("electron");
import
ImgSetting
from
"./imgSetting.vue"
;
import
bus
from
"@/bus"
;
import
PrintDialog
from
"@/views/design/head/printDialog.vue"
;
import
{
mmToPx
,
newMmToPxFn
,
extractValue
,
HLCMmToPxFn
}
from
"@/utils"
;
import
{
mmToPx
,
newMmToPxFn
,
extractValue
}
from
"@/utils"
;
const
{
checkImageOutsideGrid
}
=
require
(
"../../../server/utils/setImage"
);
const
{
pathMap
}
=
require
(
"@/config/index.js"
);
...
...
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