Cài đặt thành công tính năng người dùng đầu tiên phải đăng ký tài khoản để quản lí

This commit is contained in:
2026-06-13 17:45:49 +07:00
parent 6913bbae48
commit ee5a5b6800
10 changed files with 21 additions and 12 deletions
+2 -1
View File
@@ -19,7 +19,8 @@ export const SignupPage = ({ onBack, onSuccess }) => {
}
setIsLoading(true);
try {
const response = await fetch('http://localhost:3001/api/v1/auth/signup', {
const API_BASE = `http://${window.location.hostname}:3001`;
const response = await fetch(`${API_BASE}/api/v1/auth/signup`, {
method: 'POST',
headers: { 'Content-Type': 'application/json' },
body: JSON.stringify({