mirror of
https://github.com/scinote-eln/scinote-web.git
synced 2024-09-20 06:35:56 +08:00
Merge pull request #6214 from artoscinote/ma_SCI_9286
Add new step buttons for protocol template, remove bottom new result button [SCI-9286]
This commit is contained in:
commit
31c0ddba7e
|
@ -131,6 +131,17 @@
|
|||
</div>
|
||||
<div class="border-0 border-b border-dashed border-sn-light-grey" v-if="!inRepository"></div>
|
||||
<div id="protocol-steps-container" :class=" inRepository ? 'protocol-steps collapse in' : ''">
|
||||
<div v-if="urls.add_step_url && inRepository" class="py-5">
|
||||
<a
|
||||
class="btn btn-secondary"
|
||||
:title="i18n.t('protocols.steps.new_step_title')"
|
||||
@keyup.enter="addStep(steps.length)"
|
||||
@click="addStep(steps.length)"
|
||||
tabindex="0">
|
||||
<span class="sn-icon sn-icon-new-task" aria-hidden="true"></span>
|
||||
<span>{{ i18n.t("protocols.steps.new_step") }}</span>
|
||||
</a>
|
||||
</div>
|
||||
<div class="protocol-steps">
|
||||
<div v-for="(step, index) in steps" :key="step.id" class="step-block">
|
||||
<div v-if="index > 0 && urls.add_step_url" class="insert-step" @click="addStep(index)">
|
||||
|
@ -153,9 +164,8 @@
|
|||
:assignableMyModuleId="protocol.attributes.assignable_my_module_id"
|
||||
/>
|
||||
</div>
|
||||
<div class="insert-step"></div>
|
||||
<div v-if="steps.length > 0" class="py-5">
|
||||
<a v-if="urls.add_step_url"
|
||||
<div v-if="steps.length > 0 && urls.add_step_url && inRepository" class="py-5">
|
||||
<a
|
||||
class="btn btn-secondary"
|
||||
:title="i18n.t('protocols.steps.new_step_title')"
|
||||
@keyup.enter="addStep(steps.length)"
|
||||
|
|
|
@ -26,12 +26,6 @@
|
|||
@result:restored="removeResult"
|
||||
/>
|
||||
</div>
|
||||
<div v-if="results.length > 0" class="p-3 rounded-md bg-sn-white my-4">
|
||||
<button v-if="canCreate" :title="i18n.t('my_modules.results.add_title')" class="btn btn-secondary" @click="createResult">
|
||||
<i class="sn-icon sn-icon-new-task"></i>
|
||||
{{ i18n.t('my_modules.results.add_label') }}
|
||||
</button>
|
||||
</div>
|
||||
</div>
|
||||
</template>
|
||||
|
||||
|
|
Loading…
Reference in a new issue