li.shaoyi 8 kuukautta sitten
vanhempi
commit
da3489dcef

+ 1 - 1
src/packages/pc/components/base/table-filter-v2/index.vue

@@ -28,7 +28,7 @@
 </template>
 
 <script lang="ts" setup>
-import { shallowRef, PropType, computed, StyleHTMLAttributes } from 'vue'
+import { shallowRef, PropType, computed } from 'vue'
 import { FormInstance, FormRules } from 'element-plus'
 import { FilterOption, ActionButton } from '@/hooks/datatable-v2/types'
 import { i18n } from '@/stores'

+ 3 - 3
src/packages/pc/views/investor/manage/user/components/details/view.vue

@@ -88,8 +88,8 @@ const hideField = [2, 3, 4].includes(props.modifyStatus) // 根据状态是否
 const newData = ref<Investor.InvestorListDetailRsp['newResult']>()
 const oldData = ref<Investor.InvestorListDetailRsp['oldResult']>()
 
-// 是否实名
-const hasauthEnum = useEnum('hasauth')
+// 是否认证
+const flagEnum = useEnum('flag')
 // 状态
 const areastatusEnum = useEnum('areastatus')
 // 变更状态
@@ -155,7 +155,7 @@ const detailProps1: CellProp[] = [
     { prop: 'createName', formatLabel: () => oldData.value?.userinfoDetailVo.openMode === 1 ? 'investor.manage.user.details.createName1' : 'investor.manage.user.details.createName2' },
     { prop: 'accountStatus', label: 'investor.manage.user.details.accountStatus', formatValue: (val) => areastatusEnum.getEnumTypeName(val), show: !hideField },
     { prop: 'modifyStatus', label: 'investor.manage.user.details.modifyStatus', formatValue: (val) => modifystatusEnum.getEnumTypeName(val) },
-    { prop: 'isAuth', label: 'investor.manage.user.details.isAuth', formatValue: (val) => hasauthEnum.getEnumTypeName(val) },
+    { prop: 'isAuth', label: 'investor.manage.user.details.isAuth', formatValue: (val) => flagEnum.getEnumTypeName(val) },
     { prop: 'modifyTime', label: 'investor.manage.user.details.modifyTime', formatValue: (val) => formatDate(val) },
     { prop: 'modifyName', label: 'investor.manage.user.details.modifyName' },
     { prop: 'auditTime', label: 'investor.manage.user.details.auditTime', formatValue: (val) => formatDate(val), show: !hideField },

+ 5 - 2
src/packages/pc/views/investor/manage/user/components/edit/index.vue

@@ -25,7 +25,7 @@
                 </el-form-item>
                 <el-form-item :label="t('investor.manage.user.edit.isAuth')" prop="isAuth">
                     <el-radio-group v-model="formData.userAccountDetailVo.isAuth">
-                        <template v-for="item in getUserInfoTypeList()" :key="item.value">
+                        <template v-for="item in flagEnum.getEnumOptions()" :key="item.value">
                             <el-radio :label="item.label" :value="item.value" />
                         </template>
                     </el-radio-group>
@@ -151,9 +151,10 @@
 import { ref, reactive, PropType, onMounted, computed } from 'vue'
 import { ElMessage, FormInstance, FormRules, UploadUserFile } from 'element-plus'
 import { handleNoneValue, parseFilePaths, extractFilePaths } from '@/filters'
+import { useEnum } from '@/hooks/enum'
 import { useRequest } from '@/hooks/request'
 import { investorEdit, queryInvestorListDetail } from '@/services/api/investor'
-import { getUserInfoTypeList, getGenderList, UserInfoType } from '@/constants/member'
+import { getGenderList, UserInfoType } from '@/constants/member'
 import AppDrawer from '@pc/components/base/drawer/index.vue'
 import AppUpload from '@pc/components/base/upload/index.vue'
 import AppEnum from '@pc/components/modules/enum/index.vue'
@@ -168,6 +169,8 @@ const props = defineProps({
     }
 })
 
+const flagEnum = useEnum('flag') // 是否认证
+
 const { global: { t } } = i18n
 const formRef = ref<FormInstance>()
 const show = ref(true)

+ 2 - 2
src/packages/pc/views/notice/manage/components/audit/index.vue

@@ -23,7 +23,7 @@
 <script lang="ts" setup>
 import { reactive, shallowRef, PropType } from 'vue'
 import { ElMessage, FormInstance, FormRules } from 'element-plus'
-import { auditinform } from '@/services/api/notice'
+import { auditMsg } from '@/services/api/notice'
 import DetailsView from '../details/index.vue'
 
 const props = defineProps({
@@ -57,7 +57,7 @@ const onSubmit = () => {
     const run = () => {
         loading.value = true
         dialogVisible.value = false
-        auditinform({
+        auditMsg({
             data: formData
         }).then(() => {
             ElMessage.success('提交成功')

+ 1 - 1
src/packages/pc/views/notice/manage/components/details/index.vue

@@ -1,6 +1,6 @@
 <!-- 通知公告-公告通知管理-详情 -->
 <template>
-    <app-drawer :title="t('investor.manage.cancelapply.details.title')" width="900" v-model:show="show"
+    <app-drawer title="详情" width="900" v-model:show="show"
         :refresh="refresh">
         <app-table-details title="信息" :data="data" :label-width="120" :cell-props="detailProps1" :column="2">
             <template #content="{ value }">

+ 51 - 0
src/packages/pc/views/notice/news/components/audit/index.vue

@@ -0,0 +1,51 @@
+<!-- 通知公告-资讯管理-审核 -->
+<template>
+    <DetailsView ref="detailsRef" v-bind="{ record }" :loading="loading">
+        <el-button type="primary" @click="onSubmit(1)">审核通过</el-button>
+        <el-button type="primary" @click="onSubmit(0)">审核不通过</el-button>
+    </DetailsView>
+</template>
+
+<script lang="ts" setup>
+import { reactive, shallowRef, PropType } from 'vue'
+import { ElMessage, ElMessageBox } from 'element-plus'
+import { auditinform } from '@/services/api/notice'
+import DetailsView from '../details/index.vue'
+
+const props = defineProps({
+    record: {
+        type: Object as PropType<Notice.InformManqueryRsp>,
+        required: true
+    }
+})
+
+const detailsRef = shallowRef()
+const loading = shallowRef(false)
+
+const formData = reactive<Notice.AuditInformReq>({
+    id: props.record.id,
+    flag: 0,
+})
+
+const onSubmit = (flag: number) => {
+    ElMessageBox.confirm(
+        flag === 1 ? '确认审核通过?' : '确认审核拒绝?',
+        '提示'
+    ).then(() => {
+        formData.flag = flag
+        loading.value = true
+
+        auditinform({
+            data: formData
+        }).then(() => {
+            ElMessage.success('提交成功')
+            detailsRef.value?.close(true)
+        }).catch((err) => {
+            ElMessage.error('提交失败:' + err)
+            detailsRef.value?.close()
+        }).finally(() => {
+            loading.value = false
+        })
+    })
+}
+</script>

+ 52 - 0
src/packages/pc/views/notice/news/components/delete/index.vue

@@ -0,0 +1,52 @@
+<!-- 通知公告-资讯管理-删除 -->
+<template>
+    <app-drawer :title="t('common.alert')" v-model:show="show" :loading="loading" :refresh="refresh">
+        <div class="g-text-message">确认删除?</div>
+        <template #footer>
+            <el-button @click="onCancel(false)">{{ t('operation.cancel') }}</el-button>
+            <el-button type="primary" @click="onSubmit">{{ t('operation.confirm') }}</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import { deleteinform } from '@/services/api/notice'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+import { i18n } from '@/stores'
+
+const props = defineProps({
+    record: {
+        type: Object as PropType<Notice.InformManqueryRsp>,
+        required: true
+    }
+})
+
+const { global: { t } } = i18n
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+const loading = shallowRef(false)
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    loading.value = true
+    deleteinform({
+        data: {
+            id: props.record.id,
+        }
+    }).then(() => {
+        ElMessage.success(t('common.tips5'))
+        onCancel(true)
+    }).catch((err) => {
+        ElMessage.error(t('common.tips6') + err)
+        onCancel()
+    }).finally(() => {
+        loading.value = false
+    })
+}
+</script>

+ 77 - 0
src/packages/pc/views/notice/news/components/details/index.vue

@@ -0,0 +1,77 @@
+<!-- 通知公告-资讯管理-详情 -->
+<template>
+    <app-drawer title="详情" width="900" v-model:show="show" :refresh="refresh">
+        <app-table-details :data="data" :label-width="120" :cell-props="detailProps" :column="2">
+            <!-- 缩略图 -->
+            <template #coverimage="{ value }">
+                <el-image :src="getFirstPathFullUrl(value)" fit="cover" lazy style="width: 128px; height: 72px" />
+            </template>
+            <!-- 内容 -->
+            <template #context="{ value }">
+                <div v-html="value"></div>
+            </template>
+        </app-table-details>
+        <template #footer>
+            <el-button @click="close(false)">{{ t('operation.close') }}</el-button>
+            <slot></slot>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType, computed } from 'vue'
+import { ElMessage } from 'element-plus'
+import { formatDate, getFirstPathFullUrl } from '@/filters'
+import { useEnum } from '@/hooks/enum'
+import { useRequest } from '@/hooks/request'
+import { informDetail } from '@/services/api/notice'
+import { CellProp } from '@pc/components/base/table-details/types'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+import AppTableDetails from '@pc/components/base/table-details/index.vue'
+import { i18n } from '@/stores'
+
+const props = defineProps({
+    record: {
+        type: Object as PropType<Notice.InformManqueryRsp>,
+        required: true
+    }
+})
+
+const { global: { t } } = i18n
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+
+const flagEnum = useEnum('flag')
+
+const { data } = useRequest(informDetail, {
+    params: {
+        id: props.record.id,
+    },
+    onError: (err) => {
+        ElMessage.error(err)
+    }
+})
+
+const detailProps = computed<CellProp[]>(() => [
+    { prop: 'columnname', label: '所属栏目' },
+    { prop: 'author', label: '作者' },
+    { prop: 'srcname: string;', label: '来源' },
+    { prop: 'hits', label: '点击量' },
+    { prop: 'istop', label: '是否置顶', formatValue: (val) => flagEnum.getEnumTypeName(val) },
+    { prop: 'isshow', label: '是否展示', formatValue: (val) => flagEnum.getEnumTypeName(val) },
+    { prop: 'publishdate', label: '发布日期', formatValue: (val) => formatDate(val, 'YYYY-MM-DD') },
+    { prop: 'coverimage', label: '缩略图', entireRow: true },
+    { prop: 'title', label: '标题', entireRow: true },
+    { prop: 'brief', label: '简介', entireRow: true },
+    { prop: 'context', label: '内容', entireRow: true }
+])
+
+const close = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+defineExpose({
+    close
+})
+</script>

+ 143 - 0
src/packages/pc/views/notice/news/components/edit/index.vue

@@ -0,0 +1,143 @@
+<!-- 通知公告-资讯管理-编辑 -->
+<template>
+    <app-drawer :title="t('investor.user.open.edit.title')" width="900" v-model:show="show" :refresh="refresh"
+        :loading="loading">
+        <el-form ref="formRef" class="el-form--horizontal" label-width="100px" :model="formData" :rules="formRules"
+            :show-message="false">
+            <el-form-item label="标题" prop="title">
+                <el-input v-model="formData.title" :placeholder="t('common.pleaseenter')" />
+            </el-form-item>
+            <el-form-item label="所属栏目" prop="columnid">
+                <el-select v-model="formData.columnid">
+                    <el-option v-for="item in data?.siteColumnconfig" :key="item.id" :label="item.columnname"
+                        :value="item.id" />
+                </el-select>
+            </el-form-item>
+            <el-form-item label="作者" prop="author">
+                <el-input v-model="formData.author" :placeholder="t('common.pleaseenter')" />
+            </el-form-item>
+            <el-form-item label="来源" prop="srcid">
+                <el-select v-model="formData.srcid">
+                    <el-option v-for="item in data?.gzMemberinfo" :key="item.memberid" :label="item.membername"
+                        :value="item.memberid" />
+                </el-select>
+            </el-form-item>
+            <el-form-item label="点击量" prop="hits">
+                <el-input-number v-model="formData.hits" :placeholder="t('common.pleaseenter')" :min="0" />
+            </el-form-item>
+            <el-form-item label="发布日期" prop="publishdate">
+                <el-date-picker v-model="formData.publishdate" value-format="YYYY-MM-DD"
+                    :disabled-date="(date: Date) => date.getTime() < Date.now() - 8.64e7"
+                    :placeholder="t('common.pleasechoice')" />
+            </el-form-item>
+            <el-form-item label="是否置顶" prop="istop">
+                <el-switch v-model="formData.istop" :active-value="1" :inactive-value="0" />
+            </el-form-item>
+            <el-form-item label="是否展示" prop="isshow">
+                <el-switch v-model="formData.isshow" :active-value="1" :inactive-value="0" />
+            </el-form-item>
+            <el-form-item label="缩略图" prop="coverimage">
+                <app-upload v-model="uploadFiles" :file-types="['image']" />
+            </el-form-item>
+            <el-form-item class="el-form-item--row" label="简介" prop="brief">
+                <el-input type="textarea" v-model="formData.brief" maxlength="200" :rows="3"
+                    :placeholder="t('common.pleaseenter')" />
+            </el-form-item>
+            <el-form-item class="el-form-item--row" label="内容" prop="context">
+                <app-editor v-model="formData.context" />
+            </el-form-item>
+        </el-form>
+        <template #footer>
+            <el-button @click="onCancel(false)">{{ t('operation.close') }}</el-button>
+            <el-button type="primary" @click="onSubmit(10)">提交</el-button>
+            <el-button type="primary" @click="onSubmit(1)" v-if="!record?.id">暂存</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { ref, PropType, onMounted } from 'vue'
+import { ElMessage, FormInstance, FormRules, UploadUserFile } from 'element-plus'
+import { formatDate, parseFilePaths, extractFilePaths } from '@/filters'
+import { useRequest } from '@/hooks/request'
+import { dealinform, informManinit, informDetail } from '@/services/api/notice'
+import { i18n } from '@/stores'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+import AppEditor from '@pc/components/base/editor/index.vue'
+import AppUpload from '@pc/components/base/upload/index.vue'
+
+const props = defineProps({
+    record: {
+        type: Object as PropType<Notice.InformManqueryRsp>
+    }
+})
+
+const { global: { t } } = i18n
+const formRef = ref<FormInstance>()
+const show = ref(true)
+const refresh = ref(false)
+const uploadFiles = ref<UploadUserFile[]>([])
+
+const formData = ref<Partial<Notice.DealInformReq>>({
+    istop: 0,
+    isshow: 1,
+    hits: 0,
+    publishdate: formatDate(new Date().toISOString(), 'YYYY-MM-DD')
+})
+
+const { data } = useRequest(informManinit)
+
+const { loading, run } = useRequest(informDetail, {
+    manual: true,
+    onSuccess: ((res) => {
+        res.data.publishdate = formatDate(res.data.publishdate, 'YYYY-MM-DD')
+        formData.value = res.data
+        uploadFiles.value = parseFilePaths(res.data.coverimage)
+    }),
+    onError: (err) => {
+        ElMessage.error(err)
+    }
+})
+
+// 表单验证规则
+const formRules: FormRules = {
+    title: [{ required: true }],
+    columnid: [{ required: true }],
+    publishdate: [{ required: true }],
+    context: [{ required: true }],
+}
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = (status: number) => {
+    const rawData = { ...formData.value }
+    rawData.status = status
+    rawData.coverimage = extractFilePaths(uploadFiles.value)
+
+    formRef.value?.validate((valid) => {
+        if (valid) {
+            loading.value = true
+            dealinform({
+                data: rawData
+            }).then(() => {
+                ElMessage.success(t('common.tips3'))
+                onCancel(true)
+            }).catch((err) => {
+                ElMessage.error(t('common.tips4') + err)
+            }).finally(() => {
+                loading.value = false
+            })
+        }
+    })
+}
+
+onMounted(() => {
+    const id = props.record?.id
+    if (id) {
+        run({ id })
+    }
+})
+</script>

+ 53 - 0
src/packages/pc/views/notice/news/components/status/index.vue

@@ -0,0 +1,53 @@
+<!-- 通知公告-资讯管理-展示/不展示 -->
+<template>
+    <app-drawer :title="t('common.alert')" v-model:show="show" :loading="loading" :refresh="refresh">
+        <div class="g-text-message" v-if="record.isshow">确认设置为不展示?</div>
+        <div class="g-text-message" v-else>确认设置为展示?</div>
+        <template #footer>
+            <el-button @click="onCancel(false)">{{ t('operation.cancel') }}</el-button>
+            <el-button type="primary" @click="onSubmit">{{ t('operation.confirm') }}</el-button>
+        </template>
+    </app-drawer>
+</template>
+
+<script lang="ts" setup>
+import { shallowRef, PropType } from 'vue'
+import { ElMessage } from 'element-plus'
+import { isshow } from '@/services/api/notice'
+import AppDrawer from '@pc/components/base/drawer/index.vue'
+import { i18n } from '@/stores'
+
+const props = defineProps({
+    record: {
+        type: Object as PropType<Notice.InformManqueryRsp>,
+        required: true
+    }
+})
+
+const { global: { t } } = i18n
+const show = shallowRef(true)
+const refresh = shallowRef(false)
+const loading = shallowRef(false)
+
+const onCancel = (isRefresh = false) => {
+    show.value = false
+    refresh.value = isRefresh
+}
+
+const onSubmit = () => {
+    loading.value = true
+    isshow({
+        data: {
+            id: props.record.id,
+        }
+    }).then(() => {
+        ElMessage.success('保存成功')
+        onCancel(true)
+    }).catch((err) => {
+        ElMessage.error('保存失败:' + err)
+        onCancel()
+    }).finally(() => {
+        loading.value = false
+    })
+}
+</script>

+ 132 - 1
src/packages/pc/views/notice/news/index.vue

@@ -1,7 +1,138 @@
 <!-- 通知公告-资讯管理 -->
 <template>
-    <app-view></app-view>
+    <app-view>
+        <template #header>
+            <app-filter :option="filterOption">
+                <template #userid="{ item }">
+                    <el-form-item :label="item.label">
+                        <app-select-investor v-model="item.value" />
+                    </el-form-item>
+                </template>
+            </app-filter>
+        </template>
+        <app-table :data="dataList" :columns="tableColumns" :loading="loading">
+            <template #headerLeft>
+                <app-operation :data-list="getActionButtons(['notice_news_add'])"
+                    @click="(code: string) => openComponent(code)" />
+            </template>
+            <!-- 操作 -->
+            <template #operate="{ row }">
+                <app-operation size="small" :data-list="handleOperateButtons(row)"
+                    @click="(code: string) => openComponent(code, row)" circle />
+            </template>
+            <template #footer>
+                <app-pagination :total="total" v-model:page-size="pageSize" v-model:page-index="pageIndex"
+                    @change="onSearch" />
+            </template>
+        </app-table>
+        <component :is="componentMap.get(componentId)" v-bind="{ record }" @closed="closeComponent"
+            v-if="componentId" />
+    </app-view>
 </template>
 
 <script lang="ts" setup>
+import { shallowRef } from 'vue'
+import { ElMessage } from 'element-plus'
+import { formatDate } from '@/filters'
+import { useDataFilter } from '@/hooks/datatable-v2'
+import { useRequest } from '@/hooks/request'
+import { useOperation } from '@/hooks/operation'
+import { useEnum } from '@/hooks/enum'
+import { informManquery, informManinit } from '@/services/api/notice'
+import { i18n } from '@/stores'
+import AppTable from '@pc/components/base/table/index.vue'
+import AppPagination from '@pc/components/base/pagination/index.vue'
+import AppOperation from '@pc/components/base/operation/index.vue'
+import AppFilter from '@pc/components/base/table-filter-v2/index.vue'
+import AppSelectInvestor from '@pc/components/modules/select-investor/index.vue'
+
+const { global: { t } } = i18n
+const flagEnum = useEnum('flag')
+const columnDetailStatusEnum = useEnum('columndetail_status') // 状态
+
+const { componentMap, componentId, record, openComponent, closeComponent, getActionButtons } = useOperation<Notice.InformManqueryRsp>({
+    onClose: () => onSearch()
+})
+
+const { data } = useRequest(informManinit)
+
+const { dataList, total, pageSize, pageIndex, loading, run } = useRequest(informManquery, {
+    params: {
+        pageNum: 1,
+        pageSize: 20
+    },
+    onError: (err) => {
+        ElMessage.error(err)
+    }
+})
+
+const tableColumns = shallowRef<Model.TableColumn[]>([
+    { field: 'columnname', label: '资讯类型' },
+    { field: 'title', label: '标题' },
+    { field: 'srcname', label: '来源' },
+    { field: 'author', label: '作者' },
+    { field: 'istop', label: '是否置顶', formatValue: (val) => flagEnum.getEnumTypeName(val) },
+    { field: 'isshow', label: '是否展示', formatValue: (val) => flagEnum.getEnumTypeName(val) },
+    { field: 'publishdate', label: '发布日期', formatValue: (val) => formatDate(val, 'YYYY-MM-DD') },
+    { field: 'status', label: '状态', formatValue: (val) => columnDetailStatusEnum.getEnumTypeName(val) },
+    { field: 'creatoruser', label: '创建人' },
+    { field: 'creaedate', label: '创建时间', formatValue: (val) => formatDate(val) },
+    { field: 'operate', label: 'common.operate', fixed: 'right', width: 180 }
+])
+
+const { filterOption, getQueryParams, resetFilters } = useDataFilter<Notice.InformManqueryReq>({
+    filters: [
+        {
+            field: 'columnid',
+            label: '类型',
+            options: () => data.value?.siteColumnconfig.map((e) => ({
+                label: e.columnname,
+                value: e.id
+            })) ?? []
+        },
+        {
+            field: 'status',
+            label: '状态',
+            options: () => columnDetailStatusEnum.getEnumOptions()
+        },
+        {
+            field: 'title',
+            label: '标题'
+        },
+        {
+            field: 'isshow',
+            label: '是否展示',
+            options: () => flagEnum.getEnumOptions()
+        },
+    ],
+    buttons: [
+        { label: t('operation.search'), className: 'el-button--primary', onClick: () => onSearch() },
+        { label: t('operation.reset'), className: 'el-button--primary', validateEvent: false, onClick: () => resetFilters() }
+    ]
+})
+
+// 处理操作按钮
+const handleOperateButtons = (row: Notice.InformManqueryRsp) => {
+    const buttons = ['notice_news_details', 'notice_news_delete']
+
+    if (row.status === 10) {
+        buttons.push('notice_news_audit')
+    } else {
+        buttons.push('notice_news_modify')
+        if (row.status !== 1) {
+            if (row.isshow) {
+                buttons.push('notice_news_show')
+            } else {
+                buttons.push('notice_news_hide')
+            }
+        }
+    }
+
+    return getActionButtons(buttons)
+}
+
+const onSearch = () => {
+    const qs = getQueryParams()
+    run(qs)
+}
 </script>

+ 78 - 1
src/packages/pc/views/notice/sms/index.vue

@@ -1,7 +1,84 @@
 <!-- 通知公告-短信查询 -->
 <template>
-    <app-view></app-view>
+    <app-view>
+        <template #header>
+            <app-filter :option="filterOption" />
+        </template>
+        <app-table :data="dataList" :columns="tableColumns" :loading="loading">
+            <!-- 操作 -->
+            <template #operate="{ row }">
+                <app-operation size="small" :data-list="getActionButtons()"
+                    @click="(code: string) => openComponent(code, row)" circle />
+            </template>
+            <template #footer>
+                <app-pagination :total="total" v-model:page-size="pageSize" v-model:page-index="pageIndex"
+                    @change="onSearch" />
+            </template>
+        </app-table>
+        <component :is="componentMap.get(componentId)" v-bind="{ record }" @closed="closeComponent"
+            v-if="componentId" />
+    </app-view>
 </template>
 
 <script lang="ts" setup>
+import { shallowRef } from 'vue'
+import { ElMessage } from 'element-plus'
+import { formatDate } from '@/filters'
+import { useDataFilter } from '@/hooks/datatable-v2'
+import { useRequest } from '@/hooks/request'
+import { useOperation } from '@/hooks/operation'
+import { smsquery } from '@/services/api/notice'
+import { i18n } from '@/stores'
+import AppTable from '@pc/components/base/table/index.vue'
+import AppPagination from '@pc/components/base/pagination/index.vue'
+import AppOperation from '@pc/components/base/operation/index.vue'
+import AppFilter from '@pc/components/base/table-filter-v2/index.vue'
+
+const { global: { t } } = i18n
+
+const { componentMap, componentId, record, openComponent, closeComponent, getActionButtons } = useOperation<Notice.InformManqueryRsp>({
+    onClose: () => onSearch()
+})
+
+const { dataList, total, pageSize, pageIndex, loading, run } = useRequest(smsquery, {
+    params: {
+        pageNum: 1,
+        pageSize: 20
+    },
+    onError: (err) => {
+        ElMessage.error(err)
+    }
+})
+
+const tableColumns = shallowRef<Model.TableColumn[]>([
+    { field: 'columnname', label: '接收手机号' },
+    { field: 'title', label: '消息模板' },
+    { field: 'srcname', label: '发送状态' },
+    { field: 'author', label: '错误信息' },
+    { field: 'istop', label: '发送时间', formatValue: (val) => formatDate(val) },
+    { field: 'operate', label: 'common.operate', fixed: 'right' }
+])
+
+const { filterOption, getQueryParams, resetFilters } = useDataFilter<Notice.SmsQueryReq>({
+    filters: [
+        {
+            field: 'status',
+            label: '发送状态',
+            options: () => []
+        },
+        {
+            field: 'recvphone',
+            label: '接收手机号'
+        },
+    ],
+    buttons: [
+        { label: t('operation.search'), className: 'el-button--primary', onClick: () => onSearch() },
+        { label: t('operation.reset'), className: 'el-button--primary', validateEvent: false, onClick: () => resetFilters() }
+    ]
+})
+
+const onSearch = () => {
+    const qs = getQueryParams()
+    run(qs)
+}
 </script>

+ 22 - 1
src/services/api/notice/index.ts

@@ -32,7 +32,7 @@ export function noticeMsgDetail(options: CommonFetchOptions<{ request: Notice.No
 /**
  * 通知公告-->公告通知管理-->审核
  */
-export function auditinform(options: CommonFetchOptions<{ request: Notice.AuditMsgReq; }>) {
+export function auditMsg(options: CommonFetchOptions<{ request: Notice.AuditMsgReq; }>) {
     return httpClient.commonRequest('/notice/auditMsg', 'get', options)
 }
 
@@ -149,8 +149,29 @@ export function isshow(options: CommonFetchOptions<{ response: Notice.IsShowReq;
 }
 
 /**
+ * 通知公告-->资讯管理-->审核
+ */
+export function auditinform(options: CommonFetchOptions<{ response: Notice.AuditInformReq; }>) {
+    return httpClient.commonRequest('/notice/auditinform', 'get', options)
+}
+
+/**
  * 通知公告-->资讯管理-->删除
  */
 export function deleteinform(options: CommonFetchOptions<{ response: Notice.DeleteInformReq; }>) {
     return httpClient.commonRequest('/notice/deleteinform', 'get', options)
+}
+
+/**
+ * 通知公告-->短信查询-->获取列表
+ */
+export function smsquery(options: CommonFetchOptions<{ request: Notice.SmsQueryReq; response: Notice.SmsQueryRsp[]; }>) {
+    return httpClient.commonRequest('/notice/smsquery', 'get', options)
+}
+
+/**
+ * 通知公告-->短信查询-->重新发送
+ */
+export function resend(options: CommonFetchOptions<{ request: Notice.ResendReq; }>) {
+    return httpClient.commonRequest('/notice/resend', 'get', options)
 }

+ 32 - 0
src/types/model/notice.d.ts

@@ -311,8 +311,40 @@ declare namespace Notice {
         id: number;
     }
 
+    /** 通知公告-->资讯管理-->审核 */
+    interface AuditInformReq {
+        flag: number;
+        id: number;
+    }
+
     /** 通知公告-->资讯管理-->删除 请求 */
     interface DeleteInformReq {
         id: number;
     }
+
+    /** 通知公告-->短信查询-->获取列表 请求 */
+    interface SmsQueryReq {
+        recvphone?: string; // 接收手机号
+        status?: number; // 发送状态
+        sensitive?: string[]; // 敏感词权限
+        userid?: number;
+        pageNum: number;
+        pageSize: number;
+    }
+
+    /** 通知公告-->短信查询-->获取列表 响应 */
+    interface SmsQueryRsp {
+        createtime: string; // 发送时间
+        errinfo: string; // 错误信息
+        failedphone: string;
+        msgid: number;
+        recvphone: string; // 接收手机号
+        status: number; // 发送状态
+        tempname: string; // 消息模板
+    }
+
+    /** 通知公告-->短信查询-->重新发送 请求 */
+    interface ResendReq {
+        id: msgid;
+    }
 }