1029 lines
41 KiB
HTML
1029 lines
41 KiB
HTML
<!DOCTYPE html>
|
||
<html>
|
||
|
||
<head>
|
||
<meta charset="UTF-8" />
|
||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1.0, user-scalable=0" />
|
||
<meta http-equiv="X-UA-Compatible" content="IE=edge,chrome=1" />
|
||
<meta name="renderer" content="webkit" />
|
||
<meta name="format-detection" content="telephone=no" />
|
||
<meta name="apple-mobile-web-app-capable" content="yes" />
|
||
<meta name="apple-mobile-web-app-status-bar-style" content="black" />
|
||
<meta name="format-detection" content="telephone=no" />
|
||
<meta name="applicable-device" content="pc,mobile" />
|
||
<link rel="shortcut icon" href="/favicon.ico" />
|
||
<title>熙讯-服务支持-下载专区</title>
|
||
<meta name="keywords" content="熙讯,LED控制系统,LED控制卡,播控系统,软件服务,熙讯下载,解决方案提供商-熙讯、熙讯云科技、熙讯电子科技有限公司、熙讯官网、熙讯下载" />
|
||
<meta name="description"
|
||
content="上海熙讯电子科技有限公司是全球户外数字传媒与LED显示控制系统解决方案服务商,致力于以互联网技术和智能系统推动行业的产业升级,为打造数字智慧城市贡献力量。10年来我们精耕于这一领域,凭借卓越的创新能力、突出的定制能力、优秀的服务能力、赢得了全球客户的信任!" />
|
||
<link rel="stylesheet" href="/static/iconfont/iconfont.css" />
|
||
<link rel="stylesheet" type="text/css" href="/static/layui/css/layui.css" />
|
||
<link rel="stylesheet" type="text/css" href="/static/css/layout.css" />
|
||
|
||
<script type="text/javascript" src="/static/js/jquery.min.js"></script>
|
||
<script type="text/javascript" src="/static/js/BeerSlider.js"></script>
|
||
<meta name="Author" content="xixun" />
|
||
</head>
|
||
|
||
<script>
|
||
var type = navigator.appName;
|
||
if (type == "Netscape") var lang = navigator.language;
|
||
else var lang = navigator.userLanguage;
|
||
var lang = lang.substr(0, 2);
|
||
|
||
//英文路径
|
||
var url = window.location;
|
||
//获取网页的来路
|
||
|
||
function getQueryString(name) {
|
||
const url_string = window.location.href; // window.location.href
|
||
const url = new URL(url_string);
|
||
if (url.searchParams.get(name) != null) {
|
||
Cookie_Set("language", url.searchParams.get(name));
|
||
}
|
||
}
|
||
getQueryString("language");
|
||
console.log(!Cookie_Get("language"), lang);
|
||
if (!Cookie_Get("language") && lang == "en") {
|
||
window.location.href = "http://sysolution.net/";
|
||
}
|
||
|
||
function Cookie_Set(name, val) {
|
||
// var strsec = getsec(time);
|
||
var exp = new Date();
|
||
// exp.setTime(exp.getTime() + strsec * 1);
|
||
document.cookie = name + "=" + val + ";path=/";
|
||
}
|
||
function Cookie_Get(name) {
|
||
var arr,
|
||
reg = new RegExp("(^| )" + name + "=([^;]*)(;|$)");
|
||
if ((arr = document.cookie.match(reg))) {
|
||
return arr[2];
|
||
} else {
|
||
return null;
|
||
}
|
||
}
|
||
function getsec(str) {
|
||
var str1 = str.substring(1, str.length) * 1;
|
||
var str2 = str.substring(0, 1);
|
||
if (str2 == "s") {
|
||
return str1 * 1000;
|
||
} else if (str2 == "h") {
|
||
return str1 * 60 * 60 * 1000;
|
||
} else if (str2 == "d") {
|
||
return str1 * 24 * 60 * 60 * 1000;
|
||
}
|
||
}
|
||
|
||
</script>
|
||
<style>
|
||
.bgRed {
|
||
background-color: #d35c5d;
|
||
}
|
||
|
||
.bgBlue {
|
||
background-color: lightsteelblue;
|
||
}
|
||
|
||
.form-group {
|
||
display: flex;
|
||
align-items: center;
|
||
margin-bottom: 0.6333vw;
|
||
}
|
||
|
||
.form-group>div {
|
||
margin-right: 0.6333vw;
|
||
font-size: .8333vw;
|
||
}
|
||
|
||
|
||
.form-group .form-control,
|
||
.form-group .form-file,
|
||
.form-group select {
|
||
padding-left: 8px;
|
||
padding: 8px 30px 8px 14px;
|
||
border: 1px solid #ccc;
|
||
border-radius: 0.2vw;
|
||
font-size: 0.8333vw;
|
||
box-sizing: border-box;
|
||
}
|
||
|
||
.form-group .form-file {
|
||
font-size: 0.8333vw;
|
||
}
|
||
|
||
.form-group select {
|
||
margin-right: 0.6333vw;
|
||
}
|
||
|
||
.form-group button {
|
||
background-color: lightsteelblue;
|
||
color: #fff;
|
||
border: none;
|
||
cursor: pointer;
|
||
font-size: 0.8333vw;
|
||
padding: 8px 12px;
|
||
border-radius: 2px;
|
||
}
|
||
|
||
.btns {
|
||
padding: 2px 10px;
|
||
border-radius: 3px;
|
||
background-color: lightsteelblue;
|
||
color: #fff;
|
||
border: none;
|
||
cursor: pointer;
|
||
font-size: .8333vw;
|
||
}
|
||
|
||
.layui-table {
|
||
width: 100%;
|
||
margin: 0px;
|
||
}
|
||
|
||
.layui-table thead th,
|
||
.layui-table thead td {
|
||
text-align: center;
|
||
}
|
||
|
||
.layui-table thead th {
|
||
background-color: #9dc9ff;
|
||
font-size: 0.9375vw;
|
||
font-weight: 700;
|
||
}
|
||
|
||
.layui-table tbody th,
|
||
.layui-table tbody td {
|
||
font-size: 0.8333vw;
|
||
}
|
||
|
||
.layui-table td,
|
||
.layui-table th {
|
||
position: relative;
|
||
height: 35px;
|
||
line-height: 35px;
|
||
}
|
||
|
||
.layui-table td,
|
||
.layui-table th {
|
||
padding: 0px;
|
||
}
|
||
|
||
/* @media screen and (max-width: 460px) {
|
||
|
||
.form-group>div {
|
||
font-size:16px;
|
||
}
|
||
|
||
.form-group .form-control,
|
||
.form-group .form-file,
|
||
.form-group select {
|
||
|
||
font-size:16px;
|
||
}
|
||
|
||
.form-group .form-file {
|
||
font-size:16px;
|
||
}
|
||
.form-group button {
|
||
font-size:16px;
|
||
}
|
||
|
||
.layui-table tbody th,
|
||
.layui-table tbody td {
|
||
font-size: 16px;
|
||
}
|
||
} */
|
||
</style>
|
||
|
||
<body>
|
||
<div class="header head3">
|
||
#include(navbar)
|
||
</div>
|
||
|
||
|
||
<div class="Lcrumbs">
|
||
<div class="container1260">
|
||
<a href="javascript:;">下载专区</a>
|
||
</div>
|
||
</div>
|
||
<div class="Bg">
|
||
<div class="container1260">
|
||
<div class="service_Software clearfix">
|
||
<div class="publicLeft publicLeft_download">
|
||
<div class="li">
|
||
<h5>软件<div class="liOn"></div>
|
||
</h5>
|
||
<div class="Downul2">
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="ul3 active">
|
||
<a href="/service/download/software/LedOK Express/index.html">LedOK
|
||
Express(PC端局域网节目编辑调试软件)</a>
|
||
<a href="/service/download/software/LEDOK Lite/index.html">LEDOK Lite(手机APP
|
||
异步播放盒)</a>
|
||
<a href="/service/download/software/I Led/index.html">I Led(手机APP 动画图文卡)</a>
|
||
<a href="/service/download/software/LedSet/index.html">LedSet2.3(Y08配屏软件)</a>
|
||
<a href="/service/download/software/oldProduct/index.html">老产品及停产配套软件</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
</div>
|
||
<div class="li ">
|
||
<h5>产品文档<div class="liOn"></div>
|
||
</h5>
|
||
<div class="Downul2">
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="t ">控制系统<div class="li3On"></div>
|
||
</div>
|
||
<div class="ul3 ">
|
||
<a
|
||
href="/service/download/product_document/control_system/commerce_display/index.html">智慧商显同异步播放盒系列</a>
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/lamp_pole/index.html">灯杆车载等异步全彩系列</a>
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/car_load/index.html">动画图文卡系列</a>
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/LCD/index.html">LCD系列</a>
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/sync_send/index.html">同步发送卡</a>
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/receive_card/index.html">接收卡</a>
|
||
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="t ">配件<div class="li3On"></div>
|
||
</div>
|
||
<div class="ul3 ">
|
||
<a class=""
|
||
href="/service/download/product_document/control_system/accessory/index.html">配件</a>
|
||
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="t ">视频处理<div class="li3On"></div>
|
||
</div>
|
||
<div class="ul3 ">
|
||
<a class=""
|
||
href="/service/download/product_document/video_process/2-in-1_video_process/index.html">二合一视频处理器</a>
|
||
<a class=""
|
||
href="/service/download/product_document/video_process/independent_control/index.html">独立主控</a>
|
||
<a class=""
|
||
href="/service/download/product_document/video_process/video_splicer/index.html">视频拼接器</a>
|
||
<a class=""
|
||
href="/service/download/product_document/video_process/multimedia_server/index.html">多媒体服务器</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="t ">软件服务<div class="li3On"></div>
|
||
</div>
|
||
<div class="ul3 ">
|
||
<a class=""
|
||
href="/service/download/product_document/xixun_software/SingleMachine/index.html">PC端局域网软件</a>
|
||
<a class=""
|
||
href="/service/download/product_document/xixun_software/AIPS/index.html">云平台</a>
|
||
<a class=""
|
||
href="/service/download/product_document/xixun_software/APP/index.html">APP</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
<div class="t ">老产品系列<div class="li3On"></div>
|
||
</div>
|
||
<div class="ul3 ">
|
||
<a class=""
|
||
href="/service/download/product_document/oldProduct/index.html">老产品系列</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
|
||
</div>
|
||
<div class="li active2">
|
||
<h5>固件程序<div class="liOn"></div>
|
||
</h5>
|
||
<div class="Downul2">
|
||
<div class="ul2">
|
||
<div class="li3">
|
||
|
||
<div class="ul3 active">
|
||
<a
|
||
href="/service/download/firmware_program/cardSystem/index.html">CardSystem(控制系统)</a>
|
||
<a
|
||
href="/service/download/firmware_program/xixunplayer/index.html">Xixunplayer(播放器)</a>
|
||
<a href="/service/download/firmware_program/conn/index.html">Conn</a>
|
||
<!-- <a href="/service/download/firmware_program/display/index.html">display</a> -->
|
||
<a
|
||
href="/service/download/firmware_program/systemCore/index.html">SystemCore</a>
|
||
<a href="/service/download/firmware_program/taxiAPP/index.html">TaxiAPP</a>
|
||
<a class="active"
|
||
href="/service/download/firmware_program/kd/index.html">KD系列配件</a>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
|
||
</div>
|
||
</div>
|
||
<div class="right">
|
||
<div role="tabpanel" class="tab-pane active" id="upgrade">
|
||
<form id="login">
|
||
<div class="form-group">
|
||
<input value="" id="password" class="form-control" type="password" placeholder="请输入密码"
|
||
aria-describedby="basic-addon1">
|
||
<button type="button" onclick="comfirmpassword()" style="margin-left: 15px;">确定</button>
|
||
</div>
|
||
</form>
|
||
<div id="fileList" style="display: none;">
|
||
<form>
|
||
<div style="display: flex;flex-wrap: wrap;">
|
||
<div class="form-group">
|
||
<div>请选择分辨率:</div>
|
||
<select id="selectResolutionRatio" onchange="searchFile()">
|
||
<option value="64_16">64_16</option>
|
||
<option value="64_32">64_32</option>
|
||
<option value="64_64">64_64</option>
|
||
<option value="96_16">96_16</option>
|
||
</select>
|
||
</div>
|
||
<div class="form-group">
|
||
<input class="form-control" type="text" id="input" placeholder="请输入文件名称">
|
||
<button type="button" onclick="searchFileName()"
|
||
style="margin-left: 15px;">搜索</button>
|
||
</div>
|
||
</div>
|
||
|
||
<div class="form-group">
|
||
<input class="form-file" type="file" id="file" style="border: none;">
|
||
<button type="button" id="btnUpload" onclick="uploadFile()">上传文件</button>
|
||
</div>
|
||
</form>
|
||
<div id="fileTable">
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
</div>
|
||
#include(footer)
|
||
<div class="Topping" id="ScrollTop"><i class="iconfont icon_top1"></i></div>
|
||
|
||
</body>
|
||
|
||
</html>
|
||
|
||
<!--百度分享脚本-->
|
||
<script type="text/javascript" src="/static/js/share.js"></script>
|
||
<!--select模拟插件-->
|
||
<script type="text/javascript" src="/static/js/select2.min.js"></script>
|
||
<!--省市区三级联动-->
|
||
<script type="text/javascript" src="https://pv.sohu.com/cityjson"></script>
|
||
<script type="text/javascript" src="/static/js/jquery.citys.js"></script>
|
||
<!--wow入场插件-->
|
||
<script type="text/javascript" src="/static/js/wow.min.js"></script>
|
||
<!-- 数字滚动插件 -->
|
||
<script type="text/javascript" src="/static/js/jquery.counterup.min.js"></script>
|
||
<script type="text/javascript" src="/static/js/waypoints.min.js"></script>
|
||
<!--swiper插件-->
|
||
<script type="text/javascript" src="/static/js/swiper.jquery.min.js"></script>
|
||
<!--瀑布流插件-->
|
||
<script src="/static/js/modernizr.custom.js"></script>
|
||
<script src="/static/js/masonry.pkgd.min.js"></script>
|
||
<script src="/static/js/imagesloaded.pkgd.min.js"></script>
|
||
<script src="/static/js/classie.js"></script>
|
||
<script src="/static/js/AnimOnScroll.js"></script>
|
||
<!--自定义-->
|
||
<script type="text/javascript" src="/js/layout.js"></script>
|
||
<script src="/static/layui/layui.js" charset="utf-8"></script>
|
||
<script>
|
||
layui.use(["laypage", "layer"], function () {
|
||
var laypage = layui.laypage,
|
||
layer = layui.layer;
|
||
|
||
//总页数低于页码总数
|
||
laypage.render({
|
||
elem: "demo0",
|
||
count: "4",
|
||
curr: "1",
|
||
limit: "12",
|
||
prev: " ",
|
||
next: " ",
|
||
jump: function (obj, first) {
|
||
//首次不执行
|
||
if (!first) {
|
||
//do something
|
||
location.href = "/service/download/index_" + obj.curr + ".html" + "?cat=" + "6";
|
||
}
|
||
},
|
||
});
|
||
});
|
||
$(".service_Software .right .con1 .box .UpdateSmBox").on('click', function () {
|
||
$(this).siblings(".Description_popUp").fadeIn()
|
||
})
|
||
$(".Description_popUp i").on('click', function () {
|
||
$(".Description_popUp").fadeOut()
|
||
})
|
||
$(".Description_popUp .con .off").on('click', function () {
|
||
$(".Description_popUp").fadeOut()
|
||
})
|
||
|
||
var url = "https://ledok.cn:798";
|
||
// load a template file, then render it with data
|
||
var footer = document.getElementById("__footer")
|
||
footer.innerHTML = new EJS({
|
||
url: 'footer.ejs'
|
||
}).render()
|
||
//nav
|
||
var menu = document.getElementById("__menu")
|
||
menu.innerHTML = new EJS({
|
||
url: 'menu.ejs'
|
||
}).render(fyx_navData)
|
||
|
||
function comfirmpassword(type) {
|
||
var password = $("#password").val()
|
||
if (type && type == "consumer") {
|
||
password = $("#consumerPassword").val()
|
||
}
|
||
if (password != "") {
|
||
$.ajax({
|
||
url: url + "/YunSign/check",
|
||
method: "post",
|
||
data: {
|
||
value: password
|
||
},
|
||
success: function (res) {
|
||
// console.log(res);
|
||
if (res.code == 200) {
|
||
if (type && type == "consumer") {
|
||
$("#consumerLogin").css("display", "none");
|
||
$("#consumerTabs").css("display", "block");
|
||
consumerList();
|
||
consumerCompanyNameAndresolution();
|
||
} else {
|
||
$("#login").css("display", "none");
|
||
$("#fileList").css("display", "block");
|
||
searchFile();
|
||
}
|
||
}
|
||
}
|
||
})
|
||
}
|
||
}
|
||
|
||
function searchFile() {
|
||
$.ajax({
|
||
url: url + "/YunSign/" + $("#selectResolutionRatio option:selected").val() + "/fileList",
|
||
method: "get",
|
||
success: function (res) {
|
||
// console.log(res.data)
|
||
if (res.code == 200 && res.data != null) {
|
||
console.log('打印res.data', res.data)
|
||
var html = "<table class='layui-table my-table' lay-even ><thead ><tr style='background-color: lightsteelblue;'><td>文件名称</td><td>操作</td></tr></thead><tbody>"
|
||
res.data.forEach(element => {
|
||
if (element.is_new) {
|
||
html += "<tr><td><a href=" + url + "/download/YunSign/" + $("#selectResolutionRatio option:selected").val() + "/" + element.file + ">" + element.file + "</a><label style='color:red;margin-left:6px;'>new!</label></td><td><button class='btns bgRed' style='background-color:#d35c5d' type='button' onclick=delfile(this)>删除</button><button style='margin-left:10px;' class='btns bgBlue' type='button' onclick=setNew(this)>设置为最新版本</button></td></tr>"
|
||
} else {
|
||
html += "<tr><td><a href=" + url + "/download/YunSign/" + $("#selectResolutionRatio option:selected").val() + "/" + element.file + ">" + element.file + "</a></td><td><button class='btns bgRed' style='background-color:#d35c5d' type='button' onclick=delfile(this)>删除</button><button style='margin-left:10px;' class='btns bgBlue' type='button' onclick=setNew(this)>设置为最新版本</button></td></tr>"
|
||
}
|
||
});
|
||
html += "</tbody></table>"
|
||
$("#fileTable").html(html);
|
||
} else {
|
||
console.log('打印测试')
|
||
var html = "<table border=1><thead><tr><td>文件名称</td><td>操作</td></tr></thead><tbody><tr><td colspan=2>暂无数据</td></tr></tbody><table>";
|
||
$("#fileTable").html(html);
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
function consumerCompanyNameAndresolution(type) {
|
||
if (type && type == "from") {
|
||
$("#consumerUploadSelectResolutionRatio option").remove();
|
||
$("#consumerUploadSelectResolutionRatio").append("<option value=''>请选择</option>")
|
||
$("#consumerUploadCompanyNameRatio option").remove();
|
||
$("#consumerUploadCompanyNameRatio").append("<option value=''>请选择</option>")
|
||
} else {
|
||
$("#consumerSelectResolutionRatio option").remove();
|
||
$("#consumerSelectResolutionRatio").append("<option value=''>请选择</option>")
|
||
$("#consumerCompanyNameRatio option").remove();
|
||
$("#consumerCompanyNameRatio").append("<option value=''>请选择</option>")
|
||
}
|
||
$.ajax({
|
||
url: url + "/consumer/resolution/list",
|
||
method: "get",
|
||
success: function (res) {
|
||
if (res.code == 200 && res.data != null) {
|
||
if (type && type == "from") {
|
||
for (let i = 0; i < res.data.length; i++) {
|
||
const element = res.data[i];
|
||
$("#consumerUploadSelectResolutionRatio").append("<option value='" + element._id + "'>" + element.name + "</option>")
|
||
}
|
||
} else {
|
||
for (let i = 0; i < res.data.length; i++) {
|
||
const element = res.data[i];
|
||
$("#consumerSelectResolutionRatio").append("<option value='" + element._id + "'>" + element.name + "</option>")
|
||
}
|
||
}
|
||
}
|
||
}
|
||
})
|
||
$.ajax({
|
||
url: url + "/consumer/company/list",
|
||
method: "get",
|
||
success: function (res) {
|
||
if (res.code == 200 && res.data != null) {
|
||
if (type && type == "from") {
|
||
for (let i = 0; i < res.data.length; i++) {
|
||
const element = res.data[i];
|
||
$("#consumerUploadCompanyNameRatio").append("<option value='" + element._id + "'>" + element.name + "</option>")
|
||
}
|
||
} else {
|
||
for (let i = 0; i < res.data.length; i++) {
|
||
const element = res.data[i];
|
||
$("#consumerCompanyNameRatio").append("<option value='" + element._id + "'>" + element.name + "</option>")
|
||
}
|
||
}
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function consumerClose() {
|
||
$(".consumerOverlay").css({ "display": "none" })
|
||
$(".consumerContent").css({ "display": "none" })
|
||
$("input[name='consumerFile']").val(null)
|
||
}
|
||
function consumerUploadShow() {
|
||
consumerCompanyNameAndresolution("from")
|
||
$(".consumerOverlay").css({ "display": "flex" })
|
||
$(".consumerContent").css({ "display": "block" })
|
||
}
|
||
function consumerUpload() {
|
||
var resolution = $("#consumerUploadSelectResolutionRatio option:selected").val()
|
||
var company = $("#consumerUploadCompanyNameRatio option:selected").val()
|
||
var files = $("#consumerFile")[0].files;
|
||
if (files.length <= 0) {
|
||
return alert("请选择图片或视频")
|
||
}
|
||
if (resolution == "") {
|
||
return alert("请选择分辨率")
|
||
}
|
||
if (company == "") {
|
||
return alert("请选择公司名")
|
||
}
|
||
var fd = new FormData();
|
||
fd.append("file", files[0]);
|
||
fd.append("resolutionId", resolution);
|
||
fd.append("companyId", company);
|
||
$.ajax({
|
||
url: url + "/consumer/media/upload",
|
||
method: "post",
|
||
data: fd,
|
||
processData: false,
|
||
contentType: false,
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerList();
|
||
}
|
||
consumerClose()
|
||
}
|
||
})
|
||
}
|
||
function consumerResolutionAdd() {
|
||
var resolutionInput = $("#resolutionInput").val()
|
||
if (resolutionInput == "") {
|
||
return alert("请输入分辨率")
|
||
}
|
||
$.ajax({
|
||
url: url + "/consumer/resolution/save",
|
||
method: "post",
|
||
data: { "name": resolutionInput },
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerResolution();
|
||
$("#resolutionInput").val(null)
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function consumerResolution() {
|
||
$("#consumerResolutionShow").css({ "display": "block" })
|
||
$.ajax({
|
||
url: url + "/consumer/resolution/list",
|
||
method: "get",
|
||
success: function (res) {
|
||
if (res.code == 200 && res.data != null) {
|
||
var html = "<table class='consumerTable' border=1 id='consumerResolutionTable'>"
|
||
+ "<thead>"
|
||
+ "<tr>"
|
||
+ "<th>像素</th><th>操作</th>"
|
||
+ "</tr>"
|
||
+ "</thead> "
|
||
+ "<tbody>"
|
||
res.data.forEach(element => {
|
||
html += "<tr>"
|
||
+ "<td>"
|
||
+ "<span>" + element.name + "</span>"
|
||
+ "</td>"
|
||
+ "<td>"
|
||
+ "<button class='btn btn-default' type='button' onclick='consumerResolutionDel(" + JSON.stringify(element._id) + ")'>删除</button>"
|
||
+ "</td>"
|
||
+ "</tr>"
|
||
|
||
});
|
||
html += "</tbody></table>"
|
||
$("#consumerResolutionTable").html(html);
|
||
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function consumerResolutionDel(val) {
|
||
$.ajax({
|
||
url: url + "/consumer/resolution/delete/" + val,
|
||
method: "delete",
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerResolution();
|
||
} else {
|
||
alert(res.msg)
|
||
}
|
||
},
|
||
error: function (res) {
|
||
alert(res.responseJSON.msg)
|
||
}
|
||
})
|
||
}
|
||
function consumerCompanyDel(val) {
|
||
$.ajax({
|
||
url: url + "/consumer/company/delete/" + val,
|
||
method: "delete",
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerCompany();
|
||
} else {
|
||
alert(res.msg)
|
||
}
|
||
},
|
||
error: function (res) {
|
||
// alert(res.responseJSON.msg)
|
||
alert("当前公司名正在使用")
|
||
}
|
||
})
|
||
}
|
||
function consumerCompanyAdd() {
|
||
var companyInput = $("#companyInput").val()
|
||
if (companyInput == "") {
|
||
return alert("请输入公司名")
|
||
}
|
||
$.ajax({
|
||
url: url + "/consumer/company/save",
|
||
method: "post",
|
||
data: { "name": companyInput },
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerCompany();
|
||
$("#companyInput").val(null)
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function consumerCompany() {
|
||
$("#consumerCompanyShow").css({ "display": "block" })
|
||
$.ajax({
|
||
url: url + "/consumer/company/list",
|
||
method: "get",
|
||
success: function (res) {
|
||
if (res.code == 200 && res.data != null) {
|
||
var html = "<table class='consumerTable' border=1 id='consumerCompanyTable'>"
|
||
+ "<thead>"
|
||
+ "<tr>"
|
||
+ "<th>公司名</th><th>操作</th>"
|
||
+ "</tr>"
|
||
+ "</thead> "
|
||
+ "<tbody>"
|
||
res.data.forEach(element => {
|
||
html += "<tr>"
|
||
+ "<td>"
|
||
+ "<span>" + element.name + "</span>"
|
||
+ "</td>"
|
||
+ "<td>"
|
||
+ "<button class='btn btn-default' type='button' onclick='consumerCompanyDel(" + JSON.stringify(element._id) + ")'>删除</button>"
|
||
+ "</td>"
|
||
+ "</tr>"
|
||
|
||
});
|
||
html += "</tbody></table>"
|
||
$("#consumerCompanyTable").html(html);
|
||
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function consumerShow() {
|
||
consumerList();
|
||
consumerCompanyNameAndresolution();
|
||
}
|
||
function consumermMediaDel(val) {
|
||
$.ajax({
|
||
url: url + "/consumer/media/delete/" + val,
|
||
method: "delete",
|
||
success: function (res) {
|
||
if (res.code == 200) {
|
||
consumerList();
|
||
} else {
|
||
alert(res.msg)
|
||
}
|
||
},
|
||
error: function (res) {
|
||
alert(res.responseJSON.msg)
|
||
}
|
||
})
|
||
}
|
||
function consumerList(type) {
|
||
var resolution = $("#consumerSelectResolutionRatio option:selected").val()
|
||
var company = $("#consumerCompanyNameRatio option:selected").val()
|
||
var page = 1
|
||
var pageSize = 10
|
||
var currPageVal = parseInt($("#consumerCurrPage").text())
|
||
var pageSizeVal = parseInt($("#consumerPageSize").text())
|
||
var totalPageVal = parseInt($("#consumerTotalPage").text())
|
||
if (currPageVal) {
|
||
page = currPageVal
|
||
}
|
||
if (type) {
|
||
if (type == "pre") {
|
||
if (page > 1) {
|
||
page--
|
||
}
|
||
} else if (type == "next") {
|
||
if (page < totalPageVal) {
|
||
page++
|
||
}
|
||
}
|
||
}
|
||
var uri = "/consumer/media/list?page=" + page + "&pageSize=" + pageSize
|
||
if (resolution != "") {
|
||
uri += "&resolutionId=" + resolution
|
||
}
|
||
if (company != "") {
|
||
uri += "&companyId=" + company
|
||
}
|
||
|
||
$.ajax({
|
||
url: url + uri,
|
||
method: "get",
|
||
success: function (res) {
|
||
// console.log(res.data)
|
||
if (res.code == 200 && res.data != null) {
|
||
$("#consumerTotalPage").text(res.totalPage)
|
||
$("#consumerTotalSize").text(res.totalSize)
|
||
$("#consumerCurrPage").text(res.currPage)
|
||
$("#consumerPageSize").text(res.pageSize)
|
||
var html = "<table class='consumerTable' border=1 id='consumerTable'>"
|
||
+ "<thead>"
|
||
+ "<tr>"
|
||
+ "<th>文件名称</th><th>公司名</th><th>像素</th><th>操作</th>"
|
||
+ "</tr>"
|
||
+ "</thead> "
|
||
+ "<tbody>"
|
||
res.data.forEach(element => {
|
||
html += "<tr>"
|
||
+ "<td>"
|
||
+ "<a href=" + url + "/consumer/media/download/" + element._id + ">" + element.file_name + "</a>"
|
||
+ "</td>"
|
||
+ "<td>"
|
||
+ "<span>" + element.company_name + "</span>"
|
||
+ "</td>"
|
||
+ "<td>"
|
||
+ "<span>" + element.resolution_name + "</span>"
|
||
+ "</td>"
|
||
+ "<td>"
|
||
+ "<button class='btn btn-default' type='button' onclick='consumermMediaDel(" + JSON.stringify(element._id) + ")'>删除</button>"
|
||
+ "</td>"
|
||
+ "</tr>"
|
||
|
||
});
|
||
html += "</tbody></table>"
|
||
$("#consumerTable").html(html);
|
||
} else {
|
||
var html = "<table border=1>"
|
||
+ "<thead>"
|
||
+ "<tr>"
|
||
+ "<td>文件名称</td><td>公司名</td><td>像素</td><td>操作</td>"
|
||
+ "</thead>"
|
||
+ "<tbody>"
|
||
+ "<tr>"
|
||
+ "<td colspan=2>暂无数据</td>"
|
||
+ "</tr>"
|
||
+ "</tbody>"
|
||
+ "<table>";
|
||
$("#consumerTable").html(html);
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
|
||
function uploadFile() {
|
||
var files = $("#file")[0].files;
|
||
var wj;
|
||
if (files.length <= 0) {
|
||
return alert("请选择文件后再上传");
|
||
}
|
||
wj = new FormData();
|
||
wj.append("file", files[0]);
|
||
// console.log(wj);
|
||
// console.log(wj.get("file"))
|
||
$.ajax({
|
||
url: url + "/YunSign/upload/" + $("#selectResolutionRatio option:selected").val(),
|
||
method: "post",
|
||
data: wj,
|
||
processData: false,
|
||
contentType: false,
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
searchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
function searchFileName() {
|
||
var text = $("#input").val();
|
||
if ($.trim(text) != "") {
|
||
$("#fileTable tr:not('#theader')").hide().filter(":contains('" + text + "')").show();
|
||
} else {
|
||
$('#fileTable tr').show();
|
||
}
|
||
}
|
||
|
||
function delfile(val) {
|
||
// console.log("1245644465")
|
||
var value = $(val).parent().parent().find('td a');
|
||
console.log(value.eq(0).text());
|
||
$.ajax({
|
||
url: url + "/YunSign/delete/" + $("#selectResolutionRatio option:selected").val() + "/" + value.eq(0).text(),
|
||
method: "delete",
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
searchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function setNew(val) {
|
||
var value = $(val).parent().parent().find('td a');
|
||
console.log(value.eq(0).text());
|
||
$.ajax({
|
||
url: url + "/YunSign/setNew",
|
||
method: "post",
|
||
data: {
|
||
fbl: $("#selectResolutionRatio option:selected").val(),
|
||
version: value.eq(0).text()
|
||
},
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
searchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
|
||
|
||
// I_LED
|
||
function I_Ledcomfirmpassword() {
|
||
if ($("#I_Ledpassword").val() != "") {
|
||
$.ajax({
|
||
url: url + "/YunSign/check",
|
||
method: "post",
|
||
data: {
|
||
value: $("#I_Ledpassword").val()
|
||
},
|
||
success: function (res) {
|
||
// console.log(res);
|
||
if (res.code == 200) {
|
||
$("#I_Ledlogin").css("display", "none");
|
||
$("#I_LedfileList").css("display", "block");
|
||
I_LedsearchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
// console.log($("#password").val());
|
||
}
|
||
|
||
function I_LedsearchFile() {
|
||
$.ajax({
|
||
url: url + "/I_Led/" + $("#I_LedselectResolutionRatio option:selected").val() + "/fileList",
|
||
method: "get",
|
||
success: function (res) {
|
||
// console.log(res.data)
|
||
if (res.code == 200 && res.data != null) {
|
||
var html = "<table border=1 id='I_LedfileTable'><thead><tr><td>文件名称</td><td>操作</td></tr></thead><tbody>"
|
||
res.data.forEach(element => {
|
||
if (element.is_new) {
|
||
html += "<tr><td><a href=" + url + "/download/I_Led/" + $("#I_LedselectResolutionRatio option:selected").val() + "/" + element.file + ">" + element.file + "</a><label class='new'>new!</label></td><td><button class='btn btn-default' type='button' onclick=I_Leddelfile(this)>删除</button><button style='margin-left:10px;' class='btn btn-default' type='button' onclick=I_LedsetNew(this)>设置为最新版本</button></td></tr>"
|
||
|
||
} else {
|
||
html += "<tr><td><a href=" + url + "/download/I_Led/" + $("#I_LedselectResolutionRatio option:selected").val() + "/" + element.file + ">" + element.file + "</a></td><td><button class='btn btn-default' type='button' onclick=I_Leddelfile(this)>删除</button><button style='margin-left:10px;' class='btn btn-default' type='button' onclick=I_LedsetNew(this)>设置为最新版本</button></td></tr>"
|
||
}
|
||
});
|
||
html += "</tbody></table>"
|
||
$("#I_LedfileTable").html(html);
|
||
} else {
|
||
var html = "<table border=1><thead><tr><td>文件名称</td><td>操作</td></tr></thead><tbody><tr><td colspan=2>暂无数据</td></tr></tbody><table>";
|
||
$("#I_LedfileTable").html(html);
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
function I_LeduploadFile() {
|
||
var files = $("#I_Ledfile")[0].files;
|
||
var wj;
|
||
if (files.length <= 0) {
|
||
return alert("请选择文件后再上传");
|
||
}
|
||
wj = new FormData();
|
||
wj.append("file", files[0]);
|
||
// console.log(wj);
|
||
// console.log(wj.get("file"))
|
||
$.ajax({
|
||
url: url + "/I_Led/upload/" + $("#I_LedselectResolutionRatio option:selected").val(),
|
||
method: "post",
|
||
data: wj,
|
||
processData: false,
|
||
contentType: false,
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
I_LedsearchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
function I_LedsearchFileName() {
|
||
var text = $("#I_Ledinput").val();
|
||
if ($.trim(text) != "") {
|
||
$("#I_LedfileTable tr:not('#theader')").hide().filter(":contains('" + text + "')").show();
|
||
} else {
|
||
$('#I_LedfileTable tr').show();
|
||
}
|
||
}
|
||
|
||
function I_Leddelfile(val) {
|
||
// console.log("1245644465")
|
||
var value = $(val).parent().parent().find('td a');
|
||
console.log(value.eq(0).text());
|
||
$.ajax({
|
||
url: url + "/I_Led/delete/" + $("#I_LedselectResolutionRatio option:selected").val() + "/" + value.eq(0).text(),
|
||
method: "delete",
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
I_LedsearchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
function I_LedsetNew(val) {
|
||
var value = $(val).parent().parent().find('td a');
|
||
console.log(value.eq(0).text());
|
||
$.ajax({
|
||
url: url + "/I_Led/setNew",
|
||
method: "post",
|
||
data: {
|
||
fbl: $("#I_LedselectResolutionRatio option:selected").val(),
|
||
version: value.eq(0).text()
|
||
},
|
||
success: function (res) {
|
||
console.log(res);
|
||
if (res.code == 200) {
|
||
I_LedsearchFile();
|
||
}
|
||
}
|
||
})
|
||
}
|
||
|
||
|
||
</script> |