Oct 11 fxes (#9181)

* Added unqequip for hair styles

* Added quest rewards to quest completed modal

* Fixed display of task approvals

* Ensured the user is welcomed before showing login notification

* Added new message modal

* fixed manager functions

* Fixed group edit on group plan
This commit is contained in:
Keith Holliday
2017-10-13 06:40:53 +02:00
committed by GitHub
parent 9ca6da0f75
commit fac1889776
14 changed files with 83 additions and 109 deletions

View File

@@ -1,63 +0,0 @@
<template lang="pug">
b-modal#private-message(title="Message", size='md', :hide-footer="true")
.content
textarea.form-control(v-model='privateMessage')
button.btn.btn-primary(@click='sendPrivateMessage()', :disabled='loading') Send
</template>
<style lang="scss" scoped>
.content {
padding: 1em;
textarea {
margin-bottom: 1em;
}
}
</style>
<script>
import bModal from 'bootstrap-vue/lib/components/modal';
import notifications from 'client/mixins/notifications';
export default {
mixins: [notifications],
components: {
bModal,
},
data () {
return {
privateMessage: '',
loading: false,
userIdToMessage: '',
};
},
computed: {
userIdToMessageStore () {
return this.$store.state.userIdToMessage;
},
},
watch: {
userIdToMessageStore () {
this.userIdToMessage = this.userIdToMessageStore;
},
},
methods: {
async sendPrivateMessage () {
if (!this.privateMessage || !this.userIdToMessage) return;
this.loading = true;
await this.$store.dispatch('members:sendPrivateMessage', {
message: this.privateMessage,
toUserId: this.userIdToMessage,
});
this.loading = false;
this.text(this.$t('messageSentAlert'));
this.privateMessage = '';
},
},
};
</script>