Files
orico-official-website-old/app/usmobile/view/agents/agents.phtml
2024-10-29 14:04:59 +08:00

226 lines
8.4 KiB
PHTML
Executable File
Raw Blame History

This file contains invisible Unicode characters

This file contains invisible Unicode characters that are indistinguishable to humans but may be processed differently by a computer. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
{include file="include/head-seo" /}
{include file="include/head" /}
<script type="text/javascript">
var navID = "1";
</script>
<link rel="stylesheet" type="text/css" href="__PUBLIC__/m_weben/css/app.css?v={:time()}">
</head>
<body>
<div id="content">
<!--头部-->
{include file="include/top" /}
<!-- 详情页 s -->
<div class="cooperapp_bdpage" style="background:#F2F2F2;">
<div class="cooperapp_bd_main" style=";margin-top50px">
<h1 class="cooperapp_t1">To Be Our Distributor</h1>
<p class="cooperapp_s1">Ready to join us?<br /> your details below and our Sales team will get back to you within 2
business days.</p>
<!--内容-->
<div class="bd_ct cooperapp_bd_ct">
<div class="thimg">
<img src="__PUBLIC__/m_weben/images/mcooperation/copperaapp_img1.png" alt="" srcset="" class="cooperapp_bdimg">
</div>
<div class="bd_from">
<div class="theit">
<div class="bditem">
<label class="itlable">Company Name<span class="redtag">*</span></label>
<input type="text" class="form-control itinp companyName" placeholder="Enter your first name">
</div>
</div>
<div class="theit">
<div class="bditem">
<label class="itlable">contact Email <span class="redtag">*</span></label>
<input type="text" class="form-control itinp email" placeholder="Enter your Email">
</div>
</div>
<div class="theit">
<div class="bditem bditem1">
<label class="itlable">Phone Numbe<span class="redtag">*</span></label>
<input type="text" class="form-control itinp phone"
placeholder="This is your placeholder text">
</div>
</div>
<div class="theit">
<div class="bditem">
<label class="itlable">Type of Business<span class="redtag">*</span></label>
<select name="business_type" data-pf-type="FormInput" class="form-control itinp business_type">
<option value="Online Store">Online Store</option>
<option value="Local Shop">Local Shop</option>
<option value="Both">Both</option></select>
</div>
</div>
<div class="theit">
<div class="bditem">
<label class="itlable">Online Shop URL</label>
<input type="text" class="form-control itinp url"
placeholder="This is your placeholder tex">
</div>
</div>
<div class="theit">
<div class="bditem bditem1">
<label class="itlable">Enterprise size<span class="redtag">*</span></label>
<select name="enterprise_size" data-pf-type="FormInput" class="form-control itinp enterprise_size">
<option value="10 Or Less">10 Or Less</option>
<option value="10-50">10-50</option>
<option value="50-199">50-199</option>
<option value="200 Or More">200 Or More</option>
</select>
</div>
</div>
<div class="theit">
<div class="bditem bditem1">
<label class="itlable">company Address<span class="redtag">*</span></label>
<input class="form-control itinp address" placeholder="Enter Address">
</div>
</div>
<div class="theit">
<div class="bditem bditem1">
<label class="itlable">Message<span class="redtag">*</span></label>
<textarea class="ittextarea message" placeholder="Enter your message"></textarea>
</div>
</div>
</div>
</div>
<!-- 提交-->
<div class="bttj">SUBMT</div>
</div>
</div>
<!-- 详情页 e -->
<script>
// 输入框失去焦点
$('.companyName').blur(function(){
if($('.companyName').val() != ''){
$('.companyName').removeClass('error');
$('.companyName').next('span').addClass('hide');
}else{
$('.companyName').addClass('error');
$('.companyName').next('span').removeClass('hide');
}
})
$('.first').blur(function(){
if($('.first').val() != ''){
$('.first').removeClass('error');
$('.first').next('span').addClass('hide');
}else{
$('.first').addClass('error');
$('.first').next('span').removeClass('hide');
}
})
$('.last').blur(function(){
if($('.last').val() != ''){
$('.last').removeClass('error');
$('.last').next('span').addClass('hide');
}else{
$('.last').addClass('error');
$('.last').next('span').removeClass('hide');
}
})
$('.email').blur(function(){
if($('.email').val() != ''){
$('.email').removeClass('error');
$('.email').next('span').addClass('hide');
}else{
$('.email').addClass('error');
$('.email').next('span').removeClass('hide');
}
})
$('.region').blur(function(){
if($('.region').val() != ''){
$('.region').removeClass('error');
$('.region').next('span').addClass('hide');
}else{
$('.region').addClass('error');
$('.region').next('span').removeClass('hide');
}
})
// 提交表单
$('.submit_btn').click(function(){
var companyName = $('.companyName').val();
var firstName = $('.first').val();
var lastName = $('.last').val();
var email = $('.email').val();
var region = $('.region').val();
var checkItem = new Array();
   
    $("input[name='interested']:checked").each(function() {
        checkItem.push($(this).val());// 在数组中追加元素
    });
var interesteds = checkItem.join(",");
var inventory = $("input[name='inventory']:checked").val();
if(companyName == ''){
$('.companyName').addClass('error');
$('.companyName').next('span').removeClass('hide');
}
if(firstName == ''){
$('.first').addClass('error');
$('.first').next('span').removeClass('hide');
}
if(lastName == ''){
$('.last').addClass('error');
$('.last').next('span').removeClass('hide');
}
if(email == ''){
$('.email').addClass('error');
$('.email').next('span').removeClass('hide');
}
if(region == ''){
$('.region').addClass('error');
$('.region').next('span').removeClass('hide');
}
try {
k_win_ref = window.parent.document.referrer;
} catch(e) {
k_win_ref = '';
};
//点击创建申请块
if(companyName && firstName && lastName && email && region) {
var type = 'Agent';
$.ajax({
type: "POST",
url: "create",
data: {'company':companyName, 'email':email,'country':region,'name':firstName,'last_name':lastName,'phone':$('.phone').val(),'interested':interesteds,'is_inventory':inventory,'uri':$('.url').val(),'refer':k_win_ref},
dataType: "json",
success: function(data){
if(data.code == 200) {
//alert(data.msg);
//window.location.href='/us/agents/agents.html';
location.href = '/us/Group/submission.html';
}
else{
if(data.code == 403 || data.code == 201) {
alert(data.msg);
}
else{
$('.email').addClass('error');
$('.email').next('span').removeClass('hide');
}
}
}
});
}
})
</script>
<!-- bottom s -->
{include file="include/bottom" /}
<!-- bottom e -->
</body>
</html>