fix: 智聪记账管理,统计页面,增加tab按钮。
This commit is contained in:
@@ -139,6 +139,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>账户收支统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -50,14 +50,31 @@
|
||||
</div>
|
||||
</div>
|
||||
|
||||
<div></div>
|
||||
|
||||
</div>
|
||||
<u-list @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<div style="margin:8px">
|
||||
<button :type="firstType" style="margin-right:5px" size=mini @click="btFirstClick">账户余额</button>
|
||||
<button :type="secondType" type="primary" size=mini @click="btSecondClick">信用卡可用余额</button>
|
||||
</div>
|
||||
<u-list v-show="!tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.account+':'+item.availableLimit" size="30rpx" color="#333333" ></u--text>
|
||||
:text="item.account+':'+item.availableLimit+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</u-list-item>
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-list v-show="tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in secondListData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.account+':'+item.availableLimit+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
@@ -84,12 +101,18 @@
|
||||
import {reactive ,toRefs,ref,computed }from "vue";
|
||||
const pageNum = ref(1)
|
||||
const listData = ref([])
|
||||
|
||||
const isShow = ref(false)
|
||||
const accountTypeList = ref([])
|
||||
const settingPickShow = ref(false)
|
||||
const settingColumns = ref([])
|
||||
const showAccount = ref(false)
|
||||
|
||||
const tabShow = ref(false)
|
||||
const secondListData = ref([])
|
||||
const firstType = ref("primary")
|
||||
const secondType = ref("default")
|
||||
|
||||
const accountsBalance = ref({
|
||||
debetBalance: '',
|
||||
creditAvailableLimit: '',
|
||||
@@ -128,16 +151,30 @@
|
||||
getAccountsAnalysis({...queryParams.value }).then(res => {
|
||||
accountsBalance.value = { ...res.data }
|
||||
listData.value = listData.value.concat(res.data.accountsBalancesList)
|
||||
secondListData.value = secondListData.value.concat(res.data.creditBalancesList)
|
||||
}).catch(() => {
|
||||
})
|
||||
}
|
||||
function getDict() {
|
||||
function getDict() {
|
||||
// 记账类型类型
|
||||
getDicts('account_type').then(res => {
|
||||
accountTypeList.value =[res.data]
|
||||
})
|
||||
|
||||
}
|
||||
|
||||
function btFirstClick() {
|
||||
tabShow.value=false
|
||||
firstType.value="primary"
|
||||
secondType.value="default"
|
||||
|
||||
}
|
||||
function btSecondClick() {
|
||||
secondType.value="primary"
|
||||
firstType.value="default"
|
||||
tabShow.value=true
|
||||
|
||||
}
|
||||
function settingConfirm(e) {
|
||||
queryParams.value.settingId = e.value[0].settingId
|
||||
queryParams.value.settingName = e.value[0].settingName
|
||||
@@ -177,6 +214,18 @@
|
||||
<style lang="scss" scoped>
|
||||
|
||||
.app-container {
|
||||
|
||||
/* 在App.vue的<style>中或者单独的style文件中 */
|
||||
.btn-normal {
|
||||
background-color: #f0f0f0;
|
||||
color: #333;
|
||||
}
|
||||
|
||||
.btn-selected {
|
||||
background-color: #007AFF;
|
||||
color: #fff;
|
||||
}
|
||||
|
||||
.header-con {
|
||||
width: 100%;
|
||||
height: 100px;
|
||||
|
||||
@@ -147,6 +147,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>信用卡收支统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -196,18 +196,36 @@
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<div style="margin:8px">
|
||||
<button :type="classType" type="primary" size=mini @click="btClassClick">日期统计</button>
|
||||
<button :type="dayType" style="margin-right:5px" size=mini @click="btDayClick">分类统计</button>
|
||||
|
||||
</div>
|
||||
<u-list v-show="!tabShow" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.time+' 支出金额:'+item.value" size="30rpx" color="#333333" ></u--text>
|
||||
:text="item.time+' 支出金额 '+item.value+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
</view>
|
||||
</u-list-item>
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-list v-show="tabShow" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in secondListData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.time+' 支出金额 '+item.value+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
</view>
|
||||
</u-list-item>
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
|
||||
<u-picker itemHeight="88" :show="settingPickShow" :columns="settingColumns" keyName="settingName"
|
||||
@confirm="settingConfirm" @cancel="settingCancel"></u-picker>
|
||||
<u-picker itemHeight="88" :show="showAccount" :columns="accountList" keyName="typeNameCodeAvailableLimit" @cancel="handleAccountCancel"
|
||||
@@ -237,6 +255,12 @@
|
||||
const timeShow= ref(false)
|
||||
const time =ref( Number(new Date()))
|
||||
const flag= ref(true)
|
||||
|
||||
const secondListData = ref([])
|
||||
const tabShow = ref(false)
|
||||
const classType = ref("primary")
|
||||
const dayType = ref("default")
|
||||
|
||||
const account = ref({
|
||||
amount: '',
|
||||
income: '',
|
||||
@@ -287,6 +311,20 @@
|
||||
return data.replace(/<br\/>/g, '\n')
|
||||
}
|
||||
}
|
||||
|
||||
function btClassClick() {
|
||||
tabShow.value=false
|
||||
classType.value="primary"
|
||||
dayType.value="default"
|
||||
|
||||
}
|
||||
function btDayClick() {
|
||||
dayType.value="primary"
|
||||
classType.value="default"
|
||||
tabShow.value=true
|
||||
|
||||
}
|
||||
|
||||
function openOrCloseDate(data) {
|
||||
timeShow.value = !timeShow.value
|
||||
flag.value = data
|
||||
@@ -325,6 +363,7 @@ const start = today.getFullYear() + '-' + ('0' + (today.getMonth() + 1)).slice(-
|
||||
getDailyExpensesAnalysis({...queryParams.value }).then(res => {
|
||||
account.value = { ...res.data }
|
||||
listData.value = listData.value.concat(res.data.tableAccountsDateList)
|
||||
secondListData.value = secondListData.value.concat(res.data.accountsList)
|
||||
}).catch(() => {
|
||||
})
|
||||
}
|
||||
|
||||
@@ -149,7 +149,11 @@
|
||||
|
||||
<div></div>
|
||||
</div>
|
||||
<u-list @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<div style="margin:8px">
|
||||
<button :type="firstType" style="margin-right:5px" size=mini @click="btFirstClick">结算卡统计</button>
|
||||
<button :type="secondType" type="primary" size=mini @click="btSecondClick">近6月收款金额统计</button>
|
||||
</div>
|
||||
<u-list v-show="!tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
@@ -233,6 +237,19 @@
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-list v-show="tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in secondListData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.debitCard+' 收款 '+item.amount+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</u-list-item>
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-picker itemHeight="88" :show="settingPickShow" :columns="settingColumns" keyName="settingName"
|
||||
@confirm="settingConfirm" @cancel="settingCancel"></u-picker>
|
||||
</view>
|
||||
@@ -253,6 +270,11 @@
|
||||
const settingPickShow = ref(false)
|
||||
const settingColumns = ref([])
|
||||
|
||||
const tabShow = ref(false)
|
||||
const firstType = ref("primary")
|
||||
const secondType = ref("default")
|
||||
const secondListData = ref([])
|
||||
|
||||
const debitCardAnalysis = ref({})
|
||||
const data = reactive({
|
||||
filterPanel: false,
|
||||
@@ -279,10 +301,25 @@
|
||||
}
|
||||
});
|
||||
|
||||
|
||||
function btFirstClick() {
|
||||
tabShow.value=false
|
||||
firstType.value="primary"
|
||||
secondType.value="default"
|
||||
|
||||
}
|
||||
function btSecondClick() {
|
||||
secondType.value="primary"
|
||||
firstType.value="default"
|
||||
tabShow.value=true
|
||||
|
||||
}
|
||||
|
||||
function getList() {
|
||||
getDebitCardAnalysis({...queryParams.value }).then(res => {
|
||||
debitCardAnalysis.value = { ...res.data }
|
||||
listData.value = listData.value.concat(res.data.debitCardTableList)
|
||||
secondListData.value = secondListData.value.concat(res.data.debitCardList)
|
||||
}).catch(() => {
|
||||
})
|
||||
}
|
||||
|
||||
@@ -147,6 +147,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>储蓄账户统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -134,6 +134,9 @@
|
||||
</div>
|
||||
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>投资收益统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -99,6 +99,10 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>POS机刷卡统计
|
||||
</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -149,7 +149,11 @@
|
||||
|
||||
<div></div>
|
||||
</div>
|
||||
<u-list @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<div style="margin:8px">
|
||||
<button :type="firstType" style="margin-right:5px" size=mini @click="btFirstClick">POS机统计</button>
|
||||
<button :type="secondType" type="primary" size=mini @click="btSecondClick">近6月刷卡金额统计</button>
|
||||
</div>
|
||||
<u-list v-show="!tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
@@ -233,6 +237,19 @@
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-list v-show="tabShow" @scrolltolower="loadmore" :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in secondListData" :key="index">
|
||||
<view class="list-item">
|
||||
<view class="item-header">
|
||||
<u--text lines="2"
|
||||
:text="item.pos+' 刷卡 '+item.amount+' 元'" size="30rpx" color="#333333" ></u--text>
|
||||
</view>
|
||||
|
||||
</view>
|
||||
</u-list-item>
|
||||
<view>
|
||||
</view>
|
||||
</u-list>
|
||||
<u-picker itemHeight="88" :show="settingPickShow" :columns="settingColumns" keyName="settingName"
|
||||
@confirm="settingConfirm" @cancel="settingCancel"></u-picker>
|
||||
</view>
|
||||
@@ -253,6 +270,11 @@ const isShow = ref(false)
|
||||
const settingPickShow = ref(false)
|
||||
const settingColumns = ref([])
|
||||
|
||||
const tabShow = ref(false)
|
||||
const firstType = ref("primary")
|
||||
const secondType = ref("default")
|
||||
const secondListData = ref([])
|
||||
|
||||
const debitCardAnalysis = ref({})
|
||||
const data = reactive({
|
||||
filterPanel: false,
|
||||
@@ -279,10 +301,24 @@ onLoad(() => {
|
||||
}
|
||||
});
|
||||
|
||||
function btFirstClick() {
|
||||
tabShow.value=false
|
||||
firstType.value="primary"
|
||||
secondType.value="default"
|
||||
|
||||
}
|
||||
function btSecondClick() {
|
||||
secondType.value="primary"
|
||||
firstType.value="default"
|
||||
tabShow.value=true
|
||||
|
||||
}
|
||||
|
||||
function getList() {
|
||||
getPosStatics({...queryParams.value }).then(res => {
|
||||
debitCardAnalysis.value = { ...res.data }
|
||||
listData.value = listData.value.concat(res.data.posTableList)
|
||||
secondListData.value = secondListData.value.concat(res.data.posList)
|
||||
}).catch(() => {
|
||||
})
|
||||
}
|
||||
|
||||
@@ -124,6 +124,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>信用卡账单统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -132,6 +132,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>信用卡分期待还</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -99,6 +99,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>信用卡分期已还</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -139,6 +139,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>征信查询统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -99,6 +99,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>期货统计分析</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -100,6 +100,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>收益统计分析</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -132,6 +132,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>贷款待还统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -99,6 +99,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>贷款已还统计</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -99,6 +99,9 @@
|
||||
</div>
|
||||
</div>
|
||||
<div></div>
|
||||
</div>
|
||||
<div style="margin:8px">
|
||||
<button type="primary" style="margin-right:5px" size=mini>股票统计分析</button>
|
||||
</div>
|
||||
<u-list :spaceHeight="116" lowerThreshold="100">
|
||||
<u-list-item v-for="(item, index) in listData" :key="index">
|
||||
|
||||
@@ -112,8 +112,8 @@ const data = reactive({
|
||||
accountName: [{ required: true, message: '投资账户不能为空', trigger: ['change', 'blur'] }],
|
||||
amount: [{type: 'number', required: true, message: '交易金额不能为空', trigger: ['blur'] }],
|
||||
dealTypeName: [{ required: true, message: '交易类型不能为空', trigger:['change', 'blur'] }],
|
||||
closedPosition: [{ required: true, message: '平仓盈亏不能为空', trigger: 'blur' }],
|
||||
commission: [{ required: true, message: '手续费不能为空', trigger: 'blur' }],
|
||||
closedPosition: [{type: 'number', required: true, message: '平仓盈亏不能为空', trigger: 'blur' }],
|
||||
commission: [{ type: 'number', required: true, message: '手续费不能为空', trigger: 'blur' }],
|
||||
createTime: [{ required: true, message: '交易时间不能为空', trigger: ['change', 'blur'] }]
|
||||
}
|
||||
})
|
||||
|
||||
@@ -81,7 +81,7 @@ import auth from "@/plugins/auth"; // 建议使用auth进行鉴权操作
|
||||
{ path: '/pages/work/accounts/investAccountDeal/list', text: '投资交易记录', icon: 'chatboxes', permission: 'invest:futureStocks:list' },
|
||||
{ path: '/pages/work/accounts/investTransferRecord/list', text: '投资账户记账', icon: 'auth-filled', permission: 'invest:futureStocks:list' },
|
||||
{ path: '/pages/work/accounts/debitTransferRecord/list', text: '储蓄账户记账', icon: 'tune', permission: 'invest:debitCard' },
|
||||
{ path: '/pages/work/accounts/accounts/commonList', text: '记账账户', icon: 'staff', permission: 'invest:accounts:list' },
|
||||
// { path: '/pages/work/accounts/accounts/commonList', text: '记账账户', icon: 'staff', permission: 'invest:accounts:list' },
|
||||
{ path: '/pages/work/bill/creditCardBill/list', text: '信用卡账单', icon: 'list', permission: 'invest:creditCardBill:list' },
|
||||
{ path: '/pages/work/bill/onlineLendHistory/list', text: '贷款账单', icon: 'settings', permission: 'invest:onlineLend' },
|
||||
{ path: '/pages/work/bill/creditInstallmentHistory/list', text: '信用卡分期账单', icon: 'bars', permission: 'invest:creditCard' },
|
||||
|
||||
Reference in New Issue
Block a user