mirror of
https://github.com/fofolee/uTools-quickcommand.git
synced 2025-06-18 12:36:58 +08:00
36 lines
900 B
Vue
36 lines
900 B
Vue
<template>
|
|
<component :is="currentComponent" :ref="currentComponent" />
|
|
</template>
|
|
|
|
<script>
|
|
import PluginNickName from "components/quickFeatures/PluginNickName";
|
|
import FavFile from "components/quickFeatures/FavFile";
|
|
import FavUrl from "components/quickFeatures/FavUrl";
|
|
import { markRaw } from "vue";
|
|
|
|
export default {
|
|
components: {
|
|
pluNickName: markRaw(PluginNickName),
|
|
favFile: markRaw(FavFile),
|
|
favUrl: markRaw(FavUrl),
|
|
},
|
|
data() {
|
|
return {
|
|
currentComponent: this.$route.params.featuretype,
|
|
};
|
|
},
|
|
methods: {
|
|
importCommand(command) {
|
|
command = _.cloneDeep(command);
|
|
this.$root.utools.putDB(command, "qc_" + command.features.code);
|
|
this.$root.utools.whole.setFeature(command.features);
|
|
},
|
|
getUid() {
|
|
return Number(
|
|
Math.random().toString().substr(3, 3) + Date.now()
|
|
).toString(36);
|
|
},
|
|
},
|
|
};
|
|
</script>
|