当前位置: 首页>>代码示例>>PHP>>正文


PHP DisplayLookupWizard函数代码示例

本文整理汇总了PHP中DisplayLookupWizard函数的典型用法代码示例。如果您正苦于以下问题:PHP DisplayLookupWizard函数的具体用法?PHP DisplayLookupWizard怎么用?PHP DisplayLookupWizard使用的例子?那么恭喜您, 这里精选的函数代码示例或许可以为您提供帮助。


在下文中一共展示了DisplayLookupWizard函数的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。

示例1: WriteTableData

function WriteTableData()
{
    global $rs, $nPageSize, $strTableName, $conn, $eventObj;
    if ($eventObj->exists("ListFetchArray")) {
        $row = $eventObj->ListFetchArray($rs);
    } else {
        $row = db_fetch_array($rs);
    }
    //	if(!$row)
    //		return;
    // write header
    echo "<tr>";
    if ($_REQUEST["type"] == "excel") {
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "ID")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "Module_ID")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "Anomaly_Description")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "Anomaly_Type")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "Date_Time")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Anomalies", "Action_Taken")) . '</td>';
    } else {
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "ID") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "Module_ID") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "Anomaly_Description") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "Anomaly_Type") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "Date_Time") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Anomalies", "Action_Taken") . "</td>";
    }
    echo "</tr>";
    $totals["ID"] = 0;
    $totalsFields[] = array('fName' => "ID", 'totalsType' => '', 'viewFormat' => "");
    $totals["Module ID"] = 0;
    $totalsFields[] = array('fName' => "Module ID", 'totalsType' => '', 'viewFormat' => "");
    $totals["Anomaly Description"] = 0;
    $totalsFields[] = array('fName' => "Anomaly Description", 'totalsType' => '', 'viewFormat' => "");
    $totals["Anomaly Type"] = 0;
    $totalsFields[] = array('fName' => "Anomaly Type", 'totalsType' => '', 'viewFormat' => "");
    $totals["Date Time"] = 0;
    $totalsFields[] = array('fName' => "Date Time", 'totalsType' => '', 'viewFormat' => "Short Date");
    $totals["Action Taken"] = 0;
    $totalsFields[] = array('fName' => "Action Taken", 'totalsType' => '', 'viewFormat' => "");
    $totals = array();
    // write data rows
    $iNumberOfRows = 0;
    while ((!$nPageSize || $iNumberOfRows < $nPageSize) && $row) {
        countTotals($totals, $totalsFields, $row);
        $values = array();
        $format = "";
        $values["ID"] = GetData($row, "ID", $format);
        $values["Module ID"] = "";
        if (strlen($row["Module ID"])) {
            $values["Module ID"] = DisplayLookupWizard("Module ID", $row["Module ID"], $row, "", MODE_EXPORT);
        }
        $format = "";
        $values["Anomaly Description"] = GetData($row, "Anomaly Description", $format);
        $values["Anomaly Type"] = "";
        if (strlen($row["Anomaly Type"])) {
            $values["Anomaly Type"] = DisplayLookupWizard("Anomaly Type", $row["Anomaly Type"], $row, "", MODE_EXPORT);
        }
        $format = "Short Date";
        $values["Date Time"] = GetData($row, "Date Time", $format);
        $values["Action Taken"] = "";
        if (strlen($row["Action Taken"])) {
            $values["Action Taken"] = DisplayLookupWizard("Action Taken", $row["Action Taken"], $row, "", MODE_EXPORT);
        }
        $eventRes = true;
        if ($eventObj->exists('BeforeOut')) {
            $eventRes = $eventObj->BeforeOut($row, $values);
        }
        if ($eventRes) {
            $iNumberOfRows++;
            echo "<tr>";
            echo '<td>';
            $format = "";
            echo htmlspecialchars($values["ID"]);
            echo '</td>';
            echo '<td>';
            if ($_REQUEST["type"] == "excel") {
                echo PrepareForExcel($values["Module ID"]);
            } else {
                echo htmlspecialchars($values["Module ID"]);
            }
            echo '</td>';
            if ($_REQUEST["type"] == "excel") {
                echo '<td x:str>';
            } else {
                echo '<td>';
            }
            $format = "";
            if ($_REQUEST["type"] == "excel") {
                echo PrepareForExcel($values["Anomaly Description"]);
            } else {
                echo htmlspecialchars($values["Anomaly Description"]);
            }
            echo '</td>';
            echo '<td>';
            if ($_REQUEST["type"] == "excel") {
                echo PrepareForExcel($values["Anomaly Type"]);
            } else {
                echo htmlspecialchars($values["Anomaly Type"]);
            }
//.........这里部分代码省略.........
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:101,代码来源:Anomalies_export.php

示例2: DisplayMasterTableInfo_Module

function DisplayMasterTableInfo_Module($params)
{
    $detailtable = $params["detailtable"];
    $keys = $params["keys"];
    global $conn, $strTableName;
    $xt = new Xtempl();
    $oldTableName = $strTableName;
    $strTableName = "dbo.Module";
    //$strSQL = "SELECT ID,   [Module Type],   [Module Status],   [Module Condition],   [Serial Num],   [Entry Date]  FROM dbo.[Module]";
    $sqlHead = "SELECT ID,   [Module Type],   [Module Status],   [Module Condition],   [Serial Num],   [Entry Date]";
    $sqlFrom = "FROM dbo.[Module]";
    $sqlWhere = "";
    $sqlTail = "";
    $where = "";
    global $page_styles, $page_layouts, $page_layout_names, $container_styles;
    $layout = new TLayout("masterprint", "BoldOrange", "MobileOrange");
    $layout->blocks["bare"] = array();
    $layout->containers["0"] = array();
    $layout->containers["0"][] = array("name" => "masterprintheader", "block" => "", "substyle" => 1);
    $layout->skins["0"] = "empty";
    $layout->blocks["bare"][] = "0";
    $layout->containers["mastergrid"] = array();
    $layout->containers["mastergrid"][] = array("name" => "masterprintfields", "block" => "", "substyle" => 1);
    $layout->skins["mastergrid"] = "grid";
    $layout->blocks["bare"][] = "mastergrid";
    $page_layouts["Module_masterprint"] = $layout;
    if ($detailtable == "dbo.Anomalies") {
        $where .= GetFullFieldName("ID") . "=" . make_db_value("ID", $keys[1 - 1]);
    }
    if ($detailtable == "dbo.Customer Module Assignment") {
        $where .= GetFullFieldName("ID") . "=" . make_db_value("ID", $keys[1 - 1]);
    }
    if ($detailtable == "dbo.Readings") {
        $where .= GetFullFieldName("ID") . "=" . make_db_value("ID", $keys[1 - 1]);
    }
    if (!$where) {
        $strTableName = $oldTableName;
        return;
    }
    $str = SecuritySQL("Export");
    if (strlen($str)) {
        $where .= " and " . $str;
    }
    $strWhere = whereAdd($sqlWhere, $where);
    if (strlen($strWhere)) {
        $strWhere = " where " . $strWhere . " ";
    }
    $strSQL = $sqlHead . ' ' . $sqlFrom . $strWhere . $sqlTail;
    //	$strSQL=AddWhere($strSQL,$where);
    LogInfo($strSQL);
    $rs = db_query($strSQL, $conn);
    $data = db_fetch_array($rs);
    if (!$data) {
        $strTableName = $oldTableName;
        return;
    }
    $keylink = "";
    $keylink .= "&key1=" . htmlspecialchars(rawurlencode(@$data["ID"]));
    //	ID -
    $value = "";
    $value = ProcessLargeText(GetData($data, "ID", ""), "field=ID" . $keylink, "", MODE_PRINT);
    $xt->assign("ID_mastervalue", $value);
    //	Module Type -
    $value = "";
    $value = DisplayLookupWizard("Module Type", $data["Module Type"], $data, $keylink, MODE_PRINT);
    $xt->assign("Module_Type_mastervalue", $value);
    //	Module Status -
    $value = "";
    $value = DisplayLookupWizard("Module Status", $data["Module Status"], $data, $keylink, MODE_PRINT);
    $xt->assign("Module_Status_mastervalue", $value);
    //	Module Condition -
    $value = "";
    $value = DisplayLookupWizard("Module Condition", $data["Module Condition"], $data, $keylink, MODE_PRINT);
    $xt->assign("Module_Condition_mastervalue", $value);
    //	Serial Num -
    $value = "";
    $value = ProcessLargeText(GetData($data, "Serial Num", ""), "field=Serial+Num" . $keylink, "", MODE_PRINT);
    $xt->assign("Serial_Num_mastervalue", $value);
    //	Entry Date - Short Date
    $value = "";
    $value = ProcessLargeText(GetData($data, "Entry Date", "Short Date"), "field=Entry+Date" . $keylink, "", MODE_PRINT);
    $xt->assign("Entry_Date_mastervalue", $value);
    $xt->display("Module_masterprint.htm");
    $strTableName = $oldTableName;
}
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:85,代码来源:Module_masterprint.php

示例3: DisplayLookupWizard

    if ($preload !== false) {
        $controls["controls"]['preloadData'] = $preload;
    }
    $pageObject->fillControlsMap($controls);
    //fill field tool tips
    $pageObject->fillFieldToolTips($fName);
    // fill special settings for timepicker
    if (GetEditFormat($fName) == 'Time') {
        $pageObject->fillTimePickSettings($fName, $data[$fName]);
    }
    if (ViewFormat($fName) == FORMAT_MAP) {
        $pageObject->googleMapCfg['isUseGoogleMap'] = true;
    }
    if ($detailKeys && in_array($fName, $detailKeys) && array_key_exists($fName, $data)) {
        if ((GetEditFormat($fName) == EDIT_FORMAT_LOOKUP_WIZARD || GetEditFormat($fName) == EDIT_FORMAT_RADIO) && GetpLookupType($fName) == LT_LOOKUPTABLE) {
            $value = DisplayLookupWizard($fName, $data[$fName], $data, "", MODE_VIEW);
        } elseif (NeedEncode($fName)) {
            $value = ProcessLargeText(GetData($data, $fName, ViewFormat($fName)), "field=" . rawurlencode(htmlspecialchars($fName)), "", MODE_VIEW);
        } else {
            $value = GetData($data, $fName, ViewFormat($fName));
        }
        $xt->assign($gfName . "_editcontrol", $value);
    }
}
//fill tab groups name and sections name to controls
$pageObject->fillCntrlTabGroups();
$pageObject->jsSettings['tableSettings'][$strTableName]["keys"] = $keys;
$pageObject->jsSettings['tableSettings'][$strTableName]["prevKeys"] = $prev;
$pageObject->jsSettings['tableSettings'][$strTableName]["nextKeys"] = $next;
if ($pageObject->lockingObj) {
    $pageObject->jsSettings['tableSettings'][$strTableName]["sKeys"] = $skeys;
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Customers_edit.php

示例4: ProcessLargeText

 //Record ID -
 $value = "";
 $value = ProcessLargeText(GetData($data, "Record ID", ""), "", "", MODE_VIEW);
 if ($mainTableOwnerID == "Record ID") {
     $ownerIdValue = $value;
 }
 $xt->assign("Record_ID_value", $value);
 if (!$pageObject->isAppearOnTabs("Record ID")) {
     $xt->assign("Record_ID_fieldblock", true);
 } else {
     $xt->assign("Record_ID_tabfieldblock", true);
 }
 ////////////////////////////////////////////
 //Module ID -
 $value = "";
 $value = DisplayLookupWizard("Module ID", $data["Module ID"], $data, $keylink, MODE_VIEW);
 if ($mainTableOwnerID == "Module ID") {
     $ownerIdValue = $value;
 }
 $xt->assign("Module_ID_value", $value);
 if (!$pageObject->isAppearOnTabs("Module ID")) {
     $xt->assign("Module_ID_fieldblock", true);
 } else {
     $xt->assign("Module_ID_tabfieldblock", true);
 }
 ////////////////////////////////////////////
 //Voltage Red -
 $value = "";
 $value = ProcessLargeText(GetData($data, "Voltage Red", ""), "", "", MODE_VIEW);
 if ($mainTableOwnerID == "Voltage Red") {
     $ownerIdValue = $value;
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Readings_view.php

示例5: array

        $vals = array($fName => @$defvalues[$fName]);
    }
    $preload = $pageObject->fillPreload($fName, $vals);
    if ($preload !== false) {
        $controls["controls"]['preloadData'] = $preload;
    }
    $pageObject->fillControlsMap($controls);
    //fill field tool tips
    $pageObject->fillFieldToolTips($fName);
    // fill special settings for timepicker
    if (GetEditFormat($fName) == 'Time') {
        $pageObject->fillTimePickSettings($fName, @$defvalues[$fName]);
    }
    if (($detailKeys && in_array($fName, $detailKeys) || $fName == postvalue("category")) && array_key_exists($fName, $defvalues)) {
        if ((GetEditFormat($fName) == EDIT_FORMAT_LOOKUP_WIZARD || GetEditFormat($fName) == EDIT_FORMAT_RADIO) && GetpLookupType($fName) == LT_LOOKUPTABLE) {
            $value = DisplayLookupWizard($fName, $defvalues[$fName], $defvalues, "", MODE_VIEW);
        } elseif (NeedEncode($fName)) {
            $value = ProcessLargeText(GetData($defvalues, $fName, ViewFormat($fName)), "field=" . rawurlencode(htmlspecialchars($fName)), "", MODE_VIEW);
        } else {
            $value = GetData($defvalues, $fName, ViewFormat($fName));
        }
        $xt->assign($gfName . "_editcontrol", $value);
    }
}
//fill tab groups name and sections name to controls
$pageObject->fillCntrlTabGroups();
/////////////////////////////////////////////////////////////
if ($pageObject->isShowDetailTables && ($inlineadd == ADD_SIMPLE || $inlineadd == ADD_POPUP) && !isMobile()) {
    if (count($dpParams['ids'])) {
        $xt->assign("detail_tables", true);
        include 'classes/listpage.php';
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Month_Billings_add.php

示例6: htmlspecialchars

 $keylink .= "&key1=" . htmlspecialchars(rawurlencode(@$data["UserID"]));
 //	UserID -
 $value = "";
 $value = ProcessLargeText(GetData($data, "UserID", ""), "field=UserID" . $keylink, "", MODE_PRINT);
 $record["UserID_value"] = $value;
 //	Password -
 $value = "";
 $value = ProcessLargeText(GetData($data, "Password", ""), "field=Password" . $keylink, "", MODE_PRINT);
 $record["Password_value"] = $value;
 //	User Name -
 $value = "";
 $value = ProcessLargeText(GetData($data, "User Name", ""), "field=User+Name" . $keylink, "", MODE_PRINT);
 $record["User_Name_value"] = $value;
 //	Role -
 $value = "";
 $value = DisplayLookupWizard("Role", $data["Role"], $data, $keylink, MODE_PRINT);
 $record["Role_value"] = $value;
 if ($col < $colsonpage) {
     $record["endrecord_block"] = true;
 }
 $record["grid_recordheader"] = true;
 $record["grid_vrecord"] = true;
 if ($eventObj->exists("BeforeMoveNextPrint")) {
     $eventObj->BeforeMoveNextPrint($data, $row, $record);
 }
 $row["grid_record"]["data"][] = $record;
 if ($eventObj->exists("ListFetchArray")) {
     $data = $eventObj->ListFetchArray($rs);
 } else {
     $data = db_fetch_array($rs);
 }
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:System_Users_print.php

示例7: DisplayMasterTableInfo_Customers

function DisplayMasterTableInfo_Customers($params)
{
    $detailtable = $params["detailtable"];
    $keys = $params["keys"];
    global $conn, $strTableName;
    $xt = new Xtempl();
    $oldTableName = $strTableName;
    $strTableName = "dbo.Customers";
    //$strSQL = "SELECT ID,   Name,   [Father Name],   Address,   Contact,   Location,   [Customer Type]  FROM dbo.Customers";
    $sqlHead = "SELECT ID,   Name,   [Father Name],   Address,   Contact,   Location,   [Customer Type]";
    $sqlFrom = "FROM dbo.Customers";
    $sqlWhere = "";
    $sqlTail = "";
    $where = "";
    $mKeys = array();
    $showKeys = "";
    global $page_styles, $page_layouts, $page_layout_names, $container_styles;
    $layout = new TLayout("masterlist", "BoldOrange", "MobileOrange");
    $layout->blocks["bare"] = array();
    $layout->containers["0"] = array();
    $layout->containers["0"][] = array("name" => "masterlistheader", "block" => "", "substyle" => 1);
    $layout->skins["0"] = "empty";
    $layout->blocks["bare"][] = "0";
    $layout->containers["mastergrid"] = array();
    $layout->containers["mastergrid"][] = array("name" => "masterlistfields", "block" => "", "substyle" => 1);
    $layout->skins["mastergrid"] = "grid";
    $layout->blocks["bare"][] = "mastergrid";
    $page_layouts["Customers_masterlist"] = $layout;
    if ($detailtable == "dbo.Customer Module Assignment") {
        $where .= GetFullFieldName("ID") . "=" . make_db_value("ID", $keys[1 - 1]);
        $showKeys .= " " . GetFieldLabel("dbo_Customers", "ID") . ": " . $keys[1 - 1];
        $xt->assign('showKeys', $showKeys);
    }
    if (!$where) {
        $strTableName = $oldTableName;
        return;
    }
    $str = SecuritySQL("Search");
    if (strlen($str)) {
        $where .= " and " . $str;
    }
    $strWhere = whereAdd($sqlWhere, $where);
    if (strlen($strWhere)) {
        $strWhere = " where " . $strWhere . " ";
    }
    $strSQL = $sqlHead . ' ' . $sqlFrom . $strWhere . $sqlTail;
    //	$strSQL=AddWhere($strSQL,$where);
    LogInfo($strSQL);
    $rs = db_query($strSQL, $conn);
    $data = db_fetch_array($rs);
    if (!$data) {
        $strTableName = $oldTableName;
        return;
    }
    $keylink = "";
    $keylink .= "&key1=" . htmlspecialchars(rawurlencode(@$data["ID"]));
    //	ID -
    $value = "";
    $value = ProcessLargeText(GetData($data, "ID", ""), "field=ID" . $keylink);
    $xt->assign("ID_mastervalue", $value);
    //	Name -
    $value = "";
    $value = ProcessLargeText(GetData($data, "Name", ""), "field=Name" . $keylink);
    $xt->assign("Name_mastervalue", $value);
    //	Father Name -
    $value = "";
    $value = ProcessLargeText(GetData($data, "Father Name", ""), "field=Father+Name" . $keylink);
    $xt->assign("Father_Name_mastervalue", $value);
    //	Address -
    $value = "";
    $value = ProcessLargeText(GetData($data, "Address", ""), "field=Address" . $keylink);
    $xt->assign("Address_mastervalue", $value);
    //	Contact -
    $value = "";
    $value = ProcessLargeText(GetData($data, "Contact", ""), "field=Contact" . $keylink);
    $xt->assign("Contact_mastervalue", $value);
    //	Location -
    $value = "";
    $value = DisplayLookupWizard("Location", $data["Location"], $data, $keylink, MODE_LIST);
    $xt->assign("Location_mastervalue", $value);
    //	Customer Type -
    $value = "";
    $value = DisplayLookupWizard("Customer Type", $data["Customer Type"], $data, $keylink, MODE_LIST);
    $xt->assign("Customer_Type_mastervalue", $value);
    $xt->display("Customers_masterlist.htm");
    $strTableName = $oldTableName;
}
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:87,代码来源:Customers_masterlist.php

示例8: ProcessLargeText

        $row["Father_Name_value"] = $value;
        //	Address -
        $value = "";
        $value = ProcessLargeText(GetData($data, "Address", ""), "field=Address" . $keylink, "", MODE_PRINT);
        $row["Address_value"] = $value;
        //	Contact -
        $value = "";
        $value = ProcessLargeText(GetData($data, "Contact", ""), "field=Contact" . $keylink, "", MODE_PRINT);
        $row["Contact_value"] = $value;
        //	Location -
        $value = "";
        $value = DisplayLookupWizard("Location", $data["Location"], $data, $keylink, MODE_PRINT);
        $row["Location_value"] = $value;
        //	Customer Type -
        $value = "";
        $value = DisplayLookupWizard("Customer Type", $data["Customer Type"], $data, $keylink, MODE_PRINT);
        $row["Customer_Type_value"] = $value;
        $rowinfo[] = $row;
    }
    $xt->assign_loopsection("details_row", $rowinfo);
} else {
}
$xt->display("Customers_detailspreview.htm");
if ($mode != "inline") {
    echo "counterSeparator" . postvalue("counter");
    $layout = GetPageLayout(GoodFieldName($strTableName), 'detailspreview');
    if ($layout) {
        $rtl = $xt->getReadingOrder() == 'RTL' ? 'RTL' : '';
        echo "counterSeparator" . "styles/" . $layout->style . "/style" . $rtl . "counterSeparator" . "pagestyles/" . $layout->name . $rtl . "counterSeparator" . $layout->style . " page-" . $layout->name;
    }
}
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Customers_detailspreview.php

示例9: htmlspecialchars

 $keylink .= "&key1=" . htmlspecialchars(rawurlencode(@$data["ID"]));
 //	ID -
 $value = "";
 $value = ProcessLargeText(GetData($data, "ID", ""), "field=ID" . $keylink, "", MODE_PRINT);
 $record["ID_value"] = $value;
 //	Module Type -
 $value = "";
 $value = DisplayLookupWizard("Module Type", $data["Module Type"], $data, $keylink, MODE_PRINT);
 $record["Module_Type_value"] = $value;
 //	Module Status -
 $value = "";
 $value = DisplayLookupWizard("Module Status", $data["Module Status"], $data, $keylink, MODE_PRINT);
 $record["Module_Status_value"] = $value;
 //	Module Condition -
 $value = "";
 $value = DisplayLookupWizard("Module Condition", $data["Module Condition"], $data, $keylink, MODE_PRINT);
 $record["Module_Condition_value"] = $value;
 //	Serial Num -
 $value = "";
 $value = ProcessLargeText(GetData($data, "Serial Num", ""), "field=Serial+Num" . $keylink, "", MODE_PRINT);
 $record["Serial_Num_value"] = $value;
 //	Entry Date - Short Date
 $value = "";
 $value = ProcessLargeText(GetData($data, "Entry Date", "Short Date"), "field=Entry+Date" . $keylink, "", MODE_PRINT);
 $record["Entry_Date_value"] = $value;
 if ($col < $colsonpage) {
     $record["endrecord_block"] = true;
 }
 $record["grid_recordheader"] = true;
 $record["grid_vrecord"] = true;
 if ($eventObj->exists("BeforeMoveNextPrint")) {
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Module_print.php

示例10: ProcessLargeText

 //Date Time - Short Date
 $value = "";
 $value = ProcessLargeText(GetData($data, "Date Time", "Short Date"), "", "", MODE_VIEW);
 if ($mainTableOwnerID == "Date Time") {
     $ownerIdValue = $value;
 }
 $xt->assign("Date_Time_value", $value);
 if (!$pageObject->isAppearOnTabs("Date Time")) {
     $xt->assign("Date_Time_fieldblock", true);
 } else {
     $xt->assign("Date_Time_tabfieldblock", true);
 }
 ////////////////////////////////////////////
 //Action Taken -
 $value = "";
 $value = DisplayLookupWizard("Action Taken", $data["Action Taken"], $data, $keylink, MODE_VIEW);
 if ($mainTableOwnerID == "Action Taken") {
     $ownerIdValue = $value;
 }
 $xt->assign("Action_Taken_value", $value);
 if (!$pageObject->isAppearOnTabs("Action Taken")) {
     $xt->assign("Action_Taken_fieldblock", true);
 } else {
     $xt->assign("Action_Taken_tabfieldblock", true);
 }
 /*$jsKeysObj = 'window.recKeysObj = {';
 	$jsKeysObj .= "'".jsreplace("ID")."': '".(jsreplace(@$data["ID"]))."', ";
 $jsKeysObj = substr($jsKeysObj, 0, strlen($jsKeysObj)-2);
 $jsKeysObj .= '};';
 $pageObject->AddJsCode($jsKeysObj);	
 */
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:31,代码来源:Anomalies_view.php

示例11: proccessRecordValue


//.........这里部分代码省略.........
                 }
                 if (strlen($data[$listFieldInfo['fName']])) {
                     $value = "<a href='getfile.php?table=" . $this->shortTableName . "&filename=" . rawurlencode($fileName) . "&field=" . rawurlencode($listFieldInfo['fName']) . $keylink . "'>";
                     $value .= htmlspecialchars($fileName);
                     $value .= "</a>";
                 }
             } else {
                 if ($listFieldInfo['viewFormat'] == FORMAT_AUDIO) {
                     $fileName = GetData($data, $listFieldInfo['fName'], FORMAT_NONE);
                     $fieldIsUrl = GetFieldData($this->tName, $listFieldInfo['fName'], "fieldIsVideoUrl", false);
                     if (strlen($fileName)) {
                         $absFileName = "";
                         if (!$fieldIsUrl && GetFieldData($this->tName, $listFieldInfo['fName'], "Absolute", false)) {
                             $absFileName = GetUploadFolder($listFieldInfo['fName']) . $fileName;
                         } elseif (!$fieldIsUrl) {
                             $absFileName = getabspath(GetUploadFolder($listFieldInfo['fName']) . $fileName);
                         }
                         // if file
                         if ($fieldIsUrl || file_exists($absFileName)) {
                             $titleField = GetFieldData($this->tName, $listFieldInfo['fName'], 'audioTitleField', "");
                             $title = "";
                             if ($titleField) {
                                 $title = htmlspecialchars(GetData($data, $titleField, ViewFormat($titleField, $titleField)));
                             }
                             if ($fieldIsUrl) {
                                 $href = $fileName;
                             } else {
                                 $href = 'download.php?table=' . $this->shortTableName . '&field=' . rawurlencode($listFieldInfo['fName']) . $keylink;
                             }
                             $value = '<a class="htrack" type="audio/mpeg" title="' . $title . '" href="' . $href . '">' . $title . '</a>';
                         }
                     }
                 } else {
                     if ($listFieldInfo['viewFormat'] == FORMAT_DATABASE_AUDIO) {
                         $titleField = GetFieldData($this->tName, $listFieldInfo['fName'], 'audioTitleField', "");
                         $title = "";
                         if ($titleField) {
                             $title = htmlspecialchars(GetData($data, $titleField, ViewFormat($titleField, $titleField)));
                         }
                         if (@$data[$listFieldInfo['fName']] != NULL) {
                             $value = '<a class="htrack" type="audio/mpeg" title="' . $title . '" href="getfile.php?table=' . $this->shortTableName . '&field=' . rawurlencode($listFieldInfo['fName']) . $keylink . '">' . $title . '</a>';
                         } else {
                             $value = $title;
                         }
                     } else {
                         if ($listFieldInfo['viewFormat'] == FORMAT_VIDEO) {
                             $value = "";
                             $fieldIsUrl = GetFieldData($this->tName, $listFieldInfo['fName'], "fieldIsVideoUrl", false);
                             $fileName = GetData($data, $listFieldInfo['fName'], FORMAT_NONE);
                             if (strlen($fileName)) {
                                 $absFileName = "";
                                 if (!$fieldIsUrl && GetFieldData($this->tName, $listFieldInfo['fName'], "Absolute", false)) {
                                     $absFileName = GetUploadFolder($listFieldInfo['fName']) . $fileName;
                                 } elseif (!$fieldIsUrl) {
                                     $absFileName = getabspath(GetUploadFolder($listFieldInfo['fName']) . $fileName);
                                 }
                                 // if file
                                 if ($fieldIsUrl || file_exists($absFileName)) {
                                     $videoId = 'video_' . GoodFieldName(htmlspecialchars($listFieldInfo['fName'])) . '_' . $this->recId;
                                     if ($fieldIsUrl) {
                                         $href = $fileName;
                                     } else {
                                         $href = 'download.php?table=' . $this->shortTableName . '&field=' . rawurlencode($listFieldInfo['fName']) . $keylink;
                                     }
                                     $value = '<a href="' . $href . '" style="display:block;width:' . GetFieldData($this->tName, $listFieldInfo['fName'], 'videoWidth', "") . 'px;height:' . GetFieldData($this->tName, $listFieldInfo['fName'], 'videoHeight', "") . 'px;" id="' . $videoId . '"></a>';
                                     $this->controlsMap['video'][] = $videoId;
                                 }
                             }
                         } else {
                             if ($listFieldInfo['viewFormat'] == FORMAT_DATABASE_VIDEO) {
                                 if (@$data[$listFieldInfo['fName']] != NULL) {
                                     $videoId = 'video_' . GoodFieldName(htmlspecialchars($listFieldInfo['fName'])) . '_' . $this->recId;
                                     $value = '<a href="getfile.php?table=' . $this->shortTableName . '&field=' . rawurlencode($listFieldInfo['fName']) . $keylink . '" style="display:block;width:' . GetFieldData($this->tName, $listFieldInfo['fName'], 'videoWidth', 0) . 'px;height:' . GetFieldData($this->tName, $listFieldInfo['fName'], 'videoHeight', 0) . 'px;" id="' . $videoId . '"></a>';
                                     $this->controlsMap['video'][] = $videoId;
                                 }
                             } else {
                                 if ($listFieldInfo['viewFormat'] == FORMAT_MAP) {
                                     $value = '<div id="littleMap_' . GoodFieldName($listFieldInfo['fName']) . '_' . $this->recId . '" style="width: ' . $this->googleMapCfg['fieldsAsMap'][$listFieldInfo['fName']]['width'] . 'px; height: ' . $this->googleMapCfg['fieldsAsMap'][$listFieldInfo['fName']]['height'] . 'px;"></div>';
                                 } else {
                                     if (($listFieldInfo['editFormat'] == EDIT_FORMAT_LOOKUP_WIZARD || $listFieldInfo['editFormat'] == EDIT_FORMAT_RADIO) && GetLookupType($listFieldInfo['fName'], $this->tName) == LT_LOOKUPTABLE && GetLWLinkField($listFieldInfo['fName'], $this->tName) != GetLWDisplayField($listFieldInfo['fName'], $this->tName)) {
                                         $value = DisplayLookupWizard($listFieldInfo['fName'], $data[$listFieldInfo['fName']], $data, $keylink, MODE_LIST);
                                     } else {
                                         if (NeedEncode($listFieldInfo['fName'], $this->tName)) {
                                             $value = ProcessLargeText(GetData($data, $listFieldInfo['fName'], $listFieldInfo['viewFormat']), "field=" . rawurlencode($listFieldInfo['fName']) . $keylink, "", MODE_LIST);
                                         } else {
                                             $value = GetData($data, $listFieldInfo['fName'], $listFieldInfo['viewFormat']);
                                         }
                                     }
                                 }
                             }
                         }
                     }
                 }
             }
         }
     }
     // create address field as center link
     $value = $this->addCenterLink($value, $listFieldInfo['fName']);
     return $value;
 }
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:101,代码来源:listpage.php

示例12: labelFormat

 function labelFormat($fieldName, $data)
 {
     $table = $this->sessionPrefix;
     $strViewFormat = GetFieldData($table, $fieldName, "ViewFormat", "");
     $strEditFormat = GetFieldData($table, $fieldName, "EditFormat", "");
     if (($strEditFormat == EDIT_FORMAT_LOOKUP_WIZARD || $strEditFormat == EDIT_FORMAT_RADIO) && GetLookupType($fieldName, $table) == LT_LOOKUPTABLE && GetLWLinkField($fieldName, $table) != GetLWDisplayField($fieldName, $table)) {
         $value = DisplayLookupWizard($fieldName, $data[$fieldName], $data, "", MODE_PRINT);
     } else {
         $value = GetData($data, $fieldName, $strViewFormat);
     }
     if (strlen($value) > 50) {
         $value = substr($value, 0, 47) . "...";
     }
     return $this->chart_xmlencode($value);
 }
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:15,代码来源:charts.php

示例13: getFormattedRow


//.........这里部分代码省略.........
                     if ($this->fieldsArr[$i]['imageWidth']) {
                         $val .= " width=" . $this->fieldsArr[$i]['imageWidth'];
                     }
                     if ($this->fieldsArr[$i]['imageHeight']) {
                         $val .= " height=" . $this->fieldsArr[$i]['imageHeight'];
                     }
                     $val .= " border=0";
                     if (isEnableSection508()) {
                         $val .= " alt=\"Image from DB\"";
                     }
                     $val .= " src=\"imager.php?table=" . $this->shortTName . "&field=" . rawurlencode(htmlspecialchars($this->fieldsArr[$i]['name'])) . $keylink . "\">";
                 }
             } else {
                 $val = mlang_message("LONG_BINARY");
             }
         } elseif ($this->fieldsArr[$i]['viewFormat'] == FORMAT_FILE_IMAGE) {
             if (!$this->forExport) {
                 if (CheckImageExtension($value[$this->fieldsArr[$i]['name']])) {
                     if ($this->fieldsArr[$i]['showThumb']) {
                         // show thumbnail
                         $thumbname = $this->fieldsArr[$i]['thumbnail'] . $value[$this->fieldsArr[$i]['name']];
                         if (substr($this->fieldsArr[$i]['strhlPrefix'], 0, 7) != "http://" && !myfile_exists(getabspath($this->fieldsArr[$i]['strhlPrefix'] . $thumbname))) {
                             $thumbname = $value[$this->fieldsArr[$i]['name']];
                         }
                         $val = "<a";
                         if (IsUseiBox($this->fieldsArr[$i]['name'], $this->tName)) {
                             $val .= " rel='ibox'";
                         } else {
                             $val .= " target=_blank";
                         }
                         $val .= " href=\"" . htmlspecialchars(AddLinkPrefix($this->fieldsArr[$i]['name'], $value[$this->fieldsArr[$i]['name']])) . "\">";
                         $val .= "<img";
                         if ($thumbname == $value[$this->fieldsArr[$i]['name']]) {
                             if ($this->fieldsArr[$i]['imageWidth']) {
                                 $val .= " width=" . $this->fieldsArr[$i]['imageWidth'];
                             }
                             if ($this->fieldsArr[$i]['imageHeight']) {
                                 $val .= " height=" . $this->fieldsArr[$i]['imageHeight'];
                             }
                         }
                         $val .= " border=0";
                         if (isEnableSection508()) {
                             $val .= " alt=\"" . htmlspecialchars($value[$this->fieldsArr[$i]['name']]) . "\"";
                         }
                         $val .= " src=\"" . htmlspecialchars(AddLinkPrefix($this->fieldsArr[$i]['name'], $thumbname)) . "\"></a>";
                     } else {
                         $val = "<img";
                         if ($this->fieldsArr[$i]['imageWidth']) {
                             $val .= " width=" . $this->fieldsArr[$i]['imageWidth'];
                         }
                         if ($this->fieldsArr[$i]['imageHeight']) {
                             $val .= " height=" . $this->fieldsArr[$i]['imageHeight'];
                         }
                         $val .= " border=0";
                         if (isEnableSection508()) {
                             $val .= " alt=\"" . htmlspecialchars($value[$this->fieldsArr[$i]['name']]) . "\"";
                         }
                         $val .= " src=\"" . htmlspecialchars(AddLinkPrefix($this->fieldsArr[$i]['name'], $value[$this->fieldsArr[$i]['name']])) . "\">";
                     }
                 }
             } else {
                 $val = mlang_message("LONG_BINARY");
             }
         } elseif ($this->fieldsArr[$i]['viewFormat'] == FORMAT_DATABASE_FILE) {
             if (!$this->forExport) {
                 if ($this->fieldsArr[$i]['fileName']) {
                     $filename = $value[$this->fieldsArr[$i]['fileName']];
                     if (!$filename) {
                         $filename = "file.bin";
                     }
                 } else {
                     $filename = "file.bin";
                 }
                 if (strlen($value[$this->fieldsArr[$i]['name']])) {
                     $val = "<a href=\"getfile.php?table=" . $this->shortTName . "&filename=" . rawurlencode($filename) . "&field=" . rawurlencode(htmlspecialchars($this->fieldsArr[$i]['name'])) . $keylink . "\">";
                     $val .= htmlspecialchars($filename);
                     $val .= "</a>";
                 }
             } else {
                 $val = mlang_message("LONG_BINARY");
             }
         } elseif (($this->fieldsArr[$i]['editFormat'] == EDIT_FORMAT_LOOKUP_WIZARD || $this->fieldsArr[$i]['editFormat'] == EDIT_FORMAT_RADIO) && GetLookupType($this->fieldsArr[$i]['name'], $this->tName) == LT_LOOKUPTABLE) {
             $val = DisplayLookupWizard($this->fieldsArr[$i]['name'], $value[$this->fieldsArr[$i]['name']], $value, $keylink, $this->mode);
         } elseif (NeedEncode($this->fieldsArr[$i]['name'], $this->tName)) {
             $val = ProcessLargeText(GetData($value, $this->fieldsArr[$i]['name'], $this->fieldsArr[$i]['viewFormat']), "field=" . rawurlencode($this->fieldsArr[$i]['name']) . $keylink, "", $this->mode);
         } else {
             //$val = GetData($value, $this->fieldsArr[$i]['name'], $this->fieldsArr[$i]['viewFormat']);
             if ($this->fieldsArr[$i]['viewFormat'] == FORMAT_CHECKBOX && $this->forExport) {
                 $val = GetData($value, $this->fieldsArr[$i]['name'], FORMAT_NONE);
             } else {
                 $val = GetData($value, $this->fieldsArr[$i]['name'], $this->fieldsArr[$i]['viewFormat']);
             }
         }
         $row[$this->fieldsArr[$i]['goodName'] . "_value"] = $val;
     }
     if ($this->repLayout == REPORT_BLOCK) {
         $row[GoodFieldName('nonewgroup')] = true;
     }
     return $row;
 }
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:101,代码来源:reportlib.php

示例14: WriteTableData

function WriteTableData()
{
    global $rs, $nPageSize, $strTableName, $conn, $eventObj;
    if ($eventObj->exists("ListFetchArray")) {
        $row = $eventObj->ListFetchArray($rs);
    } else {
        $row = db_fetch_array($rs);
    }
    //	if(!$row)
    //		return;
    // write header
    echo "<tr>";
    if ($_REQUEST["type"] == "excel") {
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Record_ID")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Module_ID")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Voltage_Red")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Voltage_Blue")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Voltage_Yellow")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Currunt_Red")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Currunt_Blue")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Currunt_Yellow")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "PF_Red")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "PF_Blue")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "PF_Yellow")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Peak_Power")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Date_Time")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "IsSync")) . '</td>';
        echo '<td style="width: 100" x:str>' . PrepareForExcel(GetFieldLabel("dbo_Readings", "Currunt_Readings")) . '</td>';
    } else {
        echo "<td>" . GetFieldLabel("dbo_Readings", "Record_ID") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Module_ID") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Voltage_Red") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Voltage_Blue") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Voltage_Yellow") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Currunt_Red") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Currunt_Blue") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Currunt_Yellow") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "PF_Red") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "PF_Blue") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "PF_Yellow") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Peak_Power") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Date_Time") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "IsSync") . "</td>";
        echo "<td>" . GetFieldLabel("dbo_Readings", "Currunt_Readings") . "</td>";
    }
    echo "</tr>";
    $totals["Record ID"] = 0;
    $totalsFields[] = array('fName' => "Record ID", 'totalsType' => '', 'viewFormat' => "");
    $totals["Module ID"] = 0;
    $totalsFields[] = array('fName' => "Module ID", 'totalsType' => '', 'viewFormat' => "");
    $totals["Voltage Red"] = 0;
    $totalsFields[] = array('fName' => "Voltage Red", 'totalsType' => '', 'viewFormat' => "");
    $totals["Voltage Blue"] = 0;
    $totalsFields[] = array('fName' => "Voltage Blue", 'totalsType' => '', 'viewFormat' => "");
    $totals["Voltage Yellow"] = 0;
    $totalsFields[] = array('fName' => "Voltage Yellow", 'totalsType' => '', 'viewFormat' => "");
    $totals["Currunt Red"] = 0;
    $totalsFields[] = array('fName' => "Currunt Red", 'totalsType' => '', 'viewFormat' => "");
    $totals["Currunt Blue"] = 0;
    $totalsFields[] = array('fName' => "Currunt Blue", 'totalsType' => '', 'viewFormat' => "");
    $totals["Currunt Yellow"] = 0;
    $totalsFields[] = array('fName' => "Currunt Yellow", 'totalsType' => '', 'viewFormat' => "");
    $totals["PF Red"] = 0;
    $totalsFields[] = array('fName' => "PF Red", 'totalsType' => '', 'viewFormat' => "");
    $totals["PF Blue"] = 0;
    $totalsFields[] = array('fName' => "PF Blue", 'totalsType' => '', 'viewFormat' => "");
    $totals["PF Yellow"] = 0;
    $totalsFields[] = array('fName' => "PF Yellow", 'totalsType' => '', 'viewFormat' => "");
    $totals["Peak Power"] = 0;
    $totalsFields[] = array('fName' => "Peak Power", 'totalsType' => '', 'viewFormat' => "");
    $totals["Date Time"] = 0;
    $totalsFields[] = array('fName' => "Date Time", 'totalsType' => '', 'viewFormat' => "Short Date");
    $totals["IsSync"] = 0;
    $totalsFields[] = array('fName' => "IsSync", 'totalsType' => '', 'viewFormat' => "Checkbox");
    $totals["Currunt Readings"] = 0;
    $totalsFields[] = array('fName' => "Currunt Readings", 'totalsType' => '', 'viewFormat' => "");
    $totals = array();
    // write data rows
    $iNumberOfRows = 0;
    while ((!$nPageSize || $iNumberOfRows < $nPageSize) && $row) {
        countTotals($totals, $totalsFields, $row);
        $values = array();
        $format = "";
        $values["Record ID"] = GetData($row, "Record ID", $format);
        $values["Module ID"] = "";
        if (strlen($row["Module ID"])) {
            $values["Module ID"] = DisplayLookupWizard("Module ID", $row["Module ID"], $row, "", MODE_EXPORT);
        }
        $format = "";
        $values["Voltage Red"] = GetData($row, "Voltage Red", $format);
        $format = "";
        $values["Voltage Blue"] = GetData($row, "Voltage Blue", $format);
        $format = "";
        $values["Voltage Yellow"] = GetData($row, "Voltage Yellow", $format);
        $format = "";
        $values["Currunt Red"] = GetData($row, "Currunt Red", $format);
        $format = "";
        $values["Currunt Blue"] = GetData($row, "Currunt Blue", $format);
        $format = "";
        $values["Currunt Yellow"] = GetData($row, "Currunt Yellow", $format);
//.........这里部分代码省略.........
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:101,代码来源:Readings_export.php

示例15: ExportToExcel

function ExportToExcel()
{
    global $rs, $nPageSize, $strTableName, $conn, $eventObj;
    if ($eventObj->exists("ListFetchArray")) {
        $row = $eventObj->ListFetchArray($rs);
    } else {
        $row = db_fetch_array($rs);
    }
    //	if(!$row)
    //		return;
    $arrLabel = array();
    $arrColumnWidth = array();
    $arrTotal = array();
    $arrTotalMessage = array();
    $totals = array();
    $arrFields = array();
    $arrTmpTotal = array();
    $arrFields = GetFieldsList($strTableName);
    $arrTmpTotal = GetTableData($strTableName, ".totalsFields", array());
    foreach ($arrFields as $value) {
        $arrLabel[$value] = label($value, $strTableName);
        $arrColumnWidth[$value] = 10;
        $totals[$value] = 0;
        $totalsType = "";
        foreach ($arrTmpTotal as $tvalue) {
            if ($tvalue["fName"] == $value) {
                $totalsType = $tvalue["totalsType"];
            }
        }
        $totalsFields[] = array('fName' => $value, 'totalsType' => $totalsType, 'viewFormat' => ViewFormat($value, $strTableName));
    }
    // write data rows
    $iNumberOfRows = 0;
    $objPHPExcel = ExportExcelInit($arrLabel, $arrColumnWidth);
    while ((!$nPageSize || $iNumberOfRows < $nPageSize) && $row) {
        countTotals($totals, $totalsFields, $row);
        $values = array();
        $arrData = array();
        $arrDataType = array();
        foreach ($arrFields as $value) {
            if (GetEditFormat($value, $strTableName) == EDIT_FORMAT_LOOKUP_WIZARD || GetEditFormat($value, $strTableName) == EDIT_FORMAT_RADIO) {
                $values[$value] = "";
                if (strlen($row[$value])) {
                    $values[$value] = DisplayLookupWizard($value, $row[$value], $row, "", MODE_EXPORT);
                }
            } elseif (IsBinaryType(GetFieldType($value, $strTableName))) {
                $values[$value] = $row[$value];
            } else {
                if (ViewFormat($value, $strTableName) != FORMAT_FILE_IMAGE && ViewFormat($value, $strTableName) != FORMAT_FILE && ViewFormat($value, $strTableName) != FORMAT_HYPERLINK && ViewFormat($value, $strTableName) != FORMAT_EMAILHYPERLINK && ViewFormat($value, $strTableName) != FORMAT_CHECKBOX) {
                    $format = ViewFormat($value, $strTableName);
                } else {
                    $format = FORMAT_NONE;
                }
                $values[$value] = GetData($row, $value, $format);
            }
        }
        $eventRes = true;
        if ($eventObj->exists('BeforeOut')) {
            $eventRes = $eventObj->BeforeOut($row, $values, $arrColumnWidth, $iNumberOfRows + 1, $objPHPExcel);
        }
        if ($eventRes) {
            $iNumberOfRows++;
            $i = 0;
            foreach ($arrFields as $value) {
                if (IsBinaryType(GetFieldType($value, $strTableName))) {
                    $arrDataType[$value] = "binary";
                } elseif (ViewFormat($value, $strTableName) == FORMAT_FILE_IMAGE) {
                    $arrDataType[$value] = "file";
                } elseif (ViewFormat($value, $strTableName) == FORMAT_DATE_SHORT || ViewFormat($value, $strTableName) == FORMAT_DATE_LONG || ViewFormat($value, $strTableName) == FORMAT_DATE_TIME) {
                    $arrDataType[$value] = "date";
                } else {
                    $arrDataType[$value] = "";
                }
                $arrData[$value] = $values[$value];
            }
            ExportExcelRecord($arrData, $arrDataType, $iNumberOfRows, $objPHPExcel);
        }
        if ($eventObj->exists("ListFetchArray")) {
            $row = $eventObj->ListFetchArray($rs);
        } else {
            $row = db_fetch_array($rs);
        }
    }
    if (count($arrTmpTotal)) {
        foreach ($arrFields as $fName) {
            $value = array();
            foreach ($arrTmpTotal as $tvalue) {
                if ($tvalue["fName"] == $fName) {
                    $value = $tvalue;
                }
            }
            $total = "";
            $totalMess = "";
            if ($value["totalsType"]) {
                if ($value["totalsType"] == "COUNT") {
                    $totalMess = "Count" . ": ";
                } elseif ($value["totalsType"] == "TOTAL") {
                    $totalMess = "Total" . ": ";
                } elseif ($value["totalsType"] == "AVERAGE") {
                    $totalMess = "Average" . ": ";
//.........这里部分代码省略.........
开发者ID:samsulpendis,项目名称:Instant_Appointment,代码行数:101,代码来源:export_functions.php


注:本文中的DisplayLookupWizard函数示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。