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

xin

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