Subversion Repositories SmartDukaan

Rev

Rev 21257 | Rev 21259 | Go to most recent revision | Show entire file | Ignore whitespace | Details | Blame | Last modification | View Log | RSS feed

Rev 21257 Rev 21258
Line 23... Line 23...
23
				<div class="col-lg-10 updatesql">SELECT distinct d1.user_id from devices d1 left join devices d2 on (d1.imeinumber = d2.imeinumber and d1.created < d2.created) where d2.id is null</div>
23
				<div class="col-lg-10 updatesql">SELECT distinct d1.user_id from devices d1 left join devices d2 on (d1.imeinumber = d2.imeinumber and d1.created < d2.created) where d2.id is null</div>
24
				<div class="col-lg-2">
24
				<div class="col-lg-2">
25
					<button type="button" class="btn btn-primary sqlslecter">Use This</button>
25
					<button type="button" class="btn btn-primary sqlslecter">Use This</button>
26
				</div>
26
				</div>
27
			</li>
27
			</li>
-
 
28
			<li>							
-
 
29
				<div class="label label-info">Test Notification</div>
-
 
30
				<div class="clearfix"></div>
-
 
31
				<div class="col-lg-10 updatesql">SELECT distinct d1.user_id from devices d1 left join devices d2 on (d1.imeinumber = d2.imeinumber and d1.created < d2.created) where d2.id is null and d1.user_id(168,14,47,30916)</div>
-
 
32
				<div class="col-lg-2">
-
 
33
					<button type="button" class="btn btn-primary sqlslecter">Use This</button>
-
 
34
				</div>
-
 
35
			</li>
28
			<li>				
36
			<li>				
29
				<div class="label label-info">Unique users with price preferences set in range of 5000 or not set at all</div>
37
				<div class="label label-info">Unique users with price preferences set in range of 5000 or not set at all</div>
30
				<div class="clearfix"></div>
38
				<div class="clearfix"></div>
31
				<div class="col-lg-10 updatesql">SELECT User.id, User.email, ifnull(P.min_price,0), ifnull(P.max_price,0) FROM users User LEFT JOIN price_preferences P ON User.id = P.user_id LEFT JOIN devices d ON d.user_id = User.id WHERE (P.min_price <=  5000 AND P.max_price >= 5000 AND P.category_id =3) OR P.min_price is NULL GROUP BY d.imeinumber order by User.id DESC</div>
39
				<div class="col-lg-10 updatesql">SELECT User.id, User.email, ifnull(P.min_price,0), ifnull(P.max_price,0) FROM users User LEFT JOIN price_preferences P ON User.id = P.user_id LEFT JOIN devices d ON d.user_id = User.id WHERE (P.min_price <=  5000 AND P.max_price >= 5000 AND P.category_id =3) OR P.min_price is NULL GROUP BY d.imeinumber order by User.id DESC</div>
32
				<div class="col-lg-2">
40
				<div class="col-lg-2">
Line 63... Line 71...
63
		<h3>Enter message</h3>		
71
		<h3>Enter message</h3>		
64
		<?php //echo $this->Form->create('User',array('action'=>'push')); ?>				
72
		<?php //echo $this->Form->create('User',array('action'=>'push')); ?>				
65
		<?php echo $this->Form->input('name',array('label'=>'Campaign Name','required'=>true));?>
73
		<?php echo $this->Form->input('name',array('label'=>'Campaign Name','required'=>true));?>
66
		<?php echo $this->Form->input('title');?>
74
		<?php echo $this->Form->input('title');?>
67
		<?php echo $this->Form->input('notification_long_text',array('type'=>'textarea','id'=>'notification_long_text'));?>	
75
		<?php echo $this->Form->input('notification_long_text',array('type'=>'textarea','id'=>'notification_long_text'));?>	
68
		<?php echo $this->Form->input('image', array('label'=>'Image Url');?>
76
		<?php echo $this->Form->input('image', array('label'=>'Image Url'));?>
69
		<?php echo $this->Form->input('type',array('type'=>'select','options' => array('url'=>'Url','native'=>'Native','update'=>'Update')));?>
77
		<?php echo $this->Form->input('type',array('type'=>'select','options' => array('url'=>'Url','native'=>'Native','update'=>'Update')));?>
70
		<?php echo $this->Form->input('url');?>
78
		<?php echo $this->Form->input('url');?>
71
		<?php echo $this->Form->input('expiresat',array('type'=>'datetime'));?>
79
		<?php echo $this->Form->input('expiresat',array('type'=>'datetime'));?>
72
		<?php echo $this->Form->input('sendsms',array('type'=>'checkbox'));?>
80
		<?php echo $this->Form->input('sendsms',array('type'=>'checkbox'));?>
73
		<?php $notitype=array("GENERAL_NOTIFICATION"=>"GENERAL_NOTIFICATION","BATCH_CREDIT"=>"BATCH_CREDIT");
81
		<?php $notitype=array("GENERAL_NOTIFICATION"=>"GENERAL_NOTIFICATION","BATCH_CREDIT"=>"BATCH_CREDIT");