mirror of
https://github.com/lingble/chatwoot.git
synced 2025-11-01 19:48:08 +00:00
feat: Add CSAT response submit action (#2506)
Co-authored-by: Pranav Raj S <pranav@chatwoot.com>
This commit is contained in:
@@ -44,7 +44,11 @@
|
||||
<div v-if="isArticle">
|
||||
<chat-article :items="messageContentAttributes.items"></chat-article>
|
||||
</div>
|
||||
<customer-satisfaction v-if="isCSAT" />
|
||||
<customer-satisfaction
|
||||
v-if="isCSAT"
|
||||
:message-content-attributes="messageContentAttributes.submitted_values"
|
||||
@submit="onCSATSubmit"
|
||||
/>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
@@ -121,6 +125,17 @@ export default {
|
||||
messageId: this.messageId,
|
||||
});
|
||||
},
|
||||
onCSATSubmit({ feedback, rating }) {
|
||||
this.onResponse({
|
||||
submittedValues: {
|
||||
csat_survey_response: {
|
||||
rating,
|
||||
feedback_text: feedback,
|
||||
},
|
||||
},
|
||||
messageId: this.messageId,
|
||||
});
|
||||
},
|
||||
},
|
||||
};
|
||||
</script>
|
||||
|
||||
Reference in New Issue
Block a user