mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/izyim-api.git
synced 2026-08-19 04:24:01 +00:00
205 lines
9.9 KiB
HTML
205 lines
9.9 KiB
HTML
<html>
|
|
<head>
|
|
<title>AzureUI - Term</title>
|
|
<meta charset="UTF-8">
|
|
<meta name="viewport" content="width=device-width, initial-scale=1">
|
|
<link rel="stylesheet" href="https://maxcdn.bootstrapcdn.com/bootstrap/4.1.0/css/bootstrap.min.css">
|
|
<link href="https://fonts.googleapis.com/css?family=Nunito:300,400,600,700,900" rel="stylesheet">
|
|
<link rel="stylesheet" type="text/css" href="css/font-awesome.min.css" />
|
|
<link rel="stylesheet" type="text/css" href="css/global.style.css" />
|
|
<style>
|
|
.header {
|
|
width:relative;
|
|
margin: 0 auto;
|
|
height: 30px;
|
|
}
|
|
|
|
#backbtn {
|
|
padding: 20px;
|
|
float:left;
|
|
}
|
|
|
|
#heading {
|
|
float:right;
|
|
padding: 20px;
|
|
clear: right;
|
|
}
|
|
</style>
|
|
</head>
|
|
<body>
|
|
<!-- Header area start-->
|
|
<div class="header">
|
|
<div id="backbtn">
|
|
<a class="go-back-linkC"><i class="fa fa-arrow-left"></i></a>
|
|
</div>
|
|
|
|
<div id="heading">
|
|
<h1 class="page-title" style="color: #000">Company Profile</h1>
|
|
</div>
|
|
</div>
|
|
|
|
<!-- Header area end -->
|
|
<!-- Main Content Start Here -->
|
|
<div class="container">
|
|
<main class="fix-top-menu">
|
|
<section class="container">
|
|
<!--company profile
|
|
<form>
|
|
<div class="form-row txt-center">
|
|
<div class="profile-image">
|
|
<div class="profile-image-com">
|
|
<img id="CompanyProfile" class="avatar-img" src="images/CIEF.png" width="80" height="80" />
|
|
<label class="update-btn fix">
|
|
<input id="CompanyUpload" type="file" style="display:none" />
|
|
<i class="fa fa-camera"></i>
|
|
</label>
|
|
</div>
|
|
</div>
|
|
</div>
|
|
</form>
|
|
-->
|
|
|
|
<br>
|
|
<form>
|
|
|
|
<div class="form-row txt-center">
|
|
<b>Please upload the registration certificate.</b>
|
|
<label class="update-btn fix">
|
|
<div class="form-row txt-center">
|
|
<input id="reg_cert" type="file" />
|
|
<div class="form-divider"></div>
|
|
<a href="#" id="regCert" style="width:50%; margin-left:25%;" class="button block green">Upload</a>
|
|
</div>
|
|
</label>
|
|
</div>
|
|
|
|
</form>
|
|
|
|
<div class="form-divider"></div>
|
|
|
|
<div class="alert alert-danger" id="alert" role="alert" style="display: none"></div>
|
|
<div class="alert alert-success" id="alert1" role="alert1" style="display: none"></div>
|
|
|
|
<br>
|
|
|
|
<div class="form-label-divider">
|
|
<span class="label-span">Company Information</span>
|
|
</div>
|
|
|
|
<div class="form-divider"></div>
|
|
<div class="alert alert-danger" id="alert2" role="alert2" style="display: none"></div>
|
|
|
|
<form>
|
|
<div class="form-row-group">
|
|
<div class="form-row no-padding">
|
|
<input id="company-name" type="text" class="form-element" placeholder="Company Name" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="registration-no" type="text" class="form-element" placeholder="Registration No" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="tax-no" type="text" class="form-element" placeholder="Tax No" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="tel-no" type="text" class="form-element" placeholder="Tel No" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="fax" type="text" class="form-element" placeholder="Fax" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="address" type="text" class="form-element" placeholder="Address" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="city" type="text" class="form-element" placeholder="City" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="postcode" type="text" class="form-element" placeholder="Postcode" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="state" type="text" class="form-element" placeholder="State" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="country" type="text" class="form-element" placeholder="Country" required />
|
|
</div>
|
|
<div class="form-row no-padding">
|
|
<input id="contact-person" type="text" class="form-element" placeholder="Contact Person" required />
|
|
</div>
|
|
</div>
|
|
|
|
<div class="form-divider"></div>
|
|
|
|
<div class="form-row txt-center">
|
|
<a href="#" id="companyDetails" style="width:50%; margin-left:25%;" class="button block green">Submit</a>
|
|
</div>
|
|
</form>
|
|
</section>
|
|
</main>
|
|
</div>
|
|
<!-- Main Content End Here -->
|
|
|
|
<script src="https://ajax.googleapis.com/ajax/libs/jquery/3.3.1/jquery.min.js"></script>
|
|
<script src="https://stackpath.bootstrapcdn.com/bootstrap/4.1.0/js/bootstrap.min.js" integrity="sha384-uefMccjFJAIv6A+rW+L4AHf99KvxDjWSu1z9VI8SKNVmz4sk7buKt/6v9KI65qnm" crossorigin="anonymous"></script>
|
|
<script src="https://cdnjs.cloudflare.com/ajax/libs/popper.js/1.14.0/umd/popper.min.js" integrity="sha384-cs/chFZiN24E4KMATLdqdvsezGxaGsi4hLGOzlXwp5UZB1LY//20VyM2taTB4QvJ" crossorigin="anonymous"></script>
|
|
<script type="text/javascript">
|
|
$(document).ready(function() {
|
|
$('#regCert').click(function() {
|
|
var fd = new FormData();
|
|
var files = $('#reg_cert')[0].files[0];
|
|
fd.append('reg_cert',files);
|
|
$.ajax({
|
|
type: "POST",
|
|
url: "api/company/reg_cert/",
|
|
headers: {"Authorization": 'Bearer' + localStorage.getItem('token')},
|
|
data:fd,
|
|
contentType: false,
|
|
cache: false,
|
|
processData: false,
|
|
success: function(data) {
|
|
document.getElementById("alert").style.display = "none";
|
|
console.log(data.message);
|
|
$('#alert1').html(data.message);
|
|
$('#alert1').show();
|
|
},
|
|
error: function(data) {
|
|
console.log(data);
|
|
document.getElementById("alert1").style.display = "none";
|
|
$('#alert').html(data.responseJSON.error);
|
|
$('#alert').show();
|
|
}
|
|
});
|
|
})
|
|
|
|
$('#companyDetails').click(function() {
|
|
$.ajax({
|
|
type: "PATCH",
|
|
url: "api/company",
|
|
headers: {"Authorization": 'Bearer' + localStorage.getItem('token')},
|
|
data: {
|
|
company_name: $('#company-name').val(),
|
|
registration_no: $('#registration-no').val(),
|
|
tax_no: $('#tax-no').val(),
|
|
tel_no: $('#tel-no').val(),
|
|
fax: $('#fax').val(),
|
|
address: $('#address').val(),
|
|
city: $('#city').val(),
|
|
postcode: $('#postcode').val(),
|
|
state: $('#state').val(),
|
|
country: $('#country').val(),
|
|
contact_person: $('#contact-person').val()
|
|
},
|
|
success: function(data) {
|
|
//alert("success");
|
|
document.location.href="home.html";
|
|
},
|
|
error: function(data) {
|
|
//console.log(data);
|
|
$('#alert2').html(data.responseJSON.error);
|
|
$('#alert2').show();
|
|
}
|
|
});
|
|
})
|
|
})
|
|
</script>
|
|
|
|
</body>
|
|
</html> |