功态科技类型 11.13

master
zhc077 2 weeks ago
parent 384da30d5b
commit 5f8b822b8f
  1. 2
      jeecgboot-vue3/src/views/projectApplication/kejigongguan/data.ts
  2. 19
      jeecgboot-vue3/src/views/projectApplication/kejigongguan/projectApplicationList.vue
  3. 48
      jeecgboot-vue3/src/views/projectApplication/project/ProjectList.vue
  4. 3
      jeecgboot-vue3/src/views/projectType/ProjectType.api.ts

@ -14,7 +14,7 @@ export const projectBaseInfoSchemas: FormSchema[] = [
}, },
dynamicDisabled: true, dynamicDisabled: true,
// defaultValue: '', // defaultValue: '',
defaultValue: '1846744340708184065', // defaultValue: '1846744340708184065',
}, },
{ {
field: 'annualId', field: 'annualId',

@ -18,20 +18,21 @@
</template> </template>
<script lang="ts"> <script lang="ts">
import { BasicForm, useForm } from '@/components/Form'; import { BasicForm, useForm } from '@/components/Form';
import {defineComponent, ref} from 'vue'; import {defineComponent, ref,nextTick,onMounted} from 'vue';
import { PageWrapper } from '@/components/Page'; import { PageWrapper } from '@/components/Page';
import { projectBaseInfoSchemas, userSchemas, departSchemas } from './data'; import { projectBaseInfoSchemas, userSchemas, departSchemas } from './data';
import { Card } from 'ant-design-vue'; import { Card } from 'ant-design-vue';
import {defHttp} from "@/utils/http/axios"; import {defHttp} from "@/utils/http/axios";
import {save4shenbao} from './data.api'; import {save4shenbao} from './data.api';
import { useRouter } from 'vue-router'; import { useRouter, useRoute } from 'vue-router';
export default defineComponent({ export default defineComponent({
name: 'FormHightPage', name: 'FormHightPage',
components: { BasicForm, PageWrapper, [Card.name]: Card }, components: { BasicForm, PageWrapper, [Card.name]: Card },
setup() { setup() {
const route = useRoute();
const { currentRoute, back } = useRouter(); const { currentRoute, back } = useRouter();
const [registerProjectInfo, { validate: validateProjectInfoForm }] = useForm({ const [registerProjectInfo, { validate: validateProjectInfoForm, setFieldsValue }] = useForm({
baseColProps: { baseColProps: {
span: 6, span: 6,
}, },
@ -40,7 +41,13 @@
schemas: projectBaseInfoSchemas, schemas: projectBaseInfoSchemas,
showActionButtonGroup: false, showActionButtonGroup: false,
}); });
const setformValue1 = async () => {
// console.log(route,'route')
await setFieldsValue({projectTypeid: route.query.projectTypeId})
};
nextTick(() => {
setformValue1();
});
const [registerUser, { validate: validateUserForm }] = useForm({ const [registerUser, { validate: validateUserForm }] = useForm({
baseColProps: { baseColProps: {
span: 6, span: 6,
@ -77,11 +84,9 @@
back(); back();
}; };
function getUserDepart(){
projectBaseInfoSchemas.se
}
return { registerProjectInfo, registerUser, registerDepart, submitAll, goBack }; return { registerProjectInfo, registerUser, registerDepart, submitAll, goBack };
}, },
}); });
</script> </script>
<style lang="less" scoped> <style lang="less" scoped>

@ -10,26 +10,16 @@
<!-- <j-upload-button type="primary" v-auth="'project:project:importExcel'" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>--> <!-- <j-upload-button type="primary" v-auth="'project:project:importExcel'" preIcon="ant-design:import-outlined" @click="onImportXls">导入</j-upload-button>-->
<a-dropdown> <a-dropdown>
<template #overlay> <template #overlay>
<a-menu> <a-menu @click="go_xinjianshenbao">
<a-menu-item key="1" @click="go_xinjianshenbao"> <a-menu-item v-for="opt of projectTypeList" :key="opt.key">
<Icon icon="ant-design:plus-outlined"></Icon>
科技攻关
</a-menu-item>
<!-- <a-menu-item v-for="opt of RANGE_OPTIONS" :key="opt.key">
{{ opt.label }} {{ opt.label }}
</a-menu-item>--> </a-menu-item>
<!--<a-menu-item key="1" @click="go_xinjianshenbao">
<Icon icon="ant-design:plus-outlined"></Icon>
xxx
</a-menu-item>-->
</a-menu> </a-menu>
</template> </template>
<a-button type="primary">新建申报 <a-button type="primary">新建申报
<Icon icon="mdi:chevron-down"></Icon> <Icon icon="mdi:chevron-down"></Icon>
</a-button> </a-button>
</a-dropdown> </a-dropdown>
<!-- 高级查询
<super-query :config="superQueryConfig" @search="handleSuperQuery" />-->
</template> </template>
<!--操作栏--> <!--操作栏-->
<template #action="{ record }"> <template #action="{ record }">
@ -59,14 +49,16 @@ import {columns, searchFormSchema, superQuerySchema} from './Project.data';
batchDelete, batchDelete,
getImportUrl, getImportUrl,
getExportUrl, getExportUrl,
getProjectTypeList
} from './Project.api'; } from './Project.api';
import {getProjectTypeList} from '../../projectType/ProjectType.api';
import { downloadFile } from '/@/utils/common/renderUtils'; import { downloadFile } from '/@/utils/common/renderUtils';
import { useGo } from '/@/hooks/web/usePage'; import { useGo } from '/@/hooks/web/usePage';
import { useUserStore } from '/@/store/modules/user'; import { useUserStore } from '/@/store/modules/user';
import {getUserData} from "@/views/system/usersetting/UserSetting.api"; import {getUserData} from "@/views/system/usersetting/UserSetting.api";
import {useTimeoutFn} from "@/hooks/core/useTimeout"; import {useTimeoutFn} from "@/hooks/core/useTimeout";
import {departList4Quxian} from "@/api/sys/user";
const go = useGo(); const go = useGo();
const queryParam = reactive<any>({}); const queryParam = reactive<any>({});
@ -110,8 +102,7 @@ const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({
}) })
// //
// /*const projectTypeList = [
const RANGE_OPTIONS = [
{key: 'TODAY', label: '今天'}, {key: 'TODAY', label: '今天'},
{key: 'YESTERDAY', label: '昨天'}, {key: 'YESTERDAY', label: '昨天'},
{key: 'TOMORROW', label: '明天'}, {key: 'TOMORROW', label: '明天'},
@ -122,13 +113,16 @@ const { prefixCls,tableContext,onExportXls,onImportXls } = useListPage({
{key: 'THIS_MONTH', label: '本月'}, {key: 'THIS_MONTH', label: '本月'},
{key: 'LAST_MONTH', label: '上月'}, {key: 'LAST_MONTH', label: '上月'},
{key: 'NEXT_MONTH', label: '下月'}, {key: 'NEXT_MONTH', label: '下月'},
]; ];*/
const projectTypeList =ref([]);
const [registerTable, {reload},{ rowSelection, selectedRowKeys }] = tableContext const [registerTable, {reload},{ rowSelection, selectedRowKeys }] = tableContext
// //
const superQueryConfig = reactive(superQuerySchema); const superQueryConfig = reactive(superQuerySchema);
getProjectType();
/** /**
* 高级查询事件 * 高级查询事件
*/ */
@ -149,9 +143,10 @@ function handleAdd() {
} }
// //
function go_xinjianshenbao() { function go_xinjianshenbao(event: Recordable) {
// go('/comp/jeecg/basic'); // alert("id: "+event.key)
go('/projectApplication/index?projectTypeId='+'1846744340708184065'); //
go('/projectApplication/index?projectTypeId='+event.key);
} }
// //
@ -171,7 +166,20 @@ function go_projectLog(record) {
go('/projectLog/projectLogList?id='+record.id); go('/projectLog/projectLogList?id='+record.id);
} }
async function getProjectType(){
let params = {
status: '1',
};
await getProjectTypeList(params).then(res=>{
console.log("getProjectType is invoke-----------",JSON.stringify(res.records))
projectTypeList.value = res.records.map(item => {
return {label:item.typeName,key:item.id}
})
console.log(JSON.stringify(projectTypeList));
})
}
/** /**
* 编辑事件 * 编辑事件

@ -31,6 +31,9 @@ export const getImportUrl = Api.importExcel;
*/ */
export const list = (params) => defHttp.get({ url: Api.list, params }); export const list = (params) => defHttp.get({ url: Api.list, params });
// export const getProjectTypeList = (params) => defHttp.get({ url: Api.getProjectTypeList, params });
export const getProjectTypeList = (params) => defHttp.get({ url: Api.list, params });
/** /**
* 删除单个 * 删除单个
* @param params * @param params

Loading…
Cancel
Save