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


PHP ProjectModule::GetOneInfoByKeyID方法代码示例

本文整理汇总了PHP中ProjectModule::GetOneInfoByKeyID方法的典型用法代码示例。如果您正苦于以下问题:PHP ProjectModule::GetOneInfoByKeyID方法的具体用法?PHP ProjectModule::GetOneInfoByKeyID怎么用?PHP ProjectModule::GetOneInfoByKeyID使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在ProjectModule的用法示例。


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

示例1: Edit

 public function Edit()
 {
     if ($this->_POST) {
         $KeyID = _intval($this->_POST['KeyID']);
         $Data['ProjectName'] = trim($this->_POST['ProjectName']);
         $Data['OnlineTime'] = trim($this->_POST['OnlineTime']);
         $Data['Remark'] = addslashes($this->_POST['Remark']);
         $Data['UpdateTime'] = date("Y-m-d H:i:s");
         $ProjectModule = new ProjectModule();
         if ($ProjectModule->UpdateArrayByKeyID($Data, $KeyID)) {
             $this->__Message('修改产品成功!', UrlRewriteSimple('Project', 'Lists', true), '继续操作');
         } else {
             $this->__Message('修改产品失败,请再一次尝试!');
         }
     }
     if ($this->_GET) {
         $KeyID = _intval($this->_GET['KeyID']);
         $ProjectModule = new ProjectModule();
         $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($KeyID);
         $this->ProjectInfo = $ProjectInfo;
     }
 }
开发者ID:baiduXM,项目名称:agent,代码行数:22,代码来源:class.Project.php

示例2: Lists

 public function Lists()
 {
     if ($this->_GET) {
         $ProjectID = _intval($this->_GET['ProjectID']);
         $this->ProjectID = $ProjectID;
         $PropertyModule = new PropertyModule();
         $ProjectModule = new ProjectModule();
         //产品下属性列表
         if ($ProjectID == 1) {
             $ModelClass = new ModelClassModule();
             $ModelClassLists = $ModelClass->GetListsAll();
             $this->ModelClassLists = $ModelClassLists;
             $this->Data = array_merge($PropertyModule->GetAllModelLists(), $PropertyModule->GetAllModelLists('tb_model_packages'));
             $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($ProjectID);
             $this->ProjectInfo = $ProjectInfo;
             $NO = $this->_GET['NO'];
             if ($NO) {
                 $Model = $PropertyModule->GetOneInfoByNO($NO);
                 if (!$Model) {
                     $Model = $PropertyModule->GetOneInfoByNO($NO, 'PackagesNum', 'tb_model_packages');
                 }
                 $this->Model = $Model;
             }
             if ($this->_GET['State']) {
                 $this->State = $this->_GET['State'];
             } else {
                 $this->State = 0;
             }
         } else {
             $MysqlWhere = ' where ProjectID=' . $ProjectID . ' and ProjectPropertyParentID=0';
             $Data = $PropertyModule->GetProjectPropertyLists($MysqlWhere, 0, 100);
             foreach ($Data as $Key => $Value) {
                 $MysqlWhereTwo = ' where ProjectPropertyParentID=' . $Value['ProjectPropertyID'];
                 $Data[$Key]['Two'] = $PropertyModule->GetProjectPropertyLists($MysqlWhereTwo, 0, 100);
             }
             $this->Data = $Data;
             //一级产品属性
             $ParentMysqlWhere = ' where ProjectID=' . $ProjectID . ' and ProjectPropertyParentID=0';
             $ParentData = $PropertyModule->GetProjectPropertyLists($ParentMysqlWhere, 0, 100);
             $this->ParentData = $ParentData;
             //产品信息
             $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($ProjectID);
             $this->ProjectInfo = $ProjectInfo;
             //产品属性信息
             $ProjectPropertyID = _intval($this->_GET['ProjectPropertyID']);
             if ($ProjectPropertyID > 0) {
                 $ProjectPropertyInfo = $PropertyModule->GetOneInfoByKeyID($ProjectPropertyID);
                 $this->MyFuWuString = ',' . $ProjectPropertyInfo['MyFuWu'] . ',';
                 $this->OtherFuWuString = ',' . $ProjectPropertyInfo['OtherFuWu'] . ',';
                 $this->ProjectPropertyInfo = $ProjectPropertyInfo;
             }
             //服务
             $FuWuModule = new FuWuModule();
             $this->FuWuList = $FuWuModule->SelectLists();
         }
     }
 }
开发者ID:baiduXM,项目名称:agent,代码行数:57,代码来源:class.Property.php

示例3: Lists

 public function Lists()
 {
     include 'Include/LevelArray.php';
     $MysqlWhere = ' where 1';
     $Page = intval($this->_GET['Page']);
     $Page = $Page ? $Page : 1;
     $AgentPriceModule = new AgentPriceModule();
     $ListsNum = $AgentPriceModule->GetListsNum($MysqlWhere);
     $Rscount = $ListsNum['Num'];
     $PageSize = 10;
     if ($Rscount) {
         $Data['RecordCount'] = $Rscount;
         $Data['PageSize'] = $PageSize ? $PageSize : $Data['RecordCount'];
         $Data['PageCount'] = ceil($Data['RecordCount'] / $PageSize);
         $Data['Page'] = min($Page, $Data['PageCount']);
         $Offset = ($Page - 1) * $Data['PageSize'];
         if ($Page > $Data['PageCount']) {
             $Page = $Data['PageCount'];
         }
         $Data['Data'] = $AgentPriceModule->GetLists($MysqlWhere, $Offset, $Data['PageSize']);
         $ProjectModule = new ProjectModule();
         foreach ($Data['Data'] as $Key => $Value) {
             $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($Value['ProjectID']);
             $Data['Data'][$Key]['ProjectName'] = $ProjectInfo['ProjectName'];
             $Data['Data'][$Key]['LevelName'] = GetNameByID($Value['LevelID']);
         }
         MultiPage($Data, 10);
         $this->Data = $Data;
     }
 }
开发者ID:baiduXM,项目名称:agent,代码行数:30,代码来源:class.AgentPrice.php

示例4: AddOrder

 public function AddOrder($AgentID = 0, $ProjectID = 0, $Balance = 0, $JinE = 0)
 {
     if ($ProjectID == 0 || $JinE == 0) {
         return 0;
     }
     //求产品详情
     $ProjectModule = new ProjectModule();
     $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($ProjectID);
     //入账记录
     $InsertInfo['Description'] = '线下入账' . $JinE . '元用于购买' . $ProjectInfo['ProjectName'] . ',' . $ProjectInfo['ProjectName'] . '可用余额为' . $Balance . '。';
     $OrderDescriptionModule = new OrderDescriptionModule();
     $InsertOrderInfo['DescriptionID'] = $OrderDescriptionModule->InsertArray($InsertInfo, true);
     if ($InsertOrderInfo['DescriptionID'] > 0) {
         $OrderModule = new OrderModule();
         $InsertOrderInfo['OrderNO'] = GetOrderNO();
         $InsertOrderInfo['AgentID'] = $AgentID;
         $InsertOrderInfo['ProjectID'] = $ProjectID;
         $InsertOrderInfo['Amount'] = $JinE;
         $InsertOrderInfo['AddTime'] = date("Y-m-d H:i:s");
         $InsertOrderInfo['FromIP'] = GetIP();
         $InsertOrderInfo['Remarks'] = '';
         $InsertOrderInfo['Type'] = 1;
         $AllIsOk = $OrderModule->InsertArray($InsertOrderInfo);
         if ($AllIsOk) {
             return 1;
         } else {
             return 0;
         }
     }
     return 0;
 }
开发者ID:baiduXM,项目名称:agent,代码行数:31,代码来源:class.Agent.php

示例5: Info

 public function Info()
 {
     $this->OrderID = _intval($this->_GET['OrderID']);
     $this->Page = _intval($this->_GET['Page']);
     $OrderModule = new OrderModule();
     $OrderInfo = $OrderModule->GetOneInfoByKeyID($this->OrderID);
     $AgentModule = new AgentModule();
     $AgentInfo = $AgentModule->GetOneInfoByKeyID($OrderInfo['AgentID']);
     $OrderInfo['AgentUserName'] = $AgentInfo['UserName'];
     $ProjectModule = new ProjectModule();
     $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($OrderInfo['ProjectID']);
     $OrderInfo['ProjectName'] = $ProjectInfo['ProjectName'];
     $OrderDescriptionModule = new OrderDescriptionModule();
     $OrderDescriptionInfo = $OrderDescriptionModule->GetOneInfoByKeyID($OrderInfo['DescriptionID']);
     $OrderInfo['Description'] = $OrderDescriptionInfo['Description'];
     if ($OrderInfo['Type'] == 1) {
         $OrderInfo['TypeName'] = '入账';
     } else {
         $OrderInfo['TypeName'] = '消费';
     }
     $this->OrderInfo = $OrderInfo;
 }
开发者ID:baiduXM,项目名称:agent,代码行数:22,代码来源:class.Financial.php

示例6: Lists

 public function Lists()
 {
     $CustomersID = _intval($this->_GET['CustomersID']);
     $MysqlWhere = ' where CustomersID=' . $CustomersID;
     $Page = intval($this->_GET['Page']);
     $Page = $Page ? $Page : 1;
     $CustProModule = new CustProModule();
     $ListsNum = $CustProModule->GetListsNum($MysqlWhere);
     $Rscount = $ListsNum['Num'];
     $PageSize = 10;
     if ($Rscount) {
         $Data['RecordCount'] = $Rscount;
         $Data['PageSize'] = $PageSize ? $PageSize : $Data['RecordCount'];
         $Data['PageCount'] = ceil($Data['RecordCount'] / $PageSize);
         $Data['Page'] = min($Page, $Data['PageCount']);
         $Offset = ($Page - 1) * $Data['PageSize'];
         if ($Page > $Data['PageCount']) {
             $Page = $Data['PageCount'];
         }
         $Data['Data'] = $CustProModule->GetLists($MysqlWhere, $Offset, $Data['PageSize']);
         $ProjectModule = new ProjectModule();
         $CustomersModule = new CustomersModule();
         $PropertyModule = new PropertyModule();
         foreach ($Data['Data'] as $Key => $Value) {
             $CustomersInfo = $CustomersModule->GetOneInfoByKeyID($Value['CustomersID']);
             $Data['Data'][$Key]['CompanyName'] = $CustomersInfo['CompanyName'];
             $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($Value['ProjectID']);
             $Data['Data'][$Key]['ProjectName'] = $ProjectInfo['ProjectName'];
             if ($Value['ProjectPropertyID'] != '') {
                 $Data['Data'][$Key]['ProjectPropertyArray'] = $PropertyModule->GetProjectPropertyLists(' where ProjectPropertyID in(' . $Value['ProjectPropertyID'] . ')', 0, 100);
             }
         }
         MultiPage($Data, 10);
         $this->Data = $Data;
     }
     //获取用户信息
     $CustomersID = _intval($this->_GET['CustomersID']);
     $CustomersModule = new CustomersModule();
     $CustomersInfo = $CustomersModule->GetOneInfoByKeyID($CustomersID);
     $this->CustomersInfo = $CustomersInfo;
     //获取所有产品
     $ProjectModule = new ProjectModule();
     $ProjectLists = $ProjectModule->GetProjectLists('', 0, 100);
     $this->ProjectLists = $ProjectLists;
     //客戶产品信息
     $CustomersProjectID = _intval($this->_GET['CustomersProjectID']);
     if ($CustomersProjectID > 0) {
         $CustProInfo = $CustProModule->GetOneInfoByKeyID($CustomersProjectID);
         //产品下属性列表
         $ProjectID = $CustProInfo['ProjectID'];
         $PropertyModule = new PropertyModule();
         $String = '';
         $selected = '';
         $MysqlWhere = ' where ProjectID=' . $ProjectID . ' and ProjectPropertyParentID=0';
         $PropertyData = $PropertyModule->GetProjectPropertyLists($MysqlWhere, 0, 100);
         foreach ($PropertyData as $Key => $Value) {
             $String .= '<p>' . $Value['ProjectPropertyName'];
             $String .= '<select name="ProjectPropertyID[]" id="ProjectPropertyID' . $Value['ProjectPropertyID'] . '">';
             $MysqlWhereTwo = ' where ProjectPropertyParentID=' . $Value['ProjectPropertyID'];
             $PropertyData[$Key]['Two'] = $PropertyModule->GetProjectPropertyLists($MysqlWhereTwo, 0, 100);
             foreach ($PropertyData[$Key]['Two'] as $KeyTwo => $ValueTwo) {
                 $a = ',' . $CustProInfo['ProjectPropertyID'] . ',';
                 $b = ',' . $ValueTwo['ProjectPropertyID'] . ',';
                 if (strstr($a, $b)) {
                     $selected = 'selected="selected"';
                 }
                 $String .= '<option value="' . $ValueTwo['ProjectPropertyID'] . '" ' . $selected . '>&nbsp;&nbsp;' . $ValueTwo['ProjectPropertyName'] . '&nbsp;&nbsp;</option>';
                 unset($selected);
             }
             $String .= '</select>';
             $String .= '</p>';
         }
         $CustProInfo['property'] = $String;
     }
     $this->CustomersProjectID = $CustomersProjectID;
     $this->CustProInfo = $CustProInfo;
 }
开发者ID:baiduXM,项目名称:agent,代码行数:77,代码来源:class.CustPro.php

示例7: GetNamebyProjectID

 public function GetNamebyProjectID($id = '')
 {
     $ProjectModule = new ProjectModule();
     $ProjectInfo = $ProjectModule->GetOneInfoByKeyID($id);
     return $ProjectInfo['ProjectName'];
 }
开发者ID:baiduXM,项目名称:agent,代码行数:6,代码来源:class.Api.php


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