(printData = index)"
- style="text-align: left"
- >
+
(printData = index)"
+ style="text-align: left">
{{
getPrintName(item.PrinterID, true)
}}
@@ -30,9 +25,7 @@
- {{ $t("admin.hello") }} {{ user }}
+ {{ $t("admin.hello") }} {{ user }}
{{ $t("admin.home") }}
@@ -46,27 +39,11 @@
-
-
-
-
-
+
+
+
+
+
{{
@@ -79,26 +56,12 @@
- edit(scope.row)"
- >{{ $t("admin.edit") }}
- {{ $t("admin.add") }}
- deleted(scope.row)"
- v-if="scope.row.userName != 'admin'"
- >{{ $t("admin.delete") }}
+ edit(scope.row)">{{ $t("admin.edit")
+ }}
+ {{ $t("admin.add") }}
+ deleted(scope.row)"
+ v-if="scope.row.userName != 'admin'">{{ $t("admin.delete") }}
@@ -116,47 +79,30 @@
{{ $t("admin.selectWorkstation") }}
-
+
{{ $t("admin.formatType") }}
-
+
{{ $t("admin.number") }}
-
+
- {
- running = 0;
- runningEmergy = false;
- isFormat = true;
- handleFormat();
- }
- "
- :loading="runningState && isFormat"
- :disabled="runningState && !isFormat"
- >{{ $t("work.submit") }}
+ {
+ running = 0;
+ runningEmergy = false;
+ isFormat = true;
+ handleFormat();
+ }
+ " :loading="runningState && isFormat" :disabled="runningState && !isFormat">{{ $t("work.submit")
+ }}
@@ -167,41 +113,25 @@
{{ $t("admin.selectWorkstation") }}
-
+
{{ $t("admin.copyPath") }}
-
+
{{ $t("admin.number") }}
-
+
-
{
- running = 0;
- runningEmergy = false;
- isFormat = false;
- handleCopy();
- }
- "
- >{{ $t("work.submit") }}
+
{
+ running = 0;
+ runningEmergy = false;
+ isFormat = false;
+ handleCopy();
+ }
+ ">{{ $t("work.submit") }}
@@ -235,49 +165,22 @@
-
-
+
+
-
- {
- chageEdituservisible(false);
- getUserData();
- }
- "
- >
+
+ {
+ chageEdituservisible(false);
+ getUserData();
+ }
+ ">
-
-
+
+
@@ -464,7 +367,7 @@ export default {
131078: { tag: "Card_Low", err: 0 },
131081: { tag: "Need_Cleaning", err: 0 },
1167: { tag: "PAVO_DS_OFFLINE", err: 0 },
- 196609:{ tag: "FIND_CARD", err: 0 },
+ 196609: { tag: "FIND_CARD", err: 0 },
},
errList: [],
checkStates: {},
@@ -513,6 +416,11 @@ export default {
method: "get",
url: "/web/get_printer_info",
}).then((res) => {
+ if (!res.data || !res.data.printerList) {
+ console.warn('获取工作站列表返回的数据格式不正确:', res)
+ this.infoData = []
+ return
+ }
this.infoData = res.data.printerList;
this.workValue2 = this.workValue =
res.data.printerList.length > 0
@@ -527,6 +435,10 @@ export default {
this.DualSide = 1; //只要有一个是双面就是1
}
}
+ }).catch((e) => {
+ console.error('获取工作站列表失败:', e)
+ this.infoData = []
+ this.$message.error('获取工作站列表失败,请检查网络连接')
});
},
runCheckState() {
@@ -561,8 +473,7 @@ export default {
//阻止即将发生的事件
this.runningEmergy = true;
appendLog(
- `Task ${this.running + 1}/${
- this.isFormat ? this.number : this.number2
+ `Task ${this.running + 1}/${this.isFormat ? this.number : this.number2
} failed, Error = ${data.printer_status}`,
this.root
);
@@ -778,10 +689,10 @@ export default {
);
this.$message(
this.$t("admin.comingSoon") +
- `${time[0]}` +
- this.$t("admin.readLetter") +
- `${disk[0]}` +
- this.$t("admin.makeCpoy")
+ `${time[0]}` +
+ this.$t("admin.readLetter") +
+ `${disk[0]}` +
+ this.$t("admin.makeCpoy")
);
this.handleCopyFile(`${disk[0]}:\\`);
}
@@ -877,10 +788,10 @@ export default {
) {
this.$message(
this.$t("admin.comingSoon") +
- `${time[0]}` +
- this.$t("admin.readLetter") +
- `${disk[0]}` +
- this.$t("admin.format")
+ `${time[0]}` +
+ this.$t("admin.readLetter") +
+ `${disk[0]}` +
+ this.$t("admin.format")
);
await this.$axios({
method: "post",
@@ -1032,42 +943,50 @@ export default {
/deep/ .el-tabs__content {
overflow-y: auto;
}
+
.infdialog {
/deep/.el-dialog {
padding: 20px 0px;
}
+
/deep/.el-dialog__header {
padding: 0px;
font-size: 15px;
font-weight: bold;
}
+
/deep/.el-dialog__body {
margin-top: 30px;
padding: 0px;
}
- /deep/.el-dialog__title {
- }
+
+ /deep/.el-dialog__title {}
}
.wLog {
max-height: 600px;
overflow: auto;
}
+
h1,
h2 {
font-weight: normal;
}
+
ul {
list-style-type: none;
padding: 0;
}
+
li {
display: inline-block;
margin: 0 10px;
}
+
a {
color: #42b983;
}
+
.left {
background-color: #e8e7ee;
height: 100%;
@@ -1076,10 +995,12 @@ a {
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
+
.title {
color: #999999;
font-size: 28px;
}
+
.card {
background-color: #f5f5f5;
height: 50px;
@@ -1100,36 +1021,45 @@ a {
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
overflow-y: auto;
+
.tabs {
height: 100%;
+
/deep/.el-tabs__header {
margin: 0px;
}
+
/deep/ .el-tabs__content {
height: 100%;
}
}
+
&::-webkit-scrollbar {
/*滚动条整体样式*/
- width: 10px; /*高宽分别对应横竖滚动条的尺寸*/
+ width: 10px;
+ /*高宽分别对应横竖滚动条的尺寸*/
height: 1px;
}
+
&::-webkit-scrollbar-thumb {
/*滚动条里面小方块*/
border-radius: 10px;
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
background: #c7c7cb;
}
+
&::-webkit-scrollbar-track {
/*滚动条里面轨道*/
box-shadow: inset 0 0 5px rgba(0, 0, 0, 0.2);
border-radius: 10px;
background: #ededed;
}
+
.system {
height: 100%;
width: 100%;
}
+
.App {
height: 100%;
width: 100%;
@@ -1139,10 +1069,12 @@ a {
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
+
.format {
width: 100%;
height: 300px;
border-bottom: 1px rgb(224, 224, 224) solid;
+
.title {
font-size: 14px;
width: 150px;
@@ -1155,6 +1087,7 @@ a {
background-color: rgb(240, 240, 240);
font-weight: bold;
}
+
.tips {
font-size: 14px;
padding: 10px;
@@ -1163,22 +1096,27 @@ a {
align-items: center;
text-align: left;
}
+
.service {
height: 150px;
display: flex;
align-items: center;
justify-content: flex-start;
+
.lable {
margin: 20px;
font-size: 14px;
}
+
.el-select {
width: 150px;
}
+
.el-input {
width: 180px;
}
}
+
.el-button {
color: rgb(154, 202, 128);
width: 120px;
@@ -1189,12 +1127,15 @@ a {
float: right;
margin-right: 25px;
}
+
.el-button:hover {
background-color: white;
}
+
.el-button:active {
background-color: white;
}
+
.el-button:focus {
background-color: white;
}
@@ -1204,6 +1145,7 @@ a {
width: 100%;
height: 300px;
border-bottom: 1px rgb(224, 224, 224) solid;
+
.title {
margin-top: 10px;
font-size: 14px;
@@ -1217,6 +1159,7 @@ a {
background-color: rgb(240, 240, 240);
font-weight: bold;
}
+
.tips {
font-size: 14px;
padding: 10px;
@@ -1224,22 +1167,27 @@ a {
justify-content: flex-start;
align-items: center;
}
+
.service {
height: 150px;
display: flex;
align-items: center;
justify-content: flex-start;
+
.lable {
margin: 20px;
font-size: 14px;
}
+
.el-select {
width: 150px;
}
+
.el-input {
width: 180px;
}
}
+
.el-button {
color: rgb(154, 202, 128);
width: 120px;
@@ -1250,21 +1198,26 @@ a {
float: right;
margin-right: 25px;
}
+
.el-button:hover {
background-color: white;
}
+
.el-button:active {
background-color: white;
}
+
.el-button:focus {
background-color: white;
}
}
}
+
.dispose {
height: 100%;
width: 100%;
}
+
.brief {
height: 90%;
width: 100%;
@@ -1274,10 +1227,12 @@ a {
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
+
.el-table {
position: absolute;
z-index: 0;
}
+
.add-button {
position: absolute;
top: 6px;
@@ -1286,6 +1241,7 @@ a {
}
}
}
+
.right {
background-color: #c8cfd7;
height: 100%;
@@ -1295,10 +1251,12 @@ a {
box-sizing: border-box;
-webkit-box-sizing: border-box;
-moz-box-sizing: border-box;
+
.title {
color: #999999;
font-size: 28px;
}
+
.log {
padding: 20px;
font-size: 18px;
@@ -1311,11 +1269,13 @@ a {
-moz-box-sizing: border-box;
}
}
+
.toMain {
position: absolute;
right: 200px;
font-size: 16px;
z-index: 1;
+
.link {
color: blue;
cursor: pointer;
diff --git a/src/renderer/components/dispose.vue b/src/renderer/components/dispose.vue
index 2625bcb..c958af6 100644
--- a/src/renderer/components/dispose.vue
+++ b/src/renderer/components/dispose.vue
@@ -4,12 +4,7 @@
LogLevel
-
+
{{ $t("dispose.infoTips") }}
@@ -17,12 +12,7 @@
AutoRetryTimes
-
+
{{ $t("dispose.errorTips1") }}
@@ -68,14 +58,11 @@
{{ $t("dispose.isReservetask") }}
-
+ ">
UploadSharedDir
@@ -83,16 +70,19 @@
{{ $t("dispose.isUpload") }}
-
+
AuthorizationCode
+
+
{{ $t("dispose.authCodeTips") }}
+
+
+
+ ">
{{ $t("work.submit") }}
@@ -146,7 +136,18 @@ export default {
label: "FATAL",
},
],
- iniData: null,
+ iniData: {
+ LogLevel: 'INFO',
+ AutoRetryTimes: 0,
+ TaskDir: '',
+ SharedDir: '',
+ RejectConfig: false,
+ StopOnFailure: false,
+ KeepCombinedImage: false,
+ CleanTaskFile: false,
+ UploadSharedDir: false,
+ AuthorizationCode: ''
+ },
AutoRetryTimes: null,
LogLevel: "TRACE",
@@ -205,34 +206,35 @@ export default {
that.iniData.LogLevel = data.LogLevel ? data.LogLevel : "";
that.iniData.CleanTaskFile =
data.CleanTaskFile == "true" ||
- data.CleanTaskFile == "True" ||
- data.CleanTaskFile
+ data.CleanTaskFile == "True" ||
+ data.CleanTaskFile
? true
: false;
that.iniData.KeepCombinedImage =
data.KeepCombinedImage == "true" ||
- data.KeepCombinedImage == "True" ||
- data.KeepCombinedImage
+ data.KeepCombinedImage == "True" ||
+ data.KeepCombinedImage
? true
: false;
that.iniData.RejectConfig =
data.RejectConfig == "true" ||
- data.RejectConfig == "True" ||
- data.RejectConfig
+ data.RejectConfig == "True" ||
+ data.RejectConfig
? true
: false;
that.iniData.StopOnFailure =
data.StopOnFailure == "true" ||
- data.StopOnFailure == "True" ||
- data.StopOnFailure
+ data.StopOnFailure == "True" ||
+ data.StopOnFailure
? true
: false;
that.iniData.UploadSharedDir =
data.UploadSharedDir == "true" ||
- data.UploadSharedDir == "True" ||
- data.UploadSharedDir
+ data.UploadSharedDir == "True" ||
+ data.UploadSharedDir
? true
: false;
+ that.iniData.AuthorizationCode = data.AuthorizationCode ? data.AuthorizationCode : "";
console.log(data);
}
});
@@ -298,6 +300,7 @@ export default {
-moz-box-sizing: border-box;
display: flex;
flex-direction: column;
+
.title {
font-size: 14px;
font-weight: bold;
@@ -310,38 +313,45 @@ export default {
align-items: center;
background-color: rgb(240, 240, 240);
}
+
.row {
display: flex;
flex-direction: row;
justify-content: flex-start;
align-items: center;
margin-top: 20px;
+
.lable {
width: 200px;
margin-left: 20px;
font-size: 14px;
text-align: left;
}
+
.el-input {
width: 200px;
margin-left: 20px;
}
+
.el-select {
width: 200px;
margin-left: 20px;
}
+
.switch {
display: flex;
margin-left: 20px;
justify-content: flex-start;
width: 200px;
}
+
.tips {
font-size: 14px;
margin-left: 20px;
width: calc(100% - 440px);
text-align: left;
}
+
.el-button {
color: rgb(154, 202, 128);
width: 120px;
@@ -350,12 +360,15 @@ export default {
border-radius: 1px;
box-shadow: 1px 0px 2px 0px grey;
}
+
.el-button:hover {
background-color: white;
}
+
.el-button:active {
background-color: white;
}
+
.el-button:focus {
background-color: white;
}
diff --git a/src/renderer/components/main.vue b/src/renderer/components/main.vue
index e61cbe5..e4752e1 100644
--- a/src/renderer/components/main.vue
+++ b/src/renderer/components/main.vue
@@ -1025,6 +1025,13 @@ export default {
url: '/web/get_printer_info'
})
.then((res) => {
+ if (!res.data || !res.data.printerList) {
+ console.warn('获取工作站列表返回的数据格式不正确:', res)
+ this.infoData = []
+ this.$message.error(this.$t('main.notConnected') || '获取工作站列表失败')
+ return
+ }
+
let infoData = [...this.infoData]
this.infoData = res.data.printerList.map((item, index) => {
let child = { ...item }
@@ -1038,7 +1045,7 @@ export default {
}
})
// console.log('infoData', this.infoData)
- if (!res.data.printerList || res.data.printerList.length == 0) {
+ if (res.data.printerList.length == 0) {
this.$message.error(this.$t('main.notConnected'))
}
let DualSide = 0 //默认是单面
@@ -1077,7 +1084,9 @@ export default {
this.DualSide = DualSide
})
.catch((e) => {
-
+ console.error('获取工作站列表失败:', e)
+ this.infoData = []
+ this.$message.error(this.$t('main.notConnected') || '获取工作站列表失败,请检查网络连接')
})
},
// 清除报错通知
diff --git a/src/renderer/components/systemControl.vue b/src/renderer/components/systemControl.vue
index c02755c..e6e0cd3 100644
--- a/src/renderer/components/systemControl.vue
+++ b/src/renderer/components/systemControl.vue
@@ -9,24 +9,14 @@
state == null
? this.$t("systemControl.detecting")
: state
- ? this.$t("systemControl.start")
- : this.$t("systemControl.stop")
+ ? this.$t("systemControl.start")
+ : this.$t("systemControl.stop")
}}
{{ $t("systemControl.tips1") }}