bulksms via reports

This commit is contained in:
gayathri1990 2018-10-24 19:48:57 +05:30
parent 3f29694919
commit 45ee323a47
8 changed files with 116 additions and 23 deletions

View File

@ -177,6 +177,7 @@ app.controller('report_app_pendingCtrl', ["$scope", "$filter","$rootScope","$mod
/**
* Auto Call Tracking Sriram
*/
$rootScope.selectedStudentMN = [];
$scope.selectedStudentsID = [];
$scope.isCheckAll = function(e){
var val = (e.target.checked ? true : false);
@ -210,11 +211,13 @@ app.controller('report_app_pendingCtrl', ["$scope", "$filter","$rootScope","$mod
var ide = e.target;
var val = (ide.checked ? true : false);
var sid = e.target.id;
var smn = e.target.Phone_number;
angular.forEach($scope.app_pending_data,function(value,key){
//console.log(value);
if(sid == value.Student_id)
{
sid = value;
smn = value.Phone_number;
}
});
@ -227,6 +230,7 @@ app.controller('report_app_pendingCtrl', ["$scope", "$filter","$rootScope","$mod
//console.log("PUSH");
$scope.selectedStudentsID.push(sid);
$rootScope.selectedStudentMN.push(smn);
}
}
@ -235,6 +239,7 @@ app.controller('report_app_pendingCtrl', ["$scope", "$filter","$rootScope","$mod
//console.log("POP");
$scope.selectedStudentsID.splice(pos,1);
$rootScope.selectedStudentMN.splice(pos,1);
}
//
if(val){
@ -244,6 +249,21 @@ app.controller('report_app_pendingCtrl', ["$scope", "$filter","$rootScope","$mod
}
//console.log($scope.selectedStudentsID);
}
$scope.sendingsms = function(){
//$rootScope.student = $scope.selectedStudentsID;
if($scope.selectedStudentMN ==''){
swal('Select Check box','','warning');
return false;
}
else{
$state.go('app.broadCast.sendSMSPage');
}
}
$scope.calltracking = function(){
//$rootScope.student = $scope.selectedStudentsID;

View File

@ -227,6 +227,7 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
/**
* Auto Call Tracking Sriram
*/
$rootScope.selectedStudentbalfeesMN = [];
$scope.selectedStudentsID = [];
$scope.isCheckAll = function(e){
var val = (e.target.checked ? true : false);
@ -260,6 +261,7 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
var ide = e.target;
var val = (ide.checked ? true : false);
var sid = e.target.id;
var smn = e.target.Phone_number;
// console.log("328");
// console.log($scope.balfee_data);
angular.forEach($scope.balfee_data,function(value,key){
@ -267,6 +269,7 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
if(sid == value.Student_id && s == value.Sem_year)
{
sid = value;
smn = value.Phone_number;
}
});
console.log(sid);
@ -280,6 +283,7 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
//console.log("PUSH");
$scope.selectedStudentsID.push(sid);
$rootScope.selectedStudentbalfeesMN.push(smn);
}
}
@ -288,6 +292,7 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
//console.log("POP");
$scope.selectedStudentsID.splice(pos,1);
$rootScope.selectedStudentbalfeesMN.splice(smn);
}
//
if(val){
@ -297,6 +302,21 @@ app.controller('report_balfeeCtrl', ["$scope", "$filter","$rootScope","$modal",
}
//console.log($scope.selectedStudentsID);
}
$scope.sendingsms = function(){
//$rootScope.student = $scope.selectedStudentsID;
if($scope.selectedStudentbalfeesMN ==''){
swal('Select Check box','','warning');
return false;
}
else{
$state.go('app.broadCast.sendSMSPage');
}
}
$scope.calltracking = function(){
//$rootScope.student = $scope.selectedStudentsID;

View File

@ -173,6 +173,7 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
/**
* Auto Call Tracking Sriram
*/
$rootScope.selectedStudentcertificateMN = [];
$scope.selectedStudentsID = [];
$scope.isCheckAll = function(e){
var val = (e.target.checked ? true : false);
@ -206,6 +207,7 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
var ide = e.target;
var val = (ide.checked ? true : false);
var sid = e.target.id;
var smn = e.target.Phone_number;
// console.log("328");
// console.log($scope.balfee_data);
angular.forEach($scope.cert_data,function(value,key){
@ -213,6 +215,7 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
if(sid == value.Student_id)
{
sid = value;
smn = value.Phone_number;
}
});
console.log(sid);
@ -226,6 +229,7 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
//console.log("PUSH");
$scope.selectedStudentsID.push(sid);
$rootScope.selectedStudentcertificateMN.push(smn);
}
}
@ -234,6 +238,7 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
//console.log("POP");
$scope.selectedStudentsID.splice(pos,1);
$rootScope.selectedStudentcertificateMN.splice(pos,1);
}
//
if(val){
@ -243,6 +248,21 @@ app.controller('report_certificateCtrl', ["$scope", "$filter","$rootScope","$mod
}
//console.log($scope.selectedStudentsID);
}
$scope.sendingsms = function(){
//$rootScope.student = $scope.selectedStudentsID;
if($scope.selectedStudentcertificateMN ==''){
swal('Select Check box','','warning');
return false;
}
else{
$state.go('app.broadCast.sendSMSPage');
}
}
$scope.calltracking = function(){
//$rootScope.student = $scope.selectedStudentsID;

View File

@ -1,6 +1,6 @@
'use strict';
/*** controller for Wizard Form example***/
app.controller('sendSMSsuperadminCtrl', ["$scope", "$filter", "ngTableParams", "API_POINTS", "$http", "SweetAlert", "$state", 'md5', 'ipCookie', 'dateListDescService', function ($scope, $filter, ngTableParams, apiPoint, $http, SweetAlert, $state, md5, ipCookie, dateListDescService) {
app.controller('sendSMSsuperadminCtrl', ["$scope","$rootScope", "$filter", "ngTableParams", "API_POINTS", "$http", "SweetAlert", "$state", 'md5', 'ipCookie', 'dateListDescService', function ($scope,$rootScope, $filter, ngTableParams, apiPoint, $http, SweetAlert, $state, md5, ipCookie, dateListDescService) {
/**
* Send SMS Functionality
@ -10,6 +10,40 @@ app.controller('sendSMSsuperadminCtrl', ["$scope", "$filter", "ngTableParams", "
var localDetails = ipCookie('cookiechk');
$scope.init = function () {
$scope.mobilenumbers=$rootScope.selectedStudentMN;
$scope.certificatemobilenumbers=$rootScope.selectedStudentcertificateMN;
$scope.balfeesmobilenumbers=$rootScope.selectedStudentbalfeesMN;
if($scope.mobilenumbers != undefined)
{
//tabtwo: true
$scope.tabone = false;
$scope.tabtwo = true;
$scope.tabthree = false;
$scope.radio=1;
$scope.listMobileNums=$scope.mobilenumbers;
}
if($scope.certificatemobilenumbers != undefined)
{
//tabtwo: true
$scope.tabone = false;
$scope.tabtwo = true;
$scope.tabthree = false;
$scope.radio=1;
$scope.listMobileNums=$scope.certificatemobilenumbers;
}
if($scope.balfeesmobilenumbers != undefined)
{
//tabtwo: true
$scope.tabone = false;
$scope.tabtwo = true;
$scope.tabthree = false;
$scope.radio=1;
$scope.listMobileNums=$scope.balfeesmobilenumbers;
}
var logcheck = JSON.parse(localStorage.getItem('localObj'));

View File

@ -80,15 +80,13 @@
</form>
<!-- <pre>{{statusr | json}}</pre> -->
<div class="row" style="text-align: right;">
<div class="col-md-4">
<input class="form-control" type="text" ng-model="search" id="searchIn" autofocus tabindex="2" placeholder="Search" />
</div>
<div class="col-md-6">
<div class="col-md-6" style="align:right">
<button class="btn btn-success btn-o" ng-click="sendingsms()">Send SMS</button>
<button class="btn btn-success btn-o" ng-click="calltracking()">Call Tracking</button>
</div>
<button class="btn btn-success btn-o" ng-click="exportData()">Export to Excel</button>
</div>
</div>
<div class="table-responsive" style="margin-top: 20px;">
<table id="datatable" class="table table-striped table-bordered table-hover table-condensed" style="font-size:0.9em;" ng-controller="studentModalDemoCtrl">

View File

@ -72,25 +72,24 @@
</form>
<!-- <pre>{{statusr | json}}</pre> -->
<div class="row" style="text-align: right;">
<div class="row" style="text-align: right;">
<div class="col-md-2">
<input class="form-control" type="text" ng-model="search" id="searchIn" autofocus tabindex="2" placeholder="Search" />
</div>
<div class="col-md-2">
<div class="col-md-4">
<span>Total Fee:Rs.</span><span>{{gettotal() || "0"}}</span>
</div>
<div class="col-md-2">
<span>Paid:Rs.</span><span>{{getpaid() || "0"}}</span>
</div>
<div class="col-md-2">
<span>Balance:Rs.</span><span>{{getbalance() || "0"}}</span>
<span>({{getbalance()/gettotal()*100 | number : 2 || "0"}}%)</span>
</div>
<div class="col-md-2">
<div class="col-md-6">
<button class="btn btn-success btn-o" ng-click="sendingsms()">Send SMS</button>
<button class="btn btn-success btn-o" ng-click="calltracking()">Call Tracking</button>
</div>
<div class="col-md-2">
<button class="btn btn-success btn-o" ng-click="exportData()">Export to Excel</button>
</div>
</div>

View File

@ -121,10 +121,12 @@ td,th {
<div class="col-md-4">
<input class="form-control" type="text" ng-model="search" id="searchIn" autofocus tabindex="2" placeholder="Search" />
</div>
<div class="col-md-6">
<div class="col-md-8">
<button class="btn btn-success btn-o" ng-click="sendingsms()">Send SMS</button>
<button class="btn btn-success btn-o" ng-click="calltracking()">Call Tracking</button>
<button class="btn btn-success btn-o" ng-click="exportData()">Export to Excel</button>
</div>
<button class="btn btn-success btn-o" ng-click="exportData()">Export to Excel</button>
</div>
<div class="table-responsive" style="margin-top: 20px;">

View File

@ -16,7 +16,7 @@
<div ng-controller="sendSMSsuperadminCtrl" ng-init="init()">
<!--<h1>D</h1>-->
<tabset class="tabbable">
<tab heading="Send Student Messages" id="viewDayBook">
<tab heading="Send Student Messages" active="tabone" >
<div class="row">
<!--<div class="col-md-3">
<label for="form-field-select-2">
@ -241,7 +241,7 @@
<!--studen search result end-->
</div>
</tab>
<tab heading="Send Promotional Messages">
<tab heading="Send Promotional Messages" active ="tabtwo" >
<style>
.mobileNumberList {
margin: 6px;
@ -385,7 +385,7 @@
</div>
</form>
</tab>
<tab heading="Manage Groups">
<tab heading="Manage Groups" active ="tabthree">
<form name="Form" id="Form" novalidate ng-submit="AddGroup.submit(Form,myModel)" method="post">