|
@@ -10,9 +10,9 @@
|
|
|
|
|
|
<script setup>
|
|
<script setup>
|
|
import { ref, watch } from 'vue'
|
|
import { ref, watch } from 'vue'
|
|
-import mainApi from '~api/project/project'
|
|
|
|
import { getObjValue, isNullES } from 'js-fast-way'
|
|
import { getObjValue, isNullES } from 'js-fast-way'
|
|
import { getDictionaryData } from '~uti/tools'
|
|
import { getDictionaryData } from '~uti/tools'
|
|
|
|
+import mainApi from '~api/project/contract'
|
|
|
|
|
|
const props = defineProps({
|
|
const props = defineProps({
|
|
data: {
|
|
data: {
|
|
@@ -43,16 +43,14 @@ watch(isShow, (val) => {
|
|
//处理相关数据
|
|
//处理相关数据
|
|
const tabsKey = ref('1')
|
|
const tabsKey = ref('1')
|
|
const tabsData = ref([])
|
|
const tabsData = ref([])
|
|
-const basicForm = ref({ pid: '' })
|
|
|
|
const getDataApi = async () => {
|
|
const getDataApi = async () => {
|
|
- const { pid, cid, type, tab } = getObjValue(dataInfo.value)
|
|
|
|
|
|
+ const { cid, type, tab } = getObjValue(dataInfo.value)
|
|
if (isNullES(cid)) {
|
|
if (isNullES(cid)) {
|
|
tabsData.value = [{ key: '1', name: '合同段信息' }]
|
|
tabsData.value = [{ key: '1', name: '合同段信息' }]
|
|
} else {
|
|
} else {
|
|
tabsData.value = [{ key: '1', name: '合同段信息' }, { key: '2', name: '分配WBS' }, { key: '3', name: '分配项目人员' }]
|
|
tabsData.value = [{ key: '1', name: '合同段信息' }, { key: '2', name: '分配WBS' }, { key: '3', name: '分配项目人员' }]
|
|
}
|
|
}
|
|
await getContractTypeList()
|
|
await getContractTypeList()
|
|
- basicForm.value = { pid: pid }
|
|
|
|
if (!isNullES(cid)) {
|
|
if (!isNullES(cid)) {
|
|
if ([1, 4, 8].includes(type)) {
|
|
if ([1, 4, 8].includes(type)) {
|
|
await getContractInfo()
|
|
await getContractInfo()
|
|
@@ -72,7 +70,7 @@ const getDataApi = async () => {
|
|
|
|
|
|
//获取项目详情
|
|
//获取项目详情
|
|
const getProjectDeatil = async () => {
|
|
const getProjectDeatil = async () => {
|
|
-
|
|
|
|
|
|
+ //mainApi
|
|
}
|
|
}
|
|
|
|
|
|
//获取合同类型
|
|
//获取合同类型
|
|
@@ -82,8 +80,13 @@ const getContractTypeList = async () => {
|
|
}
|
|
}
|
|
|
|
|
|
//获取合同段基本信息
|
|
//获取合同段基本信息
|
|
|
|
+const contractForm = ref({})
|
|
const getContractInfo = async () => {
|
|
const getContractInfo = async () => {
|
|
-
|
|
|
|
|
|
+ const { cid } = getObjValue(dataInfo.value)
|
|
|
|
+ contractForm.value = {}
|
|
|
|
+ if (isNullES(cid)) return
|
|
|
|
+ const { data } = await mainApi.detail(cid)
|
|
|
|
+ contractForm.value = getObjValue(data)
|
|
}
|
|
}
|
|
|
|
|
|
//获取合同段基本信息
|
|
//获取合同段基本信息
|