Browse Source

修改参数

duy 1 year ago
parent
commit
0865fb8ed1

+ 14 - 12
src/views/transfer/components/conclusion/table-opinion.vue

@@ -21,10 +21,7 @@ const props = defineProps({
         type: [String, Number],
         default: '',
     },
-    currentId:{
-        type: [String, Number],
-        default: '',
-    },
+
 
 })
 
@@ -33,19 +30,24 @@ const emit = defineEmits(['opinionTap'])
 //变量
 const projectId = ref(props.projectId)
 const contractId = ref(props.contractId)
-const currentId = ref(props.currentId)
+const currentId = ref('')
 
 //渲染完成
-onMounted(() => {
+onMounted(async () => {
+    await getCurrentIdData()
     getTableData()
 })
+const getCurrentIdData = async ()=>{
+    const { error, code, data } = await initialgApi.getCurrentId({
+            projectId: projectId.value,
+    })
+        if (!error && code === 200) {
+            currentId.value = data
+        } else {
+            currentId.value = ''
+        }
+}
 
-//监听
-watch(() => [
-props.currentId,
-], ([cuId]) => {
-    currentId.value = cuId
-})
 //表格数据
 const tableColumn = ref([
     { key:'expertName', name: '专家', width: 80 },

+ 1 - 1
src/views/transfer/writing-conclusion.vue

@@ -76,7 +76,7 @@
 </template>
 
 <script setup>
-import { onMounted, ref } from 'vue'
+import { onActivated, onMounted, ref } from 'vue'
 import { useAppStore } from '~src/store'
 import { useRouter } from 'vue-router'
 import TableStats from './components/conclusion/table-stats.vue'