<div id="globalcss">
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
<title>{openzc:define.HEADING_TITLE/}</title>
{openzc:include filename="system/common/css.tpl"/}
</head>
<body>
<div class="container mb-5">
  <div class="block-title subtitle is-4 is-spaced mt-6 px-5 is-hidden-mobile">{openzc:define.HEADING_TITLE/}</div>
  <div class="columns mx-0">
    {openzc:include filename="system/account/account_nav.tpl"/}
    <div class="column">
		<article class="message is-light">
			<div class="message-header"><p>{openzc:define.HEADING_TITLE/}</p></div>
			<div class="message-body px-4">
	{openzc:msg name="addressbook"/}
      <div class="card column">
        <div class="card-body">
          <div class="columns">
            <div class="column pl-4">
              <h4 class="subtitle is-5"><i class="fa fa-flag"></i> {openzc:define.PRIMARY_ADDRESS_TITLE/}</h4>
              {openzc:account item="address" default="true"}
              <p class="subtitle is-6">[field:address/]</p>
              <div class="block mt-3"> <a class="button is-normal" href="[field:edit_link/]"> <i class="fa fa-edit"></i>&nbsp;&nbsp;[field:edit_text/]</a> </div>
              {/openzc:account}
			</div>
            <div class="column">
              <article class="message">
                <div class="message-body"> {openzc:define.PRIMARY_ADDRESS_DESCRIPTION/} </div>
              </article>
            </div>
          </div>
        </div>
      </div>
      <div class="card column mt-5">
        <div class="card-body">
          <div class="columns">
            <div class="column pl-4">
              <h4 class="subtitle is-5"><i class="fas fa-map-marker-alt"></i> {openzc:define.ADDRESS_BOOK_TITLE/}</h4>
              <div class="notification is-info is-light">{openzc:php}echo sprintf(TEXT_MAXIMUM_ENTRIES, MAX_ADDRESS_BOOK_ENTRIES);{/openzc:php} </div>
              <div class="columns">
				{openzc:account item="address"}
                <div class="column is-half"> <b class="is-6"> [field:firstname/] [field:lastname/] </b> {openzc:if $field['status']=='active'}(primary address){/openzc:if}
                  <p class="subtitle is-6 mt-2"> [field:address/] </p>
                  <a class="button mr-2" href="[field:edit_link/]"> <i class="fa fa-edit"></i>&nbsp;&nbsp;[field:edit_text/]</a> {openzc:if $field['status']!='active'} <a class="button" href="[field:delete_link/]"> <i class="far fa-trash-alt"></i>&nbsp;&nbsp;[field:delete_text/]</a> {/openzc:if} </div>
				{openzc:if $field['sort_index']%2==0}
				</div>
				<div class="columns">
				{/openzc:if}
                {/openzc:account}
			  </div>
            </div>
          </div>
        </div>
      </div>
      <div class="field level is-mobile mt-5">
        <div class="control level-left"> <a class="button " href="{openzc:link name='FILENAME_ADDRESS_BOOK_PROCESS'/}"><i class="fa fa-plus"></i>&nbsp;&nbsp;{openzc:define.BUTTON_ADD_ADDRESS_ALT/}</a> </div>
        <p class="level-right"><a class="button" href="{openzc:link name='FILENAME_ACCOUNT'/}"><i class="fas fa-reply"></i>&nbsp;&nbsp;{openzc:define.BUTTON_BACK_ALT/}</a></p>
      </div>
    </div>
		</article>
  </div>
</div>
</div>
</body>
{openzc:include filename="system/common/js.tpl"/}
</html>
</div>