zahmis %!s(int64=5) %!d(string=hai) anos
pai
achega
e332290c5f
Modificáronse 1 ficheiros con 4 adicións e 1 borrados
  1. 4 1
      src/server/service/bolt.js

+ 4 - 1
src/server/service/bolt.js

@@ -80,13 +80,16 @@ class BoltService {
       const inputSlack = command.text.split(' ');
       const firstArg = inputSlack[0];
       const secondArg = inputSlack[1];
+      await ack();
 
       if (firstArg === 'search') {
         const { searchService } = this.crowi;
         const option = { limit: 10 };
         const results = await searchService.searchKeyword(secondArg, null, {}, option);
         // get 10 result from slack input
-        console.log(results.data);
+        // console.log(results.data[0]);
+
+        await say(`${results.data[0]._id}`);
       }
       return;
     });