mirror of https://github.com/certd/certd
chore: 1
parent
8b9c47daf1
commit
aafa5d5f90
|
@ -23,7 +23,6 @@ services:
|
|||
# # ↓↓↓↓ --------------------------------------------------------- 如果你服务器部署在国外,可以用这个替换上面阿里云的公共dns
|
||||
# - 8.8.8.8 # 谷歌公共dns
|
||||
# - 8.8.4.4
|
||||
|
||||
# extra_hosts:
|
||||
# # ↓↓↓↓ -------------------------------------------------------- 这里可以配置自定义hosts,外网域名可以指向本地局域网ip地址
|
||||
# - "localdomain.comm:192.168.1.3"
|
||||
|
|
|
@ -26,10 +26,10 @@
|
|||
"dependencies": {
|
||||
"@ant-design/colors": "^7.0.2",
|
||||
"@ant-design/icons-vue": "^6.1.0",
|
||||
"@fast-crud/fast-crud": "^1.23.1",
|
||||
"@fast-crud/fast-extends": "^1.23.1",
|
||||
"@fast-crud/ui-antdv4": "^1.23.1",
|
||||
"@fast-crud/ui-interface": "^1.23.1",
|
||||
"@fast-crud/fast-crud": "^1.23.4",
|
||||
"@fast-crud/fast-extends": "^1.23.4",
|
||||
"@fast-crud/ui-antdv4": "^1.23.4",
|
||||
"@fast-crud/ui-interface": "^1.23.4",
|
||||
"@iconify/vue": "^4.1.1",
|
||||
"@soerenmartius/vue3-clipboard": "^0.1.2",
|
||||
"@vue-js-cron/light": "^4.0.5",
|
||||
|
|
|
@ -6,11 +6,14 @@ import { Modal } from "ant-design-vue";
|
|||
import * as api from "/@/views/sys/cname/provider/api";
|
||||
import { mitter } from "/@/utils/util.mitt";
|
||||
|
||||
export function getCommonColumnDefine(crudExpose: any, typeRef: any, api: any) {
|
||||
export function notificationProvide(api: any) {
|
||||
provide("notificationApi", api);
|
||||
provide("get:plugin:type", () => {
|
||||
return "notification";
|
||||
});
|
||||
}
|
||||
|
||||
export function getCommonColumnDefine(crudExpose: any, typeRef: any, api: any) {
|
||||
const notificationTypeDictRef = dict({
|
||||
url: "/pi/notification/getTypeDict"
|
||||
});
|
||||
|
|
|
@ -15,11 +15,13 @@ import { defineComponent, onActivated, onMounted } from "vue";
|
|||
import { useFs } from "@fast-crud/fast-crud";
|
||||
import createCrudOptions from "./crud";
|
||||
import { createNotificationApi } from "./api";
|
||||
import { notificationProvide } from "/@/views/certd/notification/common";
|
||||
|
||||
export default defineComponent({
|
||||
name: "NotificationManager",
|
||||
setup() {
|
||||
const api = createNotificationApi();
|
||||
notificationProvide(api);
|
||||
const { crudBinding, crudRef, crudExpose } = useFs({ createCrudOptions, context: { api } });
|
||||
|
||||
// 页面打开后获取列表数据
|
||||
|
|
|
@ -29,7 +29,9 @@
|
|||
:show-select="false"
|
||||
:dialog="{ width: 960 }"
|
||||
:destroy-on-close="false"
|
||||
height="400px"
|
||||
@update:model-value="onChange"
|
||||
@dialog-closed="doRefresh"
|
||||
>
|
||||
<template #default="scope">
|
||||
<fs-button class="ml-5" :disabled="disabled" :size="size" type="primary" icon="ant-design:edit-outlined" @click="scope.open"></fs-button>
|
||||
|
@ -45,6 +47,7 @@ import { createNotificationApi } from "../api";
|
|||
import { message } from "ant-design-vue";
|
||||
import { dict } from "@fast-crud/fast-crud";
|
||||
import createCrudOptions from "../crud";
|
||||
import { notificationProvide } from "/@/views/certd/notification/common";
|
||||
|
||||
defineOptions({
|
||||
name: "NotificationSelector"
|
||||
|
@ -65,7 +68,7 @@ const onChange = async (value: number) => {
|
|||
const emit = defineEmits(["update:modelValue", "selectedChange", "change"]);
|
||||
|
||||
const api = createNotificationApi();
|
||||
|
||||
notificationProvide(api);
|
||||
// const types = ref({});
|
||||
// async function loadNotificationTypes() {
|
||||
// const types = await api.GetDefineTypes();
|
||||
|
@ -148,6 +151,10 @@ watch(
|
|||
|
||||
//当不在pipeline中编辑时,可能为空
|
||||
const pipeline = inject("pipeline", null);
|
||||
|
||||
async function doRefresh() {
|
||||
await optionsDictRef.reloadDict();
|
||||
}
|
||||
</script>
|
||||
<style lang="less">
|
||||
.notification-selector {
|
||||
|
|
|
@ -4,6 +4,7 @@ import _, { merge } from "lodash-es";
|
|||
import { useUserStore } from "/@/store/modules/user";
|
||||
import { useSettingStore } from "/@/store/modules/settings";
|
||||
import * as api from "../api.plugin";
|
||||
import NotificationSelector from "/@/views/certd/notification/notification-selector/index.vue";
|
||||
|
||||
export default function (certPlugins: any[], formWrapperRef: any): CreateCrudOptionsRet {
|
||||
const inputs: any = {};
|
||||
|
@ -106,13 +107,13 @@ export default function (certPlugins: any[], formWrapperRef: any): CreateCrudOpt
|
|||
title: "失败通知",
|
||||
type: "text",
|
||||
form: {
|
||||
value: true,
|
||||
value: 0,
|
||||
component: {
|
||||
name: "a-switch",
|
||||
vModel: "checked"
|
||||
name: NotificationSelector,
|
||||
vModel: "modelValue"
|
||||
},
|
||||
order: 101,
|
||||
helper: "建议设置,任务执行失败实时提醒"
|
||||
helper: "任务执行失败实时提醒"
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
|
@ -71,7 +71,7 @@ const development = {
|
|||
type: 'better-sqlite3',
|
||||
database: './data/db.sqlite',
|
||||
synchronize: false, // 如果第一次使用,不存在表,有同步的需求可以写 true
|
||||
logging: false,
|
||||
logging: true,
|
||||
|
||||
// 配置实体模型 或者 entities: '/entity',
|
||||
entities: ['**/modules/**/entity/*.js', ...libServerEntities, ...commercialEntities, PipelineEntity, FlywayHistory, UserEntity],
|
||||
|
|
Loading…
Reference in New Issue