<!DOCTYPE html>
<html lang="zh" xmlns:th="http://www.thymeleaf.org" xmlns:shiro="http://www.pollix.at/thymeleaf/shiro">
<head>
    <link th:href="@{/css/bootstrap.min.css}" rel="stylesheet"/>
	<link th:href="@{/css/font-awesome.min.css}" rel="stylesheet"/>
	<link th:href="@{/css/animate.css}" rel="stylesheet"/>
    <link href=""src/main/resources/templates/crm/phonenumber/style.css"" rel="stylesheet">
</head>
<body class="gray-bg">
     <div class="container-div">
        
        <div class="wrapper wrapper-content animated fadeInRight">
        	<div id="divList"></div>
        </div>
    </div>
    <div class="wrapper wrapper-content animated fadeInRight">
        <div class="row">
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>

            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>

            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>

            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>
            <div class="col-lg-3">
                <div class="contact-box center-version">

                    <a href="profile.html">
                        <img alt="image" class="img-circle" src="img/a6.jpg">
                        <h3 class="m-b-xs"><strong>小红</strong></h3>
                        <div class="font-bold">超级CEo</div>
                        <address class="m-t-md">
                            <strong>企鹅公司</strong><br>
                            北京市朝阳区某区某街道<br>
                            企鹅 100000<br>
                            手机 18900000000<br>
                            邮编 100020<br>
                        </address>
                    </a>
                    <div class="contact-box-footer">
                        <div class="m-t-xs btn-group">
                            <a class="btn btn-xs btn-white"><i class="fa fa-phone"></i> 呼叫Ta </a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-envelope"></i> 发信息</a>
                            <a class="btn btn-xs btn-white"><i class="fa fa-user-plus"></i> 加好友</a>
                        </div>
                    </div>

                </div>
            </div>


        </div>
        </div>
    
    <script th:inline="javascript">
        var editFlag = [[${@permission.hasPermi('crm:phonenumber:edit')}]];
        var removeFlag = [[${@permission.hasPermi('crm:phonenumber:remove')}]];
        var sexDatas = [[${@dict.getType('sys_user_sex')}]];
        var marriageDatas = [[${@dict.getType('marriage')}]];
        var phonenumberTypeDatas = [[${@dict.getType('phonenumber_type')}]];
        var prefix = ctx + "crm/phonenumber";

        $(function() {
        	autoList();
        });
        
        var listUrl=prefix + "/list";
		function autoList(){
			$.ajax({
	            url: prefix + "/list",
	            data: {
				},
	            type: "post",
	            success: function(result) {
	            	
	            	if (result.code == 0 && result.rows.length>0) {
	            		debugger;
	            		for(var i=0;i<result.rows.length;i++){
	            			var isNewRow=(i%4)===0;
	            			if(isNewRow){
	            				$("#divList").append('<div class="row">');
	            			}
	            			$("#divList").append('<div class="col-lg-3"><div class="contact-box center-version">');
	            			$("#divList").append('<a href="###">');
	            			$("#divList").append(' <h3 class="m-b-xs"><strong>'+result.rows[i].name+'</strong></h3>');
	            			$("#divList").append(' <div class="font-bold">'+result.rows[i].duty+'</div>');
	            			$("#divList").append(' <address class="m-t-md">');
	            			$("#divList").append('   <strong>'+result.rows[i].company+'</strong><br>');
	            			$("#divList").append(result.rows[i].address+'<br>');
	            			
	            			$("#divList").append(' </address>');
	            			
	            			$("#divList").append('</a>');
           	                $("#divList").append('</div></div>');
	            			if(isNewRow){
	            				$("#divList").append('</div>');
	            			}
	            		}
	            	} else {
	            		$.modal.msgError(result.msg);
	            	}
	            },
				error : function(e) {
					$.modal.msgError("系统异常");
				}
	        })
		}
    </script>
</body>
</html>