Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Contribute to GitLab
Sign in
Toggle navigation
W
wly-APP
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
刘川
wly-APP
Commits
2727ebc4
Commit
2727ebc4
authored
Dec 29, 2025
by
chicheng
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
添加账票管理模块
parent
fbe1daab
Show whitespace changes
Inline
Side-by-side
Showing
7 changed files
with
772 additions
and
392 deletions
+772
-392
pages.json
pages.json
+30
-33
billing-invoice.nvue
pages/billing-invoice/billing-invoice.nvue
+5
-7
invoice-query.nvue
pages/billing-invoice/invoice-query.nvue
+286
-333
market-support-query.nvue
pages/billing-invoice/market-support-query.nvue
+412
-0
usercenter.nvue
pages/usercenter/usercenter.nvue
+1
-2
api.helper.js
servers/api.helper.js
+12
-12
index.js
store/index.js
+26
-5
No files found.
pages.json
View file @
2727ebc4
...
@@ -937,39 +937,6 @@
...
@@ -937,39 +937,6 @@
}
}
}
}
},
},
{
"path"
:
"pages/account-inquiry/account-inquiry"
,
"style"
:
{
"app-plus"
:
{
"titleNView"
:
{
"titleAlign"
:
"left"
,
"titleColor"
:
"#333"
,
"titleSize"
:
"17px"
,
"backgroundColor"
:
"transparent"
,
"titleText"
:
"账款查询"
,
"autoBackButton"
:
true
},
"bounce"
:
"none"
}
}
},
{
"path"
:
"pages/marketsupportfee-select/marketsupportfee-select"
,
"style"
:
{
"app-plus"
:
{
"titleNView"
:
{
"titleAlign"
:
"left"
,
"titleColor"
:
"#333"
,
"titleSize"
:
"17px"
,
"backgroundColor"
:
"transparent"
,
"titleText"
:
"市场支持费用查询"
,
"autoBackButton"
:
true
},
"bounce"
:
"none"
}
//
"enablePullDownRefresh"
:
true
}
},
{
{
"path"
:
"pages/storage-list/storage-list"
,
"path"
:
"pages/storage-list/storage-list"
,
"style"
:
{
"style"
:
{
...
@@ -1456,6 +1423,36 @@
...
@@ -1456,6 +1423,36 @@
}
}
}
}
}
}
},
{
"path"
:
"pages/billing-invoice/invoice-query"
,
"style"
:
{
"app-plus"
:
{
"titleNView"
:
{
"titleAlign"
:
"left"
,
"titleColor"
:
"#333"
,
"titleSize"
:
"17px"
,
"backgroundColor"
:
"transparent"
,
"titleText"
:
"账款查询"
,
"autoBackButton"
:
true
}
}
}
},
{
"path"
:
"pages/billing-invoice/market-support-query"
,
"style"
:
{
"app-plus"
:
{
"titleNView"
:
{
"titleAlign"
:
"left"
,
"titleColor"
:
"#333"
,
"titleSize"
:
"17px"
,
"backgroundColor"
:
"#fff"
,
"titleText"
:
"市场支持费用查询"
,
"autoBackButton"
:
true
}
}
}
}
}
],
],
"globalStyle"
:
{
"globalStyle"
:
{
...
...
pages/billing-invoice/billing-invoice.nvue
View file @
2727ebc4
...
@@ -3,19 +3,17 @@
...
@@ -3,19 +3,17 @@
<view class="status_bar" :style="navHeight"></view>
<view class="status_bar" :style="navHeight"></view>
<view class="listview">
<view class="listview">
<view class="cell-list">
<view class="cell-list">
<view class="cell-list-block" @click="goOrder('
account-inqui
ry')">
<view class="cell-list-block" @click="goOrder('
billing-invoice/invoice-que
ry')">
<image class="icon-address" src="@/static/image/billing_inquiry@3x.png" mode="aspectFit"></image>
<image class="icon-address" src="@/static/image/billing_inquiry@3x.png" mode="aspectFit"></image>
<view class="cell-list-block__content">
<view class="cell-list-block__content">
<text class="cell-list-block__title">账款查询</text>
<text class="cell-list-block__title">账款查询</text>
<text class="cell-list-block__desc">Account inquiry</text>
</view>
</view>
<image class="icon-arrow" src="@/static/image/arrow_r@3x.png" mode="aspectFit"></image>
<image class="icon-arrow" src="@/static/image/arrow_r@3x.png" mode="aspectFit"></image>
</view>
</view>
<view class="cell-list-block" @click="goOrder('
marketsupportfee-select
')">
<view class="cell-list-block" @click="goOrder('
billing-invoice/market-support-query
')">
<image class="icon-address" src="@/static/image/billing_market@3x.png" mode="aspectFit"></image>
<image class="icon-address" src="@/static/image/billing_market@3x.png" mode="aspectFit"></image>
<view class="cell-list-block__content">
<view class="cell-list-block__content">
<text class="cell-list-block__title">市场支持费用查询</text>
<text class="cell-list-block__title">市场支持费用查询</text>
<text class="cell-list-block__desc">Market support fee inquiry</text>
</view>
</view>
<image class="icon-arrow" src="@/static/image/arrow_r@3x.png" mode="aspectFit"></image>
<image class="icon-arrow" src="@/static/image/arrow_r@3x.png" mode="aspectFit"></image>
</view>
</view>
...
@@ -45,9 +43,9 @@
...
@@ -45,9 +43,9 @@
...mapState(['sysinfo'])
...mapState(['sysinfo'])
},
},
methods: {
methods: {
goOrder(
type
) {
goOrder(
path
) {
uni.navigateTo({
uni.navigateTo({
url: `/pages/${
type}/${type
}`
url: `/pages/${
path
}`
});
});
}
}
}
}
...
...
pages/
account-inquiry/account-inqui
ry.nvue
→
pages/
billing-invoice/invoice-que
ry.nvue
View file @
2727ebc4
...
@@ -6,7 +6,7 @@
...
@@ -6,7 +6,7 @@
</view>
</view>
<view class="main">
<view class="main">
<view class="list-wrapper" :style="scrollHeight">
<view class="list-wrapper" :style="scrollHeight">
<list class="list" scrollable loadmoreoffset='1' show-scrollbar='false'
>
<list class="list" scrollable loadmoreoffset='1' show-scrollbar='false'
@loadmore="scrolltolower">
<cell class="list-cell" v-for="(item,index) in lists" :key="index">
<cell class="list-cell" v-for="(item,index) in lists" :key="index">
<view class="listview">
<view class="listview">
<view class="cell-list">
<view class="cell-list">
...
@@ -18,16 +18,16 @@
...
@@ -18,16 +18,16 @@
<text class="item-block-label item-block__label">{{item.billto_name}}</text>
<text class="item-block-label item-block__label">{{item.billto_name}}</text>
</view>
</view>
<view class="item-block item-block-date">
<view class="item-block item-block-date">
<text class="detal-item-label">
开票方名称</text>
<text class="detal-item-label">
发生日期:{{item.posting_date}}</text>
</view>
</view>
<view class="block-detal block-detal-last">
<view class="block-detal block-detal-last">
<view class="block-detal-item">
<view class="block-detal-item">
<text class="detal-item-label">
贷款</text>
<text class="detal-item-label">
货款金额</text>
<text class="detal-item-value">{{item.goods_amount}}</text>
<text class="detal-item-value">{{item.goods_amount}}</text>
</view>
</view>
<view class="block-detal-item">
<view class="block-detal-item">
<text class="detal-item-label">随
量保证金</text>
<text class="detal-item-label">随
货保证金</text>
<text class="detal-item-value">{{item.forward_amount}}</text>
<text class="detal-item-value">{{item.forward_amount}}</text>
</view>
</view>
<view class="block-detal-item block-detal-item-last">
<view class="block-detal-item block-detal-item-last">
...
@@ -43,9 +43,12 @@
...
@@ -43,9 +43,12 @@
</view>
</view>
</cell>
</cell>
<cell>
<cell>
<view class="loading-more" v-if='lists.length>
2'>
<view class="loading-more" v-if='lists.length>
0'>
<text class="loading-more-text">-- 到底了 --</text>
<text class="loading-more-text">-- 到底了 --</text>
</view>
</view>
<view class="loading-more" v-else>
<text class="loading-more-text">暂无数据</text>
</view>
</cell>
</cell>
</list>
</list>
</view>
</view>
...
@@ -66,13 +69,15 @@
...
@@ -66,13 +69,15 @@
data() {
data() {
return {
return {
itemHead: {},
itemHead: {},
lists: [{
lists: [],
BILLTO_BP: '--',
condition: {
BILLTO_NAME: '',
customer: []
GOODS_AMOUNT: '',
},
FORWARD_AMOUNT: '',
page: {
DEALING_AMOUNT: '',
page: 1,
}]
pagesize: 50,
totalCount: 0
}
}
}
},
},
computed: {
computed: {
...
@@ -91,244 +96,192 @@
...
@@ -91,244 +96,192 @@
'height': `${this.sysinfo.safeArea.height -58}px`,
'height': `${this.sysinfo.safeArea.height -58}px`,
}
}
},
},
...mapState(['sysinfo', 'userInfo'
])
...mapState(['sysinfo', 'userInfo'
, 'userBpData'])
},
},
created() {
created() {
this.accountInquiry(
);
this.accountInquiry(
1);
},
},
methods: {
methods: {
async accountInquiry() {
scrolltolower() {
let CUSTOMER = []
if (this.lists.length >= this.page.totalCount && this.page.totalCount > 0) {
if (this.userInfo.role !== 'WLY001') {
return;
CUSTOMER = [{
SIGN: 'I',
OPTION: 'EQ',
LOW: this.userInfo.code,
HIGH: ''
}]
}
}
const params = {
this.page.page++;
'USER_BP': this.userInfo.code,
this.accountInquiry(this.page.page);
ROLE: 'WLY001',
},
CUSTOMER,
async accountInquiry(pageNo = 1) {
// 处理客户条件,转换为SAP格式(属性名小写,与PC端保持一致)
const customer = (this.condition.customer || []).map(v => ({
sign: v.sign || v.SIGN || 'I',
option: v.option || v.OPTION || 'EQ',
low: v.low || v.LOW || '',
high: v.high || v.HIGH || ''
}))
// 构建查询条件对象,与PC端格式保持一致
const allConditions = {}
if (customer.length > 0) {
allConditions.customer = customer
}
// 获取用户编号和角色信息,参考 ticket-order.nvue 的方式
const userCode = this.userInfo?.code || ''
// 从 userBpData 获取第一个角色的 ROLE_ID
const roleId = this.userBpData?.ROLES && this.userBpData.ROLES.length > 0
? this.userBpData.ROLES[0].ROLE_ID
: ''
let params = {
user_bp: userCode,
role: roleId,
...allConditions,
page: pageNo,
pagesize: this.page.pagesize,
totalCount: this.page.totalCount,
is_result: 1,
sort: []
}
uni.showLoading({
title: '加载中'
});
const res = await apiAccountInquiry(params);
uni.hideLoading();
if (res) {
if (pageNo === 1) {
this.lists = res.data || [];
} else {
this.lists = this.lists.concat(res.data || []);
}
this.page.totalCount = res?.TOTALCOUNT || res?.totalCount || res?.Total || this.page.totalCount;
}
}
const res = await apiAccountInquiry(params)
this.lists = res.data
}
}
}
}
}
}
</script>
</script>
<style lang="scss" scoped>
<style lang="scss" scoped>
.view {
/* #ifndef APP-PLUS */
flex-direction: column;
page {
width: 100%;
min-height: 100%;
display: flex;
background: #F2F3F5;
}
}
.header-bg {
.status_bar {
height: 284rpx;
height: var(--status-bar-height);
margin-top: -88rpx;
}
}
.header-bg-img {
/* #endif */
width: 750rpx;
}
.lists {
.lists {
position: relative;
flex: 1;
flex-direction: column;
background: #F2F3F5;
background: #f0f4f5;
overflow: hidden;
}
.main {
position: relative;
flex-direction: column;
margin-top: -164rpx;
padding: 0 16rpx;
// overflow-y: scroll;
}
.list-wrapper {
display: flex;
flex-direction: column;
}
}
.list {
.header-bg {
display: flex;
position: absolute;
flex-direction: column;
left: 0;
right: 0;
height: 382rpx;
}
}
.order {
.header-bg-img {
display: flex;
width: 750rpx;
padding: 0 16rpx;
height: 382rpx;
background: #f0f4f5;
}
}
.list-cell {
.main {
padding-bottom: 26rpx;
flex: 1;
padding: 0 32rpx;
margin-top: 100rpx;
}
}
.list
view {
.list
-wrapper {
flex: 1;
flex: 1;
flex-direction: column;
}
}
.empty-block {
.list {
height: 14px;
flex: 1;
background: #f0f4f5;
}
}
.
cell-list {
.
listview {
flex-direction: column;
flex-direction: column;
}
background-color: #FFFFFF;
border-radius: 10rpx;
.date {
font-size: 28rpx;
color: #999999;
font-size: 28rpx;
text-align: center;
margin-bottom: 24rpx;
margin-bottom: 24rpx;
padding: 24rpx;
}
}
.icon-address {
.cell-list {
width: 44rpx;
height: 44rpx;
margin-right: 16rpx;
}
.cell-list-block__content {
display: flex;
flex: 1;
flex-direction: column;
flex-direction: column;
margin-bottom: 40rpx;
}
.cell-list-block__title {
color: #333;
font-size: 30rpx;
flex: 1;
align-items: center;
margin-bottom: 4rpx;
}
}
.cell-list-block {
.planout-block-item {
overflow: hidden;
display: flex;
flex-direction: column;
flex-direction: column;
background: #fff;
padding: 20rpx 24rpx;
border-radius: 20rpx;
margin-bottom: 56rpx;
}
}
.
list-block-title {
.
item-block {
display: flex;
flex-direction: row;
align-items: center;
align-items: center;
margin-bottom: 16rpx;
margin-bottom: 16rpx;
}
}
.list-block-title__text {
.item-block-code {
color: #999999;
justify-content: space-between;
font-size: 26rpx;
}
.planout-block-item {
flex: 1;
padding: 40rpx 32rpx;
background-color: #fff;
border-radius: 16rpx 100rpx 16rpx 16rpx;
}
.item-block {
overflow: hidden;
background-color: #fff;
padding: 0 16rpx;
}
}
.item-block-label {
.item-block-label {
font-size: 2
4rpx;
font-size: 2
8rpx;
color: #333
;
color: #333
333;
}
}
.item-block__label {
.item-block__label {
flex: 1;
font-weight: bold;
text-align: left;
font-size: 32rpx;
font-size: 32rpx;
color: #333;
font-weight: 500;
// white-space: nowrap;
overflow: hidden;
text-overflow: ellipsis;
}
.item-block-code {
display: flex;
align-items: center;
justify-content: space-between;
}
.item-block-name {
margin-top: 32rpx;
margin-bottom: 8rpx;
}
}
.item-block-date {
.item-block-date {
margin-top: 12rpx;
margin-bottom: 24rpx;
margin-bottom: 48rpx;
}
}
.item-block-label-des {
.detal-item-label {
flex: 1;
font-size: 24rpx;
text-align: left;
color: #999999;
font-size: 28rpx;
color: #333;
}
}
.block-detal {
.block-detal {
display: flex;
flex-direction: row;
flex-direction: column;
background-color: #F8F8F8;
background: #f8f8f8;
padding: 24rpx;
border-radius: 20rpx;
border-radius: 8rpx;
padding: 28rpx 32rpx;
margin-bottom: 52rpx;
}
.block-detal-last {
margin-bottom: 32rpx;
}
}
.block-detal-item {
.block-detal-item {
display: flex;
flex: 1;
margin-bottom: 32rpx;
align-items: center;
justify-content: space-between;
}
.block-detal-item-last {
margin-bottom: 0;
}
.detal-item-label {
color: #999;
font-size: 24rpx;
}
}
.detal-item-value {
.detal-item-value {
color: #333;
font-size: 28rpx;
font-size: 28rpx;
color: #333333;
margin-top: 8rpx;
font-weight: bold;
}
}
.loading-more {
.loading-more {
flex: 1;
align-items: center;
align-items: center;
justify-content: center;
justify-content: center;
padding-top: 14px;
padding-top: 20rpx;
padding-bottom: 14px;
padding-bottom: 20rpx;
text-align: center;
}
}
.loading-more-text {
.loading-more-text {
font-size:
12px;
font-size:
28rpx;
color: #999;
color: #999;
}
}
.empty-block {
height: 24rpx;
}
</style>
</style>
pages/
marketsupportfee-select/marketsupportfee-select
.nvue
→
pages/
billing-invoice/market-support-query
.nvue
View file @
2727ebc4
...
@@ -6,28 +6,15 @@
...
@@ -6,28 +6,15 @@
</view>
</view>
<view class="main">
<view class="main">
<view class="middle view">
<view class="middle view">
<view class="text-block">
<text class="middle-date">开始日期</text>
<view class="middle-date-des uni-list picker-year">
<view class="uni-list-cell">
<view class="uni-list-cell-db">
<picker class="picker-block" @change="bindPickerYearStartChange" mode="date"
:value="condition.start" fields='day'>
<text class="uni-input">{{condition.start}}</text>
</picker>
</view>
</view>
<image class="icon-arrow" src="@/static/image/arrow_r@3x.png" mode="aspectFit"></image>
</view>
</view>
<view class="text-block text-block-last">
<view class="text-block text-block-last">
<text class="middle-date">截止日期</text>
<text class="middle-date">查询日期</text>
<view class="middle-date-des uni-list picker-year">
<view class="middle-date-des">
<view class="picker-year">
<view class="uni-list-cell">
<view class="uni-list-cell">
<view class="uni-list-cell-db">
<view class="uni-list-cell-db">
<picker class="picker-block" @change="bindPickerYearEndChange" mode="date"
<picker class="picker-block" @change="bindPickerDateChange" mode="date"
:value="condition.end" fields='day'>
:value="condition.posting_date" fields='day'>
<text class="uni-input">{{condition.end}}</text>
<text class="uni-input">{{condition.posting_date || '请选择日期'}}</text>
</picker>
</picker>
</view>
</view>
</view>
</view>
...
@@ -35,7 +22,7 @@
...
@@ -35,7 +22,7 @@
</view>
</view>
</view>
</view>
</view>
</view>
</view>
<view class="planout-block">
<view class="planout-block">
<button class="btn" type="default" @tap="search">
<button class="btn" type="default" @tap="search">
<text class="btn-text">查询</text>
<text class="btn-text">查询</text>
...
@@ -45,28 +32,37 @@
...
@@ -45,28 +32,37 @@
@scrolltolower='scrolltolower'>
@scrolltolower='scrolltolower'>
<list class="scroll-area view" loadmoreoffset='100' show-scrollbar='false' @loadmore="scrolltolower">
<list class="scroll-area view" loadmoreoffset='100' show-scrollbar='false' @loadmore="scrolltolower">
<cell class="list-cell" v-for="(item,index) in lists" :key='index'>
<cell class="list-cell" v-for="(item,index) in lists" :key='index'>
<!-- <scroll-view class="scroll-area" :style='scrollHeight' scroll-y="true" lower-threshold='150'
@scrolltolower='scrolltolower'> -->
<view class="middle view planout-block-item">
<view class="middle view planout-block-item">
<view class="text-block">
<view class="text-block">
<text class="middle-date middle-date-select">客户编码</text>
<text class="middle-date middle-date-select">客户编码</text>
<text class="middle-date-des middle-date-des-select">{{item.
customer}}</text>
<text class="middle-date-des middle-date-des-select">{{item.
billto_bp}}</text>
</view>
</view>
<view class="text-block">
<view class="text-block">
<text class="middle-date middle-date-select">客户名称</text>
<text class="middle-date middle-date-select">客户名称</text>
<text class="middle-date-des middle-date-des-select">{{item.
customer_name}}</text>
<text class="middle-date-des middle-date-des-select">{{item.
billto_name}}</text>
</view>
</view>
<view class="text-block">
<view class="text-block">
<text class="middle-date middle-date-select">上账日期</text>
<text class="middle-date middle-date-select">上账日期</text>
<text class="middle-date-des middle-date-des-select">{{item.posting_date}}</text>
<text class="middle-date-des middle-date-des-select">{{item.posting_date}}</text>
</view>
</view>
<view class="text-block">
<text class="middle-date middle-date-select">摘要</text>
<text class="middle-date-des middle-date-des-select">{{item.zy}}</text>
</view>
<view class="text-block text-block-last">
<view class="text-block text-block-last">
<text class="middle-date middle-date-select">金额</text>
<text class="middle-date middle-date-select">金额</text>
<text class="middle-date-des middle-date-des-select">{{item.
goods_amount}}</text>
<text class="middle-date-des middle-date-des-select">{{item.
forward_amount}}</text>
</view>
</view>
</view>
</view>
<view class="empty-block"></view>
<view class="empty-block"></view>
<!-- </scroll-view> -->
</cell>
<cell>
<view class="loading-more" v-if='lists.length>0'>
<text class="loading-more-text">-- 到底了 --</text>
</view>
<view class="loading-more" v-else>
<text class="loading-more-text">暂无数据</text>
</view>
</cell>
</cell>
</list>
</list>
</scroll-view>
</scroll-view>
...
@@ -93,24 +89,17 @@
...
@@ -93,24 +89,17 @@
refreshing: false,
refreshing: false,
isOpened: 'none',
isOpened: 'none',
condition: {
condition: {
start: '',
posting_date: ''
end: ''
},
},
lists: [],
lists: [],
page: {
page: {
"PAGE": "1",
page: 1,
"PAGESIZE": "10",
pagesize: 20,
},
totalCount: 0
toPageParams: {
page: '',
mode: '',
index: 0,
head: {}
}
}
}
}
},
},
computed: {
computed: {
...mapState(['sysinfo', 'userInfo']),
navHeight() {
navHeight() {
return {
return {
'height': `${this.sysinfo.safeArea.top + 44}px`
'height': `${this.sysinfo.safeArea.top + 44}px`
...
@@ -118,102 +107,117 @@
...
@@ -118,102 +107,117 @@
},
},
mainHeight() {
mainHeight() {
return {
return {
'height': `${this.sysinfo.safeArea.height
}px`,
'height': `${this.sysinfo.safeArea.height
}px`,
}
}
},
},
scrollHeight() {
scrollHeight() {
return {
return {
'height': `${this.sysinfo.safeArea.height - 265 - 44}px`
'height': `${this.sysinfo.safeArea.height - 180 - 44}px`,
}
}
}
},
},
onPullDownRefresh() {
...mapState(['sysinfo', 'userInfo', 'userBpData'])
console.log('refresh');
this.reset()
this.getMarketSupportFee(true)
setTimeout(function() {
uni.stopPullDownRefresh();
}, 600);
},
},
created() {
created() {
this.condition.start = timeFormat(new Date(), 'yyyy-mm-dd')
// 不设置默认日期,让用户自己选择
this.condition.end = timeFormat(new Date(), 'yyyy-mm-dd')
// this.queryData(1);
this.reset()
this.getMarketSupportFee(true);
},
},
methods: {
methods: {
async getMarketSupportFee() {
bindPickerDateChange(e) {
let CUSTOMER = []
this.condition.posting_date = e.detail.value
let POSTING_DATE = []
},
if (this.condition.start) {
search() {
POSTING_DATE = [{
this.lists = [];
SIGN: 'I',
this.page.page = 1;
OPTION: 'BT',
this.queryData(1);
LOW: '20220401' || this.condition.start.replaceAll('-', ''),
},
// LOW: '20220401' || this.condition.start.replaceAll('-', ''),
scrolltolower() {
HIGH: '20220530' || this.condition.end.replaceAll('-', '')
if (this.lists.length >= this.page.totalCount) {
// HIGH: '20220530' || this.condition.end.replaceAll('-', '')
return;
}]
}
}
if (this.userInfo.role !== 'WLY001') {
this.page.page++;
CUSTOMER = [{
this.queryData(this.page.page);
SIGN: 'I',
},
OPTION: 'EQ',
async queryData(pageNo) {
// LOW: '4000000105' || this.userInfo.code,
// 构建查询条件对象,与PC端格式保持一致
LOW: this.userInfo.code,
const allConditions = {}
HIGH: ''
// 处理日期条件,单个日期查询(EQ),转换为SAP格式数组(属性名小写,与PC端保持一致)
if (this.condition.posting_date) {
allConditions.posting_date = [{
sign: 'I',
option: 'EQ',
low: this.condition.posting_date,
high: ''
}]
}]
}
}
const params = {
'USER_BP': this.userInfo.code || '4000000105',
ROLE: 'WLY001',
CUSTOMER,
POSTING_DATE,
}
const res = await apiGetMarketSupportFee(params)
this.lists = res.data
// 处理客户条件(如果存在)
},
if (this.condition.customer && this.condition.customer.length > 0) {
reset() {
const customer = this.condition.customer.map(v => ({
this.loadParams = {
sign: v.sign || v.SIGN || 'I',
total: 0,
option: v.option || v.OPTION || 'EQ',
totalPage: 1,
low: v.low || v.LOW || '',
isDone: false,
high: v.high || v.HIGH || ''
isRefresh: false
}))
}
// 字段名使用小写,与PC端保持一致
this.page.PAGE = 1
allConditions.customer = customer
this.lists = []
}
this.loadingText = '加载中'
},
// 获取用户编号和角色信息,参考 ticket-order.nvue 的方式
scrolltolower() {
const userCode = this.userInfo?.code || ''
console.log('onReachBottom');
// 从 userBpData 获取第一个角色的 ROLE_ID
if (this.page.PAGE < this.loadParams.totalPage) {
const roleId = this.userBpData?.ROLES && this.userBpData.ROLES.length > 0
this.page.PAGE++
? this.userBpData.ROLES[0].ROLE_ID
this.getMarketSupportFee()
: ''
let params = {
user_bp: userCode,
role: roleId,
...allConditions,
page: pageNo,
pagesize: this.page.pagesize,
totalCount: this.page.totalCount,
is_result: 1,
sort: []
}
uni.showLoading({
title: '加载中'
});
const res = await apiGetMarketSupportFee(params);
uni.hideLoading();
if (res && res.data) {
if (pageNo === 1) {
this.lists = res.data || [];
} else {
} else {
this.loadParams.isDone = true
this.lists = this.lists.concat(res.data || []);
this.loadingText = '-- 到底了 --'
}
this.page.totalCount = res?.TOTALCOUNT || res?.totalCount || res?.Total || this.page.totalCount;
}
}
}
},
search() {
this.reset()
this.getMarketSupportFee(true)
},
bindPickerYearStartChange(e) {
console.log('picker发送选择改变,携带值为', e.detail.value)
this.condition.start = e.detail.value
},
bindPickerYearEndChange(e) {
console.log('picker发送选择改变,携带值为', e.detail.value)
this.condition.end = e.detail.value
},
}
}
}
}
</script>
</script>
<style lang="scss" scoped>
<style lang="scss" scoped>
.view {
/* #ifndef APP-PLUS */
page {
width: 100%;
min-height: 100%;
display: flex;
background: #F2F3F5;
}
.status_bar {
height: var(--status-bar-height);
}
/* #endif */
.lists {
position: relative;
flex-direction: column;
flex-direction: column;
overflow-y: scroll;
background: #f0f4f5;
overflow-x: hidden;
}
}
.header-bg {
.header-bg {
...
@@ -225,12 +229,8 @@
...
@@ -225,12 +229,8 @@
width: 750rpx;
width: 750rpx;
}
}
.lists {
.view {
position: relative;
flex-direction: column;
flex-direction: column;
overflow-y: scroll;
background: #f0f4f5;
overflow-x: hidden;
}
}
.main {
.main {
...
@@ -244,6 +244,7 @@
...
@@ -244,6 +244,7 @@
background-color: #fff;
background-color: #fff;
border-radius: 16rpx;
border-radius: 16rpx;
padding: 32rpx 64rpx 32rpx 48rpx;
padding: 32rpx 64rpx 32rpx 48rpx;
margin-bottom: 0;
}
}
.text-block {
.text-block {
...
@@ -252,6 +253,8 @@
...
@@ -252,6 +253,8 @@
height: 96rpx;
height: 96rpx;
margin-bottom: 14rpx;
margin-bottom: 14rpx;
border-bottom: 1px solid #f4f5f6;
border-bottom: 1px solid #f4f5f6;
justify-content: space-between;
align-items: center;
}
}
.text-block-last {
.text-block-last {
...
@@ -272,77 +275,100 @@
...
@@ -272,77 +275,100 @@
font-size: 28rpx;
font-size: 28rpx;
line-height: 96rpx;
line-height: 96rpx;
height: 96rpx;
height: 96rpx;
white-space: nowrap;
overflow: hidden;
overflow: hidden;
text-overflow: ellipsis;
text-overflow: ellipsis;
color: #888;
color: #888;
}
display: flex;
align-items: center;
.middle-date-select {
justify-content: flex-start;
color: #888;
}
.middle-date-des-select {
color: #333;
}
}
.picker-year {
.picker-year {
position: relative;
position: relative;
border-radius: 4px;
border-radius: 4px;
align-items: center;
align-items: center;
}
flex: 1;
flex-direction: row;
.uni-input {
justify-content: flex-start;
font-size: 12px;
width: 100%;
color: #888;
padding-right: 24rpx;
}
}
.uni-list-cell {
.uni-list-cell {
flex: 1;
flex: 1;
min-width: 0;
display: flex;
align-items: center;
justify-content: flex-start;
}
}
.uni-list-cell-db {
.uni-list-cell-db {
flex: 1;
flex: 1;
height: 48px;
line-height: 48px;
min-width: 0;
display: flex;
align-items: center;
justify-content: flex-start;
text-align: left;
}
}
.picker-block {
.picker-block {
flex: 1;
flex: 1;
min-width: 0;
width: 100%;
text-align: left;
display: flex;
align-items: center;
justify-content: flex-start;
}
.uni-input {
font-size: 28rpx;
color: #333;
text-align: left;
width: 100%;
overflow: visible;
white-space: nowrap;
display: block;
text-align: left;
}
}
.icon-arrow {
.icon-arrow {
position: absolute;
position: absolute;
right: 0;
right: 0;
top: 16px;
top: 50%;
margin-top: -10rpx;
width: 12rpx;
width: 12rpx;
height: 20rpx;
height: 20rpx;
z-index: 10;
z-index: 10;
}
flex-shrink: 0;
.planout-block-lists {
display: flex;
flex-direction: column;
background: #f0f4f5;
}
.list-cell {
padding-bottom: 26rpx;
}
.lists-wrapper {
display: flex;
flex-direction: column;
}
}
.planout-block {
.planout-block {
display: flex;
display: flex;
justify-content: space-between;
justify-content: space-between;
height: 92rpx;
margin-top: 30rpx;
margin-top: 64rpx;
margin-bottom: 30rpx;
margin-bottom: 48rpx;
padding: 0 24rpx;
padding: 0 24rpx;
}
}
.planout-block-item {
.planout-block-item {
flex: 1;
flex: 1;
width: 750rpx;
margin-bottom: 26rpx;
background-color: #fff;
border-radius: 16rpx;
padding: 32rpx 64rpx 32rpx 48rpx;
}
.middle-date-select {
color: #888;
}
.middle-date-des-select {
color: #333;
}
}
.btn {
.btn {
...
@@ -350,6 +376,8 @@
...
@@ -350,6 +376,8 @@
height: 92rpx;
height: 92rpx;
background: $wly-primary-color;
background: $wly-primary-color;
border-radius: 46rpx;
border-radius: 46rpx;
justify-content: center;
align-items: center;
}
}
.btn-text {
.btn-text {
...
@@ -357,11 +385,28 @@
...
@@ -357,11 +385,28 @@
font-size: 34rpx;
font-size: 34rpx;
}
}
.empty-block {
height: 26rpx;
background: #f0f4f5;
}
.scroll-area {
.scroll-area {
overflow-y: scroll;
overflow-y: scroll;
}
}
.list-cell {
flex-direction: column;
}
.empty-block {
height: 24rpx;
}
.loading-more {
align-items: center;
justify-content: center;
padding-top: 20rpx;
padding-bottom: 20rpx;
}
.loading-more-text {
font-size: 28rpx;
color: #999;
}
</style>
</style>
pages/usercenter/usercenter.nvue
View file @
2727ebc4
...
@@ -36,7 +36,7 @@
...
@@ -36,7 +36,7 @@
<text class="entry-bill-text">销售订单</text>
<text class="entry-bill-text">销售订单</text>
</view>
</view>
<
!-- <
view class="entry-block" @click="goPage('billing-invoice')">
<view class="entry-block" @click="goPage('billing-invoice')">
<view class="entry-bill">
<view class="entry-bill">
<image class="entry-bill-icon entry-bill-icon_billing"
<image class="entry-bill-icon entry-bill-icon_billing"
src="@/static/image/usercenter_billinginvoice@3x.png" mode="">
src="@/static/image/usercenter_billinginvoice@3x.png" mode="">
...
@@ -44,7 +44,6 @@
...
@@ -44,7 +44,6 @@
</view>
</view>
<text class="entry-bill-text">账票管理</text>
<text class="entry-bill-text">账票管理</text>
</view>
</view>
-->
<view class="entry-block" @click="goPage('ticket-order')" v-if='!isChildCustomer'>
<view class="entry-block" @click="goPage('ticket-order')" v-if='!isChildCustomer'>
<view class="entry-bill">
<view class="entry-bill">
<image class="entry-bill-icon entry-bill-icon_billing"
<image class="entry-bill-icon entry-bill-icon_billing"
...
...
servers/api.helper.js
View file @
2727ebc4
...
@@ -183,23 +183,23 @@ class Request {
...
@@ -183,23 +183,23 @@ class Request {
if
(
config
.
url
.
indexOf
(
'crm-app'
)
!==
-
1
)
{
if
(
config
.
url
.
indexOf
(
'crm-app'
)
!==
-
1
)
{
config
.
baseUrl
=
'https://crm.wuliangye.com.cn'
//
config.baseUrl = 'https://crm.wuliangye.com.cn'
//
config.baseUrl = 'http://221.10.127.60:5000'
config
.
baseUrl
=
'http://221.10.127.60:5000'
}
else
if
(
config
.
url
.
indexOf
(
'adapter'
)
!==
-
1
)
{
}
else
if
(
config
.
url
.
indexOf
(
'adapter'
)
!==
-
1
)
{
config
.
baseUrl
=
'http://api.wuliangcreart.com'
//
config.baseUrl = 'http://api.wuliangcreart.com'
//
config.baseUrl = 'http://221.10.127.60:5000/gateway/cyj'
config
.
baseUrl
=
'http://221.10.127.60:5000/gateway/cyj'
}
else
if
(
config
.
url
.
indexOf
(
'wmdpwebservices'
)
!==
-
1
)
{
}
else
if
(
config
.
url
.
indexOf
(
'wmdpwebservices'
)
!==
-
1
)
{
config
.
baseUrl
=
'https://crm.wuliangye.com.cn/gateway/sczx'
//
config.baseUrl = 'https://crm.wuliangye.com.cn/gateway/sczx'
//
config.baseUrl = 'http://221.10.127.60:5000/gateway/sczx'
config
.
baseUrl
=
'http://221.10.127.60:5000/gateway/sczx'
}
else
if
(
config
.
url
.
indexOf
(
'wmdp-storeapp'
)
!==
-
1
)
{
}
else
if
(
config
.
url
.
indexOf
(
'wmdp-storeapp'
)
!==
-
1
)
{
config
.
baseUrl
=
'https://crm.wuliangye.com.cn/gateway/zdcx'
//
config.baseUrl = 'https://crm.wuliangye.com.cn/gateway/zdcx'
//
config.baseUrl = 'http://221.10.127.60:5000/gateway/zdcx'
config
.
baseUrl
=
'http://221.10.127.60:5000/gateway/zdcx'
}
else
if
(
config
.
url
.
indexOf
(
'uusafe'
)
!==
-
1
)
{
}
else
if
(
config
.
url
.
indexOf
(
'uusafe'
)
!==
-
1
)
{
config
.
baseUrl
=
'https://apps.wuliangye.com.cn:9076'
//
config.baseUrl = 'https://apps.wuliangye.com.cn:9076'
//
config.baseUrl = 'https://zzy.ipincloud.cn:9070'
config
.
baseUrl
=
'https://zzy.ipincloud.cn:9070'
}
else
{
}
else
{
config
.
baseUrl
=
'http://218.89.67.37:8001/wlySap'
//
config.baseUrl = 'http://218.89.67.37:8001/wlySap'
//
config.baseUrl = 'http://221.10.127.60:5000/wlySap'
config
.
baseUrl
=
'http://221.10.127.60:5000/wlySap'
}
}
console
.
log
(
config
.
baseUrl
)
console
.
log
(
config
.
baseUrl
)
}
catch
(
e
)
{
}
catch
(
e
)
{
...
...
store/index.js
View file @
2727ebc4
...
@@ -12,7 +12,7 @@ try {
...
@@ -12,7 +12,7 @@ try {
}
}
// 需要永久存储,且下次APP启动需要取出的,在state中的变量名
// 需要永久存储,且下次APP启动需要取出的,在state中的变量名
let
saveStateKeys
=
[
'vuex_user'
,
'vuex_token'
];
let
saveStateKeys
=
[
'vuex_user'
,
'vuex_token'
,
'userInfo'
,
'userBpData'
,
'isChildCustomer'
];
// 保存变量到本地存储中
// 保存变量到本地存储中
const
saveLifeData
=
function
(
key
,
value
)
{
const
saveLifeData
=
function
(
key
,
value
)
{
...
@@ -38,11 +38,12 @@ const store = new Vuex.Store({
...
@@ -38,11 +38,12 @@ const store = new Vuex.Store({
// 如果vuex_version无需保存到本地永久存储,无需lifeData.vuex_version方式
// 如果vuex_version无需保存到本地永久存储,无需lifeData.vuex_version方式
vuex_version
:
'1.0.1'
,
vuex_version
:
'1.0.1'
,
vuex_demo
:
'绛紫'
,
vuex_demo
:
'绛紫'
,
userInfo
:
{
// 从本地存储恢复登录信息,避免热重载时丢失
userInfo
:
lifeData
.
userInfo
?
lifeData
.
userInfo
:
{
name
:
''
,
name
:
''
,
code
:
''
code
:
''
},
},
userBpData
:
{
userBpData
:
lifeData
.
userBpData
?
lifeData
.
userBpData
:
{
USER_BP
:
''
,
USER_BP
:
''
,
ROLES
:
[{
ROLES
:
[{
"ROLE_DESC"
:
""
,
"ROLE_DESC"
:
""
,
...
@@ -69,7 +70,27 @@ const store = new Vuex.Store({
...
@@ -69,7 +70,27 @@ const store = new Vuex.Store({
'INFO'
:
{},
'INFO'
:
{},
'baseinfo'
:
{}
'baseinfo'
:
{}
},
},
isChildCustomer
:
false
// 从本地存储恢复登录信息,避免热重载时丢失
isChildCustomer
:
lifeData
.
isChildCustomer
!==
undefined
?
lifeData
.
isChildCustomer
:
false
},
getters
:
{
// 获取角色信息,包含 USER_BP 和 ROLE
role
(
state
)
{
if
(
!
state
.
userBpData
)
{
return
{
USER_BP
:
''
,
ROLE
:
''
}
}
// 获取第一个角色的 ROLE_ID
const
roleId
=
state
.
userBpData
.
ROLES
&&
state
.
userBpData
.
ROLES
.
length
>
0
?
state
.
userBpData
.
ROLES
[
0
].
ROLE_ID
:
''
return
{
USER_BP
:
state
.
userBpData
.
USER_BP
||
''
,
ROLE
:
roleId
}
}
},
},
mutations
:
{
mutations
:
{
$uStore
(
state
,
payload
)
{
$uStore
(
state
,
payload
)
{
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment