开始做发票
This commit is contained in:
parent
d873a722a1
commit
11f208a513
4
app.json
4
app.json
|
@ -1,7 +1,8 @@
|
|||
{
|
||||
"pages": [
|
||||
"pages/home/index",
|
||||
"pages/invoiceDetail/index",
|
||||
"pages/invoicing/index",
|
||||
"pages/home/index",
|
||||
"pages/invoiceList/index",
|
||||
"pages/rechargeRecord/index",
|
||||
"pages/member/index",
|
||||
|
@ -14,7 +15,6 @@
|
|||
"pages/meterList/index",
|
||||
"pages/recharge/index",
|
||||
"pages/questions/index",
|
||||
"pages/invoiceDetail/index",
|
||||
"pages/editInvoice/index",
|
||||
"pages/rechargeDetail/index",
|
||||
"pages/agreements/index"
|
||||
|
|
|
@ -44,8 +44,8 @@
|
|||
<view>
|
||||
不知道预留的手机号?可联系后台管理员查询!
|
||||
</view>
|
||||
<view class="phone" bind:tap="callPhone" data-phone="13266911877">
|
||||
<van-icon name="phone-o" class="phoneIcon" /> 13266911877
|
||||
<view class="phone" bind:tap="callPhone" data-phone="0311-83864830">
|
||||
<van-icon name="phone-o" class="phoneIcon" /> 0311-83864830
|
||||
</view>
|
||||
</view>
|
||||
</view>
|
||||
|
|
|
@ -63,7 +63,8 @@ Page({
|
|||
},
|
||||
async refreshMeter() {
|
||||
const { meter } = this.data;
|
||||
this.handleGetMeterDetail(meter.code);
|
||||
console.log('meter', meter)
|
||||
this.handleGetMeterDetail(meter.id);
|
||||
},
|
||||
onOk(e) {
|
||||
const { type, index, value } = e.detail;
|
||||
|
|
|
@ -1,6 +1,8 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"van-field": "@vant/weapp/field/index",
|
||||
"van-button": "@vant/weapp/button/index"
|
||||
}
|
||||
"van-button": "@vant/weapp/button/index",
|
||||
"navigator": "/components/navigator/index"
|
||||
},
|
||||
"navigationStyle": "custom"
|
||||
}
|
|
@ -1,5 +1,5 @@
|
|||
<!--pages/invoiceInfo/index.wxml-->
|
||||
<van-cell-group>
|
||||
<!-- <van-cell-group>
|
||||
<van-field
|
||||
value="{{ detail.name }}"
|
||||
label="公司名称"
|
||||
|
@ -47,4 +47,9 @@
|
|||
<view class="wrapper operate">
|
||||
<van-button type="default" block style="flex: 1" bind:click="handleBack">返回</van-button>
|
||||
<van-button type="info" block style="margin-left: 30rpx;flex: 1;">编辑</van-button>
|
||||
</view> -->
|
||||
|
||||
<navigator title="发票详细" canBack="{{true}}" bind:back="back" />
|
||||
<view class="wrapper">
|
||||
<view> 尊敬的客户,您好 </view>
|
||||
</view>
|
24
pages/invoicing/components/card/index.js
Normal file
24
pages/invoicing/components/card/index.js
Normal file
|
@ -0,0 +1,24 @@
|
|||
// pages/invoicing/components/card/index.js
|
||||
Component({
|
||||
|
||||
/**
|
||||
* 组件的属性列表
|
||||
*/
|
||||
properties: {
|
||||
title: String,
|
||||
},
|
||||
|
||||
/**
|
||||
* 组件的初始数据
|
||||
*/
|
||||
data: {
|
||||
|
||||
},
|
||||
|
||||
/**
|
||||
* 组件的方法列表
|
||||
*/
|
||||
methods: {
|
||||
|
||||
}
|
||||
})
|
4
pages/invoicing/components/card/index.json
Normal file
4
pages/invoicing/components/card/index.json
Normal file
|
@ -0,0 +1,4 @@
|
|||
{
|
||||
"component": true,
|
||||
"usingComponents": {}
|
||||
}
|
7
pages/invoicing/components/card/index.wxml
Normal file
7
pages/invoicing/components/card/index.wxml
Normal file
|
@ -0,0 +1,7 @@
|
|||
<!--pages/invoicing/components/card/index.wxml-->
|
||||
<view class="cardBox">
|
||||
<view class="title"> {{ title }} </view>
|
||||
<view class="content">
|
||||
<slot />
|
||||
</view>
|
||||
</view>
|
17
pages/invoicing/components/card/index.wxss
Normal file
17
pages/invoicing/components/card/index.wxss
Normal file
|
@ -0,0 +1,17 @@
|
|||
/* pages/invoicing/components/card/index.wxss */
|
||||
.cardBox {
|
||||
margin-left: 32rpx;
|
||||
margin-right: 32rpx;
|
||||
padding: 2rpx 24rpx 24rpx;
|
||||
background-color: #fff;
|
||||
border-radius: 20rpx;
|
||||
}
|
||||
|
||||
.title {
|
||||
font-size: 38rpx;
|
||||
font-weight: 600;
|
||||
border-bottom: 1rpx solid #ccc;
|
||||
height: 80rpx;
|
||||
line-height: 80rpx;
|
||||
margin-bottom: 24rpx;
|
||||
}
|
|
@ -9,6 +9,7 @@ Page({
|
|||
tenement: "",
|
||||
ids: [],
|
||||
count: 0,
|
||||
show: false,
|
||||
},
|
||||
|
||||
/**
|
||||
|
@ -33,7 +34,9 @@ Page({
|
|||
onShow() {
|
||||
|
||||
},
|
||||
|
||||
changeShow() {
|
||||
this.setData({ show: true })
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面隐藏
|
||||
*/
|
||||
|
|
|
@ -1,7 +1,12 @@
|
|||
{
|
||||
"usingComponents": {
|
||||
"navigator": "/components/navigator/index",
|
||||
"van-button": "@vant/weapp/button/index"
|
||||
"van-button": "@vant/weapp/button/index",
|
||||
"card": "./components/card/index",
|
||||
"van-radio": "@vant/weapp/radio/index",
|
||||
"van-radio-group": "@vant/weapp/radio-group/index",
|
||||
"van-field": "@vant/weapp/field/index",
|
||||
"van-dialog": "@vant/weapp/dialog/index"
|
||||
},
|
||||
"navigationStyle": "custom"
|
||||
}
|
|
@ -1,14 +1,129 @@
|
|||
<!--pages/invoicing/index.wxml-->
|
||||
<navigator title="1111" canBack="{{true}}" />
|
||||
<navigator title="发票开具" canBack="{{true}}" />
|
||||
<view class="info">
|
||||
<view class="money"> 发票金额:<text class="moneyNumber"> {{money}} </text> </view>
|
||||
<view class="money"> 发票金额:<text class="moneyNumber"> ¥ {{money}} </text> </view>
|
||||
<view class="content">发票内容:<text class="contentText">电费</text> </view>
|
||||
</view>
|
||||
<view class="type"></view>
|
||||
|
||||
<view>
|
||||
<card title="发票类型">
|
||||
<van-radio-group disabled="{{true}}" direction="horizontal">
|
||||
<van-radio name="1" icon-size="30rpx" style="font-size: 32rpx;margin-bottom: 20rpx;">普通电子发票</van-radio>
|
||||
<van-radio name="2" icon-size="30rpx" style="font-size: 32rpx;">增值税专用电子发票</van-radio>
|
||||
</van-radio-group>
|
||||
</card>
|
||||
</view>
|
||||
<view class="cardWrapper">
|
||||
<card title="发票详情">
|
||||
<van-field
|
||||
value="{{ detail.name }}"
|
||||
label="抬头类型"
|
||||
border="{{ false }}"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
>
|
||||
<view slot="input" style="margin-top: 16rpx;">
|
||||
<van-radio-group disabled="{{true}}" direction="horizontal">
|
||||
<van-radio name="1" icon-size="30rpx" style="font-size: 30rpx;margin-bottom: 20rpx;">企业单位</van-radio>
|
||||
<van-radio name="2" icon-size="30rpx" style="font-size: 30rpx;">个人/非企业单位</van-radio>
|
||||
</van-radio-group>
|
||||
</view>
|
||||
|
||||
</van-field>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="发票抬头"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="发票税号"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="开户行"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="银行账号"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="地址"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="电话"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
disabled="{{true}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="备注说明"
|
||||
title-width="132rpx"
|
||||
/>
|
||||
</card>
|
||||
</view>
|
||||
<view class="content">
|
||||
|
||||
</view>
|
||||
<view class="submit">
|
||||
<van-button type="info" block> 提交 </van-button>
|
||||
</view>
|
||||
<van-button type="info" block bind:click="changeShow"> 立即申请 </van-button>
|
||||
</view>
|
||||
|
||||
<van-dialog
|
||||
use-slot
|
||||
title="确认开具"
|
||||
show="{{ show }}"
|
||||
show-cancel-button
|
||||
>
|
||||
<view class="modalContentWrapper">
|
||||
<van-field
|
||||
value="{{ '河北华昌宝能售电有限公司' }}"
|
||||
label="发票抬头"
|
||||
readonly
|
||||
type="textarea"
|
||||
autosize="{{true}}"
|
||||
title-width="132rpx"
|
||||
border="{{false}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ 99.99 }}"
|
||||
label="发票金额"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
border="{{false}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '普通发票' }}"
|
||||
label="发票类型"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
border="{{false}}"
|
||||
/>
|
||||
<van-field
|
||||
value="{{ '123456@qq.com' }}"
|
||||
label="邮箱地址"
|
||||
readonly
|
||||
title-width="132rpx"
|
||||
type="textarea"
|
||||
autosize="{{true}}"
|
||||
border="{{false}}"
|
||||
/>
|
||||
</view>
|
||||
|
||||
</van-dialog>
|
|
@ -4,6 +4,7 @@
|
|||
margin-left: 32rpx;
|
||||
margin-right: 32rpx;
|
||||
margin-bottom: 40rpx;
|
||||
padding-bottom: 40rpx;
|
||||
}
|
||||
|
||||
.info {
|
||||
|
@ -29,3 +30,15 @@
|
|||
page {
|
||||
background-color: var(--transparent-green);
|
||||
}
|
||||
|
||||
.cardWrapper {
|
||||
margin-top: 30rpx;
|
||||
}
|
||||
|
||||
.van-cell {
|
||||
padding-left: 0rpx !important;
|
||||
padding-right: 0rpx !important;
|
||||
}
|
||||
.modalContentWrapper{
|
||||
margin: 20rpx 30rpx;
|
||||
}
|
||||
|
|
|
@ -87,7 +87,7 @@ Page({
|
|||
show: false,
|
||||
title: ""
|
||||
})
|
||||
this.init(year, e)
|
||||
this.init(year, id)
|
||||
},
|
||||
/**
|
||||
* 生命周期函数--监听页面显示
|
||||
|
@ -103,9 +103,10 @@ Page({
|
|||
alertInfo(message)
|
||||
return
|
||||
}
|
||||
let tenements = [];
|
||||
let tenements = [{id: "", name: "全部"}];
|
||||
data.forEach(item => {
|
||||
if (item.tenements) {
|
||||
console.log('item.te', item.tenements)
|
||||
tenements = [...tenements, ...item.tenements]
|
||||
}
|
||||
})
|
||||
|
|
|
@ -7,8 +7,8 @@ export const getMeterList = async function() {
|
|||
}
|
||||
|
||||
// 获取表计详情
|
||||
export const getMeterDetail = async function({ tenement, code }) {
|
||||
return await GET(`/wx/getMeterDetail/${tenement}/${code}`);
|
||||
export const getMeterDetail = async function({ tenement, id }) {
|
||||
return await GET(`/wx/getMeterDetail/${tenement}/${id}`);
|
||||
}
|
||||
|
||||
// 获取某一商户的电表列表
|
||||
|
|
|
@ -1,11 +1,9 @@
|
|||
export const getRechargeOperateType = (num) => {
|
||||
console.log('typenum', num)
|
||||
const types = ["充值", "冲正", "退费"]
|
||||
return types[num];
|
||||
}
|
||||
|
||||
export const getRechargeOperateWay = (num) => {
|
||||
console.log('num', num)
|
||||
const types = ["现金", "银行卡", "支付宝", "微信", "云闪付","对公转账", "微信-支付"]
|
||||
const types = ["现金", "银行卡", "支付宝", "微信", "云闪付","对公转账", "小程序-微信支付"]
|
||||
return types[num];
|
||||
}
|
|
@ -19,6 +19,7 @@ const requestWithoutCookie = promisify(wx.request);
|
|||
|
||||
// 考虑了Cookie的请求
|
||||
const request = async function (options, config = {}) {
|
||||
console.log('请求参数', 'options', options, 'config', config)
|
||||
let token = wx.getStorageSync('token');
|
||||
const result = wx.getAccountInfoSync();
|
||||
const { envVersion } = result.miniProgram;
|
||||
|
|
Loading…
Reference in New Issue
Block a user