윤준석

FIX: rich menu and set default

......@@ -69,7 +69,7 @@ function handleEvent(event) {
})
);
}
} else if (event.postback.data == "check") {
} else if (event.postback.data == "checkItems") {
return Promise.resolve(
client.replyMessage(event.replyToken, {
type: "flex",
......@@ -166,51 +166,82 @@ module.exports = { handleEvent, config };
/*리치메뉴 설정*/
// let richMenu = {
// size: {
// width: 2500,
// height: 843,
// width: 2006,
// height: 827,
// },
// selected: false,
// name: "Nice richmenu",
// chatBarText: "Tap to open",
// name: "Real richMenu",
// chatBarText: "메뉴 열기",
// areas: [
// {
// bounds: {
// x: 0,
// y: 0,
// width: 1250,
// height: 843,
// width: 1003,
// height: 413,
// },
// action: {
// type: "postback",
// label: "new",
// data: "new",
// displayText: "키워드 등록",
// displayText: "키워드 추가",
// inputOption: "openKeyboard",
// fillInText: "",
// },
// },
// {
// bounds: {
// x: 1250,
// x: 1003,
// y: 0,
// width: 1250,
// height: 843,
// width: 1003,
// height: 413,
// },
// action: {
// type: "postback",
// label: "check",
// data: "check",
// displayText: "최신 매물 확인",
// displayText: "키워드 삭제",
// inputOption: "openKeyboard",
// fillInText: "",
// },
// },
// {
// bounds: {
// x: 0,
// y: 413,
// width: 1003,
// height: 414,
// },
// action: {
// type: "postback",
// label: "checkKeyword",
// data: "checkKeyword",
// displayText: "키워드 확인",
// },
// },
// {
// bounds: {
// x: 1003,
// y: 413,
// width: 1003,
// height: 414,
// },
// action: {
// type: "postback",
// label: "checkItems",
// data: "checkItems",
// displayText: "매물 즉시 검색",
// },
// },
// ],
// };
//// 등록
// client.createRichMenu(richMenu).then((richMenuId) => console.log(richMenuId));
// 등록
// client.createRichMenu(richMenu).then((richMenuId) => {
// console.log(richMenuId)
// });
// client.setRichMenuImage(
// "richmenu-183eff606f059b8244f0a625b54bddf1",
// fs.createReadStream("./static/img/richMenu.jpg")
// "richmenu-754798c14b181701c64cd7f0d37f52ec",
// fs.createReadStream("./static/img/richMenu.png")
// );
// client.setDefaultRichMenu("richmenu-183eff606f059b8244f0a625b54bddf1");
//client.setDefaultRichMenu("richmenu-754798c14b181701c64cd7f0d37f52ec");
......