mirror of
https://gitee.com/dromara/electron-egg.git
synced 2026-05-14 11:52:07 +08:00
add service
This commit is contained in:
@@ -6,7 +6,7 @@ const eggApiroute = {
|
||||
messageShow: '/api/example/messageShow',
|
||||
messageShowConfirm: '/api/example/messageShowConfirm',
|
||||
dbOperation: '/api/example/dbOperation',
|
||||
testElectronApi: '/api/example/testElectronApi',
|
||||
test1: '/api/example/test1',
|
||||
}
|
||||
|
||||
const ipcApiRoute = {
|
||||
|
||||
@@ -24,7 +24,7 @@ export default {
|
||||
const params = {
|
||||
id: id
|
||||
}
|
||||
requestEggApi('testElectronApi', params).then(res => {
|
||||
requestEggApi('test1', params).then(res => {
|
||||
if (res.code !== 0) {
|
||||
return false
|
||||
}
|
||||
|
||||
@@ -10,7 +10,6 @@
|
||||
</div>
|
||||
</template>
|
||||
<script>
|
||||
import { requestEggApi } from '@/api/main'
|
||||
|
||||
export default {
|
||||
data() {
|
||||
@@ -18,14 +17,6 @@ export default {
|
||||
},
|
||||
methods: {
|
||||
test () {
|
||||
const params = {}
|
||||
requestEggApi('openDir', params).then(res => {
|
||||
if (res.code !== 0) {
|
||||
return false
|
||||
}
|
||||
}).catch(err => {
|
||||
console.log('err:', err)
|
||||
})
|
||||
},
|
||||
}
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user