页面优化
This commit is contained in:
parent
3f5d1d021b
commit
0621d6b735
1
app.json
1
app.json
@ -21,6 +21,7 @@
|
|||||||
"navigationBarBackgroundColor": "#ffffff"
|
"navigationBarBackgroundColor": "#ffffff"
|
||||||
},
|
},
|
||||||
"tabBar": {
|
"tabBar": {
|
||||||
|
"custom": true,
|
||||||
"color": "#515151",
|
"color": "#515151",
|
||||||
"selectedColor": "#FE9944",
|
"selectedColor": "#FE9944",
|
||||||
"list": [{
|
"list": [{
|
||||||
|
4
app.wxss
4
app.wxss
@ -8,7 +8,7 @@ page {
|
|||||||
.page-container {
|
.page-container {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
padding: 20rpx;
|
padding: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
::-webkit-scrollbar {
|
::-webkit-scrollbar {
|
||||||
@ -21,8 +21,6 @@ page {
|
|||||||
.custom-navbar {
|
.custom-navbar {
|
||||||
display: flex;
|
display: flex;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
padding-left: 20rpx;
|
|
||||||
padding-right: 20rpx;
|
|
||||||
background-color: transparent;
|
background-color: transparent;
|
||||||
/* box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.05); */
|
/* box-shadow: 0 2rpx 4rpx rgba(0, 0, 0, 0.05); */
|
||||||
}
|
}
|
||||||
|
40
components/tabbar/custom-tabbar.js
Normal file
40
components/tabbar/custom-tabbar.js
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
Component({
|
||||||
|
properties: {
|
||||||
|
tabList: {
|
||||||
|
type: Array,
|
||||||
|
value: []
|
||||||
|
},
|
||||||
|
color: {
|
||||||
|
type: String,
|
||||||
|
value: '#515151'
|
||||||
|
},
|
||||||
|
selectedColor: {
|
||||||
|
type: String,
|
||||||
|
value: '#FE9944'
|
||||||
|
}
|
||||||
|
},
|
||||||
|
data: {},
|
||||||
|
attached() {
|
||||||
|
// 获取当前页面路径
|
||||||
|
const pages = getCurrentPages();
|
||||||
|
const currentPage = pages[pages.length - 1];
|
||||||
|
const currentPath = `/${currentPage.route}`;
|
||||||
|
const index = this.data.tabList.findIndex(item => item.pagePath === currentPath);
|
||||||
|
if (index !== -1) {
|
||||||
|
this.setData({
|
||||||
|
selected: index
|
||||||
|
});
|
||||||
|
}
|
||||||
|
},
|
||||||
|
methods: {
|
||||||
|
switchTab(e) {
|
||||||
|
console.log('点击了')
|
||||||
|
const index = e.currentTarget.dataset.index;
|
||||||
|
const pagePath = this.data.tabList[index].pagePath;
|
||||||
|
console.log(index, pagePath)
|
||||||
|
wx.switchTab({
|
||||||
|
url: '/' + pagePath
|
||||||
|
});
|
||||||
|
}
|
||||||
|
}
|
||||||
|
});
|
4
components/tabbar/custom-tabbar.json
Normal file
4
components/tabbar/custom-tabbar.json
Normal file
@ -0,0 +1,4 @@
|
|||||||
|
{
|
||||||
|
"component": true,
|
||||||
|
"usingComponents": {}
|
||||||
|
}
|
6
components/tabbar/custom-tabbar.wxml
Normal file
6
components/tabbar/custom-tabbar.wxml
Normal file
@ -0,0 +1,6 @@
|
|||||||
|
<view class="tabbar">
|
||||||
|
<view class="tabbar-item" wx:for="{{tabList}}" wx:key="index" bindtap="switchTab" data-index="{{index}}">
|
||||||
|
<image class="tabbar-icon" src="{{item.selected? item.selectedIconPath : item.iconPath}}"></image>
|
||||||
|
<view class="tabbar-text" style="color: {{item.selected? selectedColor : color}}">{{item.text}}</view>
|
||||||
|
</view>
|
||||||
|
</view>
|
29
components/tabbar/custom-tabbar.wxss
Normal file
29
components/tabbar/custom-tabbar.wxss
Normal file
@ -0,0 +1,29 @@
|
|||||||
|
.tabbar {
|
||||||
|
position: fixed;
|
||||||
|
bottom: 0;
|
||||||
|
left: 0;
|
||||||
|
width: 100%;
|
||||||
|
height: 160rpx;
|
||||||
|
background-color: #FFFFFF;
|
||||||
|
display: flex;
|
||||||
|
justify-content: space-around;
|
||||||
|
align-items: center;
|
||||||
|
border-top: 1px solid #EEEEEE;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabbar-item {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabbar-icon {
|
||||||
|
width: 24px;
|
||||||
|
height: 24px;
|
||||||
|
margin-bottom: 2px;
|
||||||
|
}
|
||||||
|
|
||||||
|
.tabbar-text {
|
||||||
|
font-size: 12px;
|
||||||
|
}
|
@ -12,6 +12,7 @@ const apiPath = {
|
|||||||
getPackageList: '/api/proj/servicepkg/packageorder/listpage/self', //获取套餐包
|
getPackageList: '/api/proj/servicepkg/packageorder/listpage/self', //获取套餐包
|
||||||
getCommendProjectName: '/api/proj/recommend/list-proj-name/ai', //推荐项目名称
|
getCommendProjectName: '/api/proj/recommend/list-proj-name/ai', //推荐项目名称
|
||||||
createProject: '/api/proj/create-quick', //快速创建项目
|
createProject: '/api/proj/create-quick', //快速创建项目
|
||||||
|
buildProject: '/api/proj/create-quick/proj-id/{projId}', //生成项目
|
||||||
reCreate: '/api/proj/generate/proj-id/${projId}', //重新生成
|
reCreate: '/api/proj/generate/proj-id/${projId}', //重新生成
|
||||||
proLangList: '/api/env/custom/list-active-lang', //项目语言
|
proLangList: '/api/env/custom/list-active-lang', //项目语言
|
||||||
ruleData: '/app/agreementportal/getrelease/{id}', //使用规则 project="operator"
|
ruleData: '/app/agreementportal/getrelease/{id}', //使用规则 project="operator"
|
||||||
@ -53,6 +54,11 @@ class ProjectService {
|
|||||||
static doCreateProject(data) {
|
static doCreateProject(data) {
|
||||||
return request(apiPath.createProject, "POST", data)
|
return request(apiPath.createProject, "POST", data)
|
||||||
}
|
}
|
||||||
|
//生成项目
|
||||||
|
static doBuildProject(id) {
|
||||||
|
const path = apiPath.buildProject.replace('{projId}', id)
|
||||||
|
return request(path, "GET")
|
||||||
|
}
|
||||||
//重新生成
|
//重新生成
|
||||||
static doReCreate(url) {
|
static doReCreate(url) {
|
||||||
const path = apiPath.reCreate.replace('${projId}', url)
|
const path = apiPath.reCreate.replace('${projId}', url)
|
||||||
|
@ -31,7 +31,7 @@ function request(url, method = "GET", data = {}, params = {}, project = "copyrig
|
|||||||
baseUrl = operatorUrl
|
baseUrl = operatorUrl
|
||||||
} else if (project == 'copyright') {
|
} else if (project == 'copyright') {
|
||||||
baseUrl = copyrightUrl
|
baseUrl = copyrightUrl
|
||||||
} else if(project=='online') {
|
} else if (project == 'online') {
|
||||||
baseUrl = 'https://www.aimzhu.com/operator'
|
baseUrl = 'https://www.aimzhu.com/operator'
|
||||||
}
|
}
|
||||||
return new Promise(function (resolve, reject) {
|
return new Promise(function (resolve, reject) {
|
||||||
|
@ -9,7 +9,7 @@ const {
|
|||||||
Page({
|
Page({
|
||||||
data: {
|
data: {
|
||||||
date: utils.formatDate(new Date()),
|
date: utils.formatDate(new Date()),
|
||||||
completeDate: utils.formatDate(new Date()), //开发完成时间
|
completeDate: '', //开发完成时间
|
||||||
version: "v1.0", //系统版本
|
version: "v1.0", //系统版本
|
||||||
type: 'ALL', //默认全托管 上级页面传递type参数 all全托管 material写材料
|
type: 'ALL', //默认全托管 上级页面传递type参数 all全托管 material写材料
|
||||||
languageList: ['JAVA'],
|
languageList: ['JAVA'],
|
||||||
@ -50,6 +50,7 @@ Page({
|
|||||||
urgent: 0, //加急费用
|
urgent: 0, //加急费用
|
||||||
isUrgentDisable: false, //是否禁用加急
|
isUrgentDisable: false, //是否禁用加急
|
||||||
proPrice: 0, //价格
|
proPrice: 0, //价格
|
||||||
|
transmitPId: '', //传递过来的套餐包ID
|
||||||
},
|
},
|
||||||
onLoad(options) {
|
onLoad(options) {
|
||||||
wx.setNavigationBarTitle({
|
wx.setNavigationBarTitle({
|
||||||
@ -65,21 +66,25 @@ Page({
|
|||||||
})
|
})
|
||||||
const typeParams = options.type //类型
|
const typeParams = options.type //类型
|
||||||
const priceParams = options.price //价格
|
const priceParams = options.price //价格
|
||||||
const isUrgentParams = options.isUrgent
|
const isUrgentParams = options.isUrgent //是否加急
|
||||||
|
const pId = options.pId //套餐包ID
|
||||||
console.log(priceParams)
|
console.log(priceParams)
|
||||||
if (priceParams && priceParams > 0) {
|
if (priceParams && priceParams > 0) {
|
||||||
this.setData({
|
this.setData({
|
||||||
price: priceParams,
|
price: priceParams,
|
||||||
proPrice: priceParams,
|
proPrice: priceParams,
|
||||||
type: typeParams,
|
type: typeParams,
|
||||||
isUrgent: isUrgentParams
|
isUrgent: isUrgentParams,
|
||||||
|
transmitPId: pId
|
||||||
})
|
})
|
||||||
} else {
|
} else {
|
||||||
wx.showToast({
|
this.setData({
|
||||||
title: '数据有误,请重试',
|
errorHint: '数据有误,请稍后重试',
|
||||||
icon: 'error'
|
showError: true
|
||||||
})
|
})
|
||||||
|
setTimeout(() => {
|
||||||
wx.navigateBack()
|
wx.navigateBack()
|
||||||
|
}, 1000);
|
||||||
}
|
}
|
||||||
if (this.data.type == 'ALL') {
|
if (this.data.type == 'ALL') {
|
||||||
this.setData({
|
this.setData({
|
||||||
@ -297,6 +302,23 @@ Page({
|
|||||||
_self.setData({
|
_self.setData({
|
||||||
packageList: res.rows
|
packageList: res.rows
|
||||||
})
|
})
|
||||||
|
if (_self.data.transmitPId != '' && _self.data.transmitPId != 'undefined') {
|
||||||
|
res.rows.map(item => {
|
||||||
|
if (item.packageInfoId == _self.data.transmitPId) {
|
||||||
|
_self.setData({
|
||||||
|
selectPackage: item,
|
||||||
|
showPackage: false,
|
||||||
|
tempPackage: {},
|
||||||
|
canSelCoupons: false,
|
||||||
|
selectCoupons: {},
|
||||||
|
tempCoupons: {},
|
||||||
|
isUrgent: false, //取消加急
|
||||||
|
isUrgentDisable: true, //加急不能选择
|
||||||
|
price: 0
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
}, err => {
|
}, err => {
|
||||||
console.log(err)
|
console.log(err)
|
||||||
_self.setData({
|
_self.setData({
|
||||||
@ -472,6 +494,11 @@ Page({
|
|||||||
})
|
})
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
clearTime() {
|
||||||
|
this.setData({
|
||||||
|
completeDate: ''
|
||||||
|
})
|
||||||
|
},
|
||||||
//保存联系人
|
//保存联系人
|
||||||
doSaveContact() {
|
doSaveContact() {
|
||||||
//校验参数
|
//校验参数
|
||||||
@ -486,7 +513,7 @@ Page({
|
|||||||
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的联系电话'
|
errorHint: '请输入正确的联系电话'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -494,7 +521,7 @@ Page({
|
|||||||
if (!isValidEmail(_self.data.contactEmail)) {
|
if (!isValidEmail(_self.data.contactEmail)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的邮箱'
|
errorHint: '请输入正确的邮箱'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -10,7 +10,7 @@
|
|||||||
</swiper>
|
</swiper>
|
||||||
<view class="info-box">
|
<view class="info-box">
|
||||||
<view class="info-title">项目信息</view>
|
<view class="info-title">项目信息</view>
|
||||||
<input value="{{projectName}}" bindinput="inputProjectName" class="info-value" placeholder="请输入系统全称(注:建议以'软件''平台''系统'等字眼结尾)" />
|
<textarea value="{{projectName}}" bindinput="inputProjectName" class="info-value" placeholder="请输入系统全称(注:建议以'软件''平台''系统'等字眼结尾)" placeholder-style="font-size:14px;"></textarea>
|
||||||
<view class="info-btn" bind:tap="doCommendProjectName">推荐</view>
|
<view class="info-btn" bind:tap="doCommendProjectName">推荐</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="content-box">
|
<view class="content-box">
|
||||||
@ -20,7 +20,7 @@
|
|||||||
<text class="label">产权联系人</text>
|
<text class="label">产权联系人</text>
|
||||||
<picker style="flex:1;" mode="selector" range="{{contactList}}" range-key="name" bindchange="doChangeContact">
|
<picker style="flex:1;" mode="selector" range="{{contactList}}" range-key="name" bindchange="doChangeContact">
|
||||||
<view style="display: flex;align-items: center;">
|
<view style="display: flex;align-items: center;">
|
||||||
<view style="font-size: 13px;text-align: center;flex:1;">{{selectContact.name}}</view>
|
<view style="font-size: 14px;text-align: center;flex:1;color: #000000;">{{selectContact.name}}</view>
|
||||||
<view class="icon-arrow-down-line" style="width: 24rpx;height: 24rpx;margin-right: 20px;"></view>
|
<view class="icon-arrow-down-line" style="width: 24rpx;height: 24rpx;margin-right: 20px;"></view>
|
||||||
</view>
|
</view>
|
||||||
</picker>
|
</picker>
|
||||||
@ -29,13 +29,13 @@
|
|||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="flex-1">
|
<view class="flex-1">
|
||||||
<text class="label" style="flex: 1;">系统版本</text>
|
<text class="label" style="flex: 1;">系统版本</text>
|
||||||
<input class="value" placeholder="v1.0" style="flex:1;" value="{{version}}" bindinput="inputVersion" />
|
<input class="value {{version != '' ? 'v-select':''}}" placeholder="v1.0" style="flex:1;" value="{{version}}" bindinput="inputVersion" />
|
||||||
</view>
|
</view>
|
||||||
<view class="flex-1">
|
<view class="flex-1">
|
||||||
<text class="label">系统语言</text>
|
<text class="label">系统语言</text>
|
||||||
<view class="value selection-box ml-20">
|
<view class="value selection-box ml-20">
|
||||||
<view style="display: flex;align-items: center;">
|
<view style="display: flex;align-items: center;">
|
||||||
<view class="language-sel" bindtap="toggleOptions">{{selectLang}}</view>
|
<view class="language-sel {{selectLang != ''? 'v-select':''}}" bindtap="toggleOptions">{{selectLang}}</view>
|
||||||
<view class="icon-arrow-down-line" style="width: 28rpx;height: 28rpx;"></view>
|
<view class="icon-arrow-down-line" style="width: 28rpx;height: 28rpx;"></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -43,12 +43,13 @@
|
|||||||
</view>
|
</view>
|
||||||
<view class="item">
|
<view class="item">
|
||||||
<view class="label">开发完成时间</view>
|
<view class="label">开发完成时间</view>
|
||||||
<picker style="flex:1;" mode="date" value="{{date}}" start="2010-01-01" end="2050-01-01" bindchange="bindDateChange">
|
<picker mode="date" style="flex:1;" value="{{date}}" start="2010-01-01" end="2050-01-01" bindchange="bindDateChange">
|
||||||
<view class="desc">
|
<view class="select-time {{completeDate ==''? 'value-hint':''}}">{{completeDate != ''? completeDate:'请选择开发完成时间'}}</view>
|
||||||
<view style="color:rgba(0,0,0,0.8)">{{completeDate}}</view>
|
|
||||||
<view class="icon icon-calendar-ind"></view>
|
|
||||||
</view>
|
|
||||||
</picker>
|
</picker>
|
||||||
|
<view style="display: flex;flex-direction: row;">
|
||||||
|
<view wx:if="{{completeDate !=''}}" bind:tap="clearTime" class="icon-clear clear-icon"></view>
|
||||||
|
<view wx:if="{{completeDate==''}}" class="icon-calendar-ind" style="height: 32rpx;width: 32rpx;"></view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
|
||||||
@ -56,12 +57,12 @@
|
|||||||
<view class="section">
|
<view class="section">
|
||||||
<view wx:if="{{canSelPackage}}" class="item" style="justify-content: space-between;">
|
<view wx:if="{{canSelPackage}}" class="item" style="justify-content: space-between;">
|
||||||
<text class="label">套餐包</text>
|
<text class="label">套餐包</text>
|
||||||
<text class="value" style="flex: 1;text-align: right;" bind:tap="doShowPackage">{{selectPackage.packageName?selectPackage.packageName:'请选择套餐包'}}</text>
|
<text class="value {{!tools.isEmpty(selectPackage) ? 'v-select':''}}" style="flex: 1;text-align: right;" bind:tap="doShowPackage">{{selectPackage.packageName?selectPackage.packageName:'请选择套餐包'}}</text>
|
||||||
<text wx:if="{{!tools.isEmpty(selectPackage)}}" class="link" bind:tap="clearSelectPackageOrCoupons">取消</text>
|
<text wx:if="{{!tools.isEmpty(selectPackage)}}" class="link" bind:tap="clearSelectPackageOrCoupons">取消</text>
|
||||||
</view>
|
</view>
|
||||||
<view wx:if="{{canSelCoupons}}" class="item">
|
<view wx:if="{{canSelCoupons}}" class="item">
|
||||||
<text class="label">优惠券</text>
|
<text class="label">优惠券</text>
|
||||||
<text bindtap="doShowCoupons" style="flex:1;text-align: right;padding-right: 10px;color: #555;font-size: 14px;">{{selectCoupons.couponId? selectCoupons.coupon.title : '请选择优惠券'}}</text>
|
<text bindtap="doShowCoupons" class="value {{!tools.isEmpty(selectCoupons)? 'v-select':''}}">{{selectCoupons.couponId? selectCoupons.coupon.title : '请选择优惠券'}}</text>
|
||||||
<text class="link" wx:if="{{!tools.isEmpty(selectCoupons)}}" bind:tap="clearSelectPackageOrCoupons">取消</text>
|
<text class="link" wx:if="{{!tools.isEmpty(selectCoupons)}}" bind:tap="clearSelectPackageOrCoupons">取消</text>
|
||||||
<text class="link" bindtap="doShowCoupons" wx:if="{{tools.isEmpty(selectCoupons)}}">选择</text>
|
<text class="link" bindtap="doShowCoupons" wx:if="{{tools.isEmpty(selectCoupons)}}">选择</text>
|
||||||
</view>
|
</view>
|
||||||
@ -87,24 +88,24 @@
|
|||||||
<view class="form-box">
|
<view class="form-box">
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title">姓名</view>
|
<view class="form-item-title">姓名</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactName}}" placeholder="请输入联系人姓名" class="form-item-content" bindinput="inputContactName" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactName}}" placeholder="请输入姓名" class="form-item-content" bindinput="inputContactName" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title">联系电话</view>
|
<view class="form-item-title">联系电话</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactPhone}}" placeholder="请输入联系电话" class="form-item-content" bindinput="inputContactPhone" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactPhone}}" placeholder="请输入联系电话" class="form-item-content" bindinput="inputContactPhone" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title no-after">联系邮箱</view>
|
<view class="form-item-title no-after" style="padding-left: 16rpx;">联系邮箱</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactEmail}}" placeholder="请输入邮箱" class="form-item-content" bindinput="inputContactEmail" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactEmail}}" placeholder="请输入联系邮箱" class="form-item-content" bindinput="inputContactEmail" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title no-after">公司</view>
|
<view class="form-item-title no-after" style="padding-left: 16rpx;">公司</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactCompany}}" placeholder="请输入公司名称" class="form-item-content" bindinput="inputContactCompany" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactCompany}}" placeholder="请输入公司名称" class="form-item-content" bindinput="inputContactCompany" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view slot="footer">
|
<view slot="footer">
|
||||||
<button type="primary" bind:tap="doSaveContact">创建</button>
|
<button class="confirm-btn" bind:tap="doSaveContact">保存</button>
|
||||||
</view>
|
</view>
|
||||||
</mp-half-screen-dialog>
|
</mp-half-screen-dialog>
|
||||||
<!-- 推荐系统名称 -->
|
<!-- 推荐系统名称 -->
|
||||||
@ -113,7 +114,7 @@
|
|||||||
<view slot="desc">
|
<view slot="desc">
|
||||||
<textarea bindinput="inputCommendProjectName" placeholder="请简单介绍您想创建的系统,我们会根据您的描述为您推荐系统全称" style="border: 1px solid #f2f2f2;width: 82vw;padding: 10px;height: 50px;"></textarea>
|
<textarea bindinput="inputCommendProjectName" placeholder="请简单介绍您想创建的系统,我们会根据您的描述为您推荐系统全称" style="border: 1px solid #f2f2f2;width: 82vw;padding: 10px;height: 50px;"></textarea>
|
||||||
<!-- 推荐回来的列表 -->
|
<!-- 推荐回来的列表 -->
|
||||||
<scroll-view scroll-y style="height: 300px;">
|
<scroll-view scroll-y style="height: 300rpx;">
|
||||||
<view class="project-box">
|
<view class="project-box">
|
||||||
<block wx:for="{{projectNameList}}" wx:key="index">
|
<block wx:for="{{projectNameList}}" wx:key="index">
|
||||||
<view class="project-item" bind:tap="doSelectProjectName" data-value="{{item}}">{{item}}</view>
|
<view class="project-item" bind:tap="doSelectProjectName" data-value="{{item}}">{{item}}</view>
|
||||||
@ -121,14 +122,15 @@
|
|||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
<view slot="footer" style="height: 0px;">
|
<view slot="footer">
|
||||||
<button type="primary" bind:tap="doCreateFullName">生成</button>
|
<button class="confirm-btn" bind:tap="doCreateFullName">生成</button>
|
||||||
</view>
|
</view>
|
||||||
</mp-half-screen-dialog>
|
</mp-half-screen-dialog>
|
||||||
<!-- 优惠卷弹窗 -->
|
<!-- 优惠卷弹窗 -->
|
||||||
<mp-half-screen-dialog show="{{showCoupons}}">
|
<mp-half-screen-dialog show="{{showCoupons}}">
|
||||||
<view slot="title">优惠卷</view>
|
<view slot="title">优惠卷</view>
|
||||||
<view slot="desc">
|
<view slot="desc">
|
||||||
|
<scroll-view scroll-y style="height: 400rpx;">
|
||||||
<view class="coupons-list-box">
|
<view class="coupons-list-box">
|
||||||
<radio-group>
|
<radio-group>
|
||||||
<block wx:for="{{couponsList}}" wx:key="index">
|
<block wx:for="{{couponsList}}" wx:key="index">
|
||||||
@ -152,6 +154,7 @@
|
|||||||
</block>
|
</block>
|
||||||
</radio-group>
|
</radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
<view slot="footer">
|
<view slot="footer">
|
||||||
<button class="confirm-btn" style="margin-top: 10px;" bind:tap="confirmSelCoupons">确定</button>
|
<button class="confirm-btn" style="margin-top: 10px;" bind:tap="confirmSelCoupons">确定</button>
|
||||||
@ -161,6 +164,7 @@
|
|||||||
<mp-half-screen-dialog show="{{showPackage}}">
|
<mp-half-screen-dialog show="{{showPackage}}">
|
||||||
<view slot="title">套餐包</view>
|
<view slot="title">套餐包</view>
|
||||||
<view slot="desc">
|
<view slot="desc">
|
||||||
|
<scroll-view scroll-y style="height: 400rpx;">
|
||||||
<view class="coupons-list-box">
|
<view class="coupons-list-box">
|
||||||
<radio-group>
|
<radio-group>
|
||||||
<block wx:for="{{packageList}}" wx:key="index">
|
<block wx:for="{{packageList}}" wx:key="index">
|
||||||
@ -180,6 +184,7 @@
|
|||||||
</block>
|
</block>
|
||||||
</radio-group>
|
</radio-group>
|
||||||
</view>
|
</view>
|
||||||
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
<view slot="footer">
|
<view slot="footer">
|
||||||
<button class="confirm-btn" style="margin-top: 10px;" bind:tap="confirmSelectPackage">确定</button>
|
<button class="confirm-btn" style="margin-top: 10px;" bind:tap="confirmSelectPackage">确定</button>
|
||||||
|
@ -62,15 +62,18 @@ page {
|
|||||||
|
|
||||||
.info-title {
|
.info-title {
|
||||||
font-size: 36rpx;
|
font-size: 36rpx;
|
||||||
font-weight: 500;
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
.info-value {
|
.info-value {
|
||||||
margin-top: 20rpx;
|
margin-top: 20rpx;
|
||||||
border: 1rpx solid #f2f2f2;
|
border: 1rpx solid #f2f2f2;
|
||||||
padding: 24rpx;
|
font-size: 14px;
|
||||||
font-size: 28rpx;
|
line-height: 16px;
|
||||||
background-color: white;
|
background-color: white;
|
||||||
|
height: 65rpx;
|
||||||
|
width: auto;
|
||||||
|
padding: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.info-btn {
|
.info-btn {
|
||||||
@ -104,6 +107,7 @@ page {
|
|||||||
|
|
||||||
.label {
|
.label {
|
||||||
color: black;
|
color: black;
|
||||||
|
font-weight: bold;
|
||||||
}
|
}
|
||||||
|
|
||||||
.desc {
|
.desc {
|
||||||
@ -118,18 +122,46 @@ page {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.select-time {
|
||||||
|
color: #000000;
|
||||||
|
flex: 1;
|
||||||
|
font-size: 14px;
|
||||||
|
text-align: left;
|
||||||
|
padding-left: 30rpx;
|
||||||
|
}
|
||||||
|
|
||||||
|
.clear-icon {
|
||||||
|
width: 20px;
|
||||||
|
height: 20px;
|
||||||
|
margin-right: 20rpx;
|
||||||
|
}
|
||||||
|
|
||||||
.desc .icon {
|
.desc .icon {
|
||||||
width: 32rpx;
|
width: 32rpx;
|
||||||
height: 32rpx;
|
height: 32rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.value {
|
.value {
|
||||||
color: #666;
|
color: #9A9A9A;
|
||||||
padding-right: 10px;
|
padding-right: 10px;
|
||||||
|
flex: 1;
|
||||||
|
text-align: right;
|
||||||
|
padding-right: 10px;
|
||||||
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.value-hint {
|
||||||
|
color: #9A9A9A;
|
||||||
|
}
|
||||||
|
|
||||||
|
.v-select {
|
||||||
|
color: #000000;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
.language-sel {
|
.language-sel {
|
||||||
font-size: 30rpx;
|
font-size: 14px;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
}
|
}
|
||||||
@ -171,6 +203,8 @@ page {
|
|||||||
background-color: #f0f0f0;
|
background-color: #f0f0f0;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.weui-half-screen-dialog__ft {}
|
||||||
|
|
||||||
.bottom-box {
|
.bottom-box {
|
||||||
position: fixed;
|
position: fixed;
|
||||||
left: 0;
|
left: 0;
|
||||||
@ -234,7 +268,7 @@ page {
|
|||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-item-title:not(.no-after)::after {
|
.form-item-title:not(.no-after)::before {
|
||||||
content: "*";
|
content: "*";
|
||||||
color: red;
|
color: red;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
@ -244,19 +278,24 @@ page {
|
|||||||
|
|
||||||
.form-item-content {
|
.form-item-content {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
text-align: right;
|
||||||
}
|
}
|
||||||
|
|
||||||
.project-box {
|
.project-box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: row;
|
||||||
|
flex-wrap: wrap;
|
||||||
|
margin-top: 10rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.project-item {
|
.project-item {
|
||||||
font-size: 18px;
|
font-size: 24rpx;
|
||||||
background-color: #f5f5f5;
|
background-color: #ffaa0034;
|
||||||
margin: 10px;
|
|
||||||
padding: 10px;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
color: #FFA900;
|
||||||
|
text-align: center;
|
||||||
|
margin: 20rpx;
|
||||||
|
padding: 5rpx 20rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.confirm-btn {
|
.confirm-btn {
|
||||||
@ -264,15 +303,21 @@ page {
|
|||||||
color: white;
|
color: white;
|
||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
height: 40px;
|
height: 40px;
|
||||||
border-radius: 10px;
|
border-radius: 5px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
width: 85vw !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
|
||||||
|
.weui-half-screen-dialog__bd {
|
||||||
|
padding-bottom: 40rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.coupons-list-box {
|
.coupons-list-box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: flex-start;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.tickets {
|
.tickets {
|
||||||
@ -286,7 +331,7 @@ page {
|
|||||||
width: 60vw;
|
width: 60vw;
|
||||||
position: relative;
|
position: relative;
|
||||||
padding: 10px;
|
padding: 10px;
|
||||||
background: radial-gradient(circle at right top, transparent 16rpx, #ffaa0017 0) right top / 100% 51% no-repeat,
|
background: radial-gradient(circle at right top, transparent 16rpx, #ffaa0017 0) right top / 100% 50% no-repeat,
|
||||||
radial-gradient(circle at right bottom, transparent 16rpx, #ffaa0017 0) right bottom / 100% 50% no-repeat;
|
radial-gradient(circle at right bottom, transparent 16rpx, #ffaa0017 0) right bottom / 100% 50% no-repeat;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -6,7 +6,7 @@ page {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.input-money {
|
.input-money {
|
||||||
font-size: 24px;
|
font-size: 48rpx;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
height: 24px;
|
height: 24px;
|
||||||
line-height: 24px;
|
line-height: 24px;
|
||||||
|
@ -23,7 +23,7 @@ Page({
|
|||||||
companyName: '', //公司名称
|
companyName: '', //公司名称
|
||||||
companyBank: '', //开户行
|
companyBank: '', //开户行
|
||||||
companyBankNum: '', //账户号码
|
companyBankNum: '', //账户号码
|
||||||
packageId: null, //套餐ID
|
packageId: '', //套餐ID
|
||||||
payMoney: 0, //金额
|
payMoney: 0, //金额
|
||||||
packageName: '', //套餐名称
|
packageName: '', //套餐名称
|
||||||
accountRechargeId: '', //订单ID
|
accountRechargeId: '', //订单ID
|
||||||
@ -50,8 +50,9 @@ Page({
|
|||||||
// 获取完整的年月日时分秒,以及默认显示的数组
|
// 获取完整的年月日时分秒,以及默认显示的数组
|
||||||
const obj = dateTimePicker.dateTimePicker(this.data.startYear, this.data.endYear);
|
const obj = dateTimePicker.dateTimePicker(this.data.startYear, this.data.endYear);
|
||||||
console.log(obj.dateTime)
|
console.log(obj.dateTime)
|
||||||
|
console.log(typeof options.packageId)
|
||||||
this.setData({
|
this.setData({
|
||||||
packageId: options.packageId, //套餐包
|
packageId: options.packageId && options.packageId != 'undefined' ? options.packageId : '', //套餐包
|
||||||
packageName: options.name,
|
packageName: options.name,
|
||||||
payMoney: options.money, //金额
|
payMoney: options.money, //金额
|
||||||
dateTimeArray: obj.dateTimeArray,
|
dateTimeArray: obj.dateTimeArray,
|
||||||
@ -62,6 +63,7 @@ Page({
|
|||||||
this.buildCurrentTime()
|
this.buildCurrentTime()
|
||||||
this.getEnterpriseAccountInfo()
|
this.getEnterpriseAccountInfo()
|
||||||
//获取订单
|
//获取订单
|
||||||
|
console.log(this.data.packageId)
|
||||||
this.doGetOrder()
|
this.doGetOrder()
|
||||||
},
|
},
|
||||||
//公司名称
|
//公司名称
|
||||||
@ -114,6 +116,7 @@ Page({
|
|||||||
title: '加载中...',
|
title: '加载中...',
|
||||||
})
|
})
|
||||||
const _self = this
|
const _self = this
|
||||||
|
console.log(_self.data.packageId)
|
||||||
const data = {
|
const data = {
|
||||||
packageInfoId: _self.data.packageId ? _self.data.packageId : '',
|
packageInfoId: _self.data.packageId ? _self.data.packageId : '',
|
||||||
rechargeMoney: _self.data.payMoney,
|
rechargeMoney: _self.data.payMoney,
|
||||||
|
@ -1,7 +1,7 @@
|
|||||||
/* pages/copyright/publicPay/publicPay.wxss */
|
/* pages/copyright/publicPay/publicPay.wxss */
|
||||||
page {
|
page {
|
||||||
background: linear-gradient(to bottom, #F0F0F0, #FFFFFF);
|
background: linear-gradient(to bottom, #F0F0F0, #FFFFFF);
|
||||||
background-size: 100% 100vh;
|
background-size: 100vw 100vh;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -30,9 +30,9 @@ page {
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
align-items: flex-start;
|
||||||
width: 90vw;
|
|
||||||
padding: 6px 20px;
|
padding: 6px 20px;
|
||||||
|
width: 85vw;
|
||||||
}
|
}
|
||||||
|
|
||||||
.red {
|
.red {
|
||||||
@ -43,13 +43,13 @@ page {
|
|||||||
} */
|
} */
|
||||||
|
|
||||||
.title {
|
.title {
|
||||||
flex: .3;
|
flex: 0.3;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
color: black;
|
color: black;
|
||||||
}
|
}
|
||||||
|
|
||||||
.content {
|
.content {
|
||||||
flex: 1;
|
flex: 0.7;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -132,9 +132,9 @@ page {
|
|||||||
}
|
}
|
||||||
|
|
||||||
.input-box {
|
.input-box {
|
||||||
width: 60vw;
|
flex: 1;
|
||||||
background-color: #FAFAFA;
|
background-color: #FAFAFA;
|
||||||
border-radius: 20px;
|
border-radius: 2rpx;
|
||||||
padding: 3px 8px;
|
padding: 3px 8px;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
font-size: 12px;
|
font-size: 12px;
|
||||||
|
@ -12,14 +12,19 @@ const deviceInfo = wx.getDeviceInfo()
|
|||||||
const screenInfo = wx.getWindowInfo();
|
const screenInfo = wx.getWindowInfo();
|
||||||
const statusBarHeight = screenInfo.statusBarHeight; // 状态栏高度
|
const statusBarHeight = screenInfo.statusBarHeight; // 状态栏高度
|
||||||
const navBarHeight = deviceInfo.platform == 'IOS' ? 48 : 50; // 导航栏高度(iOS 为 44px,Android 为 48px)
|
const navBarHeight = deviceInfo.platform == 'IOS' ? 48 : 50; // 导航栏高度(iOS 为 44px,Android 为 48px)
|
||||||
|
const tabBarHeight = screenInfo.screenHeight - (screenInfo.safeArea ? screenInfo.safeArea.bottom : 50);
|
||||||
|
const screenHeight = screenInfo.screenHeight
|
||||||
|
const screenWidth = screenInfo.screenWidth
|
||||||
const windowHeight = screenInfo.windowHeight - navBarHeight - statusBarHeight; //可用内容高度
|
const windowHeight = screenInfo.windowHeight - navBarHeight - statusBarHeight; //可用内容高度
|
||||||
|
|
||||||
Page({
|
Page({
|
||||||
data: {
|
data: {
|
||||||
statusBarHeight: statusBarHeight,
|
statusBarHeight: statusBarHeight,
|
||||||
navBarHeight: navBarHeight,
|
navBarHeight: navBarHeight,
|
||||||
totalHeight: navBarHeight, // 导航栏总高度
|
totalHeight: navBarHeight, // 导航栏总高度
|
||||||
contentHeight: windowHeight,
|
contentHeight: windowHeight,
|
||||||
|
screenHeight: screenHeight, //屏幕高度
|
||||||
|
screenWidth: screenWidth, //屏幕宽度
|
||||||
|
tabBarHeight: tabBarHeight, //tabbar高度
|
||||||
tagList: [],
|
tagList: [],
|
||||||
currentTag: '',
|
currentTag: '',
|
||||||
imgUrl: previewUrl,
|
imgUrl: previewUrl,
|
||||||
@ -75,10 +80,26 @@ Page({
|
|||||||
showAd: false, //显示优惠卷广告
|
showAd: false, //显示优惠卷广告
|
||||||
tempCoupons: null, //优惠卷
|
tempCoupons: null, //优惠卷
|
||||||
isNoShowToday: false, //今日不再显示
|
isNoShowToday: false, //今日不再显示
|
||||||
|
tabList: [{
|
||||||
|
"pagePath": "pages/index/index",
|
||||||
|
"text": "首页",
|
||||||
|
"iconPath": "/static/images/ic_home_normal.png",
|
||||||
|
"selectedIconPath": "/static/images/ic_home_select.png",
|
||||||
|
"selected": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"pagePath": "pages/mine/mineIndex/mine",
|
||||||
|
"text": "我的",
|
||||||
|
"iconPath": "/static/images/ic_mine_normal.png",
|
||||||
|
"selectedIconPath": "/static/images/ic_mine_select.png",
|
||||||
|
"selected": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
color: "#515151",
|
||||||
|
selectedColor: "#FE9944",
|
||||||
},
|
},
|
||||||
onLoad(e) {
|
onLoad(e) {
|
||||||
const _self = this
|
const _self = this
|
||||||
console.log(screenInfo.windowHeight)
|
|
||||||
//获取通知
|
//获取通知
|
||||||
_self.doGetNotice()
|
_self.doGetNotice()
|
||||||
//获取标签选项
|
//获取标签选项
|
||||||
@ -86,10 +107,6 @@ Page({
|
|||||||
//获取列表
|
//获取列表
|
||||||
const params = _self.buildParams(1, true)
|
const params = _self.buildParams(1, true)
|
||||||
_self.doGetSelfList(params, true)
|
_self.doGetSelfList(params, true)
|
||||||
const h = Utils.pxToRpx(_self.data.contentHeight)
|
|
||||||
_self.setData({
|
|
||||||
contentHeight: h
|
|
||||||
})
|
|
||||||
const noShowToday = Cache.get('noShowToday')
|
const noShowToday = Cache.get('noShowToday')
|
||||||
const currentDate = new Date().toLocaleDateString();
|
const currentDate = new Date().toLocaleDateString();
|
||||||
if (noShowToday && noShowToday === currentDate) {
|
if (noShowToday && noShowToday === currentDate) {
|
||||||
@ -99,6 +116,41 @@ Page({
|
|||||||
} else {
|
} else {
|
||||||
_self.doGetClaimsCoupons()
|
_self.doGetClaimsCoupons()
|
||||||
}
|
}
|
||||||
|
this.countViewHeight()
|
||||||
|
},
|
||||||
|
onShow() {
|
||||||
|
const pages = getCurrentPages();
|
||||||
|
const currentPage = pages[pages.length - 1];
|
||||||
|
const tabList = this.data.tabList;
|
||||||
|
tabList.forEach(item => {
|
||||||
|
item.selected = item.pagePath === currentPage.route;
|
||||||
|
});
|
||||||
|
this.setData({
|
||||||
|
tabList
|
||||||
|
});
|
||||||
|
},
|
||||||
|
//计算剩余高度
|
||||||
|
countViewHeight() {
|
||||||
|
const query = wx.createSelectorQuery();
|
||||||
|
const _self = this
|
||||||
|
// 指定要查询的 view 元素
|
||||||
|
query.select('#title-box').boundingClientRect();
|
||||||
|
query.exec((res) => {
|
||||||
|
if (res[0]) {
|
||||||
|
const height = res[0].height;
|
||||||
|
//屏幕高度-内容高度-tabbar高度
|
||||||
|
const contentHeight = _self.data.screenHeight - height - 50
|
||||||
|
console.log('tabbarHeight:', _self.data.tabBarHeight)
|
||||||
|
const h = Utils.pxToRpx(contentHeight, _self.data.screenWidth)
|
||||||
|
const tempH = h - 130
|
||||||
|
console.log('转后', h, '内容高度:', tempH)
|
||||||
|
_self.setData({
|
||||||
|
contentHeight: tempH
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
console.log('未找到指定的 view 元素');
|
||||||
|
}
|
||||||
|
})
|
||||||
},
|
},
|
||||||
//获取可以申领的优惠卷
|
//获取可以申领的优惠卷
|
||||||
doGetClaimsCoupons() {
|
doGetClaimsCoupons() {
|
||||||
@ -381,6 +433,33 @@ Page({
|
|||||||
downloadProgress: 0
|
downloadProgress: 0
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
//去生成项目
|
||||||
|
doCreatePro(e) {
|
||||||
|
wx.showLoading({
|
||||||
|
title: '生成中...',
|
||||||
|
})
|
||||||
|
const _self = this
|
||||||
|
const item = e.currentTarget.dataset.value
|
||||||
|
ProjectService.doBuildProject(item.projId)
|
||||||
|
.then(res => {
|
||||||
|
// 刷新列表
|
||||||
|
wx.hideLoading()
|
||||||
|
console.log(res)
|
||||||
|
_self.setData({
|
||||||
|
successHint: '正在生成中,请耐心等待',
|
||||||
|
showSuccess: true
|
||||||
|
})
|
||||||
|
_self.doRefreshList()
|
||||||
|
})
|
||||||
|
.catch(err => {
|
||||||
|
console.log(err)
|
||||||
|
wx.hideLoading()
|
||||||
|
_self.setData({
|
||||||
|
errorHint: err.msg ? err.msg : '生成失败,请稍后重试',
|
||||||
|
showError: true
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
//重新生成
|
//重新生成
|
||||||
doReCreate(e) {
|
doReCreate(e) {
|
||||||
console.log(e)
|
console.log(e)
|
||||||
|
@ -5,7 +5,8 @@
|
|||||||
"mp-toptips": "weui-miniprogram/toptips/toptips",
|
"mp-toptips": "weui-miniprogram/toptips/toptips",
|
||||||
"down-progress": "/components/down-progress/down-progress",
|
"down-progress": "/components/down-progress/down-progress",
|
||||||
"mp-loading": "weui-miniprogram/loading/loading",
|
"mp-loading": "weui-miniprogram/loading/loading",
|
||||||
"ad-popup": "/components/ad-popup/ad-popup"
|
"ad-popup": "/components/ad-popup/ad-popup",
|
||||||
|
"custom-tabbar": "/components/tabbar/custom-tabbar"
|
||||||
},
|
},
|
||||||
"navigationStyle": "custom"
|
"navigationStyle": "custom"
|
||||||
}
|
}
|
@ -1,8 +1,11 @@
|
|||||||
<view class="bg-title" style="padding-bottom: 60rpx;">
|
<view style="position: relative;display: flex;flex-direction: column;">
|
||||||
|
<view class="bg-title" style="position: absolute;height: 500rpx;width: 100vw;"></view>
|
||||||
|
<view style="position: relative;top:0;left:0;">
|
||||||
|
<view class="title-box" id="title-box">
|
||||||
<view class="custom-navbar" style="height: {{totalHeight}}px; padding-top: {{statusBarHeight}}px;justify-content: flex-start;color: white;">
|
<view class="custom-navbar" style="height: {{totalHeight}}px; padding-top: {{statusBarHeight}}px;justify-content: flex-start;color: white;">
|
||||||
<view class="navbar-title">AI喵著</view>
|
<view class="navbar-title">AI喵著</view>
|
||||||
</view>
|
</view>
|
||||||
<view style="padding: 0px 10px 10px 10px;">
|
<view>
|
||||||
<view class="title-func">
|
<view class="title-func">
|
||||||
<view class="create-btn" bind:tap="createCopy">
|
<view class="create-btn" bind:tap="createCopy">
|
||||||
<view class="icon-add" style="width: 40rpx;height: 40rpx;"></view>
|
<view class="icon-add" style="width: 40rpx;height: 40rpx;"></view>
|
||||||
@ -17,12 +20,13 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
<view id="tab-box" class="container-title">
|
||||||
<view class="content-box">
|
|
||||||
<view class="container-title">
|
|
||||||
<view class="container-box">
|
<view class="container-box">
|
||||||
<view class="list-title-box">
|
<view class="list-title-box">
|
||||||
<view class="list-title-txt">软著列表</view>
|
<view class="list-title-txt">
|
||||||
|
<view class="title-line"></view>
|
||||||
|
<view style="margin-left: 8rpx;">软著列表</view>
|
||||||
|
</view>
|
||||||
<view class="list-title-btns">
|
<view class="list-title-btns">
|
||||||
<view bind:tap="doChangeStatus" data-value="PROCESSING" class="{{currentStatus=='PROCESSING'? 'btn-select':'btn-normal'}} border-left">进行中的</view>
|
<view bind:tap="doChangeStatus" data-value="PROCESSING" class="{{currentStatus=='PROCESSING'? 'btn-select':'btn-normal'}} border-left">进行中的</view>
|
||||||
<view bind:tap="doChangeStatus" data-value="COMPLETE" class="{{currentStatus=='COMPLETE'? 'btn-select':'btn-normal'}} border-right">已完成的</view>
|
<view bind:tap="doChangeStatus" data-value="COMPLETE" class="{{currentStatus=='COMPLETE'? 'btn-select':'btn-normal'}} border-right">已完成的</view>
|
||||||
@ -51,8 +55,10 @@
|
|||||||
</scroll-view>
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<container-loading loadingState="{{listLoading}}" style="height: {{contentHeight+110}}rpx;" bindrefresh="doRefreshList">
|
</view>
|
||||||
<scroll-view scroll-y="{{true}}" style="height: {{contentHeight+110}}rpx;" bindrefresherrefresh="doRefreshList" refresher-enabled refresher-triggered="{{listRefreshTrig}}" bindscrolltolower="doLoadMore" lower-threshold='30'>
|
<view class="content-box">
|
||||||
|
<container-loading loadingState="{{listLoading}}" style="height:{{contentHeight}}rpx;" bindrefresh="doRefreshList">
|
||||||
|
<scroll-view scroll-y="{{true}}" style="height: {{contentHeight}}rpx;" bindrefresherrefresh="doRefreshList" refresher-enabled refresher-triggered="{{listRefreshTrig}}" bindscrolltolower="doLoadMore" lower-threshold='30'>
|
||||||
<view class="list-content">
|
<view class="list-content">
|
||||||
<block wx:for="{{projectList}}" wx:key="index">
|
<block wx:for="{{projectList}}" wx:key="index">
|
||||||
<view class="list-item">
|
<view class="list-item">
|
||||||
@ -60,12 +66,12 @@
|
|||||||
<swiper class="cover" autoplay>
|
<swiper class="cover" autoplay>
|
||||||
<block wx:for="{{item.codeTypePage.previewImgs}}" wx:for-item="imgItem" wx:for-index="imgIndex" wx:key="imgIndex">
|
<block wx:for="{{item.codeTypePage.previewImgs}}" wx:for-item="imgItem" wx:for-index="imgIndex" wx:key="imgIndex">
|
||||||
<swiper-item class="cover">
|
<swiper-item class="cover">
|
||||||
<image class="cover" src="{{imgItem}}"></image>
|
<image class="cover" mode="scaleToFill" src="{{imgItem}}"></image>
|
||||||
</swiper-item>
|
</swiper-item>
|
||||||
</block>
|
</block>
|
||||||
</swiper>
|
</swiper>
|
||||||
<view class="item-img-status">
|
<view class="item-img-status {{tools.statusColor(item.generate.generateStatus,item.aiSetting.settingStatus)}}">
|
||||||
<text>{{tools.status(item.generate.generateStatus)}}</text>
|
<text>{{tools.status(item.generate.generateStatus,item.aiSetting.settingStatus)}}</text>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="item-content">
|
<view class="item-content">
|
||||||
@ -81,6 +87,7 @@
|
|||||||
<view class="project-create-time">{{item.gmtCreate}}</view>
|
<view class="project-create-time">{{item.gmtCreate}}</view>
|
||||||
<view wx:if="{{item.generate.generateStatus=='SUCCESS'}}" class="project-btn" bind:tap="doShowDownload" data-value="{{item}}">下载</view>
|
<view wx:if="{{item.generate.generateStatus=='SUCCESS'}}" class="project-btn" bind:tap="doShowDownload" data-value="{{item}}">下载</view>
|
||||||
<view wx:if="{{item.generate.generateStatus=='FAILED'}}" class="project-re-btn" bind:tap="doReCreate" data-value="{{item}}">重新生成</view>
|
<view wx:if="{{item.generate.generateStatus=='FAILED'}}" class="project-re-btn" bind:tap="doReCreate" data-value="{{item}}">重新生成</view>
|
||||||
|
<view wx:if="{{item.aiSetting.settingStatus=='NONE'}}" class="project-btn" bind:tap="doCreatePro" data-value="{{item}}">生成</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
@ -89,7 +96,10 @@
|
|||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
</container-loading>
|
</container-loading>
|
||||||
|
</view>
|
||||||
|
</view>
|
||||||
</view>
|
</view>
|
||||||
|
<custom-tabbar tabList="{{tabList}}" color="{{color}}" selectedColor="{{selectedColor}}"></custom-tabbar>
|
||||||
<mp-half-screen-dialog show="{{showDownload}}" ext-class="custom-dialog">
|
<mp-half-screen-dialog show="{{showDownload}}" ext-class="custom-dialog">
|
||||||
<view slot="title" style="font-size: 16px;font-weight: bold;">资料下载</view>
|
<view slot="title" style="font-size: 16px;font-weight: bold;">资料下载</view>
|
||||||
<view slot="desc" style="margin-top: 10px;">
|
<view slot="desc" style="margin-top: 10px;">
|
||||||
|
@ -9,18 +9,24 @@
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
padding: 20rpx;
|
padding: 20rpx;
|
||||||
margin-top: -50rpx;
|
margin-left: 30rpx;
|
||||||
margin-left: 20rpx;
|
margin-right: 30rpx;
|
||||||
margin-right: 20rpx;
|
border-bottom-left-radius: 10rpx;
|
||||||
border-radius: 10rpx;
|
border-bottom-right-radius: 10rpx;
|
||||||
background-color: rgba(255, 255, 255, 1);
|
background-color: rgba(255, 255, 255, 1);
|
||||||
box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(206, 206, 206, 0.4);
|
box-shadow: 0rpx 2rpx 6rpx 0rpx rgba(206, 206, 206, 0.6);
|
||||||
}
|
}
|
||||||
|
|
||||||
.container-title {
|
.container-title {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
height: 80px;
|
}
|
||||||
|
|
||||||
|
.title-box {
|
||||||
|
display: flex;
|
||||||
|
flex-direction: column;
|
||||||
|
justify-content: flex-start;
|
||||||
|
padding: 0rpx 30rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.title-func {
|
.title-func {
|
||||||
@ -91,13 +97,27 @@
|
|||||||
.container-box {
|
.container-box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
|
background-color: white;
|
||||||
|
padding: 20rpx;
|
||||||
|
border-top-left-radius: 10rpx;
|
||||||
|
border-top-right-radius: 10rpx;
|
||||||
margin-top: 20rpx;
|
margin-top: 20rpx;
|
||||||
|
background-color: rgba(255, 255, 255, 1);
|
||||||
|
box-shadow: 0rpx -6rpx 6rpx 0rpx rgba(206, 206, 206, 0.1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.list-title-box {
|
.list-title-box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
|
align-items: center;
|
||||||
|
}
|
||||||
|
|
||||||
|
.title-line {
|
||||||
|
width: 10rpx;
|
||||||
|
height: 32rpx;
|
||||||
|
border-radius: 17rpx;
|
||||||
|
background-color: rgba(255, 169, 0, 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
.list-title-txt {
|
.list-title-txt {
|
||||||
@ -106,6 +126,10 @@
|
|||||||
font-size: 16px;
|
font-size: 16px;
|
||||||
font-family: TaipeiHei-bold;
|
font-family: TaipeiHei-bold;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
|
display: flex;
|
||||||
|
flex-direction: row;
|
||||||
|
justify-content: center;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.list-title-btns {
|
.list-title-btns {
|
||||||
@ -189,6 +213,7 @@
|
|||||||
background-color: #F7F7F7;
|
background-color: #F7F7F7;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
.list-item:nth-of-type(n+2) {
|
.list-item:nth-of-type(n+2) {
|
||||||
@ -203,31 +228,50 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.item-img .cover {
|
.item-img .cover {
|
||||||
width: 95px;
|
width: 210rpx;
|
||||||
height: 68px;
|
height: 136rpx;
|
||||||
border-radius: 2px;
|
border-radius: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-img-status {
|
.item-img-status {
|
||||||
background-color: #AFE5C7;
|
|
||||||
text-align: center;
|
text-align: center;
|
||||||
position: absolute;
|
position: absolute;
|
||||||
bottom: 0;
|
bottom: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
width: 95px;
|
width: 210rpx;
|
||||||
font-size: 24rpx;
|
font-size: 24rpx;
|
||||||
border-bottom-left-radius: 2px;
|
border-bottom-left-radius: 2px;
|
||||||
border-bottom-right-radius: 2px;
|
border-bottom-right-radius: 2px;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.status-gray {
|
||||||
|
background-color: #adadadc0;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status-green {
|
||||||
|
background-color: #AFE5C7;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status-yellow {
|
||||||
|
background-color: #fe9844c0;
|
||||||
|
color: black;
|
||||||
|
}
|
||||||
|
|
||||||
|
.status-red {
|
||||||
|
background-color: #FF0000C0;
|
||||||
|
color: white;
|
||||||
|
}
|
||||||
|
|
||||||
.item-content {
|
.item-content {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
height: 72px;
|
height: 72px;
|
||||||
padding-left: 16px;
|
padding-left: 16rpx;
|
||||||
width: 90vw;
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-content-title {
|
.item-content-title {
|
||||||
@ -235,7 +279,6 @@
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
width: 59vw;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -245,6 +288,10 @@
|
|||||||
text-align: left;
|
text-align: left;
|
||||||
font-weight: bold;
|
font-weight: bold;
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
display: block;
|
||||||
|
white-space: nowrap;
|
||||||
|
overflow: hidden;
|
||||||
|
text-overflow: ellipsis;
|
||||||
}
|
}
|
||||||
|
|
||||||
.project-status {
|
.project-status {
|
||||||
@ -254,12 +301,14 @@
|
|||||||
flex: .3;
|
flex: .3;
|
||||||
padding-left: 5px;
|
padding-left: 5px;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
|
white-space: nowrap;
|
||||||
}
|
}
|
||||||
|
|
||||||
.item-content-title {
|
.item-content-title {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
|
min-width: 0;
|
||||||
}
|
}
|
||||||
|
|
||||||
.project-aff {
|
.project-aff {
|
||||||
@ -287,7 +336,6 @@
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: flex-end;
|
align-items: flex-end;
|
||||||
width: 57vw;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.project-create-time {
|
.project-create-time {
|
||||||
@ -296,7 +344,7 @@
|
|||||||
}
|
}
|
||||||
|
|
||||||
.project-btn {
|
.project-btn {
|
||||||
font-size: 28rpx;
|
font-size: 24rpx;
|
||||||
background-color: #FE9944;
|
background-color: #FE9944;
|
||||||
color: white;
|
color: white;
|
||||||
padding: 2px 10px;
|
padding: 2px 10px;
|
||||||
@ -505,5 +553,5 @@
|
|||||||
|
|
||||||
.weui-half-screen-dialog__ft {
|
.weui-half-screen-dialog__ft {
|
||||||
height: 0;
|
height: 0;
|
||||||
padding: 0;
|
/* padding: 0; */
|
||||||
}
|
}
|
@ -128,11 +128,11 @@ Page({
|
|||||||
Cache.set("token", res.accessToken);
|
Cache.set("token", res.accessToken);
|
||||||
//创建所属人
|
//创建所属人
|
||||||
if (res.phone && res.phone != '') {
|
if (res.phone && res.phone != '') {
|
||||||
|
//判断是否存在所属人
|
||||||
_self.setData({
|
_self.setData({
|
||||||
phone: res.phone
|
phone: res.phone
|
||||||
})
|
})
|
||||||
_self.doUpdateUserInfo('')
|
_self.doGetMineContact()
|
||||||
_self.doGetCsaNo()
|
|
||||||
} else {
|
} else {
|
||||||
//获取客服编号
|
//获取客服编号
|
||||||
wx.switchTab({
|
wx.switchTab({
|
||||||
@ -153,6 +153,34 @@ Page({
|
|||||||
_self.doShowExit()
|
_self.doShowExit()
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
//判断是否需要创建联系人
|
||||||
|
doGetMineContact() {
|
||||||
|
wx.showLoading({
|
||||||
|
title: '加载中...',
|
||||||
|
})
|
||||||
|
const data = {
|
||||||
|
page: 1,
|
||||||
|
rows: 2
|
||||||
|
}
|
||||||
|
UserApi.doGetMineContactList(data)
|
||||||
|
.then(res => {
|
||||||
|
wx.hideLoading()
|
||||||
|
if (res.rows && res.rows.length <= 0) {
|
||||||
|
//需要创建
|
||||||
|
_self.doUpdateUserInfo('')
|
||||||
|
_self.doGetCsaNo()
|
||||||
|
} else {
|
||||||
|
//无需创建
|
||||||
|
wx.switchTab({
|
||||||
|
url: '/pages/index/index',
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(err => {
|
||||||
|
wx.hideLoading()
|
||||||
|
_self.doShowExit()
|
||||||
|
})
|
||||||
|
},
|
||||||
//创建用户
|
//创建用户
|
||||||
doUpdateUserInfo(name) {
|
doUpdateUserInfo(name) {
|
||||||
const _self = this
|
const _self = this
|
||||||
|
File diff suppressed because one or more lines are too long
@ -179,7 +179,7 @@ Page({
|
|||||||
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的联系电话'
|
errorHint: '请输入正确的联系电话'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -187,7 +187,7 @@ Page({
|
|||||||
if (!isValidEmail(_self.data.contactEmail)) {
|
if (!isValidEmail(_self.data.contactEmail)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的邮箱'
|
errorHint: '请输入正确的邮箱'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -240,7 +240,7 @@ Page({
|
|||||||
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
if (_self.data.contactPhone == '' || !isValidPhone(_self.data.contactPhone)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的联系电话'
|
errorHint: '请输入正确的联系电话'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
@ -248,7 +248,7 @@ Page({
|
|||||||
if (!isValidEmail(_self.data.contactEmail)) {
|
if (!isValidEmail(_self.data.contactEmail)) {
|
||||||
_self.setData({
|
_self.setData({
|
||||||
showError: true,
|
showError: true,
|
||||||
errorHint: '请输入合法的邮箱'
|
errorHint: '请输入正确的邮箱'
|
||||||
})
|
})
|
||||||
return
|
return
|
||||||
}
|
}
|
||||||
|
@ -15,7 +15,7 @@
|
|||||||
<view class="contact-desc">
|
<view class="contact-desc">
|
||||||
<view class="contact-icon">
|
<view class="contact-icon">
|
||||||
<view class="ic-user" style="width: 24px;height: 24px;"></view>
|
<view class="ic-user" style="width: 24px;height: 24px;"></view>
|
||||||
<view class="ml-10">{{item.name}}</view>
|
<view class="ml-10 name">{{item.name}}</view>
|
||||||
</view>
|
</view>
|
||||||
<view>{{item.phone}}</view>
|
<view>{{item.phone}}</view>
|
||||||
<view class="options-box">
|
<view class="options-box">
|
||||||
@ -41,25 +41,25 @@
|
|||||||
<view class="form-box">
|
<view class="form-box">
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title">姓名</view>
|
<view class="form-item-title">姓名</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactName}}" placeholder="请输入联系人姓名" class="form-item-content" bindinput="inputContactName" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactName}}" placeholder="请输入姓名" class="form-item-content" bindinput="inputContactName" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title">联系电话</view>
|
<view class="form-item-title">联系电话</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactPhone}}" placeholder="请输入联系电话" class="form-item-content" bindinput="inputContactPhone" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactPhone}}" placeholder="请输入联系电话" class="form-item-content" bindinput="inputContactPhone" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title no-after">联系邮箱</view>
|
<view class="form-item-title no-after" style="padding-left: 16rpx;">联系邮箱</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactEmail}}" placeholder="请输入邮箱" class="form-item-content" bindinput="inputContactEmail" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactEmail}}" placeholder="请输入联系邮箱" class="form-item-content" bindinput="inputContactEmail" />
|
||||||
</view>
|
</view>
|
||||||
<view class="form-item">
|
<view class="form-item">
|
||||||
<view class="form-item-title no-after">公司</view>
|
<view class="form-item-title no-after" style="padding-left: 16rpx;">公司</view>
|
||||||
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactCompany}}" placeholder="请输入公司名称" class="form-item-content" bindinput="inputContactCompany" />
|
<input adjust-position="{{true}}" cursor-spacing="{{50}}" value="{{contactCompany}}" placeholder="请输入公司名称" class="form-item-content" bindinput="inputContactCompany" />
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view slot="footer">
|
<view slot="footer">
|
||||||
<button wx:if="{{isCreate}}" type="primary" bind:tap="doSaveContact">{{btnTxt}}</button>
|
<button wx:if="{{isCreate}}" class="confirm-btn" bind:tap="doSaveContact">{{btnTxt}}</button>
|
||||||
<button wx:if="{{!isCreate}}" type="primary" bind:tap="doEditContact">{{btnTxt}}</button>
|
<button wx:if="{{!isCreate}}" class="confirm-btn" bind:tap="doEditContact">{{btnTxt}}</button>
|
||||||
</view>
|
</view>
|
||||||
</mp-half-screen-dialog>
|
</mp-half-screen-dialog>
|
||||||
|
|
||||||
|
@ -17,10 +17,12 @@ page {
|
|||||||
position: fixed;
|
position: fixed;
|
||||||
top: 0;
|
top: 0;
|
||||||
left: 0;
|
left: 0;
|
||||||
width: 97vw;
|
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
|
justify-content: center;
|
||||||
|
align-self: center;
|
||||||
|
width: 96vw;
|
||||||
}
|
}
|
||||||
|
|
||||||
.search-container {
|
.search-container {
|
||||||
@ -29,7 +31,7 @@ page {
|
|||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
background-color: rgba(255, 255, 255, 1);
|
background-color: rgba(255, 255, 255, 1);
|
||||||
font-family: -regular;
|
font-family: -regular;
|
||||||
margin: 10px;
|
margin: 10px 15px;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@ -114,6 +116,15 @@ page {
|
|||||||
align-items: center;
|
align-items: center;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
.name {
|
||||||
|
line-height: 23rpx;
|
||||||
|
color: rgba(0, 0, 0, 1);
|
||||||
|
font-size: 32rpx;
|
||||||
|
text-align: left;
|
||||||
|
font-weight: bold;
|
||||||
|
font-family: SourceHanSansSC-black;
|
||||||
|
}
|
||||||
|
|
||||||
.service-desc {
|
.service-desc {
|
||||||
padding: 0px 15px 15px 15px;
|
padding: 0px 15px 15px 15px;
|
||||||
line-height: 20px;
|
line-height: 20px;
|
||||||
@ -128,10 +139,10 @@ page {
|
|||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
background-color: rgba(122, 196, 131, 0.42);
|
background-color: rgba(122, 196, 131, 0.42);
|
||||||
color: rgba(255, 255, 255, 1);
|
color: rgba(255, 255, 255, 1);
|
||||||
font-size: 14px;
|
font-size: 28rpx;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-family: PingFangSC-regular;
|
font-family: PingFangSC-regular;
|
||||||
padding: 5px 15px;
|
padding: 5rpx 10rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.del {
|
.del {
|
||||||
@ -139,10 +150,10 @@ page {
|
|||||||
border-radius: 4px;
|
border-radius: 4px;
|
||||||
background-color: rgba(247, 49, 42, 0.42);
|
background-color: rgba(247, 49, 42, 0.42);
|
||||||
color: rgba(255, 255, 255, 1);
|
color: rgba(255, 255, 255, 1);
|
||||||
font-size: 14px;
|
font-size: 28rpx;
|
||||||
text-align: center;
|
text-align: center;
|
||||||
font-family: PingFangSC-regular;
|
font-family: PingFangSC-regular;
|
||||||
padding: 5px 15px;
|
padding: 5rpx 10rpx;
|
||||||
margin-left: 5px;
|
margin-left: 5px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -188,7 +199,7 @@ page {
|
|||||||
text-align: left;
|
text-align: left;
|
||||||
}
|
}
|
||||||
|
|
||||||
.form-item-title:not(.no-after)::after {
|
.form-item-title:not(.no-after)::before {
|
||||||
content: "*";
|
content: "*";
|
||||||
color: red;
|
color: red;
|
||||||
font-size: 14px;
|
font-size: 14px;
|
||||||
@ -198,4 +209,23 @@ page {
|
|||||||
|
|
||||||
.form-item-content {
|
.form-item-content {
|
||||||
flex: 1;
|
flex: 1;
|
||||||
|
text-align: right;
|
||||||
|
}
|
||||||
|
|
||||||
|
.confirm-btn {
|
||||||
|
background-color: green;
|
||||||
|
color: white;
|
||||||
|
font-size: 16px;
|
||||||
|
height: 40px;
|
||||||
|
border-radius: 5px;
|
||||||
|
text-align: center;
|
||||||
|
width: 85vw !important;
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-half-screen-dialog__ft {
|
||||||
|
/* padding: 0rpx; */
|
||||||
|
}
|
||||||
|
|
||||||
|
.weui-half-screen-dialog__bd {
|
||||||
|
padding-bottom: 40rpx;
|
||||||
}
|
}
|
@ -5,10 +5,9 @@
|
|||||||
<view wx:if="{{keywords !=''}}" bind:tap="clearSearch" class="icon-clear" style="width: 20px;height: 20px;"></view>
|
<view wx:if="{{keywords !=''}}" bind:tap="clearSearch" class="icon-clear" style="width: 20px;height: 20px;"></view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="content-container">
|
<container-loading loadingState="{{loadingState}}" style="height: 85vh;margin-top: 80rpx;" bindrefresh="doRefreshList">
|
||||||
<container-loading loadingState="{{loadingState}}" style="height: 85vh;" bindrefresh="doRefreshList">
|
|
||||||
<scroll-view scroll-y="{{true}}" style="height: 85vh;" bindrefresherrefresh="doRefreshList" refresher-enabled refresher-triggered="{{listRefreshTrig}}" bindscrolltolower="doLoadMore" lower-threshold='30'>
|
<scroll-view scroll-y="{{true}}" style="height: 85vh;" bindrefresherrefresh="doRefreshList" refresher-enabled refresher-triggered="{{listRefreshTrig}}" bindscrolltolower="doLoadMore" lower-threshold='30'>
|
||||||
<view class="order-box" style="padding-bottom: 30px;">
|
<view class="order-box">
|
||||||
<block wx:for="{{orderList}}" wx:key="index">
|
<block wx:for="{{orderList}}" wx:key="index">
|
||||||
<view class="order-item">
|
<view class="order-item">
|
||||||
<view class="order-title">
|
<view class="order-title">
|
||||||
@ -40,6 +39,5 @@
|
|||||||
</view>
|
</view>
|
||||||
</scroll-view>
|
</scroll-view>
|
||||||
</container-loading>
|
</container-loading>
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
<wxs src="../../../../utils/comm.wxs" module="tools"></wxs>
|
<wxs src="../../../../utils/comm.wxs" module="tools"></wxs>
|
@ -1,6 +1,6 @@
|
|||||||
page {
|
page {
|
||||||
background: linear-gradient(to bottom, #F0F0F0, #FFFFFF);
|
background: linear-gradient(to bottom, #F0F0F0, #FFFFFF);
|
||||||
background-size: 100% 100vh;
|
background-size: 100vw 100vh;
|
||||||
background-repeat: no-repeat;
|
background-repeat: no-repeat;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -15,10 +15,10 @@ page {
|
|||||||
.search-container {
|
.search-container {
|
||||||
position: relative;
|
position: relative;
|
||||||
align-self: center;
|
align-self: center;
|
||||||
border-radius: 5px;
|
border-radius: 5rpx;
|
||||||
background-color: rgba(255, 255, 255, 1);
|
background-color: rgba(255, 255, 255, 1);
|
||||||
font-family: -regular;
|
font-family: -regular;
|
||||||
margin: 10px;
|
margin: 20rpx 30rpx;
|
||||||
padding: 5px;
|
padding: 5px;
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
@ -51,6 +51,7 @@ page {
|
|||||||
.content-container {
|
.content-container {
|
||||||
height: 86vh;
|
height: 86vh;
|
||||||
margin-top: 50px;
|
margin-top: 50px;
|
||||||
|
width: 100vw;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
@ -58,14 +59,13 @@ page {
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: center;
|
padding-bottom: 30px;
|
||||||
width: 100vw;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.order-item {
|
.order-item {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
width: 100vw;
|
flex-grow: 1;
|
||||||
}
|
}
|
||||||
|
|
||||||
.order-item:nth-of-type(n+2) {
|
.order-item:nth-of-type(n+2) {
|
||||||
@ -77,9 +77,10 @@ page {
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
width: 87vw;
|
|
||||||
padding: 8px 17px;
|
padding: 8px 17px;
|
||||||
background-color: #7AC483;
|
background-color: #7AC483;
|
||||||
|
border-top-left-radius: 5rpx;
|
||||||
|
border-top-right-radius: 5rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.order-no {
|
.order-no {
|
||||||
@ -98,9 +99,10 @@ page {
|
|||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: column;
|
flex-direction: column;
|
||||||
justify-content: center;
|
justify-content: center;
|
||||||
align-items: flex-start;
|
|
||||||
background-color: white;
|
background-color: white;
|
||||||
padding: 17px;
|
padding: 17px;
|
||||||
|
border-bottom-left-radius: 5rpx;
|
||||||
|
border-bottom-right-radius: 5rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.order-caption {
|
.order-caption {
|
||||||
@ -116,7 +118,6 @@ page {
|
|||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: space-between;
|
justify-content: space-between;
|
||||||
align-items: center;
|
align-items: center;
|
||||||
width: 87vw;
|
|
||||||
margin-top: 15px;
|
margin-top: 15px;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -151,10 +152,8 @@ page {
|
|||||||
.order-remark-box {
|
.order-remark-box {
|
||||||
display: flex;
|
display: flex;
|
||||||
flex-direction: row;
|
flex-direction: row;
|
||||||
justify-content: center;
|
|
||||||
align-items: center;
|
align-items: center;
|
||||||
margin-top: 10px;
|
margin-top: 10px;
|
||||||
width: 87vw;
|
|
||||||
}
|
}
|
||||||
|
|
||||||
.order-remark-title {
|
.order-remark-title {
|
||||||
@ -166,7 +165,7 @@ page {
|
|||||||
|
|
||||||
.order-remark-content {
|
.order-remark-content {
|
||||||
color: rgba(16, 16, 16, 1);
|
color: rgba(16, 16, 16, 1);
|
||||||
font-size: 10px;
|
font-size: 20rpx;
|
||||||
text-align: left;
|
text-align: left;
|
||||||
font-family: PingFangSC-light;
|
font-family: PingFangSC-light;
|
||||||
border-radius: 5px;
|
border-radius: 5px;
|
||||||
|
@ -1,5 +1,6 @@
|
|||||||
// pages/mine/mine.js
|
// pages/mine/mine.js
|
||||||
import UserApi from '../../../net/api/userApi'
|
import UserApi from '../../../net/api/userApi'
|
||||||
|
import ProApi from '../../../net/api/projectApi'
|
||||||
import {
|
import {
|
||||||
copyrightUrl
|
copyrightUrl
|
||||||
} from '../../../net/http'
|
} from '../../../net/http'
|
||||||
@ -9,6 +10,9 @@ const deviceInfo = wx.getDeviceInfo()
|
|||||||
const screenInfo = wx.getWindowInfo();
|
const screenInfo = wx.getWindowInfo();
|
||||||
const statusBarHeight = screenInfo.statusBarHeight; // 状态栏高度
|
const statusBarHeight = screenInfo.statusBarHeight; // 状态栏高度
|
||||||
const navBarHeight = deviceInfo.platform == 'IOS' ? 48 : 50; // 导航栏高度(iOS 为 44px,Android 为 48px)
|
const navBarHeight = deviceInfo.platform == 'IOS' ? 48 : 50; // 导航栏高度(iOS 为 44px,Android 为 48px)
|
||||||
|
const tabBarHeight = screenInfo.screenHeight - (screenInfo.safeArea ? screenInfo.safeArea.bottom : 50);
|
||||||
|
const screenHeight = screenInfo.screenHeight
|
||||||
|
const screenWidth = screenInfo.screenWidth
|
||||||
const windowHeight = screenInfo.windowHeight - navBarHeight - statusBarHeight; //可用内容高度
|
const windowHeight = screenInfo.windowHeight - navBarHeight - statusBarHeight; //可用内容高度
|
||||||
Page({
|
Page({
|
||||||
|
|
||||||
@ -20,6 +24,9 @@ Page({
|
|||||||
navBarHeight: navBarHeight,
|
navBarHeight: navBarHeight,
|
||||||
totalHeight: navBarHeight, // 导航栏总高度
|
totalHeight: navBarHeight, // 导航栏总高度
|
||||||
contentHeight: windowHeight,
|
contentHeight: windowHeight,
|
||||||
|
screenHeight: screenHeight, //屏幕高度
|
||||||
|
screenWidth: screenWidth, //屏幕宽度
|
||||||
|
tabBarHeight: tabBarHeight, //tabbar高度
|
||||||
allCount: 0,
|
allCount: 0,
|
||||||
materialCount: 0,
|
materialCount: 0,
|
||||||
accountInfo: {},
|
accountInfo: {},
|
||||||
@ -49,6 +56,26 @@ Page({
|
|||||||
errorHint: '',
|
errorHint: '',
|
||||||
animationData: {}, //刷新动画
|
animationData: {}, //刷新动画
|
||||||
animation: null,
|
animation: null,
|
||||||
|
tabList: [{
|
||||||
|
"pagePath": "pages/index/index",
|
||||||
|
"text": "首页",
|
||||||
|
"iconPath": "/static/images/ic_home_normal.png",
|
||||||
|
"selectedIconPath": "/static/images/ic_home_select.png",
|
||||||
|
"selected": true
|
||||||
|
},
|
||||||
|
{
|
||||||
|
"pagePath": "pages/mine/mineIndex/mine",
|
||||||
|
"text": "我的",
|
||||||
|
"iconPath": "/static/images/ic_mine_normal.png",
|
||||||
|
"selectedIconPath": "/static/images/ic_mine_select.png",
|
||||||
|
"selected": false
|
||||||
|
}
|
||||||
|
],
|
||||||
|
color: "#515151",
|
||||||
|
selectedColor: "#FE9944",
|
||||||
|
allPrice: 0, //全托管价格
|
||||||
|
materialPrice: 0, //写材料价格
|
||||||
|
urgent: 0, //加急价格
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
@ -58,10 +85,6 @@ Page({
|
|||||||
const _self = this
|
const _self = this
|
||||||
_self.getMineAccount()
|
_self.getMineAccount()
|
||||||
_self.getMinePackageCount()
|
_self.getMinePackageCount()
|
||||||
const h = Utils.pxToRpx(_self.data.contentHeight)
|
|
||||||
_self.setData({
|
|
||||||
contentHeight: h
|
|
||||||
})
|
|
||||||
// 创建一个动画实例
|
// 创建一个动画实例
|
||||||
const animation = wx.createAnimation({
|
const animation = wx.createAnimation({
|
||||||
duration: 1000,
|
duration: 1000,
|
||||||
@ -70,6 +93,125 @@ Page({
|
|||||||
this.setData({
|
this.setData({
|
||||||
animation: animation
|
animation: animation
|
||||||
})
|
})
|
||||||
|
this.countViewHeight()
|
||||||
|
this.doGetPrice()
|
||||||
|
},
|
||||||
|
//计算高度
|
||||||
|
countViewHeight() {
|
||||||
|
//
|
||||||
|
const query = wx.createSelectorQuery();
|
||||||
|
const _self = this
|
||||||
|
// 指定要查询的 view 元素
|
||||||
|
query.select('#func-box').boundingClientRect();
|
||||||
|
query.exec((res) => {
|
||||||
|
if (res[0]) {
|
||||||
|
const height = res[0].height;
|
||||||
|
//屏幕高度-内容高度-tabbar高度
|
||||||
|
const contentHeight = _self.data.screenHeight - height - 50
|
||||||
|
const h = Utils.pxToRpx(contentHeight, _self.data.screenWidth)
|
||||||
|
const tempH = h - 140
|
||||||
|
console.log('转后', h, '内容高度:', tempH)
|
||||||
|
_self.setData({
|
||||||
|
contentHeight: tempH
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
console.log('未找到指定的 view 元素');
|
||||||
|
}
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//跳转创建项目页面
|
||||||
|
openCreate(e) {
|
||||||
|
//计算价格
|
||||||
|
const _self = this
|
||||||
|
const type = e.currentTarget.dataset.type
|
||||||
|
if (type == 'ALL') {
|
||||||
|
if (_self.data.allCount > 0) {
|
||||||
|
_self.doGetPackage(type)
|
||||||
|
} else {
|
||||||
|
//提示充值
|
||||||
|
_self.setData({
|
||||||
|
errorHint: '您的账户当前无套餐包,为正常使用请及时充值。',
|
||||||
|
showError: true
|
||||||
|
})
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
if (_self.data.materialCount > 0) {
|
||||||
|
_self.doGetPackage(type)
|
||||||
|
} else {
|
||||||
|
//提示充值
|
||||||
|
_self.setData({
|
||||||
|
errorHint: '您的账户当前无套餐包,为正常使用请及时充值。',
|
||||||
|
showError: true
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
},
|
||||||
|
//获取套餐包详情
|
||||||
|
doGetPackage(type) {
|
||||||
|
const _self = this
|
||||||
|
const data = {
|
||||||
|
page: 1,
|
||||||
|
rows: 10,
|
||||||
|
packageType: type,
|
||||||
|
keyong: 1,
|
||||||
|
}
|
||||||
|
ProApi.doGetPackageList(data)
|
||||||
|
.then(res => {
|
||||||
|
console.log(res.rows)
|
||||||
|
if (res.rows && res.rows.length > 0) {
|
||||||
|
const packageId = res.rows[0].packageInfoId
|
||||||
|
const price = type == 'ALL' ? _self.data.allPrice : _self.data.materialPrice
|
||||||
|
wx.navigateTo({
|
||||||
|
url: '../../copyright/createProjectInfo/createProjectInfo?type=' + type + '&price=' + price + '&isUrgent=false&pId=' + packageId,
|
||||||
|
})
|
||||||
|
} else {
|
||||||
|
_self.setData({
|
||||||
|
errorHint: '您的账户当前无套餐包,为正常使用请及时充值。',
|
||||||
|
showError: true
|
||||||
|
})
|
||||||
|
}
|
||||||
|
})
|
||||||
|
.catch(err => {
|
||||||
|
_self.setData({
|
||||||
|
errorHint: '获取套餐包失败,请稍后重试',
|
||||||
|
showError: true
|
||||||
|
})
|
||||||
|
})
|
||||||
|
},
|
||||||
|
//获取单价
|
||||||
|
doGetPrice() {
|
||||||
|
wx.showLoading({
|
||||||
|
title: '加载中...',
|
||||||
|
})
|
||||||
|
const _self = this
|
||||||
|
ProApi.doGetPrice()
|
||||||
|
.then(res => {
|
||||||
|
wx.hideLoading()
|
||||||
|
console.log(res)
|
||||||
|
res.projTypes.forEach(el => {
|
||||||
|
if (el.type == 'ALL') {
|
||||||
|
_self.setData({
|
||||||
|
allPrice: el.price
|
||||||
|
})
|
||||||
|
} else if (el.type == 'MATERIAL') {
|
||||||
|
_self.setData({
|
||||||
|
materialPrice: el.price
|
||||||
|
})
|
||||||
|
}
|
||||||
|
});
|
||||||
|
_self.setData({
|
||||||
|
urgent: res.additional.urgent, //加急办理
|
||||||
|
})
|
||||||
|
}, err => {
|
||||||
|
wx.hideLoading()
|
||||||
|
wx.showToast({
|
||||||
|
title: '数据有误,请稍后重试',
|
||||||
|
icon: 'error',
|
||||||
|
success: () => {
|
||||||
|
wx.navigateBack()
|
||||||
|
}
|
||||||
|
})
|
||||||
|
})
|
||||||
},
|
},
|
||||||
//刷新账户
|
//刷新账户
|
||||||
doRefresh() {
|
doRefresh() {
|
||||||
@ -77,6 +219,7 @@ Page({
|
|||||||
_self.playAnimation()
|
_self.playAnimation()
|
||||||
_self.getMineAccount() //获取账户信息
|
_self.getMineAccount() //获取账户信息
|
||||||
_self.getMinePackageCount() //获取套餐包信息
|
_self.getMinePackageCount() //获取套餐包信息
|
||||||
|
_self.doGetPrice() //获取单价
|
||||||
},
|
},
|
||||||
//播放刷新动画
|
//播放刷新动画
|
||||||
playAnimation() {
|
playAnimation() {
|
||||||
@ -101,6 +244,15 @@ Page({
|
|||||||
}, 1100);
|
}, 1100);
|
||||||
},
|
},
|
||||||
onShow(options) {
|
onShow(options) {
|
||||||
|
const pages = getCurrentPages();
|
||||||
|
const currentPage = pages[pages.length - 1];
|
||||||
|
const tabList = this.data.tabList;
|
||||||
|
tabList.forEach(item => {
|
||||||
|
item.selected = item.pagePath === currentPage.route;
|
||||||
|
});
|
||||||
|
this.setData({
|
||||||
|
tabList
|
||||||
|
});
|
||||||
this.getMineAccount() //获取账户信息
|
this.getMineAccount() //获取账户信息
|
||||||
this.getMinePackageCount() //获取套餐包信息
|
this.getMinePackageCount() //获取套餐包信息
|
||||||
},
|
},
|
||||||
|
@ -1,7 +1,8 @@
|
|||||||
{
|
{
|
||||||
"usingComponents": {
|
"usingComponents": {
|
||||||
"mp-dialog": "weui-miniprogram/dialog/dialog",
|
"mp-dialog": "weui-miniprogram/dialog/dialog",
|
||||||
"mp-toptips": "weui-miniprogram/toptips/toptips"
|
"mp-toptips": "weui-miniprogram/toptips/toptips",
|
||||||
|
"custom-tabbar": "/components/tabbar/custom-tabbar"
|
||||||
},
|
},
|
||||||
"navigationStyle": "custom",
|
"navigationStyle": "custom",
|
||||||
"enablePullDownRefresh": true
|
"enablePullDownRefresh": true
|
||||||
|
@ -1,10 +1,10 @@
|
|||||||
<view class="bg-container">
|
<view class="bg-container">
|
||||||
<image class="bg-image" src="/static/images/bg_mine.png"></image>
|
<image class="bg-image" src="/static/images/bg_mine.png"></image>
|
||||||
<view class="content-container">
|
<view class="content-container">
|
||||||
|
<view id="func-box" style="padding: 0rpx 30rpx;">
|
||||||
<view class="custom-navbar" style="height: {{totalHeight}}px; padding-top: {{statusBarHeight}}px;justify-content: center;">
|
<view class="custom-navbar" style="height: {{totalHeight}}px; padding-top: {{statusBarHeight}}px;justify-content: center;">
|
||||||
<view class="navbar-title" style="color:#532A00;">AI喵著</view>
|
<view class="navbar-title" style="color:#532A00;">AI喵著</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="container-content">
|
|
||||||
<view class="container-box">
|
<view class="container-box">
|
||||||
<view class="box-up">
|
<view class="box-up">
|
||||||
<view class="balance" bind:tap="doRefresh">
|
<view class="balance" bind:tap="doRefresh">
|
||||||
@ -19,11 +19,11 @@
|
|||||||
<view class="box-down">
|
<view class="box-down">
|
||||||
<view>套餐包余额</view>
|
<view>套餐包余额</view>
|
||||||
<view class="package-bag">
|
<view class="package-bag">
|
||||||
<view class="package-bag-item">
|
<view class="package-bag-item" bind:tap="openCreate" data-type="ALL">
|
||||||
<text class="title">全托管</text>
|
<text class="title">全托管</text>
|
||||||
<text class="num">{{allCount}}</text>
|
<text class="num">{{allCount}}</text>
|
||||||
</view>
|
</view>
|
||||||
<view class="package-bag-item">
|
<view class="package-bag-item" bind:tap="openCreate" data-type="MATERIAL">
|
||||||
<text class="title">写材料</text>
|
<text class="title">写材料</text>
|
||||||
<text class="num">{{materialCount}}</text>
|
<text class="num">{{materialCount}}</text>
|
||||||
</view>
|
</view>
|
||||||
@ -34,8 +34,9 @@
|
|||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
<view class="menu-box" style="height: {{contentHeight+190}}rpx;">
|
</view>
|
||||||
<scroll-view scroll-y style="height: {{contentHeight+190}}rpx;">
|
<view class="menu-box" style="height: {{contentHeight}}rpx;">
|
||||||
|
<scroll-view scroll-y style="height: {{contentHeight}}rpx;">
|
||||||
<view class="menu-container">
|
<view class="menu-container">
|
||||||
<block wx:for="{{menuList}}" wx:key="index">
|
<block wx:for="{{menuList}}" wx:key="index">
|
||||||
<view class="menu-item" bind:tap="itemClick" hover-class="menu-item-active" data-path="{{item.path}}">
|
<view class="menu-item" bind:tap="itemClick" hover-class="menu-item-active" data-path="{{item.path}}">
|
||||||
@ -48,8 +49,8 @@
|
|||||||
</scroll-view>
|
</scroll-view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
</view>
|
||||||
</view>
|
|
||||||
</view>
|
</view>
|
||||||
|
<custom-tabbar tabList="{{tabList}}" color="{{color}}" selectedColor="{{selectedColor}}"></custom-tabbar>
|
||||||
<mp-dialog title="提示" show="{{showHint}}" buttons="{{buttons}}" bindbuttontap="closeHint">
|
<mp-dialog title="提示" show="{{showHint}}" buttons="{{buttons}}" bindbuttontap="closeHint">
|
||||||
<view style="color: black;">{{hintTxt}}</view>
|
<view style="color: black;">{{hintTxt}}</view>
|
||||||
</mp-dialog>
|
</mp-dialog>
|
||||||
|
@ -17,7 +17,6 @@
|
|||||||
|
|
||||||
.content-container {
|
.content-container {
|
||||||
position: relative;
|
position: relative;
|
||||||
padding: 0rpx 10rpx 10rpx 10rpx;
|
|
||||||
z-index: 1;
|
z-index: 1;
|
||||||
color: white;
|
color: white;
|
||||||
}
|
}
|
||||||
@ -131,6 +130,8 @@
|
|||||||
background: white;
|
background: white;
|
||||||
border-radius: 20rpx;
|
border-radius: 20rpx;
|
||||||
padding-top: 20rpx;
|
padding-top: 20rpx;
|
||||||
|
margin-left: 30rpx;
|
||||||
|
margin-right: 30rpx;
|
||||||
}
|
}
|
||||||
|
|
||||||
.menu-item {
|
.menu-item {
|
||||||
|
@ -3,11 +3,16 @@ var isEmpty = function (obj) {
|
|||||||
if (typeof obj !== 'object') return false;
|
if (typeof obj !== 'object') return false;
|
||||||
return JSON.stringify(obj) === '{}';
|
return JSON.stringify(obj) === '{}';
|
||||||
};
|
};
|
||||||
var status = function (value) {
|
//state=AiSetting, value=generate
|
||||||
var status = '排队中...'
|
var status = function (value, state) {
|
||||||
|
var status = '未生成'
|
||||||
|
if (state == 'SUCCESS') {
|
||||||
switch (value) {
|
switch (value) {
|
||||||
case 'NONE':
|
case 'NONE':
|
||||||
status = '排队中...'
|
status = '未生成'
|
||||||
|
break
|
||||||
|
case 'PENDING':
|
||||||
|
status = '等待'
|
||||||
break
|
break
|
||||||
case 'GENERATING':
|
case 'GENERATING':
|
||||||
status = '生成中...'
|
status = '生成中...'
|
||||||
@ -19,6 +24,19 @@ var status = function (value) {
|
|||||||
status = '生成失败'
|
status = '生成失败'
|
||||||
break
|
break
|
||||||
}
|
}
|
||||||
|
} else {
|
||||||
|
switch (state) {
|
||||||
|
case 'FAILED':
|
||||||
|
status = '生成失败'
|
||||||
|
break
|
||||||
|
case 'GENERATING':
|
||||||
|
status = '生成中...'
|
||||||
|
break
|
||||||
|
case 'NONE':
|
||||||
|
status = '未生成'
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
return status
|
return status
|
||||||
};
|
};
|
||||||
var orderStatus = function (value) {
|
var orderStatus = function (value) {
|
||||||
@ -42,6 +60,37 @@ var orderStatus = function (value) {
|
|||||||
}
|
}
|
||||||
return statusStr
|
return statusStr
|
||||||
};
|
};
|
||||||
|
var statusColor = function (value, state) {
|
||||||
|
var color = 'status-gray'
|
||||||
|
if (state == 'SUCCESS') {
|
||||||
|
switch (value) {
|
||||||
|
case 'NONE':
|
||||||
|
case 'PENDING':
|
||||||
|
color = 'status-gray'
|
||||||
|
break
|
||||||
|
case 'GENERATING':
|
||||||
|
case 'SUCCESS':
|
||||||
|
color = 'status-green'
|
||||||
|
break
|
||||||
|
case 'FAILED':
|
||||||
|
color = 'status-red'
|
||||||
|
break
|
||||||
|
}
|
||||||
|
} else {
|
||||||
|
switch (state) {
|
||||||
|
case 'GENERATING':
|
||||||
|
color = 'status-green'
|
||||||
|
break
|
||||||
|
case 'FAILED':
|
||||||
|
color = 'status-red'
|
||||||
|
break
|
||||||
|
case 'NONE':
|
||||||
|
color = 'status-gray'
|
||||||
|
break
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return color
|
||||||
|
}
|
||||||
var proType = function (value) {
|
var proType = function (value) {
|
||||||
// PROJ:项目、AGENT:代理、FULL_REFUND:全额退款、CORRECTION1_REFUND:补正1次退款、CORRECTION2_REFUND:补正2次退款
|
// PROJ:项目、AGENT:代理、FULL_REFUND:全额退款、CORRECTION1_REFUND:补正1次退款、CORRECTION2_REFUND:补正2次退款
|
||||||
var str = '项目创建'
|
var str = '项目创建'
|
||||||
@ -109,5 +158,6 @@ module.exports = {
|
|||||||
proType: proType,
|
proType: proType,
|
||||||
boderStyle: boderStyle,
|
boderStyle: boderStyle,
|
||||||
fontColor: fontColor,
|
fontColor: fontColor,
|
||||||
timeSplit: timeSplit
|
timeSplit: timeSplit,
|
||||||
|
statusColor: statusColor
|
||||||
};
|
};
|
@ -62,8 +62,11 @@ const dateTimePicker = (startYear, endYear) => {
|
|||||||
};
|
};
|
||||||
}
|
}
|
||||||
|
|
||||||
const pxToRpx = (pxValue) => {
|
const pxToRpx = (pxValue, screenWidth) => {
|
||||||
return (pxValue / 750) * 750;
|
console.log('转换Px', pxValue, '屏幕宽度', screenWidth)
|
||||||
|
// return pxValue * (750 / screenWidth);
|
||||||
|
const rpx = (750 / screenWidth) * Number(pxValue)
|
||||||
|
return Math.floor(rpx);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user