Skip to content
Snippets Groups Projects
Commit d9704ef3 authored by asmundh's avatar asmundh
Browse files

Fix form-bug

parent 141ef533
No related branches found
No related tags found
No related merge requests found
...@@ -41,7 +41,7 @@ ...@@ -41,7 +41,7 @@
</div> <!-- form-group// --> </div> <!-- form-group// -->
<div class="input-group mb-2"> <div class="input-group mb-2">
<span class="input-group-text"> <i class="fas fa-mobile"></i> </span> <span class="input-group-text"> <i class="fas fa-mobile"></i> </span>
<input class="form-control" name="phone" placeholder="Phone number" type="text" <input class="form-control" name="phone_number" placeholder="Phone number" type="text"
required> required>
</div> <!-- form-group// --> </div> <!-- form-group// -->
<div class="input-group mb-2"> <div class="input-group mb-2">
...@@ -56,7 +56,7 @@ ...@@ -56,7 +56,7 @@
</div> <!-- form-group// --> </div> <!-- form-group// -->
<div class="input-group mb-2"> <div class="input-group mb-2">
<span class="input-group-text"> <i class="fas fa-hotel"></i> </span> <span class="input-group-text"> <i class="fas fa-hotel"></i> </span>
<input class="form-control" name="address" placeholder="Street address" type="text" <input class="form-control" name="street_address" placeholder="Street address" type="text"
required> required>
</div> <!-- form-group// --> </div> <!-- form-group// -->
<div class="d-grid"> <div class="d-grid">
......
...@@ -11,12 +11,12 @@ async function createNewUser(event) { ...@@ -11,12 +11,12 @@ async function createNewUser(event) {
} else { } else {
let body = { let body = {
username: formData.get("username"), username: formData.get("username"),
password: formData.get("password"), password: formData.get("password"),
phone: formData.get("phone"), phone_number: formData.get("phone_number"),
country: formData.get("country"), country: formData.get("country"),
city: formData.get("city"), city: formData.get("city"),
address: formData.get("address") street_address: formData.get("street_address")
}; };
response = await sendRequest("POST", `${HOST}/api/token/`, body); response = await sendRequest("POST", `${HOST}/api/token/`, body);
if (response.ok) { if (response.ok) {
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment