[O] Lock submission button when in demo mode
This commit is contained in:
@@ -72,7 +72,7 @@
|
|||||||
|
|
||||||
<span slot="footer" class="dialog-footer">
|
<span slot="footer" class="dialog-footer">
|
||||||
<el-button @click="ratingDialog = false" :disabled="ratingPosting">Cancel</el-button>
|
<el-button @click="ratingDialog = false" :disabled="ratingPosting">Cancel</el-button>
|
||||||
<el-button type="primary" @click="submitRating()" :disabled="ratingPosting">
|
<el-button type="primary" @click="submitRating()" :disabled="canSubmit">
|
||||||
{{course.rated ? 'Update' : 'Submit'}}
|
{{course.rated ? 'Update' : 'Submit'}}
|
||||||
</el-button>
|
</el-button>
|
||||||
</span>
|
</span>
|
||||||
@@ -100,6 +100,11 @@
|
|||||||
ratingPosting = false;
|
ratingPosting = false;
|
||||||
rating = this.course.rating;
|
rating = this.course.rating;
|
||||||
|
|
||||||
|
get canSubmit()
|
||||||
|
{
|
||||||
|
return this.ratingPosting || App.instance.demoMode
|
||||||
|
}
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Redirect to the course page
|
* Redirect to the course page
|
||||||
*/
|
*/
|
||||||
|
|||||||
Reference in New Issue
Block a user