<div class="modal" ng-controller="LinkerDetailCtrl">
	<header class="bar bar-header bar-{{barTheme}}">
		<i class="button button-icon icon ion-ios-reloading" ng-show="loading"></i>
		<div class="title">联系人详情</div>
		<button class="button button-clear" sino-modal-back-button="goBack()">关闭</button>
	</header>

	<ion-content class="linker-detail has-header" scroll="true">
		<div class="list">

			<div class="item item-avatar item-icon-right">
        <sino-person-photo user-id="{{user.userId}}" size="40x40" class="size_40x40 item-image"></sino-person-photo>
				<span class="linker-detail-user">{{user.userName}}</span>
			</div>

			<div class="item item-divider">
		    	部门
		  	</div>
			<div class="item item-text-wrap">
				{{user.deptName}}
			</div>
			<div class="item item-divider">
		    	职位
		  	</div>
			<div class="item item-text-wrap">
				{{getUserDuty(user)}}
			</div>
			<div class="item item-divider" ng-if="!!user.phone && (showPhone || user.isPhonePublic) ">
        手机
      </div>
      <div class="item item-text-wrap item-icon-right" ng-if="!!user.phone && (showPhone || user.isPhonePublic)">
        {{user.phone}}
        <a href="tel:{{user.phone}}"><i class="icon-left icon ion-iphone"></i></a>
        <a ng-href="sms:{{user.phone}}"><i class="icon ion-ios-email-outline"></i></a>
      </div>

      <div class="item item-divider" ng-if="!!user.officePhone && user.isPhonePublic">
          办公电话
      </div>
      <div class="item item-text-wrap item-icon-right" ng-if="!!user.officePhone && user.isPhonePublic">
        {{user.officePhone}}
        <a href="tel:{{user.officePhone}}"><i class="icon-left icon ion-ios-telephone-outline"></i></a>
        <a ng-href="sms:{{user.officePhone}}"><i class="icon ion-ios-email-outline"></i></a>
      </div>
		</div>
		<div class="list">
			<div class="button button-block button-energized" ng-if="canAddToContact" ng-click="addToContacts()">
 				添加到通讯录
			</div>
			<div class="button button-full button-light font-color-red" ng-if="favorited" ng-click="cancelFavorite()">
			  从常用联系人中移除
			</div>
			<div class="button button-block button-positive" ng-if="!favorited" ng-click="favorite()">
  				添加到常用联系人
			</div>
		</div>
	</ion-content>

</div>
