Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- $('#Controller')
- .on('click',
- '#SaveProfile',
- function() {
- debugger;
- var CertificateInstitutions =
- JSON.parse(localStorage.getItem("CertificateInstitutionsListLocal"));
- var CertificateUniverSitys =
- JSON.parse(localStorage.getItem("CertificateUniverSitysListLocal"));
- var ExternalProjects =
- JSON.parse(localStorage.getItem("ExProjectListLocal"));
- var soical = {
- GithubId: $('#GithubId').val(),
- StackowerflowId: $('#StackowerflowId').val(),
- TweiterId: $('#TweiterId').val()
- }
- var SkillList = $('select.tagit-hiddenSelect :selected')
- .map(function() {
- return this.value;
- })
- .get();
- var form = $('#CreateProfileForm');
- var token = $('input[name="__RequestVerificationToken"]', form).val();
- var file_data = $("#Image").prop("files")[0];
- var fd = new FormData();
- fd.append("isFirst", true);
- fd.append("token", token);
- fd.append("image", file_data);
- fd.append("soical", soical);
- fd.append("SkillList", SkillList);
- fd.append("ExternalProjects",ExternalProjects);
- fd.append("CertificateUniverSitys", CertificateUniverSitys);
- fd.append("CertificateInstitutions", CertificateInstitutions);
- $.ajax({
- url: '@postUrl',
- method: "POST",
- contentType: false,
- processData: false,
- data: fd
- });
- });
- public virtual async Task<ActionResult> CreatePrfile(CreateFreelancerProfileViewModel viewModel, bool isFirst, HttpPostedFileBase image)
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement