mirror of
https://gitlab.com/CIEFWorldwideSdnBhd/izyim-api.git
synced 2026-08-19 04:24:01 +00:00
update company profile frontend
This commit is contained in:
@@ -67,7 +67,7 @@
|
||||
<div class="form-row txt-center">
|
||||
<input id="reg_cert" type="file" />
|
||||
<div class="form-divider"></div>
|
||||
<a href="#" style="width:50%; margin-left:25%;" class="button block green">Upload</a>
|
||||
<a href="#" id="regCert" style="width:50%; margin-left:25%;" class="button block green">Upload</a>
|
||||
</div>
|
||||
</label>
|
||||
</div>
|
||||
@@ -122,12 +122,61 @@
|
||||
<div class="form-divider"></div>
|
||||
|
||||
<div class="form-row txt-center">
|
||||
<a href="#" style="width:50%; margin-left:25%;" class="button block green">Submit</a>
|
||||
<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 type="text/javascript">
|
||||
$(document).ready(function() {
|
||||
$('#regCert').click(function() {
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "api/company/reg_cert/5",
|
||||
data: {
|
||||
file:new FormData(this),
|
||||
},
|
||||
contentType: false,
|
||||
cache: false,
|
||||
processData: false,
|
||||
success: function(data) {
|
||||
alert("success");
|
||||
},
|
||||
error: function() {
|
||||
alert("Login Failed");}
|
||||
});
|
||||
})
|
||||
|
||||
$('#companyDetails').click(function() {
|
||||
$.ajax({
|
||||
type: "POST",
|
||||
url: "api/company",
|
||||
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");
|
||||
},
|
||||
error: function() {
|
||||
alert("Login Failed");}
|
||||
});
|
||||
})
|
||||
})
|
||||
</script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
Reference in New Issue
Block a user