コード例 #1
0
function addCat()
{
    $request = Slim::getInstance()->request();
    $body = json_decode($request->getBody());
    //print_r($body);exit;
    if (isset($body->id)) {
        unset($body->id);
    }
    $unique_field = array();
    $unique_field['name'] = $body->name;
    $rowcount = rowCount(json_encode($unique_field), 'category');
    //echo $rowcount;exit;
    if ($rowcount == 0) {
        $allinfo['save_data'] = $body;
        if (!empty($body->icon)) {
            $body->icon->filename = time() . $body->icon->filename;
            file_put_contents('category_icons/' . $body->icon->filename, base64_decode($body->icon->base64));
            $body->icon = $body->icon->filename;
        }
        //$allinfo['unique_data'] = $unique_field;
        $cat_details = add(json_encode($allinfo), 'category');
        if (!empty($cat_details)) {
            /* $user_details = add(json_encode($allinfo),'coupons');
               $user_details = json_decode($user_details);*/
            $result = '{"type":"success","message":"Added Succesfully"}';
        } else {
            $result = '{"type":"error","message":"Not Added"}';
        }
    } else {
        $result = '{"type":"error","message":"Already exists"}';
    }
    echo $result;
}
コード例 #2
0
            echo "\n<input type='checkbox' id='chkbox{$i}' name='chkbox{$i}' /><label for='chkbox{$i}'>{$rowPer['0']}</label><br>\n";
            echo "<input type='hidden' name='hidId{$i}' value='{$rowPer['0']}' />";
            $rowPer = null;
        }
    }
    $rsPer = null;
    $num_rows = 0;
}
if ($opn == 'assembly') {
    $pc = $_GET['pc'];
    $sub_div = $_GET['sub_div'];
    echo "<select id='assembly' name='assembly' style='width:180px;'>\n";
    include_once 'function/add_fun.php';
    //$rsAssembly=fatch_assembly_ag_pc($pc,$sub_div);
    $rsAssembly = fatch_assembly_ag_pc1($pc);
    $num_rows = rowCount($rsAssembly);
    if ($num_rows > 0) {
        echo "<option value='0'>-Select Assembly-</option>\n";
        for ($i = 1; $i <= $num_rows; $i++) {
            $rowAssembly = getRows($rsAssembly);
            echo "<option value='{$rowAssembly['assemblycd']}'>{$rowAssembly['assemblyname']}</option>\n";
        }
    }
    $rsAssembly = null;
    $num_rows = 0;
    $rowAssembly = null;
    echo "</select>";
}
if ($opn == 'app_replacement') {
    $per_cd = $_GET['p_id'];
    $usercd = $_GET['usercd'];
コード例 #3
0
      <input type="hidden" id="hid_branch_code" name="hid_branch_code" />
    </tr>
	<tr>
	  <td align="left" colspan="4">&nbsp;</td></tr>
    <tr>
      <td colspan="4" align="center"><input type="submit" name="submit" id="submit" value="Save" class="button" onclick="javascript:return validate();" /></td>
    </tr>
    <tr><td colspan="4" align="left"><div id="form1_errorloc" class="error"></div></td></tr>
    <tr><td colspan="4" align="center"><div class="scroller">
            <?php 
//include_once('function/training_fun.php');
if (isset($rsBranch)) {
    unset($rsBranch, $rowBranch, $num_rows);
}
$rsBranch = fatch_branch_master('', $dist_cd);
$num_rows = rowCount($rsBranch);
if ($num_rows > 0) {
    echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
    echo "<tr height='30px'><th align='center'>Sl. No</th><th align='center'>Bank Code</th><th align='left'>Branch IFSC</th><th align='left'>Branch Name</th><th align='left'>Branch Address</th><th>Edit</th><th>Delete</th></tr>\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowBranch = getRows($rsBranch);
        $branch_cd = '"' . encode($rowBranch['branchcd']) . '"';
        $bank_cd = '"' . encode($rowBranch['bank_cd']) . '"';
        echo "<tr><td width='5%' align='right'>{$i}.</td><td align='center' width='15%'>{$rowBranch['bank_cd']}</td><td width='15%' align='left'>{$rowBranch['ifsc_code']}</td>";
        echo "<td width='25%' align='left'>{$rowBranch['branch_name']}</td><td width='35%' align='left'>{$rowBranch['address']}</td>";
        echo "<td align='center' width='10%'><img src='images/edit.png' alt='' height='20px' onclick='javascript:edit_branch({$branch_cd},{$bank_cd});' /></td>\n";
        echo "<td align='center' width='10%'><img src='images/delete.png' alt='' height='20px' onclick='javascript:delete_branch({$branch_cd},{$bank_cd});' /></td></tr>\n";
        unset($rowBranch, $branch_cd, $bank_cd);
    }
    echo "</table>\n";
} else {
コード例 #4
0
 // number of items per page.
 $all = $_GET['a'];
 if ($all == "all") {
     $items = $num_rows_T;
 }
 $nrpage_amount = $num_rows_T / $items;
 $page_amount = ceil($num_rows_T / $items);
 $page_amount = $page_amount - 1;
 $page = $_GET['p'];
 $section = 'training-allocation-list';
 if ($page < "1") {
     $page = "0";
 }
 $p_num = $items * $page;
 $rstraining_alloc_list = fatch_training_allocation_listAct($sub_div, $training_type, $training_venue, $frmdt, $todt, $usercode, $p_num, $items);
 $num_rows = rowCount($rstraining_alloc_list);
 if ($num_rows < 1) {
     echo "No record found";
     //echo $officeid.",".$officename.",".$frmdt.",".$todt.",".$usercode;
 } else {
     echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
     echo "<tr height='30px'><th>Sl.</th><th>Training Venue</th>\r\n\t\t\t\t<th>Date</th>\r\n\t\t\t\t<th>Time</th>\r\n\t\t\t\t<th>Post Status</th>\r\n\t\t\t\t<th>No of PP</th>\r\n\t\t\t\t<th>Delete</th></tr>\n";
     for ($i = 1; $i <= $num_rows; $i++) {
         $rowTraining_alloc_list = getRows($rstraining_alloc_list);
         $schedule_code = '"' . encode($rowTraining_alloc_list['schedule_code']) . '"';
         echo "<tr><td align='right' width='4%'>{$i}.</td><td align='left' width='30%'>{$rowTraining_alloc_list['venuename']}</td><td width='15%' align='center'>{$rowTraining_alloc_list['training_dt']}</td>";
         echo "<td width='15%' align='left'>{$rowTraining_alloc_list['training_time']}</td><td width='15%' align='left'>{$rowTraining_alloc_list['poststatus']}</td>";
         echo "<td width='10%' align='left'>{$rowTraining_alloc_list['no_pp']}</td>";
         echo "<td align='center' width='5%'><img src='images/delete.png' alt='' height='20px'";
         if ($rowTraining_alloc_list['usercode'] == $usercode) {
             echo " onclick='javascript:delete_training_allocation({$schedule_code});' ";
コード例 #5
0
ファイル: listrecords.php プロジェクト: slims/slims8_akasia
    $r = $res->execute();
    if ($r === false) {
        if (SHOW_QUERY_ERROR) {
            echo __FILE__ . ',' . __LINE__ . "<br />";
            echo "Query: {$query}<br />\n";
            print_r($db->errorInfo());
            exit;
        } else {
            $errors[] = oai_error('noRecordsMatch');
        }
    } else {
        $r = $res->setFetchMode(PDO::FETCH_ASSOC);
        if ($r === false) {
            exit("FetchMode is not supported");
        }
        $num_rows = rowCount($metadataPrefix, $extquery, $db);
        if ($num_rows == 0) {
            echo "Cannot find records: {$query}\n";
            $errors[] = oai_error('noRecordsMatch');
        }
    }
}
if (!empty($errors)) {
    oai_exit();
}
// Will we need a new ResumptionToken?
if ($args['verb'] == 'ListRecords') {
    $maxItems = MAXRECORDS;
} elseif ($args['verb'] == 'ListIdentifiers') {
    $maxItems = MAXIDS;
} else {
コード例 #6
0
unset($rsAssembly, $num_rows);
?>
									</select></td>
                    <td colspan="2">&nbsp;</td>
                </tr>
                <tr>
                	<td align="left">Polling Party No:</td>
                    <td align="left"><input type="text" name="polling_party_no" id="polling_party_no" style="width:142px;" onchange="return personnel_list();" /></td><td colspan="2">&nbsp;</td>
                </tr>
                <tr>
                	<td align="left">Post Status:</td>
                    <td align="left" colspan="3"><select id="posting_status" name="posting_status" onchange="return personnel_list();" style="width:150px;">
                    								<option value="0">-Select Posting Status-</option>
													<?php 
$rsP = fatch_postingstatus();
$num_rows = rowCount($rsP);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowP = getRows($rsP);
        echo "<option value='{$rowP['0']}'>{$rowP['1']}</option>\n";
    }
}
$rsP = null;
$num_rows = 0;
$rowP = null;
?>
                                                 </select></td>
                </tr>
                <tr>
                	<td align="left"><b>Personnel ID:</b></td>
                    <td align="left"><span id="personnel_list"><select id="p_id" name="p_id" style="width:150px;" onchange="fatch_personnel_dtl(this.value);"></select>
}
unset($rsBn, $num_rows, $rowSubDiv);
?>
      				</select></td></tr>
	<tr>
	  <td align="left">Subdivision</td>
	  <td align="left" id="subdiv_result"><select name="Subdivision" id="Subdivision" style="width:240px;">
      				</select></td></tr>
    <tr>
      <td align="left">Government Category</td>
      <td align="left"><select name="govt_cat" id="govt_cat" style="width:240px;">
      					<option value="0">-Select Government Category-</option>
                            <?php 
include_once "function/add_fun.php";
$rsBn = fatch_statusofoffice('');
$num_rows = rowCount($rsBn);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowBn = getRows($rsBn);
        echo "<option value='{$rowBn['0']}'>{$rowBn['1']}</option>\n";
        $rowBn = NULL;
    }
}
unset($rsBn, $rowBn, $num_rows);
?>
                        </select></td>
    </tr>    
    <tr><td colspan="2"><img src="images/blank.gif" alt="" height="2px" /></td></tr>
    <tr>
      <td colspan="2" align="center"><input type="submit" name="submit" id="submit" value="Submit" class="button" /></td></tr>
      <tr><td colspan="2" align="center"><img src="images/blank.gif" alt="" height="5px" /></td></tr>
コード例 #8
0
$stmt = mysqli_prepare($link, $sql);
mysqli_stmt_bind_param($stmt, 'issssssssssssssssssss', $grp_id, $for_ass, $for_pc, $pp_code, $pp_name, $pp_desig, $post_status, $post_stat, $pp_ofc_cd, $pp_office, $ofc_add, $postofc, $subdiv, $ps, $dist, $pin, $dcvenue, $dc_addr, $dc_dateD, $dc_time, $rcvenue);
$rec = 0;
extract($_GET);
$group_id = isset($_GET['group_id']) ? decode($_GET['group_id']) : "";
$forassembly = isset($_GET['assembly']) ? decode($_GET['assembly']) : "";
$forpc = $_GET['pc_cd'];
$sql1 = "update personnela set training2_sch='' where forpc='{$pc_cd}'";
$ret1 = execUpdate($sql1);
$sql19 = "update personnela join second_training on personnela.forpc=second_training.for_pc and personnela.forassembly=second_training.assembly and personnela.booked=second_training.party_reserve set personnela.training2_sch=second_training.schedule_cd where  personnela.groupid>=second_training.start_sl and personnela.groupid<=second_training.end_sl and second_training.for_pc='{$pc_cd}'";
$ret = execUpdate($sql19);
//$forpc='40';
$del_ret = delete_prev_data_second_rand_reserve($forassembly, $forpc, $group_id);
$rec_set_hdr = second_appointment_letter_reserve($group_id, $forassembly, $forpc);
if (rowCount($rec_set_hdr) > 0) {
    for ($n = 0; $n < rowCount($rec_set_hdr); $n++) {
        $rec_arr_hdr = getRows($rec_set_hdr);
        $grp_id = $rec_arr_hdr['groupid'];
        $for_ass = $rec_arr_hdr['assemblycd'] . "-" . $rec_arr_hdr['assemblyname'];
        $for_pc = $rec_arr_hdr['pccd'] . "-" . $rec_arr_hdr['pcname'];
        //$polling_station=$rec_arr_hdr['psno'].", ".$rec_arr_hdr['psname'];
        $dc = $rec_arr_hdr['dc_venue'] != '' ? $rec_arr_hdr['dc_venue'] . ", " . $rec_arr_hdr['dc_addr'] : "";
        $dc_date = $rec_arr_hdr['dc_date'] != '' ? $rec_arr_hdr['dc_date'] : "";
        $dc_dateD = $rec_arr_hdr['dc_dateD'] != '' ? $rec_arr_hdr['dc_dateD'] : "";
        $dc_time = $rec_arr_hdr['dc_time'] != '' ? $rec_arr_hdr['dc_time'] : "";
        $rcvenue = $rec_arr_hdr['rcvenue'] != '' ? $rec_arr_hdr['rcvenue'] : "";
        $dcvenue = $rec_arr_hdr['dc_venue'];
        $dc_addr = $rec_arr_hdr['dc_addr'];
        $pp_name = $rec_arr_hdr['officer_name'];
        $pp_desig = $rec_arr_hdr['off_desg'];
        $pp_code = $rec_arr_hdr['personcd'];
コード例 #9
0
        $rowTrainingVenue = getRows($rsTrainingVenue);
        echo "<option value='{$rowTrainingVenue['0']}'>{$rowTrainingVenue['1']}</option>\n";
        $rowTrainingVenue = null;
    }
}
$rowTrainingVenue = null;
$num_rows = 0;
?>
	    </select></td></tr>
    <tr>
      <td align="left"><span class="error">&nbsp;</span>Training Type</td>
      <td align="left"><select name="training_type" id="training_type" style="width:220px;">
		<option value="0">-Select Training Type-</option>
                            <?php 
$rsTrainingType = fatch_training_type('');
$num_rows = rowCount($rsTrainingType);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowTrainingType = getRows($rsTrainingType);
        echo "<option value='{$rowTrainingType['0']}' >{$rowTrainingType['1']}</option>\n";
    }
}
$rsTrainingType = null;
$num_rows = 0;
$rowTrainingType = null;
?>
      </select></td></tr>
    <tr>
      <td align="left">&nbsp;</td>
      <td align="left">&nbsp;</td>
    </tr>
コード例 #10
0
 DISTRICT</td></tr>
<tr>
  <td align="center">DETAILS REPORT</td></tr>
<tr><td align="center"><form method="post" name="form1" id="form1" target="_blank" action="reports/emp-query.php">
    <table width="60%" class="form" cellpadding="0">
	<tr><td align="center" colspan="2"><img src="images/blank.gif" alt="" height="2px" /></td></tr>
    <tr><td height="18px" colspan="2" align="center"><span id="msg" class="error"></span></td></tr>
    <tr><td colspan="2"><img src="images/blank.gif" alt="" height="5px" /></td></tr>
    <tr>
	  <td align="left"><span class="error">*</span>District</td>
	  <td align="left"><select name="district" id="district" style="width:240px;" onchange="javascript:return district_change(this.value);">
      						<option value="0">-Select District-</option>
                            <?php 
include_once "function/master_fun.php";
$rsDist = fatch_district_master('');
$num_rows = rowCount($rsDist);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowDist = getRows($rsDist);
        echo "<option value='{$rowDist['0']}'>{$rowDist['1']}</option>";
    }
}
$rsBn = null;
$num_rows = 0;
$rowSubDiv = null;
?>
      				</select></td></tr>
	<tr>
	  <td align="left"><span class="error">*</span>Subdivision</td>
	  <td align="left" id="subdiv_result"><select name="Subdivision" id="Subdivision" style="width:240px;">
      				</select></td></tr> 
コード例 #11
0
body{
	font-size: 14px;
	text-align: justify;
}
</style>
</head>
<body>
<div align="center">
<?php 
date_default_timezone_set('Asia/Calcutta');
include_once '../inc/db_trans.inc.php';
include_once '../function/form_12_fun.php';
$personcd = decode($_GET['personcd']);
$type = $_GET['type'];
$rsF12 = form12A_report($personcd, $type);
$num_rows = rowCount($rsF12);
$rowF12 = getRows($rsF12);
if ($rowF12['assemblyname'] == "" || $rowF12['assemblyname'] == null) {
    $assemblyname = "Other";
} else {
    $assemblyname = $rowF12['assemblyname'];
}
if ($rowF12['pcname'] == "" || $rowF12['pcname'] == null) {
    $pcname = "__________________";
} else {
    $pcname = $rowF12['pcname'];
}
?>
  <table width="400" border="0" cellspacing="0" cellpadding="1">
    <tr>
      <td><div align="center"><em>Conduct of Elections Rules, 1961</em></div></td>
コード例 #12
0
function merchantSaveMember()
{
    //echo 'aqb';exit;
    $is_active = 1;
    $site_path = SITEURL;
    $newdate = date('Y-m-d');
    $request = Slim::getInstance()->request();
    $membership_info = json_decode($request->getBody());
    $user_exist = $membership_info->user_type;
    unset($membership_info->user_type);
    if ($user_exist == "New User") {
        $unique_field = array();
        $user = array();
        $unique_field['email'] = $membership_info->email;
        //$unique_field['username']=$user->username;
        $rowCount = rowCount(json_encode($unique_field), 'users');
        if ($rowCount == 0) {
            $unique_code = time() . rand(100000, 1000000);
            $pass = '******';
            $user['txt_pwd'] = $pass;
            $user['email'] = $membership_info->email;
            $user['unique_code'] = $unique_code;
            $user['password'] = md5($pass);
            $user['user_type_id'] = 2;
            $user['is_active'] = 1;
            $user['registration_date'] = date('Y-m-d h:m:s');
            //$activation_link = $user->activation_url;
            //unset($user->activation_url);
            $allinfo['save_data'] = $user;
            //$allinfo['unique_data'] = $unique_field;
            $user_details = add(json_encode($allinfo), 'users');
            if (!empty($user_details)) {
                $user_details = json_decode($user_details);
                //echo  $user_details->email; exit;
                //  print_r($user_details);exit;
                $from = ADMINEMAIL;
                $to = $user_details->email;
                $subject = 'User Registration';
                $body = '<html><body><p>Dear User,</p>

		            <p>Thank You for signing up with mFoodGate.<br />
		            <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">Your Account Details:</span><br />
		            <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif"><strong>Email: ' . $to . '</strong></span><br />
		            <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif"><strong>Password: '******'</strong></span></p>

		            <p><span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">If we can help you with anything in the meantime just let us know by e-mailing&nbsp;</span>' . $from . '<br />
		            <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">Thanks again for signing up with the site</span><span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">!&nbsp;</span></p>

		            <p>Thanks,<br />
		            mFood&nbsp;Team</p>

		            <p>&nbsp;</p></body></html>
		            ';
                //$body = "Hello";
                sendMail($to, $subject, $body);
                $new_user_id = $user_details->id;
                $offer_details = json_decode(findById($membership_info->offer_id, 'offers'));
                $voucher_data = array();
                $voucher_data['offer_id'] = $membership_info->offer_id;
                $voucher_data['created_on'] = $offer_details->created_on;
                $voucher_data['price'] = $offer_details->price;
                $voucher_data['offer_price'] = $offer_details->offer_price;
                $voucher_data['offer_percent'] = $offer_details->offer_percent;
                $voucher_data['from_date'] = $offer_details->offer_from_date;
                $voucher_data['to_date'] = $offer_details->offer_to_date;
                $voucher_data['is_active'] = 1;
                $s = add(json_encode(array('save_data' => $voucher_data)), 'vouchers');
                $s = json_decode($s);
                $owner_data = array();
                $owner_data['offer_id'] = $membership_info->offer_id;
                $owner_data['voucher_id'] = $s->id;
                $owner_data['from_user_id'] = 0;
                $owner_data['to_user_id'] = $new_user_id;
                $owner_data['purchased_date'] = date('Y-m-d h:i:s');
                $owner_data['is_active'] = 1;
                $owner_data['price'] = $offer_details->price;
                $owner_data['offer_price'] = $offer_details->offer_price;
                $owner_data['offer_percent'] = $offer_details->offer_percent;
                $owner_data['buy_price'] = $offer_details->offer_price;
                add(json_encode(array('save_data' => $owner_data)), 'voucher_owner');
                $result = '{"type":"success","message":"Added Succesfully"}';
            } else {
                $result = '{"type":"error","message":"Try Again"}';
            }
        } else {
            if ($rowCount > 0) {
                $result = '{"type":"error","message":"Email already exist"}';
            }
        }
    } else {
        if ($user_exist == "Existing User") {
            $unique_code = $membership_info->unique_code;
            $sql = "SELECT * FROM users where users.unique_code=:unique_code";
            $db = getConnection();
            $stmt = $db->prepare($sql);
            $stmt->bindParam("unique_code", $unique_code);
            $stmt->execute();
            $user_info = $stmt->fetchObject();
            $count = $stmt->rowCount();
            if ($count == 0) {
                $result = '{"type":"error","message":"User code does not exist"}';
            } else {
                $new_user_id = $user_info->id;
                $offer_details = json_decode(findById($membership_info->offer_id, 'offers'));
                $voucher_data = array();
                $voucher_data['offer_id'] = $membership_info->offer_id;
                $voucher_data['created_on'] = $offer_details->created_on;
                $voucher_data['price'] = $offer_details->price;
                $voucher_data['offer_price'] = $offer_details->offer_price;
                $voucher_data['offer_percent'] = $offer_details->offer_percent;
                $voucher_data['from_date'] = $offer_details->offer_from_date;
                $voucher_data['to_date'] = $offer_details->offer_to_date;
                $voucher_data['is_active'] = 1;
                $s = add(json_encode(array('save_data' => $voucher_data)), 'vouchers');
                $s = json_decode($s);
                $owner_data = array();
                $owner_data['offer_id'] = $membership_info->offer_id;
                $owner_data['voucher_id'] = $s->id;
                $owner_data['from_user_id'] = 0;
                $owner_data['to_user_id'] = $new_user_id;
                $owner_data['purchased_date'] = date('Y-m-d h:i:s');
                $owner_data['is_active'] = 1;
                $owner_data['price'] = $offer_details->price;
                $owner_data['offer_price'] = $offer_details->offer_price;
                $owner_data['offer_percent'] = $offer_details->offer_percent;
                $owner_data['buy_price'] = $offer_details->offer_price;
                add(json_encode(array('save_data' => $owner_data)), 'voucher_owner');
                $result = '{"type":"success","message":"Added successfully"}';
            }
        }
    }
    echo $result;
}
コード例 #13
0
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowP = getRows($rsP);
        echo "<option value='{$rowP['0']}'>{$rowP['1']}</option>\n";
        $rowP = NULL;
    }
}
unset($rsP, $num_rows, $rowP);
?>
      				</select></td>
      <td align="left"><span class="error">*</span>Remarks</td>
      <td align="left"><!--<input type="text" name="remarks" id="remarks" style="width:142px;" maxlength="30" />-->
      <select name="remarks" id="remarks" style="width:150px;">
      						<option value="0">-Select Remarks-</option>
                            <?php 
$rsR = fatch_remarks();
$num_rows = rowCount($rsR);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowR = getRows($rsR);
        echo "<option value='{$rowR['remarks_cd']}'>{$rowR['remarks']}</option>\n";
        $rowR = NULL;
    }
}
unset($rsP, $num_rows, $rowP);
?>
      				</select>
      </td>
    </tr>
    <tr>
      <td align="left"><span class="error">&nbsp;&nbsp;</span>Group</td>
      <td align="left"><select name="pgroup" id="pgroup" style="width:150px;" >
コード例 #14
0
                echo "Changed";
            }
            $res2 = add_employee_replacement_log($new_p_id, $old_p_id, $ass, $groupid, $usercd);
        }
    }
}
//================================ Single Replacement Personnel =======================================
if ($opn == 'new_search') {
    $forpc = $_GET["forpc"];
    $ofc_id = $_GET["ofc_id"];
    $post_stat = $_GET["post_stat"];
    if ($forpc != '' && $ofc_id != '' && $gender != '') {
        $rsNew_Per;
        $rowNew_Per;
        $rsNew_Per = fatch_Random_personnel_for_PreGroupReplacement($forpc, $ofc_id, $gender, $post_stat);
        $num_rowsNew_Per = rowCount($rsNew_Per);
        if ($num_rowsNew_Per > 0) {
            $rowNew_Per = getRows($rsNew_Per);
            echo "<table>\n";
            echo "<tr><td align='center' colspan='4'><b>NEW PERSONNEL</b></td></tr>\n";
            echo "<tr><td align='left' width='22%'><b>Personnel ID: </b></td><td align='left' id='new_per_id'>" . $rowNew_Per['personcd'] . "</td><td align='left'><b>Office ID: </b></td><td>" . $rowNew_Per['officecd'] . "</td></tr>\n";
            echo "<tr><td align='left'>Name: </td><td align='left' colspan='3'>" . $rowNew_Per['officer_name'] . "</td></tr>\n";
            echo "<tr><td align='left'>Designation: </td><td align='left' colspan='3'>" . $rowNew_Per['off_desg'] . "</td></tr>\n";
            echo "<tr><td align='left'>Office Address: </td><td align='left' colspan='3'>" . $rowNew_Per['address1'] . "," . $rowNew_Per['address2'] . ", PO-" . $rowNew_Per['postoffice'] . ", PS-" . $rowNew_Per['policestation'] . ", Subdiv-" . $rowNew_Per['subdivision'] . ", Dist.-" . $rowNew_Per['district'] . "," . $rowNew_Per['pin'] . "</td></tr>\n";
            echo "<tr><td align='left'>Date of Birth: </td><td align='left'>" . $rowNew_Per['dateofbirth'] . "</td><td align='left'>Sex: </td><td align='left'>" . $rowNew_Per['gender'] . "</td></tr>\n";
            echo "<tr><td align='left'>EPIC No: </td><td align='left'>" . $rowNew_Per['epic'] . "</td><td align='left'>Posting Status: </td><td align='left'>" . $rowNew_Per['poststatus'] . "</td></tr>\n";
            echo "<tr><td align='left'>Present Address: </td><td align='left' colspan='3'>" . $rowNew_Per['present_addr1'] . ", " . $rowNew_Per['present_addr2'] . "</td></tr>\n";
            echo "<tr><td align='left' colspan='4'><b>Assembly of</b></td></tr>\n";
            echo "<tr><td align='left' colspan='2'>Present Address: </td><td align='left' colspan='2'>" . $rowNew_Per['pre_ass'] . "<hidden id='hid_pre_ass' name='hid_pre_ass' style='display:none;'>" . $rowNew_Per['pre_ass'] . "</hidden></td></tr>\n";
            echo "<tr><td align='left' colspan='2'>Permanent Address: </td><td align='left' colspan='2'>" . $rowNew_Per['per_ass'] . "<hidden id='hid_per_ass' name='hid_per_ass' style='display:none;'>" . $rowNew_Per['per_ass'] . "</hidden></td></tr>\n";
            echo "<tr><td align='left' colspan='2'>Place of Posting: </td><td align='left' colspan='2'>" . $rowNew_Per['post_ass'] . "<hidden id='hid_post_ass' name='hid_post_ass' style='display:none;'>" . $rowNew_Per['post_ass'] . "</hidden></td></tr>\n";
コード例 #15
0
      <td height="16px" colspan="4" align="center"><?php 
print isset($msg) ? $msg : "";
?>
<span id="msg" class="error"></span></td>
    </tr>
    <tr>
      <td align="center" colspan="4"><img src="images/blank.gif" alt="" height="2px" /></td>
    </tr>
    <tr>
      <td align="left"><span class="error">*</span>Subdivision Name</td>
      <td align="left"><select name="sub_div" id="sub_div" style="width:200px;" onchange="return subdivision_change(this.value);">
      							<option value='0'>Select</option>
      					<?php 
$districtcd = $dist_cd;
$rsSubDiv = fatch_Subdivision($districtcd);
$num_rows = rowCount($rsSubDiv);
for ($i = 1; $i <= $num_rows; $i++) {
    $rowSubDiv = getRows($rsSubDiv);
    echo "<option value='{$rowSubDiv['subdivisioncd']}'>{$rowSubDiv['subdivision']}</option>";
    unset($rowSubDiv);
}
unset($num_rows, $rsSubDiv);
?>
                       </select></td>
    </tr>
    <tr>
      <td align="left"><span class="error">*</span>Assembly</td>
      <td align="left" id="assembly_result"><select name="assembly" id="assembly" style="width:200px;"></select></td>
    </tr>
	<tr>
      <td align="left"><span class="error">&nbsp;&nbsp;</span>Master Roll/ Scroll</td>
コード例 #16
0
function addMerchant()
{
    $request = Slim::getInstance()->request();
    $user = json_decode($request->getBody());
    if (isset($user->id)) {
        unset($user->id);
    }
    $unique_field = array();
    $unique_field['email'] = $user->email;
    //$unique_field['username']=$user->username;
    $rowCount = rowCount(json_encode($unique_field), 'users');
    if ($rowCount == 0) {
        $unique_code = time() . rand(100000, 1000000);
        $pass = rand(100000, 1000000);
        //$user->password = $pass;
        $user->txt_pwd = $pass;
        $user->unique_code = $unique_code;
        $user->password = md5($user->password);
        $user->is_active = 1;
        /*if($user->user_type_id == 'Merchant'){
              $user->user_type_id = 3;
          }else{
              $user->user_type_id = 2;
          }*/
        #$user->user_type_id = 2;
        //$user->user_type_id = '2';
        $user->registration_date = date('Y-m-d h:m:s');
        #$activation_link = $user->activation_url;
        #unset($user->activation_url);
        if (!empty($user->image)) {
            file_put_contents('./user_images/' . $user->image->filename, base64_decode($user->image->base64));
            $user->image = $user->image->filename;
        }
        $allinfo['save_data'] = (array) $user;
        //$allinfo['unique_data'] = $unique_field;
        $user_details = add(json_encode($allinfo), 'users');
        //var_dump($user_details);
        //exit;
        if (!empty($user_details)) {
            $user_details = json_decode($user_details);
            //echo  $user_details->email; exit;
            //  print_r($user_details);exit;
            $from = ADMINEMAIL;
            $to = $user_details->email;
            $subject = 'User Registration';
            $body = '<html><body><p>Dear User,</p>

		    <p>Thank You for signing up with mFoodGate.<br />
		    <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">Your Account Details:</span><br />
		    <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif"><strong>Email: ' . $to . '</strong></span><br />
		    <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif"><strong>Password: '******'</strong></span></p>

		    <p>
		    <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">If we can help you with anything in the meantime just let us know by e-mailing&nbsp;</span>' . $from . '<br />
		    <span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">Thanks again for signing up with the site</span><span style="color:rgb(34, 34, 34); font-family:arial,sans-serif">!&nbsp;</span></p>

		    <p>Thanks,<br />
		    mFood&nbsp;Team</p>

		    <p>&nbsp;</p></body></html>
		    ';
            //$body = "Hello";
            sendMail($to, $subject, $body);
            $result = '{"type":"success","message":"Added Succesfully","data":' . json_encode($user_details) . '}';
        } else {
            $result = '{"type":"error","message":"Try Again"}';
        }
    } else {
        if ($rowCount > 0) {
            $result = '{"type":"error","message":"Email already exist"}';
        }
    }
    echo $result;
}
コード例 #17
0
print $_SESSION['environment'];
?>
</td></tr>
		<tr><td align="left" width="150px" class="heading1">ASSEMBLY :</td><td class="heading1"><?php 
print $rowAssembly['assemblycd'] . " - " . $rowAssembly['assemblyname'];
?>
</td></tr>
		<tr><td align="center" colspan="2">
		<table width="100%">
<?php 
if (rowCount($rec_set_hdr) > 0) {
    for ($n = 0; $n < rowCount($rec_set_hdr); $n++) {
        $rec_arr_hdr = getRows($rec_set_hdr);
        $grp_id = $rec_arr_hdr['groupid'];
        $rec_set = second_appointment_letter($grp_id, $rec_arr_hdr['assemblycd']);
        $num_rows = rowCount($rec_set);
        if ($num_rows > 0) {
            ?>
			<tr><td width="10%" class="table2">Polling Party : <?php 
            print $grp_id;
            ?>
</td>
				<td align="left" class="table2">
				<table width="100%">
<?php 
            for ($i = 0; $i < $num_rows; $i++) {
                $rec_arr = getRows($rec_set);
                ?>

					<tr><td class="table" width="5%">&nbsp;<?php 
                print $rec_arr['poststat'];
コード例 #18
0
include_once 'inc/db_trans.inc.php';
include_once 'function/training2_fun.php';
$rec = 0;
include_once 'inc/commit_con.php';
//try {
mysqli_autocommit($link, FALSE);
$sql_empty_sl = "update second_appt set slno=0";
execUpdate($sql_empty_sl);
$sql = "update second_appt set slno=? where pers_off=? and pr_personcd=?";
$stmt = mysqli_prepare($link, $sql);
if ($stmt != false) {
    mysqli_stmt_bind_param($stmt, 'iss', $slno, $pers_off, $pr_personcd);
}
$rsRec = fetch_second_apt();
$num_rows = rowCount($rsRec);
if ($num_rows > 0) {
    for ($i = 0; $i < $num_rows; $i++) {
        $rowRec = getRows($rsRec);
        $pers_off = $rowRec['pers_off'];
        $pr_personcd = $rowRec['pr_personcd'];
        $slno = $i + 1;
        mysqli_stmt_execute($stmt);
        $rec += mysqli_stmt_affected_rows($stmt);
    }
}
if (!mysqli_commit($link)) {
    print "Transaction commit failed\n";
    exit;
} else {
    print "{$rec} Record(s) updated successfully\n";
コード例 #19
0
$sql = "Select personnel.officer_name As officer_name,\r\n\t  personnel.off_desg As designation,\r\n\t  personnel.personcd As personcd,\r\n\t  Date_Format(personnel.dateofbirth, _latin1'%d/%m/%Y') As dateofbirth,\r\n\t  personnel.gender As gender,\r\n\t  personnel.scale As scale,\r\n\t  personnel.basic_pay As basic_pay,\r\n\t  personnel.grade_pay As grade_pay,\r\n\t  qualification.qualification As qualification,\r\n\t  personnel.email As email,\r\n\t  personnel.resi_no As resi_no,\r\n\t  personnel.mob_no As mob_no,\r\n\t  language.language As language,\r\n\t  personnel.present_addr1 As present_addr1,\r\n\t  personnel.present_addr2 As present_addr2,\r\n\t  personnel.perm_addr1 As perm_addr1,\r\n\t  personnel.perm_addr2 As perm_addr2,\r\n\t  personnel.acno As acno,\r\n\t  personnel.epic As epic,                         \r\n\t  personnel.partno As partno,\r\n\t  personnel.slno As slno,\r\n\t  poststat.poststatus As poststatus,\r\n\t  personnel.bank_acc_no As bank_acc_no,\r\n\t  personnel.assembly_temp As assembly_temp,\r\n\t  personnel.assembly_perm As assembly_perm,\r\n\t  personnel.assembly_off As assembly_off,\r\n\t  personnel.bank_cd As bank_cd,\r\n\t  bank.bank_name As bank_name,\r\n\t  branch.ifsc_code As ifsc_code,\r\n\t  branch.branch_name As branch_name,\r\n\t  branch.address As address,\r\n\t  personnel.remarks As remarks,\r\n\t  personnel.officecd As officecd,\r\n\t  office.office As office,\r\n\t  office.address1 As address1,\r\n\t  office.address2 As address2,\r\n\t  office.postoffice As postoffice,\r\n\t  district.district As district,\r\n\t  office.pin As pin,\r\n\t  personnel.usercode As usercode,\r\n\t  personnel.posted_date As posted_date\r\n\tFrom ((((((personnel\r\n\t  Left Join bank On bank.bank_cd = personnel.bank_cd)\r\n\t  Join qualification On qualification.qualificationcd =\r\n\t\tpersonnel.qualificationcd)\r\n\t  Join language On language.languagecd = personnel.languagecd)\r\n\t  Join poststat On poststat.post_stat = personnel.poststat)\r\n\t  Left Join branch On branch.branchcd = personnel.branchcd)\r\n\t  Join office On personnel.officecd = office.officecd)\r\n\t  Join district On office.districtcd = district.districtcd";
$sql .= " where personnel.personcd>0 ";
if ($frmdate != '' && $frmdate != null) {
    $sql .= "and personnel.posted_date>='{$frmdate}' ";
}
if ($todate != '' && $todate != null) {
    $sql .= "and personnel.posted_date<='{$todate}' ";
}
//if($user!='' && $user!=null)
//	$sql.="and personnel.usercode='$user' ";
if ($officename != '' && $officename != null) {
    $sql .= "and personnel.officecd='{$officename}' ";
}
$sql .= "order by personnel.officer_name ASC";
$rs = execSelect($sql);
$num_rows = rowCount($rs);
if ($num_rows > 0) {
    echo "<hr width='100%' />\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $row = getRows($rs);
        //<span>&nbsp;&nbsp;&nbsp;</span>
        echo "<div width='100%'>\n";
        echo $i . "<div style='padding-left:10px;'><span align='left'><b>Name, Designation (code) :</b></span><span align='left' ";
        echo "style='margin-right: " . (350 - strlen($row[0] . ', ' . $row[1] . ', (' . $row[2] . ')') * 5) . "pt;'";
        echo "> {$row['0']}, {$row['1']}, ({$row['2']})</span><span class='sp1'>&nbsp;</span><span align='left'><b>Date of Birth :</b></span><span align='left'> {$row['3']}</span><span class='sp1'>&nbsp;</span><span align='left'><b>Gender :</b></span><span align='left'> {$row['4']}</span></div>\n";
        echo "<div  style='padding-left:10px;'><span align='left'><b>Pay Scale :</b></span><span align='left' ";
        echo "style='margin-right: " . (80 - strlen($row[5]) * 5) . "pt;'";
        echo ">&nbsp;{$row['5']}</span><span class='sp1'>&nbsp;</span><span align='left'><b>Basic Pay :</b></span><span align='left' ";
        echo "style='margin-right: " . (80 - strlen($row[6]) * 5) . "pt;'";
        echo ">&nbsp;{$row['6']}</span><span class='sp1'>&nbsp;</span><span align='left' width='10%'><b>Grade Pay :</b></span><span align='left' ";
        echo "style='margin-right: " . (80 - strlen($row[7]) * 5) . "pt;'";
コード例 #20
0
                            <tr><td align="center"><?php 
                echo $rowPostStat['post_stat'];
                ?>
</td>
                            <?php 
                include_once '../function/report_fun.php';
                $c_g = 0;
                $s_g = 0;
                $c_g_u = 0;
                $s_g_u = 0;
                $l_b = 0;
                $g_a_f = 0;
                $a_b = 0;
                $o_g = 0;
                $rsNo = govt_cat_ag_post_stat_report($post_stat, $sub_div);
                $num_rows = rowCount($rsNo);
                if ($num_rows > 0) {
                    for ($j = 1; $j <= $num_rows; $j++) {
                        $rowNo = getRows($rsNo);
                        if ($rowNo['govt_description'] == 'Central Government') {
                            $c_g = $rowNo['total'];
                        }
                        if ($rowNo['govt_description'] == 'State Government') {
                            $s_g = $rowNo['total'];
                        }
                        if ($rowNo['govt_description'] == 'Central Government Undertaking') {
                            $c_g_u = $rowNo['total'];
                        }
                        if ($rowNo['govt_description'] == 'State Government Undertaking') {
                            $s_g_u = $rowNo['total'];
                        }
コード例 #21
0
      <td align="left"><span class="error">*</span>Assembly Name</td>
      <td align="left"><input type="text" name="assemblyname" id="assemblyname" style="width:250px;" /></td>
      <td align="left"></td>
    </tr><input type="hidden" id="hid_assembly_code" name="hid_assembly_code" />
    
	<tr>
	  <td align="left" colspan="4">&nbsp;</td></tr>
    <tr>
      <td colspan="4" align="center"><input type="submit" name="submit" id="submit" value="Save" class="button" onclick="javascript:return validate();" /></td>
    </tr>
    <tr><td colspan="4" align="left"><div id="form1_errorloc" class="error"></div></td></tr>
    <tr><td colspan="4" align="center"><div class="scroller">
            <?php 
//include_once('function\training_fun.php');
$rsAssDiv = fatch_assembly_masterlist($dist_cd);
$num_rows = rowCount($rsAssDiv);
if ($num_rows > 0) {
    echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
    echo "<tr height='30px'><th>Sl. No.</th><th align='center'>Assembly Code</th><th align='left'>Assembly Name</th><th align='left'>Parliament Name</th><th>Edit</th><th>Delete</th></tr>\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowAssDiv = getRows($rsAssDiv);
        $assembly_code = '"' . encode($rowAssDiv['assemblycd']) . '"';
        //$sub_code='"'.encode($rowAssDiv['subdivisioncd']).'"';
        echo "<tr><td align='right' width='10%'>{$i}.</td><td align='center' width='20%'>{$rowAssDiv['assemblycd']}</td><td width='35%' align='left'>{$rowAssDiv['assemblyname']}</td>";
        echo "<td width='35%' align='left'>{$rowAssDiv['pcname']}</td>";
        echo "<td align='center' width='10%'><img src='images/edit.png' alt='' height='20px' onclick='javascript:edit_assembly({$assembly_code});' /></td>\n";
        echo "<td align='center' width='10%'><img src='images/delete.png' alt='' height='20px' onclick='javascript:delete_assembly({$assembly_code});' /></td></tr>\n";
    }
    echo "</table>\n";
} else {
    echo "<div id='table1' style='border: 1px solid;'>No records found</div>";
コード例 #22
0
include_once '../inc/db_trans.inc.php';
include_once '../function/training2_fun.php';
//include_once('../inc/commit_con.php');
extract($_GET);
$from = isset($_POST['txtfrom']) ? $_POST['txtfrom'] : '0';
$to = isset($_POST['txtto']) ? $_POST['txtto'] : '0';
//$hid_rec=(isset($_POST['hid_rec'])?$_POST['hid_rec']:'0');
$env = isset($_SESSION['environment']) ? $_SESSION['environment'] : "";
$distnm_cap = isset($_SESSION['distnm_cap']) ? $_SESSION['distnm_cap'] : "";
if ($from > $to || $from < 1 || $to < 1) {
    echo "Please check record no";
    exit;
}
$mem_no = 4;
$rsApp = second_appointment_letter2_print($from - 1, $to - $from + 1, $mem_no);
$num_rows = rowCount($rsApp);
if ($num_rows > 0) {
    for ($i = 0; $i < $num_rows; $i++) {
        $rowApp = getRows($rsApp);
        $pers_off = $rowApp['pers_off'];
        $per_poststat = $rowApp['per_poststat'];
        $grp_id = $rowApp['groupid'];
        $for_ass = $rowApp['assembly'] . "-" . $rowApp['assembly_name'];
        $for_pc = $rowApp['pccd'] . "-" . $rowApp['pcname'];
        //$polling_station=$rec_arr_hdr['psno'].", ".$rec_arr_hdr['psname'];
        $dc = $rowApp['dc_venue'] != '' ? $rowApp['dc_venue'] . ", " . $rowApp['dc_address'] : "___________________________________";
        $dc_date = $rowApp['dc_date'] != '' ? $rowApp['dc_date'] : "___________";
        $dc_time = $rowApp['dc_time'] != '' ? $rowApp['dc_time'] : "___________";
        $rcvenue = $rowApp['rc_venue'] != '' ? $rowApp['rc_venue'] : "_______________________________";
        $pr_name = $rowApp['pr_name'];
        $pr_desig = $rowApp['pr_designation'];
コード例 #23
0
 for ($i = 1; $i <= $num_rows; $i++) {
     $rowId = getRows($rsId);
     $rsApp = first_appointment_letter_hdr($rowId['per_code']);
     if (rowCount($rsApp) == 0) {
         echo "Appointment Letter not available. </td></tr></table></div></body></html>";
         exit;
     }
     $rowApp = getRows($rsApp);
     $token_no = substr($rowApp['pp_subdivision'], 0, 4) . "/" . $rowApp['post_stat'] . "/" . $rowApp['token'];
     echo "<table width='750'>\r\n  <tr>\r\n    <td align='left'><div style='border:1px solid; width:150px;text-align:center;'>ELECTION URGENT</div></td>\r\n\t<td align='right'><div style='border:0px solid; width:250px;text-align:center;'>Token No. {$token_no}</div></td>\r\n  </tr>\r\n</table>\r\n<p align='center'><strong><u>ORDER OF APPOINTMENT FOR TRAINING</u></strong><br />\r\n<u>{$env}</u></p>\r\n<table cellspacing='0' cellpadding='0' width='750'>\r\n  <tr>\r\n    <td width='70%' align='left'>Order No: {$_SESSION['apt1_orderno']}</td>\r\n    <td width='20%' align='right'>Date:&nbsp;</td>\r\n\t<td width='10%' align='left'>&nbsp;{$_SESSION['apt1_date']}</td>\r\n  </tr>\r\n</table>\r\n<table cellspacing='0' cellpadding='0' width='750'>\r\n\t<tr><td>\r\n<p>&nbsp;&nbsp; In exercise of the power conferred upon vide Section 26 of the R. P. Act, 1951, I do hereby appoint the officer specified below as {$rowApp['poststatus']} for undergoing training in connection with the conduct of General Election to House of People, 2014 from {$rowApp['forpc']}-{$rowApp['pcname']} .</p>";
     //from $rowApp[forpc]-$rowApp[pcname] PC
     echo "</td></tr>\r\n</table>\r\n<div align='center'>\r\n  <table width='600px' border='1' cellspacing='0' cellpadding='0'>\r\n    <tr>\r\n      <td align='center'><strong>Name of Polling Officer</strong></td>\r\n    </tr>\r\n    <tr>\r\n      <td align='left'>{$rowApp['officer_name']}, {$rowApp['person_desig']}&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>PIN-{$rowApp['personcd']}</b>\r\n      <br />{$rowApp['office']}, {$rowApp['address1']}, {$rowApp['address2']}, P.O.-{$rowApp['postoffice']}, Subdiv-{$rowApp['subdivision']}, P.S.-{$rowApp['policestation']}, Dist.-{$rowApp['district']}, PIN-{$rowApp['pin']}\r\n      <br /><br /><br />({$rowApp['officecd']})&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;<b>{$rowApp['poststatus']}</b>\r\n      </td>\r\n    </tr>\r\n  </table>\r\n</div>\r\n<div align='center'><table width='600px'><tr><td align='left'>The Officer should report for Training as per following Schedule.</td></tr></table></div>\r\n<div align='center'><br />\r\n  <table width='730px' border='1' cellspacing='0' cellpadding='0'>\r\n    <tr>\r\n      <td colspan='5' align='center'><strong>Training Schedule</strong></td>\r\n    </tr>\r\n    <tr>\r\n      <td width='20%'><strong>Training</strong></td>\r\n      <td width='25%'><strong>Venue</strong></td>\r\n      <td width='27%'><strong>Address</strong></td>\r\n      <td width='12%'><strong>Date</strong></td>\r\n      <td width='15%'><strong>Time</strong></td>\r\n    </tr>";
     $office_address = $rowApp['address1'] . ", " . $rowApp['address2'];
     $rsAppDtl = first_appointment_letter($rowApp['personcd']);
     if (rowCount($rsAppDtl) > 0) {
         for ($j = 1; $j <= rowCount($rsAppDtl); $j++) {
             $rowAppDtl = getRows($rsAppDtl);
             echo "<tr>\r\n\t\t\t  <td height='70'>{$rowAppDtl['training_desc']}</td>\r\n\t\t\t  <td>{$rowAppDtl['venuename']}</td>\r\n\t\t\t  <td>{$rowAppDtl['venueaddress1']}, {$rowAppDtl['venueaddress2']}</td>\r\n\t\t\t  <td>{$rowAppDtl['training_dt']}</td>\r\n\t\t\t  <td>{$rowAppDtl['training_time']}</td>\r\n\t\t\t</tr>";
             $training_desc = $rowAppDtl['training_desc'];
             $venuename = $rowAppDtl['venuename'];
             $venue_add = $rowAppDtl['venueaddress1'] . ", " . $rowAppDtl['venueaddress2'];
             $training_dt = $rowAppDtl['training_dt'];
             $training_time = $rowAppDtl['training_time'];
             mysqli_stmt_bind_param($stmt, 'ssssssssssssssssssssssssssssss', $rowApp['officer_name'], $rowApp['person_desig'], $rowApp['personcd'], $rowApp['officer_desig'], $office_address, $rowApp['postoffice'], $rowApp['subdivision'], $rowApp['policestation'], $rowApp['district'], $rowApp['pin'], $rowApp['officecd'], $rowApp['poststatus'], $rowApp['mob_no'], $training_desc, $venuename, $venue_add, $training_dt, $training_time, $rowApp['forpc'], $rowApp['pcname'], $rowApp['forsubdivision'], $rowApp['epic'], $rowApp['acno'], $rowApp['partno'], $rowApp['slno'], $rowApp['bank_name'], $rowApp['branch_name'], $rowApp['bank_acc_no'], $rowApp['ifsc_code'], $token_no);
             mysqli_stmt_execute($stmt);
             $rowAppDtl = NULL;
         }
         unset($rsAppDtl);
     } else {
         $training_desc = '';
         $venuename = '';
コード例 #24
0
    if ($num_rows > 0) {
        echo "<option value='0'>-Select Office-</option>\n";
        for ($i = 1; $i <= $num_rows; $i++) {
            $rowOfc = getRows($rsOfc);
            echo "<option value='{$rowOfc['0']}'>{$rowOfc['1']}</option>\n";
            $rowOfc = NULL;
        }
    }
    unset($rsOfc, $num_rows, $rowOfc);
    echo "</select>";
}
if ($opn == 'personnel') {
    $office = isset($_GET['office']) ? $_GET['office'] : "";
    echo "<select id='personnel' name='personnel' style='width:240px;' onchange='return personnel_change(this.value);'>\n";
    $rsPer = fatch_personnel_ag_office($office);
    $num_rows = rowCount($rsPer);
    if ($num_rows > 0) {
        echo "<option value='0'>-Select Personnel-</option>\n";
        for ($i = 1; $i <= $num_rows; $i++) {
            $rowPer = getRows($rsPer);
            echo "<option value='{$rowPer['0']}'>{$rowPer['0']}</option>\n";
            $rowPer = NULL;
        }
    }
    unset($rsPer, $num_rows, $rowPer);
    echo "</select>";
}
if ($opn == 'per_dtl') {
    $personcd = isset($_GET['personcd']) ? $_GET['personcd'] : "";
    $epic = isset($_GET['epic']) ? $_GET['epic'] : "";
    if ($personcd != '' && $personcd != null) {
コード例 #25
0
      <td align="left"><select name="block_muni_type" id="block_muni_type">
      						<option value="b">Block</option>
                            <option value="m">Municipality</option>
                       </select></td><input type="hidden" id="hid_block_muni_code" name="hid_block_muni_code" />
    </tr>  
	<tr>
	  <td align="left" colspan="4">&nbsp;</td></tr>
    <tr>
      <td colspan="4" align="center"><input type="submit" name="submit" id="submit" value="Save" class="button" onclick="javascript:return validate();" /></td>
    </tr>
    <tr><td colspan="4" align="left"><div id="form1_errorloc" class="error"></div></td></tr>
    <tr><td colspan="4" align="center"><div class="scroller">
            <?php 
//include_once('function/training_fun.php');
$rsBlock = fatch_block_muni_master('', $dist_cd);
$num_rows = rowCount($rsBlock);
if ($num_rows > 0) {
    echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
    echo "<tr height='30px'><th align='center'>Sl. No</th><th align='center'>Block/Municipality Code</th><th align='left'>Block/Municipality Name</th><th align='left'>Subdivision</th><th>Edit</th><th>Delete</th></tr>\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowBlock = getRows($rsBlock);
        $blockminicd = '"' . encode($rowBlock['blockminicd']) . '"';
        echo "<tr><td width='5%' align='right'>{$i}.</td><td align='center' width='20%'>{$rowBlock['blockminicd']}</td><td width='30%' align='left'>{$rowBlock['blockmuni']}</td>";
        echo "<td width='30%' align='left'>{$rowBlock['subdivision']}</td>";
        echo "<td align='center' width='10%'><img src='images/edit.png' alt='' height='20px' onclick='javascript:edit_block({$blockminicd});' /></td>\n";
        echo "<td align='center' width='10%'><img src='images/delete.png' alt='' height='20px' onclick='javascript:delete_block({$blockminicd});' /></td></tr>\n";
    }
    echo "</table>\n";
} else {
    echo "<div id='table1' style='border: 1px solid;'>No records found</div>";
}
コード例 #26
0
stm_aix("p1i10","p1i1",[0,"Close"]);
stm_ep();*/
stm_aix("p0i5","p0i0",[0,"Signout","","",-1,-1,0,"signout.php","_self"],80,25);
stm_ep();
stm_em();
</script>

&nbsp;<span class="form">Hi, <?php 
print $_SESSION['user'];
?>
</span>
<?php 
$user_cat = isset($_SESSION['user_cat']) ? $_SESSION['user_cat'] : '';
$sql_env = "select * from environment where dist_cd='{$dist_cd}'";
$rs_env = execSelect($sql_env);
if (rowCount($rs_env) > 0) {
    $row_env = getRows($rs_env);
    $environment = uppercase($row_env['environment']);
    $_SESSION['environment'] = $environment;
    $distnm_cap = $row_env['distnm_cap'];
    $_SESSION['distnm_cap'] = $distnm_cap;
    $apt1_orderno = $row_env['apt1_orderno'];
    $_SESSION['apt1_orderno'] = $apt1_orderno;
    $apt1_date = new DateTime($row_env['apt1_date']);
    $_SESSION['apt1_date'] = $apt1_date->format('d/m/Y');
    $apt2_orderno = $row_env['apt2_orderno'];
    $_SESSION['apt2_orderno'] = $apt2_orderno;
    $apt2_date = new DateTime($row_env['apt2_date']);
    $_SESSION['apt2_date'] = $apt2_date->format('d/m/Y');
    $signature = $row_env['signature'];
    $_SESSION['signature'] = $signature;
コード例 #27
0
function fatch_Random_personnel_for_replacement_r($for_subdiv, $forpc, $assembly, $posting_status, $groupid, $gender)
{
    $sqltmp = "select officecd from personnela where groupid='{$groupid}' and personnela.forsubdivision='{$for_subdiv}' and personnela.forassembly='{$assembly}' and booked='P'";
    $rs_tmp = execSelect($sqltmp);
    $num_rows_tmp = rowCount($rs_tmp);
    for ($i = 0; $i < $num_rows_tmp; $i++) {
        $row_tmp = getRows($rs_tmp);
        $office[$i] = $row_tmp['officecd'];
    }
    $row_tmp = NULL;
    $rs_tmp = NULL;
    $sqlc = "select count(*) as cnt\r\n\tFrom personnela Inner Join office On personnela.officecd = office.officecd \r\n  \tInner Join policestation On office.policestn_cd = policestation.policestationcd\r\n  \tInner Join subdivision On office.subdivisioncd = subdivision.subdivisioncd\r\n  \tInner Join poststat On personnela.poststat = poststat.post_stat\r\n  \tInner Join assembly As ass_pre On personnela.assembly_temp = ass_pre.assemblycd\r\n  \tInner Join assembly ass_per On personnela.assembly_perm = ass_per.assemblycd \r\n  \tInner Join assembly ass_ofc On personnela.assembly_off = ass_ofc.assemblycd\r\n  \tInner Join district On district.districtcd = subdivision.districtcd \r\n\tLeft Join termination On personnela.personcd = termination.personal_id";
    $sqlc .= " WHERE termination.personal_id is null and personnela.gender='{$gender}' and personnela.assembly_temp<>'{$assembly}' and personnela.assembly_perm<>'{$assembly}' and personnela.assembly_off<>'{$assembly}' and personnela.poststat='{$posting_status}' ";
    $sqlc .= " and (personnela.booked='R' or personnela.booked='' or personnela.booked is null) and personnela.forpc='{$forpc}' and personnela.forassembly='{$assembly}'";
    for ($i = 0; $i < $num_rows_tmp; $i++) {
        $sqlc .= " and personnela.officecd<>'{$office[$i]}'";
    }
    $rsc = execSelect($sqlc);
    $rowc = getRows($rsc);
    $limit = $rowc['cnt'];
    //echo $limit; exit;
    $random_no = rand(0, $limit - 1);
    $sql = "Select personnela.personcd,personnela.officecd,personnela.officer_name,personnela.off_desg,office.address1,\r\n  \toffice.address2,office.postoffice,policestation.policestation,subdivision.subdivision,district.district,\r\n  office.pin,DATE_FORMAT(personnela.dateofbirth,'%d-%m-%Y') as dateofbirth,personnela.gender,personnela.epic,\r\n  \tpoststat.poststatus,personnela.present_addr1,personnela.present_addr2,ass_pre.assemblyname As pre_ass,\r\n  \tass_per.assemblyname As per_ass,ass_ofc.assemblyname As post_ass\r\n\tFrom personnela Inner Join office On personnela.officecd = office.officecd\r\n  \tInner Join policestation On office.policestn_cd = policestation.policestationcd \r\n  \tInner Join subdivision On office.subdivisioncd = subdivision.subdivisioncd\r\n  \tInner Join poststat On personnela.poststat = poststat.post_stat\r\n  \tInner Join assembly As ass_pre On personnela.assembly_temp = ass_pre.assemblycd \r\n  \tInner Join assembly ass_per On personnela.assembly_perm = ass_per.assemblycd\r\n  \tInner Join assembly ass_ofc On personnela.assembly_off = ass_ofc.assemblycd\r\n  \tInner Join district On district.districtcd = subdivision.districtcd\r\n\tLeft Join termination On personnela.personcd = termination.personal_id ";
    $sql .= " WHERE termination.personal_id is null and personnela.gender='{$gender}' and personnela.assembly_temp<>'{$assembly}' and personnela.assembly_perm<>'{$assembly}' and personnela.assembly_off<>'{$assembly}' and personnela.poststat='{$posting_status}' ";
    $sql .= " and (personnela.booked='R' or personnela.booked='' or personnela.booked is null) and personnela.forpc='{$forpc}' and personnela.forassembly='{$assembly}'";
    for ($i = 0; $i < $num_rows_tmp; $i++) {
        $sql .= " and personnela.officecd<>'{$office[$i]}'";
    }
    $sql .= " limit 1 offset {$random_no}";
    $rs = execSelect($sql);
    connection_close();
    return $rs;
}
コード例 #28
0
// number of items per page.
$all = isset($_GET['a']) ? $_GET['a'] : "";
if ($all == "all") {
    $items = $num_rows_T;
}
$nrpage_amount = $num_rows_T / $items;
$page_amount = ceil($num_rows_T / $items);
$page_amount = $page_amount - 1;
$page = isset($_GET['p']) ? $_GET['p'] : "";
$section = 'training_venue2_list';
if ($page < "1") {
    $page = "0";
}
$p_num = $items * $page;
$rstrainingvenue_list = fatch_trainingvenue_listAct($subdivision, $venuename, $usercode, $p_num, $items, $dist);
$num_rows = rowCount($rstrainingvenue_list);
if ($num_rows < 1) {
    echo "no record found";
    //echo $officeid.",".$officename.",".$frmdt.",".$todt.",".$usercode;
} else {
    echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
    echo "<tr height='30px'><th>Sl.</th><th>Sub Division</th>\r\n            <th>Venue Name</th>\r\n            <th>Venue Address</th>\r\n\t\t\t<th>Edit</th>\r\n            <th>Delete</th></tr>\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowtrainingvenue_list = getRows($rstrainingvenue_list);
        $venue_cd = '"' . encode($rowtrainingvenue_list[0]) . '"';
        echo "<tr><td align='right' width='3%'>{$i}.</td><td align='left' width='15%'>{$rowtrainingvenue_list['subdivision']}</td><td width='24%' align='left'>{$rowtrainingvenue_list['venuename']}</td>";
        echo "<td width='44%' align='left'>{$rowtrainingvenue_list['venueaddress1']},{$rowtrainingvenue_list['venueaddress2']}</td>";
        echo "<td align='center' width='4%'><img src='images/edit.png' alt='' height='20px' ";
        if ($rowtrainingvenue_list['usercode'] == $usercode) {
            echo "onclick='javascript:edit_trainingvenue({$venue_cd});'";
        } else {
コード例 #29
0
          				<option value="P">Party</option>
                        <option value="R">Reserve</option>
                        </select></td>
        </tr>
        <tr>
          <td align="left"><span class="error">*</span>Sl. No. Range</td>
          <td align="left"><input type="text" name="start_sl" id="start_sl" style="width:50px" />&nbsp;&nbsp;
          To: <input type="text" name="end_sl" id="end_sl" style="width:50px;" /></td>
        </tr>
        <tr>
          <td align="left"><span class="error">*</span>Venue</td>
          <td align="left"><select name="venue" id="venue" style="width:180px;">
          					<option value="0">-Select Training Venue-</option>
                            <?php 
$rsTrainingVenue = fatch_training_venue2_ag_subdiv('');
$num_rows = rowCount($rsTrainingVenue);
if ($num_rows > 0) {
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowTrainingVenue = getRows($rsTrainingVenue);
        echo "<option value='{$rowTrainingVenue['0']}'>{$rowTrainingVenue['1']}</option>\n";
        $rowTrainingVenue = NULL;
    }
}
unset($rowTrainingVenue, $num_rows);
?>
      					</select>
          </td>
        </tr>
        <tr>
          <td align="left"><span class="error">*</span>Training Date</td>
          <td align="left"><input type="text" name="training_dt" id="training_dt" maxlength="10" style="width:180px;" /></td>
コード例 #30
0
$all = $_GET['a'];
if ($all == "all") {
    $items = $num_rows_dum;
}
$items = $items == 0 ? 1 : $items;
$nrpage_amount = $num_rows_dum / $items;
$page_amount = ceil($num_rows_dum / $items);
$page_amount = $page_amount - 1;
$page = $_GET['p'];
$section = 'list-office-details';
if ($page < "1") {
    $page = "0";
}
$p_num = $items * $page;
$rsOffice = fatch_OfficeList1($sub_div, $officeid, $officename, $frmdt, $todt, $usercode, $p_num, $items);
$num_rows = rowCount($rsOffice);
if ($num_rows < 1) {
    echo "No record found";
    //echo $officeid.",".$officename.",".$frmdt.",".$todt.",".$usercode;
} else {
    echo "<table width='100%' cellpadding='0' cellspacing='0' border='0' id='table1'>\n";
    echo "<tr height='30px'><th>Sl.</th><th>Office ID</th>\r\n            <th>Office Name</th>\r\n            <th>Office Address</th>\r\n            <th>Nature of Office</th>\r\n            <th>Edit</th>\r\n\t\t\t<th>Delete</th></tr>\n";
    for ($i = 1; $i <= $num_rows; $i++) {
        $rowOffice = getRows($rsOffice);
        $ofc_cd = '"' . encode($rowOffice[0]) . '"';
        echo "<tr><td align='right' width='3%'>{$i}.</td><td align='center' width='8%'>{$rowOffice['0']}</td><td width='28%' align='left'>{$rowOffice['1']}</td>";
        echo "<td width='38%' align='left'>{$rowOffice['2']},{$rowOffice['3']}, PO-{$rowOffice['4']}, Pin-{$rowOffice['5']}</td><td width='15%' align='left'>{$rowOffice['6']}</td>";
        echo "<td align='center' width='4%'><img src='images/edit.png' alt='' height='20px' ";
        if ($rowOffice['usercode'] == $usercode) {
            echo " onclick='javascript:edit_office({$ofc_cd});' title='Click to edit' ";
        } else {