🐛 Fixed issues with sync, squashed a bug introduced in last transpile
This commit is contained in:
36
README.md
36
README.md
@@ -1,5 +1,5 @@
|
|||||||
<div align="center">
|
<div align="center">
|
||||||
<a href="https://postwoman.io"><img src="static/logo.png" alt="Postwoman.io logo" height="160"></a>
|
<a href="https://postwoman.io"><img src="https://raw.githubusercontent.com/liyasthomas/postwoman/master/static/logo.png" alt="Postwoman.io logo" height="160"></a>
|
||||||
<br>
|
<br>
|
||||||
<br>
|
<br>
|
||||||
<p>
|
<p>
|
||||||
@@ -8,7 +8,7 @@
|
|||||||
<p>
|
<p>
|
||||||
<i>Web alternative to Postman - Helps you create requests faster, saving precious time on development - <a href="https://postwoman.launchaco.com">Subscribe</a></i>
|
<i>Web alternative to Postman - Helps you create requests faster, saving precious time on development - <a href="https://postwoman.launchaco.com">Subscribe</a></i>
|
||||||
</p>
|
</p>
|
||||||
<p>
|
<p style="width: 80%;">
|
||||||
|
|
||||||
[](https://travis-ci.com/liyasthomas/postwoman) [](https://github.com/liyasthomas/postwoman/releases/latest) [](https://postwoman.io) [](CONTRIBUTING.md) [](https://opencollective.com/postwoman) [](https://www.paypal.me/liyascthomas) [](https://t.me/postwoman_app) [](https://discord.gg/GAMWxmR) [](https://twitter.com/intent/tweet?url=https%3A%2F%2Fpostwoman.io&text=%F0%9F%91%BD%20Postwoman%20%E2%80%A2%20API%20request%20builder%20-%20Helps%20you%20create%20your%20requests%20faster%2C%20saving%20you%20precious%20time%20on%20your%20development&original_referer=https%3A%2F%2Ftwitter.com%2Fshare%3Ftext%3D%25F0%259F%2591%25BD%2520Postwoman%2520%25E2%2580%25A2%2520API%2520request%2520builder%2520-%2520Helps%2520you%2520create%2520your%2520requests%2520faster%2C%2520saving%2520you%2520precious%2520time%2520on%2520your%2520development%26url%3Dhttps%3A%2F%2Fpostwoman.io%26hashtags%3Dpostwoman%26via%3Dliyasthomas&via=liyasthomas&hashtags=postwoman)
|
[](https://travis-ci.com/liyasthomas/postwoman) [](https://github.com/liyasthomas/postwoman/releases/latest) [](https://postwoman.io) [](CONTRIBUTING.md) [](https://opencollective.com/postwoman) [](https://www.paypal.me/liyascthomas) [](https://t.me/postwoman_app) [](https://discord.gg/GAMWxmR) [](https://twitter.com/intent/tweet?url=https%3A%2F%2Fpostwoman.io&text=%F0%9F%91%BD%20Postwoman%20%E2%80%A2%20API%20request%20builder%20-%20Helps%20you%20create%20your%20requests%20faster%2C%20saving%20you%20precious%20time%20on%20your%20development&original_referer=https%3A%2F%2Ftwitter.com%2Fshare%3Ftext%3D%25F0%259F%2591%25BD%2520Postwoman%2520%25E2%2580%25A2%2520API%2520request%2520builder%2520-%2520Helps%2520you%2520create%2520your%2520requests%2520faster%2C%2520saving%2520you%2520precious%2520time%2520on%2520your%2520development%26url%3Dhttps%3A%2F%2Fpostwoman.io%26hashtags%3Dpostwoman%26via%3Dliyasthomas&via=liyasthomas&hashtags=postwoman)
|
||||||
|
|
||||||
@@ -30,11 +30,31 @@
|
|||||||
**Donate: [Open Collective](https://opencollective.com/postwoman), [PayPal](https://www.paypal.me/liyascthomas), [Patreon](https://www.patreon.com/liyasthomas), [:octocat: GitHub Sponsors](https://github.com/sponsors/postwoman-io)**
|
**Donate: [Open Collective](https://opencollective.com/postwoman), [PayPal](https://www.paypal.me/liyascthomas), [Patreon](https://www.patreon.com/liyasthomas), [:octocat: GitHub Sponsors](https://github.com/sponsors/postwoman-io)**
|
||||||
|
|
||||||
<div align="center">
|
<div align="center">
|
||||||
<br>
|
<a href="https://postwoman.io"><img src="https://raw.githubusercontent.com/liyasthomas/postwoman/master/static/images/screenshot1.png" alt="Screenshot1" width="100%"></a>
|
||||||
<a href="https://postwoman.io"><img src="static/images/screenshot1.png" alt="Screenshot1" width="100%"></a>
|
|
||||||
<br>
|
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
|
<details>
|
||||||
|
<summary>Table of contents</summary>
|
||||||
|
|
||||||
|
---
|
||||||
|
1. [Features](#features-)
|
||||||
|
2. [Demo](#demo--)
|
||||||
|
3. [Usage](#usage-)
|
||||||
|
4. [Built with](#built-with-)
|
||||||
|
5. [Developing](#developing-)
|
||||||
|
6. [Docker](#docker--)
|
||||||
|
7. [Releasing](#releasing-)
|
||||||
|
8. [Contributing](#contributing-)
|
||||||
|
9. [Continuous Integration](#continuous-integration--)
|
||||||
|
10. [Versioning](#versioning--)
|
||||||
|
11. [Change log](#change-log-)
|
||||||
|
12. [Authors](#authors-)
|
||||||
|
13. [License](#license-)
|
||||||
|
14. [Acknowledgements](#acknowledgements-)
|
||||||
|
15. [Badges](#badges-)
|
||||||
|
---
|
||||||
|
</details>
|
||||||
|
|
||||||
### Features ✨
|
### Features ✨
|
||||||
|
|
||||||
❤️ **Lightweight**: Crafted with minimalistic UI design - simple design is the best design.
|
❤️ **Lightweight**: Crafted with minimalistic UI design - simple design is the best design.
|
||||||
@@ -324,7 +344,7 @@ docker run -p 3000:3000 liyasthomas/postwoman:latest
|
|||||||
docker build -t postwoman:latest
|
docker build -t postwoman:latest
|
||||||
```
|
```
|
||||||
|
|
||||||
## Releasing 🏷️
|
## Releasing 🧞
|
||||||
|
|
||||||
1. [Clone this repo](https://help.github.com/en/articles/cloning-a-repository) with git.
|
1. [Clone this repo](https://help.github.com/en/articles/cloning-a-repository) with git.
|
||||||
2. Install dependencies by running `npm install` within the directory that you cloned (probably `postwoman`).
|
2. Install dependencies by running `npm install` within the directory that you cloned (probably `postwoman`).
|
||||||
@@ -347,7 +367,7 @@ This project is developed by [Liyas Thomas](https://github.com/liyasthomas) usin
|
|||||||
|
|
||||||
See the [CHANGELOG](CHANGELOG.md) file for details.
|
See the [CHANGELOG](CHANGELOG.md) file for details.
|
||||||
|
|
||||||
## Authors 🔮
|
## Authors 🧙
|
||||||
|
|
||||||
### Lead Developers
|
### Lead Developers
|
||||||
|
|
||||||
@@ -441,7 +461,7 @@ This project is licensed under the [MIT License](https://opensource.org/licenses
|
|||||||
- Inspirations:
|
- Inspirations:
|
||||||
- [Dribbble](https://dribbble.com)
|
- [Dribbble](https://dribbble.com)
|
||||||
|
|
||||||
## Badges
|
## Badges 📛
|
||||||
|
|
||||||
<table>
|
<table>
|
||||||
<tr>
|
<tr>
|
||||||
|
|||||||
@@ -64,6 +64,14 @@ export default {
|
|||||||
collectionIndex: this.$props.collectionIndex,
|
collectionIndex: this.$props.collectionIndex,
|
||||||
})
|
})
|
||||||
this.hideModal()
|
this.hideModal()
|
||||||
|
this.syncCollections()
|
||||||
|
},
|
||||||
|
syncCollections() {
|
||||||
|
if (fb.currentUser !== null) {
|
||||||
|
if (fb.currentSettings[0].value) {
|
||||||
|
fb.writeCollections(JSON.parse(JSON.stringify(this.$store.state.postwoman.collections)))
|
||||||
|
}
|
||||||
|
}
|
||||||
},
|
},
|
||||||
hideModal() {
|
hideModal() {
|
||||||
this.$emit("hide-modal")
|
this.$emit("hide-modal")
|
||||||
|
|||||||
@@ -122,6 +122,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.$store.commit("postwoman/importCollections", collections)
|
this.$store.commit("postwoman/importCollections", collections)
|
||||||
this.fileImported()
|
this.fileImported()
|
||||||
|
this.syncToFBCollections()
|
||||||
}
|
}
|
||||||
reader.readAsText(this.$refs.inputChooseFileToReplaceWith.files[0])
|
reader.readAsText(this.$refs.inputChooseFileToReplaceWith.files[0])
|
||||||
},
|
},
|
||||||
@@ -142,6 +143,7 @@ export default {
|
|||||||
}
|
}
|
||||||
this.$store.commit("postwoman/importCollections", collections)
|
this.$store.commit("postwoman/importCollections", collections)
|
||||||
this.fileImported()
|
this.fileImported()
|
||||||
|
this.syncToFBCollections()
|
||||||
}
|
}
|
||||||
reader.readAsText(this.$refs.inputChooseFileToImportFrom.files[0])
|
reader.readAsText(this.$refs.inputChooseFileToImportFrom.files[0])
|
||||||
},
|
},
|
||||||
@@ -167,6 +169,13 @@ export default {
|
|||||||
this.$store.commit("postwoman/replaceCollections", fb.currentCollections)
|
this.$store.commit("postwoman/replaceCollections", fb.currentCollections)
|
||||||
this.fileImported()
|
this.fileImported()
|
||||||
},
|
},
|
||||||
|
syncToFBCollections() {
|
||||||
|
if (fb.currentUser !== null) {
|
||||||
|
if (fb.currentSettings[0].value) {
|
||||||
|
fb.writeCollections(JSON.parse(JSON.stringify(this.$store.state.postwoman.collections)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
fileImported() {
|
fileImported() {
|
||||||
this.$toast.info(this.$t("file_imported"), {
|
this.$toast.info(this.$t("file_imported"), {
|
||||||
icon: "folder_shared",
|
icon: "folder_shared",
|
||||||
|
|||||||
@@ -84,8 +84,8 @@ export default {
|
|||||||
this.syncEnvironments()
|
this.syncEnvironments()
|
||||||
},
|
},
|
||||||
hideModal() {
|
hideModal() {
|
||||||
this.$data.name = undefined
|
|
||||||
this.$emit("hide-modal")
|
this.$emit("hide-modal")
|
||||||
|
this.$data.name = undefined
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -135,7 +135,7 @@ export default {
|
|||||||
}
|
}
|
||||||
},
|
},
|
||||||
watch: {
|
watch: {
|
||||||
editingEnvironment: function(update) {
|
editingEnvironment: function (update) {
|
||||||
this.name =
|
this.name =
|
||||||
this.$props.editingEnvironment && this.$props.editingEnvironment.name
|
this.$props.editingEnvironment && this.$props.editingEnvironment.name
|
||||||
? this.$props.editingEnvironment.name
|
? this.$props.editingEnvironment.name
|
||||||
@@ -210,8 +210,8 @@ export default {
|
|||||||
this.syncEnvironments()
|
this.syncEnvironments()
|
||||||
},
|
},
|
||||||
hideModal() {
|
hideModal() {
|
||||||
this.$data.name = undefined
|
|
||||||
this.$emit("hide-modal")
|
this.$emit("hide-modal")
|
||||||
|
this.$data.name = undefined
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
@@ -168,10 +168,18 @@ export default {
|
|||||||
this.$store.commit("postwoman/replaceEnvironments", fb.currentEnvironments)
|
this.$store.commit("postwoman/replaceEnvironments", fb.currentEnvironments)
|
||||||
this.fileImported()
|
this.fileImported()
|
||||||
},
|
},
|
||||||
|
syncToFBEnvironments() {
|
||||||
|
if (fb.currentUser !== null) {
|
||||||
|
if (fb.currentSettings[1].value) {
|
||||||
|
fb.writeEnvironments(JSON.parse(JSON.stringify(this.$store.state.postwoman.environments)))
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
fileImported() {
|
fileImported() {
|
||||||
this.$toast.info(this.$t("file_imported"), {
|
this.$toast.info(this.$t("file_imported"), {
|
||||||
icon: "folder_shared",
|
icon: "folder_shared",
|
||||||
})
|
})
|
||||||
|
this.syncToFBEnvironments()
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
}
|
}
|
||||||
|
|||||||
Binary file not shown.
|
Before Width: | Height: | Size: 95 KiB After Width: | Height: | Size: 88 KiB |
@@ -138,9 +138,11 @@ export const mutations = {
|
|||||||
},
|
},
|
||||||
|
|
||||||
importAddEnvironments(state, { environments, confirmation }) {
|
importAddEnvironments(state, { environments, confirmation }) {
|
||||||
const duplicateEnvironment = environments.some(({ name }) =>
|
const duplicateEnvironment = environments.some((item) => {
|
||||||
state.environments.some(({ name }) => name.toLowerCase() === name.toLowerCase())
|
return state.environments.some((item2) => {
|
||||||
)
|
return item.name.toLowerCase() === item2.name.toLowerCase()
|
||||||
|
})
|
||||||
|
})
|
||||||
if (duplicateEnvironment) {
|
if (duplicateEnvironment) {
|
||||||
this.$toast.info("Duplicate environment")
|
this.$toast.info("Duplicate environment")
|
||||||
return
|
return
|
||||||
|
|||||||
Reference in New Issue
Block a user