合并
This commit is contained in:
@ -181,7 +181,7 @@ const dialogRecord = reactive<DialogOption>({
|
||||
|
||||
const initFormData: ContractorMaterialForm = {
|
||||
id: undefined,
|
||||
projectId: currentProject.value.id,
|
||||
projectId: currentProject.value?.id,
|
||||
contractorId: undefined,
|
||||
materialName: undefined,
|
||||
materialType: undefined,
|
||||
@ -195,7 +195,7 @@ const data = reactive<PageData<ContractorMaterialForm, ContractorMaterialQuery>>
|
||||
queryParams: {
|
||||
pageNum: 1,
|
||||
pageSize: 10,
|
||||
projectId: currentProject.value.id,
|
||||
projectId: currentProject.value?.id,
|
||||
contractorId: undefined,
|
||||
materialName: undefined,
|
||||
materialType: undefined,
|
||||
@ -215,7 +215,7 @@ const getSubList = async () => {
|
||||
const res = await listContractor({
|
||||
pageNum: 1,
|
||||
pageSize: 10000,
|
||||
projectId: currentProject.value.id
|
||||
projectId: currentProject.value?.id
|
||||
});
|
||||
contractorList.value = res.rows;
|
||||
handleQuery();
|
||||
@ -307,7 +307,7 @@ const handleDelete = async (row?: ContractorMaterialVO) => {
|
||||
|
||||
//监听项目id刷新数据
|
||||
const listeningProject = watch(
|
||||
() => currentProject.value.id,
|
||||
() => currentProject.value?.id,
|
||||
(nid, oid) => {
|
||||
queryParams.value.projectId = nid;
|
||||
form.value.projectId = nid;
|
||||
|
Reference in New Issue
Block a user