source: branches/feature-module-paygent/data/include/csv_output.inc @ 17

Revision 17, 1.4 KB checked in by uehara, 14 years ago (diff)
Line 
1<?php
2/*
3 * Copyright(c) 2000-2007 LOCKON CO.,LTD. All Rights Reserved.
4 *
5 * http://www.lockon.co.jp/
6 */
7
8$arrSubnavi = array(
9    1 => 'product',
10    2 => 'customer',
11    3 => 'order',
12    4 => 'campaign'
13);
14
15$arrSubnaviName = array(
16    1 => '¾¦ÉÊ´ÉÍý',
17    2 => '¸ÜµÒ´ÉÍý',
18    3 => '¼õÃí´ÉÍý',
19    4 => '¥­¥ã¥ó¥Ú¡¼¥ó'
20);
21
22/**************************************************************************************************************
23 * ´Ø¿ô̾   ¡§sfgetCsvOutput
24 * ½èÍýÆâÍÆ ¡§CSV½ÐÎϹàÌܤò¼èÆÀ¤¹¤ë
25 * °ú¿ô     ¡§¤Ê¤·
26 * Ìá¤êÃÍ   ¡§CSV½ÐÎϹàÌÜ
27 **************************************************************************************************************/
28function sfgetCsvOutput($csv_id = "", $where = "", $arrVal = array()){
29    $objQuery = new SC_Query();
30    $arrData = array();
31    $ret = array();
32   
33    $sql = "";
34    $sql .= " SELECT ";
35    $sql .= "     no, ";
36    $sql .= "     csv_id, ";
37    $sql .= "     col, ";
38    $sql .= "     disp_name, ";
39    $sql .= "     rank, ";
40    $sql .= "     status, ";
41    $sql .= "     create_date, ";
42    $sql .= "     update_date ";
43    $sql .= " FROM ";
44    $sql .= "     dtb_csv ";
45   
46    if ($where != "") {
47        $sql .= $where;
48        $arrData = $arrVal;
49    }elseif($csv_id != ""){
50        $sql .= " WHERE csv_id = ? ";
51        $arrData = array($csv_id);
52    }
53   
54    $sql .= " ORDER BY ";
55    $sql .= "     rank , no";
56    $sql .= " ";   
57   
58    $ret = $objQuery->getall($sql, $arrData);
59   
60    return $ret;
61}
62
63?>
Note: See TracBrowser for help on using the repository browser.