提交 fc0bea3d authored 作者: 黄旭新's avatar 黄旭新

xin

......@@ -8,6 +8,15 @@
</view>
</view>
<!-- 搜索框end -->
<!-- 我的企业tab栏start -->
<view class="MyBusiness_tab">
<view :class="{'border_bottom': tabIndex ==1}" @click="tabClick(1)">邀请的企业</view>
<view :class="{'border_bottom': tabIndex ==2}" @click="tabClick(2)">签订的企业</view>
<view :class="{'border_bottom': tabIndex ==3}" @click="tabClick(3)">接单的企业</view>
<view :class="{'border_bottom': tabIndex ==4}" @click="tabClick(4)">委托的企业</view>
<view :class="{'border_bottom': tabIndex ==5}" @click="tabClick(5)">存量的企业</view>
</view>
<!-- 我的企业tab栏end -->
<!-- 统计start -->
<view class="lable">
<view class="lable_block">
......@@ -55,9 +64,11 @@
<view class="hexian"></view>
<!-- <view class="list_button" v-if="item.type=='现货分成'" @click="cashDivide(1)">现货分成</view> -->
<view class="list_button" v-if="item.spotPackageIncomeRatio" @click="clickRatio(index)">现货分成</view>
<view class="list_button" v-if="item.isAuthenticate == 2" @click="look(item.enterpriseId)">查看详情</view>
<view class="list_button" v-if="item.isAuthenticate == 2" @click="look(item.enterpriseId)">查看详情
</view>
<view class="list_button" @click="relation(item.phone)">联系企业</view>
<view class="list_button" v-if="item.isAuthenticate != 2" @click="remindAuthenticate(item.enterpriseId)">提醒他认证</view>
<view class="list_button" v-if="item.isAuthenticate != 2"
@click="remindAuthenticate(item.enterpriseId)">提醒他认证</view>
</view>
</view>
</scroll-view>
......@@ -90,7 +101,7 @@
</view>
</view>
<!-- 弹窗end -->
<bottomWindow @closeModel='closeModel' v-if="isshare" :type="1"/>
<bottomWindow @closeModel='closeModel' v-if="isshare" :type="1" />
</view>
</template>
......@@ -124,6 +135,7 @@
},
data() {
return {
tabIndex: 1, // tab栏索引
enterpriseName: '', //搜索内容
electricId: '', //电客id
EnterpriseNumber: '0', //企业数量
......@@ -138,44 +150,48 @@
}
},
methods: {
// tab栏索引
tabClick(i) {
this.tabIndex = i
},
//邀请企业
inviteclick(){
let that=this
if(this.isAuthenticate!=2){
inviteclick() {
let that = this
if (this.isAuthenticate != 2) {
uni.showToast({
title:'您还未通过实名认证',
icon:'none'
title: '您还未通过实名认证',
icon: 'none'
})
let natime=setTimeout(function(){
let natime = setTimeout(function() {
uni.navigateTo({
url:'../Certification/Certification'
url: '../Certification/Certification'
})
clearTimeout(natime)
},1000)
}, 1000)
return false
}else{
that.isshare=true
} else {
that.isshare = true
}
},
//分享
onShareAppMessage(res) {
let inviteCode=uni.getStorageSync('user').inviteCode
let name=uni.getStorageSync('user').certificationName
return {
title:name+'邀请您绑定成为他的用电企业会员',
path: '/pages/login/login?inviteType=3&&inviteCode='+inviteCode,//分享的页面路径
imageUrl:'../../static/images/index/group.png',
// content: '邀请您绑定成为他的用电企业会员',
desc: '电客',
success:(res) => {
console.log('111111')
console.log(res)
},
fail:(err) => {
console.log('222222')
console.log(err)
}
let inviteCode = uni.getStorageSync('user').inviteCode
let name = uni.getStorageSync('user').certificationName
return {
title: name + '邀请您绑定成为他的用电企业会员',
path: '/pages/login/login?inviteType=3&&inviteCode=' + inviteCode, //分享的页面路径
imageUrl: '../../static/images/index/group.png',
// content: '邀请您绑定成为他的用电企业会员',
desc: '电客',
success: (res) => {
console.log('111111')
console.log(res)
},
fail: (err) => {
console.log('222222')
console.log(err)
}
}
},
closeModel(e) {
if (e == 'closeModel') {
......@@ -378,7 +394,7 @@
width: 100%;
padding: 23rpx 32rpx;
background-color: #fff;
margin-bottom: 32rpx;
margin-bottom: 16rpx;
.search_box {
width: 100%;
......@@ -415,6 +431,22 @@
}
}
// 我的企业tab栏
.MyBusiness_tab {
display: flex;
justify-content: space-around;
view {
font-size: 22rpx;
height: 60rpx;
}
.border_bottom {
border-bottom: 2rpx solid #1989fa;
}
}
// 邀请按钮
.button_box {
display: flex;
justify-content: center;
......
......@@ -229,7 +229,7 @@
<!-- 邮箱 -->
<view class="item_common">
<view class="title">邮箱</view>
<input type="number" v-model="phone" placeholder="请输入" disabled/>
<input type="number" v-model="phone" placeholder="请输入" disabled />
<view class="border_bottom"></view>
</view>
<!-- 所属行业 -->
......@@ -294,7 +294,7 @@
<!-- 详细地址 -->
<view class="item_common">
<view class="title">详细地址</view>
<input type="number" v-model="address" placeholder="请输入" disabled/>
<input type="number" v-model="address" placeholder="请输入" disabled />
<view class="border_bottom"></view>
</view>
<!-- 营业执照 -->
......@@ -784,10 +784,20 @@
valleyElectricity: this.valleyElectricity,
electricityBill: this.electricityBill
}
uni.setStorageSync('enterpriseInfo', obj)
uni.navigateTo({
url: '/pagesA/takePhoto/takePhoto'
get(api.verifiedBefore, obj).then(res => {
if (res.code == 200) {
uni.setStorageSync('enterpriseInfo', obj)
uni.navigateTo({
url: '/pagesA/takePhoto/takePhoto'
})
} else {
uni.showToast({
title: res.msg,
icon: 'none'
})
}
})
// this.isClick = false
// post(api.enterpriseVerified, {
// id: this.id,
......
......@@ -405,7 +405,7 @@
name: '开具合同',
others: '',
image:'https://fire.huoshitou.net/profile/icon/jslxd.png',
url: '/pagesA/Contracts/LssueContracts/LssueContracts'
url: '/pagesA/Contracts/LssueContracts/LssueContracts?template=1'
},
{
id: 5,
......
......@@ -3,13 +3,19 @@
<!-- 合同类型切换 -->
<view class="ContractTab">
<view class="ContractTab_child" @click="tabContract(1)">
<text :class="{'active':ContractType==1}">线下合同</text>
<text :class="{'active':ContractType==1}">邀请的企业</text>
</view>
<view class="ContractTab_child" @click="tabContract(2)">
<text :class="{'active':ContractType==2}">平台合同</text>
<text :class="{'active':ContractType==2}">签订的企业</text>
</view>
<view class="ContractTab_child" @click="tabContract(3)">
<text :class="{'active':ContractType==3}">存量合同</text>
<text :class="{'active':ContractType==3}">接单的企业</text>
</view>
<view class="ContractTab_child" @click="tabContract(4)">
<text :class="{'active':ContractType==4}">委托的企业</text>
</view>
<view class="ContractTab_child" @click="tabContract(5)">
<text :class="{'active':ContractType==5}">存量企业</text>
</view>
<view class="hexian"></view>
</view>
......@@ -22,7 +28,7 @@
</view>
</view>
<!-- 合同类型tab栏start -->
<view class="ContractType_title" v-if="ContractType == 1">
<view class="ContractType_title" v-if="ContractType == 2">
<view :class="{'title_active': tabIndex == 6 }" @click="checkType(6)">未生效</view>
<view :class="{'title_active': tabIndex == 2 }" @click="checkType(2)">审核通过</view>
<view :class="{'title_active': tabIndex == 7 }" @click="checkType(7)">已生效</view>
......@@ -207,7 +213,7 @@
<!-- 合同内容-存量合同end -->
<!-- 开具合同start -->
<view class="button_box" v-if="ContractType == 1">
<view class="button_box" v-if="ContractType == 2">
<view class="button_block" @click="creat">
<view>开具合同</view>
</view>
......@@ -727,7 +733,7 @@
flex: 1;
height: 100%;
text-align: center;
font-size: 30rpx;
font-size: 22rpx;
color: #999;
line-height: 95rpx;
......
......@@ -45,14 +45,22 @@
<image src="../../../static/images/right.png" mode=""></image>
</picker>
</view>
<view class="LssueContracts_accessory" v-if="onTemplate">
<view class="LssueContracts_accessory_title">合同附件(请上传照片或者PDF文件)</view>
<view class="LssueContracts_accessory_imgs">
<image v-for="(item,index) in imgList" :src="item" :key="index"></image>
<view class="pdf_box" v-if="pdFurl" @click="slectImage">上传成功</view>
<image v-if="onUpload" src="../../../static/images/upload_bg.png" @click="slectImage"></image>
</view>
</view>
</view>
<view v-if="flag" class="LssueContracts_btn" @click="submit">
保存
</view>
<view v-else class="addContracts_btn">
保存合同中
<view :class="['LssueContracts_btn',{'active_btn': onSubmint},{'btn_marginTop': !onTemplate}]">
<view v-if="onSubmint">保存合同中</view>
<view v-if="!onTemplate" @click="openContract">下载合同</view>
<view v-else @click="submit">保存</view>
</view>
</view>
</template>
......@@ -66,6 +74,9 @@
onLoad(options) {
let that = this
that.contractId = options.id
if (options.template) {
this.onTemplate = false
}
// 售电公司列表
get(api.electricitySalesCompaniesList).then(res => {
if (res.code == 200) {
......@@ -100,12 +111,16 @@
contractStartTime: '', //合同开始时间
contractEndTime: '', //合同结束时间
electricId: '', //电客id
flag: true,
typeValue: '', //合同类型名称
typeOptions: ['固定价差', '月竞分成'], //合同类型
companyValue: '', //乙方公司(售电公司)
companys: '', //后台返回的售电公司列表
companyOptions: [], //处理后的售电公司列表
pdFurl: '', // 上传pdf
imgList: [], // 上传照片
onUpload: true, // 是否出现上传图片
onTemplate: true, // 是否为开具合同
onSubmint: false, // 是否正在上传
}
},
computed: {
......@@ -125,7 +140,7 @@
let year = new Date().getFullYear() + 10
return year + '-12-31'
}
},
methods: {
//数据回显
......@@ -205,6 +220,49 @@
this.contractEndTime = e.detail.value + '/12/31'
}
},
// 下载合同
openContract(){
console.log('下载合同')
},
// 上传合同附件
slectImage() {
let that = this;
wx.chooseMessageFile({
count: 1,
type: 'all',
// sizeType: ['original', 'compressed'], //可以指定是原图还是压缩图,默认二者都有
success: function(res) {
uni.showLoading({
title: '上传中'
})
// console.log(res)
const tempFilePaths = res.tempFiles
// console.log(tempFilePaths)
uni.uploadFile({
url: api.uploadFile, //接口地址
filePath: tempFilePaths[0].path,
name: 'file',
success: function(res) {
let url = JSON.parse(res.data).url
if (url.lastIndexOf('.pdf') > -1) {
that.pdFurl = url
// console.log(that.pdFurl)
that.imgList = []
// that.onUpload = true
} else {
// that.isImage = true
that.imgList.push(url)
if (that.imgList.length > 5) {
that.onUpload = false
}
that.pdFurl = ''
}
uni.hideLoading()
}
})
}
});
},
// 保存合同
submit() {
let {
......@@ -237,7 +295,7 @@
return
}
}
this.flag = false
this.onSubmint = true
if (this.contractId) {
// 如果有合同id就是编辑合同
get(api.exitContract, {
......@@ -330,7 +388,7 @@
position: relative;
padding-top: 32rpx;
width: 100%;
min-height: 100%;
height: auto;
background-color: #f4f5f7;
.LssueContracts_box {
......@@ -379,14 +437,51 @@
}
}
}
.LssueContracts_accessory {
padding-bottom: 16rpx;
width: 100%;
height: auto;
font-size: 34rpx;
color: #333;
.LssueContracts_accessory_title {
height: 110rpx;
line-height: 110rpx;
}
.LssueContracts_accessory_imgs {
display: flex;
flex-wrap: wrap;
width: 100%;
height: auto;
.pdf_box {
display: flex;
justify-content: center;
align-items: center;
margin-bottom: 10rpx;
margin-right: 10rpx;
width: 180rpx;
height: 180rpx;
background-color: #ccc;
border: 1rpx solid #999;
}
image {
width: 180rpx;
height: 180rpx;
margin-bottom: 10rpx;
margin-right: 10rpx;
}
}
}
}
.LssueContracts_btn {
position: absolute;
left: 50%;
bottom: 100rpx;
transform: translate(-50%, 0);
width: 622rpx;
margin: 64rpx 0;
margin-left: 32rpx;
width: 686rpx;
height: 104rpx;
line-height: 104rpx;
text-align: center;
......@@ -397,20 +492,12 @@
border-radius: 16rpx;
}
.addContracts_btn {
position: absolute;
left: 50%;
bottom: 100rpx;
transform: translate(-50%, 0);
width: 622rpx;
height: 104rpx;
line-height: 104rpx;
text-align: center;
font-size: 30rpx;
font-weight: 700;
color: #fff;
.active_btn {
background-color: #ccc;
border-radius: 16rpx;
}
.btn_marginTop {
margin-top: 360rpx;
}
}
</style>
......@@ -29,6 +29,7 @@
export default {
onLoad(options) {
this.contractId = options.id
},
data() {
return {
......@@ -36,6 +37,7 @@
pdFurl: '', // pdf文件
imgList: [], //图片
onUpload: true, // 是否出现上传图片
}
},
methods: {
......@@ -101,13 +103,15 @@
that.pdFurl = url
console.log(that.pdFurl)
that.onUpload = false
// that.onUpload = false
that.imgList = []
} else {
// that.isImage = true
that.imgList.push(url)
if (that.imgList.length > 5) {
that.onUpload = false
}
that.pdFurl = ''
}
}
......
......@@ -142,5 +142,5 @@ erp.uploadCourierDetail = HOST + 'common/uploadCourierDetail' // 查看上传快
erp.electricitySalesCompanies = HOST + 'common/electricitySalesCompanies' // 入驻公司列表
erp.companyProfile = HOST + 'common/companyProfile' // 入驻公司公司简介
erp.companyPackageList = HOST + 'common/companyPackageList' // 售电公司详情---拼团套餐
erp.verifiedBefore = HOST + 'enterprise/verifiedBefore' // 企业认证提交前校验接口
export default erp;
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论