전체 글351 728x90 Ionic 5 # [Android] Can not add task ': processDebugGoogleServices'as a task with that name already exists 개발환경 : ionic, android FCM 가이드를 따라 추가한 뒤 뜨는 에러 Can not add task ': processDebugGoogleServices'as a task with that name already exists 플러그인이 중복되어 나오는 에러였다. build.gradle 파일의 apply from 중 중복된 fcm 플러그인 소스를 주석처리하여 해결하였다. 참고 사이트 : https://cpoint-lab.co.jp/article/201808/5080/ 【Android】「Cannot add task ‘:processDebugGoogleServices’ as a task with that name already exists.」エラーの対処法 本日遭遇したエラーの対処法です。 状況はという.. 2020. 1. 16. Java #JSONArray 와 JSONObject로 JSON 생성하기 import org.json.simple.JSONArray; import org.json.simple.JSONObject; ... JSONArray jsonArray = new JSONArray(); JSONObject jsonObject = new JSONObject(); jsonObject.put("key1", "value1"); jsonObject.put("key2", "value1"); jsonArray.add(jsonObject); String jsonString = jsonArray.toJSONString(); //jsonString //=> [{"key1":"value1"}, {"key2":"value2"}] 2020. 1. 14. ionic 5 #staticInjectorError(AppModule)[UniqueDeviceID] ionic 의 unique-device-id 를 사용하고자 한 ts 파일에 import 하니 나온 에러.. staticInjectorError(AppModule)[UniqueDeviceID] app.module.ts 의 providers 에 추가하여 해결하였다. import { UniqueDeviceID } from '@ionic-native/unique-device-id/ngx'; @NgModule({ ... providers: [ ... UniqueDeviceID ], bootstrap: [AppComponent] }) export class AppModule {} https://ionicframework.com/docs/native/unique-device-id 2020. 1. 14. Java #원하는 길이의 랜덤숫자 생성 import java.util.concurrent.ThreadLocalRandom; public class HelloWorld{ public static void main(String []args){ System.out.println(getRandomLong(22)); //원하는 길이의 랜덤 숫자 반환 } /** * @description 원하는 길이의 랜덤 숫자 반환 * @param len 반환 받을 숫자의 길이 * @return result 결과 값 */ public static String getRandomLong(int len) { ThreadLocalRandom random = ThreadLocalRandom.current(); String result = ""; for(int i=0; i 2020. 1. 2. Angular 8 #does not exist on type 'GlobalEventHandlers' in angular 에러 does not exist on type 'GlobalEventHandlers' in angular does not exist on type 'GlobalEventHandlers' in angular 상황 html 파일의 iframe 태그에 ViewChild를 걸고 ts 파일에서 this.receiver.contentWindow 를 작성하였고 화면 출력시에 에러가 발생하였다. @ViewChild('myiframe') myiframe: HTMLElement; 해결 @ViewChild의 HTMLElement를 HTMLFrameElement 로 변경하니 해결되었다. HTML Element 에 따라 정확히 지정해두어야 오류가 나지 않는 것이다. @ViewChild('myiframe') myiframe: H.. 2019. 12. 19. ionic 5 #keypress is not working in Android 안드로이드 폰에서 keypress 가 먹히지 않는 이슈를 발견하였다. 숫자/문자 입력 이벤트를 잡기 위해 keypress대신 ionInput 으로 사용하고 Backspace나 Enter 같은 이벤트를 잡기 위해 keyup을 사용하였다. ion-input 의 value를 유효성 체크하여 값을 비우거나 유지하는 이벤트는 onChange로 사용하였다. 추가 작성. ionic 의 input event 는 속도가 너무 느리다! 속도 개선을 위해 ion-input를 지우고 숫자 키패드를 ion-grid로 출력해 터치 이벤트를 잡아 변수에 담아두는 방식으로 교체했다. 2019. 12. 16. ionic 5 #Modal Controller 추가하여 사용하기 modal.page.ts 준비 import { Component, Input } from '@angular/core'; import { NavParams, ModalController } from '@ionic/angular'; @Component({ selector: 'app-modal', templateUrl: './modal.page.html', styleUrls: ['./modal.page.scss'] }) export class ModalPage { @Input() something1: string; @Input() something2: string; constructor(private navParams: NavParams, private modalCtrl: ModalController) { c.. 2019. 12. 3. Angular 8 #사각형 내 점 판별 알고리즘으로 클릭 이벤트 설정하기 영역 외 클릭일 경우 해당 div를 zIndex로 숨긴다. (경우에 따라 다른 방법 가능) IE에선 zIndex를 숫자로 인식하는 현상이 있어 .toString()을 사용하였다. ============= html ============= button ============= ts ============= @ViewChild("_buttonRectangle", {static: false}) _buttonRectangle: jqxButtonComponent; @HostListener("click", ["$event"]) onClick(e) { var point = {x: e.clientX, y: e.clientY}; // 사각형 영역 var rect = this._buttonRectangle.nativeEl.. 2019. 11. 18. Tistory 방문자 통계 분석 #2019년 11월 13일 시뮝 연구소의 하루 방문자 수가 점점 증가하고 있다. 그 원인을 분석해본다. 1. 월간 방문 통계 지금이 11월 13일인 것을 감안하고 본다면 월간 방문 통계가 꾸준히 상승하는 것이란 것을 확인할 수 있다. 구글 검색을 통한 접근이 가장 많았으며, 두 번째는 다음이고 세 번째가 네이버다. PC를 통한 접근이 많은 편이다. 2. 최근 7일 통계 작년부터 눈치챘던 사실이며 이 글을 쓰게된 원인이기도 한 재미 있는 통계이다. 주말에 방문자들이 감소되는 것으로 방문자의 대부분이 직장인임을 암시한다. 그 와중에 주말에 검색한 분들을 보며 주말출근을 짐작할 수 있었다. 확신하는 이유는 토일요일이 아닌 공휴일에도 방문자가 줄어들었기 때문이다. 3. 조회수 1위 게시글 분석 사실 에러 해결법을 찾는 것에 힘이 들어 겨.. 2019. 11. 13. jqWidgets #jqxButton routerLink 2019. 11. 5. Angular #Lifecycle sequence HookPurpose and Timing ngOnChanges() Respond when Angular (re)sets data-bound input properties. The method receives a SimpleChanges object of current and previous property values. Called before ngOnInit() and whenever one or more data-bound input properties change. Angular가 데이터 바인딩 된 입력 속성을 설정할 때 응답합니다. 이 메소드는 현재 및 이전 특성 값의 SimpleChanges 오브젝트를 수신합니다. ngOnInit () 전에 호출되고 하나 이상의 데이터 바인딩 된 입력 속성이 변.. 2019. 10. 31. Angular #jqxRadioButton [groupName] is not working 1 2 type1 type2 jqxRadioButton 에 [groupName]을 주었는데 모든 버튼이 하나로 묶이는 현상이 생깁니다. 해결 방법을 찾다찾다 우연히 찾게된 놀라운 방법... I gave jqxRadioButton [groupName] and all the buttons are bundled together. Finding a solution Amazing way found by accident ... - html 파일 - 1 2 type1 type2 - ts 파일 - @ViewChildren('_type1 _type2') _types : jqxRadioButtonComponent; ... //this._types._results.find(result=>result.val()) //선택 값.. 2019. 10. 22. 728x90 이전 1 ··· 7 8 9 10 11 12 13 ··· 30 다음 728x90