Sfoglia il codice sorgente

增加流量池操作记录

wxy 3 mesi fa
parent
commit
e1b88afe97

+ 5 - 0
src/api/path/flowPool.api.js

@@ -43,3 +43,8 @@ export  function  createWarning(data){
 export  function  updateWarning(data){
     return service.post('/admin/alert/warningUpdate',data)
 }
+
+// 流量池操作记录
+export function updateFlowPoolData(data){
+    return service.post('/admin/platform/trafficPoolListRecord',data)
+}

+ 2 - 1
src/components/Search/index.vue

@@ -93,6 +93,7 @@ const loadDictOptions = async (index, dict) => {
     const dictionary = await Getdictionary(dict);
     loadedDicts.value[dict] = dictionary || [];
     SearchForm.value[index].options = loadedDicts.value[dict];
+    originalSearchForm.value[index].options = loadedDicts.value[dict];
 };
 
 watch(
@@ -105,7 +106,7 @@ watch(
             }
         }
         // 如果当前长度超过5条就需要折叠展开
-        if (SearchForm.value.length >= 5) {
+        if (SearchForm.value.length >6) {
             show.value = true;
         }
         // 初始化切割数组,使用原始SearchForm数据的副本进行操作

+ 149 - 19
src/views/OperationRecord/FlowpoolRecord/index.vue

@@ -1,39 +1,169 @@
+<!-- 流量池 -->
 <template>
-  <div>
-    <div class="Search">
-      <Search></Search>
+  <div class="container">
+    <!-- 搜索条件区 -->
+    <div class="search-section">
+      <Search :SearchForm="SearchFormList" @query="intData" @reset="reset"></Search>
     </div>
 
-    <div class="table">
-      <a-table :columns="columnsFlow" :data="data" :pagination="pageData" @page-change="evChangePage" />
+    <div class="audit-btn">
+      <a-button @click="dictShowModel(1, null)" type="text" v-if="role == 1">
+        <template #icon>
+          <icon-plus-circle />
+        </template>
+        <template #default>
+          {{ $t('form.Add') }}
+        </template>
+      </a-button>
     </div>
+
+    <a-table row-key="id" :data="dataSource" :columns="columnsFlow" :pagination="pagination" :scroll="{ x: 'auto' }"
+      @page-change="evChangePage">
+
+      <template #status="{ record }">
+        <a-tag :color="record.status == 1 ? '#00b42a' : '#f53f3f'">{{ trafficList.find(val => val.value ==
+          record.status)?.label }}</a-tag>
+      </template>
+
+    </a-table>
+
+
   </div>
 </template>
 
 <script setup>
-import { ref, onMounted, toRefs } from 'vue';
+import { onMounted, ref, toRefs } from "vue";
+import { columnsFlow ,SearchFormList} from "../config";
+import {
+  updateFlowPoolData,
+} from "@/api/path/flowPool.api"
+import { useSystemStore } from "@/store/modules/systemStore"
+import { Getdictionary } from '@/mixins/index.js'
 import Search from '@/components/Search/index.vue'
-import {columnsFlow} from '../config'
-
+const systemStore = useSystemStore()
 const state = ref({
-  pageData: {
-    total: 10,
-    size: 10,
+  role: systemStore.getRole,
+  searchForm: {},
+  pagination: {
+    total: 0,
+    pageSize: 10,
     current: 1,
   },
-  data: []
+  sourceList: [],
+  trafficList: [],
+  dataSource: [],
 })
+const {
+  role,
+  searchForm,
+  pagination,
+  sourceList,
+  trafficList,
+  dataSource,
+} = toRefs(state.value)
+
+const intData = async (item) => {
+  if (item) {
+    searchForm.value = item
+  }
+  const param = {
+    current: pagination.value.current,
+    size: pagination.value.pageSize,
+    ...searchForm.value,
+  }
+  const { data } = await updateFlowPoolData(param)
+  dataSource.value = (data.records || []).map((item, index) => {
+    const sourceName = sourceList.value.find(val => val.value == item.source)?.label
+    const Activated = 0 + '/' + item.iccids?.length
+    const HaveBeenUsed = 0 + '/' + item.size + item.sizeType
+    item.children = item.children?.map(res => {
+      return {
+        ...res,
+        sourceName,// 运营商名称
+        Activated: Activated,
+        HaveBeenUsed: HaveBeenUsed,
+        trafficPoolType:res.trafficPoolType==1?'前流量池':'后流量池',
+        simTariffName:item.simTariffName,
+        size:res.size+'/'+res.sizeType
+      }
+    })
+    return {
+      ...item,
+      sourceName,// 运营商名称
+      Activated: Activated,
+      trafficPoolType:item.trafficPoolType==1?'前流量池':'后流量池',
+      HaveBeenUsed: HaveBeenUsed,
+      size:item.size+'/'+item.sizeType
+    }
+  })
 
-const { pageData, data } = toRefs(state.value)
+  pagination.value.total = data.total
+}
 
-// 分页
 const evChangePage = (page) => {
-  pageData.value.current = page
+  pagination.value.current = page
+  intData()
+}
+const reset = (item) => {
+  searchForm.value = item
+  pagination.value.current = 1
+  intData()
+}
+
+const handleDictValue = async () => {
+  sourceList.value = await Getdictionary('source')
+  trafficList.value = await Getdictionary('trafficPacketStatus')
 }
+
+onMounted(async () => {
+  await handleDictValue()
+  await intData()
+})
+
 </script>
-<style scoped>
-.Search,
-.table {
+
+<style scoped lang="less">
+.m-r-10 {
+  margin-right: 10px;
+}
+
+.search-section {
   margin-top: 20px;
+  margin-bottom: 20px;
+}
+
+.container {
+  .head-title {
+    display: flex;
+    justify-content: space-between;
+  }
+
+  .form-row {
+    display: flex;
+
+    .form-row-col {
+      width: 25%;
+      display: flex;
+      align-items: center;
+
+      .form-row-label {
+        width: 120px;
+        text-align: right;
+      }
+    }
+  }
+}
+
+silent-expire-alarm {
+  padding: 20px !important;
+  // background: #fcf;
+}
+
+.search-section {
+  margin-bottom: 20px;
+}
+
+.audit-btn {
+  margin-bottom: 10px;
 }
-</style>
+</style>

+ 38 - 94
src/views/OperationRecord/config.js

@@ -181,116 +181,60 @@ export const trafficSearchFrom = [
   },
 ];
 
-// 客户搜索字段
-export const UserSearchForm = [
+
+
+// 流量池
+export const columnsFlow = [
+  { title: window.$t('flowPool.poolNumber'), dataIndex: 'id', align: 'center', ellipsis:true,width: 50 },
+  { title: '池类型', dataIndex: 'trafficPoolType', align: 'center', ellipsis:true,width: 50 },
+  { title: window.$t('flowPool.label'), dataIndex: 'label', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.trafficPoolStatus'), slotName: 'status', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.source'), dataIndex: 'sourceName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.tariffName'), dataIndex: 'simTariffName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title:'池大小', dataIndex: 'size', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.ActivatedName'),dataIndex:'Activated', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.HaveBeenUsedName'), dataIndex: 'HaveBeenUsed', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
+  { title: window.$t('flowPool.updated_at'), dataIndex: 'updatedAt', align: 'center', width: 200,tooltip:true,ellipsis:true },
+]
+
+
+export const SearchFormList = [
   {
     type: "input",
-    label: "客户名称",
-    field: "name",
+    label: "流量池名称",
+    field: "label",
     value: "", // 双向绑定的值
   },
   {
-    type: "input",
-    label: "客户账号",
-    field: "username",
+    type: "select",
+    label: "流量池状态",
+    field: "status",
+    options: [], // 默认空,后面会通过字典加载
+    dict: "trafficPacketStatus",
     value: "", // 双向绑定的值
+    width: "200",
   },
   {
     type: "select",
-    label: "客户状态",
-    field: "state",
+    label: "运营商名称",
+    field: "source",
     options: [], // 默认空,后面会通过字典加载
-    dict: "userType",
+    dict: "source",
     value: "", // 双向绑定的值
     width: "200",
   },
   {
-    type: "range-picker",
-    label: "创建时间",
-    field: "createdAt",
-    value: [], // 双向绑定的值
-    width: "300",
-    Custom: 'mode="month"', // 自定义值
-  },
-];
-
-export const UserColumns = [
-  {
-    title: window.$t("customer.id"),
-    dataIndex: "id",
-    align: "center",
-    ellipsis: true,
-  },
-  {
-    title: window.$t("customer.customerName"),
-    dataIndex: "name",
-    align: "center",
-    ellipsis: true,
-  },
-  {
-    title: window.$t("customer.userAdmin"),
-    dataIndex: "username",
-    align: "center",
-  },
-  {
-    title: window.$t("customer.customerStatus"),
-    slotName: "state",
-    align: "center",
-    ellipsis: true,
-  },
-  { title: "app_key  ", dataIndex: "appKey", align: "center", ellipsis: true },
-  {
-    title: "app_secret",
-    dataIndex: "appSecret",
-    align: "center",
-    ellipsis: true,
-  },
-  {
-    title: window.$t("customer.startTime"),
-    dataIndex: "createdAt",
-    align: "center",
-    ellipsis: true,
-  },
-  {
-    title: window.$t("customer.updateTime"),
-    dataIndex: "updatedAt",
-    align: "center",
-    ellipsis: true,
+    type: "input",
+    label: "资费名称",
+    field: "tariffName",
+    value: "", // 双向绑定的值
   },
   {
-    title: window.$t("global.common.operations"),
-    slotName: "operation",
-    align: "center",
-    ellipsis: true,
+    type: "range-picker",
+    label: "更新日期",
+    field: "updatedAt",
+    value: "", // 双向绑定的值
+    width: "240",
   },
 ];
 
-
-// 流量池
-export const columnsFlow = [
-  { title: window.$t('flowPool.poolNumber'), dataIndex: 'id', align: 'center', ellipsis:true,width: 50 },
-  { title: window.$t('flowPool.label'), dataIndex: 'label', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  // { title: window.$t('flowPool.userId'), dataIndex: 'user_id', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.trafficPoolType'), dataIndex: 'trafficPoolType', align: 'center', width: 200 },
-  { title: window.$t('flowPool.trafficPoolStatus'), slotName: 'status', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  // { title: window.$t('flowPool.cardFlow'), dataIndex: 'cardFlow', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.UsedMonth'), dataIndex: 'UsedMonth', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.surplusFlow'), dataIndex: 'surplusFlow', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.exceededFlow'), dataIndex: 'exceededFlow', align: 'center', width: 200 },
-  { title: window.$t('flowPool.source'), dataIndex: 'sourceName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  { title: window.$t('flowPool.tariffName'), dataIndex: 'simTariffName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  { title: window.$t('flowPool.ActivatedName'),dataIndex:'Activated', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  { title: window.$t('flowPool.HaveBeenUsedName'), dataIndex: 'HaveBeenUsed', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-  // { title: window.$t('flowPool.cardRariffName'), dataIndex: 'cardRariffName', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.cardNum'), dataIndex: 'cardNum', align: 'center', width: 200 },
-  // { title: window.$t('flowPool.totalFlow'), dataIndex: 'totalFlow', align: 'center', width: 200 },
-  { title: window.$t('flowPool.updated_at'), dataIndex: 'updatedAt', align: 'center', width: 200,tooltip:true,ellipsis:true },
-  {
-      title: window.$t('global.common.operations'),
-      slotName: 'id',
-      align: 'center',
-      width: 250,
-      fixed: "right",
-  }
-]
-

+ 192 - 25
src/views/flowPool/config.js

@@ -1,26 +1,193 @@
 export const columns = [
-    { title: window.$t('flowPool.poolNumber'), dataIndex: 'id', align: 'center', ellipsis:true,width: 50 },
-    { title: window.$t('flowPool.label'), dataIndex: 'label', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    // { title: window.$t('flowPool.userId'), dataIndex: 'user_id', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.trafficPoolType'), dataIndex: 'trafficPoolType', align: 'center', width: 200 },
-    { title: window.$t('flowPool.trafficPoolStatus'), slotName: 'status', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    // { title: window.$t('flowPool.cardFlow'), dataIndex: 'cardFlow', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.UsedMonth'), dataIndex: 'UsedMonth', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.surplusFlow'), dataIndex: 'surplusFlow', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.exceededFlow'), dataIndex: 'exceededFlow', align: 'center', width: 200 },
-    { title: window.$t('flowPool.source'), dataIndex: 'sourceName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    { title: window.$t('flowPool.tariffName'), dataIndex: 'simTariffName', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    { title: window.$t('flowPool.ActivatedName'),dataIndex:'Activated', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    { title: window.$t('flowPool.HaveBeenUsedName'), dataIndex: 'HaveBeenUsed', align: 'center', width: 200 ,tooltip:true,ellipsis:true},
-    // { title: window.$t('flowPool.cardRariffName'), dataIndex: 'cardRariffName', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.cardNum'), dataIndex: 'cardNum', align: 'center', width: 200 },
-    // { title: window.$t('flowPool.totalFlow'), dataIndex: 'totalFlow', align: 'center', width: 200 },
-    { title: window.$t('flowPool.updated_at'), dataIndex: 'updatedAt', align: 'center', width: 200,tooltip:true,ellipsis:true },
-    {
-        title: window.$t('global.common.operations'),
-        slotName: 'id',
-        align: 'center',
-        width: 250,
-        fixed: "right",
-    }
-]
+  {
+    title: window.$t("flowPool.poolNumber"),
+    dataIndex: "id",
+    align: "center",
+    ellipsis: true,
+    width: 50,
+  },
+  {
+    title: window.$t("flowPool.label"),
+    dataIndex: "label",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.trafficPoolStatus"),
+    slotName: "status",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.source"),
+    dataIndex: "sourceName",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.tariffName"),
+    dataIndex: "simTariffName",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.ActivatedName"),
+    dataIndex: "Activated",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.HaveBeenUsedName"),
+    dataIndex: "HaveBeenUsed",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.updated_at"),
+    dataIndex: "updatedAt",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("global.common.operations"),
+    slotName: "id",
+    align: "center",
+    width: 250,
+    fixed: "right",
+  },
+];
+
+export const columnsAfter = [
+  {
+    title: window.$t("flowPool.poolNumber"),
+    dataIndex: "id",
+    align: "center",
+    ellipsis: true,
+    width: 50,
+  },
+  {
+    title: window.$t("flowPool.label"),
+    dataIndex: "label",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.trafficPoolStatus"),
+    slotName: "status",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.source"),
+    dataIndex: "sourceName",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.tariffName"),
+    dataIndex: "simTariffName",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: "池大小",
+    dataIndex: "size",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.ActivatedName"),
+    dataIndex: "Activated",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.HaveBeenUsedName"),
+    dataIndex: "HaveBeenUsed",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("flowPool.updated_at"),
+    dataIndex: "updatedAt",
+    align: "center",
+    width: 200,
+    tooltip: true,
+    ellipsis: true,
+  },
+  {
+    title: window.$t("global.common.operations"),
+    slotName: "id",
+    align: "center",
+    width: 250,
+    fixed: "right",
+  },
+];
+
+export const SearchFormList = [
+  {
+    type: "input",
+    label: "流量池名称",
+    field: "label",
+    value: "", // 双向绑定的值
+  },
+  {
+    type: "select",
+    label: "流量池状态",
+    field: "status",
+    options: [], // 默认空,后面会通过字典加载
+    dict: "trafficPacketStatus",
+    value: "", // 双向绑定的值
+    width: "200",
+  },
+  {
+    type: "select",
+    label: "运营商名称",
+    field: "source",
+    options: [], // 默认空,后面会通过字典加载
+    dict: "source",
+    value: "", // 双向绑定的值
+    width: "200",
+  },
+  {
+    type: "input",
+    label: "资费名称",
+    field: "tariffName",
+    value: "", // 双向绑定的值
+  },
+  {
+    type: "range-picker",
+    label: "更新日期",
+    field: "updatedAt",
+    value: "", // 双向绑定的值
+    width: "240",
+  },
+];

+ 12 - 35
src/views/flowPool/index.vue

@@ -3,30 +3,7 @@
   <div class="container">
     <!-- 搜索条件区 -->
     <div class="search-section">
-      <a-form :model="searchForm" layout="inline">
-        <a-form-item field="label" :label="$t('flowPool.label')">
-          <a-input v-model="searchForm.label" :placeholder="$t('lotCard.please') + $t('flowPool.label')" allow-clear />
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.status')">
-          <a-select v-model="value" :style="{ width: '240px' }" :placeholder="$t('flowPool.flowPoolStatus')">
-            <a-option v-for="item of trafficList" :value="item.id" :label="item.label" />
-          </a-select>
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.operator')">
-          <a-select v-model="value" :style="{ width: '240px' }" :placeholder="$t('flowPool.operatorName')">
-            <a-option v-for="item of sourceList" :value="item.id" :label="item.label" />
-          </a-select>
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.start_time')">
-          <a-date-picker style="width: 200px;" :placeholder="$t('flowPool.start_timeName')" />
-        </a-form-item>
-        <a-form-item>
-          <a-space>
-            <a-button type="primary" @click="handleSearch">{{ $t('form.Search') }}</a-button>
-            <a-button @click="resetSearch">{{ $t('form.Reset') }}</a-button>
-          </a-space>
-        </a-form-item>
-      </a-form>
+      <Search :SearchForm="SearchFormList" @query="intData" @reset="reset"></Search>
     </div>
 
     <div class="audit-btn">
@@ -76,7 +53,7 @@
 
 <script setup>
 import { onMounted, ref, getCurrentInstance, toRefs } from "vue";
-import { columns } from "./config";
+import { columns ,SearchFormList} from "./config";
 import { Message } from '@arco-design/web-vue'
 import {
   deleteTrafficPool,
@@ -90,13 +67,11 @@ import openExport from "./components/openExport.vue"
 import { useI18n } from 'vue-i18n'
 const { t } = useI18n();
 const systemStore = useSystemStore()
+import Search from '@/components/Search/index.vue'
 const state = ref({
   role: systemStore.getRole,
   formRef: null,
-  searchForm: {
-    "label": "",
-    "trafficPoolType": "1"
-  },
+  searchForm: {},
   pagination: {
     total: 0,
     pageSize: 10,
@@ -130,7 +105,10 @@ const {
 } = toRefs(state.value)
 const { proxy } = getCurrentInstance()
 
-const intData = async () => {
+const intData = async (item) => {
+  if(item){
+    searchForm.value = item
+  }
   const param = {
     current: pagination.value.current,
     size: pagination.value.pageSize,
@@ -168,11 +146,10 @@ const evChangePage = (page) => {
   pagination.value.current = page
   intData()
 }
-const handleSearch = () => {
-  intData()
-}
-const resetSearch = () => {
-  searchForm.value.label = ''
+
+const reset = (item) => {
+  searchForm.value = item
+  pagination.value.current = 1
   intData()
 }
 

+ 15 - 62
src/views/flowPool/rearFlowPool/index.vue

@@ -3,55 +3,7 @@
   <div class="container">
     <!-- 搜索条件区 -->
     <div class="search-section">
-      <a-form :model="searchForm" layout="inline">
-        <a-form-item field="label" :label="$t('flowPool.label')">
-          <a-input
-            v-model="searchForm.label"
-            :placeholder="$t('lotCard.please') + $t('flowPool.label')"
-            allow-clear
-          />
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.status')">
-          <a-select
-            v-model="value"
-            :style="{ width: '240px' }"
-            :placeholder="$t('flowPool.flowPoolStatus')"
-          >
-            <a-option
-              v-for="item of trafficList"
-              :value="item.id"
-              :label="item.label"
-            />
-          </a-select>
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.operator')">
-          <a-select
-            v-model="value"
-            :style="{ width: '240px' }"
-            :placeholder="$t('flowPool.operatorName')"
-          >
-            <a-option
-              v-for="item of sourceList"
-              :value="item.id"
-              :label="item.label"
-            />
-          </a-select>
-        </a-form-item>
-        <a-form-item field="label" :label="$t('flowPool.start_time')">
-          <a-date-picker
-            style="width: 200px"
-            :placeholder="$t('flowPool.start_timeName')"
-          />
-        </a-form-item>
-        <a-form-item>
-          <a-space>
-            <a-button type="primary" @click="handleSearch">{{
-              $t("form.Search")
-            }}</a-button>
-            <a-button @click="resetSearch">{{ $t("form.Reset") }}</a-button>
-          </a-space>
-        </a-form-item>
-      </a-form>
+      <Search :SearchForm="SearchFormList" @query="intData" @reset="reset"></Search>
     </div>
 
     <div class="audit-btn">
@@ -68,7 +20,7 @@
     <a-table
       row-key="id"
       :data="dataSource"
-      :columns="columns"
+      :columns="columnsAfter"
       :pagination="pagination"
       :scroll="{ x: 'auto' }"
       @page-change="evChangePage"
@@ -125,7 +77,7 @@
 
 <script setup>
 import { onMounted, reactive, toRefs } from "vue";
-import { columns } from "../config";
+import { columnsAfter,SearchFormList } from "../config";
 import { Message } from "@arco-design/web-vue";
 import { deleteTrafficPool, lotCatdList } from "@/api/path/flowPool.api";
 import { useSystemStore } from "@/store/modules/systemStore";
@@ -133,6 +85,7 @@ import add from "../components/add.vue";
 import Forewarning from "../components/forewarning.vue";
 import { Getdictionary } from "@/mixins/index.js";
 import {useI18n} from 'vue-i18n'
+import Search from '@/components/Search/index.vue'
 const {t} = useI18n();
 const systemStore = useSystemStore();
 const state = reactive({
@@ -142,9 +95,7 @@ const state = reactive({
     pageSize: 10,
     current: 1,
   },
-  searchForm: {
-    label: "",
-  },
+  searchForm: {},
   role: systemStore.getRole,
   typeCurrent: 1,
   visibleForewarning: false,
@@ -169,7 +120,10 @@ const {
   showAdd,
 } = toRefs(state);
 
-const intData = async () => {
+const intData = async (item) => {
+  if(item){
+    searchForm.value = item
+  }
   const param = {
     current: pagination.value.current,
     size: pagination.value.pageSize,
@@ -195,6 +149,7 @@ const intData = async () => {
       Activated: Activated,
       HaveBeenUsed: HaveBeenUsed,
       trafficPoolStatus,
+      size:item.size+'/'+item.sizeType
     };
   });
   pagination.value.total = data.total;
@@ -217,13 +172,11 @@ const evChangePage = (page) => {
   intData();
 };
 
-const handleSearch = () => {
-  intData();
-};
-const resetSearch = () => {
-  searchForm.value.label = "";
-  intData();
-};
+const reset = (item) => {
+  searchForm.value = item
+  pagination.value.current = 1
+  intData()
+}
 
 // 弹框
 const dictShowModel = (type, data) => {

+ 5 - 2
src/views/order/BuyCard/index.vue

@@ -147,7 +147,8 @@ const state = ref({
     id: '',
     endDate: ''
   },
-  SearchForm:{}
+  SearchForm:{},
+  orderTypeStatus:[]
 });
 
 const {
@@ -167,7 +168,8 @@ const {
   formPreing,
   showEndDate,
   formEndDate,
-  SearchForm
+  SearchForm,
+  orderTypeStatus
 } = toRefs(state.value);
 
 const columns = [
@@ -200,6 +202,7 @@ const intData = async (item) => {
   }
   const simTypeList = await Getdictionary('cardType')
   let sourceList = await Getdictionary('source')
+  orderTypeStatus.value = await Getdictionary('orderType')
   purchaseOrderList(param).then(res => {
     tableData.value = (res.data.records || []).map((item, key) => {
       const sourceName = sourceList.find(val => val.value == item.source)?.label

+ 1 - 1
src/views/order/config.js

@@ -10,7 +10,7 @@ export const SearchFormBuyOrder = [
     label: "审核状态",
     field: "moderationStatus",
     options: [], // 默认空,后面会通过字典加载
-    dict: "source",
+    dict: "orderType",
     value: "", // 双向绑定的值
     width: "200",
   },