Skip to content
Toggle navigation
Projects
Groups
Snippets
Help
saas_plus
/
business-assistant
This project
Loading...
Sign in
Toggle navigation
Go to a project
Project
Repository
Issues
0
Merge Requests
0
Pipelines
Wiki
Settings
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Commit ca26721c
authored
Oct 22, 2022
by
张立顺
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
bugfix
1 parent
5dfc6255
Hide whitespace changes
Inline
Side-by-side
Showing
5 changed files
with
32 additions
and
50 deletions
components/Tab/Tab.wxml
pages/apply/apply.js
pages/tab/index/index.js
pages/tab/output/components/merchant/mrechant.js
pages/tab/output/output.js
components/Tab/Tab.wxml
View file @
ca26721
<wxs src="./Tab.wxs" module="filterUtils" />
<block wx:if="{{openScroll}}">
<scroll-view
class="tab-box {{align}} {{outClassName}}"
scroll-x
enable-flex
scroll-with-animation
scroll-into-view="{{to}}"
enhanced="{{true}}"
show-scrollbar="{{false}}"
>
class="tab-box {{align}} {{outClassName}}"
scroll-x
enable-flex
scroll-with-animation
scroll-into-view="{{to}}"
enhanced="{{true}}"
show-scrollbar="{{false}}">
<block wx:for="{{tab}}" wx:key="index">
<view
class="tab {{index==count?'active':''}}"
bindtap="click"
data-count="{{index}}"
id="to-{{index}}"
>
class="tab {{index==count?'active':''}}"
bindtap="click"
data-count="{{index}}"
id="to-{{index}}">
<view class="text">{{item}}</view>
<!-- <view class="text" style="width:{{38 * item.length + 20}}rpx;">{{item}}</view> -->
<view class="line" />
...
...
@@ -27,16 +25,13 @@
<view class="tab-box flex">
<block wx:for="{{tab}}" wx:key="index">
<view
class="tab {{index==count?'active':''}}"
style="width:{{itemWidth}}"
bindtap="click"
data-count="{{index}}"
>
<view class="text text-center">
{{item}}
</view>
class="tab {{index==count?'active':''}}"
style="width:{{itemWidth}}"
bindtap="click"
data-count="{{index}}">
<view class="text text-center">{{item}}</view>
<view class="line" style="lineStyle" />
<!--
-->
<!-- -->
<view wx:if="{{filterUtils.hasRedpoint(unreadClueCount)}}" class="redpoint" />
</view>
</block>
...
...
pages/apply/apply.js
View file @
ca26721
...
...
@@ -66,7 +66,10 @@ Page({
if
(
result
)
{
wx
.
$api
.
showToast
(
'申请成功'
)
setTimeout
(()
=>
{
wx
.
$router
.
back
()
wx
.
$router
.
back
(
page
=>
{
page
.
getClueInit
&&
page
.
getClueInit
()
// this.getClueInit()
})
},
1000
)
}
})
...
...
pages/tab/index/index.js
View file @
ca26721
...
...
@@ -169,8 +169,8 @@ Page({
wx
.
$router
.
go
(
'packageOutput.openBusiness'
,
params
)
}
else
{
//申请门店
let
{
type
,
item
}
=
e
.
currentTarget
.
dataset
wx
.
$router
.
go
(
'apply'
,
item
.
clueId
)
//
let { type, item } = e.currentTarget.dataset
wx
.
$router
.
go
(
'apply'
,
item
?.
clueId
||
''
)
}
// wx.$router.go('apply',1235)
},
...
...
@@ -213,20 +213,12 @@ Page({
},
// 提交测算
submit
(
e
)
{
<<<<<<<
HEAD
console
.
log
(
e
)
let
sales
=
e
?
+
e
.
detail
.
value
.
sales
:
this
.
data
.
formData
.
sales
let
flow
=
e
?
+
e
.
detail
.
value
.
flow
:
this
.
data
.
formData
.
flow
console
.
log
(
'flow'
,
sales
,
flow
)
const
reg
=
/^
[
1-9
]\d
*$/
console
.
log
(
reg
.
test
(
sales
),
flow
,
'---'
)
=======
console
.
log
(
e
);
let
sales
=
e
?
+
e
.
detail
.
value
.
sales
:
this
.
data
.
formData
.
sales
;
let
flow
=
e
?
+
e
.
detail
.
value
.
flow
:
this
.
data
.
formData
.
flow
;
console
.
log
(
'flow'
,
sales
,
flow
)
const
reg
=
/^
[
1-9
]\d
*$/
;
console
.
log
(
reg
.
test
(
sales
),
flow
,
"---"
);
>>>>>>>
79
abc4b9c737b04214efde25436bd78cadbc6b51
if
(
!
reg
.
test
(
sales
))
{
wx
.
showToast
({
title
:
'门店月平均新车销量应为正整数'
,
...
...
@@ -264,27 +256,16 @@ Page({
this
.
data
.
senceData
.
forEach
((
item
,
index
)
=>
{
item
.
productList
.
forEach
((
i
,
lastIndex
)
=>
{
if
(
i
.
profit
)
{
<<<<<<<
HEAD
let
sale
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].sale`
let
name
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].profit`
let
flowKey
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].flow`
let
profit
=
_this
.
formula
(
i
.
productType
,
sales
,
flow
)
console
.
log
(
name
,
profit
)
this
.
setData
({
[
name
]:
profit
,
[
sale
]:
sales
})
=======
let
sale
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].sale`
;
let
name
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].profit`
;
let
flowKey
=
`senceData[
${
index
}
].productList[
${
lastIndex
}
].flow`
;
let
profit
=
_this
.
formula
(
i
.
productType
,
sales
,
flow
);
console
.
log
(
name
,
profit
);
this
.
setData
({
[
name
]:
profit
,
[
sale
]:
sales
,
[
flowKey
]:
flow
,
});
>>>>>>>
79
abc4b9c737b04214efde25436bd78cadbc6b51
[
flowKey
]:
flow
})
}
})
})
...
...
@@ -569,6 +550,7 @@ Page({
wx
.
$api
.
setCopyData
(
phone
)
},
getClueInit
(
param
)
{
// console.log(22222)
this
.
getUnreadApi
(
param
)
this
.
getPageApi
(
param
)
},
...
...
pages/tab/output/components/merchant/mrechant.js
View file @
ca26721
...
...
@@ -149,7 +149,7 @@ Component({
this
.
setData
({
list
:
[]
})
return
wx
.
$api
.
showT
ips
(
result
.
message
)
return
wx
.
$api
.
showT
oast
(
result
.
message
)
}
let
{
dataList
,
yqMerchantIds
}
=
data
const
list
=
yqMerchantIds
.
reduce
((
list
,
item
,
index
)
=>
{
...
...
pages/tab/output/output.js
View file @
ca26721
...
...
@@ -116,7 +116,9 @@ Page({
/**
* 生命周期函数--监听页面初次渲染完成
*/
onReady
()
{},
onReady
()
{
// console.log(getTextWidth('随后获取dom元素的clientWidth 随后获取dom元素的clientWidth随后获取dom元素的clientWidth随后获取dom元素的clientWidth', '12px'))
},
/**
* 生命周期函数--监听页面显示
...
...
Write
Preview
Markdown
is supported
Attach a file
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 post a comment