You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
information-system/webht/third_party/dingmail/views/user.php

258 lines
11 KiB
PHP

This file contains ambiguous Unicode characters!

This file contains ambiguous Unicode characters that may be confused with others in your current locale. If your use case is intentional and legitimate, you can safely ignore this warning. Use the Escape button to highlight these characters.

<!DOCTYPE html>
<html lang="zh-cn">
<head>
<meta charset="utf-8">
<meta http-equiv="X-UA-Compatible" content="IE=edge">
<meta name="viewport" content="width=device-width, initial-scale=1">
<title>HT在线平台</title>
<!-- <link href="/css/webht/bootstrap.min.css" rel="stylesheet">
<link href="/css/webht/webht.css?v=1" rel="stylesheet">-->
<link href="/min?f=/css/webht/bootstrap.min.css,/css/webht/webht.css" rel="stylesheet">
<!--[if lt IE 9]>
<script src="http://cdn.bootcss.com/html5shiv/3.7.2/html5shiv.min.js"></script>
<script src="http://cdn.bootcss.com/respond.js/1.4.2/respond.min.js"></script>
<![endif]-->
<!--
<script src="/js/jquery.min.js"></script>
<script src="/js/bootstrap.min.js"></script>
<script src="/js/webht.js?v=1"></script>
-->
<script src="/min?f=/js/jquery.min.js,/js/bootstrap.min.js,/js/webht.js,/js/jquery.suggest.js"></script>
<link rel="shortcut icon" href="/css/images/webht.jpg">
</head>
<body>
<nav class="navbar navbar-inverse navbar-red">
<div class="container-fluid">
<!-- Brand and toggle get grouped for better mobile display -->
<div class="navbar-header">
<button type="button" class="navbar-toggle collapsed" data-toggle="collapse" data-target="#bs-example-navbar-collapse-1">
<span class="sr-only">Toggle navigation</span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
<span class="icon-bar"></span>
</button>
<a class="navbar-brand" href="<?php echo site_url('');?>"><span class="icon-home"></span> 中华游在线</a>
<a class="navbar-brand visible-xs-block"><?php if(isset($navtitle)) echo $navtitle;?></a>
</div>
<div class="collapse navbar-collapse" id="bs-example-navbar-collapse-1">
<ul class="nav navbar-nav">
<li><a href="<?php echo site_url('apps/dingmail/index/mail_index');?>">Value发送</a></li>
<li><a href="<?php echo site_url('apps/dingmail/index/index/'.get_cookie('dingunionid'));?>">个人中心</a></li>
<li><a href="<?php echo site_url('apps/dingmail/index/rank_person');?>">排行榜</a></li>
</ul>
<ul class="nav navbar-nav navbar-right">
<li><a href="<?php echo site_url('apps/dingmail/index/logout');?>">退出</a></li>
</ul>
</div>
</div><!-- /.container-fluid -->
</nav>
<div class="container" style="max-width:1200px;">
<div class="row">
<div class="col-sm-7 col-xs-24 pull-right" style="font: 14px 'Arial','Microsoft YaHei';line-height:25px;">
<div class="panel" style="margin-top:15px;">
<div class="panel-body nopadding">
<div class="row">
<div class="col-xs-10">
<?php if(!empty($user->ddu_Avatar)){?>
<img class="img-responsive" src="<?php echo $user->ddu_Avatar?>"/>
<?php }else{?>
请退出后再次扫码登录,将展示你的钉钉头像
<?php }?>
</div>
<div class="col-xs-14">
<p></p><h4 class="text-center strong"><?php echo $user->ddu_Name?></h4><p></p>
<div class="col-xs-12 text-center text-muted" style="border-left:1px solid #ddd;">
<a href="<?php echo site_url('apps/dingmail/index/index/'.$user_unionid.'/like');?>">
<strong><?php echo $like_count->count;?></strong><br>
<span>赞</span>
</a>
</div>
<div class="col-xs-12 text-center text-muted" style="border-left:1px solid #ddd;">
<a href="<?php echo site_url('apps/dingmail/index/index/'.$user_unionid.'/unlike');?>">
<strong><?php echo $unlike_count->count;?></strong><br>
<span>板砖</span>
</a>
</div>
<p></p>
<div class="col-xs-24 btn-sm"></div>
</div>
</div>
</div>
</div>
<div class="panel">
<div class="panel-body">
<legend>
<span class="text-primary glyphicon glyphicon-thumbs-up" style="font-size:20px;"></span>
<span style="font-size:15px;">他们都觉得很赞!</span>
</legend>
<?php foreach($whos_like as $obj){?>
<span><?php echo $obj->ddv_Name; ?>; </span>
<?php } ?>
<div class="clearfix"></div>
</div>
</div>
<div class="panel">
<div class="panel-body">
<legend>
<span class="text-danger glyphicon glyphicon-thumbs-down" style="font-size:20px;"></span>
<span style="font-size:15px;">他们拍砖了!</span>
</legend>
<?php foreach($whos_unlike as $obj){?>
<span><?php echo $obj->ddv_Name; ?>; </span>
<?php } ?>
<div class="clearfix"></div>
</div>
</div>
<?php if(get_cookie('dingname') == $user->ddu_Name ){ ?>
<div class="panel">
<div class="panel-body">
<legend>
<span class="text-danger glyphicon glyphicon-leaf" style="font-size:20px;"></span>
<span style="font-size:15px;">个人邮件签名设置!</span>
</legend>
<div class="col-xs-24 nopadding" style="height:70px;background:none;">
<a href="http://www.mycht.cn/webht.php/apps/dingmail/index/mail_index">
<img src="http://www.mycht.cn/css/images/+valuemail.png">
</a>
<a href="http://www.mycht.cn/webht.php/apps/dingmail/index/index/<?php echo $this->session->userdata('dingdinguserinfo')->ddu_Unionid?>/like">
<img src="http://www.mycht.cn/css/images/+like.png">
</a>
<a href="http://www.mycht.cn/webht.php/apps/dingmail/index/index/<?php echo $this->session->userdata('dingdinguserinfo')->ddu_Unionid?>/unlike">
<img src="http://www.mycht.cn/css/images/+unlike.png">
</a>
</div>
<div class="clearfix">
<p>钉邮签名没有更新成功的同学请看这里:</p>
<p>拖动鼠标选中上方的三个按钮(在<span class="text-danger">按钮下方</span>鼠标左键三击试试)然后按下Ctrl+C键进行复制到自己的钉邮签名里即可。</p><p>温馨提示:不能直接用鼠标右键功能进行复制</p>
</div>
</div>
</div>
<?php }else{ ?>
<div></div>
<?php }?>
</div>
<div class="col-sm-17 col-xs-24">
<a name="gotocomment" id="gotocomment"></a>
<form id="from-add-comment" method="post" action="<?php echo site_url('apps/dingmail/index/add_comment');?>" style="background:#fff;padding:0 15px 15px 15px;margin-top:15px;">
<div class="col-xs-24 btn-lg"></div>
<p class="col-xs-24 nopadding"><em class="text-primary strong">大家好,我是<?php echo $user->ddu_Name; ?>,欢迎留言......</em></p>
<div class="col-xs-24 nopadding">
<textarea class="form-control" rows="3" name="comment" id="comment-textarea"></textarea>
</div>
<div class="col-xs-24 btn-sm"></div>
<div class="col-xs-24 nopadding">
<input type="hidden" name="user_unionid" value="<?php echo $user_unionid;?>">
<input type="hidden" name="user_sn" value="<?php echo $user->ddu_Sn;?>">
<input type="hidden" name="user_name" value="<?php echo $user->ddu_Name;?>">
<div class="pull-right">
<label style="padding:0 10px 0 0"><input type="checkbox" name="hidden_name" value="hidden_name"/><span style="padding-left:10px">匿名发送</span></label>
<button type="button" id="btn-add-comment" class="btn btn-danger">确 定</button>
</div>
</div>
<div class="clearfix"></div>
</form>
<div class="col-xs-24 nopadding" style="margin-top:20px;margin-bottom:50px;font: 14px 'Arial','Microsoft YaHei';line-height:23px;">
<?php foreach($all_comment as $key=>$value){?>
<div class="col-xs-24" style="border-bottom:1px solid #ededed;padding:15px 20px;background:#fff;">
<p class="text-primary">
<?php if($value->ddu_Avatar){?>
<img style="width:30px;display:inline;border-radius:50%;margin-right:15px;" class="img-responsive" src="<?php echo $value->ddu_Avatar?>"/>
<?php }?>
<?php if($value->ddv_Type == 'hidden_comment'){
echo $value->ddv_Name;
}else{?>
<a href="http://www.mycht.cn/webht.php/apps/dingmail/index/index/<?php echo $value->ddv_User_Unionid?>"><?php echo $value->ddv_Name?></a>
<?php }?>
</p>
<?php if($value->ddv_Content == 'like' || $value->ddv_Content == 'unlike' ){ ?>
<p>对你点了一个<?php echo $value->ddv_Content?></p>
<?php }else if($value->ddv_Type == 'comment' || $value->ddv_Type == 'hidden_comment'){?>
<p><?php echo $value->ddv_Content?></p>
<?php }else{ ?>
<p><?php echo $value->ddv_Type.'+1'.'<br>';echo $value->ddm_Subject; ?></p><a href="http://www.mycht.cn/webht.php/apps/dingmail/index/like/<?php echo $value->ddv_Identify?>/comment">查看更多</a>
<?php }?>
<p>
<span class="text-muted"><?php echo date('m-d-y H:i:s',$value->ddv_Createtime)?></span>
</p>
</div>
<?php } ?>
</div>
</div>
</div>
</div>
<div class="modal fade" id="myModal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-body">
<div class="media">
<div class="media-left">
<div>
<span id="msgclass" class="glyphicon glyphicon-ok text-success" aria-hidden="true" style="font-size:85px;"> </span>
</div>
</div>
<div class="media-body" style="font-size:32px;">
<div class="col-xs-24 btn-lg"><p></p></div>
<span id="msgbox" class="text-success"></span>
</div>
</div>
</div>
</div>
</div>
</div>
</body>
<script>
var comment_url="<?php echo site_url('apps/dingmail/index/index/'.$user_unionid);?>";
$("#btn-add-comment").click(function() {
if ($("#comment-textarea").val().replace(/(^\s*)|(\s*$)/g,'')=="") {
$("#msgclass").removeClass('glyphicon-ok text-success');
$("#msgclass").addClass('glyphicon-remove text-danger');
$("#msgbox").removeClass('text-success');
$("#msgbox").addClass('text-danger');
$("#msgbox").text('评论内容不能为空!');
$('#myModal').modal('show');
setTimeout(function() {
$('#myModal').modal('hide');
},5000);
return false;
};
var url = $("form#from-add-comment").attr('action');
var data= $("form#from-add-comment").serialize();
console.log(data);
$.post(url,data,function(result){
if (result) {
$("#msgclass").removeClass('glyphicon-remove text-danger');
$("#msgclass").addClass('glyphicon-ok text-success');
$("#msgbox").removeClass('text-danger');
$("#msgbox").addClass('text-success');
$("#msgbox").text('评论成功!');
$('#myModal').modal('show');
setTimeout(function() {
$('#myModal').modal('hide');
location.href=comment_url;
},1500);
}else{
$("#msgclass").removeClass('glyphicon-ok text-success');
$("#msgclass").addClass('glyphicon-remove text-danger');
$("#msgbox").removeClass('text-success');
$("#msgbox").addClass('text-danger');
$("#msgbox").text('评论发布失败!');
$('#myModal').modal('show');
setTimeout(function() {
$('#myModal').modal('hide');
},5000);
}
});
});
</script>
</html>