|
|
|
@ -12,7 +12,8 @@ |
|
|
|
|
transform: translate(-50%, -50%); |
|
|
|
|
" |
|
|
|
|
> |
|
|
|
|
<a-button @click="save" type="primary">Primary Button</a-button> |
|
|
|
|
<!-- <a-button @click="save" type="primary">Primary Button</a-button>--> |
|
|
|
|
<th>单位名称</th> |
|
|
|
|
</div> |
|
|
|
|
</th> |
|
|
|
|
<th colspan="3">分年预算</th> |
|
|
|
@ -36,10 +37,19 @@ |
|
|
|
|
</tbody> |
|
|
|
|
</table> |
|
|
|
|
</div> |
|
|
|
|
<div class="button-container"> |
|
|
|
|
<a-button type="primary" @click="save">保存</a-button> |
|
|
|
|
<a-button type="primary" @click="router.back();">返回</a-button> |
|
|
|
|
</div> |
|
|
|
|
</template> |
|
|
|
|
|
|
|
|
|
<script setup> |
|
|
|
|
import {ref,onMounted,computed} from 'vue' |
|
|
|
|
import {useRoute, useRouter} from "vue-router"; |
|
|
|
|
import {saveOrUpdate} from "@/views/projectApplication/project/Project.api"; |
|
|
|
|
|
|
|
|
|
const router = useRouter(); |
|
|
|
|
const route = useRoute(); |
|
|
|
|
// import moment from 'moment'; |
|
|
|
|
const data = ref({ |
|
|
|
|
year1:'', |
|
|
|
@ -55,6 +65,17 @@ onMounted(()=> { |
|
|
|
|
// data.value.year1 = '2025' |
|
|
|
|
|
|
|
|
|
}) |
|
|
|
|
|
|
|
|
|
async function handleSubmit() { |
|
|
|
|
let val = await validate(); |
|
|
|
|
console.log('val----------',JSON.stringify(val)) |
|
|
|
|
// let data = getFieldsValue(); |
|
|
|
|
// let params = Object.assign({}, formData, data); |
|
|
|
|
val.id = route.query.id; |
|
|
|
|
console.log('表单数据', val) |
|
|
|
|
await saveOrUpdate(val, true) |
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
const save = () => { |
|
|
|
|
let params = { |
|
|
|
|
year1:data.value.year1.$y, |
|
|
|
|