td class="lines-code">
+import android.webkit.WebViewClient;
8
+import android.widget.TextView;
9
+
10
+import com.android.views.progressbar.ProgressWheel;
11
+
12
+import ai.pai.lensman.R;
13
+import ai.pai.lensman.base.BaseActivity;
14
+import ai.pai.lensman.utils.SystemUtils;
15
+
16
+
17
+public class WebViewActivity extends BaseActivity implements View.OnClickListener {
18
+
19
+    private ProgressWheel spinner;
20
+
21
+    @Override
22
+    protected void onCreate(Bundle savedInstanceState) {
23
+        super.onCreate(savedInstanceState);
24
+        setContentView(R.layout.activity_webview);
25
+        SystemUtils.setImmerseLayout(this, findViewById(R.id.title_layout));
26
+
27
+        spinner = (ProgressWheel)findViewById(R.id.wheel_wait_http);
28
+
29
+        String url = getIntent().getStringExtra("url");
30
+        String title = getIntent().getStringExtra("title");
31
+        ((TextView) findViewById(R.id.title_bar_middle_txt)).setText(title);
32
+        findViewById(R.id.title_bar_back_layout).setOnClickListener(this);
33
+        findViewById(R.id.title_bar_option_layout).setVisibility(View.INVISIBLE);
34
+        WebView webView = (WebView) findViewById(R.id.webview_contract);
35
+        webView.getSettings().setJavaScriptEnabled(true);
36
+
37
+        spinner.setVisibility(View.VISIBLE);
38
+        spinner.startSpinning();
39
+
40
+        spinner.postDelayed(new Runnable() {
41
+            @Override
42
+            public void run() {
43
+                spinner.stopSpinning();
44
+                spinner.setVisibility(View.GONE);
45
+            }
46
+        },2000);
47
+        webView.setWebViewClient(new WebViewClient() {
48
+
49
+            @Override
50
+            public boolean shouldOverrideUrlLoading(WebView view, String url) {
51
+                view.loadUrl(url);
52
+                return true;
53
+            }
54
+
55
+        });
56
+        webView.setWebChromeClient(new WebChromeClient(){
57
+
58
+            @Override
59
+            public void onProgressChanged(WebView view, int newProgress) {
60
+                super.onProgressChanged(view, newProgress);
61
+                if(newProgress>90){
62
+                    spinner.stopSpinning();
63
+                    spinner.setVisibility(View.GONE);
64
+                }
65
+            }
66
+        });
67
+        webView.loadUrl(url);
68
+
69
+    }
70
+
71
+    @Override
72
+    public void onClick(View v) {
73
+        switch (v.getId()) {
74
+            case R.id.title_bar_back_layout:
75
+                finish();
76
+                break;
77
+            default:
78
+                break;
79
+        }
80
+    }
81
+}

+ 10 - 4
app/src/main/java/ai/pai/lensman/settings/SettingsActivity.java

@@ -1,12 +1,15 @@
1 1
 package ai.pai.lensman.settings;
2 2
 
3
+import android.content.Intent;
3 4
 import android.os.Bundle;
4 5
 import android.support.annotation.Nullable;
5
-import android.support.v7.app.AppCompatActivity;
6 6
 import android.widget.EditText;
7 7
 import android.widget.Toast;
8 8
 
9 9
 import ai.pai.lensman.R;
10
+import ai.pai.lensman.activities.AboutUsActivity;
11
+import ai.pai.lensman.activities.FeedbackActivity;
12
+import ai.pai.lensman.activities.WebViewActivity;
10 13
 import ai.pai.lensman.base.BaseActivity;
11 14
 import ai.pai.lensman.utils.BoxUrlContainer;
12 15
 import butterknife.BindView;
@@ -33,17 +36,20 @@ public class SettingsActivity extends BaseActivity {
33 36
 
34 37
     @OnClick(R.id.layout_about_us)
35 38
     void go2About(){
36
-
39
+        startActivity(new Intent(this, AboutUsActivity.class));
37 40
     }
38 41
 
39 42
     @OnClick(R.id.layout_contact)
40 43
     void go2Contact(){
41
-
44
+        Intent contactIntent = new Intent(this,WebViewActivity.class);
45
+        contactIntent.putExtra("url","http://pai.ai/page/contact_us");
46
+        contactIntent.putExtra("title",getString(R.string.contact_us));
47
+        startActivity(contactIntent);
42 48
     }
43 49
 
44 50
     @OnClick(R.id.layout_feedback)
45 51
     void go2Feedback(){
46
-
52
+        startActivity(new Intent(this, FeedbackActivity.class));
47 53
     }
48 54
 
49 55
     @OnClick(R.id.btn_confirm_ip)

+ 2 - 0
app/src/main/java/ai/pai/lensman/utils/UrlContainer.java

@@ -39,5 +39,7 @@ public class UrlContainer {
39 39
 
40 40
     public static final String QUERY_ORDER_URL = HOST_URL+"l/query";
41 41
 
42
+    public static final String FEEDBACK_URL = HOST_URL +"op/feedback";
43
+
42 44
 
43 45
 }

BIN
app/src/main/res/drawable-xhdpi/about_contract.png


BIN
app/src/main/res/drawable-xhdpi/about_update_app.png


BIN
app/src/main/res/drawable-xhdpi/logo_in_about.png


+ 9 - 0
app/src/main/res/drawable/send_btn_bg_selector.xml

@@ -0,0 +1,9 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<selector xmlns:android="http://schemas.android.com/apk/res/android">
3
+
4
+
5
+    <item android:drawable="@color/colorPrimary" android:state_selected="true"></item>
6
+    <item android:drawable="@color/colorPrimary" android:state_focused="true"></item>
7
+    <item android:drawable="@color/silver" android:state_enabled="false" />
8
+    <item android:drawable="@color/colorPrimary"></item>
9
+</selector>

+ 117 - 0
app/src/main/res/layout/activity_about_us.xml

@@ -0,0 +1,117 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:layout_width="match_parent"
4
+    android:layout_height="match_parent"
5
+    android:background="@color/white"
6
+    android:orientation="vertical">
7
+
8
+    <RelativeLayout
9
+        android:id="@+id/title_layout"
10
+        android:layout_width="match_parent"
11
+        android:layout_height="wrap_content"
12
+        android:background="@color/colorPrimaryDark">
13
+        <include layout="@layout/title_bar_with_back_and_option" />
14
+    </RelativeLayout>
15
+
16
+    <RelativeLayout
17
+        android:layout_width="match_parent"
18
+        android:layout_height="215dp"
19
+        android:gravity="center_horizontal">
20
+
21
+        <ImageView
22
+            android:layout_width="140dp"
23
+            android:layout_height="140dp"
24
+            android:layout_marginTop="51dp"
25
+            android:src="@drawable/logo_in_about"/>
26
+    </RelativeLayout>
27
+
28
+    <LinearLayout
29
+        android:id="@+id/layout_check_update"
30
+        android:layout_width="match_parent"
31
+        android:layout_height="44dp"
32
+        android:paddingLeft="12dp"
33
+        android:orientation="horizontal"
34
+        android:background="@color/white"
35
+        android:gravity="center_vertical">
36
+
37
+        <ImageView
38
+            android:layout_width="32dp"
39
+            android:layout_height="32dp"
40
+            android:src="@drawable/about_update_app"
41
+            />
42
+
43
+        <TextView
44
+            android:layout_width="0dp"
45
+            android:layout_weight="1"
46
+            android:layout_height="wrap_content"
47
+            android:text="@string/check_update"
48
+            android:textSize="16sp"
49
+            android:textColor="@color/dark_grey"
50
+            android:layout_marginLeft="10dp"/>
51
+
52
+        <ImageView
53
+            android:layout_width="wrap_content"
54
+            android:layout_height="wrap_content"
55
+            android:layout_marginRight="12dp"
56
+            android:layout_gravity="right|center_vertical"
57
+            android:src="@drawable/arrow_right"/>
58
+    </LinearLayout>
59
+
60
+
61
+    <LinearLayout
62
+        android:id="@+id/layout_about_declare"
63
+        android:layout_width="match_parent"
64
+        android:layout_height="44dp"
65
+        android:paddingLeft="12dp"
66
+        android:orientation="horizontal"
67
+        android:background="@color/white"
68
+        android:gravity="center_vertical">
69
+
70
+        <ImageView
71
+            android:layout_width="32dp"
72
+            android:layout_height="32dp"
73
+            android:src="@drawable/about_contract"
74
+            />
75
+
76
+        <TextView
77
+            android:layout_width="0dp"
78
+            android:layout_weight="1"
79
+            android:layout_height="wrap_content"
80
+            android:text="@string/contract"
81
+            android:textSize="16sp"
82
+            android:textColor="@color/dark_grey"
83
+            android:layout_marginLeft="10dp"/>
84
+
85
+        <ImageView
86
+            android:layout_width="wrap_content"
87
+            android:layout_height="wrap_content"
88
+            android:layout_marginRight="12dp"
89
+            android:layout_gravity="right|center_vertical"
90
+            android:src="@drawable/arrow_right"/>
91
+    </LinearLayout>
92
+
93
+
94
+    <LinearLayout
95
+        android:layout_width="match_parent"
96
+        android:layout_height="match_parent"
97
+        android:gravity="center|bottom"
98
+        android:paddingBottom="8dp"
99
+        android:orientation="vertical">
100
+
101
+        <TextView
102
+            android:layout_width="wrap_content"
103
+            android:layout_height="wrap_content"
104
+            android:textColor="@color/grey"
105
+            android:textSize="14sp"
106
+            android:text="@string/copyright"/>
107
+
108
+        <TextView
109
+            android:layout_width="wrap_content"
110
+            android:layout_height="wrap_content"
111
+            android:padding="4dp"
112
+            android:textColor="@color/grey"
113
+            android:textSize="14sp"
114
+            android:text="@string/company_name"/>
115
+
116
+    </LinearLayout>
117
+</LinearLayout>

+ 41 - 0
app/src/main/res/layout/activity_feedback.xml

@@ -0,0 +1,41 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:layout_width="match_parent"
4
+    android:layout_height="match_parent"
5
+    android:background="@color/background_light_grey_color"
6
+    android:orientation="vertical">
7
+
8
+    <RelativeLayout
9
+        android:id="@+id/title_layout"
10
+        android:layout_width="match_parent"
11
+        android:layout_height="wrap_content"
12
+        android:background="@color/colorPrimaryDark">
13
+        <include layout="@layout/title_bar_with_back_and_option" />
14
+    </RelativeLayout>
15
+
16
+    <EditText
17
+        android:id="@+id/et_feedback_content"
18
+        android:layout_width="match_parent"
19
+        android:textSize="14sp"
20
+        android:textColorHint="@color/grey"
21
+        android:background="@color/white"
22
+        android:textColor="@color/dark_grey"
23
+        android:hint="@string/feedback_hint"
24
+        android:paddingTop="10dp"
25
+        android:paddingLeft="12dp"
26
+        android:gravity="top"
27
+        android:layout_height="120dp" />
28
+
29
+    <Button
30
+        android:id="@+id/btn_feedback_send"
31
+        android:layout_width="match_parent"
32
+        android:layout_height="48dp"
33
+        android:layout_marginTop="30dp"
34
+        android:textColor="@color/white"
35
+        android:textSize="20sp"
36
+        android:enabled="false"
37
+        android:background="@drawable/send_btn_bg_selector"
38
+        android:text="@string/send"/>
39
+
40
+
41
+</LinearLayout>

+ 31 - 0
app/src/main/res/layout/activity_webview.xml

@@ -0,0 +1,31 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<RelativeLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:layout_width="match_parent"
4
+    android:layout_height="match_parent"
5
+    xmlns:progress="http://schemas.android.com/apk/res-auto"
6
+    android:background="@color/background_light_grey_color">
7
+
8
+    <RelativeLayout
9
+        android:id="@+id/title_layout"
10
+        android:layout_width="match_parent"
11
+        android:layout_height="wrap_content"
12
+        android:background="@color/colorPrimaryDark">
13
+        <include layout="@layout/title_bar_with_back_and_option" />
14
+    </RelativeLayout>
15
+
16
+    <WebView
17
+        android:id="@+id/webview_contract"
18
+        android:layout_width="match_parent"
19
+        android:layout_height="match_parent"
20
+        android:layout_below="@id/title_layout"/>
21
+
22
+    <com.android.views.progressbar.ProgressWheel
23
+        android:id="@+id/wheel_wait_http"
24
+        android:layout_width="80dp"
25
+        android:layout_height="80dp"
26
+        android:layout_centerInParent="true"
27
+        android:visibility="gone"
28
+        progress:textColor="@color/white"
29
+        progress:barColor="@color/colorPrimary"/>
30
+
31
+</RelativeLayout>

+ 51 - 0
app/src/main/res/layout/title_bar_with_back_and_option.xml

@@ -0,0 +1,51 @@
1
+<?xml version="1.0" encoding="utf-8"?>
2
+<LinearLayout xmlns:android="http://schemas.android.com/apk/res/android"
3
+    android:id="@+id/title_bar_with_back_btn"
4
+    android:layout_width="match_parent"
5
+    android:layout_height="@dimen/action_bar_height"
6
+    android:orientation="horizontal"
7
+    android:background="@color/colorPrimary">
8
+
9
+    <LinearLayout
10
+        android:id="@+id/title_bar_back_layout"
11
+        android:layout_width="70dp"
12
+        android:layout_height="match_parent"
13
+        android:gravity="center_vertical"
14
+        android:orientation="horizontal"
15
+        android:paddingLeft="12dp">
16
+
17
+        <ImageView
18
+            android:layout_width="32dp"
19
+            android:layout_height="32dp"
20
+            android:src="@drawable/back_selector" />
21
+
22
+    </LinearLayout>
23
+
24
+    <TextView
25
+        android:id="@+id/title_bar_middle_txt"
26
+        android:layout_width="0dp"
27
+        android:layout_height="match_parent"
28
+        android:layout_weight="1"
29
+        android:singleLine="true"
30
+        android:gravity="center"
31
+        android:paddingLeft="10dp"
32
+        android:paddingRight="10dp"
33
+        android:textColor="@color/white"
34
+        android:textSize="@dimen/action_bar_title_large_text_size" />
35
+
36
+    <LinearLayout
37
+        android:id="@+id/title_bar_option_layout"
38
+        android:layout_width="70dp"
39
+        android:layout_height="match_parent"
40
+        android:gravity="center_vertical|right"
41
+        android:orientation="horizontal"
42
+        android:paddingRight="12dp">
43
+
44
+        <ImageView
45
+            android:layout_width="32dp"
46
+            android:layout_height="32dp"
47
+            android:src="@drawable/option" />
48
+
49
+    </LinearLayout>
50
+
51
+</LinearLayout>

+ 1 - 0
app/src/main/res/values/colors.xml

@@ -4,6 +4,7 @@
4 4
     <color name="colorPrimaryDark">#2E78E5</color>
5 5
     <color name="colorAccent">#0BBE06</color>
6 6
 
7
+    <color name="silver">#C0C0C0</color>
7 8
     <color name="light_blue">#1E90FF</color>
8 9
     <color name="white">#ffffffff</color>
9 10
     <color name="transparent">#00000000</color>

+ 16 - 3
app/src/main/res/values/strings.xml

@@ -1,6 +1,11 @@
1 1
 <resources>
2 2
     <string name="app_name">拍爱</string>
3 3
     <string name="bar_app_name">拍爱摄影师版</string>
4
+
5
+    <string name="version_text">拍爱 V1.0</string>
6
+    <string name="copyright">Copyright © 2016 </string>
7
+    <string name="company_name">北京佳艺徕经贸有限责任公司</string>
8
+
4 9
     <string name="bt_connected">已连接</string>
5 10
     <string name="bt_disconnected">已断开</string>
6 11
     <string name="briefs">简报</string>
@@ -118,13 +123,21 @@
118 123
     <string name="price_manage">价格管理</string>
119 124
 
120 125
     <string name="platform_price_rule">分成及结算规则</string>
121
-    
126
+
122 127
     <string name="feedback">意见反馈</string>
123
-    
128
+
124 129
     <string name="contact_us">联系我们</string>
125
-    
130
+
126 131
     <string name="about_us">关于我们</string>
127 132
 
128 133
     <string name="box_set_ip">BOX IP设置</string>
129 134
 
135
+    <string name="send">发送</string>
136
+    <string name="feedback_hint">您的建议是我们前进的动力</string>
137
+    <string name="thank_feedback">已发送,感谢您的宝贵意见</string>
138
+    <string name="check_update">检查更新</string>
139
+    <string name="contract">用户协议</string>
140
+
141
+    <string name="check_update_processing">正在检查更新</string>
142
+
130 143
 </resources>

lensman balance decr when origin deleted & update redis · d79857ed0e - Gogs: Go Git Service

lensman balance decr when origin deleted & update redis

Brightcells 8 年 前
コミット
d79857ed0e
共有3 個のファイルを変更した52 個の追加16 個の削除を含む
  1. 48 12
      group/lensman_views.py
  2. 3 3
      pay/views.py
  3. 1 1
      utils/redis/rkeys.py

+ 48 - 12
group/lensman_views.py

@@ -15,7 +15,7 @@ from logit import logit
15 15
 from TimeConvert import TimeConvert as tc
16 16
 
17 17
 from account.models import LensmanInfo, UserIncomeExpensesInfo, UserInfo
18
-from group.models import GroupInfo, GroupPhotoInfo, GroupPhotoOrderInfo, GroupUserInfo
18
+from group.models import GroupInfo, GroupPhotoInfo, GroupPhotoOrderInfo
19 19
 from message.models import SystemMessageInfo
20 20
 from pay.models import OrderInfo
21 21
 from photo.models import PhotosInfo
@@ -23,8 +23,9 @@ from utils.error.errno_utils import LensmanStatusCode, OrderStatusCode, UserStat
23 23
 from utils.error.response_utils import response
24 24
 from utils.message_utils import system_messages
25 25
 from utils.page_utils import pagination
26
-from utils.redis.rgroup import get_group_info, get_group_users_info, set_group_info, set_group_users_info
27
-from utils.redis.rkeys import GROUP_LAST_PHOTO_PK, TODAY_INCOME, TODAY_UPLOAD_PHOTO_AMOUNT, WEEK_INCOME, WEEK_SOLD
26
+from utils.redis.rgroup import get_group_info, set_group_info
27
+from utils.redis.rkeys import (GROUP_LAST_PHOTO_PK, TODAY_INCOME, TODAY_UPLOAD_PHOTO_AMOUNT, TOTAL_INCOME, WEEK_INCOME,
28
+                               WEEK_SOLD)
28 29
 from utils.redis.rorder import set_lensman_order_record
29 30
 from utils.redis.rprice import get_lensman_price_fixed, set_lensman_price_fixed
30 31
 from utils.thumbnail_utils import make_thumbnail
@@ -299,28 +300,63 @@ def lensman_origin_photo_upload_api(request):
299 300
     except OrderInfo.DoesNotExist:
300 301
         return response(OrderStatusCode.WX_ORDER_NOT_FOUND)
301 302
 
302
-    from_uid = order.from_uid
303 303
     # 原图已删除, 处理退款逻辑
304 304
     if deleted:
305
+        # 用户增加余额
305 306
         try:
306
-            user = UserInfo.objects.get(uid=from_uid)
307
+            from_user = UserInfo.objects.select_for_update().get(user_id=order.from_uid)
307 308
         except UserInfo.DoesNotExist:
308 309
             pass
309 310
 
310
-        if user:
311
+        if from_user:
311 312
             # 增加余额
312
-            user.balance += order.total_fee
313
-            user.save()
313
+            from_user.balance += order.total_fee
314
+            from_user.save()
314 315
             # 余额记录
315 316
             UserIncomeExpensesInfo.objects.create(
316
-                user_id=from_uid,
317
+                user_id=order.from_uid,
317 318
                 photo_id=order.photo_id,
318 319
                 type=UserIncomeExpensesInfo.INCOME,
319 320
                 amount=order.total_fee,
320
-                balance=user.balance,
321
+                balance=from_user.balance,
321 322
                 remark=u'高清图购买退款',
322 323
             )
323 324
 
325
+        # 摄影师减少余额
326
+        try:
327
+            to_user = UserInfo.objects.select_for_update().get(user_id=order.to_uid)
328
+        except UserInfo.DoesNotExist:
329
+            pass
330
+
331
+        if to_user:
332
+            # 减少余额
333
+            to_user.balance -= order.total_fee
334
+            to_user.save()
335
+            # 余额记录
336
+            UserIncomeExpensesInfo.objects.create(
337
+                user_id=order.to_uid,
338
+                photo_id=order.photo_id,
339
+                type=UserIncomeExpensesInfo.EXPENSE,
340
+                amount=order.total_fee,
341
+                balance=to_user.balance,
342
+                remark=u'高清图购买退款',
343
+            )
344
+
345
+        # Redis 数值更新
346
+        ymd = tc.local_string(tc.to_local_datetime(order.created_at), format='%Y%m%d')
347
+        week = Week.withdate(order.created_at)
348
+
349
+        # 总收入
350
+        r.decr_limit(TOTAL_INCOME % (order.to_uid, order.photo_type), order.total_fee, limit=0)
351
+        # 周收入
352
+        r.decr_limit(WEEK_INCOME % (order.to_uid, order.photo_type, week), order.total_fee, limit=0)
353
+        # 日收入
354
+        r.decr_limit(TODAY_INCOME % (order.to_uid, order.photo_type, ymd), order.total_fee, limit=0)
355
+
356
+        # 周售出
357
+        r.decr_limit(WEEK_SOLD % (order.to_uid, order.photo_type, week), limit=0)
358
+
359
+        # 更新订单状态
324 360
         order.photo_status = OrderInfo.DELETED
325 361
         order.reback_status = True
326 362
         order.reback_at = tc.utc_datetime()
@@ -348,7 +384,7 @@ def lensman_origin_photo_upload_api(request):
348 384
         porder, created = GroupPhotoOrderInfo.objects.get_or_create(
349 385
             group_id=order.group_id,
350 386
             session_id=session_id,
351
-            user_id=from_uid,
387
+            user_id=order.from_uid,
352 388
             photo_id=order.photo_id,
353 389
             lensman_photo_id=photo_id,
354 390
         )
@@ -377,7 +413,7 @@ def lensman_brief_api(request):
377 413
     # 日上传
378 414
     today_upload = int(r.get(TODAY_UPLOAD_PHOTO_AMOUNT % (user_id, ymd)) or 0)
379 415
     # 周售出
380
-    week_sold = int(r.get(WEEK_SOLD % (OrderInfo.ORIGIN, user_id, ymd)) or 0)
416
+    week_sold = int(r.get(WEEK_SOLD % (user_id, OrderInfo.ORIGIN, ymd)) or 0)
381 417
 
382 418
     # 摄影师端系统消息
383 419
     systems = system_messages(user_id, SystemMessageInfo.PAIAI_LENSMAN)

+ 3 - 3
pay/views.py

@@ -138,8 +138,8 @@ def order_paid_success(order):
138 138
     total_fee = order.total_fee
139 139
 
140 140
     try:
141
-        user = UserInfo.objects.select_for_update().filter(user_id=to_uid)[0]
142
-    except IndexError:
141
+        user = UserInfo.objects.select_for_update().get(user_id=to_uid)
142
+    except UserInfo.DoesNotExist:
143 143
         return
144 144
 
145 145
     user.balance += order.total_fee
@@ -156,7 +156,7 @@ def order_paid_success(order):
156 156
     r.incr(TODAY_INCOME % (to_uid, order.photo_type, ymd), total_fee)
157 157
 
158 158
     # 周售出
159
-    r.incr(WEEK_SOLD % (order.photo_type, to_uid, week))
159
+    r.incr(WEEK_SOLD % (to_uid, order.photo_type, week))
160 160
 
161 161
     UserIncomeExpensesInfo.objects.create(
162 162
         user_id=to_uid,

+ 1 - 1
utils/redis/rkeys.py

@@ -38,7 +38,7 @@ TODAY_INCOME = 'today:income:%s:%s:%s'  # STRING,日收入,user_id、photo_t
38 38
 # 上传
39 39
 TODAY_UPLOAD_PHOTO_AMOUNT = 'today:upload:photo:amount:%s:%s'  # STRING,日上传照片数量,user_id、tc.local_string(format='%Y%m%d')
40 40
 # 售出
41
-WEEK_SOLD = 'week:sold:%s:%s:%s'  # STRING,周售出,photo_type、user_id、Week.thisweek().isoformat()
41
+WEEK_SOLD = 'week:sold:%s:%s:%s'  # STRING,周售出,user_id、photo_type、Week.thisweek().isoformat()
42 42
 
43 43
 # 摄影师定价相关
44 44
 LENSMAN_PHOTO_PRICE_FIXED = 'lensman:photo:price:fixed:%s'  # STRING,摄影师照片定价(单位:分),user_id