chengjie 5 月之前
父節點
當前提交
14e6c22bb3

二進制
.DS_Store


+ 1 - 1
app.js

@@ -5,7 +5,7 @@ App({
5 5
     //IsProduction: true,
6 6
     ShareTitle: "语境背单词",
7 7
     SharePath: "pages/index/index",
8
-    ShareImage: '../images/program_share-a01.png',
8
+    ShareImage: '../images/pic_07.png',
9 9
     ProgramID: 186,
10 10
     ProgramName: "语境背单词",
11 11
     AppID: "wx80059777521b897c",

二進制
pages/.DS_Store


+ 8 - 14
pages/main/article.js

@@ -17,7 +17,7 @@ const app = getApp();
17 17
 Page({
18 18
   data: {
19 19
     Words:"",
20
-    IsShowPanelHelp:true,
20
+    IsShowFirstOpen:true,
21 21
     IsBuilding:false,
22 22
     IsShowLightColor:false,
23 23
     IsShowKeyword:true,//显示关键词
@@ -31,13 +31,13 @@ Page({
31 31
   },
32 32
   onLoad: function (options) {
33 33
     let that = this;
34
-    let words=app.globalData.SelectedWords.join(" ");
35
-    const hiddenhelp=wx.getStorageSync('HiddenArticleHelp');
34
+    let words=app.globalData.SelectedWords.join(",");
35
+    const hiddenhelp=wx.getStorageSync('HiddenArticleFirstOpen');
36 36
 
37 37
     that.setData({
38 38
       Containnerheight: main.getWindowHeight(),
39 39
       Words:words, 
40
-      IsShowPanelHelp:!hiddenhelp,
40
+      IsShowFirstOpen:!hiddenhelp,
41 41
     });
42 42
 
43 43
     if (options.ID)
@@ -271,9 +271,9 @@ Page({
271 271
   },
272 272
   closeHelp:function(){
273 273
     this.setData({
274
-      IsShowPanelHelp:false,
274
+      IsShowFirstOpen:false,
275 275
     });
276
-    wx.setStorageSync('HiddenArticleHelp', true);
276
+    wx.setStorageSync('HiddenArticleFirstOpen', true);
277 277
   },
278 278
   selectedAnswer:function(e){
279 279
     const that=this;
@@ -353,17 +353,14 @@ Page({
353 353
   //访问服务器的GeneratePDF接口,提交this.data.Content数据,获得一个生成好的pdf文件,服务端的代码已经生成好
354 354
   generatePDF: function(e) {
355 355
     let that = this;
356
-    this.setData({ 
357
-      generatingPDF: true,
358
-    });
359
-    
356
+    that.data.Content.Words=that.data.Words.split(" ").join(",");
360 357
     let url = common.Encrypt("GeneratePDF");
361 358
     url =app.globalData.serverUrl + url;
362 359
     wx.request({
363 360
       url: url,
364 361
       method: "POST",
365 362
       data: {
366
-        Content: that.data.Content
363
+        Content: that.data.Content,
367 364
       },
368 365
       responseType: 'arraybuffer',  // 确保响应类型为arraybuffer
369 366
       success: function(res) {
@@ -415,9 +412,6 @@ Page({
415 412
           title: '网络错误,请稍候重试',
416 413
           icon: 'none'
417 414
         });
418
-      },
419
-      complete: function() {
420
-        that.setData({ generatingPDF: false });
421 415
       }
422 416
     });
423 417
   },

+ 1 - 1
pages/main/article.wxml

@@ -93,7 +93,7 @@
93 93
   </view>
94 94
 </view>
95 95
 
96
-<view wx:if="{{IsShowPanelHelp}}" class="panelHelp container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
96
+<view wx:if="{{IsShowFirstOpen}}" class="panelHelp container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
97 97
   <view class="panelHelp1">
98 98
     <image src="../images/sysIcon_b07.png" class="sysIcon_b07"></image>
99 99
     <view class="panelHelp2 FlexColumn">

+ 12 - 9
pages/main/myarticles.wxml

@@ -7,17 +7,20 @@
7 7
   <block wx:if="{{List.length>0}}">
8 8
     <view class="panel1 FlexColumn" wx:for="{{List}}" wx:key="index">
9 9
       <view class="text01" bind:tap="goto" data-url="article?ID={{item.ID}}">{{item.CreateTime}}</view>
10
-      <view class="panel11 FlexRow" bind:tap="goto" data-url="article?ID={{item.ID}}">
11
-        <view class="panelLine"></view>
12
-        <view class="panel111 FlexColumn">
13
-          <view class="text02">{{item.LevelStr}} {{item.ArticleStyle}}</view>
14
-          <view class="text03">{{item.ArticleStart}}</view>
10
+      
11
+      <view class="panel10 FlexColumn"  bind:tap="goto" data-url="article?ID={{item.ID}}">
12
+        <view class="panel11 FlexRow">
13
+          <view class="panelLine"></view>
14
+          <view class="panel111 FlexColumn">
15
+            <view class="text02">{{item.LevelStr}} {{item.ArticleStyle}}</view>
16
+            <view class="text03">{{item.ArticleStart}}</view>
17
+          </view>
18
+        </view>
19
+        <view class="panel12 FlexRow">
20
+          <text class="text04">{{item.WordsStr}}</text>
15 21
         </view>
16 22
       </view>
17
-      <view class="panel12 FlexRow" bind:tap="goto" data-url="article?ID={{item.ID}}">
18
-        <text class="text04">{{item.WordsStr}}</text>
19
-      </view>
20
-
23
+      
21 24
       <view class="panelBtn FlexRow">
22 25
         <view class="btn1" bind:tap="setClipboard" data-words="{{item.Words}}">复用单词</view>
23 26
         <image src="../images/sysIcon_a13.png" class="sysIcon_a13"></image>

+ 3 - 0
pages/main/myarticles.wxss

@@ -16,6 +16,9 @@
16 16
   color: #C1E1C1;
17 17
   position: relative;
18 18
 }
19
+.panel10{
20
+  width:100%;
21
+}
19 22
 .text01{
20 23
   align-self: start;
21 24
   margin: 30rpx 0 0 30rpx;

+ 1 - 1
pages/main/ocr.wxss

@@ -54,4 +54,4 @@
54 54
   width: 72rpx;
55 55
   height: 14rpx;
56 56
   background-color: #FFDD88;
57
-}
57
+}

+ 5 - 0
pages/main/paste.js

@@ -57,6 +57,11 @@ Page({
57 57
       delta: 1
58 58
     });
59 59
   },
60
+  showExample:function(){
61
+    this.setData({
62
+      IsShowExample:!this.data.IsShowExample,
63
+    });
64
+  },
60 65
   onShareAppMessage: function () {
61 66
     return {
62 67
       title: app.globalData.ShareTitle,

+ 9 - 1
pages/main/paste.wxml

@@ -1,7 +1,7 @@
1 1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2 2
   <view class="panel1 FlexRow">
3 3
     <view class="text01">1行1个单词或词组</view>
4
-    <view class="panel11 FlexRow">
4
+    <view class="panel11 FlexRow" bind:tap="showExample">
5 5
       <image src="../images/sysIcon_a01.png" class="sysIcon_a01"></image>
6 6
       <view>范例</view>
7 7
     </view>
@@ -21,4 +21,12 @@
21 21
       <view class="panelFooter13 panelFooter10 FlexColumn" bind:tap="submit">确定</view>
22 22
     </view>
23 23
   </view>
24
+</view>
25
+
26
+
27
+<view wx:if="{{IsShowExample}}" class="panelMenu container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
28
+  
29
+  <image src="../images/pic_h02.png" class="pic_h02"></image>
30
+  <image src="../images/pic_04.png" class="pic_04"></image>
31
+  <view class="panelExampleBtn FlexColumn" catch:tap="showExample">返回</view>
24 32
 </view>

+ 30 - 0
pages/main/paste.wxss

@@ -92,4 +92,34 @@
92 92
 .text02{
93 93
   font-size:24rpx;
94 94
   margin-top: 17rpx;
95
+}
96
+
97
+
98
+.panelMenu{
99
+  background-color: rgba(26,67,51,0.50);
100
+  z-index: 20;
101
+  position: fixed;
102
+  top:0;
103
+}
104
+
105
+.panelExampleBtn{
106
+  width: 100%;
107
+  height:140rpx;
108
+  background: #875A4B;
109
+  font-size: 48rpx;
110
+  color: #F0F0F0;
111
+  position: fixed;
112
+  bottom:0;
113
+}
114
+.pic_h02{
115
+  position: fixed;
116
+  bottom:176rpx;
117
+  width: 670rpx;
118
+  height:760rpx;
119
+}
120
+.pic_04{
121
+  width:100%;
122
+  height: 170rpx;
123
+  position: fixed;
124
+  bottom:140rpx;
95 125
 }

+ 6 - 0
pages/main/selectword.js

@@ -10,6 +10,7 @@ Page({
10 10
     Count:0,
11 11
     CountMax:COUNT_MAX,
12 12
     Words:[],
13
+    IsShowExample:false,
13 14
   },
14 15
   onLoad: function (options) {
15 16
     var that = this;
@@ -88,6 +89,11 @@ Page({
88 89
       this.close(2);
89 90
     }
90 91
   },
92
+  showExample:function(){
93
+    this.setData({
94
+      IsShowExample:!this.data.IsShowExample,
95
+    });
96
+  },
91 97
   onShareAppMessage: function () {
92 98
     return {
93 99
       title: app.globalData.ShareTitle,

+ 9 - 1
pages/main/selectword.wxml

@@ -2,7 +2,7 @@
2 2
   <block wx:if="{{Words.length>0}}">
3 3
     <view class="panel1 FlexRow">
4 4
       <view class="text01">挑选单词1-{{CountMax}}个</view>
5
-      <view class="panel11 FlexRow">
5
+      <view class="panel11 FlexRow" bind:tap="showExample">
6 6
         <image src="../images/sysIcon_a01.png" class="sysIcon_a01"></image>
7 7
         <view>提升识别</view>
8 8
       </view>
@@ -49,3 +49,11 @@
49 49
     </view>
50 50
   </view>
51 51
 </view>
52
+
53
+
54
+<view wx:if="{{IsShowExample}}" class="panelMenu container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
55
+  
56
+  <image src="../images/pic_h03.png" class="pic_h03"></image>
57
+  <image src="../images/pic_04.png" class="pic_04"></image>
58
+  <view class="panelExampleBtn FlexColumn" catch:tap="showExample">返回</view>
59
+</view>

+ 30 - 0
pages/main/selectword.wxss

@@ -166,4 +166,34 @@
166 166
   width:10rpx;
167 167
   height:16rpx;
168 168
   margin: 0 10rpx;
169
+}
170
+
171
+
172
+.panelMenu{
173
+  background-color: rgba(26,67,51,0.50);
174
+  z-index: 20;
175
+  position: fixed;
176
+  top:0;
177
+}
178
+
179
+.panelExampleBtn{
180
+  width: 100%;
181
+  height:140rpx;
182
+  background: #875A4B;
183
+  font-size: 48rpx;
184
+  color: #F0F0F0;
185
+  position: fixed;
186
+  bottom:0;
187
+}
188
+.pic_h03{
189
+  position: fixed;
190
+  bottom:176rpx;
191
+  width: 670rpx;
192
+  height:1258rpx;
193
+}
194
+.pic_04{
195
+  width:100%;
196
+  height: 170rpx;
197
+  position: fixed;
198
+  bottom:140rpx;
169 199
 }

+ 11 - 5
pages/main/wordsinput.js

@@ -8,7 +8,8 @@ Page({
8 8
     Words:[],
9 9
     IsShowAlert:false,
10 10
     IsShowSetPanel:false,
11
-    IsShowPanelHelp:false,
11
+    IsShowFirstOpen:false,
12
+    IsShowExample:false,
12 13
   },
13 14
   onLoad: function (options) {
14 15
     var that = this;
@@ -19,13 +20,13 @@ Page({
19 20
     if (!ArticleStyle)
20 21
       ArticleStyle=[{Name:"任意",CSS:"Selected"},{Name:"童话",CSS:""},{Name:"科幻",CSS:""},{Name:"奇幻",CSS:""},{Name:"旅行",CSS:""},{Name:"动物",CSS:""},{Name:"家庭亲子",CSS:""},{Name:"校园生活",CSS:""},{Name:"科普",CSS:""},{Name:"节日文化",CSS:""},{Name:"成长",CSS:""},{Name:"人生励志",CSS:""},{Name:"环保",CSS:""}];
21 22
   
22
-    const hiddenhelp=wx.getStorageSync('HiddenWordInputHelp');
23
+    const hiddenhelp=wx.getStorageSync('HiddenWordInputFirstOpen');
23 24
 
24 25
     that.setData({
25 26
       Containnerheight: main.getWindowHeight(),
26 27
       Grade:grade,
27 28
       ArticleStyle:ArticleStyle,
28
-      IsShowPanelHelp:!hiddenhelp,
29
+      IsShowFirstOpen:!hiddenhelp,
29 30
       KeyboardBtnName:"next",
30 31
     });
31 32
 
@@ -120,6 +121,11 @@ Page({
120 121
       IsShowSetPanel:!this.data.IsShowSetPanel,
121 122
     });
122 123
   },
124
+  showExample:function(){
125
+    this.setData({
126
+      IsShowExample:!this.data.IsShowExample,
127
+    });
128
+  },
123 129
   keyboardOK:function(e){
124 130
     const that=this;
125 131
     let id=e.currentTarget.dataset.id;
@@ -141,9 +147,9 @@ Page({
141 147
   },
142 148
   closeHelp:function(){
143 149
     this.setData({
144
-      IsShowPanelHelp:false,
150
+      IsShowFirstOpen:false,
145 151
     });
146
-    wx.setStorageSync('HiddenWordInputHelp', true);
152
+    wx.setStorageSync('HiddenWordInputFirstOpen', true);
147 153
   },
148 154
   selectBtn:function(e){
149 155
     const index=e.currentTarget.dataset.index;

+ 9 - 2
pages/main/wordsinput.wxml

@@ -1,7 +1,7 @@
1 1
 <view class="container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
2 2
   <view class="panel1 FlexRow">
3 3
     <view class="text01">输入单词5-10个</view>
4
-    <view class="panel11 FlexRow">
4
+    <view class="panel11 FlexRow" bind:tap="showExample">
5 5
       <image src="../images/sysIcon_a01.png" class="sysIcon_a01"></image>
6 6
       <view>范例</view>
7 7
     </view>
@@ -40,7 +40,7 @@
40 40
   
41 41
 </view>
42 42
 
43
-<view wx:if="{{IsShowPanelHelp}}" class="panelHelp container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
43
+<view wx:if="{{IsShowFirstOpen}}" class="panelHelp container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
44 44
   <view class="panelHelp1">
45 45
     <image src="../images/sysIcon_b06.png" class="sysIcon_b06"></image>
46 46
     <view class="panelHelp2 FlexColumn">
@@ -79,4 +79,11 @@
79 79
       </view>
80 80
     </view>
81 81
   </view>
82
+</view>
83
+
84
+<view wx:if="{{IsShowExample}}" class="panelMenu container FlexColumn" style='min-height:{{Containnerheight}}rpx;'>
85
+  
86
+  <image src="../images/pic_h01.png" class="pic_h01"></image>
87
+  <image src="../images/pic_04.png" class="pic_04"></image>
88
+  <view class="panelExampleBtn FlexColumn" catch:tap="showExample">返回</view>
82 89
 </view>

+ 22 - 0
pages/main/wordsinput.wxss

@@ -269,4 +269,26 @@
269 269
   height:60rpx;
270 270
   background: #303030;
271 271
   border-radius: 50%;
272
+}
273
+
274
+.panelExampleBtn{
275
+  width: 100%;
276
+  height:140rpx;
277
+  background: #875A4B;
278
+  font-size: 48rpx;
279
+  color: #F0F0F0;
280
+  position: fixed;
281
+  bottom:0;
282
+}
283
+.pic_h01{
284
+  position: fixed;
285
+  bottom:176rpx;
286
+  width: 670rpx;
287
+  height:950rpx;
288
+}
289
+.pic_04{
290
+  width:100%;
291
+  height: 170rpx;
292
+  position: fixed;
293
+  bottom:140rpx;
272 294
 }