修改前端导入规范.
This commit is contained in:
@@ -124,13 +124,14 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<script setup lang="ts">
|
||||
<script lang="ts" setup>
|
||||
import type { HostIdentityQueryRequest, HostIdentityQueryResponse } from '@/api/asset/host-identity';
|
||||
import { usePagination, useColLayout } from '@/types/card';
|
||||
import { computed, reactive, ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { objectTruthKeyCount, resetObject } from '@/utils';
|
||||
import fieldConfig from '../types/card.fields';
|
||||
import { deleteHostIdentity, getHostIdentityPage, HostIdentityQueryRequest, HostIdentityQueryResponse } from '@/api/asset/host-identity';
|
||||
import { deleteHostIdentity, getHostIdentityPage } from '@/api/asset/host-identity';
|
||||
import { Message, Modal } from '@arco-design/web-vue';
|
||||
import usePermission from '@/hooks/permission';
|
||||
import useCopy from '@/hooks/copy';
|
||||
@@ -225,6 +226,6 @@
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
|
||||
</style>
|
||||
|
||||
@@ -61,12 +61,14 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostIdentityUpdateRequest } from '@/api/asset/host-identity';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createHostIdentity, updateHostIdentity, HostIdentityUpdateRequest } from '@/api/asset/host-identity';
|
||||
import { FieldRule, Message } from '@arco-design/web-vue';
|
||||
import { createHostIdentity, updateHostIdentity } from '@/api/asset/host-identity';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import HostKeySelector from '@/components/asset/host-key/host-key-selector.vue';
|
||||
|
||||
const { visible, setVisible } = useVisible();
|
||||
|
||||
@@ -125,8 +125,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostIdentityQueryRequest, HostIdentityQueryResponse } from '@/api/asset/host-identity';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { deleteHostIdentity, getHostIdentityPage, HostIdentityQueryRequest, HostIdentityQueryResponse } from '@/api/asset/host-identity';
|
||||
import { deleteHostIdentity, getHostIdentityPage } from '@/api/asset/host-identity';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { CardField, CardFieldConfig } from '@/types/card';
|
||||
import type { CardField, CardFieldConfig } from '@/types/card';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const fieldConfig = {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const name = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const columns = [
|
||||
|
||||
@@ -78,13 +78,14 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<script setup lang="ts">
|
||||
<script lang="ts" setup>
|
||||
import type { HostKeyQueryRequest, HostKeyQueryResponse } from '@/api/asset/host-key';
|
||||
import { usePagination, useColLayout } from '@/types/card';
|
||||
import { reactive, ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { resetObject } from '@/utils';
|
||||
import fieldConfig from '../types/card.fields';
|
||||
import { deleteHostKey, getHostKeyPage, HostKeyQueryRequest, HostKeyQueryResponse } from '@/api/asset/host-key';
|
||||
import { deleteHostKey, getHostKeyPage } from '@/api/asset/host-key';
|
||||
import { Message, Modal } from '@arco-design/web-vue';
|
||||
|
||||
const { loading, setLoading } = useLoading();
|
||||
@@ -163,6 +164,6 @@
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
|
||||
</style>
|
||||
|
||||
@@ -89,12 +89,14 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostKeyUpdateRequest } from '@/api/asset/host-key';
|
||||
import type { FieldRule, FileItem } from '@arco-design/web-vue';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createHostKey, updateHostKey, getHostKey, HostKeyUpdateRequest } from '@/api/asset/host-key';
|
||||
import { FieldRule, FileItem, Message } from '@arco-design/web-vue';
|
||||
import { createHostKey, updateHostKey, getHostKey } from '@/api/asset/host-key';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { readFileText } from '@/utils/file';
|
||||
|
||||
const { visible, setVisible } = useVisible();
|
||||
|
||||
@@ -98,8 +98,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostKeyQueryRequest, HostKeyQueryResponse } from '@/api/asset/host-key';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { deleteHostKey, getHostKeyPage, HostKeyQueryRequest, HostKeyQueryResponse } from '@/api/asset/host-key';
|
||||
import { deleteHostKey, getHostKeyPage } from '@/api/asset/host-key';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { CardField, CardFieldConfig } from '@/types/card';
|
||||
import type { CardField, CardFieldConfig } from '@/types/card';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const fieldConfig = {
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const name = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const columns = [
|
||||
|
||||
@@ -141,13 +141,14 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<script setup lang="ts">
|
||||
<script lang="ts" setup>
|
||||
import type { HostQueryRequest, HostQueryResponse } from '@/api/asset/host';
|
||||
import { usePagination, useColLayout } from '@/types/card';
|
||||
import { computed, reactive, ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { dataColor, objectTruthKeyCount, resetObject } from '@/utils';
|
||||
import fieldConfig from '../types/host.card.fields';
|
||||
import { deleteHost, getHostPage, HostQueryRequest, HostQueryResponse } from '@/api/asset/host';
|
||||
import { deleteHost, getHostPage } from '@/api/asset/host';
|
||||
import { Message, Modal } from '@arco-design/web-vue';
|
||||
import { tagColor } from '@/views/asset/host/types/const';
|
||||
import TagMultiSelector from '@/components/meta/tag/tag-multi-selector.vue';
|
||||
@@ -243,7 +244,7 @@
|
||||
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.host-address {
|
||||
cursor: pointer;
|
||||
color: rgb(var(--arcoblue-6))
|
||||
|
||||
@@ -138,14 +138,16 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
import type { HostSshConfig } from '@/views/asset/host/types/host-config.types';
|
||||
import { ref, watch } from 'vue';
|
||||
import { updateHostConfigStatus, updateHostConfig } from '@/api/asset/host';
|
||||
import { HostSshConfig, AuthTypeEnum } from '@/views/asset/host/types/host-config.types';
|
||||
import { AuthTypeEnum } from '@/views/asset/host/types/host-config.types';
|
||||
import { sshRules } from '@/views/asset/host/types/host-config.form.rules';
|
||||
import HostKeySelector from '@/components/asset/host-key/host-key-selector.vue';
|
||||
import HostIdentitySelector from '@/components/asset/host-identity/host-identity-selector.vue';
|
||||
import { toOptions } from '@/utils/enum';
|
||||
import { FieldRule, Message } from '@arco-design/web-vue';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
|
||||
const { loading, setLoading } = useLoading();
|
||||
|
||||
@@ -53,11 +53,12 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostUpdateRequest } from '@/api/asset/host';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/host.form.rules';
|
||||
import { createHost, updateHost, HostUpdateRequest } from '@/api/asset/host';
|
||||
import { createHost, updateHost } from '@/api/asset/host';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import TagMultiSelector from '@/components/meta/tag/tag-multi-selector.vue';
|
||||
|
||||
|
||||
@@ -163,8 +163,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { HostQueryRequest, HostQueryResponse } from '@/api/asset/host';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { deleteHost, getHostPage, HostQueryRequest, HostQueryResponse } from '@/api/asset/host';
|
||||
import { deleteHost, getHostPage } from '@/api/asset/host';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/host.table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const port = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { CardField, CardFieldConfig } from '@/types/card';
|
||||
import type { CardField, CardFieldConfig } from '@/types/card';
|
||||
|
||||
const fieldConfig = {
|
||||
rowGap: '10px',
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const name = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
|
||||
const columns = [
|
||||
{
|
||||
|
||||
@@ -50,14 +50,14 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { ValidatedError } from '@arco-design/web-vue/es/form/interface';
|
||||
import type { LoginRequest } from '@/api/user/auth';
|
||||
import { ref, reactive } from 'vue';
|
||||
import { useRouter } from 'vue-router';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { ValidatedError } from '@arco-design/web-vue/es/form/interface';
|
||||
import { useI18n } from 'vue-i18n';
|
||||
import { useUserStore } from '@/store';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import type { LoginRequest } from '@/api/user/auth';
|
||||
|
||||
const router = useRouter();
|
||||
const { t } = useI18n();
|
||||
|
||||
@@ -13,4 +13,5 @@
|
||||
router.replace({ path: gotoPath });
|
||||
</script>
|
||||
|
||||
<style scoped lang="less"></style>
|
||||
<style lang="less" scoped>
|
||||
</style>
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.content {
|
||||
// padding-top: 100px;
|
||||
position: absolute;
|
||||
|
||||
@@ -31,7 +31,7 @@
|
||||
};
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.content {
|
||||
// padding-top: 100px;
|
||||
position: absolute;
|
||||
|
||||
@@ -49,13 +49,14 @@
|
||||
];
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.item {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
width: 100%;
|
||||
height: 24px;
|
||||
margin-bottom: 4px;
|
||||
|
||||
.item-content {
|
||||
flex: 1;
|
||||
overflow: hidden;
|
||||
|
||||
@@ -21,7 +21,7 @@
|
||||
});
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.banner {
|
||||
width: 100%;
|
||||
padding: 20px 20px 0 20px;
|
||||
|
||||
@@ -111,4 +111,5 @@
|
||||
});
|
||||
</script>
|
||||
|
||||
<style scoped lang="less"></style>
|
||||
<style lang="less" scoped>
|
||||
</style>
|
||||
|
||||
@@ -17,13 +17,14 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { ToolTipFormatterParams } from '@/types/echarts';
|
||||
import type { AnyObject } from '@/types/global';
|
||||
import type { ContentDataRecord } from '@/api/dashboard';
|
||||
import { ref } from 'vue';
|
||||
import { graphic } from 'echarts';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { queryContentData, ContentDataRecord } from '@/api/dashboard';
|
||||
import { queryContentData } from '@/api/dashboard';
|
||||
import useChartOption from '@/hooks/chart-option';
|
||||
import { ToolTipFormatterParams } from '@/types/echarts';
|
||||
import { AnyObject } from '@/types/global';
|
||||
|
||||
function graphicFactory(side: AnyObject) {
|
||||
return {
|
||||
@@ -38,6 +39,7 @@
|
||||
},
|
||||
};
|
||||
}
|
||||
|
||||
const { loading, setLoading } = useLoading(true);
|
||||
const xAxis = ref<string[]>([]);
|
||||
const chartsData = ref<number[]>([]);
|
||||
@@ -117,8 +119,8 @@
|
||||
return `<div>
|
||||
<p class="tooltip-title">${firstElement.axisValueLabel}</p>
|
||||
<div class="content-panel"><span>总内容量</span><span class="tooltip-value">${(
|
||||
Number(firstElement.value) * 10000
|
||||
).toLocaleString()}</span></div>
|
||||
Number(firstElement.value) * 10000
|
||||
).toLocaleString()}</span></div>
|
||||
</div>`;
|
||||
},
|
||||
className: 'echarts-tooltip-diy',
|
||||
@@ -197,4 +199,5 @@
|
||||
fetchData();
|
||||
</script>
|
||||
|
||||
<style scoped lang="less"></style>
|
||||
<style lang="less" scoped>
|
||||
</style>
|
||||
|
||||
@@ -90,9 +90,10 @@
|
||||
:value="2.8"
|
||||
:precision="1"
|
||||
:value-from="0"
|
||||
animation
|
||||
>
|
||||
<template #suffix> % <icon-caret-up class="up-icon" /> </template>
|
||||
animation>
|
||||
<template #suffix> %
|
||||
<icon-caret-up class="up-icon" />
|
||||
</template>
|
||||
</a-statistic>
|
||||
</a-space>
|
||||
</a-grid-item>
|
||||
@@ -102,29 +103,35 @@
|
||||
</a-grid>
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup></script>
|
||||
<script lang="ts" setup>
|
||||
</script>
|
||||
|
||||
<style lang="less" scoped>
|
||||
.arco-grid.panel {
|
||||
margin-bottom: 0;
|
||||
padding: 16px 20px 0 20px;
|
||||
}
|
||||
|
||||
.panel-col {
|
||||
padding-left: 43px;
|
||||
border-right: 1px solid rgb(var(--gray-2));
|
||||
}
|
||||
|
||||
.col-avatar {
|
||||
margin-right: 12px;
|
||||
background-color: var(--color-fill-2);
|
||||
}
|
||||
|
||||
.up-icon {
|
||||
color: rgb(var(--red-6));
|
||||
}
|
||||
|
||||
.unit {
|
||||
margin-left: 8px;
|
||||
color: rgb(var(--gray-8));
|
||||
font-size: 12px;
|
||||
}
|
||||
|
||||
:deep(.panel-border) {
|
||||
margin: 4px 0 0 0;
|
||||
}
|
||||
|
||||
@@ -73,10 +73,10 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { TableData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { queryPopularList } from '@/api/dashboard';
|
||||
import type { TableData } from '@arco-design/web-vue/es/table/interface';
|
||||
|
||||
const type = ref('text');
|
||||
const { loading, setLoading } = useLoading();
|
||||
@@ -98,19 +98,23 @@
|
||||
fetchData('text');
|
||||
</script>
|
||||
|
||||
<style scoped lang="less">
|
||||
<style lang="less" scoped>
|
||||
.general-card {
|
||||
min-height: 395px;
|
||||
}
|
||||
|
||||
:deep(.arco-table-tr) {
|
||||
height: 44px;
|
||||
|
||||
.arco-typography {
|
||||
margin-bottom: 0;
|
||||
}
|
||||
}
|
||||
|
||||
.increases-cell {
|
||||
display: flex;
|
||||
align-items: center;
|
||||
|
||||
span {
|
||||
margin-right: 4px;
|
||||
}
|
||||
|
||||
@@ -32,4 +32,5 @@
|
||||
];
|
||||
</script>
|
||||
|
||||
<style scoped lang="less"></style>
|
||||
<style lang="less" scoped>
|
||||
</style>
|
||||
|
||||
@@ -1,7 +1,7 @@
|
||||
import type { GetParams } from '@/types/global';
|
||||
import Mock from 'mockjs';
|
||||
import qs from 'query-string';
|
||||
import dayjs from 'dayjs';
|
||||
import { GetParams } from '@/types/global';
|
||||
import setupMock, { successResponseWrap } from '@/utils/setup-mock';
|
||||
|
||||
const textList = [
|
||||
|
||||
@@ -92,13 +92,15 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { DictKeyUpdateRequest } from '@/api/system/dict-key';
|
||||
import type { ExtraParamType } from '../types/const';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createDictKey, updateDictKey, DictKeyUpdateRequest } from '@/api/system/dict-key';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { definedExtraKeys, innerKeys, ExtraParamType } from '../types/const';
|
||||
import { createDictKey, updateDictKey } from '@/api/system/dict-key';
|
||||
import { definedExtraKeys, innerKeys } from '../types/const';
|
||||
import { ValueTypeEnum } from '../types/enum.types';
|
||||
import { toOptions } from '@/utils/enum';
|
||||
|
||||
|
||||
@@ -55,7 +55,7 @@
|
||||
:bordered="false">
|
||||
<!-- 配置值类型 -->
|
||||
<template #valueType="{ record }">
|
||||
<a-tag :color="getEnumValue(record.valueType, ValueTypeEnum,'color')">
|
||||
<a-tag :color="getEnumValue(record.valueType, ValueTypeEnum, 'color')">
|
||||
{{ getEnumValue(record.valueType, ValueTypeEnum) }}
|
||||
</a-tag>
|
||||
</template>
|
||||
@@ -64,7 +64,7 @@
|
||||
<template v-if="record.extraSchema">
|
||||
<a-space>
|
||||
<template v-for="item in JSON.parse(record.extraSchema)" :key="item.name">
|
||||
<a-tag :color="getEnumValue(item.type, ValueTypeEnum,'color')">
|
||||
<a-tag :color="getEnumValue(item.type, ValueTypeEnum, 'color')">
|
||||
{{ item.name }}
|
||||
</a-tag>
|
||||
</template>
|
||||
@@ -115,8 +115,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { DictKeyQueryRequest, DictKeyQueryResponse } from '@/api/system/dict-key';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { batchDeleteDictKey, deleteDictKey, getDictKeyPage, DictKeyQueryRequest, DictKeyQueryResponse } from '@/api/system/dict-key';
|
||||
import { batchDeleteDictKey, deleteDictKey, getDictKeyPage } from '@/api/system/dict-key';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const keyName = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
|
||||
const columns = [
|
||||
{
|
||||
|
||||
@@ -88,11 +88,12 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { DictValueUpdateRequest } from '@/api/system/dict-value';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createDictValue, updateDictValue, DictValueUpdateRequest } from '@/api/system/dict-value';
|
||||
import { createDictValue, updateDictValue } from '@/api/system/dict-value';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { ExtraParamType, innerKeys } from '../../dict-key/types/const';
|
||||
import { ValueTypeEnum } from '../../dict-key/types/enum.types';
|
||||
|
||||
@@ -134,15 +134,13 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { DictValueQueryRequest, DictValueQueryResponse } from '@/api/system/dict-value';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { batchDeleteDictValue, deleteDictValue, getDictValuePage, DictValueQueryRequest, DictValueQueryResponse } from '@/api/system/dict-value';
|
||||
import { batchDeleteDictValue, deleteDictValue, getDictValuePage } from '@/api/system/dict-value';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
import { usePagination, useRowSelection } from '@/types/table';
|
||||
import {} from '../types/const';
|
||||
import {} from '../types/enum.types';
|
||||
import { toOptions, getEnumValue } from '@/utils/enum';
|
||||
import useCopy from '@/hooks/copy';
|
||||
import DictKeySelector from '@/components/system/dict-key/dict-key-selector.vue';
|
||||
|
||||
|
||||
@@ -24,7 +24,6 @@
|
||||
import { onUnmounted, ref } from 'vue';
|
||||
import { useCacheStore } from '@/store';
|
||||
import { getDictKeyList } from '@/api/system/dict-key';
|
||||
import { getTagList } from '@/api/meta/tag';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
|
||||
const table = ref();
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const keyId = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const columns = [
|
||||
|
||||
@@ -118,7 +118,8 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { reactive, ref, watch } from 'vue';
|
||||
import type { MenuUpdateRequest } from '@/api/system/menu';
|
||||
import { ref, watch } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
@@ -127,7 +128,7 @@
|
||||
import { toOptions } from '@/utils/enum';
|
||||
import IconPicker from '@sanqi377/arco-vue-icon-picker';
|
||||
import MenuTreeSelector from './menu-tree-selector.vue';
|
||||
import { createMenu, updateMenu, MenuUpdateRequest } from '@/api/system/menu';
|
||||
import { createMenu, updateMenu } from '@/api/system/menu';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
|
||||
const { visible, setVisible } = useVisible();
|
||||
|
||||
@@ -111,12 +111,12 @@
|
||||
:content="`确定要将当前节点以及所有子节点改为${toggleEnumValue(record.status, MenuStatusEnum, 'label')}?`"
|
||||
@ok="updateStatus(record.id, toggleEnumValue(record.status, MenuStatusEnum))">
|
||||
<a-tooltip content="点击切换状态">
|
||||
<a-tag :color="getEnumValue(record.status, MenuStatusEnum,'color')" class="pointer">
|
||||
<a-tag :color="getEnumValue(record.status, MenuStatusEnum, 'color')" class="pointer">
|
||||
{{ getEnumValue(record.status, MenuStatusEnum) }}
|
||||
</a-tag>
|
||||
</a-tooltip>
|
||||
</a-popconfirm>
|
||||
<a-tag v-else :color="getEnumValue(record.status, MenuStatusEnum,'color')">
|
||||
<a-tag v-else :color="getEnumValue(record.status, MenuStatusEnum, 'color')">
|
||||
{{ getEnumValue(record.status, MenuStatusEnum) }}
|
||||
</a-tag>
|
||||
<!-- 显示状态 -->
|
||||
@@ -127,14 +127,14 @@
|
||||
@ok="updateVisible(record.id, toggleEnumValue(record.visible, MenuVisibleEnum))">
|
||||
<a-tooltip content="点击切换状态">
|
||||
<a-tag v-if="(record.visible || record.visible === 0) && record.type !== MenuTypeEnum.FUNCTION.value"
|
||||
:color="getEnumValue(record.visible, MenuVisibleEnum,'color')"
|
||||
:color="getEnumValue(record.visible, MenuVisibleEnum, 'color')"
|
||||
class="pointer">
|
||||
{{ getEnumValue(record.visible, MenuVisibleEnum) }}
|
||||
</a-tag>
|
||||
</a-tooltip>
|
||||
</a-popconfirm>
|
||||
<a-tag v-else-if="(record.visible || record.visible === 0) && record.type !== MenuTypeEnum.FUNCTION.value"
|
||||
:color="getEnumValue(record.visible, MenuVisibleEnum,'color')">
|
||||
:color="getEnumValue(record.visible, MenuVisibleEnum, 'color')">
|
||||
{{ getEnumValue(record.visible, MenuVisibleEnum) }}
|
||||
</a-tag>
|
||||
</a-space>
|
||||
@@ -181,9 +181,10 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import { reactive, ref, onUnmounted } from 'vue';
|
||||
import type { MenuQueryRequest, MenuQueryResponse } from '@/api/system/menu';
|
||||
import { reactive, ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { getMenuList, deleteMenu, updateMenuStatus, initCache, MenuQueryRequest, MenuQueryResponse } from '@/api/system/menu';
|
||||
import { getMenuList, deleteMenu, updateMenuStatus, initCache } from '@/api/system/menu';
|
||||
import { toOptions, getEnumValue, toggleEnumValue } from '@/utils/enum';
|
||||
import { MenuStatusEnum, MenuVisibleEnum, MenuTypeEnum } from '../types/enum.types';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -14,9 +14,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { TreeNodeData } from '@arco-design/web-vue';
|
||||
import { useCacheStore } from '@/store';
|
||||
import { computed } from 'vue';
|
||||
import { TreeNodeData } from '@arco-design/web-vue';
|
||||
|
||||
const props = defineProps({
|
||||
modelValue: Number,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const parentId = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
|
||||
const columns = [
|
||||
{
|
||||
|
||||
@@ -36,9 +36,9 @@
|
||||
</template>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { UserUpdateRequest } from '@/api/user/user';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import { ref } from 'vue';
|
||||
import { UserUpdateRequest } from '@/api/user/user';
|
||||
import formRules from '../user/types/form.rules';
|
||||
|
||||
const { loading, setLoading } = useLoading();
|
||||
|
||||
@@ -40,11 +40,12 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { RoleUpdateRequest } from '@/api/user/role';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createRole, updateRole, RoleUpdateRequest, } from '@/api/user/role';
|
||||
import { createRole, updateRole } from '@/api/user/role';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
|
||||
const { visible, setVisible } = useVisible();
|
||||
|
||||
@@ -43,10 +43,11 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { RoleGrantMenuRequest, RoleQueryResponse } from '@/api/user/role';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import { getRoleMenuId, grantRoleMenu, RoleGrantMenuRequest, RoleQueryResponse } from '@/api/user/role';
|
||||
import { getRoleMenuId, grantRoleMenu } from '@/api/user/role';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { useCacheStore } from '@/store';
|
||||
import { getMenuList } from '@/api/system/menu';
|
||||
|
||||
@@ -67,7 +67,7 @@
|
||||
<!-- 状态 -->
|
||||
<template #status="{ record }">
|
||||
<span class="circle" :style="{
|
||||
background: getEnumValue(record.status, RoleStatusEnum,'color')
|
||||
background: getEnumValue(record.status, RoleStatusEnum, 'color')
|
||||
}" />
|
||||
{{ getEnumValue(record.status, RoleStatusEnum) }}
|
||||
</template>
|
||||
@@ -128,8 +128,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { RoleQueryRequest, RoleQueryResponse } from '@/api/user/role';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { deleteRole, getRolePage, updateRoleStatus, RoleQueryRequest, RoleQueryResponse } from '@/api/user/role';
|
||||
import { deleteRole, getRolePage, updateRoleStatus } from '@/api/user/role';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const name = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const columns = [
|
||||
|
||||
@@ -54,11 +54,12 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { UserUpdateRequest } from '@/api/user/user';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import formRules from '../types/form.rules';
|
||||
import { createUser, updateUser, UserUpdateRequest } from '@/api/user/user';
|
||||
import { createUser, updateUser } from '@/api/user/user';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { md5 } from '@/utils';
|
||||
|
||||
|
||||
@@ -45,6 +45,7 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { UserQueryResponse, UserUpdateRequest } from '@/api/user/user';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
@@ -52,7 +53,7 @@
|
||||
import UserRoleSelector from '@/components/user/role/user-role-selector.vue';
|
||||
import { getRoleList } from '@/api/user/role';
|
||||
import { useCacheStore } from '@/store';
|
||||
import { getUserRoleIdList, grantUserRole, UserQueryResponse, UserUpdateRequest } from '@/api/user/user';
|
||||
import { getUserRoleIdList, grantUserRole } from '@/api/user/user';
|
||||
|
||||
const { visible, setVisible } = useVisible();
|
||||
const { loading: saveLoading, setLoading: setSaveLoading } = useLoading();
|
||||
|
||||
@@ -43,11 +43,12 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { UserQueryResponse, UserUpdateRequest } from '@/api/user/user';
|
||||
import { ref } from 'vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import useVisible from '@/hooks/visible';
|
||||
import { password } from '../types/form.rules';
|
||||
import { resetUserPassword, UserQueryResponse, UserUpdateRequest } from '@/api/user/user';
|
||||
import { resetUserPassword } from '@/api/user/user';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import { md5 } from '@/utils';
|
||||
|
||||
|
||||
@@ -78,7 +78,7 @@
|
||||
<!-- 状态 -->
|
||||
<template #status="{ record }">
|
||||
<span class="circle" :style="{
|
||||
background: getEnumValue(record.status, UserStatusEnum,'color')
|
||||
background: getEnumValue(record.status, UserStatusEnum, 'color')
|
||||
}" />
|
||||
{{ getEnumValue(record.status, UserStatusEnum) }}
|
||||
</template>
|
||||
@@ -150,8 +150,9 @@
|
||||
</script>
|
||||
|
||||
<script lang="ts" setup>
|
||||
import type { UserQueryRequest, UserQueryResponse } from '@/api/user/user';
|
||||
import { reactive, ref } from 'vue';
|
||||
import { deleteUser, getUserPage, updateUserStatus, UserQueryRequest, UserQueryResponse } from '@/api/user/user';
|
||||
import { deleteUser, getUserPage, updateUserStatus } from '@/api/user/user';
|
||||
import { Message } from '@arco-design/web-vue';
|
||||
import useLoading from '@/hooks/loading';
|
||||
import columns from '../types/table.columns';
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { FieldRule } from '@arco-design/web-vue';
|
||||
import type { FieldRule } from '@arco-design/web-vue';
|
||||
|
||||
export const username = [{
|
||||
required: true,
|
||||
|
||||
@@ -1,4 +1,4 @@
|
||||
import { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import type { TableColumnData } from '@arco-design/web-vue/es/table/interface';
|
||||
import { dateFormat } from '@/utils';
|
||||
|
||||
const columns = [
|
||||
|
||||
Reference in New Issue
Block a user