l-5 ol-5">
|
22
|
+class LatestAppInfo(BaseModelMixin, PaiaiSrcMixin):
|
|
22
|
23
|
latest_adr_version_code = models.IntegerField(_(u'latest_adr_version_code'), default=0, help_text=u'最新安卓版本号')
|
|
23
|
24
|
latest_adr_version_name = models.CharField(_(u'latest_adr_version_name'), max_length=255, blank=True, null=True, help_text=u'最新安卓版本名')
|
|
24
|
25
|
latest_adr_app = models.FileField(_(u'latest_adr_app'), upload_to=upload_path, blank=True, null=True, help_text=u'最新版安卓 APP')
|
|
|
|
@@ -51,7 +52,7 @@ class LatestAppInfo(CreateUpdateMixin, PaiaiSrcMixin):
|
|
51
|
52
|
}
|
|
52
|
53
|
|
|
53
|
54
|
|
|
54
|
|
-class PatchInfo(CreateUpdateMixin, PlatformMixin, PaiaiSrcMixin):
|
|
|
55
|
+class PatchInfo(BaseModelMixin, PlatformMixin, PaiaiSrcMixin):
|
|
55
|
56
|
version = models.CharField(_(u'version'), max_length=255, blank=True, null=True, help_text=u'版本(1.0.0)')
|
|
56
|
57
|
patch = models.FileField(_(u'patch'), upload_to=upload_path, blank=True, null=True, help_text=u'补丁')
|
|
57
|
58
|
|
|
|
|
@@ -73,7 +74,7 @@ class PatchInfo(CreateUpdateMixin, PlatformMixin, PaiaiSrcMixin):
|
|
73
|
74
|
}
|
|
74
|
75
|
|
|
75
|
76
|
|
|
76
|
|
-class APPSettingsInfo(CreateUpdateMixin, PlatformMixin, PaiaiSrcMixin):
|
|
|
77
|
+class APPSettingsInfo(BaseModelMixin, PlatformMixin, PaiaiSrcMixin):
|
|
77
|
78
|
channel = models.CharField(_(u'channel'), max_length=255, blank=True, null=True, help_text=u'渠道')
|
|
78
|
79
|
version = models.CharField(_(u'version'), max_length=255, blank=True, null=True, help_text=u'版本(1.0.0)')
|
|
79
|
80
|
|
|
|
|
@@ -93,7 +94,7 @@ class APPSettingsInfo(CreateUpdateMixin, PlatformMixin, PaiaiSrcMixin):
|
|
93
|
94
|
}
|
|
94
|
95
|
|
|
95
|
96
|
|
|
96
|
|
-class SplashInfo(CreateUpdateMixin, PaiaiSrcMixin):
|
|
|
97
|
+class SplashInfo(BaseModelMixin, PaiaiSrcMixin):
|
|
97
|
98
|
splash_image = models.ImageField(_(u'splash_image'), upload_to=upload_path, blank=True, null=True, help_text=u'启动页面图片')
|
|
98
|
99
|
spalash_image_airtime = models.DateTimeField(_(u'spalash_image_airtime'), blank=True, null=True, help_text=u'启动页面图片开始日期')
|
|
99
|
100
|
spalash_image_deadline = models.DateTimeField(_(u'spalash_image_deadline'), blank=True, null=True, help_text=u'启动页面图片截止日期')
|
|
|
|
@@ -118,7 +119,7 @@ class SplashInfo(CreateUpdateMixin, PaiaiSrcMixin):
|
|
118
|
119
|
}
|
|
119
|
120
|
|
|
120
|
121
|
|
|
121
|
|
-class FeedbackInfo(CreateUpdateMixin, PaiaiSrcMixin):
|
|
|
122
|
+class FeedbackInfo(BaseModelMixin, PaiaiSrcMixin):
|
|
122
|
123
|
user_id = models.CharField(_(u'user_id'), max_length=255, blank=True, null=True, help_text=u'用户唯一标识')
|
|
123
|
124
|
feedback = models.TextField(_(u'feedback'), blank=True, null=True, help_text=u'用户反馈')
|
|
124
|
125
|
|
|
|
|
@@ -130,7 +131,7 @@ class FeedbackInfo(CreateUpdateMixin, PaiaiSrcMixin):
|
|
130
|
131
|
return u'{0.pk}'.format(self)
|
|
131
|
132
|
|
|
132
|
133
|
|
|
133
|
|
-class GuestEntranceControlInfo(CreateUpdateMixin, PlatformMixin, VersionMixin, PaiaiSrcMixin):
|
|
|
134
|
+class GuestEntranceControlInfo(BaseModelMixin, PlatformMixin, VersionMixin, PaiaiSrcMixin):
|
|
134
|
135
|
|
|
135
|
136
|
class Meta:
|
|
136
|
137
|
verbose_name = _('guestentrancecontrolinfo')
|
|
|
|
@@ -150,7 +151,7 @@ class GuestEntranceControlInfo(CreateUpdateMixin, PlatformMixin, VersionMixin, P
|
|
150
|
151
|
}
|
|
151
|
152
|
|
|
152
|
153
|
|
|
153
|
|
-class BoxProgramVersionInfo(CreateUpdateMixin):
|
|
|
154
|
+class BoxProgramVersionInfo(BaseModelMixin):
|
|
154
|
155
|
srv_version_code = models.IntegerField(_(u'srv_version_code'), default=0, help_text=u'Box Server 版本号')
|
|
155
|
156
|
srv_version_name = models.CharField(_(u'srv_version_name'), max_length=255, blank=True, null=True, help_text=u'Box Server 版本名')
|
|
156
|
157
|
srv_sha1 = models.CharField(_(u'srv_sha1'), max_length=255, blank=True, null=True, help_text=u'Box Server Commit SHA1')
|
|
|
|
@@ -6,15 +6,6 @@ from django.utils.translation import ugettext_lazy as _
|
|
6
|
6
|
from utils.version_utils import is_version_match
|
|
7
|
7
|
|
|
8
|
8
|
|
|
9
|
|
-class CreateUpdateMixin(models.Model):
|
|
10
|
|
- status = models.BooleanField(_(u'status'), default=True, help_text=_(u'状态'), db_index=True)
|
|
11
|
|
- created_at = models.DateTimeField(_(u'created_at'), auto_now_add=True, editable=True, help_text=_(u'创建时间'))
|
|
12
|
|
- updated_at = models.DateTimeField(_(u'updated_at'), auto_now=True, editable=True, help_text=_(u'更新时间'))
|
|
13
|
|
-
|
|
14
|
|
- class Meta:
|
|
15
|
|
- abstract = True
|
|
16
|
|
-
|
|
17
|
|
-
|
|
18
|
9
|
class PlatformMixin(models.Model):
|
|
19
|
10
|
BOTH = 0
|
|
20
|
11
|
ADR = 1
|
|
|
|
@@ -2,14 +2,14 @@
|
|
2
|
2
|
|
|
3
|
3
|
from django.db import models
|
|
4
|
4
|
from django.utils.translation import ugettext_lazy as _
|
|
|
5
|
+from models_ext import BaseModelMixin
|
|
5
|
6
|
from shortuuidfield import ShortUUIDField
|
|
6
|
7
|
from TimeConvert import TimeConvert as tc
|
|
7
|
8
|
|
|
8
|
9
|
from group.models import GroupPhotoInfo
|
|
9
|
|
-from pai2.basemodels import CreateUpdateMixin
|
|
10
|
10
|
|
|
11
|
11
|
|
|
12
|
|
-class OrderInfo(CreateUpdateMixin):
|
|
|
12
|
+class OrderInfo(BaseModelMixin):
|
|
13
|
13
|
NOMARK = 0
|
|
14
|
14
|
ORIGIN = 1
|
|
15
|
15
|
|
|
|
|
@@ -2,12 +2,12 @@
|
|
2
|
2
|
|
|
3
|
3
|
from django.db import models
|
|
4
|
4
|
from django.utils.translation import ugettext_lazy as _
|
|
|
5
|
+from models_ext import BaseModelMixin
|
|
5
|
6
|
|
|
6
|
|
-from pai2.basemodels import CreateUpdateMixin
|
|
7
|
7
|
from utils.qiniucdn import qiniu_file_url
|
|
8
|
8
|
|
|
9
|
9
|
|
|
10
|
|
-class UUIDInfo(CreateUpdateMixin):
|
|
|
10
|
+class UUIDInfo(BaseModelMixin):
|
|
11
|
11
|
uuid = models.CharField(_(u'uuid'), max_length=22, blank=True, null=True, help_text=u'唯一标识', db_index=True, unique=True)
|
|
12
|
12
|
lensman_id = models.CharField(_(u'lensman_id'), max_length=255, blank=True, null=True, help_text=u'摄影师唯一标识', db_index=True)
|
|
13
|
13
|
|
|
|
|
@@ -27,7 +27,7 @@ class UUIDInfo(CreateUpdateMixin):
|
|
27
|
27
|
}
|
|
28
|
28
|
|
|
29
|
29
|
|
|
30
|
|
-class PhotoUUIDInfo(CreateUpdateMixin):
|
|
|
30
|
+class PhotoUUIDInfo(BaseModelMixin):
|
|
31
|
31
|
photo_md5 = models.CharField(_(u'photo_md5'), max_length=255, blank=True, null=True, help_text=u'照片唯一标识', db_index=True, unique=True)
|
|
32
|
32
|
|
|
33
|
33
|
photo_path = models.CharField(_(u'photo_path'), max_length=255, blank=True, null=True, help_text=u'照片路径')
|
|
|
|
@@ -54,7 +54,7 @@ class PhotoUUIDInfo(CreateUpdateMixin):
|
|
54
|
54
|
return u'{0.pk}'.format(self)
|
|
55
|
55
|
|
|
56
|
56
|
|
|
57
|
|
-class PhotosInfo(CreateUpdateMixin):
|
|
|
57
|
+class PhotosInfo(BaseModelMixin):
|
|
58
|
58
|
lensman_id = models.CharField(_(u'lensman_id'), max_length=255, blank=True, null=True, help_text=u'摄影师唯一标识', db_index=True)
|
|
59
|
59
|
session_id = models.CharField(_(u'session_id'), max_length=255, blank=True, null=True, help_text=u'照片组唯一标识', db_index=True)
|
|
60
|
60
|
photo_id = models.CharField(_(u'photo_id'), max_length=255, blank=True, null=True, help_text=u'照片唯一标识', db_index=True)
|