1 parent
52ba462e42
commit
a810fb2e98
1 file changed
+6
@@ -8,6 +8,9 @@ import lombok.extern.slf4j.Slf4j;
|
||||
import org.springframework.beans.factory.annotation.Value;
|
||||
import org.springframework.stereotype.Component;
|
||||
|
||||
import java.io.File;
|
||||
import java.util.Objects;
|
||||
|
||||
@Slf4j
|
||||
@Getter
|
||||
@Component
|
||||
@@ -25,6 +28,9 @@ public class WeComSdkClient {
|
||||
@PostConstruct
|
||||
public void init() {
|
||||
System.setProperty("java.library.path", libPath);
|
||||
for (File file : Objects.requireNonNull(new File(libPath).listFiles())) {
|
||||
System.load(file.getAbsolutePath());
|
||||
}
|
||||
sdk = Finance.NewSdk();
|
||||
int ret = Finance.Init(sdk, corpId, secret);
|
||||
if (ret != 0) {
|
||||
|
||||
Reference in new issue
Block a user