|
@@ -504,8 +504,12 @@ class AiView(View):
|
|
|
content = ai_sm_qs[0]['lang__content']
|
|
|
currency = ai_sm_qs[0]['currency']
|
|
|
price = ai_sm_qs[0]['price']
|
|
|
- store_meal_name = title + '-' + content
|
|
|
-
|
|
|
+ ai_store_meal_qs = AiStoreMeal.objects.filter(id=rank, is_show=1, lang__lang='cn'). \
|
|
|
+ values('lang__title', 'lang__content')
|
|
|
+ if ai_store_meal_qs.exists():
|
|
|
+ store_meal_name = ai_store_meal_qs[0]['lang__title'] + '-' + ai_store_meal_qs[0]['lang__content']
|
|
|
+ else:
|
|
|
+ store_meal_name = '未知套餐'
|
|
|
nowTime = int(time.time())
|
|
|
orderID = CommonService.createOrderID()
|
|
|
price = round(float(price), 2)
|