mirror of
https://github.com/QIDITECH/QIDIStudio.git
synced 2026-01-30 16:38:41 +03:00
fix some bug
This commit is contained in:
1
.gitignore
vendored
1
.gitignore
vendored
@@ -1,6 +1,7 @@
|
|||||||
Build
|
Build
|
||||||
Build.bat
|
Build.bat
|
||||||
/build/
|
/build/
|
||||||
|
/build2/
|
||||||
/build2022/
|
/build2022/
|
||||||
deps/build
|
deps/build
|
||||||
MYMETA.json
|
MYMETA.json
|
||||||
|
|||||||
3
resources/images/monitor_axis_home_icon.svg
Normal file
3
resources/images/monitor_axis_home_icon.svg
Normal file
@@ -0,0 +1,3 @@
|
|||||||
|
<svg width="30" height="30" viewBox="0 0 30 30" fill="none" xmlns="http://www.w3.org/2000/svg">
|
||||||
|
<path d="M25.313 14.8577C25.8116 14.7499 25.9047 14.3886 25.5223 14.0519L15.1727 5.00017C14.7886 4.6651 14.161 4.66346 13.7769 4.99853L3.39301 14.0519C3.0089 14.387 3.10207 14.7482 3.60059 14.8561L4.84606 15.1242C5.34458 15.232 5.75156 15.7371 5.75156 16.247V24.6744C5.75156 25.1844 6.16836 25.6012 6.67831 25.6012H11.062C11.572 25.6012 11.9887 25.1844 11.9887 24.6744V20.6307C11.9887 20.1208 12.4055 19.704 12.9155 19.704H15.8723C16.3822 19.704 16.799 20.1208 16.799 20.6307V24.6744C16.799 25.1844 17.2158 25.6012 17.7258 25.6012H22.2369C22.7469 25.6012 23.1637 25.1844 23.1637 24.6744V16.247C23.1637 15.7371 23.5707 15.232 24.0692 15.1258L25.313 14.8577Z" fill="#4479fb" fill-opacity="0.2" stroke="#4479fb" stroke-width="0.718299" stroke-miterlimit="10" stroke-linecap="round"/>
|
||||||
|
</svg>
|
||||||
|
After Width: | Height: | Size: 884 B |
@@ -139,6 +139,17 @@ var LangText={
|
|||||||
"t146": "Upload limit exceeded",
|
"t146": "Upload limit exceeded",
|
||||||
"t147": "File upload failed",
|
"t147": "File upload failed",
|
||||||
"t148": "Add",
|
"t148": "Add",
|
||||||
|
"t204": "Login Guide",
|
||||||
|
"t205": "After registering and logging in with QIDI MAKER or QIDI LINK account, you can bind your QIDI STUDIO software to your account.",
|
||||||
|
"t206": "After the binding is completed, the QIDI STUDIO slicing software can remotely control and manage the pre-printing machine through the QIDI cloud server, enabling the remote sending",
|
||||||
|
"t207": " of print jobs, status synchronization, and device management.",
|
||||||
|
"t208": "More",
|
||||||
|
"t209": "What is the difference between QIDI MAKER and QIDI LINK ?",
|
||||||
|
"t210": "QIDI MAKER is a comprehensive upgrade of QIDI LINK, which can better adapt to QIDI 3D printers, providing ",
|
||||||
|
"t211": "more stable and faster connection as well as richer functions and support.",
|
||||||
|
"t212": "QIDI MAKER will gradually support more models of QIDI 3D printers.",
|
||||||
|
"t213": "The account cannot be logged in?",
|
||||||
|
"t214": "If you encounter any problems, please feel free to contact the official after-sales support of QIDI at any time:",
|
||||||
"wk17": "QIDI Tech Academy",
|
"wk17": "QIDI Tech Academy",
|
||||||
"wk18": "Quick Start Tutorial",
|
"wk18": "Quick Start Tutorial",
|
||||||
"wk19": "Learn by Topic",
|
"wk19": "Learn by Topic",
|
||||||
@@ -292,6 +303,17 @@ var LangText={
|
|||||||
"t201": "设备连接",
|
"t201": "设备连接",
|
||||||
"t202":"请设置您的打印机连接以查看设备。",
|
"t202":"请设置您的打印机连接以查看设备。",
|
||||||
"t203":"请使用 QIDI Link APP 连接您的打印机。链接完成后,在线设备将同步到 “Link” 页面。",
|
"t203":"请使用 QIDI Link APP 连接您的打印机。链接完成后,在线设备将同步到 “Link” 页面。",
|
||||||
|
"t204":"登录指南",
|
||||||
|
"t205":"通过 QIDI MAKER 或 QIDI LINK 注册并登录账号后,即可将你的 QIDI STUDIO 软件绑定至账户。",
|
||||||
|
"t206":"完成绑定后,QIDI STUDIO切片软件可通过 QIDI 云服务器,远程控制并管理前打印机,实现远程发",
|
||||||
|
"t207":"送打印任务、状态同步与设备管理。",
|
||||||
|
"t208":"了解更多",
|
||||||
|
"t209":"QIDI MAKER与QIDI LINK的区别 ?",
|
||||||
|
"t210":"QIDI MAKER 是QIDI LINK的全面升级版本,能够更好的适配QIDI 3D打印机,提",
|
||||||
|
"t211":"供更稳定、快速的连接和更丰富的功能与支持。",
|
||||||
|
"t212":"QIDI MAKER将逐步支持更多QIDI 3D打印机型号。",
|
||||||
|
"t213":"账号无法登录 ?",
|
||||||
|
"t214":"如遇到任何问题,请随时联系QIDI官方售后支持:",
|
||||||
"wk1": "快速入门指南",
|
"wk1": "快速入门指南",
|
||||||
"wk2": "本文介绍了QIDI Studio的最基本用法。它指导用户配置软件,创建项目,并逐步完成第一个打印任务。",
|
"wk2": "本文介绍了QIDI Studio的最基本用法。它指导用户配置软件,创建项目,并逐步完成第一个打印任务。",
|
||||||
"wk3": "基于项目的工作流",
|
"wk3": "基于项目的工作流",
|
||||||
|
|||||||
@@ -1,14 +1,18 @@
|
|||||||
<!DOCTYPE html>
|
<!DOCTYPE html>
|
||||||
<html lang="zh-CN">
|
<html>
|
||||||
<head>
|
<head>
|
||||||
<meta charset="UTF-8">
|
<meta charset="utf-8">
|
||||||
<title>登录指南</title>
|
<script type="text/javascript" src="../include/jquery-2.1.1.min.js"></script>
|
||||||
|
<script type="text/javascript" src="../include/globalapi.js"></script>
|
||||||
|
<script type="text/javascript" src="../data/text.js"></script>
|
||||||
|
<title class='trans'>Login Guide</title>
|
||||||
<style>
|
<style>
|
||||||
body {
|
body {
|
||||||
font-family: 'Segoe UI', sans-serif;
|
font-family: 'Segoe UI', sans-serif;
|
||||||
line-height: 1.8;
|
line-height: 1.8;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
margin: 40px;
|
margin-top: 0px;
|
||||||
|
margin-left : 45px;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
background: white;
|
background: white;
|
||||||
min-height: 100vh;
|
min-height: 100vh;
|
||||||
@@ -20,27 +24,28 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
max-width: 1000px;
|
max-width: 1600px;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
width: 100%;
|
width: 100%;
|
||||||
}
|
}
|
||||||
|
|
||||||
h1 {
|
h1 {
|
||||||
font-weight: normal;
|
font-weight: 300;
|
||||||
font-size: 55px;
|
font-size: 79px;
|
||||||
margin-bottom: 50px;
|
margin-bottom: 42px;
|
||||||
|
margin-top: 20px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro {
|
.intro {
|
||||||
margin-bottom: 80px;
|
margin-bottom: 138px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.intro p {
|
.intro p {
|
||||||
font-size: 20px;
|
font-size: 24px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
line-height: 1.8;
|
line-height: 1.43;
|
||||||
margin: 0;
|
margin: 0;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
}
|
}
|
||||||
@@ -57,11 +62,12 @@
|
|||||||
color: white;
|
color: white;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 10px 14px 0px;
|
padding: 10px 14px 0px;
|
||||||
border-radius: 6px;
|
border-radius: 8px;
|
||||||
font-size: 20px;
|
font-size: 30px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
min-width: 180px;
|
min-width: 200px;
|
||||||
height: 60px;
|
height: 78px;
|
||||||
|
width: 295px;
|
||||||
letter-spacing: 1px;
|
letter-spacing: 1px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -69,31 +75,33 @@
|
|||||||
background-color: #4459FB;
|
background-color: #4459FB;
|
||||||
color: white;
|
color: white;
|
||||||
border: none;
|
border: none;
|
||||||
padding: 14px 14px;
|
padding: 16px 14px 10px 18px;
|
||||||
border-radius: 6px;
|
border-radius: 8px;
|
||||||
font-size: 20px;
|
font-size: 30px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
min-width: 180px;
|
min-width: 180px;
|
||||||
height: 60px;
|
height: 78px;
|
||||||
|
width: 300px;
|
||||||
letter-spacing: 1px;
|
letter-spacing: 1px;
|
||||||
|
margin-left : 25px;
|
||||||
}
|
}
|
||||||
.arrow-icon {
|
.arrow-icon {
|
||||||
margin-left: 10px;
|
margin-left: 13px;
|
||||||
margin-right: 0px;
|
margin-right: 0px;
|
||||||
padding: 0px;
|
padding: 0px;
|
||||||
width: 35px;
|
width: 48px;
|
||||||
height: 35px;
|
height: 48px;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
margin-bottom: 8px;
|
margin-bottom: 8px;
|
||||||
}
|
}
|
||||||
.secondary-arrow-icon {
|
.secondary-arrow-icon {
|
||||||
margin-left: 40px;
|
margin-left: 60px;
|
||||||
margin-right: 0px;
|
margin-right: 0px;
|
||||||
padding: 0px;
|
padding: 0px;
|
||||||
width: 35px;
|
width: 48px;
|
||||||
height: 35px;
|
height: 48px;
|
||||||
vertical-align: middle;
|
vertical-align: middle;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
padding: 0;
|
padding: 0;
|
||||||
@@ -104,17 +112,22 @@
|
|||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
border: 1px solid white;
|
border: 1px solid white;
|
||||||
color: white;
|
color: white;
|
||||||
border-radius: 2px;
|
font-size: 18px;
|
||||||
|
height: 30px;
|
||||||
|
width: 105px;
|
||||||
|
border-radius: 5px;
|
||||||
cursor: pointer;
|
cursor: pointer;
|
||||||
|
margin-top: 60px;
|
||||||
|
font-weight: 550;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
.faq-section {
|
.faq-section {
|
||||||
margin-top: 20px;
|
margin-top: 40px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.faq-title {
|
.faq-title {
|
||||||
font-size: 16px;
|
font-size: 18px;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
margin-bottom: 0px;
|
margin-bottom: 0px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
@@ -130,12 +143,22 @@
|
|||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
}
|
}
|
||||||
|
.faq-question2 {
|
||||||
.faq-answer {
|
font-weight: 900;
|
||||||
font-size: 14px;
|
margin-bottom: 0px;
|
||||||
|
font-size: 17px;
|
||||||
|
color: #FFFFFF;
|
||||||
|
}
|
||||||
|
.answer {
|
||||||
|
margin-bottom: 15px;
|
||||||
|
}
|
||||||
|
.faq-answer p {
|
||||||
|
font-size: 16px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
line-height: 1.6;
|
line-height: 1.6;
|
||||||
margin-bottom: 0px;
|
margin-bottom: 0px;
|
||||||
|
margin: 0;
|
||||||
|
padding: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.support-section {
|
.support-section {
|
||||||
@@ -153,11 +176,12 @@
|
|||||||
.support-link {
|
.support-link {
|
||||||
color: #007bff;
|
color: #007bff;
|
||||||
text-decoration: none;
|
text-decoration: none;
|
||||||
font-size: 14px;
|
font-size: 16px;
|
||||||
display: inline-block;
|
display: inline-block;
|
||||||
margin-top: 0px;
|
margin-top: 0px;
|
||||||
margin-bottom: 0px;
|
margin-bottom: 0px;
|
||||||
color: #FFFFFF;
|
color: #FFFFFF;
|
||||||
|
text-decoration: underline;
|
||||||
}
|
}
|
||||||
|
|
||||||
.footer {
|
.footer {
|
||||||
@@ -170,14 +194,12 @@
|
|||||||
</head>
|
</head>
|
||||||
<body>
|
<body>
|
||||||
<div class="content">
|
<div class="content">
|
||||||
<h1>登录指南</h1>
|
<h1 class="trans" tid="t204">Login Guide</h1>
|
||||||
|
|
||||||
<div class="intro">
|
<div class="intro" >
|
||||||
<p>通过 QIDI MAKER 或 QIDI LINK 注册并登录账号后,即可将你的 QIDI </p>
|
<p class="trans" tid="t205">After registering and logging in with QIDI MAKER or QIDI LINK account, you can bind your QIDI STUDIO software to your account.</p>
|
||||||
<p>STUDIO 软件绑定至账户。</p>
|
<p class='trans' tid="t206">After the binding is completed, the QIDI STUDIO slicing software can remotely control and manage the pre-printing machine through the QIDI cloud server, enabling the remote sending</p>
|
||||||
<p>完成绑定后,QIDI STUDIO 切片软件可通过 QIDI 云服务器、远程控制并管理
|
<p class='trans' tid="t207"> of print jobs, status synchronization, and device management.</p>
|
||||||
<p>当前全部已登录该用户账号的打印机,实现远程发送打印任务、状态同步与
|
|
||||||
<p>设备管理。</p>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="button-container">
|
<div class="button-container">
|
||||||
@@ -192,27 +214,28 @@
|
|||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="detail-button">
|
<div class="detail-button">
|
||||||
<button class="more-button" id="more" >
|
<button class="more-button trans" id="more" tid="t208">
|
||||||
了解更多
|
More
|
||||||
</button>
|
</button>
|
||||||
</div>
|
</div>
|
||||||
<div class = "detail-text" id = "text-detail">
|
<div class = "detail-text" id = "text-detail">
|
||||||
<div class="faq-section" id="faq">
|
<div class="faq-section" id="faq">
|
||||||
<div class="faq-item">
|
<div class="faq-item">
|
||||||
<div class="faq-question">QIDI MAKER与QIDI LINK的区别?</div>
|
<div class="faq-question trans" tid="t209">What is the difference between QIDI MAKER and QIDI LINK ?</div>
|
||||||
<div class="faq-answer">QIDI MAKER APP是一个面向用户的一站式3D打印平台,致力于为用户提供便<br>
|
<div class="faq-answer">
|
||||||
捷、流畅且愉悦的3D打印体验。目前,QIDI MAKER暂时仅兼容QIDI Max4,<br>
|
<p class="trans" tid="t210">QIDI MAKER is a comprehensive upgrade of QIDI LINK, which can better adapt to QIDI 3D printers, providing </p>
|
||||||
后续将逐步支持更多QIDI 3D打印机型号。</div>
|
<p class="trans" tid="t211">more stable and faster connection as well as richer functions and support.</p>
|
||||||
|
<p class="trans" tid="t212">QIDI MAKER will gradually support more models of QIDI 3D printers.</p>
|
||||||
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="faq-item">
|
<div class="faq-item">
|
||||||
<div class="faq-question">账号无法登录?</div>
|
<div class="faq-question2 trans" tid="t213">The account cannot be logged in?</div>
|
||||||
<div class="faq-answer">如遇到任何问题,请随时联系QIDI官方售后支持:</div>
|
<div class="faq-answer trans" tid="t214">If you encounter any problems, please feel free to contact the official after-sales support of QIDI at any time:</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<div class="support-section">
|
<div class="support-section">
|
||||||
<div class="support-title">官方售后支持</div>
|
|
||||||
<div>
|
<div>
|
||||||
<a href="https://wiki.qidi3d.com/en/AfterSalesContact" target="_blank" class="support-link">
|
<a href="https://wiki.qidi3d.com/en/AfterSalesContact" target="_blank" class="support-link">
|
||||||
https://wiki.qidi3d.com/en/AfterSalesContact
|
https://wiki.qidi3d.com/en/AfterSalesContact
|
||||||
@@ -231,6 +254,7 @@
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
window.addEventListener('DOMContentLoaded', function() {
|
window.addEventListener('DOMContentLoaded', function() {
|
||||||
|
TranslatePage();
|
||||||
document.getElementById('text-detail').hidden = true;
|
document.getElementById('text-detail').hidden = true;
|
||||||
});
|
});
|
||||||
document.getElementById('more').addEventListener('click', function() {
|
document.getElementById('more').addEventListener('click', function() {
|
||||||
|
|||||||
@@ -332,10 +332,12 @@ void PrinterWebView::init_scroll_window(wxPanel* Panel) {
|
|||||||
devicesizer->Add(label_boxsizer_online);
|
devicesizer->Add(label_boxsizer_online);
|
||||||
devicesizer->AddSpacer(7);
|
devicesizer->AddSpacer(7);
|
||||||
}
|
}
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
m_net_devices = wxGetApp().get_devices();
|
m_net_devices = wxGetApp().get_devices();
|
||||||
for (const auto& device : m_net_devices) {
|
for (const auto& device : m_net_devices) {
|
||||||
AddNetButton(device);
|
AddNetButton(device);
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
//y40
|
//y40
|
||||||
if (webisNetMode == isNetWeb) {
|
if (webisNetMode == isNetWeb) {
|
||||||
@@ -475,7 +477,6 @@ void PrinterWebView::SetLoginStatus(bool status) {
|
|||||||
{
|
{
|
||||||
s_lastDeviceCount = currentDeviceCount;
|
s_lastDeviceCount = currentDeviceCount;
|
||||||
|
|
||||||
// <20><><EFBFBD><EFBFBD><EFBFBD>߳<EFBFBD><DFB3>и<EFBFBD><D0B8><EFBFBD>UI
|
|
||||||
GUI::wxGetApp().CallAfter([this]() {
|
GUI::wxGetApp().CallAfter([this]() {
|
||||||
this->UpdateState();
|
this->UpdateState();
|
||||||
this->SetPresetChanged(true);
|
this->SetPresetChanged(true);
|
||||||
@@ -488,14 +489,14 @@ void PrinterWebView::SetLoginStatus(bool status) {
|
|||||||
}).detach();
|
}).detach();
|
||||||
#endif
|
#endif
|
||||||
} else {
|
} else {
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
std::vector<NetDevice> devices;
|
std::vector<NetDevice> devices;
|
||||||
wxGetApp().set_devices(devices);
|
wxGetApp().set_devices(devices);
|
||||||
if (!wxGetApp().is_link_connect()) // <20><>link<6E><6B>¼<EFBFBD><C2BC>ʱ<EFBFBD><CAB1><EFBFBD>˳<EFBFBD><CBB3><EFBFBD>¼<EFBFBD><C2BC>Ҫ<EFBFBD>ر<EFBFBD>sse<73><65><EFBFBD><EFBFBD>
|
if (!wxGetApp().is_link_connect())
|
||||||
{
|
{
|
||||||
#if QDT_RELEASE_TO_PUBLIC
|
|
||||||
MakerHttpHandle::getInstance().closeSSEClient();
|
MakerHttpHandle::getInstance().closeSSEClient();
|
||||||
#endif
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
// y28
|
// y28
|
||||||
if(webisNetMode == isNetWeb)
|
if(webisNetMode == isNetWeb)
|
||||||
webisNetMode = isDisconnect;
|
webisNetMode = isDisconnect;
|
||||||
@@ -708,7 +709,7 @@ void PrinterWebView::updateDeviceConnectType(const std::string& device_id, const
|
|||||||
if (machine_button == nullptr) {
|
if (machine_button == nullptr) {
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
// cj_1 <20>л<EFBFBD><D0BB><EFBFBD><EFBFBD>ð<EFBFBD>ť<EFBFBD><EFBFBD>ʾ<EFBFBD><EFBFBD>ʽ<EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
// cj_1 <20>л<EFBFBD><D0BB><EFBFBD>ð<EFBFBD>ť<EFBFBD><C5A5>ʾ<EFBFBD><CABE>ʽ<EFBFBD><CABD><EFBFBD><EFBFBD>
|
||||||
cancelAllDevButtonSelect();
|
cancelAllDevButtonSelect();
|
||||||
clearStatusPanelData();
|
clearStatusPanelData();
|
||||||
machine_button->SetIsSelected(true);
|
machine_button->SetIsSelected(true);
|
||||||
@@ -1107,7 +1108,9 @@ void PrinterWebView::onStatusPanelTask(wxCommandEvent& event)
|
|||||||
m_device_manager->sendActionCommand(m_cur_deviceId, action_type);
|
m_device_manager->sendActionCommand(m_cur_deviceId, action_type);
|
||||||
}
|
}
|
||||||
|
|
||||||
} else {
|
}
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
|
else {
|
||||||
HttpData httpData;
|
HttpData httpData;
|
||||||
json bodyJson;
|
json bodyJson;
|
||||||
bodyJson["serialNumber"] = m_cur_deviceId;
|
bodyJson["serialNumber"] = m_cur_deviceId;
|
||||||
@@ -1153,6 +1156,7 @@ void PrinterWebView::onStatusPanelTask(wxCommandEvent& event)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
//cj_1
|
//cj_1
|
||||||
@@ -1186,6 +1190,7 @@ void PrinterWebView::onSetBoxTask(wxCommandEvent& event)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
HttpData httpData;
|
HttpData httpData;
|
||||||
json bodyJson;
|
json bodyJson;
|
||||||
bodyJson["serialNumber"] = m_cur_deviceId;
|
bodyJson["serialNumber"] = m_cur_deviceId;
|
||||||
@@ -1207,7 +1212,7 @@ void PrinterWebView::onSetBoxTask(wxCommandEvent& event)
|
|||||||
std::cout << "http error" << isSucceed << std::endl;
|
std::cout << "http error" << isSucceed << std::endl;
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void PrinterWebView::onRefreshRfid(wxCommandEvent& event)
|
void PrinterWebView::onRefreshRfid(wxCommandEvent& event)
|
||||||
@@ -1225,6 +1230,7 @@ void PrinterWebView::onRefreshRfid(wxCommandEvent& event)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
//RFID_READ SLOT=slot3
|
//RFID_READ SLOT=slot3
|
||||||
HttpData httpData;
|
HttpData httpData;
|
||||||
json bodyJson;
|
json bodyJson;
|
||||||
@@ -1245,7 +1251,7 @@ void PrinterWebView::onRefreshRfid(wxCommandEvent& event)
|
|||||||
|
|
||||||
auto device = m_device_manager->getDevice(m_cur_deviceId);
|
auto device = m_device_manager->getDevice(m_cur_deviceId);
|
||||||
return;
|
return;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
}
|
}
|
||||||
@@ -1458,22 +1464,22 @@ void PrinterWebView::OnScroll(wxScrollWinEvent& event)
|
|||||||
}
|
}
|
||||||
|
|
||||||
std::string extractBetweenMarkers(const std::string& path) {
|
std::string extractBetweenMarkers(const std::string& path) {
|
||||||
// <20><><EFBFBD><EFBFBD> "/gcodes" <20><>λ<EFBFBD><CEBB>
|
// <20><><EFBFBD><EFBFBD> "/gcodes" <20><>λ<EFBFBD><CEBB>
|
||||||
size_t startPos = path.find("/gcodes");
|
size_t startPos = path.find("/gcodes");
|
||||||
if (startPos == std::string::npos) {
|
if (startPos == std::string::npos) {
|
||||||
return ""; // û<>ҵ<EFBFBD> /gcodes
|
return ""; // û<>ҵ<EFBFBD> /gcodes
|
||||||
}
|
}
|
||||||
|
|
||||||
// <20><> /gcodes <20><><EFBFBD>濪ʼ<E6BFAA><CABC><EFBFBD><EFBFBD><EFBFBD>ϳ<EFBFBD><CFB3>ȣ<EFBFBD>
|
// <20><> /gcodes <20><><EFBFBD>濪ʼ<E6BFAA><CABC><EFBFBD><EFBFBD><EFBFBD>ϳ<EFBFBD><CFB3>ȣ<EFBFBD>
|
||||||
startPos += 7; // "/gcodes" <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7
|
startPos += 7; // "/gcodes" <20><><EFBFBD><EFBFBD><EFBFBD><EFBFBD>7
|
||||||
|
|
||||||
// <20><><EFBFBD><EFBFBD> ".3mf" <20><>λ<EFBFBD><CEBB>
|
// <20><><EFBFBD><EFBFBD> ".3mf" <20><>λ<EFBFBD><CEBB>
|
||||||
size_t endPos = path.find(".3mf", startPos);
|
size_t endPos = path.find(".3mf", startPos);
|
||||||
if (endPos == std::string::npos) {
|
if (endPos == std::string::npos) {
|
||||||
return ""; // û<>ҵ<EFBFBD> .3mf
|
return ""; // û<>ҵ<EFBFBD> .3mf
|
||||||
}
|
}
|
||||||
|
|
||||||
// <20><>ȡ<EFBFBD>м䲿<D0BC><E4B2BF>
|
// <20><>ȡ<EFBFBD>м䲿<D0BC><E4B2BF>
|
||||||
return path.substr(startPos, endPos - startPos);
|
return path.substr(startPos, endPos - startPos);
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -1510,7 +1516,7 @@ void PrinterWebView::OnScroll(wxScrollWinEvent& event)
|
|||||||
std::string oldPrintFileName = device->m_print_filename;
|
std::string oldPrintFileName = device->m_print_filename;
|
||||||
device->updateByJsonData(status);
|
device->updateByJsonData(status);
|
||||||
device->last_update = std::chrono::steady_clock::now();
|
device->last_update = std::chrono::steady_clock::now();
|
||||||
//cj_1 <20><><EFBFBD><EFBFBD>ӡ<EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ˣ<EFBFBD><CBA3><EFBFBD><EFBFBD>´<EFBFBD>ӡ<EFBFBD>̶<EFBFBD><CCB6><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD>ļ<EFBFBD>ͼƬ<CDBC><C6AC><EFBFBD><EFBFBD>ӡ<EFBFBD><D3A1>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
//cj_1 <20><><EFBFBD><EFBFBD>ӡ<EFBFBD>ļ<EFBFBD><C4BC><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>ˣ<EFBFBD><CBA3><EFBFBD><EFBFBD>´<EFBFBD>ӡ<EFBFBD>̶<EFBFBD><CCB6><EFBFBD>Ϣ<EFBFBD><CFA2><EFBFBD>ļ<EFBFBD>ͼƬ<CDBC><C6AC><EFBFBD><EFBFBD>ӡ<EFBFBD><D3A1>ʱ<EFBFBD><CAB1><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||||
if (oldPrintFileName != device->m_print_filename) {
|
if (oldPrintFileName != device->m_print_filename) {
|
||||||
|
|
||||||
std::string url = device->m_frp_url + "/api/qidiclient/files/list";
|
std::string url = device->m_frp_url + "/api/qidiclient/files/list";
|
||||||
@@ -1723,7 +1729,7 @@ void PrinterWebView::bindTaskHandle()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
// <20><><EFBFBD><EFBFBD> key-value <20><>
|
// <20><><EFBFBD><EFBFBD> key-value <20><>
|
||||||
for (auto& pair : m_eventToTaskPath) {
|
for (auto& pair : m_eventToTaskPath) {
|
||||||
const wxEventTypeTag< wxCommandEvent >eventType = pair.first;
|
const wxEventTypeTag< wxCommandEvent >eventType = pair.first;
|
||||||
t_status_page->Bind(eventType, &PrinterWebView::onStatusPanelTask, this);
|
t_status_page->Bind(eventType, &PrinterWebView::onStatusPanelTask, this);
|
||||||
@@ -1817,15 +1823,15 @@ std::string extractEndNumbers(const std::string& str) {
|
|||||||
size_t endPos = str.find_last_not_of("0123456789");
|
size_t endPos = str.find_last_not_of("0123456789");
|
||||||
|
|
||||||
if (endPos == std::string::npos) {
|
if (endPos == std::string::npos) {
|
||||||
// <20>ַ<EFBFBD><D6B7><EFBFBD>ȫ<EFBFBD><C8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
// <20>ַ<EFBFBD><D6B7><EFBFBD>ȫ<EFBFBD><C8AB><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||||
return str;
|
return str;
|
||||||
}
|
}
|
||||||
else if (endPos == str.length() - 1) {
|
else if (endPos == str.length() - 1) {
|
||||||
// <20><><EFBFBD><EFBFBD>һ<EFBFBD><EFBFBD><EFBFBD>ַ<EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
// <20><><EFBFBD>һ<EFBFBD><D2BB><EFBFBD>ַ<EFBFBD><D6B7><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD><EFBFBD>
|
||||||
return "";
|
return "";
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
// <20><><EFBFBD><EFBFBD>ĩβ<C4A9><CEB2><EFBFBD><EFBFBD><EFBFBD>ֲ<EFBFBD><D6B2><EFBFBD>
|
// <20><><EFBFBD><EFBFBD>ĩβ<C4A9><CEB2><EFBFBD><EFBFBD><EFBFBD>ֲ<EFBFBD><D6B2><EFBFBD>
|
||||||
return str.substr(endPos + 1);
|
return str.substr(endPos + 1);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -215,7 +215,9 @@ private:
|
|||||||
std::map<wxEventType, std::string> m_localEventToTaskPath;
|
std::map<wxEventType, std::string> m_localEventToTaskPath;
|
||||||
std::string m_userInfo;
|
std::string m_userInfo;
|
||||||
|
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
std::vector<NetDevice> m_net_devices;
|
std::vector<NetDevice> m_net_devices;
|
||||||
|
#endif
|
||||||
|
|
||||||
};
|
};
|
||||||
|
|
||||||
|
|||||||
@@ -143,6 +143,7 @@ void QDSFilamentConfig::init()
|
|||||||
|
|
||||||
void QDSFilamentConfig::initTypeName()
|
void QDSFilamentConfig::initTypeName()
|
||||||
{
|
{
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
std::string resultBody = MakerHttpHandle::getInstance().httpGetTask(Environment::TESTENV, m_typeName.path);
|
std::string resultBody = MakerHttpHandle::getInstance().httpGetTask(Environment::TESTENV, m_typeName.path);
|
||||||
if (resultBody == "") {
|
if (resultBody == "") {
|
||||||
return;
|
return;
|
||||||
@@ -172,10 +173,12 @@ void QDSFilamentConfig::initTypeName()
|
|||||||
catch (...) {
|
catch (...) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
void QDSFilamentConfig::initFilamentData(FilamentData& filamentData)
|
void QDSFilamentConfig::initFilamentData(FilamentData& filamentData)
|
||||||
{
|
{
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
std::string resultBody = MakerHttpHandle::getInstance().httpGetTask(Environment::TESTENV, filamentData.path);
|
std::string resultBody = MakerHttpHandle::getInstance().httpGetTask(Environment::TESTENV, filamentData.path);
|
||||||
if (resultBody == "") {
|
if (resultBody == "") {
|
||||||
return;
|
return;
|
||||||
@@ -197,7 +200,7 @@ void QDSFilamentConfig::initFilamentData(FilamentData& filamentData)
|
|||||||
catch (...) {
|
catch (...) {
|
||||||
|
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
}
|
}
|
||||||
|
|
||||||
std::string QDSFilamentConfig::getData(FilamentData filamentData, int index)
|
std::string QDSFilamentConfig::getData(FilamentData filamentData, int index)
|
||||||
@@ -1838,6 +1841,7 @@ void QDSDeviceManager::unSelected(){
|
|||||||
}
|
}
|
||||||
|
|
||||||
//y76
|
//y76
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
void QDSDeviceManager::setNetDevices(std::vector<NetDevice> devices){
|
void QDSDeviceManager::setNetDevices(std::vector<NetDevice> devices){
|
||||||
std::lock_guard<std::mutex> lock(manager_mutex_);
|
std::lock_guard<std::mutex> lock(manager_mutex_);
|
||||||
net_devices = devices;
|
net_devices = devices;
|
||||||
@@ -1847,6 +1851,7 @@ std::vector<NetDevice> QDSDeviceManager::getNetDevices(){
|
|||||||
std::lock_guard<std::mutex> lock(manager_mutex_);
|
std::lock_guard<std::mutex> lock(manager_mutex_);
|
||||||
return net_devices;
|
return net_devices;
|
||||||
}
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
void QDSDeviceManager::upBoxInfoToBoxMsg(std::shared_ptr<QDSDevice>& device){
|
void QDSDeviceManager::upBoxInfoToBoxMsg(std::shared_ptr<QDSDevice>& device){
|
||||||
std::vector<int> slot_state(17);
|
std::vector<int> slot_state(17);
|
||||||
|
|||||||
@@ -245,8 +245,10 @@ public:
|
|||||||
void setSelected(const std::string& device_id);
|
void setSelected(const std::string& device_id);
|
||||||
std::shared_ptr<QDSDevice> getSelectedDevice();
|
std::shared_ptr<QDSDevice> getSelectedDevice();
|
||||||
void unSelected();
|
void unSelected();
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
void setNetDevices(std::vector<NetDevice> devices);
|
void setNetDevices(std::vector<NetDevice> devices);
|
||||||
std::vector<NetDevice> getNetDevices();
|
std::vector<NetDevice> getNetDevices();
|
||||||
|
#endif
|
||||||
void upBoxInfoToBoxMsg(std::shared_ptr<QDSDevice>& device);
|
void upBoxInfoToBoxMsg(std::shared_ptr<QDSDevice>& device);
|
||||||
|
|
||||||
private:
|
private:
|
||||||
@@ -269,7 +271,10 @@ private:
|
|||||||
std::mutex callback_mutex_;
|
std::mutex callback_mutex_;
|
||||||
std::unordered_map<std::string, std::shared_ptr<QDSDevice>> devices_;
|
std::unordered_map<std::string, std::shared_ptr<QDSDevice>> devices_;
|
||||||
std::unordered_map<std::string, std::shared_ptr<WebSocketConnect>> connections_;
|
std::unordered_map<std::string, std::shared_ptr<WebSocketConnect>> connections_;
|
||||||
|
|
||||||
|
#if QDT_RELEASE_TO_PUBLIC
|
||||||
std::vector<NetDevice> net_devices;
|
std::vector<NetDevice> net_devices;
|
||||||
|
#endif
|
||||||
|
|
||||||
|
|
||||||
// WebSocket
|
// WebSocket
|
||||||
|
|||||||
Reference in New Issue
Block a user