创建创新券

master
JayChou 2 weeks ago
parent 2ce6dcacb2
commit 21d7669c8d
  1. 9
      jeecgboot-vue3/src/router/helper/mainOut.ts
  2. 59
      jeecgboot-vue3/src/views/demo/main-home/components/innovationVouchers/index.vue
  3. 29
      jeecgboot-vue3/src/views/demo/main-home/components/instrumentSharing/index.vue

@ -100,6 +100,15 @@ export const mainOutRoutes: AppRouteModule[] = [
ignoreAuth: true,
},
},
{
path: '/main-home/innovationVouchers',
name: 'InnovationVouchers',
component: () => import('/@/views/demo/main-home/components/innovationVouchers/index.vue'),
meta: {
title: '创新券',
ignoreAuth: true,
},
},
],
},
];

@ -0,0 +1,59 @@
<template>
<div class="container">
<a-table :dataSource="indexaward" :columns="columns" >
<template v-if="columns.Key === 'setting'">
<div>
111
</div>
</template>
</a-table>
</div>
</template>
<script setup>
import { ref } from 'vue';
const columns = [
{
title: '申报项目名称',
dataIndex: 'proName',
key: 'proName',
},
{
title: '申报类别',
dataIndex: 'state_dictText',
key: 'state_dictText',
},
{
title: '申请金额',
dataIndex: 'proMoney',
key: 'proMoney',
},
{
title: '创新券编码',
dataIndex: 'cxqCode',
key: 'cxqCode',
},
{
title: '操作',
dataIndex: '',
key: 'setting',
},
];
const indexaward = ref([]);
const getindexawardEvent = async () => {
console.log(111);
fetch(import.meta.env.VITE_GLOB_API_URL_CXQ + '/innovationvoucher/innovationVoucher/listcms')
.then((res) => res.json())
.then((res) => (indexaward.value = res.result.records));
};
getindexawardEvent();
</script>
<style scoped lang="less">
.container {
width: 1200px;
margin: 0 auto;
}
</style>

@ -23,7 +23,9 @@
<div class="item">
<div class="left">仪器分类:</div>
<div class="right">
<div :class="indexclassIndex === index ? 'avtive' : ''" @click="onIndexclass(i,index)" v-for="(i,index) in indexclass" :key="i.id">{{ i.instruName }}</div>
<div :class="indexclassIndex === index ? 'avtive' : ''" @click="onIndexclass(i, index)" v-for="(i, index) in indexclass" :key="i.id">{{
i.instruName
}}</div>
</div>
</div>
</div>
@ -91,10 +93,11 @@
<script setup lang="ts">
import { ref } from 'vue';
import { getindexcomp, getindexsubject, getindexclass,getindexaward } from '@/api/mainHome/index';
import { getindexcomp, getindexsubject, getindexclass, getindexaward } from '@/api/mainHome/index';
import { Pagination } from 'ant-design-vue';
import { useRouter } from 'vue-router';
import axios from 'axios'
import axios from 'axios';
const router = useRouter();
const current = ref(1);
const total = ref(0);
@ -107,10 +110,10 @@
});
const indexcomplist = ref<any>([]);
const getindexcompEvent = async () => {
const data =page.value
const data = page.value;
for (const key in data) {
if (!page.value[key]) {
delete data[key]
delete data[key];
}
}
const res: any = await getindexcomp(data);
@ -155,20 +158,19 @@
page.value.type = data.id;
indexclassIndex.value = index;
getindexcompEvent();
}
};
//
const onBooking = () => {
router.push('/instrument/InstrumentList')
}
router.push('/instrument/InstrumentList');
};
//
const getindexawardEvent = async () => {
axios.get(import.meta.env.VITE_GLOB_API_URL_CXQ + '/innovationvoucher/innovationVoucher/listcms').then(res => {
axios.get(import.meta.env.VITE_GLOB_API_URL_CXQ + '/innovationvoucher/innovationVoucher/listcms').then((res) => {
console.log(res);
})
}
getindexawardEvent()
});
};
getindexawardEvent();
</script>
<style scoped lang="less">
@ -275,7 +277,6 @@
border: 1px solid #002e97;
color: #002e97;
cursor: pointer;
}
}
}

Loading…
Cancel
Save