public static function getDiscountByCode($request, $code)
    {
        $discount = Discount_Shortcuts_GetDiscountByCodeOr404($code);
        $discountEngine = $discount->get_engine();
        $validationCode = $discountEngine->validate($discount, $request);
        $discount->__set('validation_code', $validationCode);
        // حق دسترسی
        // CMS_Precondition::userCanAccessContent($request, $content);
        // اجرای درخواست
        return $discount;
    }
public static function getDiscountByCode($request, $code)
    {
        $discount = Discount_Shortcuts_GetDiscountByCodeOr404($code);
        $discountEngine = $discount->get_engine();
        $validationCode = $discountEngine->validate($discount, $request);
        $discount->__set('validation_code', $validationCode);
        // حق دسترسی
        // CMS_Precondition::userCanAccessContent($request, $content);
        // اجرای درخواست
        return $discount;
    }
public static function getDiscountByCode ( $ request , $ code ) { $ discount = Discount_Shortcuts_GetDiscountByCodeOr404 ( $ code ) ; $ discountEngine = $ discount -> get_engine ( ) ; $ validationCode = $ discountEngine -> validate ( $ discount , $ request ) ; $ discount -> __set ( 'validation_code' , $ validationCode ) ; // حق دسترسی // CMS_Precondition::userCanAccessContent($request, $content); // اجرای درخواست return $ discount ; }
Returns tag with given name.

@param Pluf_HTTP_Request $request
@param string $code
@return Discount_Discount
Returns tag with given name .