New file |
| | |
| | | /** |
| | | * (不建议写成 request.post(xxx),因为这样 post 时,无法 params 与 data 同时传参) |
| | | * |
| | | * 关注项目接口集合 |
| | | */ |
| | | |
| | | import { http } from "@/utils/http"; |
| | | import { baseUrlApi } from "../util"; |
| | | import type { Result, PageResult } from "../types"; |
| | | |
| | | // 供应商收藏或者取消收藏 |
| | | export const addCollection = (data?: object) => { |
| | | return http.request<Result>( |
| | | "post", |
| | | baseUrlApi("/api/suplierTendOrder/addCollection"), |
| | | { |
| | | data |
| | | } |
| | | ); |
| | | }; |
| | | |
| | | // 供应商查询收藏 |
| | | export const pageCollection = (data?: object) => { |
| | | return http.request<PageResult>( |
| | | "post", |
| | | baseUrlApi("/api/suplierTendOrder/pageCollection"), |
| | | { |
| | | data |
| | | } |
| | | ); |
| | | }; |
| | |
| | | /** |
| | | * (不建议写成 request.post(xxx),因为这样 post 时,无法 params 与 data 同时传参) |
| | | * |
| | | * 注册api接口集合 |
| | | * @method login 登录 |
| | | * 项目管理接口集合 |
| | | */ |
| | | |
| | | import { http } from "@/utils/http"; |
| | |
| | | state, |
| | | loading, |
| | | columns, |
| | | CGRcolumns, |
| | | selectedNum, |
| | | dataList, |
| | | onSearch, |
| | |
| | | </el-card> |
| | | <PureTableBar |
| | | title="" |
| | | :columns="nowRole.code == 'CGR' ? CGRcolumns : columns" |
| | | :columns="columns" |
| | | :tableRef="tableRef?.getTableRef()" |
| | | @refresh="onSearch" |
| | | @fullscreen="onFullscreen" |
| | |
| | | :icon="useRenderIcon(EditPen)" |
| | | @click="openDialog('修改', row)" |
| | | /> |
| | | <!-- <el-button |
| | | <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :size="size" |
| | | :icon="useRenderIcon(AddFill)" |
| | | icon="arcticons:one-hand-operation" |
| | | @click="openDialog('新增', { parentId: row.id } as any)" |
| | | > |
| | | 新增 |
| | | </el-button> --> |
| | | /> |
| | | <el-popconfirm |
| | | :title="`是否确认删除项目名称为${row.projectName}的这条数据`" |
| | | @confirm="handleDelete(row)" |
| | |
| | | import dayjs from "dayjs"; |
| | | // import dayjs from "dayjs"; |
| | | import editForm from "../form.vue"; |
| | | import { handleTree } from "@/utils/tree"; |
| | | import { message } from "@/utils/message"; |
| | | import { zhaobiaoPageOrder } from "@/api/item/index"; |
| | | |
| | | import { |
| | | getCaigoufangshiList, |
| | | getHangyepingmuList, |
| | | getOrderStatusList, |
| | | getRegionList, |
| | | getDaimaleixingList, |
| | | caigourenAdd, |
| | | caigourenUpdate, |
| | | caigourenDelete, |
| | | caigourenBatchDelete |
| | | } from "@/api/item/index"; |
| | | import { usePublicHooks } from "../../hooks"; |
| | | import { pageCollection } from "@/api/item/aboutitem"; |
| | | import { addDialog } from "@/components/ReDialog"; |
| | | import { type Ref, reactive, ref, onMounted, h, computed } from "vue"; |
| | | import type { FormItemProps } from "./types"; |
| | | import { |
| | | cloneDeep, |
| | | isAllEmpty, |
| | | deviceDetection, |
| | | getKeyList |
| | | } from "@pureadmin/utils"; |
| | | import { useUserStoreHook } from "@/store/modules/user"; |
| | | import { cloneDeep, deviceDetection, getKeyList } from "@pureadmin/utils"; |
| | | import type { PaginationProps } from "@pureadmin/table"; |
| | | |
| | | const nowRole = computed(() => { |
| | | return useUserStoreHook().nowRole; |
| | | }); |
| | | const selectedNum = ref(0); |
| | | |
| | | export function useDept(tableRef: Ref) { |
| | |
| | | currentPage: 1, |
| | | background: true |
| | | }); |
| | | //获取采购方式 |
| | | const getCaigoufangshiListFun = async () => { |
| | | const res = await getCaigoufangshiList(); |
| | | state.caigoufangshiList = res.result; |
| | | }; |
| | | // //获取采购方式 |
| | | // const getCaigoufangshiListFun = async () => { |
| | | // const res = await getCaigoufangshiList(); |
| | | // state.caigoufangshiList = res.result; |
| | | // }; |
| | | |
| | | //获取行业品目 |
| | | const getHangyepingmuListFun = async () => { |
| | | const res = await getHangyepingmuList(); |
| | | state.hangyepingmuList = res.result; |
| | | }; |
| | | // //获取行业品目 |
| | | // const getHangyepingmuListFun = async () => { |
| | | // const res = await getHangyepingmuList(); |
| | | // state.hangyepingmuList = res.result; |
| | | // }; |
| | | |
| | | //获取项目进度 |
| | | const getOrderStatusListFun = async () => { |
| | | const res = await getOrderStatusList(); |
| | | state.orderStatusList = res.result; |
| | | }; |
| | | // //获取项目进度 |
| | | // const getOrderStatusListFun = async () => { |
| | | // const res = await getOrderStatusList(); |
| | | // state.orderStatusList = res.result; |
| | | // }; |
| | | |
| | | // 获取区域 |
| | | const getRegionListFun = async () => { |
| | | const res = await getRegionList(); |
| | | state.regionList = res.result; |
| | | }; |
| | | // // 获取区域 |
| | | // const getRegionListFun = async () => { |
| | | // const res = await getRegionList(); |
| | | // state.regionList = res.result; |
| | | // }; |
| | | |
| | | // 获取代码类型 |
| | | const getDaimaleixingListFun = async () => { |
| | | const res = await getDaimaleixingList(); |
| | | state.daimaleixingList = res.result; |
| | | }; |
| | | // // 获取代码类型 |
| | | // const getDaimaleixingListFun = async () => { |
| | | // const res = await getDaimaleixingList(); |
| | | // state.daimaleixingList = res.result; |
| | | // }; |
| | | const formRef = ref(); |
| | | const dataList = ref([]); |
| | | const loading = ref(true); |
| | | const { tagStyle } = usePublicHooks(); |
| | | const getOrderStatus = row => { |
| | | const res = state.orderStatusList.find(item => { |
| | | return row.orderStatus == item.status; |
| | |
| | | reserveSelection: true // 数据刷新后保留选项 |
| | | }, |
| | | { |
| | | label: "采购人", |
| | | label: "报名截止时间", |
| | | prop: "caigourenmingcheng", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "项目名称", |
| | | label: "区域", |
| | | prop: "projectName", |
| | | width: 180, |
| | | align: "left" |
| | | }, |
| | | { |
| | | label: "项目进度", |
| | | prop: "orderStatus", |
| | | label: "项目名称", |
| | | prop: "projectName", |
| | | minWidth: 70, |
| | | cellRenderer: ({ row, props }) => getOrderStatus(row) |
| | | }, |
| | | { |
| | | label: "报名费", |
| | | label: "项目编号", |
| | | prop: "baomingfei", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "投标保证金", |
| | | prop: "toubiaobaozhengjin", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "中标供应商", |
| | | prop: "zhongbiaoName", |
| | | minWidth: 180 |
| | | }, |
| | | { |
| | | label: "评审专家", |
| | | prop: "zhuanjiaName", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "质疑", |
| | | prop: "zhiyi", |
| | | minWidth: 100, |
| | | cellRenderer: ({ row, props }) => ( |
| | | <span>{row.status === 1 ? "有" : "无"}</span> |
| | | ) |
| | | }, |
| | | { |
| | | label: "投诉", |
| | | prop: "tousu", |
| | | minWidth: 100, |
| | | cellRenderer: ({ row, props }) => ( |
| | | // <el-tag size={props.size} style={tagStyle.value(row.status)}> |
| | | <span>{row.status === 1 ? "有" : "无"}</span> |
| | | // </el-tag> |
| | | ) |
| | | }, |
| | | { |
| | | label: "操作", |
| | | fixed: "right", |
| | | width: 80, |
| | | slot: "operation" |
| | | } |
| | | ]; |
| | | const CGRcolumns: TableColumnList = [ |
| | | { |
| | | label: "勾选列", // 如果需要表格多选,此处label必须设置 |
| | | type: "selection", |
| | | fixed: "left", |
| | | reserveSelection: true // 数据刷新后保留选项 |
| | | }, |
| | | { |
| | | label: "代理机构", |
| | | prop: "dailijigoumingcheng", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "项目名称", |
| | | prop: "projectName", |
| | | width: 180, |
| | | align: "left" |
| | | }, |
| | | { |
| | | label: "项目进度", |
| | | prop: "orderStatus", |
| | | minWidth: 70, |
| | | cellRenderer: ({ row, props }) => getOrderStatus(row) |
| | | }, |
| | | { |
| | | label: "报名费", |
| | | prop: "baomingfei", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "投标保证金", |
| | | prop: "toubiaobaozhengjin", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "中标供应商", |
| | | label: "开标时间", |
| | | prop: "zhongbiaoName", |
| | | minWidth: 180 |
| | | }, |
| | | { |
| | | label: "评审专家", |
| | | prop: "zhuanjiaName", |
| | | minWidth: 70 |
| | | }, |
| | | { |
| | | label: "质疑", |
| | | prop: "zhiyi", |
| | | minWidth: 100, |
| | | cellRenderer: ({ row, props }) => ( |
| | | <span>{row.status === 1 ? "有" : "无"}</span> |
| | | ) |
| | | }, |
| | | { |
| | | label: "投诉", |
| | | prop: "tousu", |
| | | minWidth: 100, |
| | | cellRenderer: ({ row, props }) => ( |
| | | // <el-tag size={props.size} style={tagStyle.value(row.status)}> |
| | | <span>{row.status === 1 ? "有" : "无"}</span> |
| | | // </el-tag> |
| | | ) |
| | | }, |
| | | { |
| | | label: "操作", |
| | |
| | | }; |
| | | async function onSearch() { |
| | | const obj = cloneDeep(form); |
| | | obj.tousu = obj.tousu.join(""); |
| | | obj.zhiyi = obj.zhiyi.join(""); |
| | | obj.xingzhengquyu = obj.xingzhengquyu ? obj.xingzhengquyu.join("") : ""; |
| | | // obj.tousu = obj.tousu.join(""); |
| | | // obj.zhiyi = obj.zhiyi.join(""); |
| | | // obj.xingzhengquyu = obj.xingzhengquyu ? obj.xingzhengquyu.join("") : ""; |
| | | loading.value = true; |
| | | const { result } = await zhaobiaoPageOrder(obj); // 这里是返回一维数组结构,前端自行处理成树结构,返回格式要求:唯一id加父节点parentId,parentId取父节点id |
| | | const { result } = await pageCollection(obj); // 这里是返回一维数组结构,前端自行处理成树结构,返回格式要求:唯一id加父节点parentId,parentId取父节点id |
| | | const newData = result.items; |
| | | loading.value = false; |
| | | pagination.total = result.total; |
| | |
| | | state, |
| | | loading, |
| | | columns, |
| | | CGRcolumns, |
| | | dataList, |
| | | selectedNum, |
| | | /** 搜索 */ |
New file |
| | |
| | | <script setup lang="ts"> |
| | | import { ref, reactive, onMounted, computed, PropType } from "vue"; |
| | | import { useRenderIcon } from "@/components/ReIcon/src/hooks"; |
| | | import { useDept } from "./utils/hook"; |
| | | import { FormItemProps } from "./utils/types"; |
| | | |
| | | interface Emits { |
| | | (e: "backListPage"): void; |
| | | } |
| | | const emit = defineEmits<Emits>(); |
| | | const props = defineProps({ |
| | | nowInfo: Object as PropType<FormItemProps> |
| | | }); |
| | | import Delete from "~icons/ep/delete"; |
| | | import EditPen from "~icons/ep/edit-pen"; |
| | | import IconParkSolidBack from "~icons/icon-park-solid/back"; |
| | | |
| | | const { |
| | | state, |
| | | loading, |
| | | selectedNum, |
| | | dataList, |
| | | onSearch, |
| | | resetForm, |
| | | openDialog, |
| | | handleDelete, |
| | | handleSelectionChange, |
| | | handleSizeChange, |
| | | handleCurrentChange, |
| | | pagination, |
| | | checkboxAsRadio, |
| | | onSelectionCancel, |
| | | onbatchDel |
| | | } = useDept(ref({})); |
| | | defineOptions({ |
| | | name: "itemdetail" |
| | | }); |
| | | onMounted(() => { |
| | | console.log(props.nowInfo); |
| | | }); |
| | | const backListPage = () => { |
| | | emit("backListPage"); |
| | | }; |
| | | </script> |
| | | |
| | | <template> |
| | | <div> |
| | | <el-card> |
| | | <template v-slot:header> |
| | | <div class="flex justify-between"> |
| | | <div>{{ nowInfo.projectName }}</div> |
| | | <div> |
| | | <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :icon="useRenderIcon(EditPen)" |
| | | @click="openDialog('修改', nowInfo)" |
| | | /> |
| | | <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :icon="useRenderIcon(Delete)" |
| | | @click="openDialog('修改', nowInfo)" |
| | | /> |
| | | <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :icon="useRenderIcon(IconParkSolidBack)" |
| | | @click="backListPage" |
| | | /> |
| | | </div> |
| | | </div> |
| | | </template> |
| | | <div> |
| | | <el-descriptions class="margin-top" :column="3" :size="size" border> |
| | | <el-descriptions-item label="项目编号"> |
| | | {{ nowInfo.projectCode }} |
| | | </el-descriptions-item> |
| | | <el-descriptions-item label="行业品目" |
| | | >18100000000</el-descriptions-item |
| | | > |
| | | <el-descriptions-item label="采购方式"> |
| | | {{ nowInfo.caigoufangshiName }} |
| | | </el-descriptions-item> |
| | | <el-descriptions-item label="联合体投标"> |
| | | {{ nowInfo.lianhetitoubiao }} |
| | | </el-descriptions-item> |
| | | <el-descriptions-item label="Remarks"> |
| | | <el-tag size="small">School</el-tag> |
| | | </el-descriptions-item> |
| | | <el-descriptions-item label="Address" /> |
| | | </el-descriptions> |
| | | </div> |
| | | </el-card> |
| | | </div> |
| | | </template> |
| | | |
| | | <style lang="scss" scoped></style> |
| | |
| | | projectName: "", // 项目名称(必填) |
| | | hangyepinmu: null, // 行业品目(可选) |
| | | caigoufangshi: null, // 采购方式(可选) |
| | | caigoufangshiName: null, |
| | | caigouyusuan: null, // 采购预算(可选) |
| | | dingbiaoguize: null, // 定标规则(可选) |
| | | baomingfei: null, // 报名费(可选) |
| | |
| | | const handleChange = value => { |
| | | console.log(value); |
| | | }; |
| | | const selectChange = value => { |
| | | let obj = state.caigoufangshiList.find(item => { |
| | | return item.value == value; |
| | | }); |
| | | newFormInline.value.caigoufangshiName = obj.label; |
| | | }; |
| | | |
| | | defineExpose({ getRef }); |
| | | onMounted(async () => {}); |
| | | </script> |
| | |
| | | </el-form-item> |
| | | </re-col> |
| | | <re-col :value="6" :xs="24" :sm="24"> |
| | | <el-form-item label="项目编号" prop="projectCode"> |
| | | <el-form-item label="项目编号"> |
| | | <el-input |
| | | v-model="newFormInline.projectCode" |
| | | disabled |
| | | clearable |
| | | placeholder="请输入项目编号" |
| | | /> |
| | |
| | | v-model="newFormInline.caigoufangshi" |
| | | placeholder="请选择采购方式" |
| | | style="width: 240px" |
| | | @change="selectChange" |
| | | > |
| | | <el-option |
| | | v-for="item in state.caigoufangshiList" |
| | |
| | | import EditPen from "~icons/ep/edit-pen"; |
| | | import Refresh from "~icons/ep/refresh"; |
| | | import AddFill from "~icons/ri/add-circle-line"; |
| | | import IonEnterOutline from "~icons/ion/enter-outline"; |
| | | import { useUserStoreHook } from "@/store/modules/user"; |
| | | |
| | | defineOptions({ |
| | | name: "SystemDept" |
| | | }); |
| | | |
| | | import Detail from "./detail.vue"; |
| | | const formRef = ref(); |
| | | const tableRef = ref(); |
| | | |
| | | const isList = ref(true); |
| | | const nowItem = ref({}); |
| | | const { |
| | | form, |
| | | state, |
| | |
| | | const nowRole = computed(() => { |
| | | return useUserStoreHook().nowRole; |
| | | }); |
| | | |
| | | const enterDetail = item => { |
| | | isList.value = false; |
| | | nowItem.value = item; |
| | | }; |
| | | const backListPage = () => { |
| | | isList.value = true; |
| | | }; |
| | | onMounted(() => {}); |
| | | </script> |
| | | |
| | | <template> |
| | | <div class="main"> |
| | | <!-- class="search-form bg-bg_color w-full pl-8 pt-[12px] overflow-auto" --> |
| | | <template v-if="isList"> |
| | | <el-card shadow="hover" :body-style="{ paddingBottom: '0' }"> |
| | | <el-form ref="formRef" :model="form" labelWidth="100"> |
| | | <el-row> |
| | |
| | | start-placeholder="开始日期" |
| | | end-placeholder="结束日期" |
| | | value-format="YYYY-MM-DD HH:mm:ss" |
| | | :default-time="[new Date('1 00:00:00'), new Date('1 23:59:59')]" |
| | | :default-time="[ |
| | | new Date('1 00:00:00'), |
| | | new Date('1 23:59:59') |
| | | ]" |
| | | class="w-[100%]!" |
| | | /> |
| | | <!-- start-placeholder="开始日期" |
| | |
| | | > |
| | | 重置 |
| | | </el-button> --> |
| | | <el-button type="primary" @click="openDialog()"> 新增 </el-button> |
| | | <el-button type="primary" @click="openDialog()"> |
| | | 新增 |
| | | </el-button> |
| | | </el-form-item> |
| | | </el-col> |
| | | </el-row> |
| | |
| | | </div> |
| | | <el-popconfirm title="是否确认删除?" @confirm="onbatchDel"> |
| | | <template #reference> |
| | | <el-button type="danger" text class="mr-1!"> 批量删除 </el-button> |
| | | <el-button type="danger" text class="mr-1!"> |
| | | 批量删除 |
| | | </el-button> |
| | | </template> |
| | | </el-popconfirm> |
| | | </div> |
| | |
| | | @page-current-change="handleCurrentChange" |
| | | > |
| | | <template #operation="{ row }"> |
| | | <el-button |
| | | <!-- <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :size="size" |
| | | :icon="useRenderIcon(EditPen)" |
| | | @click="openDialog('修改', row)" |
| | | /> |
| | | <!-- <el-button |
| | | /> --> |
| | | <el-button |
| | | class="reset-margin" |
| | | link |
| | | type="primary" |
| | | :size="size" |
| | | :icon="useRenderIcon(AddFill)" |
| | | @click="openDialog('新增', { parentId: row.id } as any)" |
| | | > |
| | | 新增 |
| | | </el-button> --> |
| | | <el-popconfirm |
| | | :icon="useRenderIcon(IonEnterOutline)" |
| | | @click="enterDetail(row)" |
| | | /> |
| | | <!-- <el-popconfirm |
| | | :title="`是否确认删除项目名称为${row.projectName}的这条数据`" |
| | | @confirm="handleDelete(row)" |
| | | > |
| | |
| | | :icon="useRenderIcon(Delete)" |
| | | /> |
| | | </template> |
| | | </el-popconfirm> |
| | | </el-popconfirm> --> |
| | | </template> |
| | | </pure-table> |
| | | </template> |
| | | </PureTableBar> |
| | | </template> |
| | | <template v-else> |
| | | <detail :now-info="nowItem" @backListPage="backListPage" /> |
| | | </template> |
| | | </div> |
| | | </template> |
| | | |
| | |
| | | projectName: string; // 项目名称(必填) |
| | | hangyepinmu: any | null; // 行业品目(可选) |
| | | caigoufangshi: any | null; // 采购方式(可选) |
| | | caigoufangshiName: any | null; // 采购方式(可选) |
| | | caigouyusuan: any | null; // 采购预算(可选) |
| | | dingbiaoguize: any | null; // 定标规则(可选) |
| | | baomingfei: any | null; // 报名费(可选) |