Skip to content
Projects
Groups
Snippets
Help
This project
Loading...
Sign in / Register
Toggle navigation
W
wechat_baking
Overview
Overview
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
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
huahua
wechat_baking
Commits
eb4ebd13
Commit
eb4ebd13
authored
Jan 23, 2025
by
huahua
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
提交
parent
15df9d8e
Expand all
Hide whitespace changes
Inline
Side-by-side
Showing
9 changed files
with
164 additions
and
129 deletions
+164
-129
App.vue
+2
-2
pages/index/index.vue
+0
-0
pages/index/index_diy.vue
+36
-60
pages/index/machineDetail.vue
+80
-8
pages/index/shapeScrollView.vue
+1
-1
pages/index/textsettings.vue
+31
-28
pages/mall/lineUp.vue
+1
-25
util/Env.js
+5
-5
util/script.js
+8
-0
No files found.
App.vue
View file @
eb4ebd13
...
...
@@ -8,7 +8,7 @@
},
onLaunch
:
function
()
{
//字体列表
homeservice
.
queryList
({
/*
homeservice.queryList({
s: 'Material.fontFamilyList'
}).then(result => {
result.forEach(item=>{
...
...
@@ -58,7 +58,7 @@
})
}).catch(err => {
});
});
*/
},
onShow
:
function
()
{
//调用监听网络状态的方法
...
...
pages/index/index.vue
View file @
eb4ebd13
This diff is collapsed.
Click to expand it.
pages/index/index_diy.vue
View file @
eb4ebd13
This diff is collapsed.
Click to expand it.
pages/index/machineDetail.vue
View file @
eb4ebd13
...
...
@@ -41,13 +41,14 @@
<view
v-if=
"statusloading == 2"
style=
"min-height: 100%;background: #131319 !important;"
>
<view
class=
"start"
style=
"padding-bottom: 100upx; padding-top: 200upx;"
>
<image
src=
"../../static/icon_guaqi.png"
mode=
"aspectFill"
class=
"start_img"
></image>
<view
class=
"start_text"
style=
"margin-top: -80upx;font-size: 31upx;"
>
{{
machine_id
||
''
}}
</view>
<view
class=
"start_text"
>
{{
msg
||
''
}}
</view>
<view
@
click=
"tomakePhoneCall"
>
<view
@
click=
"tomakePhoneCall"
v-if=
"phone"
>
<view
class=
"start_text"
>
联系客服
</view>
<view
class=
"start_text"
style=
"display: flex; justify-content: center; align-items: center;"
>
<image
src=
"../../static/phone.png"
mode=
""
style=
"width: 32upx; height: 32upx; margin-right: 5upx;"
></image>
{{
phone
||
'
18938664545
'
}}
{{
phone
||
''
}}
</view>
</view>
</view>
...
...
@@ -69,7 +70,7 @@
<image
src=
"../../static/liebiao.png"
mode=
""
style=
"width: 243upx; height: 123upx;"
></image>
</view>
<view
@
click=
"toProxyApplet()"
v-if=
"list.is_open_manage == 1"
style=
"position: fixed; z-index: 99; right: 0; bottom: 300upx; display: flex;align-items: center;justify-content: center;
<view
@
click=
"toProxyApplet()"
v-if=
"list.is_open_manage == 1
&& statusloading == 1
"
style=
"position: fixed; z-index: 99; right: 0; bottom: 300upx; display: flex;align-items: center;justify-content: center;
width: 100upx; height: 88upx; background: #F29F3D; border-radius: 44upx 0px 0px 44upx;"
>
<view
style=
"font-size: 24upx; font-weight: 800; color: #FFFFFF;"
>
<view>
运营
</view>
...
...
@@ -109,12 +110,16 @@
msg
:
null
,
worksid
:
1
,
statusloading
:
null
,
//加载状态
phone
:
'
18938664545
'
,
phone
:
''
,
goods
:
[],
//商品列表
currentIndex
:
0
,
selectItem
:
null
,
//选择对象
name
:
""
,
show_admin_login
:
0
show_admin_login
:
0
,
globalData
:
{
typefacedata
:
[],
num
:
0
},
};
},
...
...
@@ -209,7 +214,7 @@
mask
:
true
})
uni
.
makePhoneCall
({
phoneNumber
:
this
.
phone
||
'
18938664545
'
,
//仅为示例
phoneNumber
:
this
.
phone
||
''
,
//仅为示例
success
(
res
)
{
uni
.
hideLoading
();
},
...
...
@@ -281,7 +286,17 @@
}
else
{
this
.
worksid
=
100211
}
console
.
log
(
"worksid="
+
this
.
worksid
)
if
(
this
.
list
.
wx_flag
==
1
){
this
.
msg
=
"稍等片刻,我很快恢复"
this
.
myheadtext
=
'歇一歇'
//头部标题栏
this
.
statusloading
=
2
this
.
phone
=
this
.
list
.
shop
.
tel
uni
.
stopPullDownRefresh
();
uni
.
hideLoading
();
return
;
}
this
.
toFirstCheck
();
this
.
myheadtext
=
this
.
machine_id
//头部标题栏
}
...
...
@@ -351,7 +366,64 @@
this
.
$base
.
machine_id
=
this
.
machine_id
this
.
statusloading
=
1
;
this
.
Adlist
()
//轮播图
let
url
=
"/api/material/mchineFontFamilyList"
;
let
queryParam
=
{
machine_id
:
this
.
machine_id
}
var
that
=
this
;
this
.
$http
.
post
(
url
,
queryParam
).
then
(
result
=>
{
var
dataList
=
result
.
data
;
dataList
.
forEach
(
item
=>
{
item
.
long
=
false
item
.
textlong
=
null
})
dataList
.
unshift
({
id
:
0
,
key
:
"SourceHanSansCN-Normal"
,
remark
:
""
,
title
:
"思源黑体"
,
textlong
:
true
,
long
:
true
})
this
.
globalData
.
typefacedata
=
dataList
this
.
$base
.
typefacedata
=
this
.
globalData
.
typefacedata
let
t1
=
new
Date
().
getTime
();
let
that
=
this
this
.
globalData
.
typefacedata
.
forEach
(
textlist
=>
{
uni
.
loadFontFace
({
global
:
true
,
family
:
textlist
.
title
,
source
:
'url('
+
textlist
.
remark
+
')'
,
desc
:
{
weight
:
100
},
success
:
function
(
success
)
{
textlist
.
textlong
=
true
},
fail
:
function
(
fail
)
{
textlist
.
textlong
=
false
},
complete
(
res
)
{
//console.log("完成")
textlist
.
long
=
true
that
.
globalData
.
typefacedata
.
forEach
(
item
=>
{
if
(
item
.
long
==
true
)
{
that
.
globalData
.
num
++
}
})
that
.
$base
.
typefacedata
=
that
.
globalData
.
typefacedata
if
(
that
.
globalData
.
num
==
that
.
globalData
.
typefacedata
.
length
)
{
}
that
.
globalData
.
num
=
0
}
})
})
}).
catch
(
err
=>
{
//uni.hideLoading();
});
},
onShow
()
{
...
...
pages/index/shapeScrollView.vue
View file @
eb4ebd13
<
template
>
<view
class=
"content"
style=
"width: 100%; height: 100%; position: relative;
margin-top: 100upx;
"
>
<view
class=
"content"
style=
"width: 100%; height: 100%; position: relative;"
>
<refresh
@
interrupt=
"interrupt"
@
pushToInterrupt=
"pushToInterrupt"
@
finished=
"finished"
@
scrolltolower=
"g"
:scrollHeight=
"windowHeight"
>
<template
slot=
"top"
>
<view
style=
"color: #FFFFFF;position: absolute; top: 0;width: 100%; text-align: center;"
...
...
pages/index/textsettings.vue
View file @
eb4ebd13
...
...
@@ -2,8 +2,10 @@
<view>
<view
style=
"position: fixed;width: 100%;"
:style=
"
{bottom: inputBottom+'px'}">
<view
v-if=
"show && text != 'typeface'"
style=
"width: 100%; height: 100upx; display: flex; flex-direction: row; "
>
<!--
<view>
{{
show
}}{{
text
}}
</view>
-->
<view
style=
"width: 260upx; height: 100%; background: #292933; border-top-right-radius: 60upx;display: flex; flex-direction: row; "
>
<image
v-if=
"bg_text_color"
style=
"width: 47upx; height: 47upx; display: block;margin-top: 45upx; margin-left:45upx;"
src=
"../../static/img/icon_qiehuan_on.png"
...
...
@@ -24,13 +26,14 @@
height: 98upx;"
>
<view
style=
"width: 601upx; height: 57upx; background: rgb(255,255,255,0.1); margin: 21upx 41upx 21upx 21upx; border-radius: 10upx;"
>
<input
:fixed=
"true"
:auto-height=
"true"
:show-confirm-bar=
"false"
:cursor-spacing=
"73"
:adjust-position=
"false"
type=
"text"
maxlength=
"
20
"
@
input=
"textInput"
v-model=
"data.currentText"
@
focus=
"focusTextarea"
@
blur=
"blurTextarea"
type=
"text"
maxlength=
"
35
"
@
input=
"textInput"
v-model=
"data.currentText"
@
focus=
"focusTextarea"
@
blur=
"blurTextarea"
placeholder=
"请输入文字内容..."
style=
"font-size: 34upx; font-weight: 400; height: 57upx; line-height: 57upx; padding: 0upx 0 0upx 20upx; color: #FFFFFF;"
/>
</view>
<view
style=
"width: 1px; height: 28upx; background: #FFFFFF;"
></view>
<image
style=
"width: 43upx; height: 30upx; display: block;margin: auto;"
src=
"../../static/icon/icon_determine.png"
mode=
"aspectFill"
@
click=
"cancel('share')"
></image>
</view>
<view
v-if=
"text == 'typeface'"
style=
"border-bottom: 2upx solid #000000;"
>
<scroll-view
style=
"width: calc(100% - 40upx); margin: auto; height:598upx; overflow: hidden;"
scroll-y
scroll-with-animation
>
<view
v-for=
"(item, index) in typefacedata"
...
...
@@ -61,24 +64,7 @@
</scroll-view>
</view>
<view
v-if=
"show && text != 'typeface'"
style=
"display: flex; height: 90upx; padding: 38upx 0 41upx; align-items: center;"
>
<!-- 背景 -->
<!--
<view
style=
"width: calc(100% / 7);"
@
click=
"bgtextcolor"
>
<image
style=
"width: 69upx; height: 69upx; display: block;margin: auto;"
:src=
"bg_text_color ? '../../static/icon/icon_qiehuan_one.png' : '../../static/icon/icon_qiehuan.png'"
mode=
"aspectFill"
></image>
</view>
-->
<!-- 颜色 开始-->
<!--
<scroll-view
style=
"box-sizing: border-box; white-space: nowrap; margin: 10upx 0; "
scroll-x
scroll-with-animation
>
<view
style=
"text-align: center; display: inline-block; padding-left: 20upx;"
v-for=
"(item,index) in colorList"
:key=
"index"
@
click
.
stop=
"workcolor(item.color)"
>
<view
v-if=
"data.itemList[data.cidx]"
>
<view
v-if=
"data.itemList[data.cidx].font_color == item.color && !bg_text_color"
style=
"width: 60upx; height: 60upx; background: #000000; border: 4upx solid #EF6262; border-radius: 50%;"
:style=
"
{background:item.color}">
</view>
<view
v-else-if=
"data.itemList[data.cidx].under_color == item.color && bg_text_color"
style=
"width: 60upx; height: 60upx; background: #000000; border: 4upx solid #EF6262; border-radius: 50%;"
:style=
"
{background:item.color}" >
</view>
<view
v-else
style=
"width: 68upx; height: 68upx; border-radius: 50%;"
:style=
"
{background:item.color}" >
</view>
</view>
<view
v-else
style=
"width: 68upx; height: 68upx; border-radius: 50%;"
:style=
"
{background:item.color}">
</view>
</view>
</scroll-view>
-->
<!-- 颜色 结束-->
<!-- 颜色 开始-->
<scroll-view
style=
"box-sizing: border-box; white-space: nowrap;
margin-left: 35upx; margin-right: 35upx;margin-bottom: 30upx; margin-top: 40upx; width: calc(100% - 70upx);"
scroll-x
scroll-with-animation
>
...
...
@@ -721,7 +707,6 @@
index
:
'WG9'
}
],
show
:
true
,
data
:
null
,
bg_text_color
:
null
,
...
...
@@ -735,7 +720,8 @@
{
text
:
'站酷庆科黄油体'
,
url
:
'url("https://tprint.refinecolor.com/text/ZhankuQingkeButterBody.ttf")'
,
fontname
:
'站酷庆科黄油体'
,
lineheight
:
1.18
,
long
:
false
,
textlong
:
null
},
{
text
:
'字体视界法棍体'
,
url
:
'url("https://tprint.refinecolor.com/text/Font_horizon_method_stick_body.ttf")'
,
fontname
:
'字体视界法棍体'
,
lineheight
:
1.14
,
long
:
false
,
textlong
:
null
},
],
typefacedata
:
null
typefacedata
:
null
,
countNum
:
0
};
},
onShow
()
{
...
...
@@ -755,16 +741,26 @@
//替换文字
replaceText
(
textStr
){
if
(
textStr
.
includes
(
"-Regular"
)){
if
(
textStr
.
includes
(
"-Regular"
)){
textStr
=
textStr
.
replace
(
"-Regular"
,
""
)
}
return
textStr
;
}
return
textStr
;
},
//过滤字符串
/* filterTextInput(textStr) {
let content = textStr.replace(/[^\a-\z\A-\Z0-9\u4E00-\u9FA5\.\,\?\<\>\。\,\-\——\=\;\@\!\!\+\$\%\*\(\)\#\&\*]/g, '');
let that = this;
setTimeout(function() {
that.data.currentText = content;
that.$emit('textInput', content)
}, 0);
}, */
//过滤字符串
filterTextInput
(
textStr
)
{
let
content
=
textStr
.
replace
(
/
[^\a
-
\z\A
-
\Z
0-9
\u
4E00-
\u
9FA5
\.\,\?
\<
\>\。\,\-\—
—
\=\;\@\!\!\+\$\%\*\(\)\#\&\*]
/g
,
''
);
textStr
=
textStr
.
replace
(
/
\u
D83C
[\u
DF00-
\u
DFFF
]
|
\u
D83D
[\u
DC00-
\u
DE4F
]
/g
,
""
);
let
content
=
textStr
let
that
=
this
;
setTimeout
(
function
()
{
that
.
data
.
currentText
=
content
;
...
...
@@ -772,18 +768,23 @@
},
0
);
},
typefaceshow
(
e
){
this
.
$emit
(
'typefaceshow'
,
e
)
},
keyboard
(
e
)
{
this
.
inputBottom
=
0
},
typeface
(
e
)
{
this
.
text
=
e
this
.
inputBottom
=
0
let
that
=
this
;
//console.log("text="+this.text+"&show="+this.show+"&this.countNum="+this.countNum)
},
typefaceClick
(
e
,
index
)
{
// console.log(index + 1)
if
((
index
+
1
)
==
this
.
typefacedata
.
length
){
if
(
e
.
textlong
==
true
){
this
.
$emit
(
'typefaceClick'
,
e
)
...
...
@@ -798,6 +799,7 @@
this
.
$emit
(
'typefaceClick'
,
e
)
}
},
loadFont
(
textlist
)
{
let
that
=
this
;
uni
.
showLoading
({
...
...
@@ -825,6 +827,7 @@
}
})
},
setData
(
obj
)
{
let
that
=
this
;
let
keys
=
[];
...
...
@@ -861,7 +864,6 @@
},
textInput
(
e
)
{
this
.
filterTextInput
(
e
.
detail
.
value
)
//this.$emit('textInput', e)
},
cancel
(
e
)
{
this
.
$emit
(
'cancel'
,
e
)
...
...
@@ -879,6 +881,7 @@
this
.
data
=
data
.
data
this
.
bg_text_color
=
data
.
bg_text_color
this
.
text
=
data
.
text
console
.
log
(
"text="
+
this
.
text
)
if
(
this
.
text
==
'typeface'
){
this
.
typeface
(
'typeface'
)
this
.
inputBottom
=
'none'
...
...
pages/mall/lineUp.vue
View file @
eb4ebd13
...
...
@@ -61,19 +61,6 @@
</view>
</view>
<!--
<view
v-if=
"designer.status.value == 1"
>
<view
style=
"text-align: left; font-size: 29upx; color: #F29F3D ; line-height: 80upx;font-weight: 600;"
>
打印中
</view>
</view>
<view
v-else
>
<view
style=
"text-align: left; font-size: 30upx; color: #333; line-height: 80upx;font-weight: 600; margin-top: 20upx;"
>
排队中
</view>
</view>
<view
style=
"width: 90%;font-size: 28upx; margin-top: 70upx; font-weight: 550; text-align: right; font-size: 36upx; color: #333; margin-right: 30upx;"
>
{{
designer
.
id
||
''
}}
</view>
-->
<!-- 提示 -->
<view
v-if=
"sighstate && designer != null"
>
<view
...
...
@@ -88,8 +75,6 @@
style=
"width: 26upx; height: 26upx; padding: 12upx 22upx;"
></image>
</view>
<view
style=
"width: 558upx;position: absolute; top: 40upx "
>
<view
style=
"display: flex; align-items: center; justify-content: center;
width: 500upx;
height: 350upx;
...
...
@@ -105,15 +90,6 @@
</view>
</view>
<!--
<view
style=
"width: 400upx; height: 300upx; display: flex; border: 1px solid #F6BE36;
box-shadow: 0 0 20px #ccc; border-radius: 10upx;"
>
<view
style=
"display: flex; align-items: center; justify-content: center;
width: 100%; height: 200upx; margin: auto;"
>
<image
:src=
"designer.works_image + '?x-oss-process=image/resize,lfit,w_120'"
mode=
"aspectFit"
style=
" margin: auto; width: 120upx; max-height: 200upx; "
></image>
</view>
</view>
-->
<!-- 作品排队中 -->
<view
v-if=
"designer.status.value == 1"
style=
"text-align: center; font-size: 36upx; margin-top: 50upx;"
>
作品打印中
</view>
<view
v-if=
"designer.status.value != 1"
style=
"text-align: center; font-size: 36upx; margin-top: 50upx;"
>
作品排队中
</view>
...
...
@@ -164,7 +140,7 @@
key
:
2
,
//1直营配送站 2 万能通用版 3色彩自助站
sighstate
:
false
,
statetime
:
null
,
animMaind_time
:
10
000
,
//动画时间----刷子上下动画时间
animMaind_time
:
5
000
,
//动画时间----刷子上下动画时间
designer
:
null
,
userId
:
null
,
//用户信息
headheight
:
0
,
//头部高度
...
...
util/Env.js
View file @
eb4ebd13
...
...
@@ -3,13 +3,13 @@ if(!accountInfo.miniProgram.envVersion){
//console.error("获取运行环境失败!");
}
const
baseApi
=
{
//
开发版
//开发版
develop
:
"https://tprint.refinecolor.com"
,
//develop: "https://tprint.colorpark.cn",
//
体验版
trial
:
"https://tprint.refinecolor.com"
,
//
trial: "https://tprint.colorpark.cn",
//
正式版
//体验版
//
trial: "https://tprint.refinecolor.com",
trial
:
"https://tprint.colorpark.cn"
,
//正式版
release
:
"https://tprint.colorpark.cn"
,
};
const
baseURL
=
baseApi
[
accountInfo
.
miniProgram
.
envVersion
]
...
...
util/script.js
View file @
eb4ebd13
...
...
@@ -37,6 +37,14 @@ function callRecognizeBankCard(imageURL, miniProgramType, type, callback) {
request_
[
"ImageURL"
]
=
imageURL
;
request_
[
"Mode"
]
=
"ln17_256"
;
request_
[
"OutputFormat"
]
=
"png"
;
}
else
if
(
type
==
5
)
{
//图像超分
request_
[
"Url"
]
=
imageURL
;
Action
=
"MakeSuperResolutionImage"
;
endpoint
=
"imageenhan.cn-shanghai.aliyuncs.com"
;
API_VERSION
=
"2019-09-30"
;
request_
[
"Mode"
]
=
"enhancement"
;
request_
[
"UpscaleFactor"
]
=
"4"
;
request_
[
"OutputQuality"
]
=
"100"
;
}
else
{
request_
[
"AlgoType"
]
=
"handdrawn"
;
}
...
...
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