| 1 |
<template> |
| 2 |
<div class="wpfnl-step__single-template" > |
| 3 |
<div class="template-preview-image"> |
| 4 |
<div class="template-action"> |
| 5 |
<a :href="step.link" target="_blank" class="btn-default step-btn"> preview </a> |
| 6 |
</div> |
| 7 |
|
| 8 |
<div class="step-image-wrapper" :style="{ backgroundImage: `url(${image})` }"> |
| 9 |
</div> |
| 10 |
</div> |
| 11 |
|
| 12 |
<div class="step-template-info"> |
| 13 |
<span class="title">{{step.title}}</span> |
| 14 |
</div> |
| 15 |
</div> |
| 16 |
</template> |
| 17 |
<script> |
| 18 |
export default { |
| 19 |
name: 'SingleStepPreview', |
| 20 |
props: { |
| 21 |
step: Object, |
| 22 |
image: String, |
| 23 |
previewLink: String, |
| 24 |
isAddNewFunnelButtonDisabled: Boolean, |
| 25 |
}, |
| 26 |
data: function () { |
| 27 |
return { |
| 28 |
showLoader : false |
| 29 |
} |
| 30 |
}, |
| 31 |
methods: { |
| 32 |
importStep: function (e) { |
| 33 |
e.preventDefault(); |
| 34 |
var that = this; |
| 35 |
this.showLoader = true; |
| 36 |
that.createStep( {'id' : this.step.id, 'type' : this.step.step_type, 'name' : this.step.step_type}, this.funnelID, that); |
| 37 |
}, |
| 38 |
} |
| 39 |
} |
| 40 |
</script> |