File indexing completed on 2024-12-29 05:24:49

0001 <?php 
0002 /**
0003  *  ocs-webserver
0004  *
0005  *  Copyright 2016 by pling GmbH.
0006  *
0007  *    This file is part of ocs-webserver.
0008  *
0009  *    This program is free software: you can redistribute it and/or modify
0010  *    it under the terms of the GNU Affero General Public License as
0011  *    published by the Free Software Foundation, either version 3 of the
0012  *    License, or (at your option) any later version.
0013  *
0014  *    This program is distributed in the hope that it will be useful,
0015  *    but WITHOUT ANY WARRANTY; without even the implied warranty of
0016  *    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
0017  *    GNU Affero General Public License for more details.
0018  *
0019  *    You should have received a copy of the GNU Affero General Public License
0020  *    along with this program.  If not, see <http://www.gnu.org/licenses/>.
0021  **/
0022 ?>
0023 
0024 <style type="text/css">
0025         
0026 
0027         div.jtable-main-container table.jtable tbody > tr > td{
0028             vertical-align: top;
0029             border-left:0px;
0030             border-right:0px;
0031             font-size: small;
0032         }
0033         div.jtable-main-container table.jtable{
0034             border: 0px;
0035         }
0036         div.jtable-main-container table.jtable th{
0037             border: 0px;
0038             background: none;
0039             font-weight: bold;
0040         }
0041         
0042         #TableContainer
0043         {
0044             padding: 20px;
0045         }
0046         #titleheader{
0047             padding-left: 20px;
0048             padding-top: 100px;
0049         }
0050 
0051         a.btn-xs
0052         {
0053             line-height: 12px;
0054             padding: 3px 5px;
0055             border-radius: 2px;
0056             margin: 2px;
0057             float: right;
0058         }
0059         
0060 
0061         div.jtable-main-container table.jtable .tooltipuser{
0062             color: #2673b0;
0063             cursor: pointer;
0064         }
0065 
0066         div.jtable-main-container img.avatar{
0067                 width: 50px;
0068                 border: 1px solid #dbdbdb;
0069                 -webkit-border-radius: 999px;
0070                 -moz-border-radius: 999px;
0071                 border-radius: 999px;
0072                 -webkit-background-clip: padding-box;
0073                 -moz-background-clip: padding;
0074                 background-clip: padding-box;
0075                 display: block;
0076         }
0077        
0078        a.removeuser{
0079         display: block;
0080        }
0081 
0082        .aligncenter
0083        {
0084         text-align: center;
0085        }
0086 
0087 
0088 </style>
0089 
0090 <link href="/theme/backend/lib/jquery-ui/themes/smoothness/jquery-ui.min.css" rel="stylesheet">
0091 <link href="/theme/backend/lib/jtable/themes/jqueryui/jtable_jqueryui.min.css" rel="stylesheet">
0092 <script src="/theme/backend/lib/jquery-ui/jquery-ui.min.js"></script>
0093 <script src="/theme/backend/lib/jtable/jquery.jtable.min.js"></script>
0094 
0095 <div class="messages">
0096 
0097 </div>
0098 <div class="tooltip_templates" style="display:none">
0099       <span id="tooltip_content">
0100           <i class="fa fa-spinner"></i>
0101       </span>
0102   </div>
0103 <div id="titleheader"> <h1>Paypal address duplicated </h1></div>
0104 <div id="TableContainer"></div>
0105 <div id="dialog-form" title="Object Details"></div>
0106 <div id="dialog-confirm" title="Confirm"></div>
0107 <script type="text/javascript">
0108     $(document).ready(function () {
0109         $('#TableContainer').jtable({
0110             jqueryuiTheme: true,
0111             paging: true,
0112             sorting: false,            
0113             actions: {
0114                 listAction: '/spam/paypallist',                                       
0115             },
0116             recordsLoaded: function (event, data) {
0117                 TooltipUser.setup("tooltipuser","right");        
0118             },
0119             rowInserted: function (event, data) {
0120                if (data.record.cntComments==1) {                   
0121                     data.row.css("background", "#F7F7E1");                   
0122                }
0123             },
0124             fields: {
0125                 paypal_mail: {
0126                     key: true,
0127                     title: 'paypal',
0128                     create: false,
0129                     edit: false,
0130                     list: true,
0131                     display:function(data){      
0132                              if(data.record.is_deleted==1)
0133                              {
0134                                 return '<span style="color:red">'+data.record.paypal_mail+'</span>';
0135                              }                                                     
0136                             return data.record.paypal_mail;
0137                         }
0138                 }, 
0139                  
0140                 names: {
0141                     title: 'username',
0142                    
0143                     edit: false,
0144                     display:function(data){                    
0145 
0146                         var names = data.record.names.split(',');    
0147                         var ids = data.record.ids.split(',');    
0148                         var d = data.record.is_deleted.split(',');                            
0149                         var html = '';
0150                         names.forEach(function callback(name , index ) {                               
0151                             sname=name;
0152                             if(d[index]==1)                                
0153                             {
0154                                 sname='<span style="color:red">'+name+'</span>';
0155                             }           
0156                             html=html+'<a href="/u/'+name+'" target="_blank" class="tooltipuser" data-tooltip-content="#tooltip_content" data-user="'+ids[index]+'" >'+sname+', <a>';
0157                         });
0158                                                                        
0159                         return html;
0160                     }                    
0161                 } ,                    
0162                 created_at: {
0163                     title: 'lastest created_at',
0164                     width: '15%', 
0165                     edit: false
0166                     
0167                 } ,       
0168                  amount: {
0169                     title: 'last month earn',
0170                     width: '15%', 
0171                     edit: false
0172                     
0173                 } ,                                                            
0174                     cnt: {
0175                     title: '#cnt',
0176                     width: '5%', 
0177                     edit: false,
0178                     display:function(data){                                                           
0179                             return data.record.cnt;
0180                         }
0181                 } ,    
0182                 
0183                                    
0184                 
0185             }
0186         });
0187 
0188         //$('#TableContainer').jtable('load');
0189         $('#TableContainer').jtable('load', {},function(){
0190               //TooltipUser.setup("tooltipuser","right");        
0191             });
0192 
0193         $("#dialog-form").dialog({
0194             autoOpen: false,
0195             //height: 350,
0196             width: 600,
0197             modal: true,
0198             buttons: {
0199                 Close: function () {
0200                     $(this).dialog("close");
0201                 }
0202             }
0203         });
0204 
0205      
0206 
0207     });
0208 </script>