Commit 688c5b6b by LJM

企业专享

parent 40f3e398
......@@ -5,10 +5,28 @@
color: #fff;
}
.bg {
height: 455rpx;
background: url('https://static.ichunt.com/dist/res/home/images/dome/bg1.png') no-repeat center;
background-size: cover;
position: relative;
width: 100%;
height: 544rpx;
margin-bottom: 20rpx;
.pic {
width: 100%;
height: 544rpx;
display: block;
}
.btn {
position: absolute;
top: 50%;
left: 0;
right: 0;
width: 220rpx;
height: 68rpx;
margin: 0 auto;
border-radius: 6rpx;
border: 2rpx solid #ffffff;
font-size: 24rpx;
color: #fff;
}
}
.section {
position: relative;
......@@ -113,7 +131,7 @@
box-sizing: border-box;
flex-wrap: wrap;
.pic {
width: 144rpx;
width: 120rpx;
height: 81rpx;
overflow: hidden;
margin-bottom: 16rpx;
......
......@@ -35,6 +35,11 @@
border-radius: 6rpx;
font-size: 24rpx;
color: #292b33;
transition: all 0.4s ease;
&.curr {
color: #ffffff;
background-color: #1969f9;
}
}
}
.textarea-box {
......
......@@ -246,7 +246,7 @@
}
},
{
"path": "pages/mine/enterprise",
"path": "pages/mine/exclusive",
"style": {
"navigationBarTitleText": "企业专享"
}
......
......@@ -5,49 +5,39 @@
<view style="text-align: right;" @click="open()"><text class="iconfont icon-juxing5"></text></view>
</template>
</navElement>
<view class="bg"></view>
<view class="bg row">
<image :src="detail.h5_domestic_head_image[0].images" mode="aspectFill" class="pic"></image>
<navigator class="btn row rowCenter verCenter" :url="'/s?k=' + detail.h5_domestic_sku_name[0].title">立即体验</navigator>
</view>
<view class="section">
<view class="brand">
<view class="uni-swiper-wrap">
<swiper class="swiper" circular :indicator-dots="indicatorDots" :autoplay="autoplay" :interval="interval" :duration="duration">
<swiper-item>
<view class="head-box row bothSide verCenter">
<view class="left row verCenter">
<image mode="aspectFill" src="https://img.ichunt.com/images/ichunt/202305/27/58c2e7a3d42ed265a2c763bf704d807a.jpg" lazy-load="true" class="pic"></image>
<text class="t1">Analog Devices</text>
</view>
<view class="right row verCenter">
<text class="t1">详情</text>
<text class="iconfont icon-jt"></text>
</view>
</view>
<view class="text-desc">Analog Devices以追求创新、品质和卓越为使命,是一家历史悠久,成长迅速的技术公司。Analog Devices的客户逾10万家,产品涵盖几乎所有电子设备类型,是业内公认的数公司。Analog Devices的客户逾10万家,产品涵盖几乎所有电子设备类型,是业内公认的数</view>
</swiper-item>
<swiper-item>
<swiper-item v-for="(item, index) in detail.h5_domestic_cooperate_brand" :key="index">
<view class="head-box row bothSide verCenter">
<view class="left row verCenter">
<image mode="aspectFill" src="https://img.ichunt.com/images/ichunt/202305/27/58c2e7a3d42ed265a2c763bf704d807a.jpg" lazy-load="true" class="pic"></image>
<text class="t1">dsdwde2s</text>
<image mode="aspectFill" :src="item.brand_logo" lazy-load="true" class="pic"></image>
<text class="t1">{{ item.brand_name }}</text>
</view>
<view class="right row verCenter">
<text class="t1">详情</text>
<text class="iconfont icon-jt"></text>
</view>
</view>
<view class="text-desc">Analog Devices以追求创新、品质和卓越为使命,是一家历史悠久,成长迅速的技术公司。Analog Devices的客户逾10万家,产品涵盖几乎所有电子设备类型,是业内公认的数公司。Analog Devices的客户逾10万家,产品涵盖几乎所有电子设备类型,是业内公认的数</view>
<view class="text-desc">{{ item.brand_brief }}</view>
</swiper-item>
</swiper>
</view>
</view>
<view class="faebtn row avarage">
<view class="box column rowCenter verCenter">
<navigator class="box column rowCenter verCenter" url="/s">
<image src="../../static/a1.png" class="pic"></image>
<text class="tt">数字化选型</text>
</view>
<view class="box column rowCenter verCenter">
</navigator>
<navigator class="box column rowCenter verCenter" url="/fae">
<image src="../../static/a2.png" class="pic"></image>
<text class="tt">FAE技术支持</text>
</view>
</navigator>
<view class="box column rowCenter verCenter">
<image src="../../static/a3.png" class="pic"></image>
<text class="tt">样品服务</text>
......@@ -100,7 +90,6 @@ export default {
},
data() {
return {
ad: ['https://img.ichunt.com/images/ichunt/202305/27/58c2e7a3d42ed265a2c763bf704d807a.jpg', 'https://img.ichunt.com/images/ichunt/202305/27/2ddce4486082a8b825f3026fe3e715aa.jpg'],
searchParams: {},
indicatorDots: true,
autoplay: true,
......
......@@ -68,13 +68,10 @@ export default {
com_name: '',
linkman: '',
mobile: '',
email: '',
com_nature: '',
business_license_src: ''
email: ''
}
};
},
onShow() {},
methods: {
open() {
this.$refs.popup.open('center');
......@@ -86,6 +83,9 @@ export default {
window.location.reload();
},
submit() {
var reg = /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/;
var email_reg = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
if (!this.formParams.com_name) {
uni.showToast({
title: '请填写公司名称',
......@@ -107,6 +107,13 @@ export default {
});
return false;
}
if (!reg.test(this.formParams.mobile)) {
uni.showToast({
title: '手机格式错误',
icon: 'none'
});
return false;
}
if (!this.formParams.email) {
uni.showToast({
title: '请填写邮箱',
......@@ -114,17 +121,14 @@ export default {
});
return false;
}
if (!this.formParams.com_nature) {
if (!email_reg.test(this.formParams.email)) {
uni.showToast({
title: '请选择公司性质',
title: '邮箱格式错误',
icon: 'none'
});
return false;
}
this.formParams.business_license_src = this.image_list[0];
this.request(Api_Url + '/help/help/addCreditApply', 'POST', this.formParams, true, true).then(res => {
this.request(Api_Url + '/help/help/addCompanyApply', 'POST', this.formParams, true, true).then(res => {
if (res.err_code === 0) {
this.open();
} else {
......
......@@ -8,28 +8,28 @@
<text class="required">*</text>
<text class="name">姓名:</text>
</view>
<view class="input-box"><input type="text" placeholder="请输入姓名" class="uni-input" /></view>
<view class="input-box"><input type="text" placeholder="请输入姓名" class="uni-input" v-model="formParams.name" /></view>
</view>
<view class="box">
<view class="label-box">
<text class="required">*</text>
<text class="name">手机号:</text>
</view>
<view class="input-box"><input type="text" placeholder="请输入手机号" class="uni-input" /></view>
<view class="input-box"><input type="text" placeholder="请输入手机号" class="uni-input" v-model="formParams.mobile" /></view>
</view>
<view class="box">
<view class="label-box">
<text class="required">*</text>
<text class="name">公司名:</text>
</view>
<view class="input-box"><input type="text" placeholder="请输入公司名" class="uni-input" /></view>
<view class="input-box"><input type="text" placeholder="请输入公司名" class="uni-input" v-model="formParams.company_name" /></view>
</view>
<view class="box">
<view class="label-box">
<text class="required">*</text>
<text class="name">邮箱:</text>
</view>
<view class="input-box"><input type="text" placeholder="请输入邮箱" class="uni-input" /></view>
<view class="input-box"><input type="text" placeholder="请输入邮箱" class="uni-input" v-model="formParams.email" /></view>
</view>
</view>
<view class="title row verCenter">项目信息</view>
......@@ -40,9 +40,7 @@
<text class="name">项目阶段</text>
</view>
<view class="tab row avarage">
<view class="tab-box row rowCenter verCenter">设计研发</view>
<view class="tab-box row rowCenter verCenter">小批量试产</view>
<view class="tab-box row rowCenter verCenter">已量产</view>
<view class="tab-box row rowCenter verCenter" v-for="(item, index) in project_stage" :key="index" :class="{ curr: index == project_stage_index }" @click="tab(index, 1)">{{ item }}</view>
</view>
</view>
<view class="box">
......@@ -51,9 +49,7 @@
<text class="name">申请理由</text>
</view>
<view class="tab row avarage">
<view class="tab-box row rowCenter verCenter">压缩成本</view>
<view class="tab-box row rowCenter verCenter">停产料替代</view>
<view class="tab-box row rowCenter verCenter">进口交期长</view>
<view class="tab-box row rowCenter verCenter" v-for="(item, index) in apply_reason" :key="index" :class="{ curr: index == apply_reason_index }" @click="tab(index, 2)">{{ item }}</view>
</view>
</view>
<view class="box">
......@@ -61,10 +57,10 @@
<text class="required">*</text>
<text class="name">需求描述:</text>
</view>
<view class="textarea-box row"><textarea class="uni-textarea" placeholder="请输入需求描述"></textarea></view>
<view class="textarea-box row"><textarea class="uni-textarea" placeholder="请输入需求描述" v-model="formParams.detail"></textarea></view>
</view>
</view>
<view class="btn row rowCenter verCenter"><view class="btn1 row rowCenter verCenter">提交</view></view>
<view class="btn row rowCenter verCenter"><view class="btn1 row rowCenter verCenter" @click="submit()">提交</view></view>
</view>
</template>
......@@ -77,14 +73,119 @@ export default {
navElement
},
data() {
return {};
},
onLoad(options) {},
onShow() {
this.getData();
return {
project_stage_index: -1,
project_stage: ['设计研发', '小批量试产', '已量产'],
apply_reason_index: -1,
apply_reason: ['压缩成本', '停产料替代', '进口交期长'],
formParams: {
name: '',
mobile: '',
company_name: '',
email: '',
project_stage: '',
apply_reason: '',
detail: ''
}
};
},
methods: {
getData() {}
tab(index, type) {
if (type == 1) {
this.project_stage_index = index;
this.formParams.project_stage = this.project_stage[index];
} else if (type == 2) {
this.apply_reason_index = index;
this.formParams.apply_reason = this.apply_reason[index];
}
},
submit() {
var reg = /^1(3[0-9]|4[01456879]|5[0-35-9]|6[2567]|7[0-8]|8[0-9]|9[0-35-9])\d{8}$/;
var email_reg = /^[^\s@]+@[^\s@]+\.[^\s@]+$/;
if (!this.formParams.name) {
uni.showToast({
title: '请输入姓名',
icon: 'none'
});
return false;
}
if (!this.formParams.mobile) {
uni.showToast({
title: '请输入手机号',
icon: 'none'
});
return false;
}
if (!reg.test(this.formParams.mobile)) {
uni.showToast({
title: '手机格式错误',
icon: 'none'
});
return false;
}
if (!this.formParams.company_name) {
uni.showToast({
title: '请输入公司姓名',
icon: 'none'
});
return false;
}
if (!this.formParams.email) {
uni.showToast({
title: '请输入邮箱',
icon: 'none'
});
return false;
}
if (!email_reg.test(this.formParams.email)) {
uni.showToast({
title: '邮箱格式错误',
icon: 'none'
});
return false;
}
if (!this.formParams.project_stage) {
uni.showToast({
title: '请选择项目阶段',
icon: 'none'
});
return false;
}
if (!this.formParams.apply_reason) {
uni.showToast({
title: '请选择申请理由',
icon: 'none'
});
return false;
}
if (!this.formParams.detail) {
uni.showToast({
title: '请输入需求描述',
icon: 'none'
});
return false;
}
this.request(Api_Url + '/help/help/add_fae_apply', 'POST', this.formParams, true, true).then(res => {
if (res.err_code === 0) {
uni.showToast({
title: res.err_msg,
icon: 'success'
});
setTimeout(() => {
uni.navigateBack({
delta: 1
});
}, 2000);
} else {
uni.showToast({
title: res.err_msg,
icon: 'none'
});
}
});
}
}
};
</script>
......
......@@ -77,7 +77,7 @@ const router = new Router({
aliasPath: '/order/confirm',
meta: {
title: '确认订单',
auth: true
auth: true
}
},
{
......@@ -331,8 +331,8 @@ const router = new Router({
}
},
{
path: '/pages/mine/enterprise',
aliasPath: '/enterprise',
path: '/pages/mine/exclusive',
aliasPath: '/exclusive',
meta: {
title: '企业专享',
auth: false
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment