# 6. 푸시 알람을 누르면 상세 화면으로 이동하게 하고 싶어요.

{% hint style="info" %}
아직 UI화 되지 않은 부분이에요.

코드를 사용하지만 어렵지 않으니 잘 따라와 주세요.
{% endhint %}

관리자 웹 > 고급 설정 > 로직 설정에서 설정할 푸시 로직을 찾아주세요.

<figure><img src="https://3976660509-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2FDgfvhQgmY9NbRK0Sln7j%2Fuploads%2FINZ0sji4CquOs4bDnaEw%2FScreenshot%202024-07-17%20at%208.01.07%E2%80%AFPM.png?alt=media&#x26;token=27955ff5-3fb1-4f63-b506-11db1964595a" alt=""><figcaption></figcaption></figure>

위 사진처럼 **flowOptions**에 아래 코드를 넣어주세요.

flowOptions는 로직 설정의 **Then > To do** 부분이에요.

```json
"custom": {
	"detailObjectId": "newDocument._id",
	"type": "read",
	"findByMeta": "readMeta",
	"metaCode": "community"
},
"pushAppendData": {
	"itemId": {
		"method": "type",
		"name": "cast",
		"details": {
			"type": "toString",
			"base": "newDocument._id"
		}
	},
	"findByMeta": "readMeta",
	"menuName": "푸시 온 글",
	"type": "read",
	"metaCode": "community"
}
```

### 상위 Method

* custom : 푸시 내역을 눌렀을 때 이동할 곳
* pushAppendData : 앱 푸시 눌렀을 때 이동할 곳

### 하위 공통 Method

* metaCode : 이동할 메타 (ex: community, \_users, ...)
* findByMeta : 그 메타의 어떤 화면 (ex: listMeta, readMeta, editMeta)
  * 등록/수정 화면 : editMeta
  * 목록 화면 : listMeta
  * 상세 화면 : readMeta
* type : 이동할 화면의 타입
  * 등록/수정 화면 : edit
  * 목록 화면 : list
  * 상세 화면 : read
  * 복합 메타 : multiList

### 상세 화면으로 이동할 때

* detailObjectId : 상세 화면으로 이동할 경우 그 화면의 id
  * custom에 사용
  * (ex: newDocument.\_id, tmpDocument.magazineDoc.\_id)
* itemId : 상세 화면으로 이동할 경우 그 화면의 id
  * pushAppendData에 사용
  * base의 값만 수정하여 사용
  * (ex: newDocument.postJoin.\_id, tmpDocument.myPostDoc.\_id)

원하는 게시글의 id를 찾는 법은 다른 로직 강의를 참고해 주세요.

24.07.17 Jihwan
