|
|
|
@ -186,10 +186,13 @@
|
|
|
|
|
splaceholder="请输入内容"
|
|
|
|
|
v-model="inputQuery.appSecret"
|
|
|
|
|
></el-input>
|
|
|
|
|
<el-button type="primary" style="margin-left: 10px;" @click="testConnection()">测试连通性
|
|
|
|
|
</el-button>
|
|
|
|
|
</el-form-item>
|
|
|
|
|
</div>
|
|
|
|
|
</el-col>
|
|
|
|
|
</el-row>
|
|
|
|
|
|
|
|
|
|
</el-card>
|
|
|
|
|
<div style="text-align: center">
|
|
|
|
|
<el-form-item>
|
|
|
|
@ -213,6 +216,7 @@
|
|
|
|
|
getCompany,
|
|
|
|
|
modifyCompany,
|
|
|
|
|
getRefid,
|
|
|
|
|
testConnection
|
|
|
|
|
} from "../../api/warehouse/company";
|
|
|
|
|
import store from "../../store/index";
|
|
|
|
|
|
|
|
|
@ -330,6 +334,26 @@
|
|
|
|
|
this.inputQuery.bussinessStatus = this.inputQuery.bussinessStatus + "";
|
|
|
|
|
});
|
|
|
|
|
},
|
|
|
|
|
//测试连通性
|
|
|
|
|
testConnection() {
|
|
|
|
|
if (this.inputQuery.appId === '' || this.inputQuery.appSecret === '') {
|
|
|
|
|
this.$message.error("请输入授权参数");
|
|
|
|
|
} else {
|
|
|
|
|
let param = {
|
|
|
|
|
appId: this.inputQuery.appId,
|
|
|
|
|
appSecret: this.inputQuery.appSecret
|
|
|
|
|
};
|
|
|
|
|
testConnection(param).then((res) => {
|
|
|
|
|
if (res.code == 20000) {
|
|
|
|
|
this.$message.success("连接成功");
|
|
|
|
|
} else {
|
|
|
|
|
this.$message.error("无法连接");
|
|
|
|
|
}
|
|
|
|
|
}).catch(() => {
|
|
|
|
|
this.$message.error("无法连接");
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
};
|
|
|
|
|
</script>
|
|
|
|
|