diff --git a/README.md b/README.md new file mode 100644 index 0000000..3e73fde --- /dev/null +++ b/README.md @@ -0,0 +1,19 @@ +# api-xsmb-today + +> take infor from api by https://api-xsmb-today.herokuapp.com/v1 +> +> web-scraped from https://xosoketqua.com/xsmb-xo-so-mien-bac.html + +--- + +| Keys | Type | +| ---- | ------ | +| time | String | +| G.ĐB | String | +| G.1 | String | +| G.2 | String | +| G.3 | String | +| G.4 | String | +| G.5 | String | +| G.6 | String | +| G.7 | String | diff --git a/controllers/mainController.js b/controllers/mainController.js index 39acd0d..0070eb6 100644 --- a/controllers/mainController.js +++ b/controllers/mainController.js @@ -110,9 +110,12 @@ class MainController { nowDay.getFullYear(); // console.log(nowDay.getHours() + ':' + nowDay.getMinutes()); // console.log(objTimesNames); + + const date = $('.class-title-list-link', html).first().find('a:last-child').text().split(' ')[1]; + res.status(200).json({ countNumbers: numbers.length, - time: calendar, + time: date, objTimesNames, }); });