하이브리드 처리 부분에서 일부 통신을 PHP 웹뷰로 띄우는 부분이 있는데 앵귤러로 처리 하니 편하네요 ㅎㅎㅎ
[code]
<script type="text/javascript">
function address_book($scope, $http) {
// 주소록 데이터
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㄱ').success(function(response) {$scope.data1 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㄴ').success(function(response) {$scope.data2 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㄷ').success(function(response) {$scope.data3 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㄹ').success(function(response) {$scope.data4 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅁ').success(function(response) {$scope.data5 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅂ').success(function(response) {$scope.data6 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅅ').success(function(response) {$scope.data7 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅇ').success(function(response) {$scope.data8 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅈ').success(function(response) {$scope.data9 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅊ').success(function(response) {$scope.data10 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅋ').success(function(response) {$scope.data11 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅌ').success(function(response) {$scope.data12 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅍ').success(function(response) {$scope.data13 = response;});
$http.get('<?php echo APP_DATA_URL; ?>/data/user_data.php?linear=ㅎ').success(function(response) {$scope.data14 = response;});
var match = function (item, val) {
var regex = new RegExp(val, 'i');
return item.name_linear.toString().search(regex) == 0 ||
item.name.toString().search(regex) == 0 ||
item.tel_1_origin.toString().search(regex) == 0 ||
item.tel_1.toString().search(regex) == 0 ||
item.tel_4cut.toString().search(regex) == 0;
};
// 검색 설정
$scope.filterData = function(item) {
if(!$scope.searchField) return true;
var matched = true;
// Otherwise apply your matching logic
$scope.searchField.split(' ').forEach(function(token) {
matched = matched && match(item, token);
});
return matched;
}
}
</script>
<!-- 본문검색 { -->
<section id="topmenu">
<div class="header">
<p class="srchBox">
<span class="btn s"></span>
<input type="text" ng-model="searchField" class="txt" placeholder="이름, 전화번호를 입력해주세요.">
<a href="<?php echo APP_URL; ?>/member_form" class="btn new">신규고객</a>
</p>
</div>
</section>
<!-- } 본문검색 -->
<!-- 탭메뉴 { -->
<div class="calltab">
<ul>
<li class="off"><a href="#"><span>통화이력</span></a></li>
<li class="on"><a href="#"><span>고객목록</span></a></li>
</ul>
</div>
<!-- } 탭메뉴 -->
<!-- 리스트 { -->
<div class="memlist" ng-controller="address_book">
<h2 ng-if="data1">ㄱ</h2>
<ul ng-repeat="x in data1 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data2">ㄴ</h2>
<ul ng-repeat="x in data2 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data3">ㄷ</h2>
<ul ng-repeat="x in data3 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data4">ㄹ</h2>
<ul ng-repeat="x in data4 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data5">ㅁ</h2>
<ul ng-repeat="x in data5 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data6">ㅂ</h2>
<ul ng-repeat="x in data6 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data7">ㅅ</h2>
<ul ng-repeat="x in data7 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data8">ㅇ</h2>
<ul ng-repeat="x in data8 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data9">ㅈ</h2>
<ul ng-repeat="x in data9 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data10">ㅊ</h2>
<ul ng-repeat="x in data10 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data11">ㅋ</h2>
<ul ng-repeat="x in data11 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data12">ㅌ</h2>
<ul ng-repeat="x in data12 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data13">ㅍ</h2>
<ul ng-repeat="x in data13 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
<h2 ng-if="data14">ㅎ</h2>
<ul ng-repeat="x in data14 | filter:filterData">
<li>
<span ng-hide="true">{{x.name_linear}}</span>
<span ng-hide="true">{{x.tel_4cut}}</span>
<a href="tel:{{x.tel_1_origin}}" class="tel">
<p class="name">{{x.name}} {{x.tel_1}}</p>
<p class="age">{{x.sex}} / {{x.age}}세</p>
</a>
<a href="<?php echo APP_URL; ?>/member_form?idx={{x.idx}}" class="go ic">고객정보</a>
</li>
</ul>
</div>
<!-- } 리스트 -->
[/code]
댓글 6개
뭐? 이리 습득력이 빨라요......^-^
얼렁 쫏아가야 되는데 ...헉헉 되겠당.....ㅋㅋㅋㅋ
아직 많이 몰라요.
본격적으로 사용 한지가1주일 밖에 안되서
더 가볍네요.
좋은 정보 감사합니다.
다음앱에 적용 해봐야겠네요 ㅎㅎ
배열에 for($i=0;$i < sizeof($initial);$i++)문 돌리는게 더... T_T;
이해를 돕기위해 길게 작성 한겁니다 ㅎㅎㅎ
게시판 목록
프로그램
| 번호 | 제목 | 글쓴이 | 날짜 | 조회 |
|---|---|---|---|---|
| 7830 | 10년 전 | 446 | ||
| 7829 |
|
10년 전 | 632 | |
| 7828 | 10년 전 | 558 | ||
| 7827 | 10년 전 | 455 | ||
| 7826 | 10년 전 | 465 | ||
| 7825 | 10년 전 | 507 | ||
| 7824 | 10년 전 | 467 | ||
| 7823 | 10년 전 | 412 | ||
| 7822 | 10년 전 | 386 | ||
| 7821 | 10년 전 | 331 | ||
| 7820 | 10년 전 | 361 | ||
| 7819 |
|
10년 전 | 761 | |
| 7818 | 10년 전 | 409 | ||
| 7817 | 10년 전 | 568 | ||
| 7816 | 10년 전 | 428 | ||
| 7815 | 10년 전 | 624 | ||
| 7814 | 10년 전 | 462 | ||
| 7813 | 10년 전 | 415 | ||
| 7812 | 10년 전 | 427 | ||
| 7811 | 10년 전 | 408 | ||
| 7810 | 10년 전 | 602 | ||
| 7809 | 10년 전 | 536 | ||
| 7808 | 10년 전 | 412 | ||
| 7807 | 10년 전 | 430 | ||
| 7806 |
프로그래머7
|
10년 전 | 1355 | |
| 7805 | 10년 전 | 1296 | ||
| 7804 |
zahir1312
|
10년 전 | 794 | |
| 7803 |
|
10년 전 | 1395 | |
| 7802 | 10년 전 | 489 | ||
| 7801 | 10년 전 | 880 | ||
| 7800 | 10년 전 | 1099 | ||
| 7799 | 10년 전 | 581 | ||
| 7798 | 10년 전 | 533 | ||
| 7797 | 10년 전 | 545 | ||
| 7796 | 10년 전 | 384 | ||
| 7795 | 10년 전 | 536 | ||
| 7794 | 10년 전 | 580 | ||
| 7793 | 10년 전 | 1078 | ||
| 7792 | 10년 전 | 500 | ||
| 7791 | 10년 전 | 584 | ||
| 7790 | 10년 전 | 523 | ||
| 7789 |
fbastore
|
10년 전 | 1470 | |
| 7788 | 10년 전 | 574 | ||
| 7787 | 10년 전 | 431 | ||
| 7786 | 10년 전 | 632 | ||
| 7785 | 10년 전 | 615 | ||
| 7784 | 10년 전 | 671 | ||
| 7783 | 10년 전 | 485 | ||
| 7782 | 10년 전 | 519 | ||
| 7781 | 10년 전 | 922 | ||
| 7780 | 10년 전 | 839 | ||
| 7779 | 10년 전 | 793 | ||
| 7778 | 10년 전 | 376 | ||
| 7777 | 10년 전 | 487 | ||
| 7776 | 10년 전 | 485 | ||
| 7775 | 10년 전 | 425 | ||
| 7774 | 10년 전 | 640 | ||
| 7773 | 10년 전 | 397 | ||
| 7772 | 10년 전 | 761 | ||
| 7771 | 10년 전 | 416 | ||
| 7770 | 10년 전 | 662 | ||
| 7769 | 10년 전 | 416 | ||
| 7768 | 10년 전 | 634 | ||
| 7767 | 10년 전 | 1199 | ||
| 7766 | 10년 전 | 517 | ||
| 7765 | 10년 전 | 568 | ||
| 7764 |
잘살아보자
|
10년 전 | 422 | |
| 7763 |
|
10년 전 | 1485 | |
| 7762 |
Tosea
|
10년 전 | 1080 | |
| 7761 | 10년 전 | 675 | ||
| 7760 |
잘살아보자
|
10년 전 | 720 | |
| 7759 |
잘살아보자
|
10년 전 | 563 | |
| 7758 |
잘살아보자
|
10년 전 | 621 | |
| 7757 | 10년 전 | 1264 | ||
| 7756 |
ITBANK
|
10년 전 | 1275 | |
| 7755 | 10년 전 | 1940 | ||
| 7754 | 10년 전 | 1087 | ||
| 7753 | 10년 전 | 906 | ||
| 7752 | 10년 전 | 1413 | ||
| 7751 |
잘살아보자
|
10년 전 | 560 | |
| 7750 |
잘살아보자
|
10년 전 | 495 | |
| 7749 |
잘살아보자
|
10년 전 | 515 | |
| 7748 |
잘살아보자
|
10년 전 | 537 | |
| 7747 |
잘살아보자
|
10년 전 | 615 | |
| 7746 |
잘살아보자
|
10년 전 | 694 | |
| 7745 |
잘살아보자
|
10년 전 | 935 | |
| 7744 |
잘살아보자
|
10년 전 | 433 | |
| 7743 | 10년 전 | 961 | ||
| 7742 |
starbros
|
10년 전 | 855 | |
| 7741 |
잘살아보자
|
10년 전 | 694 | |
| 7740 |
잘살아보자
|
10년 전 | 579 | |
| 7739 |
잘살아보자
|
10년 전 | 478 | |
| 7738 |
잘살아보자
|
10년 전 | 555 | |
| 7737 |
잘살아보자
|
10년 전 | 532 | |
| 7736 |
잘살아보자
|
10년 전 | 549 | |
| 7735 |
잘살아보자
|
10년 전 | 883 | |
| 7734 |
잘살아보자
|
10년 전 | 443 | |
| 7733 |
잘살아보자
|
10년 전 | 559 | |
| 7732 |
잘살아보자
|
10년 전 | 720 | |
| 7731 |
잘살아보자
|
10년 전 | 638 |
댓글 작성
댓글을 작성하시려면 로그인이 필요합니다.
로그인하기