本文整理汇总了PHP中ARInteger::instance方法的典型用法代码示例。如果您正苦于以下问题:PHP ARInteger::instance方法的具体用法?PHP ARInteger::instance怎么用?PHP ARInteger::instance使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类ARInteger
的用法示例。
在下文中一共展示了ARInteger::instance方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的PHP代码示例。
示例1: registerClass
public function registerClass($className, $id)
{
self::getEavClasses();
self::$eavClasses[$className] = $id;
$schema = self::getSchemaInstance('EavObject');
$schema->registerField(new ARForeignKeyField(EavObject::getClassField($className), $className, "ID", null, ARInteger::instance()), false);
}
示例2: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField('ID', ARInteger::instance()));
$schema->registerField(new ARField('name', ARVarchar::instance(60)));
}
示例3: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName("Role");
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance(10)));
$schema->registerField(new ARField("name", ARText::instance(150)));
}
示例4: defineSchema
/**
* Define database schema for Category model
*
* @param string $className Schema name
*/
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
parent::defineSchema($className);
$schema->registerField(new ARField("isEnabled", ARBool::instance()));
$schema->registerField(new ARField("isAnyRecord", ARBool::instance()));
$schema->registerField(new ARField("isAllSubconditions", ARBool::instance()));
$schema->registerField(new ARField("isActionCondition", ARBool::instance()));
$schema->registerField(new ARField("isFinal", ARBool::instance()));
$schema->registerField(new ARField("isReverse", ARBool::instance()));
$schema->registerField(new ARField("conditionClass", ARVarchar::instance(80)));
$schema->registerField(new ARField("recordCount", ARInteger::instance()));
$schema->registerField(new ARField("validFrom", ARDateTime::instance()));
$schema->registerField(new ARField("validTo", ARDateTime::instance()));
$schema->registerField(new ARField("subTotal", ARInteger::instance()));
$schema->registerField(new ARField("count", ARInteger::instance()));
$schema->registerField(new ARField("comparisonType", ARInteger::instance()));
$schema->registerField(new ARField("position", ARInteger::instance()));
$schema->registerField(new ARField("name", ARArray::instance()));
$schema->registerField(new ARField("description", ARArray::instance()));
$schema->registerField(new ARField("couponCode", ARVarchar::instance(100)));
$schema->registerField(new ARField("couponLimitCount", ARInteger::instance()));
$schema->registerField(new ARField("couponLimitType", ARInteger::instance()));
$schema->registerField(new ARField("serializedCondition", ARText::instance()));
}
示例5: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryForeignKeyField('categoryID', 'Category', 'ID', 'Category', ARInteger::instance()));
$schema->registerField(new ARPrimaryForeignKeyField('productID', 'Product', 'ID', 'Product', ARInteger::instance()));
}
示例6: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = parent::defineSchema($className);
$schema->setName("ProductRelationshipGroup");
$schema->registerField(new ARField("name", ARArray::instance()));
$schema->registerField(new ARField("type", ARInteger::instance()));
}
示例7: defineSchema
/**
* Define database schema used by this active record instance
*
* @param string $className Schema name
*/
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("parentTransactionID", "Transaction", "ID", "Transaction", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("orderID", "CustomerOrder", "ID", "CustomerOrder", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("currencyID", "currency", "ID", 'Currency', ARChar::instance(3)));
$schema->registerField(new ARForeignKeyField("realCurrencyID", "realCurrency", "ID", 'Currency', ARChar::instance(3)));
$schema->registerField(new ARForeignKeyField("userID", "user", "ID", 'User', ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("eavObjectID", "eavObject", "ID", 'EavObject', ARInteger::instance()), false);
$schema->registerField(new ARField("amount", ARFloat::instance()));
$schema->registerField(new ARField("realAmount", ARFloat::instance()));
$schema->registerField(new ARField("time", ARDateTime::instance()));
$schema->registerField(new ARField("method", ARVarchar::instance(40)));
$schema->registerField(new ARField("gatewayTransactionID", ARVarchar::instance(40)));
$schema->registerField(new ARField("type", ARInteger::instance()));
$schema->registerField(new ARField("methodType", ARInteger::instance()));
$schema->registerField(new ARField("isCompleted", ARBool::instance()));
$schema->registerField(new ARField("isVoided", ARBool::instance()));
$schema->registerField(new ARField("ccExpiryYear", ARInteger::instance()));
$schema->registerField(new ARField("ccExpiryMonth", ARInteger::instance()));
$schema->registerField(new ARField("ccLastDigits", ARVarchar::instance(40)));
$schema->registerField(new ARField("ccType", ARVarchar::instance(40)));
$schema->registerField(new ARField("ccName", ARVarchar::instance(100)));
$schema->registerField(new ARField("ccCVV", ARVarchar::instance(80)));
$schema->registerField(new ARField("comment", ARText::instance()));
$schema->registerField(new ARField("serializedData", ARText::instance()));
}
示例8: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName("DeliveryZoneCityMask");
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("deliveryZoneID", "DeliveryZone", "ID", "DeliveryZone", ARInteger::instance()));
$schema->registerField(new ARField("mask", ARChar::instance(60)));
}
示例9: defineSchema
public static function defineSchema($className)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryForeignKeyField(call_user_func(array($className, 'getOwnerIDColumnName')), call_user_func(array($className, 'getOwnerClass')), "ID", null, ARInteger::instance()));
$schema->registerField(new ARPrimaryForeignKeyField(call_user_func(array($className, 'getFieldIDColumnName')), call_user_func(array($className, 'getFieldClass')), "ID", null, ARInteger::instance()));
return $schema;
}
示例10: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARField("name", ARArray::instance()));
$schema->registerField(new ARField("position", ARInteger::instance(2)));
}
示例11: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName("AccessControlAssociation");
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("roleID", "Role", "ID", "Role", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("userGroupID", "UserGroup", "ID", "UserGroup", ARInteger::instance()));
}
示例12: defineSchema
/**
* Define database schema
*/
public static function defineSchema($className)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("userID", "user", "ID", 'User', ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("userAddressID", "userAddress", "ID", 'UserAddress', ARInteger::instance()));
}
示例13: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("productID", "Product", "ID", null, ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("variationID", "ProductVariation", "ID", null, ARInteger::instance()));
}
示例14: defineSchema
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName("UserGroup");
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("eavObjectID", "eavObject", "ID", 'EavObject', ARInteger::instance()), false);
$schema->registerField(new ARField("name", ARVarchar::instance(60)));
$schema->registerField(new ARField("description", ARVarchar::instance(100)));
}
示例15: defineSchema
/**
* Define database schema used by this active record instance
*
* @param string $className Schema name
*/
public static function defineSchema($className = __CLASS__)
{
$schema = self::getSchemaInstance($className);
$schema->setName($className);
$schema->registerField(new ARPrimaryKeyField("ID", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("orderID", "CustomerOrder", "ID", "CustomerOrder", ARInteger::instance()));
$schema->registerField(new ARForeignKeyField("discountConditionID", "DiscountCondition", "ID", "DiscountCondition", ARInteger::instance()));
$schema->registerField(new ARField("couponCode", ARVarchar::instance(255)));
}