update function checkIndexSN
This commit is contained in:
		
							parent
							
								
									0bb2557cd6
								
							
						
					
					
						commit
						f686c7b9ed
					
				| 
						 | 
				
			
			@ -166,13 +166,16 @@ export const checkIndexSN = async (content, beginLine, nameF) => {
 | 
			
		|||
          }
 | 
			
		||||
        }
 | 
			
		||||
      }
 | 
			
		||||
    //   console.log(nameF+" output\n", output);
 | 
			
		||||
      if (output.filter((i)=>i.PID!=="").length > 0) {
 | 
			
		||||
      //   console.log(nameF+" output\n", output);
 | 
			
		||||
      if (output.filter((i) => i.PID !== "").length > 0) {
 | 
			
		||||
        let token =
 | 
			
		||||
          "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczovL2FwaS5uc3d0ZWFtLm5ldC9hcGkvbG9naW4iLCJpYXQiOjE2ODkzOTEyMDMsImV4cCI6MTcyMDkyNzIwMywibmJmIjoxNjg5MzkxMjAzLCJqdGkiOiJreFA1MW9jck5rdEYzSzY3Iiwic3ViIjozNjkwLCJwcnYiOiJjOGVlMWZjODllNzc1ZWM0YzczODY2N2U1YmUxN2E1OTBiNmQ0MGZjIn0.p-aE0oWkKmdrcKWD94oSmMd_CMbY_4MoqADIwYIhIKw";
 | 
			
		||||
        
 | 
			
		||||
          let data = {
 | 
			
		||||
          data: output.filter((i)=>i.PID!==""),
 | 
			
		||||
        let token_int =
 | 
			
		||||
          "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJpc3MiOiJodHRwczovL2ludC5pcHN1cHBseS5jb20uYXUvYXBpL2xvZ2luIiwiaWF0IjoxNjg5ODYyNjAxLCJleHAiOjE3MjEzOTg2MDEsIm5iZiI6MTY4OTg2MjYwMSwianRpIjoiUElZVjNBM3ZPQVlMQ081SyIsInN1YiI6MSwicHJ2IjoiYzhlZTFmYzg5ZTc3NWVjNGM3Mzg2NjdlNWJlMTdhNTkwYjZkNDBmYyJ9.UcybIKMBjTAY9i0PfIDQMtqHyN72Ul0jC03ZDGLGpMI";
 | 
			
		||||
        
 | 
			
		||||
        let data = {
 | 
			
		||||
          data: output.filter((i) => i.PID !== ""),
 | 
			
		||||
          urlAPI: "/api/test-log-serial-number/save-data",
 | 
			
		||||
        };
 | 
			
		||||
 | 
			
		||||
| 
						 | 
				
			
			@ -182,7 +185,13 @@ export const checkIndexSN = async (content, beginLine, nameF) => {
 | 
			
		|||
          { headers: { Authorization: "Bearer " + token } }
 | 
			
		||||
        );
 | 
			
		||||
 | 
			
		||||
        console.log(nameF+" response\n",response.data)
 | 
			
		||||
        // const response_int = await axios.post(
 | 
			
		||||
        //     "https://int.ipsupply.com.au/api/transferPostData",
 | 
			
		||||
        //     data,
 | 
			
		||||
        //     { headers: { Authorization: "Bearer " + token } }
 | 
			
		||||
        //   );
 | 
			
		||||
 | 
			
		||||
        console.log(nameF + " response\n", response.data);
 | 
			
		||||
      }
 | 
			
		||||
    }
 | 
			
		||||
  } catch (error) {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
| 
						 | 
				
			
			@ -45,7 +45,7 @@ const databaseConfig: DatabaseConfig = {
 | 
			
		|||
      pool: {
 | 
			
		||||
        min: 1,
 | 
			
		||||
        max: 2000,
 | 
			
		||||
        acquireTimeoutMillis: 60 * 1000,
 | 
			
		||||
        acquireTimeoutMillis: 60 * 1000
 | 
			
		||||
      },
 | 
			
		||||
 | 
			
		||||
      migrations: {
 | 
			
		||||
| 
						 | 
				
			
			
 | 
			
		|||
		Loading…
	
		Reference in New Issue