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


PHP DatabaseManager::singleDateToDatabaseDate方法代码示例

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


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

示例1: Defuntion

$kid = $_GET["kid"];
if ($sortType == NULL || $sortType == '') {
    $sortType = 'id DESC';
}
if ($numberPage === NULL || $numberPage < 0) {
    echo "<script src='../JS/functions.js'></script><script>nextPage('set', '0')</script>";
}
//Getting all registries
if ($simpleKeyword !== NULL) {
    $defuntionRegistries = DefuntionManager::simpleSearchDefuntion($simpleKeyword, $sortType, $numberPage);
} else {
    if ($kid !== NULL) {
        $defuntionSearch = new Defuntion();
        $kcelebration = DatabaseManager::singleDateToDatabaseDate($_GET["kcelebration"]);
        $kbornp = $_GET["kbornp"];
        $kbornd = DatabaseManager::singleDateToDatabaseDate($_GET["kbornd"]);
        $knamec = $_GET["knamec"];
        $klastname1c = $_GET["klastname1c"];
        $klastname2c = $_GET["klastname2c"];
        $knamef = $_GET["knamef"];
        $kchurch = $_GET["kchurch"];
        $defuntionSearch->setId($kid);
        $defuntionSearch->setDeadDate($kcelebration);
        $posibleNames[0] = PersonManager::searchPersonsByNames($knamec, $klastname1c, $klastname2c, false);
        $defuntionSearch->setIdOwner($posibleNames);
        $posibleChurch = ChurchManager::simpleSearchChurch($kchurch, 'id', -1);
        $defuntionSearch->setIdChurch($posibleChurch);
        $defuntionRegistries = DefuntionManager::advancedSearchDefuntion($defuntionSearch, 'AND', $sortType, $numberPage);
    } else {
        $defuntionRegistries = DefuntionManager::getAllDefuntions($sortType, $numberPage);
    }
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:defuntionMenu.php

示例2: Person

}
$girlfriend = new Person();
if ($_POST["idGirlfriend"] !== '0') {
    $girlfriend = PersonManager::getSinglePerson('id', $_POST["idGirlfriend"]);
}
$boyfriend->setId($_POST["idBoyfriend"]);
$boyfriend->setNames($_POST["boyfriendName"]);
$boyfriend->setLastname1($_POST["lastname1Boyfriend"]);
$boyfriend->setLastname2($_POST["lastname2Boyfriend"]);
$girlfriend->setId($_POST["idGirlfriend"]);
$girlfriend->setNames($_POST["girlfriendName"]);
$girlfriend->setLastname1($_POST["lastname1Girlfriend"]);
$girlfriend->setLastname2($_POST["lastname2Girlfriend"]);
$marriage = new Marriage();
$marriage->setId($_POST["idMarriage"]);
$celb = DatabaseManager::singleDateToDatabaseDate($_POST["celebrationDate"]);
$marriage->setCelebrationDate($celb);
$marriage->setIdChurchProcess($churchProcess->getId());
$marriage->setIdChurchMarriage($churchMarriage->getId());
$marriage->setIdRector($_POST["rectorId"]);
if ($boyfriend->getId() === '0') {
    PersonManager::addPerson($boyfriend, 'true');
    $boyfriend = PersonManager::getSinglePerson('id', PersonManager::getLastID());
} else {
    PersonManager::updatePerson($boyfriend);
}
if ($girlfriend->getId() === '0') {
    PersonManager::addPerson($girlfriend, 'true');
    $girlfriend = PersonManager::getSinglePerson('id', PersonManager::getLastID());
} else {
    PersonManager::updatePerson($girlfriend);
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:insertMarriage.php

示例3: Marriage

$sortType = $_GET["sort"];
$simpleKeyword = $_GET["keyword"];
$kid = $_GET["kid"];
if ($sortType == NULL || $sortType == '') {
    $sortType = 'id';
}
if ($numberPage === NULL || $numberPage < 0) {
    echo "<script src='../JS/functions.js'></script><script>nextPage('set', '0')</script>";
}
//Getting all registries
if ($simpleKeyword !== NULL) {
    $marriageRegistries = MarriageManager::simpleSearchMarriage($simpleKeyword, $sortType, $numberPage);
} else {
    if ($kid !== NULL) {
        $marriageSearch = new Marriage();
        $kcelebration = DatabaseManager::singleDateToDatabaseDate($_GET["kcelebration"]);
        $knameb = $_GET["knameb"];
        $klastname1b = $_GET["klastname1b"];
        $klastname2b = $_GET["klastname2b"];
        $knameg = $_GET["knameg"];
        $klastname1g = $_GET["klastname1g"];
        $klastname2g = $_GET["klastname2g"];
        $kchurchc = $_GET["kchurch"];
        $kbook = $_GET["kbook"];
        $knumber = $_GET["knumber"];
        $kpape = $_GET["kpape"];
        $marriageSearch->setId($kid);
        $marriageSearch->setCelebrationDate($kcelebration);
        $posibleNames[0] = PersonManager::searchPersonsByNames($knameb, $klastname1b, $klastname2b, false);
        $posibleNames[1] = PersonManager::searchPersonsByNames($knameg, $klastname1g, $klastname2g, false);
        $marriageSearch->setIdBoyfriend($posibleNames[0]);
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:marriageMenu.php

示例4:

                 $baptism->setIdCivilRegistry('1');
                 $celb = DatabaseManager::singleDateToDatabaseDate($_POST["baptismDate"]);
                 $baptism->setCelebrationDate($celb);
                 $church = ChurchManager::getSingleChurch('name', $_POST["baptismChurch"]);
                 if ($church !== NULL) {
                     $baptism->setIdChurch($church->getId());
                     $baptism->setIdRector(RectorManager::getSingleRector('idActualChurch', $church->getId())->getId());
                 }
                 $baptism->setIdOwner($child->getId());
                 $baptism->setIdBookRegistry($bookRegistry->getId());
                 BaptismManager::addBaptism($baptism);
             }
         } else {
             $baptism = BaptismManager::getSingleBaptism('id', $_POST["baptismId"]);
             if ($baptism !== NULL) {
                 $celb = DatabaseManager::singleDateToDatabaseDate($_POST["baptismDate"]);
                 $baptism->setCelebrationDate($celb);
                 $church = ChurchManager::getSingleChurch('name', $_POST["baptismChurch"]);
                 if ($church !== NULL) {
                     $baptism->setIdChurch($church->getId());
                 }
                 BaptismManager::updateBaptism($baptism);
                 $baptismReg = BaptismManager::getSingleBaptismRegistry('id', $baptism->getIdBookRegistry());
                 $baptismReg->setBook($_POST["bookBookRegistryB"]);
                 $baptismReg->setPage($_POST["pageBookRegistryB"]);
                 $baptismReg->setNumber($_POST["numBookRegistryB"]);
                 BaptismManager::updateBaptismRegistry($baptismReg);
             }
         }
     }
 }
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:insertConfirmation.php

示例5: Person

if (!isset($_POST) || $_POST["idChild"] === NULL) {
    echo "KO";
    die;
}
$church = ChurchManager::getSingleChurch('name', $_POST["celebrationChurch"]);
$child = new Person();
if ($_POST["idChild"] !== '0') {
    $child = PersonManager::getSinglePerson('id', $_POST["idChild"]);
}
$child->setId($_POST["idChild"]);
$child->setNames($_POST["nameChild"]);
$child->setLastname1($_POST["lastname1Child"]);
$child->setLastname2($_POST["lastname2Child"]);
$defuntion = new Defuntion();
$defuntion->setId($_POST["idDefuntion"]);
$defuntion->setDeadDate(DatabaseManager::singleDateToDatabaseDate($_POST["celebrationDate"]));
$defuntion->setIdChurch($church->getId());
$defuntion->setIdOwner($child->getId());
//Get the defuntion Crypt
if ($_POST["idCrypt"] == '0') {
    if ($_POST["inCrypt"] == "true") {
        $myCrypt = new Crypt();
        $myCrypt->setIdNiche($church->getIdNiche());
        $myCrypt->setCol($_POST["cryptColumn"]);
        $myCrypt->setRow($_POST["cryptRow"]);
        $myCrypt->setNumber($_POST["cryptNumber"]);
        DefuntionManager::addCrypt($myCrypt);
        $singleCrypt = DefuntionManager::getSingleCrypt('col', $myCrypt->getCol(), 'row', $myCrypt->getRow(), 'idNiche', $myCrypt->getIdNiche(), 'number', $myCrypt->getNumber());
        $defuntion->setIdCrypt($singleCrypt->getId());
    } else {
        $defuntion->setIdCrypt(NULL);
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:insertDefuntion.php

示例6: Person

}
$church = ChurchManager::getSingleChurch('name', $_POST["celebrationChurch"]);
$child = new Person();
if ($_POST["idChild"] !== '0') {
    $child = PersonManager::getSinglePerson('id', $_POST["idChild"]);
}
$child->setId($_POST["idChild"]);
$child->setNames($_POST["nameChild"]);
$child->setLastname1($_POST["lastname1Child"]);
$child->setLastname2($_POST["lastname2Child"]);
$child->setGender(substr($_POST["genderChild"], 0, 1));
$baptism = new Baptism();
$baptism->setId($_POST["idBaptism"]);
$celb = DatabaseManager::singleDateToDatabaseDate($_POST["celebrationDate"]);
$baptism->setCelebrationDate($celb);
$baptism->setBornDate(DatabaseManager::singleDateToDatabaseDate($_POST["bornDateChild"]));
$baptism->setBornPlace($_POST["bornPlaceChild"]);
$baptism->setIdChurch($church->getId());
$baptism->setIdRector($_POST["rectorId"]);
$legitimate = substr($_POST["legitimateChild"], 0, 1);
if ($legitimate === 'S' || $legitimate === 'Y') {
    $baptism->setLegitimate('Y');
} else {
    $baptism->setLegitimate('N');
}
//Data Process for the Father
$father = new Person();
if ($_POST["idFather"] !== '0') {
    $father = PersonManager::getSinglePerson('id', $_POST["idFather"]);
    $father->setId($_POST["idFather"]);
    $father->setNames($_POST["nameFather"]);
开发者ID:jonatalamantes,项目名称:NotariusAdOmnes,代码行数:31,代码来源:insertBaptism.php


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