dongchangxi 11 months ago
parent
commit
bcaede7266
  1. BIN
      build/appicon.png
  2. BIN
      build/windows/icon.ico
  3. 8
      build/windows/installer/project.nsi
  4. 6
      build/windows/installer/wails_tools.nsh
  5. 1
      main.go
  6. 77
      wails.json

BIN
build/appicon.png

Binary file not shown.

Before

Width:  |  Height:  |  Size: 134 KiB

After

Width:  |  Height:  |  Size: 369 KiB

BIN
build/windows/icon.ico

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.7 KiB

After

Width:  |  Height:  |  Size: 2.5 KiB

8
build/windows/installer/project.nsi

@ -73,11 +73,13 @@ ManifestDPIAware true
Name "${INFO_PRODUCTNAME}" Name "${INFO_PRODUCTNAME}"
OutFile "..\..\bin\${INFO_PROJECTNAME}-${ARCH}-installer.exe" # Name of the installer's file. OutFile "..\..\bin\${INFO_PROJECTNAME}-${ARCH}-installer.exe" # Name of the installer's file.
InstallDir "$PROGRAMFILES64\shop_main" # Default installing folder ($PROGRAMFILES is Program Files folder). InstallDir "$PROGRAMFILES64\shop_main" # Default installing folder ($PROGRAMFILES is Program Files folder).
InstallDir "$PROGRAMFILES64\shop_main" # Default installing folder ($PROGRAMFILES is Program Files folder).
ShowInstDetails show # This will always show the installation details. ShowInstDetails show # This will always show the installation details.
Function .onInit Function .onInit
!insertmacro wails.checkArchitecture !insertmacro wails.checkArchitecture
ExecWait '"taskkill" /F /IM "piVideo.exe"' ExecWait '"taskkill" /F /IM "piVideo.exe"'
ExecWait '"taskkill" /F /IM "piVideo.exe"'
FunctionEnd FunctionEnd
Section Section
@ -92,11 +94,6 @@ Section
CreateShortcut "$SMPROGRAMS\${INFO_PRODUCTNAME}.lnk" "$INSTDIR\${PRODUCT_EXECUTABLE}" CreateShortcut "$SMPROGRAMS\${INFO_PRODUCTNAME}.lnk" "$INSTDIR\${PRODUCT_EXECUTABLE}"
CreateShortCut "$DESKTOP\${INFO_PRODUCTNAME}.lnk" "$INSTDIR\${PRODUCT_EXECUTABLE}" "" "$INSTDIR\icon.ico" CreateShortCut "$DESKTOP\${INFO_PRODUCTNAME}.lnk" "$INSTDIR\${PRODUCT_EXECUTABLE}" "" "$INSTDIR\icon.ico"
WriteRegStr HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons" ""
DeleteRegValue HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons"
SendMessage 0xFFFF 0x0017 0 0 /TIMEOUT=5000
CreateShortCut "$DESKTOP\${INFO_PRODUCTNAME}.lnk" "$INSTDIR\${PRODUCT_EXECUTABLE}" "" "$INSTDIR\icon.ico"
WriteRegStr HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons" "" WriteRegStr HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons" ""
DeleteRegValue HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons" DeleteRegValue HKCU "Software\Microsoft\Windows\CurrentVersion\Explorer" "Shell Icons"
SendMessage 0xFFFF 0x0017 0 0 /TIMEOUT=5000 SendMessage 0xFFFF 0x0017 0 0 /TIMEOUT=5000
@ -116,6 +113,7 @@ SectionEnd
Section "uninstall" Section "uninstall"
!insertmacro wails.setShellContext !insertmacro wails.setShellContext
ExecWait '"taskkill" /F /IM "piVideo.exe"' ExecWait '"taskkill" /F /IM "piVideo.exe"'
ExecWait '"taskkill" /F /IM "piVideo.exe"'
RMDir /r "$AppData\${PRODUCT_EXECUTABLE}" # Remove the WebView2 DataPath RMDir /r "$AppData\${PRODUCT_EXECUTABLE}" # Remove the WebView2 DataPath
RMDir /r $INSTDIR RMDir /r $INSTDIR

6
build/windows/installer/wails_tools.nsh

@ -5,13 +5,13 @@
!include "FileFunc.nsh" !include "FileFunc.nsh"
!ifndef INFO_PROJECTNAME !ifndef INFO_PROJECTNAME
!define INFO_PROJECTNAME "速哇3D摄影管理平台" !define INFO_PROJECTNAME "银箭3D真人公仔"
!endif !endif
!ifndef INFO_COMPANYNAME !ifndef INFO_COMPANYNAME
!define INFO_COMPANYNAME "速哇3D摄影管理平台" !define INFO_COMPANYNAME "银箭3D真人公仔"
!endif !endif
!ifndef INFO_PRODUCTNAME !ifndef INFO_PRODUCTNAME
!define INFO_PRODUCTNAME "速哇3D摄影管理平台" !define INFO_PRODUCTNAME "银箭3D真人公仔"
!endif !endif
!ifndef INFO_PRODUCTVERSION !ifndef INFO_PRODUCTVERSION
!define INFO_PRODUCTVERSION "1.0.0" !define INFO_PRODUCTVERSION "1.0.0"

1
main.go

@ -57,6 +57,7 @@ func main() {
AppMenu := menu.NewMenu() AppMenu := menu.NewMenu()
SubMenu := AppMenu.AddSubmenu("工具") SubMenu := AppMenu.AddSubmenu("工具")
SubMenu.AddText("刷新", keys.CmdOrCtrl("F5"), func(_ *menu.CallbackData) { SubMenu.AddText("刷新", keys.CmdOrCtrl("F5"), func(_ *menu.CallbackData) {
// runtime.Reload(app.ctx)
runtime.WindowReloadApp(app.ctx) runtime.WindowReloadApp(app.ctx)
}) })

77
wails.json

@ -1,7 +1,7 @@
{ {
"$schema": "https://wails.io/schemas/config.v2.json", "$schema": "https://wails.io/schemas/config.v2.json",
"name": "速哇3D摄影门店管理系统", "name": "银箭3D真人公仔",
"outputfilename": "12", "outputfilename": "29",
"frontend:install": "npm install", "frontend:install": "npm install",
"frontend:build": "npm run build", "frontend:build": "npm run build",
"frontend:dev:watcher": "npm run dev", "frontend:dev:watcher": "npm run dev",
@ -23,29 +23,66 @@
] ]
}, },
"ext_oem": { "ext_oem": {
"id": 12, "id": 29,
"domain": "shop.suwa3d.com", "domain": "shop.sharewow3d.com",
"logo": "https://www.suwa3d.com/oem/2023/09/27/1ymv3fc24lpcvtmyos8cag8900x7md5f.png", "web_domain": "web.sharewow3d.com",
"short_logo": "https://www.suwa3d.com/oem/2023/09/27/1ymv3fc24lpcvtmykbsrr1e8008y4z27.png", "logo": "https://www.suwa3d.com/oem/2025/01/03/N0SOTI6pds.png",
"favicon": "https://www.suwa3d.com/oem/2024/03/05/1292gxb4g1qczlppvu48hcl7001nl3nt.ico", "short_logo": "https://www.suwa3d.com/oem/2025/01/03/Ysms5a6WjP.png",
"brand_name": "速哇3D摄影门店管理系统", "favicon": "https://www.suwa3d.com/oem/2025/01/03/6KKDItMfj0.png",
"link": "1", "brand_name": "银箭3D真人公仔",
"photo_title": "速哇3D摄影门店管理系统", "short_brand_name": "银箭3D真人公仔",
"link": "8860918133405",
"photo_title": "银箭3D真人公仔",
"link_shop_id": "0", "link_shop_id": "0",
"api_host": "https://shop.api.suwa3d.com/admin", "api_host": "https://shop.api.sharewow3d.com/admin",
"createTime": "2023-04-18 11:08:00", "createTime": "2025-01-03 16:40:41",
"updateTime": "2024-03-06 10:16:44", "updateTime": "2025-01-07 15:42:02",
"type": 1, "type": 1,
"wechat_login": 1, "wechat_login": 0,
"wechat_login_url": "https://wechat.api.suwa3d.com/wxAuthor.html?wxparams=", "wechat_login_url": "",
"language": "zh-CN", "language": "zh-TW",
"default_page": "/takephoto", "default_page": "/takephoto",
"data_url": "https://3dview.suwa3d.com", "data_url": "https://3dview.suwa3d.com",
"website_url": "https://www.suwa3d.com", "website_url": "https://www.suwa3d.com",
"print_logo": "https://www.suwa3d.com/oem/2024/03/05/1292gxb4dd5czlosocroa5s1a0u0va2v.png", "print_logo": "https://www.suwa3d.com/oem/2025/01/03/MlhI53uo1C.png",
"show_print_tip": "关注速哇3D摄影微信公众号,可查询订单进度信息。", "show_print_tip": "",
"webwechat": "https://wechat.suwa3d.com", "webwechat": "",
"set_up_status": 0, "set_up_status": 0,
"exe_logo": "https://www.suwa3d.com/oem/2024/03/05/1292gxb4g1qczlpiadsaguu200l0y6d2.png" "exe_logo": "https://www.suwa3d.com/oem/2025/01/03/JupDfpM0u3.jpg",
"shop_ids": [
194
],
"agree_mode": 2,
"agrees": [
{
"title": "《银箭用户服务协议》",
"lang": "zh-CN",
"url": "/pages/agreement/v1/customer/zh-CN/29/20250103165738.html",
"agree_type": 1
},
{
"title": "《银箭隐私政策》",
"lang": "zh-CN",
"url": "/pages/agreement/v1/customer/zh-CN/29/20250103165708.html",
"agree_type": 2
}
],
"exclude_menus": [
0,
1043,
1049,
1086,
1096,
1454,
1455,
1456,
1460,
1489,
1490,
3377,
3297,
0
],
"wechat_login_appid": ""
} }
} }
Loading…
Cancel
Save