- 登录页
+
+
+
+ 正在进入系统中...
+
+
diff --git a/src/views/resources/monitor-manage/index.vue b/src/views/resources/monitor-manage/index.vue
new file mode 100644
index 0000000..dd011de
--- /dev/null
+++ b/src/views/resources/monitor-manage/index.vue
@@ -0,0 +1,17 @@
+
+
+ 河道管理
+
+
+
+
+
diff --git a/src/views/setting/advertising/components/AdvertisingModal.vue b/src/views/setting/advertising/components/AdvertisingModal.vue
new file mode 100644
index 0000000..ccf1e0c
--- /dev/null
+++ b/src/views/setting/advertising/components/AdvertisingModal.vue
@@ -0,0 +1,189 @@
+
+
+
+
+
+
+
+
+
+
+
+
+ {{ cItem.label }}
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
+
diff --git a/src/views/setting/advertising/index.vue b/src/views/setting/advertising/index.vue
index 555d821..d5ca2ed 100644
--- a/src/views/setting/advertising/index.vue
+++ b/src/views/setting/advertising/index.vue
@@ -1,17 +1,72 @@
- 广告管理
+
+
+
+
+ 新建
+
+
+
+
+
diff --git a/src/views/setting/advertising/tools/form.js b/src/views/setting/advertising/tools/form.js
new file mode 100644
index 0000000..7968a1f
--- /dev/null
+++ b/src/views/setting/advertising/tools/form.js
@@ -0,0 +1,57 @@
+import { ref, reactive } from 'vue'
+import { ADVERTISING_TYPE, ADVERTISING_PLATFORM, ADVERTISING_STATUS } from '@/utils/dictionary.js'
+
+export const form = reactive({
+ advertisingForm: {
+ cover: null,
+ title: null,
+ description: null,
+ type: 1,
+ platform: 1,
+ url: null,
+ status: 1,
+ width: null,
+ height: null,
+ startTime: null,
+ endTime: null,
+ sort: null,
+ content: null
+ },
+ advertisingRules: {
+ title: [{ required: true, message: '请输入广告标题', trigger: 'blur' }],
+ sort: [{ required: true, type: 'number', message: '请输入排序号', trigger: 'blur' }]
+ },
+ formItem: [
+ { type: 'oss', refIndex: 0, key: 'imageStatus', file: 'cover', label: '广告图片', props: { maxlength: '20', placeholder: '请输入部门编号', clearable: true }},
+
+ { type: 'input', key: 'title', label: '广告标题', props: { maxlength: '20', placeholder: '请输入广告标题', clearable: true }},
+ { type: 'input', key: 'description', label: '广告描述', props: { maxlength: '20', placeholder: '请输入广告描述', clearable: true }},
+
+ { type: 'select', key: 'type', label: '广告类型', props: { options: ADVERTISING_TYPE, placeholder: '请选择广告类型' }},
+ { type: 'select', key: 'platform', label: '投放平台', props: { options: ADVERTISING_PLATFORM, placeholder: '请选择投放平台' }},
+
+ { type: 'input', key: 'url', label: '广告URL', props: { maxlength: '20', placeholder: '请输入广告URL', clearable: true }},
+ { type: 'radio', key: 'status', label: '广告状态', options: ADVERTISING_STATUS, mode: ['config'] },
+
+ { type: 'number', key: 'width', label: '广告宽度', props: { min: 0, placeholder: '请输入广告宽度', showButton: false, clearable: true }},
+ { type: 'number', key: 'height', label: '广告高度', props: { min: 0, placeholder: '请输入广告高度', showButton: false, clearable: true }},
+
+ { type: 'date', key: 'startTime', label: '开始时间', props: {
+ type: 'datetime',
+ valueFormat: 'yyyy-MM-dd HH:mm:ss', format: 'yyyy-MM-dd HH:mm:ss',
+ actions: ['clear', 'confirm'],
+ timePickerProps: { actions: ['confirm'] }
+ }},
+ { type: 'date', key: 'endTime', label: '结束时间', props: {
+ type: 'datetime',
+ valueFormat: 'yyyy-MM-dd HH:mm:ss', format: 'yyyy-MM-dd HH:mm:ss',
+ actions: ['clear', 'confirm'],
+ timePickerProps: { actions: ['confirm'] }
+ }},
+
+ { type: 'number', key: 'sort', label: '排序号', props: { min: 0, placeholder: '请输入排序号', showButton: false, clearable: true }},
+
+ { type: 'editor', key: 'content', label: '广告内容', props: { height: 300 }}
+ ]
+})
+
diff --git a/src/views/setting/advertising/tools/search.js b/src/views/setting/advertising/tools/search.js
new file mode 100644
index 0000000..3531025
--- /dev/null
+++ b/src/views/setting/advertising/tools/search.js
@@ -0,0 +1,14 @@
+import { reactive } from 'vue'
+
+const data = reactive([
+ {
+ label: '广告名称',
+ key: 'title',
+ props: {
+ placeholder: '请输入广告名称'
+ }
+ }
+])
+
+export default data
+
diff --git a/src/views/setting/advertising/tools/table.js b/src/views/setting/advertising/tools/table.js
new file mode 100644
index 0000000..66cf4a6
--- /dev/null
+++ b/src/views/setting/advertising/tools/table.js
@@ -0,0 +1,237 @@
+import { h, ref, reactive } from 'vue'
+import TableImage from '@/components/DataTable/tools/Image.vue'
+import TableTags from '@/components/DataTable/tools/Tags.vue'
+import TableAction from '@/components/DataTable/tools/Action.vue'
+import { ADVERTISING_TYPE, ADVERTISING_PLATFORM, ADVERTISING_STATUS } from '@/utils/dictionary.js'
+import { advertisingDelete } from '@/api/setting/advertising.js'
+
+/* 注册table */
+const tableRef = ref()
+const searchParams = ref()
+
+function handleSearch(params) {
+ searchParams.value = { ...params }
+ tableRef.value.reFetch({ searchParams })
+}
+
+/**
+ * @description: 获取数据及操作
+ * @param {*} row 单行数据
+ * @param {*} type 操作类型 create:创建,preview:预览,edit:编辑
+ * @return {*}
+ */
+function getRowData(row, type) {
+ data.rowData = type === 'create' ? { pid: row.id } : row
+ data.modalType = type
+ data.modalShow = true
+}
+
+// 删除方法
+function deleteData(id) {
+ advertisingDelete(id)
+ .then((res) => {
+ if (res.code === 0) {
+ handleSearch()
+ }
+ })
+ .catch((e) => {
+ console.log(e)
+ })
+}
+
+const data = reactive({
+ tableRef,
+ searchParams,
+ rowData: {},
+ modalType: 'create',
+ modalShow: false,
+ handleSearch,
+
+ columns: [
+ {
+ type: 'selection'
+ },
+ {
+ title: '编号',
+ key: 'key',
+ render: (_, index) => {
+ return `${index + 1}`
+ },
+ align: 'center',
+ width: 50
+ },
+ {
+ title: '广告名称',
+ key: 'title',
+ align: 'center',
+ width: 200
+ },
+ {
+ title: '广告封面',
+ key: 'cover',
+ render(row) {
+ return h(TableImage, {
+ images: {
+ width: 36,
+ height: 36,
+ src: row.cover
+ }
+ })
+ },
+ align: 'center',
+ width: 100
+ },
+ {
+ title: '广告类型',
+ key: 'type',
+ align: 'center',
+ width: 100,
+ render(row) {
+ return h(TableTags, {
+ data: row.type,
+ filters: ADVERTISING_TYPE,
+ tags: {
+ bordered: true
+ }
+ })
+ }
+ },
+ {
+ title: '投放平台',
+ key: 'platform',
+ align: 'center',
+ width: 100,
+ render(row) {
+ return h(TableTags, {
+ data: row.platform,
+ filters: ADVERTISING_PLATFORM,
+ tags: {
+ bordered: true
+ }
+ })
+ }
+ },
+ {
+ title: '广告描述',
+ key: 'description',
+ align: 'center',
+ ellipsis: {
+ tooltip: true
+ },
+ width: 250
+ },
+ {
+ title: '广告地址',
+ key: 'url',
+ align: 'center',
+ ellipsis: {
+ tooltip: true
+ },
+ width: 200
+ },
+ {
+ title: '广告尺寸',
+ key: 'size',
+ align: 'center',
+ render(row) {
+ return h(TableTags, {
+ data: `${row.width} x ${row.height}`
+ })
+ },
+ width: 100
+ },
+ {
+ title: '开始时间',
+ key: 'startTime',
+ align: 'center',
+ width: 200
+ },
+ {
+ title: '结束时间',
+ key: 'endTime',
+ align: 'center',
+ width: 200
+ },
+ {
+ title: '浏览量',
+ key: 'viewNum',
+ align: 'center',
+ width: 100
+ },
+ {
+ title: '状态',
+ key: 'status',
+ align: 'center',
+ width: 50,
+ render(row) {
+ return h(TableTags, {
+ data: row.status,
+ filters: ADVERTISING_STATUS,
+ tags: {
+ bordered: true
+ }
+ })
+ }
+ },
+ {
+ title: '排序',
+ key: 'sort',
+ align: 'center',
+ width: 50
+ },
+ {
+ title: '创建时间',
+ key: 'createTime',
+ align: 'center',
+ width: 200
+ },
+ {
+ title: '操作',
+ align: 'center',
+ width: 150,
+ fixed: 'right',
+ render(row) {
+ return h(TableAction, {
+ actions: [
+ {
+ label: '添加',
+ type: 'button',
+ props: {
+ type: 'primary',
+ text: true,
+ onClick: getRowData.bind(null, row, 'create')
+ },
+ auth: 'basic_list'
+ },
+ {
+ label: '修改',
+ type: 'button',
+ props: {
+ type: 'primary',
+ text: true,
+ onClick: getRowData.bind(null, row, 'update')
+ },
+ auth: 'basic_list'
+ },
+ {
+ label: '删除',
+ type: 'popconfirm',
+ auth: 'basic_list',
+ tip: '确定删除这条数据吗?',
+ props: {
+ onPositiveClick: deleteData.bind(null, [row.id])
+ },
+ ButtonProps: {
+ text: true,
+ type: 'primary'
+ }
+ }
+ ],
+ align: 'center'
+ })
+ }
+ }
+ ]
+})
+
+export default data
diff --git a/src/views/statistics/statistical-analysis/index.vue b/src/views/statistics/statistical-analysis/index.vue
index 0a522f7..3b691fd 100644
--- a/src/views/statistics/statistical-analysis/index.vue
+++ b/src/views/statistics/statistical-analysis/index.vue
@@ -1,14 +1,32 @@
- 统计分析
+ 这是按钮one
+ 这是按钮two