You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
114 lines
3.0 KiB
114 lines
3.0 KiB
5 years ago
|
<!DOCTYPE html>
|
||
|
<html>
|
||
|
|
||
|
<head>
|
||
|
<meta charset="utf-8">
|
||
|
<meta name="viewport" content="width=device-width,initial-scale=1,minimum-scale=1,maximum-scale=1,user-scalable=no" />
|
||
|
<title>系统公告</title>
|
||
|
<!--REM自适应布局JS-->
|
||
|
<link rel="stylesheet" type="text/css" href="../../../lib/css/mui.min.css">
|
||
|
<link rel="stylesheet" type="text/css" href="../../../lib/css/basic.css" />
|
||
|
<link rel="stylesheet" type="text/css" href="../../css/base.css" />
|
||
|
<script src="../../../lib/js/mui.min.js"></script>
|
||
|
<script src="../../../lib/js/vue.js"></script>
|
||
|
<script src="../../../lib/js/app.js"></script>
|
||
|
<script src="../../js/base/rem-layout.js"></script>
|
||
|
<script type="text/javascript" src="../../js/my/my_ajax.js"></script>
|
||
|
<script src="../../../lib/js/require2.1.11.js"></script>
|
||
|
|
||
|
</head>
|
||
|
<style>
|
||
|
|
||
|
</style>
|
||
|
|
||
|
<body>
|
||
|
<div id="data-info">
|
||
|
<header class="mui-bar mui-bar-nav app-header app-header-darkly">
|
||
|
<a class="mui-action-back mui-icon mui-icon-left-nav mui-pull-left"></a>
|
||
|
<h1 class="mui-title">{{langue.title}}</h1>
|
||
|
</header>
|
||
|
<div class="mui-content">
|
||
|
<ul class="mui-table-view app-table-view app-table-view-darkly">
|
||
|
<li v-for="item in systemNotice" class="mui-table-view-cell">
|
||
|
<a class="mui-navigate-right view-herf" :id="item.id" @click="handleG(item.id)">
|
||
|
{{item.title}}
|
||
|
</a>
|
||
|
</li>
|
||
|
</ul>
|
||
|
</div>
|
||
|
</div>
|
||
|
</body>
|
||
|
|
||
|
</html>
|
||
|
<script>
|
||
|
// 国际化
|
||
|
var langues = {
|
||
|
zh_CN: {
|
||
|
title: "系统公告"
|
||
|
|
||
|
},
|
||
|
zh_HK: {
|
||
|
title: "系統公告"
|
||
|
|
||
|
},
|
||
|
en_US: {
|
||
|
title: "System notification"
|
||
|
|
||
|
}
|
||
|
};
|
||
|
//2、页面上所有需要国际化的文字,包括提示,都通过Vue去引用,例子:
|
||
|
var langueKey = app.getLanguageLocalStorage(); //获取国际化语种
|
||
|
var langue = langues[langueKey]; // 获取国际化语种数据
|
||
|
//3、每个页面都需要加上以下的方法:
|
||
|
window.addEventListener('switchLangueData', function(e) {
|
||
|
//dataInfo为Vue对象的名称
|
||
|
dataInfo.langue = langues[e.detail];
|
||
|
});
|
||
|
var dataInfo = new Vue({
|
||
|
el: "#data-info",
|
||
|
data: {
|
||
|
langue: langue,
|
||
|
systemNotice: [],
|
||
|
id: ''
|
||
|
},
|
||
|
methods: {
|
||
|
handleG: function(id) {
|
||
|
this.id = id;
|
||
|
test(id);
|
||
|
}
|
||
|
}
|
||
|
});
|
||
|
|
||
|
mui.plusReady(function() { //请求系统公告
|
||
|
getSystemNotince();
|
||
|
});
|
||
|
</script>
|
||
|
<script>
|
||
|
function getSystemNotince() {
|
||
|
mui.ajax(myAjaxJs.AJAX_STSTEM_NOTICE_E.getUrl, {
|
||
|
headers: {
|
||
|
"locale": app.getLanguageLocalStorage() // 语种头部
|
||
|
},
|
||
|
type: myAjaxJs.AJAX_STSTEM_NOTICE_E.getType, //HTTP请求类型
|
||
|
dataType: 'json', //服务器返回json格式数据
|
||
|
timeout: 10000, //超时时间设置为10秒;
|
||
|
success: function(data) {
|
||
|
if(data.code == 200) {
|
||
|
// console.log(JSON.stringify(data.data.rows));
|
||
|
dataInfo.systemNotice = data.data.rows;
|
||
|
} else {
|
||
|
mui.toast(data.msg);
|
||
|
}
|
||
|
},
|
||
|
error: function(xhr, type, errorThrown) {
|
||
|
// mui.toast('1111');
|
||
|
}
|
||
|
})
|
||
|
}
|
||
|
|
||
|
function test(id) {
|
||
|
app.openWin('system_notice_value.html', 'system_notice_value.html', {}, {
|
||
|
_id: id
|
||
|
});
|
||
|
}
|
||
|
</script>
|