处理冲突
This commit is contained in:
		
							
								
								
									
										10
									
								
								app.py
									
									
									
									
									
								
							
							
						
						
									
										10
									
								
								app.py
									
									
									
									
									
								
							@@ -474,10 +474,7 @@ def upload_image():
 | 
				
			|||||||
 | 
					
 | 
				
			||||||
# 确认录入路由
 | 
					# 确认录入路由
 | 
				
			||||||
@app.route('/confirm', methods=['POST'])
 | 
					@app.route('/confirm', methods=['POST'])
 | 
				
			||||||
<<<<<<< HEAD
 | 
					 | 
				
			||||||
@user_or_admin_required
 | 
					@user_or_admin_required
 | 
				
			||||||
=======
 | 
					 | 
				
			||||||
>>>>>>> 30645e46ff2a6ee5c12fd95fb21b7eb4fb51c5f0
 | 
					 | 
				
			||||||
def confirm_data():
 | 
					def confirm_data():
 | 
				
			||||||
    """
 | 
					    """
 | 
				
			||||||
    确认并录入用户编辑后的数据
 | 
					    确认并录入用户编辑后的数据
 | 
				
			||||||
@@ -502,18 +499,11 @@ def confirm_data():
 | 
				
			|||||||
        data_string = json_to_string(edited_data)
 | 
					        data_string = json_to_string(edited_data)
 | 
				
			||||||
        print(f"转换后的数据字符串: {data_string}")
 | 
					        print(f"转换后的数据字符串: {data_string}")
 | 
				
			||||||
        
 | 
					        
 | 
				
			||||||
<<<<<<< HEAD
 | 
					 | 
				
			||||||
        # 构造新的数据结构,只包含data和image字段,并添加用户ID
 | 
					        # 构造新的数据结构,只包含data和image字段,并添加用户ID
 | 
				
			||||||
        processed_data = {
 | 
					        processed_data = {
 | 
				
			||||||
            "data": data_string,
 | 
					            "data": data_string,
 | 
				
			||||||
            "image": image_filename,  # 存储图片文件名
 | 
					            "image": image_filename,  # 存储图片文件名
 | 
				
			||||||
            "user_id": session['user_id']  # 添加用户ID关联
 | 
					            "user_id": session['user_id']  # 添加用户ID关联
 | 
				
			||||||
=======
 | 
					 | 
				
			||||||
        # 构造新的数据结构,只包含data和image字段
 | 
					 | 
				
			||||||
        processed_data = {
 | 
					 | 
				
			||||||
            "data": data_string,
 | 
					 | 
				
			||||||
            "image": image_filename  # 存储图片文件名
 | 
					 | 
				
			||||||
>>>>>>> 30645e46ff2a6ee5c12fd95fb21b7eb4fb51c5f0
 | 
					 | 
				
			||||||
        }
 | 
					        }
 | 
				
			||||||
        print(f"准备存储的数据: {processed_data}")
 | 
					        print(f"准备存储的数据: {processed_data}")
 | 
				
			||||||
        
 | 
					        
 | 
				
			||||||
 
 | 
				
			|||||||
		Reference in New Issue
	
	Block a user