@@ -6,7 +6,7 @@ import Vuex from 'vuex'; //引入 vuex
66Vue . use ( Vuex ) ;
77
88// const $http = "https://logboard-dev.numbersprotocol.io/api/v1/";
9- const $http = process . env . VUE_APP_API_HOST || "https://logboard-dev.numbersprotocol.io/api/v1/ " ;
9+ const $http = process . env . VUE_APP_API_HOST || "https://logboard-dev.numbersprotocol.io/api/v1" ;
1010// const $http = "https://logboard-dev.numbersprotocol.io/api/v1/";
1111
1212// const $raw_api = `${$http}/records/`;
@@ -261,7 +261,7 @@ export default new Vuex.Store({
261261 console . log ( "fetch past-days Api_start" ) ///past-days
262262 commit ( 'ChangisLoading' , true ) ;
263263 //https://logboard-dev.numbersprotocol.io/api/v1/records/past-days/?uid=8d83c9c8-72c6-43b7-8476-6b189a4e786f&template=heartFailure&range=this-month
264- return axios . get ( `${ $http } records/past-days/?uid=${ this . state . uid } &template=${ this . state . selectTemplate } &range=${ payload . range } ` ) . then ( response => {
264+ return axios . get ( `${ $http } / records/past-days/?uid=${ this . state . uid } &template=${ this . state . selectTemplate } &range=${ payload . range } ` ) . then ( response => {
265265 console . log ( "fetchDaysApi_get" , response ) ///past-days
266266 console . log ( response ) ///past-days
267267 console . log ( response . data . length ) ///past-days
@@ -342,7 +342,7 @@ export default new Vuex.Store({
342342 console . log ( "fetchTODaysApi_start" )
343343 commit ( 'ChangisLoading' , true ) ;
344344 //https://logboard-dev.numbersprotocol.io/api/v1/records/today/?uid=8d83c9c8-72c6-43b7-8476-6b189a4e786f&template=heartFailure
345- return axios . get ( `${ $http } records/today/?uid=${ this . state . uid } &template=${ this . state . selectTemplate } ` ) . then ( response => {
345+ return axios . get ( `${ $http } / records/today/?uid=${ this . state . uid } &template=${ this . state . selectTemplate } ` ) . then ( response => {
346346 console . log ( "fetchTODaysApi_get" , response )
347347 console . log ( response )
348348 console . log ( response . data . timestamp )
0 commit comments