402 lines
16 KiB
Plaintext
402 lines
16 KiB
Plaintext
@using WX.CRM.WebHelper;
|
|
@using WX.CRM.Model.Entity;
|
|
@using WX.CRM.Model.MAP;
|
|
@using WX.CRM.Common;
|
|
@using WX.CRM.Model.QueryMap
|
|
@{
|
|
ViewBag.Title = "我的桌面";
|
|
Layout = "~/Views/Shared/_Index_Layout2.cshtml";
|
|
}
|
|
<style>
|
|
.kjMenu {
|
|
list-style: outside none circle;
|
|
position: relative;
|
|
}
|
|
|
|
.kjMenu li {
|
|
width: 150px;
|
|
float: left;
|
|
margin-bottom: 5px;
|
|
margin-right: 5px;
|
|
margin-top: 5px;
|
|
vertical-align: middle;
|
|
}
|
|
|
|
.kjMenu li:hover a {
|
|
border-bottom: 2px solid red;
|
|
}
|
|
|
|
|
|
.kjMenu li a {
|
|
height: 30px;
|
|
width: 80%;
|
|
color: black;
|
|
font-size: 14px;
|
|
font-weight: bold;
|
|
display: inline-block;
|
|
}
|
|
|
|
.kjMenu li a:focus {
|
|
color: red;
|
|
font-weight: bold;
|
|
}
|
|
|
|
.kjMenu li img {
|
|
vertical-align: middle;
|
|
padding-right: 10px;
|
|
}
|
|
|
|
.ulColor a {
|
|
color: red;
|
|
font-weight: bold;
|
|
}
|
|
|
|
.nmalegeb .panel-title {
|
|
padding-left: 35px;
|
|
}
|
|
|
|
.nmalegeb .panel-icon {
|
|
left: 10px;
|
|
}
|
|
|
|
.WelComeIcon {
|
|
display: inline-block;
|
|
position: relative;
|
|
width: 25px;
|
|
height: 25px;
|
|
background: url(/Content/Images/icon/windows.png) no-repeat center;
|
|
vertical-align: middle;
|
|
/*cursor: pointer;*/
|
|
padding-left: 20px;
|
|
}
|
|
</style>
|
|
<script src="~/layui-v2.5.4/layui.js"></script>
|
|
<div class="mvctool" @*style="border-bottom: 1px solid #6ca5d1; "*@>
|
|
<div class="mvctool_mytitle">
|
|
<span id="showOrHidSearch" class="WelComeIcon" ishiiden="false"></span>
|
|
我的桌面
|
|
</div>
|
|
<input class="layui-btn layui-btn-sm layui-btn-ok" data-method="btnUpdatePwd" onclick="undefined" id="btnUpdatePwd" type="button" value="修改密码">
|
|
<input class="layui-btn layui-btn-sm layui-btn-normal" data-method="btnDialyMemu" onclick="undefined" id="btnDialyMemu" type="button" value="常用菜单管理">
|
|
<input class="layui-btn layui-btn-sm layui-btn-primary" data-method="btnFeedback" onclick="undefined" id="btnFeedback" type="button" value="意见反馈">
|
|
<input class="layui-btn layui-btn-sm layui-btn-ok" data-method="btnC2021" onclick="undefined" id="btnC2021" type="button" value="证券从业资格视频2021">
|
|
<input class="layui-btn layui-btn-sm layui-btn-primary" data-method="btnMp4_2" onclick="undefined" id="btnMp4_2" type="button" value="证券从业资格视频2020">
|
|
<input class="layui-btn layui-btn-sm layui-btn-primary" data-method="btnStudy" onclick="undefined" id="btnStudy" type="button" value="考试资源">
|
|
<input class="layui-btn layui-btn-sm layui-btn-normal" data-method="btnExam" onclick="undefined" id="btnExam" type="button" value="考试">
|
|
|
|
</div>
|
|
<div style="width:100%;" id="manDiv">
|
|
<table id="manTable" style="width:100%; background-color:#eff0f4" class="nmalegeb">
|
|
<tr>
|
|
<td width="50%" style=" padding:5px;">
|
|
<div id="panel1" data-options="iconCls:'icon-kuaijie',width:'auto'" class="easyui-panel" title="快捷菜单" style="padding:10px;">
|
|
<ul class="kjMenu">
|
|
@{
|
|
List<BAS_LEFTMEMU> cacheMenuList = DataCacheHelper.GetCache().GetList_LeftMemu();
|
|
BAS_LEFTMEMU cacheMeu = null;
|
|
}
|
|
@foreach (var menu in (ViewBag.memuList as List<BAS_DAILYMEMU>))
|
|
{
|
|
cacheMeu = cacheMenuList.FirstOrDefault(m => m.MENUID == menu.MENUID);
|
|
if (cacheMeu != null)
|
|
{
|
|
<li onclick="openurl(this,'@cacheMeu.MNAME','@cacheMeu.URL')"><a href="#"><img src="/Content/Images/surperlink.png" />@cacheMeu.MNAME</a></li>
|
|
|
|
}
|
|
}
|
|
</ul>
|
|
</div>
|
|
</td>
|
|
<td width="50%" style=" padding:5px;">
|
|
<div id="panel2" data-options="iconCls:'icon-weixin',width:'auto',tools:[ { iconCls:'icon-reload', handler:function(){ loadWorckAccount();} }]" class="easyui-panel" title="我的工作微信">
|
|
<table id="tablist" width="100%" class="layui-table">
|
|
<thead>
|
|
<tr class="grid_table_head">
|
|
<th style="width:25px;"> </th>
|
|
<th width="23%" style="text-align:center;">微信用户名</th>
|
|
<th width="23%" style="text-align:center;">微信号</th>
|
|
<th width="15%" style="text-align:center;">昵称</th>
|
|
<th width="12%" style="text-align:center;">状态</th>
|
|
<th width="23%" style="text-align:center;">最后刷新时间</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@{int i = 0;}
|
|
@foreach (var msg in (ViewBag.wxWorkAccount as List<WX_WORKACCOUNT_ALIVE>))
|
|
{
|
|
|
|
i++;
|
|
<tr>
|
|
<td><span>@i</span></td>
|
|
<td>@msg.UserName</td>
|
|
<td>@msg.Alias</td>
|
|
<td>@msg.NickName</td>
|
|
<td><span style="color:@(msg.OnLine == 1 ? "red":"#AAAAAA")">@(msg.OnLine == 1 ? "在线" : "离线")</span></td>
|
|
<td>@msg.LastTime</td>
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
</div>
|
|
|
|
|
|
</td>
|
|
</tr>
|
|
<tr>
|
|
<td width="50%" style=" padding:5px;">
|
|
<div id="panel3" data-options="iconCls:'icon-gonggao'" class="easyui-panel" title="公司公告">
|
|
<table id="tablist4" width="100%" class="layui-table">
|
|
<thead>
|
|
<tr class="grid_table_head">
|
|
<th style="width:25px;"> </th>
|
|
<th width="50%" style="text-align:center;">标题</th>
|
|
<th width="30%" style="text-align:center;">时间</th>
|
|
<th style="text-align:center;width:30px;">操作</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody>
|
|
@{int n = 0;}
|
|
@foreach (var msg in (ViewBag.noticeList as List<BAS_NOTICE>))
|
|
{
|
|
n++;
|
|
<tr>
|
|
<td><span>@n</span></td>
|
|
<td>@msg.TITLE</td>
|
|
<td>@msg.CTIME</td>
|
|
<td><a href="javascript:window.parent.ChildAddTab('公告详情', '/Content/NoticeDetail.html?id=@msg.PKID');">查看</a></td>
|
|
</tr>
|
|
}
|
|
</tbody>
|
|
</table>
|
|
|
|
</div>
|
|
</td>
|
|
<td style=" padding:5px;vertical-align:top;">
|
|
<div id="panel4" data-options="iconCls:'icon-compute'" class="easyui-panel" title="产品展示">
|
|
<table id="tablistProduct" width="100%" class="layui-table">
|
|
@*<thead>
|
|
<tr class="grid_table_head">
|
|
<th style="width:25px;"> </th>
|
|
<th style="text-align:center;">产品名称</th>
|
|
<th style="text-align:center;">价格</th>
|
|
<th style="text-align:left;">时长</th>
|
|
<th width="50%" style="text-align:left;">说明</th>
|
|
</tr>
|
|
</thead>
|
|
<tbody id="productPannel">
|
|
|
|
</tbody>*@
|
|
</table>
|
|
</div>
|
|
</td>
|
|
</tr>
|
|
</table>
|
|
</div>
|
|
<script type="text/javascript">
|
|
$(function () {
|
|
/*$('#tablist').tablegrid({
|
|
url: '/Home/GetNewAccountList',
|
|
loadNow: false,
|
|
height: 180,
|
|
onLoadSuccess: function (data) {
|
|
//成功
|
|
}, onLoadError: function (ex) {
|
|
//失败
|
|
}
|
|
});*/
|
|
loadWorckAccount();
|
|
//loadProduct();
|
|
//$('#tablist3').tablegrid({
|
|
// url: '/Home/GetRecourceCheck',
|
|
// loadNow: true,
|
|
// height: 180
|
|
//});
|
|
|
|
LoadNotice();
|
|
|
|
///三分钟刷新一次
|
|
/*var timename = setInterval(function () {
|
|
alert(Date.parse(new Date()));
|
|
$('#tablist').tablegrid('Load');
|
|
clearInterval(timename);
|
|
|
|
}, 1000*60);*/
|
|
|
|
function refreshWorkAccount() {
|
|
$('#tablist')
|
|
.tablegrid({
|
|
url: '/Home/GetWorkAccountList?type=cache',
|
|
loadNow: true,
|
|
height: 120,
|
|
onLoadSuccess: function (data) {
|
|
//成功
|
|
},
|
|
onLoadError: function (ex) {
|
|
//失败
|
|
}
|
|
});
|
|
}
|
|
|
|
//setInterval(refreshWorkAccount, 1000 * 60);
|
|
|
|
$("#btnUpdatePwd")
|
|
.click(function () {
|
|
$("#modalwindow").html(GetIframeHtml("/Base/InnerUser/ChangeUserIfo"));
|
|
$("#modalwindow")
|
|
.window({
|
|
title: '修改密码',
|
|
width: 700,
|
|
height: 400,
|
|
iconCls: 'icon-edit'
|
|
})
|
|
.window('open');
|
|
});
|
|
$("#btnDialyMemu")
|
|
.click(function () {
|
|
$("#modalwindow").html(GetIframeHtml("/Base/DailyMemu/Index"));
|
|
$("#modalwindow").window({ title: '常用菜单管理', width: 750, height: 500 }).window('open');
|
|
});
|
|
$("#btnFeedback")
|
|
.click(function () {
|
|
$("#modalwindow").html(GetIframeHtml("/Base/Feedback/Add"));
|
|
$("#modalwindow").window({ title: '意见反馈', width: 750, height: 500 }).window('open');
|
|
});
|
|
$("#btnMp4").click(function () {
|
|
parent.ChildAddTab('证券从业资格视频2018', '/MP4/Mp4.html', 'icon-world_link');
|
|
});
|
|
$("#btnMp4_2").click(function () {
|
|
parent.ChildAddTab('证券从业资格视频2020', '/MP4/Mp4_2.html', 'icon-world_link');
|
|
});
|
|
$("#btnC2021").click(function () {
|
|
window.open("https://www.aliyundrive.com/s/3LJw69VCvpB");
|
|
});
|
|
$("#btnStudy").click(function () {
|
|
parent.ChildAddTab('考试资源', '/MP4/study.html', 'icon-world_link');
|
|
});
|
|
$("#btnExam").click(function () {
|
|
parent.ChildAddTab('考试', '/exam/exam/index', 'icon-world_link');
|
|
});
|
|
var resizefunction = function () { //自动适应大小
|
|
var windowwidth = $(window).width();
|
|
//$('#manDiv').width(windowwidth);
|
|
//$('#manTable').width(windowwidth);
|
|
$('#panel2').panel('resize',
|
|
{
|
|
width: parseInt((windowwidth - 45) / 2),
|
|
height: 280
|
|
});
|
|
$('#panel1').panel('resize',
|
|
{
|
|
width: parseInt((windowwidth - 45) / 2),
|
|
height: 280
|
|
});
|
|
$('#panel3').panel('resize',
|
|
{
|
|
width: parseInt((windowwidth - 45) / 2),
|
|
height: 280
|
|
});
|
|
$('#panel4').panel('resize',
|
|
{
|
|
width: parseInt((windowwidth - 45) / 2),
|
|
height: 280
|
|
});
|
|
};
|
|
resizefunction();
|
|
$(window).resize(resizefunction);
|
|
});
|
|
|
|
function SaveRecourceCheck() {
|
|
var row = $("#tablist3").tablegrid("getSelected");
|
|
if (row != null) {
|
|
//console.dir(row);
|
|
if (confirm("确定已经在客服微信中删除该客户了吗?")) {
|
|
if (row.eid === "" || row.eid === undefined) {
|
|
alert('参数错误,请刷新重试!');
|
|
return;
|
|
}
|
|
var eid = row.eid.split('-')[0];
|
|
$.r_post("/Home/SaveRecourceCheck?eid=" + eid + "&username=" + row.username + "&jobusername=" + row.jobusername, function (data) {
|
|
if (data.msg === "ok") {
|
|
$("#tablist3").tablegrid("Load");
|
|
$.messageBox5s('提示', "操作成功!");
|
|
} else {
|
|
$.messageBox5s('提示', "操作失败,请稍后重试!");
|
|
}
|
|
}, "json");
|
|
}
|
|
} else { $.messageBox5s('提示', "选中要确认的数据!"); }
|
|
}
|
|
function ShowResDetial(url) {
|
|
window.parent.ChildAddTab("客户详细", url, "");
|
|
}
|
|
function GetIframeHtml(src) {
|
|
return "<iframe width='100%' height='98%' scrolling='no' frameborder='0'' src='" + src + "'></iframe>";
|
|
}
|
|
function openurl(li, name, url) {
|
|
$(li).addClass("ulColor");
|
|
window.parent.ChildAddTab(name, url, "");
|
|
}
|
|
|
|
function loadWorckAccount() {
|
|
$('#tablist').tablegrid({
|
|
url: '/Home/GetWorkAccountList?type=nocache',
|
|
loadNow: true,
|
|
height: 120,
|
|
onLoadSuccess: function (data) {
|
|
//成功
|
|
}, onLoadError: function (ex) {
|
|
//失败
|
|
}
|
|
});
|
|
}
|
|
//function loadProduct() {
|
|
// $.r_post("/WeiXin/SubProduct/GetWelComeJsonList", function (data) {
|
|
// $("#productPannel").html("");
|
|
// $(data).each(function (a, da) {
|
|
// $("#productPannel").append("<tr><td>" + (a + 1) + "</td><td>" + da.SUBPRODUCTNAME + "</td><td>" + da.PRICE + "</td><td>" + da.RIGHTPERIOD + "</td><td>" + (da.REMARK??"")+"</td><tr>");
|
|
// });
|
|
// }, "json");
|
|
//}
|
|
function LoadNotice() {
|
|
$('#tablist4').tablegrid({
|
|
url: '/Home/GetNoticeList',
|
|
loadNow: false,
|
|
height: 180,
|
|
onLoadSuccess: function (data) {
|
|
//成功
|
|
},
|
|
onLoadError: function (ex) {
|
|
//失败
|
|
}
|
|
});
|
|
}
|
|
function getDataGridHeader() {
|
|
var columns = $('#tablist3').tablegrid("getHead");
|
|
return columns;
|
|
}
|
|
|
|
function Export_Click() {
|
|
$("#modalwindow").html(GetIframeHtml("/Control/ExcelExport?Query=" + encodeURIComponent("/Home/Export?" + GetQueryStr())));
|
|
$("#modalwindow").window({ title: '导出', width: 480, height: 300, iconCls: 'icon-export' }).window('open');
|
|
}
|
|
layui.use(['laypage', 'layer', 'table'], function () {
|
|
var table = layui.table;
|
|
table.render({
|
|
id: 'testReload'//列表别名ID
|
|
, elem: '#tablistProduct'
|
|
, url: '/WeiXin/SubProduct/GetWelComeJsonList'
|
|
, method: 'POST'
|
|
//, limit: 30
|
|
, height: "190"
|
|
, cols: [[
|
|
{ field: 'numbers', type: 'numbers' }
|
|
, { field: 'SUBPRODUCTNAME', width: 140, title: '产品名称' }
|
|
, { field: 'PRICE', width: 80, title: '价格' }
|
|
, { field: 'RIGHTPERIOD', width: 80, title: '时长' }
|
|
, { field: 'REMARK', title: '说明' }
|
|
|
|
]]
|
|
});
|
|
});
|
|
</script>
|