大屏修改
This commit is contained in:
2
unpackage/cache/apk/apkurl
vendored
2
unpackage/cache/apk/apkurl
vendored
@@ -1 +1 @@
|
||||
https://app.liuyingyong.cn/build/download/f08bbf50-0170-11f1-abb5-2d31e3ed3876
|
||||
https://app.liuyingyong.cn/build/download/015ec8a0-42a9-11f1-bc7c-e56616a1224d
|
||||
2
unpackage/cache/apk/cmManifestCache.json
vendored
2
unpackage/cache/apk/cmManifestCache.json
vendored
File diff suppressed because one or more lines are too long
4
unpackage/cache/cloudcertificate/certini
vendored
4
unpackage/cache/cloudcertificate/certini
vendored
@@ -1,4 +1,4 @@
|
||||
[General]
|
||||
andrCertfile=package.keystore
|
||||
andrCertAlias=H5030C5DA
|
||||
andrCertPass="W29ipqz66AeiuWXdgp/Yfw=="
|
||||
andrCertAlias=H52AA0236
|
||||
andrCertPass="hHI0OSKD0xr/JbYQhViEkA=="
|
||||
|
||||
BIN
unpackage/cache/cloudcertificate/package.keystore
vendored
BIN
unpackage/cache/cloudcertificate/package.keystore
vendored
Binary file not shown.
BIN
unpackage/cache/wgt/H5030C5DA/img/bj.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/bj.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 587 KiB |
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 8.1 KiB |
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang_tou.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang_tou.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 2.1 KiB |
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang_you.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/kuang_you.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 2.5 KiB |
BIN
unpackage/cache/wgt/H5030C5DA/img/quan.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/quan.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 6.0 KiB |
BIN
unpackage/cache/wgt/H5030C5DA/img/tou.png
vendored
BIN
unpackage/cache/wgt/H5030C5DA/img/tou.png
vendored
Binary file not shown.
|
Before Width: | Height: | Size: 41 KiB |
45
unpackage/cache/wgt/H5030C5DA/js/echarts.min.js
vendored
45
unpackage/cache/wgt/H5030C5DA/js/echarts.min.js
vendored
File diff suppressed because one or more lines are too long
25224
unpackage/cache/wgt/H5030C5DA/js/echarts.min.old.js
vendored
25224
unpackage/cache/wgt/H5030C5DA/js/echarts.min.old.js
vendored
File diff suppressed because it is too large
Load Diff
180
unpackage/cache/wgt/H5030C5DA/json/pie.json
vendored
180
unpackage/cache/wgt/H5030C5DA/json/pie.json
vendored
@@ -1,180 +0,0 @@
|
||||
{
|
||||
"kczl":"888716",
|
||||
"zhw":"6542",
|
||||
"rkl":"5",
|
||||
"ckl":"8",
|
||||
"pie": [{
|
||||
"value": 20,
|
||||
"name": "空货位"
|
||||
},
|
||||
{
|
||||
"value": 18,
|
||||
"name": "满货位"
|
||||
},
|
||||
{
|
||||
"value": 10,
|
||||
"name": "入库已分配"
|
||||
},
|
||||
{
|
||||
"value": 8,
|
||||
"name": "出库已分配"
|
||||
},
|
||||
{
|
||||
"value": 12,
|
||||
"name": "入库需盘点"
|
||||
},
|
||||
{
|
||||
"value": 5,
|
||||
"name": "出库需盘点"
|
||||
}
|
||||
],
|
||||
"statistic": [{
|
||||
"mouth": "1",
|
||||
"入库": 1,
|
||||
"出库": 1
|
||||
},
|
||||
{
|
||||
"mouth": "2",
|
||||
"入库": 3,
|
||||
"出库": 3
|
||||
},
|
||||
{
|
||||
"mouth": "3",
|
||||
"入库": 4,
|
||||
"出库": 5
|
||||
},
|
||||
{
|
||||
"mouth": "4",
|
||||
"入库": 6,
|
||||
"出库": 4
|
||||
},
|
||||
{
|
||||
"mouth": "5",
|
||||
"入库": 1,
|
||||
"出库": 4
|
||||
},
|
||||
{
|
||||
"mouth": "6",
|
||||
"入库": 6,
|
||||
"出库": 3
|
||||
},
|
||||
{
|
||||
"mouth": "7",
|
||||
"入库": 3,
|
||||
"出库": 5
|
||||
},
|
||||
{
|
||||
"mouth": "8",
|
||||
"入库": 6,
|
||||
"出库": 1
|
||||
},
|
||||
{
|
||||
"mouth": "9",
|
||||
"入库": 7,
|
||||
"出库": 4
|
||||
},
|
||||
{
|
||||
"mouth": "10",
|
||||
"入库": 5,
|
||||
"出库": 8
|
||||
},
|
||||
{
|
||||
"mouth": "11",
|
||||
"入库": 5,
|
||||
"出库": 6
|
||||
},
|
||||
{
|
||||
"mouth": "12",
|
||||
"入库": 3,
|
||||
"出库": 4
|
||||
},
|
||||
{
|
||||
"mouth": "13",
|
||||
"入库": 5,
|
||||
"出库": 2
|
||||
},
|
||||
{
|
||||
"mouth": "14",
|
||||
"入库": 7,
|
||||
"出库": 7
|
||||
},
|
||||
{
|
||||
"mouth": "15",
|
||||
"入库": 4,
|
||||
"出库": 5
|
||||
}
|
||||
],
|
||||
"bzrk": [5, 8, 4, 5, 6, 9, 5],
|
||||
"bzck": [6, 4, 9, 5, 4, 7, 4],
|
||||
"taskDetail": [{
|
||||
"jobId": "RY202205090001",
|
||||
"taskNo": "10196",
|
||||
"trayCode": "987789",
|
||||
"cargoSpaceId": "010100102",
|
||||
"type": "入库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090002",
|
||||
"taskNo": "10197",
|
||||
"trayCode": "111111",
|
||||
"cargoSpaceId": "010100103",
|
||||
"type": "入库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090003",
|
||||
"taskNo": "10198",
|
||||
"trayCode": "222222",
|
||||
"cargoSpaceId": "010100104",
|
||||
"type": "出库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090004",
|
||||
"taskNo": "10199",
|
||||
"trayCode": "333333",
|
||||
"cargoSpaceId": "010100201",
|
||||
"type": "出库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090002",
|
||||
"taskNo": "10197",
|
||||
"trayCode": "111111",
|
||||
"cargoSpaceId": "010100103",
|
||||
"type": "入库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090003",
|
||||
"taskNo": "10198",
|
||||
"trayCode": "222222",
|
||||
"cargoSpaceId": "010100104",
|
||||
"type": "出库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090004",
|
||||
"taskNo": "10199",
|
||||
"trayCode": "333333",
|
||||
"cargoSpaceId": "010100201",
|
||||
"type": "出库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090002",
|
||||
"taskNo": "10197",
|
||||
"trayCode": "111111",
|
||||
"cargoSpaceId": "010100103",
|
||||
"type": "入库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090003",
|
||||
"taskNo": "10198",
|
||||
"trayCode": "222222",
|
||||
"cargoSpaceId": "010100104",
|
||||
"type": "出库"
|
||||
},
|
||||
{
|
||||
"jobId": "RY202205090004",
|
||||
"taskNo": "10199",
|
||||
"trayCode": "333333",
|
||||
"cargoSpaceId": "010100201",
|
||||
"type": "出库"
|
||||
}
|
||||
]
|
||||
}
|
||||
1
unpackage/cache/wgt/H5030C5DA/manifest.json
vendored
1
unpackage/cache/wgt/H5030C5DA/manifest.json
vendored
@@ -1 +0,0 @@
|
||||
{"@platforms":["android","iPhone","iPad"],"id":"H5030C5DA","name":"FT541dp","version":{"name":"1.0","code":"100"},"description":"","icons":{"72":"icon.png"},"launch_path":"index.html","developer":{"name":"","email":"","url":""},"permissions":{"Accelerometer":{"description":"访问加速度感应器"},"Audio":{"description":"访问麦克风"},"Cache":{"description":"管理应用缓存"},"Console":{"description":"跟踪调试输出日志"},"Device":{"description":"访问设备信息"},"Downloader":{"description":"文件下载管理"},"Events":{"description":"应用扩展事件"},"File":{"description":"访问本地文件系统"},"Gallery":{"description":"访问系统相册"},"Invocation":{"description":"使用Native.js能力"},"Orientation":{"description":"访问方向感应器"},"Proximity":{"description":"访问距离感应器"},"Storage":{"description":"管理应用本地数据"},"Uploader":{"description":"管理文件上传任务"},"Runtime":{"description":"访问运行期环境"},"XMLHttpRequest":{"description":"跨域网络访问"},"Zip":{"description":"文件压缩与解压缩"},"Speech":{"description":"管理语音识别插件"},"Webview":{"description":"窗口管理"},"NativeUI":{"description":"原生UI控件"},"Navigator":{"description":"浏览器信息"},"NativeObj":{"description":"原生对象"}},"plus":{"splashscreen":{"autoclose":true,"waiting":true},"popGesture":"close","runmode":"normal","signature":"Sk9JTiBVUyBtYWlsdG86aHIyMDEzQGRjbG91ZC5pbw==","distribute":{"apple":{"appid":"","devices":"universal","frameworks":[],"mobileprovision":"","p12":"","password":""},"google":{"aliasname":"","keystore":"","packagename":"plus.H5030C5DA","password":"","permissions":["<uses-permission android:name=\"android.permission.CHANGE_NETWORK_STATE\"/>","<uses-permission android:name=\"android.permission.MOUNT_UNMOUNT_FILESYSTEMS\"/>","<uses-permission android:name=\"android.permission.READ_CONTACTS\"/>","<uses-permission android:name=\"android.permission.VIBRATE\"/>","<uses-permission android:name=\"android.permission.READ_LOGS\"/>","<uses-permission android:name=\"android.permission.ACCESS_WIFI_STATE\"/>","<uses-feature android:name=\"android.hardware.camera.autofocus\"/>","<uses-permission android:name=\"android.permission.WRITE_CONTACTS\"/>","<uses-permission android:name=\"android.permission.ACCESS_NETWORK_STATE\"/>","<uses-permission android:name=\"android.permission.CAMERA\"/>","<uses-permission android:name=\"android.permission.RECORD_AUDIO\"/>","<uses-permission android:name=\"android.permission.GET_ACCOUNTS\"/>","<uses-permission android:name=\"android.permission.MODIFY_AUDIO_SETTINGS\"/>","<uses-permission android:name=\"android.permission.READ_PHONE_STATE\"/>","<uses-permission android:name=\"android.permission.CHANGE_WIFI_STATE\"/>","<uses-permission android:name=\"android.permission.WAKE_LOCK\"/>","<uses-permission android:name=\"android.permission.CALL_PHONE\"/>","<uses-permission android:name=\"android.permission.FLASHLIGHT\"/>","<uses-permission android:name=\"android.permission.ACCESS_COARSE_LOCATION\"/>","<uses-feature android:name=\"android.hardware.camera\"/>","<uses-permission android:name=\"android.permission.ACCESS_FINE_LOCATION\"/>","<uses-permission android:name=\"android.permission.WRITE_SETTINGS\"/>"],"custompermissions":true},"orientation":["portrait-primary"],"icons":{"ios":{"ipad":{"normal":"","normal7":"","retina":"","retina7":"","settings-normal":"","settings-retina":"","spotlight-normal":"","spotlight-normal7":"","spotlight-retina":"","spotlight-retina7":""},"iphone":{"normal":"","retina":"","retina7":"","retina8":"","settings-normal":"","settings-retina":"","settings-retina8":"","spotlight-normal":"","spotlight-retina":"","spotlight-retina7":""},"prerendered":true},"android":{"ldpi":"","mdpi":""}},"splashscreen":{"ios":{"iphone":{"default":"","retina35":"","retina40":"","retina47":"","retina55":"","retina55l":""},"ipad":{"portrait":"","portrait-retina":"","landscape":"","landscape-retina":"","portrait7":"","portrait-retina7":"","landscape7":"","landscape-retina7":""}},"android":{"mdpi":"","ldpi":"","hdpi":"","xhdpi":"","xxhdpi":""}},"ios":{"dSYMs":false}},"adid":"126168020307"},"screenOrientation":["portrait-primary"]}
|
||||
@@ -80,7 +80,7 @@ body {
|
||||
.lanes-container {
|
||||
display: flex;
|
||||
justify-content: space-between;
|
||||
height: 75%;
|
||||
height: 60%;
|
||||
width: 100%;
|
||||
}
|
||||
|
||||
@@ -125,7 +125,7 @@ body {
|
||||
}
|
||||
|
||||
.alarm-section {
|
||||
height: 23%;
|
||||
height: 37%;
|
||||
width: 100%;
|
||||
background-image: url('../img/kuang.png');
|
||||
background-size: 100% 100%;
|
||||
@@ -137,7 +137,7 @@ body {
|
||||
position: absolute;
|
||||
width: 20%;
|
||||
height: 1px;
|
||||
top: 10%; /* Changed from margin-top to top for height-relative positioning */
|
||||
top: 6%;
|
||||
left: 1%;
|
||||
margin-top: 0;
|
||||
margin-left: 0;
|
||||
@@ -186,15 +186,15 @@ body {
|
||||
|
||||
.alarm-list-container {
|
||||
position: absolute;
|
||||
top: 30%; /* Moved down to prevent overlap with title */
|
||||
top: 18%;
|
||||
width: 96%;
|
||||
left: 2%;
|
||||
height: 65%; /* Adjusted height */
|
||||
height: 78%;
|
||||
overflow: hidden;
|
||||
}
|
||||
|
||||
.alarm-content-scroll {
|
||||
height: calc(100% - 40px);
|
||||
height: calc(100% - 44px);
|
||||
overflow: hidden;
|
||||
position: relative;
|
||||
width: 100%;
|
||||
@@ -216,13 +216,14 @@ body {
|
||||
|
||||
.alarm-item p {
|
||||
margin: 0;
|
||||
padding-top: 4px;
|
||||
padding-bottom: 2px;
|
||||
padding-top: 6px;
|
||||
padding-bottom: 6px;
|
||||
width: 25%;
|
||||
text-align: center;
|
||||
word-break: break-all;
|
||||
height: 35px;
|
||||
font-size: 26px;
|
||||
height: 44px;
|
||||
font-size: 28px;
|
||||
line-height: 32px;
|
||||
}
|
||||
|
||||
/* Reuse existing list styles for alarm */
|
||||
@@ -244,18 +245,18 @@ body {
|
||||
|
||||
.kuang>li>p {
|
||||
margin: 0;
|
||||
padding-top: 4px;
|
||||
padding-bottom: 2px;
|
||||
padding-top: 6px;
|
||||
padding-bottom: 6px;
|
||||
width: 25%; /* 4 columns for alarm list */
|
||||
text-align: center;
|
||||
word-break: break-all;
|
||||
height: 35px;
|
||||
font-size: 26px;
|
||||
height: 44px;
|
||||
font-size: 28px;
|
||||
}
|
||||
.kuang>li:first-child {
|
||||
color: #ffb742;
|
||||
text-align: center;
|
||||
height: 40px;
|
||||
height: 44px;
|
||||
background: #013132;
|
||||
/* font-weight: bold; */
|
||||
font-size: 30px;
|
||||
@@ -291,3 +292,160 @@ body {
|
||||
font-weight: bold;
|
||||
font-size: 30px;
|
||||
}
|
||||
|
||||
/* ===== 服务器设置按钮 ===== */
|
||||
.setting-btn-box {
|
||||
position: absolute;
|
||||
top: 50%;
|
||||
left: 1%;
|
||||
transform: translateY(-50%);
|
||||
z-index: 20;
|
||||
}
|
||||
|
||||
.setting-btn {
|
||||
background: rgba(0, 255, 249, 0.08);
|
||||
border: 1px solid #00fff9;
|
||||
color: #00fff9;
|
||||
font-size: 20px;
|
||||
padding: 6px 18px;
|
||||
border-radius: 6px;
|
||||
cursor: pointer;
|
||||
letter-spacing: 2px;
|
||||
transition: background 0.2s;
|
||||
}
|
||||
|
||||
.setting-btn:hover {
|
||||
background: rgba(0, 255, 249, 0.2);
|
||||
}
|
||||
|
||||
/* ===== 弹窗遮罩 ===== */
|
||||
.setting-modal-mask {
|
||||
display: none;
|
||||
position: fixed;
|
||||
top: 0; left: 0;
|
||||
width: 100%; height: 100%;
|
||||
background: rgba(0, 0, 0, 0.6);
|
||||
z-index: 1000;
|
||||
}
|
||||
|
||||
/* ===== 弹窗主体 ===== */
|
||||
.setting-modal {
|
||||
display: none;
|
||||
position: fixed;
|
||||
top: 50%; left: 50%;
|
||||
transform: translate(-50%, -50%);
|
||||
width: 480px;
|
||||
background: #021e23;
|
||||
border: 1px solid #00fff9;
|
||||
border-radius: 12px;
|
||||
z-index: 1001;
|
||||
box-shadow: 0 0 40px rgba(0, 255, 249, 0.3);
|
||||
padding: 0 0 24px;
|
||||
}
|
||||
|
||||
.setting-modal-title {
|
||||
text-align: center;
|
||||
color: #00fff9;
|
||||
font-size: 28px;
|
||||
font-weight: bold;
|
||||
padding: 20px 0 14px;
|
||||
border-bottom: 1px solid rgba(0, 255, 249, 0.2);
|
||||
letter-spacing: 4px;
|
||||
}
|
||||
|
||||
.setting-modal-body {
|
||||
padding: 24px 36px 8px;
|
||||
}
|
||||
|
||||
.setting-row {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
margin-bottom: 22px;
|
||||
}
|
||||
|
||||
.setting-label {
|
||||
color: #ffb742;
|
||||
font-size: 24px;
|
||||
width: 80px;
|
||||
flex-shrink: 0;
|
||||
letter-spacing: 2px;
|
||||
}
|
||||
|
||||
.setting-options {
|
||||
display: flex;
|
||||
gap: 16px;
|
||||
}
|
||||
|
||||
.setting-option {
|
||||
padding: 8px 28px;
|
||||
border: 1px solid #00fff9;
|
||||
border-radius: 6px;
|
||||
color: #00fff9;
|
||||
font-size: 22px;
|
||||
cursor: pointer;
|
||||
transition: all 0.2s;
|
||||
letter-spacing: 2px;
|
||||
}
|
||||
|
||||
.setting-option:hover {
|
||||
background: rgba(0, 255, 249, 0.15);
|
||||
}
|
||||
|
||||
.setting-option.active {
|
||||
background: #00fff9;
|
||||
color: #021e23;
|
||||
font-weight: bold;
|
||||
}
|
||||
|
||||
.setting-preview {
|
||||
margin-top: 4px;
|
||||
padding: 10px 14px;
|
||||
background: rgba(0, 255, 249, 0.06);
|
||||
border-radius: 6px;
|
||||
color: #aafffd;
|
||||
font-size: 18px;
|
||||
line-height: 1.8;
|
||||
min-height: 56px;
|
||||
letter-spacing: 1px;
|
||||
}
|
||||
|
||||
.setting-modal-footer {
|
||||
display: flex;
|
||||
justify-content: center;
|
||||
gap: 24px;
|
||||
margin-top: 20px;
|
||||
}
|
||||
|
||||
.setting-save-btn {
|
||||
background: #00fff9;
|
||||
color: #021e23;
|
||||
border: none;
|
||||
font-size: 22px;
|
||||
font-weight: bold;
|
||||
padding: 8px 40px;
|
||||
border-radius: 6px;
|
||||
cursor: pointer;
|
||||
letter-spacing: 4px;
|
||||
transition: opacity 0.2s;
|
||||
}
|
||||
|
||||
.setting-save-btn:hover {
|
||||
opacity: 0.85;
|
||||
}
|
||||
|
||||
.setting-cancel-btn {
|
||||
background: transparent;
|
||||
color: #aaa;
|
||||
border: 1px solid #555;
|
||||
font-size: 22px;
|
||||
padding: 8px 40px;
|
||||
border-radius: 6px;
|
||||
cursor: pointer;
|
||||
letter-spacing: 4px;
|
||||
transition: all 0.2s;
|
||||
}
|
||||
|
||||
.setting-cancel-btn:hover {
|
||||
border-color: #888;
|
||||
color: #ccc;
|
||||
}
|
||||
@@ -22,6 +22,40 @@
|
||||
<div class="shijian"></div>
|
||||
<div class="riqi"></div>
|
||||
</div>
|
||||
<!-- 服务器设置按钮 -->
|
||||
<div class="setting-btn-box">
|
||||
<button class="setting-btn" onclick="openSettingModal()">⚙ 服务器设置</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<!-- 服务器设置弹窗 -->
|
||||
<div class="setting-modal-mask" id="settingModalMask" onclick="closeSettingModal()"></div>
|
||||
<div class="setting-modal" id="settingModal">
|
||||
<div class="setting-modal-title">服务器设置</div>
|
||||
<div class="setting-modal-body">
|
||||
<!-- 仓库选择 -->
|
||||
<div class="setting-row">
|
||||
<div class="setting-label">仓库</div>
|
||||
<div class="setting-options" id="warehouseOptions">
|
||||
<div class="setting-option" data-value="02" onclick="selectOption('warehouse', this)">二联</div>
|
||||
<div class="setting-option" data-value="01" onclick="selectOption('warehouse', this)">三联</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 端口选择 -->
|
||||
<div class="setting-row">
|
||||
<div class="setting-label">端口</div>
|
||||
<div class="setting-options" id="typeOptions">
|
||||
<div class="setting-option" data-value="1" onclick="selectOption('type', this)">入库端</div>
|
||||
<div class="setting-option" data-value="2" onclick="selectOption('type', this)">出库端</div>
|
||||
</div>
|
||||
</div>
|
||||
<!-- 当前生效配置预览 -->
|
||||
<div class="setting-preview" id="settingPreview"></div>
|
||||
</div>
|
||||
<div class="setting-modal-footer">
|
||||
<button class="setting-save-btn" onclick="saveSettings()">保 存</button>
|
||||
<button class="setting-cancel-btn" onclick="closeSettingModal()">取 消</button>
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div class="content-wrapper">
|
||||
@@ -1,8 +1,13 @@
|
||||
var ip="http://172.19.50.70:10012"
|
||||
//仓库 01 三联 02 二联
|
||||
var warehouseId="01"
|
||||
//入出库端 1 入库 2 出库
|
||||
var type="1"
|
||||
// ===== 仓库/端口 IP 映射 =====
|
||||
var warehouseIpMap = {
|
||||
"02": "http://172.19.40.46:10012", // 二联
|
||||
"01": "http://172.19.50.70:10012" // 三联
|
||||
};
|
||||
|
||||
// ===== 从 localStorage 读取配置,默认二联/入库端 =====
|
||||
var warehouseId = localStorage.getItem("warehouseId") || "02";
|
||||
var type = localStorage.getItem("type") || "1";
|
||||
var ip = warehouseIpMap[warehouseId];
|
||||
function getData() {
|
||||
$.ajax({
|
||||
url: ip+"/api/stock/all",
|
||||
@@ -405,7 +410,7 @@ $(document).ready(function() {
|
||||
getLaneData();
|
||||
window.setInterval(getLaneData, 1500);
|
||||
|
||||
window.setInterval(scrollAlarmList, 1000);
|
||||
// window.setInterval(scrollAlarmList, 1000);
|
||||
})
|
||||
|
||||
function getAlarmData() {
|
||||
@@ -668,14 +673,14 @@ function scrollAlarmList() {
|
||||
var firstItem = list.find("li:first");
|
||||
if (firstItem.length === 0) return;
|
||||
|
||||
var height = firstItem.height();
|
||||
var height = firstItem.outerHeight(true);
|
||||
// Default to some height if 0 (e.g. if hidden)
|
||||
if (height === 0) height = 30;
|
||||
if (height === 0) height = 44;
|
||||
|
||||
if (list.children().length > 3) {
|
||||
if (list.children().length >= 1) {
|
||||
firstItem.animate({
|
||||
marginTop: -height + "px"
|
||||
}, 500, function() {
|
||||
}, 600, function() {
|
||||
firstItem.css("marginTop", 0).appendTo(list);
|
||||
});
|
||||
}
|
||||
@@ -721,3 +726,71 @@ function mockLaneData() {
|
||||
$("#" + id).html(content);
|
||||
});
|
||||
}
|
||||
|
||||
// ===== 服务器设置弹窗 =====
|
||||
|
||||
// 临时选中状态(未保存前不生效)
|
||||
var _pendingWarehouse = warehouseId;
|
||||
var _pendingType = type;
|
||||
|
||||
function openSettingModal() {
|
||||
_pendingWarehouse = warehouseId;
|
||||
_pendingType = type;
|
||||
|
||||
// 初始化选中状态
|
||||
$("#warehouseOptions .setting-option").each(function() {
|
||||
$(this).toggleClass("active", $(this).data("value") === _pendingWarehouse);
|
||||
});
|
||||
$("#typeOptions .setting-option").each(function() {
|
||||
$(this).toggleClass("active", $(this).data("value") + "" === _pendingType + "");
|
||||
});
|
||||
|
||||
updatePreview();
|
||||
$("#settingModalMask").fadeIn(200);
|
||||
$("#settingModal").fadeIn(200);
|
||||
}
|
||||
|
||||
function closeSettingModal() {
|
||||
$("#settingModalMask").fadeOut(200);
|
||||
$("#settingModal").fadeOut(200);
|
||||
}
|
||||
|
||||
function selectOption(group, el) {
|
||||
var val = $(el).data("value") + "";
|
||||
if (group === "warehouse") {
|
||||
_pendingWarehouse = val;
|
||||
$("#warehouseOptions .setting-option").removeClass("active");
|
||||
} else {
|
||||
_pendingType = val;
|
||||
$("#typeOptions .setting-option").removeClass("active");
|
||||
}
|
||||
$(el).addClass("active");
|
||||
updatePreview();
|
||||
}
|
||||
|
||||
function updatePreview() {
|
||||
var whName = _pendingWarehouse === "02" ? "二联" : "三联";
|
||||
var typeName = _pendingType === "1" ? "入库端" : "出库端";
|
||||
var previewIp = warehouseIpMap[_pendingWarehouse];
|
||||
$("#settingPreview").html(
|
||||
"仓库:<b>" + whName + "</b> 端口:<b>" + typeName + "</b><br>" +
|
||||
"IP:" + previewIp
|
||||
);
|
||||
}
|
||||
|
||||
function saveSettings() {
|
||||
// 更新全局变量
|
||||
warehouseId = _pendingWarehouse;
|
||||
type = _pendingType;
|
||||
ip = warehouseIpMap[warehouseId];
|
||||
|
||||
// 持久化到 localStorage
|
||||
localStorage.setItem("warehouseId", warehouseId);
|
||||
localStorage.setItem("type", type);
|
||||
|
||||
closeSettingModal();
|
||||
|
||||
// 立即刷新数据
|
||||
getAlarmData();
|
||||
getLaneData();
|
||||
}
|
||||
Reference in New Issue
Block a user