mirror of
https://github.com/TeaOSLab/EdgeAdmin.git
synced 2025-11-06 06:40:27 +08:00
多处增加是否独立配置选项
This commit is contained in:
25
web/public/js/components/server/prior-checkbox.js
Normal file
25
web/public/js/components/server/prior-checkbox.js
Normal file
@@ -0,0 +1,25 @@
|
||||
Vue.component("prior-checkbox", {
|
||||
props: ["v-config"],
|
||||
data: function () {
|
||||
return {
|
||||
isPrior: this.vConfig.isPrior
|
||||
}
|
||||
},
|
||||
watch: {
|
||||
isPrior: function (v) {
|
||||
this.vConfig.isPrior = v
|
||||
}
|
||||
},
|
||||
template: `<tbody>
|
||||
<tr :class="{active:isPrior}">
|
||||
<td class="title">打开独立配置</td>
|
||||
<td>
|
||||
<div class="ui toggle checkbox">
|
||||
<input type="checkbox" v-model="isPrior"/>
|
||||
<label class="red"></label>
|
||||
</div>
|
||||
<p class="comment"><strong v-if="isPrior">[已打开]</strong> 打开后可以覆盖父级配置。</p>
|
||||
</td>
|
||||
</tr>
|
||||
</tbody>`
|
||||
})
|
||||
Reference in New Issue
Block a user