send messeges, fix #12
This commit is contained in:
parent
3f29e8c4e7
commit
e487aebc4e
@ -18,7 +18,7 @@ urlpatterns = [
|
||||
path('player/media/op/', views.FileOperations.as_view()),
|
||||
re_path(r'^player/media/upload/(?P<filename>[^/]+)$',
|
||||
views.FileUpload.as_view()),
|
||||
path('player/messenger/send/', views.MessegeSender.as_view()),
|
||||
path('player/send/message/', views.MessageSender.as_view()),
|
||||
path('player/playlist/', views.Playlist.as_view()),
|
||||
path('player/stats/', views.Statistics.as_view()),
|
||||
path('player/user/current/', views.CurrentUserView.as_view()),
|
||||
|
@ -58,7 +58,10 @@ class MessengerViewSet(viewsets.ModelViewSet):
|
||||
filterset_class = MessengerFilter
|
||||
|
||||
|
||||
class MessegeSender(APIView):
|
||||
class MessageSender(APIView):
|
||||
"""
|
||||
send messages with zmq to the playout engine
|
||||
"""
|
||||
|
||||
def post(self, request, *args, **kwargs):
|
||||
if 'data' in request.data:
|
||||
|
@ -223,7 +223,6 @@
|
||||
</template>
|
||||
|
||||
<script>
|
||||
// import { mapState } from 'vuex'
|
||||
import Menu from '@/components/Menu.vue'
|
||||
|
||||
export default {
|
||||
@ -406,7 +405,7 @@ export default {
|
||||
boxborderw: this.form.border
|
||||
}
|
||||
|
||||
const response = await this.$axios.post('api/player/messenger/send/', { data: obj })
|
||||
const response = await this.$axios.post('api/player/send/message/', { data: obj })
|
||||
|
||||
if (response.data && response.data.status.Success && response.data.status.Success === '0 Success') {
|
||||
this.success = true
|
||||
@ -418,7 +417,7 @@ export default {
|
||||
}
|
||||
</script>
|
||||
|
||||
<style>
|
||||
<style scoped>
|
||||
.messege-container {
|
||||
margin-top: 5em;
|
||||
}
|
||||
@ -427,4 +426,9 @@ export default {
|
||||
width: 50%;
|
||||
margin-bottom: 2em;
|
||||
}
|
||||
|
||||
.sub-btn {
|
||||
min-width: 90px;
|
||||
max-width: 100px;
|
||||
}
|
||||
</style>
|
||||
|
Loading…
x
Reference in New Issue
Block a user