## 預創建項目
填寫項目前,需要使用`預創建項目`接口來預創建項目。如果有未提交的草稿項目,這個接口會返回草稿項目內容,需要根據草稿內容來填充頁面上的表單。
~~~[api:auth]
post:/CompetitionProject/preCreate
int:id#項目ID(用于審核不通過的項目獲取編輯數據)
*int:competition_id=2#賽事ID
<<<
success
{
"code": 0,
"msg": "項目預創建成功",
"data": {
"user_id": 10001,
"competition_id": "2",
"competition_area_id": "1",
"name": "",
"company_name": "",
"principal": "",
"contact": "",
"email": "",
"city_id": null,
"team_type": "",
"competition_groups": "",
"competition_scopes": "",
"start_date": null,
"end_date": null,
"summary": "",
"other_patent": "",
"keywords": "",
"introduction": "",
"team_introduction": "",
"market_analysis": "",
"awards": "",
"remark": "",
"file1": "",
"file2": "",
"file3": "",
"file4": "",
"file5": "",
"file6": "",
"status": 99,
"create_time": "2021-07-23 17:09:21",
"update_time": "2021-07-23 17:09:21",
"id": "4",
"members": [],
"progress": [],
"patent": []
}
}
<<<
success
{
"code": 0,
"msg": "預創建項目加載成功",
"data": {
"id": 9,
"user_id": 10001,
"competition_id": 2,
"competition_area_id": 1,
"name": "第二屆率先杯",
"company_name": "123",
"principal": "123",
"contact": "123123123",
"email": "1513515131@qq.com",
"city_id": 27822,
"team_type": "員工組(僅限中科院系統員工勾選)",
"competition_groups": "創意暢享組",
"competition_scopes": "智能無人平臺技術",
"start_date": "2021-08-06",
"end_date": "2021-09-17",
"summary": "111111",
"other_patent": "",
"keywords": "1111",
"introduction": "<p>1111</p>\n",
"team_introduction": "11111111111111111",
"market_analysis": "111",
"awards": "111",
"remark": "11111",
"file1": "https://cas-doc-file.makercas.com/10001/project-9/f7ac352761befc1f3d5cb6dccea6c468.pdf",
"file2": "https://cas-doc-file.makercas.com/10001/project-9/c109983774e59a73fd27aa779845e504.pptx",
"file3": "https://cas-doc-file.makercas.com/10001/project-9/380962b6e87d501eee22b1a5e2b5748b.docx",
"file4": "https://cas-doc-file.makercas.com/10001/project-9/380962b6e87d501eee22b1a5e2b5748b.docx",
"file5": "https://cas-doc-file.makercas.com/10001/project-9/f7ac352761befc1f3d5cb6dccea6c468.pdf",
"file6": "",
"status": 2,
"audit_remark": "測試",
"update_time": "2021-08-04 15:57:10",
"create_time": "2021-08-03 12:01:21",
"members": [
{
"id": 26,
"user_id": 10001,
"competition_id": 2,
"competition_project_id": 9,
"name": "11",
"age": 12,
"phone": "15813702116",
"email": "1513515131@qq.com",
"education": "博士",
"position": "12",
"work": "121",
"employer": "2121",
"update_time": "2021-08-04 14:57:27",
"delete_time": "0000-00-00 00:00:00"
},
{
"id": 27,
"user_id": 10001,
"competition_id": 2,
"competition_project_id": 9,
"name": "2121",
"age": 2121,
"phone": "15813702116",
"email": "1513515131@qq.com",
"education": "初中",
"position": "項目負責人",
"work": "11",
"employer": "11",
"update_time": "2021-08-04 14:57:27",
"delete_time": "0000-00-00 00:00:00"
}
],
"progress": [
{
"id": 14,
"user_id": 10001,
"competition_id": 2,
"competition_project_id": 9,
"start_date": "2021-08-18",
"end_date": "2021-09-14",
"content": "1111",
"update_time": "2021-08-04 14:58:10",
"create_time": "2021-08-04 14:58:10"
}
],
"patent": [
{
"id": 14,
"user_id": 10001,
"competition_id": 2,
"competition_project_id": 9,
"type": "發明型專利",
"username": "1",
"name": "11",
"sn": "1111111",
"update_time": "2021-08-04 15:17:22",
"create_time": "2021-08-04 15:17:22"
}
],
"city": {
"id": 27822,
"name": "韶關市",
"city_id": 27631,
"province": {
"id": 27631,
"city_id": 0,
"name": "廣東省",
"level": 1,
"code": 44,
"sort": 50,
"create_time": "2021-07-21 16:48:05"
}
}
}
}
<<<
error
{
"code": 400,
"msg": "數據校驗不通過",
"error": {
"competition_id": "賽事不存在",
"competition_area_id": "賽事賽區ID必須是整數"
}
}
~~~
## 字段列表
參閱 [獲取項目數據](%E8%8E%B7%E5%8F%96%E9%A1%B9%E7%9B%AE%E6%95%B0%E6%8D%AE.md) 的獲取字段列表
## 更新記錄
### 2021-09-29
刪除`recommended_by`基本情況-推薦單位字段