Yoshie Muranaka | 7bc85e4 | 2021-02-11 09:59:13 -0800 | [diff] [blame] | 1 | <template> |
| 2 | <b-modal |
| 3 | id="modal-update-firmware" |
| 4 | :title="$t('pageFirmware.singleFileUpload.sectionTitleUpdateFirmware')" |
| 5 | :ok-title=" |
| 6 | $t('pageFirmware.singleFileUpload.form.updateFirmware.startUpdate') |
| 7 | " |
| 8 | :cancel-title="$t('global.action.cancel')" |
| 9 | @ok="$emit('ok')" |
| 10 | > |
| 11 | <template v-if="isSingleFileUploadEnabled"> |
| 12 | <p> |
| 13 | {{ $t('pageFirmware.singleFileUpload.modal.updateFirmwareInfo') }} |
| 14 | </p> |
| 15 | <p> |
| 16 | {{ |
| 17 | $t('pageFirmware.singleFileUpload.modal.updateFirmwareInfo2', { |
| 18 | running: runningBmcVersion, |
| 19 | }) |
| 20 | }} |
| 21 | </p> |
| 22 | <p class="m-0"> |
| 23 | {{ $t('pageFirmware.singleFileUpload.modal.updateFirmwareInfo3') }} |
| 24 | </p> |
| 25 | </template> |
| 26 | <template v-else> |
| 27 | {{ $t('pageFirmware.singleFileUpload.modal.updateFirmwareInfoDefault') }} |
| 28 | </template> |
| 29 | </b-modal> |
| 30 | </template> |
| 31 | |
| 32 | <script> |
| 33 | export default { |
| 34 | computed: { |
| 35 | runningBmc() { |
| 36 | return this.$store.getters['firmwareSingleImage/activeBmcFirmware']; |
| 37 | }, |
| 38 | runningBmcVersion() { |
| 39 | return this.runningBmc?.version || '--'; |
| 40 | }, |
| 41 | isSingleFileUploadEnabled() { |
| 42 | return this.$store.getters[ |
| 43 | 'firmwareSingleImage/isSingleFileUploadEnabled' |
| 44 | ]; |
| 45 | }, |
| 46 | }, |
| 47 | }; |
| 48 | </script> |