Skip to content
Toggle navigation
Toggle navigation
This project
Loading...
Sign in
dev
/
zhiliang-light-mp
Go to a project
Toggle navigation
Toggle navigation pinning
Projects
Groups
Snippets
Help
Project
Activity
Repository
Pipelines
Graphs
Issues
0
Merge Requests
0
Wiki
Network
Create a new issue
Builds
Commits
Issue Boards
Files
Commits
Network
Compare
Branches
Tags
42cb6c6d
authored
2019-12-16 18:23:22 +0800
by
simon
Browse Files
Options
Browse Files
Tag
Download
Email Patches
Plain Diff
默认提交
1 parent
b3a2f8d4
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
7 additions
and
7 deletions
src/config.js
src/image/my-qrcode/qr-bg.png
src/pages/my-qrcode/my-qrcode.js
src/pages/my-qrcode/my-qrcode.wxml
src/config.js
View file @
42cb6c6
...
...
@@ -2,7 +2,7 @@ let ENV_CONFIG = require('./env/index');
const
APPID
=
''
/** ====每次发布版本记得修改此环境配置==== */
const
ENV
=
'
Dev
'
;
// Dev Prod
const
ENV
=
'
Prod
'
;
// Dev Prod
const
NET_CONFIG
=
ENV_CONFIG
[
ENV
];
const
MOCKAPI
=
ENV_CONFIG
.
mockApi
;
...
...
src/image/my-qrcode/qr-bg.png
View file @
42cb6c6
34.8 KB
|
W:
|
H:
26.8 KB
|
W:
|
H:
2-up
Swipe
Onion skin
src/pages/my-qrcode/my-qrcode.js
View file @
42cb6c6
...
...
@@ -64,7 +64,7 @@ Page({
let
avatarSpace
=
5
;
let
avatarWidBlock
=
300
*
0.3
;
let
avatarWid
=
avatarWidBlock
-
(
avatarSpace
*
2
);
let
qrTop
=
360
;
let
qrTop
=
268
;
// 合成图片需要的数据
let
{
userInfo
...
...
@@ -84,7 +84,7 @@ Page({
x
:
0
,
y
:
0
,
width
:
690
,
height
:
945
,
height
:
849
,
url
:
"../../image/my-qrcode/qr-bg.png"
,
},
// 二维码
...
...
@@ -111,7 +111,7 @@ Page({
let
lines
=
[];
let
texts
=
[{
x
:
690
/
2
,
y
:
71
6
,
y
:
62
6
,
width
:
690
,
fontSize
:
26
,
color
:
"#000000"
,
...
...
@@ -133,7 +133,7 @@ Page({
let
posterData
=
{
width
:
690
,
height
:
945
,
height
:
849
,
debug
:
false
,
blocks
:
blocks
,
images
:
images
,
...
...
@@ -192,7 +192,7 @@ Page({
return
;
}
wx
.
setClipboardData
({
data
:
'「深士照明」50万电工奖\n分享二维码:邀请好友就获奖\n好友购买:再获10
5
返现奖金'
,
data
:
'「深士照明」50万电工奖\n分享二维码:邀请好友就获奖\n好友购买:再获10
%
返现奖金'
,
success
(
res
)
{
wx
.
saveImageToPhotosAlbum
({
filePath
:
_this
.
data
.
imageUrl
,
...
...
src/pages/my-qrcode/my-qrcode.wxml
View file @
42cb6c6
...
...
@@ -9,7 +9,7 @@
<image bindtap="onPreviewImageHandler" class="my-card" mode="widthFix" src="{{imageUrl}}" />
</view>
<view class="tips">
<text>「深士照明」50万电工奖\n分享二维码:邀请好友就获奖\n好友购买:再获10
5
返现奖金</text>
<text>「深士照明」50万电工奖\n分享二维码:邀请好友就获奖\n好友购买:再获10
%
返现奖金</text>
</view>
<view class="btn-wrap">
<view bindtap="saveImageToPhotosAlbum" class="btn">保存照片|复制文字</view>
...
...
Please
register
or
sign in
to post a comment