rabin %!s(int64=7) %!d(string=hai) anos
pai
achega
c000833898
Modificáronse 1 ficheiros con 4 adicións e 3 borrados
  1. 4 3
      demos/helloworld/front/page/main.py

+ 4 - 3
demos/helloworld/front/page/main.py

@@ -27,9 +27,10 @@ class select_path(Load):
 		product = Demeter.model('product')
 		product.site_id = id
 		self.data['product'] = product.select(col = '*', order = 'cda2te desc', group = '', limit = '0,100')
-		Demeter.echo(product.sql)
-		Demeter.echo(product.bind)
-		Demeter.echo(product.log)
+		if not self.data['product']:
+			Demeter.echo(product.sql)
+			Demeter.echo(product.bind)
+			Demeter.echo(product.log)
 		self.view('index.html')
 
 # 测试数据库 更新和插入 /main/update