Version Notes
Dealer Inquiry
Download this release
Release Info
Developer | Capacity Web Solutions |
Extension | Dealer_Inquery |
Version | 2.1.2 |
Comparing to | |
See all releases |
Code changes from version 2.1.1 to 2.1.2
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Form.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Tab/Form.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Tabs.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Grid.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Renderer/Image.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Block/Inquiry.php +9 -8
- app/code/community/CapacityWebSolutions/Inquiry/Controller/Router.php +81 -0
- app/code/community/CapacityWebSolutions/Inquiry/Helper/Data.php +7 -8
- app/code/community/CapacityWebSolutions/Inquiry/Model/Inquiry.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Inquiryfiles.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiry.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiry/Collection.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiryfiles.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiryfiles/Collection.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/Observer.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/Model/System/Config/Source/Customergroup.php +1 -1
- app/code/community/CapacityWebSolutions/Inquiry/Model/System/Config/Source/Ownermail.php +1 -1
- app/code/community/CapacityWebSolutions/Inquiry/controllers/Adminhtml/InquiryController.php +5 -7
- app/code/community/CapacityWebSolutions/Inquiry/controllers/IndexController.php +44 -106
- app/code/community/CapacityWebSolutions/Inquiry/controllers/TestController.php +29 -0
- app/code/community/CapacityWebSolutions/Inquiry/etc/adminhtml.xml +46 -0
- app/code/community/CapacityWebSolutions/Inquiry/etc/config.xml +82 -113
- app/code/community/CapacityWebSolutions/Inquiry/etc/system.xml +40 -18
- app/design/adminhtml/default/default/layout/inquiry.xml +2 -2
- app/design/frontend/base/default/layout/inquiry.xml +0 -14
- app/design/frontend/base/default/template/inquiry/inquiry.phtml +51 -28
- app/design/frontend/base/default/template/inquiry/thanks.phtml +7 -7
- package.xml +5 -5
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry extends Mage_Adminhtml_Block_Widget_Grid_Container
|
11 |
{
|
12 |
public function __construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry extends Mage_Adminhtml_Block_Widget_Grid_Container
|
9 |
{
|
10 |
public function __construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
|
11 |
{
|
12 |
public function __construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit extends Mage_Adminhtml_Block_Widget_Form_Container
|
9 |
{
|
10 |
public function __construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Form.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
|
11 |
{
|
12 |
protected function _prepareForm()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Form extends Mage_Adminhtml_Block_Widget_Form
|
9 |
{
|
10 |
protected function _prepareForm()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Tab/Form.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
|
11 |
{
|
12 |
protected function _prepareForm()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Tab_Form extends Mage_Adminhtml_Block_Widget_Form
|
9 |
{
|
10 |
protected function _prepareForm()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Edit/Tabs.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
|
11 |
{
|
12 |
public function __construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Edit_Tabs extends Mage_Adminhtml_Block_Widget_Tabs
|
9 |
{
|
10 |
public function __construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Grid.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Grid extends Mage_Adminhtml_Block_Widget_Grid
|
11 |
{
|
12 |
public function __construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Grid extends Mage_Adminhtml_Block_Widget_Grid
|
9 |
{
|
10 |
public function __construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Adminhtml/Inquiry/Renderer/Image.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Renderer_Image extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract
|
11 |
{
|
12 |
public function render(Varien_Object $row)
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Adminhtml_Inquiry_Renderer_Image extends Mage_Adminhtml_Block_Widget_Grid_Column_Renderer_Abstract
|
9 |
{
|
10 |
public function render(Varien_Object $row)
|
app/code/community/CapacityWebSolutions/Inquiry/Block/Inquiry.php
CHANGED
@@ -1,18 +1,18 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Block_Inquiry extends Mage_Core_Block_Template
|
11 |
{
|
|
|
12 |
public function __construct()
|
13 |
{
|
14 |
//general settings
|
15 |
$this->setLinkEnabled((bool)Mage::getStoreConfig("inquiry/general/enable_toplink"));
|
|
|
16 |
$this->setLinkLabel(Mage::getStoreConfig("inquiry/general/toplink"));
|
17 |
$this->setHeading(trim(Mage::getStoreConfig('inquiry/general/heading')));
|
18 |
$this->setIndicates(trim(Mage::getStoreConfig('inquiry/general/indicates')));
|
@@ -74,11 +74,12 @@ class CapacityWebSolutions_Inquiry_Block_Inquiry extends Mage_Core_Block_Templat
|
|
74 |
public function addTopLinkStores()
|
75 |
{
|
76 |
$enable_link = $this->getLinkEnabled();
|
|
|
77 |
if($enable_link){
|
78 |
$label = trim($this->getLinkLabel());
|
79 |
$storeID = Mage::app()->getStore()->getId();
|
80 |
$toplinkBlock = $this->getParentBlock();
|
81 |
-
$toplinkBlock->addLink($this->__($label)
|
82 |
}
|
83 |
}
|
84 |
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Block_Inquiry extends Mage_Core_Block_Template
|
9 |
{
|
10 |
+
|
11 |
public function __construct()
|
12 |
{
|
13 |
//general settings
|
14 |
$this->setLinkEnabled((bool)Mage::getStoreConfig("inquiry/general/enable_toplink"));
|
15 |
+
$this->setUrlKey(trim(Mage::getStoreConfig("inquiry/general/url_key")));
|
16 |
$this->setLinkLabel(Mage::getStoreConfig("inquiry/general/toplink"));
|
17 |
$this->setHeading(trim(Mage::getStoreConfig('inquiry/general/heading')));
|
18 |
$this->setIndicates(trim(Mage::getStoreConfig('inquiry/general/indicates')));
|
74 |
public function addTopLinkStores()
|
75 |
{
|
76 |
$enable_link = $this->getLinkEnabled();
|
77 |
+
$url_key = $this->getUrlKey()?$this->getUrlKey():"inquiry";
|
78 |
if($enable_link){
|
79 |
$label = trim($this->getLinkLabel());
|
80 |
$storeID = Mage::app()->getStore()->getId();
|
81 |
$toplinkBlock = $this->getParentBlock();
|
82 |
+
$toplinkBlock->addLink($this->__($label),$url_key,$label,true,array(),90);
|
83 |
}
|
84 |
}
|
85 |
|
app/code/community/CapacityWebSolutions/Inquiry/Controller/Router.php
ADDED
@@ -0,0 +1,81 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
8 |
+
class CapacityWebSolutions_Inquiry_Controller_Router extends Mage_Core_Controller_Varien_Router_Abstract
|
9 |
+
{
|
10 |
+
const CUSTOM_URL_KEY = 'inquiry/general/url_key';
|
11 |
+
/**
|
12 |
+
* Initialize Controller Router
|
13 |
+
*
|
14 |
+
* @param Varien_Event_Observer $observer
|
15 |
+
*/
|
16 |
+
public function initControllerRouters($observer)
|
17 |
+
{
|
18 |
+
/* @var $front Mage_Core_Controller_Varien_Front */
|
19 |
+
$front = $observer->getEvent()->getFront();
|
20 |
+
$front->addRouter('inquiry', $this);//replace router_name with a suitable name
|
21 |
+
}
|
22 |
+
|
23 |
+
/**
|
24 |
+
* Validate and Match router with the Page and modify request
|
25 |
+
*
|
26 |
+
* @param Zend_Controller_Request_Http $request
|
27 |
+
* @return bool
|
28 |
+
*/
|
29 |
+
public function match(Zend_Controller_Request_Http $request)
|
30 |
+
{
|
31 |
+
if (!Mage::isInstalled()) {
|
32 |
+
Mage::app()->getFrontController()->getResponse()
|
33 |
+
->setRedirect(Mage::getUrl('install'))
|
34 |
+
->sendResponse();
|
35 |
+
exit;
|
36 |
+
}
|
37 |
+
|
38 |
+
$identifier = trim($request->getPathInfo(), "/");
|
39 |
+
|
40 |
+
$condition = new Varien_Object(array(
|
41 |
+
'identifier' => $identifier,
|
42 |
+
'continue' => true
|
43 |
+
));
|
44 |
+
Mage::dispatchEvent('inquiry_controller_router_match_before', array(
|
45 |
+
'router' => $this,
|
46 |
+
'condition' => $condition
|
47 |
+
));
|
48 |
+
|
49 |
+
$identifier = $condition->getIdentifier();
|
50 |
+
|
51 |
+
if ($condition->getRedirectUrl()) {
|
52 |
+
Mage::app()->getFrontController()->getResponse()
|
53 |
+
->setRedirect($condition->getRedirectUrl())
|
54 |
+
->sendResponse();
|
55 |
+
$request->setDispatched(true);
|
56 |
+
return true;
|
57 |
+
}
|
58 |
+
|
59 |
+
if (!$condition->getContinue()) {
|
60 |
+
return false;
|
61 |
+
}
|
62 |
+
|
63 |
+
|
64 |
+
$custom_url = Mage::getStoreConfig(self::CUSTOM_URL_KEY);
|
65 |
+
|
66 |
+
if($identifier==$custom_url){
|
67 |
+
$request->setModuleName('inquiry')// replace modulename with the frontname of the router of your controller
|
68 |
+
->setControllerName('index')// replace index with your controller name
|
69 |
+
->setActionName('index'); // replace index with your action name
|
70 |
+
}else{
|
71 |
+
$request->setModuleName('inquiry')
|
72 |
+
->setControllerName('index')
|
73 |
+
->setActionName('noroute');
|
74 |
+
|
75 |
+
}
|
76 |
+
|
77 |
+
$request->setAlias(Mage_Core_Model_Url_Rewrite::REWRITE_REQUEST_PATH_ALIAS,$identifier);
|
78 |
+
|
79 |
+
return true;
|
80 |
+
}
|
81 |
+
}
|
app/code/community/CapacityWebSolutions/Inquiry/Helper/Data.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Helper_Data extends Mage_Core_Helper_Abstract
|
11 |
{
|
12 |
public function updateDetails(){
|
@@ -77,7 +75,7 @@ class CapacityWebSolutions_Inquiry_Helper_Data extends Mage_Core_Helper_Abstract
|
|
77 |
foreach($files as $file) {
|
78 |
unlink($file);
|
79 |
}
|
80 |
-
|
81 |
if (!file_exists($path)) {
|
82 |
mkdir($path, 0777, true);
|
83 |
}
|
@@ -85,6 +83,7 @@ class CapacityWebSolutions_Inquiry_Helper_Data extends Mage_Core_Helper_Abstract
|
|
85 |
$random = rand();
|
86 |
$image_name = "captcha-".$random.".jpeg";
|
87 |
imagepng($image, $path.DS.$image_name);
|
|
|
88 |
return $image_name;
|
89 |
}
|
90 |
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Helper_Data extends Mage_Core_Helper_Abstract
|
9 |
{
|
10 |
public function updateDetails(){
|
75 |
foreach($files as $file) {
|
76 |
unlink($file);
|
77 |
}
|
78 |
+
|
79 |
if (!file_exists($path)) {
|
80 |
mkdir($path, 0777, true);
|
81 |
}
|
83 |
$random = rand();
|
84 |
$image_name = "captcha-".$random.".jpeg";
|
85 |
imagepng($image, $path.DS.$image_name);
|
86 |
+
|
87 |
return $image_name;
|
88 |
}
|
89 |
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Inquiry.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Inquiry extends Mage_Core_Model_Abstract
|
11 |
{
|
12 |
public function _construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Inquiry extends Mage_Core_Model_Abstract
|
9 |
{
|
10 |
public function _construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Inquiryfiles.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Inquiryfiles extends Mage_Core_Model_Abstract
|
11 |
{
|
12 |
public function _construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Inquiryfiles extends Mage_Core_Model_Abstract
|
9 |
{
|
10 |
public function _construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiry.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiry extends Mage_Core_Model_Mysql4_Abstract
|
11 |
{
|
12 |
public function _construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiry extends Mage_Core_Model_Mysql4_Abstract
|
9 |
{
|
10 |
public function _construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiry/Collection.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiry_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
11 |
{
|
12 |
public function _construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiry_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
9 |
{
|
10 |
public function _construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiryfiles.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiryfiles extends Mage_Core_Model_Mysql4_Abstract
|
10 |
{
|
11 |
public function _construct()
|
12 |
{
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiryfiles extends Mage_Core_Model_Mysql4_Abstract
|
|
|
|
|
8 |
{
|
9 |
public function _construct()
|
10 |
{
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Mysql4/Inquiryfiles/Collection.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiryfiles_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
11 |
{
|
12 |
public function _construct()
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Mysql4_Inquiryfiles_Collection extends Mage_Core_Model_Mysql4_Collection_Abstract
|
9 |
{
|
10 |
public function _construct()
|
app/code/community/CapacityWebSolutions/Inquiry/Model/Observer.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Model_Observer
|
11 |
{
|
12 |
public function updateStatusAfterDeleteCustomer($observer)
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Model_Observer
|
9 |
{
|
10 |
public function updateStatusAfterDeleteCustomer($observer)
|
app/code/community/CapacityWebSolutions/Inquiry/Model/System/Config/Source/Customergroup.php
CHANGED
@@ -1 +1 @@
|
|
1 |
-
<?php
|
2 |
{
|
3 |
return Mage::helper('customer')->getGroups()->toOptionArray();
|
4 |
}
|
|
|
5 |
Extension Name : Dealer Inquiry
|
6 |
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
7 |
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
8 |
Support Email : support@magebees.com
|
9 |
***************************************************************************/
|
10 |
{
|
11 |
return Mage::helper('customer')->getGroups()->toOptionArray();
|
12 |
}
|
|
|
1 |
{
|
2 |
return Mage::helper('customer')->getGroups()->toOptionArray();
|
3 |
}
|
4 |
+
<?php
|
5 |
Extension Name : Dealer Inquiry
|
6 |
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
7 |
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
8 |
Support Email : support@magebees.com
|
9 |
***************************************************************************/
|
10 |
{
|
11 |
return Mage::helper('customer')->getGroups()->toOptionArray();
|
12 |
}
|
app/code/community/CapacityWebSolutions/Inquiry/Model/System/Config/Source/Ownermail.php
CHANGED
@@ -1 +1 @@
|
|
1 |
-
<?php
|
2 |
{
|
3 |
}
|
|
|
4 |
Extension Name : Dealer Inquiry
|
5 |
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
6 |
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
7 |
Support Email : support@magebees.com
|
8 |
***************************************************************************/
|
9 |
{
|
10 |
}
|
|
|
1 |
{
|
2 |
}
|
3 |
+
<?php
|
4 |
Extension Name : Dealer Inquiry
|
5 |
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
6 |
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
7 |
Support Email : support@magebees.com
|
8 |
***************************************************************************/
|
9 |
{
|
10 |
}
|
app/code/community/CapacityWebSolutions/Inquiry/controllers/Adminhtml/InquiryController.php
CHANGED
@@ -1,12 +1,10 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_Adminhtml_InquiryController extends Mage_Adminhtml_Controller_action
|
11 |
{
|
12 |
const EMAIL_TEMPLATE_XML_PATH = 'inquiry/create_account/email_template';
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_Adminhtml_InquiryController extends Mage_Adminhtml_Controller_action
|
9 |
{
|
10 |
const EMAIL_TEMPLATE_XML_PATH = 'inquiry/create_account/email_template';
|
app/code/community/CapacityWebSolutions/Inquiry/controllers/IndexController.php
CHANGED
@@ -1,23 +1,27 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
-
|
10 |
class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_Front_Action
|
11 |
{
|
12 |
const OWNER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/admin_email/email_template';
|
13 |
const CUSTOMER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/customer_email/email_template';
|
14 |
const INQUIRY_FORM_TITLE = 'inquiry/general/page_title';
|
|
|
|
|
15 |
|
16 |
public function indexAction() {
|
17 |
$title = Mage::getStoreConfig(self::INQUIRY_FORM_TITLE);
|
18 |
-
|
19 |
$page_layout = Mage::helper("inquiry")->getDealerPageLayout();
|
20 |
$this->loadLayout()->getLayout()->getBlock('root')->setTemplate('page/'.$page_layout);
|
|
|
|
|
|
|
|
|
21 |
$this->renderLayout();
|
22 |
Mage::getSingleton('core/session')->setInquiryFormData(false);
|
23 |
}
|
@@ -29,11 +33,11 @@ class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_
|
|
29 |
|
30 |
$captcha = $this->getRequest()->getParam("captcha");
|
31 |
$captcha_code = Mage::getSingleton('core/session')->getCaptcha();
|
32 |
-
if(!empty($captcha) && $captcha != $captcha_code)
|
33 |
-
{
|
34 |
Mage::getSingleton('core/session')->addError(Mage::helper('inquiry')->__('Captcha code does not match!'));
|
35 |
Mage::getSingleton('core/session')->setInquiryFormData($data);
|
36 |
-
|
|
|
37 |
}
|
38 |
$storeid = Mage::app()->getStore()->getStoreId();
|
39 |
$websiteid = Mage::app()->getWebsite()->getId();
|
@@ -89,7 +93,8 @@ class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_
|
|
89 |
}catch (Exception $e) {
|
90 |
$data['file'] = '';
|
91 |
Mage::getSingleton('core/session')->addError($e->getMessage());
|
92 |
-
|
|
|
93 |
}
|
94 |
}
|
95 |
}
|
@@ -103,10 +108,15 @@ class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_
|
|
103 |
{
|
104 |
Mage::getSingleton('core/session')->addError(Mage::helper('inquiry')->__('Email id already exits !'));
|
105 |
Mage::getSingleton('core/session')->setInquiryFormData($data);
|
106 |
-
|
|
|
107 |
}
|
108 |
}
|
109 |
-
|
|
|
|
|
|
|
|
|
110 |
}
|
111 |
|
112 |
public function sendOwnerMail($data){
|
@@ -180,126 +190,54 @@ class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_
|
|
180 |
}
|
181 |
|
182 |
//labels
|
183 |
-
|
184 |
-
$emailTemplateVariables['firstname_label'] = $config_change_label['f_name'];
|
185 |
-
}else {
|
186 |
-
$emailTemplateVariables['firstname_label'] = "First Name";
|
187 |
-
}
|
188 |
|
189 |
-
|
190 |
-
$emailTemplateVariables['lastname_label'] = $config_change_label['l_name'];
|
191 |
-
}else {
|
192 |
-
$emailTemplateVariables['lastname_label'] = "Last Name";
|
193 |
-
}
|
194 |
|
195 |
-
|
196 |
-
$emailTemplateVariables['company_label'] = $config_change_label['company_name'];
|
197 |
-
}else{
|
198 |
-
$emailTemplateVariables['company_label'] = "Company Name";
|
199 |
-
}
|
200 |
|
201 |
-
|
202 |
-
|
203 |
-
|
204 |
-
$emailTemplateVariables['vat_number_label'] = "TAX/VAT Number";
|
205 |
-
}
|
206 |
-
|
207 |
-
if($config_change_label['address']){
|
208 |
-
$emailTemplateVariables['address_label'] = $config_change_label['address'];
|
209 |
-
}else{
|
210 |
-
$emailTemplateVariables['address_label'] = "Address";
|
211 |
-
}
|
212 |
|
213 |
-
|
214 |
-
$emailTemplateVariables['city_label'] = $config_change_label['city'];
|
215 |
-
}else{
|
216 |
-
$emailTemplateVariables['city_label'] = "City";
|
217 |
-
}
|
218 |
|
219 |
-
|
220 |
-
$emailTemplateVariables['state_label'] = $config_change_label['state'];
|
221 |
-
}else{
|
222 |
-
$emailTemplateVariables['state_label'] = "State/Province";
|
223 |
-
}
|
224 |
|
225 |
-
|
226 |
-
$emailTemplateVariables['country_label'] = $config_change_label['country'];
|
227 |
-
}else{
|
228 |
-
$emailTemplateVariables['country_label'] = "Country";
|
229 |
-
}
|
230 |
|
231 |
-
|
232 |
-
$emailTemplateVariables['zip_label'] = $config_change_label['postal_code'];
|
233 |
-
}else{
|
234 |
-
$emailTemplateVariables['zip_label'] = "ZIP/Postal Code";
|
235 |
-
}
|
236 |
|
237 |
-
|
238 |
-
$emailTemplateVariables['phone_label'] = $config_change_label['contact_number'];
|
239 |
-
}else{
|
240 |
-
$emailTemplateVariables['phone_label'] = "Contact Number";
|
241 |
-
}
|
242 |
|
243 |
-
|
244 |
-
$emailTemplateVariables['email_label'] = $config_change_label['email'];
|
245 |
-
}else{
|
246 |
-
$emailTemplateVariables['email_label'] = "Email";
|
247 |
-
}
|
248 |
|
249 |
if(!empty($data['website'])){
|
250 |
-
|
251 |
-
$emailTemplateVariables['website_label'] = $config_change_label['website'];
|
252 |
-
}else{
|
253 |
-
$emailTemplateVariables['website_label'] = "Website";
|
254 |
-
}
|
255 |
}
|
256 |
|
257 |
if(!empty($data['desc'])){
|
258 |
-
|
259 |
-
$emailTemplateVariables['description_label'] = $config_change_label['description'];
|
260 |
-
}else{
|
261 |
-
$emailTemplateVariables['description_label'] = "Business Description";
|
262 |
-
}
|
263 |
}
|
264 |
|
265 |
if(!empty($data['date_time'])){
|
266 |
-
|
267 |
-
$emailTemplateVariables['datetime_label'] = $config_change_label['datetime'];
|
268 |
-
}else{
|
269 |
-
$emailTemplateVariables['datetime_label'] = "Date Time";
|
270 |
-
}
|
271 |
}
|
272 |
|
273 |
if(!empty($data['file'])){
|
274 |
-
|
275 |
-
$emailTemplateVariables['upload_file_label'] = $config_change_label['upload_file'];
|
276 |
-
}else{
|
277 |
-
$emailTemplateVariables['upload_file_label'] = "Uploaded File(s)";
|
278 |
-
}
|
279 |
}
|
280 |
|
281 |
if(!empty($data['extra_field_one'])){
|
282 |
-
|
283 |
-
$emailTemplateVariables['extra_field_one_label'] = $config_change_label['extra_field_one'];
|
284 |
-
}else{
|
285 |
-
$emailTemplateVariables['extra_field_one_label'] = "Extra Field 2";
|
286 |
-
}
|
287 |
}
|
288 |
|
289 |
if(!empty($data['extra_field_two'])){
|
290 |
-
|
291 |
-
$emailTemplateVariables['extra_field_two_label'] = $config_change_label['extra_field_two'];
|
292 |
-
}else{
|
293 |
-
$emailTemplateVariables['extra_field_two_label'] = "Extra Field 2";
|
294 |
-
}
|
295 |
}
|
296 |
|
297 |
if(!empty($data['extra_field_three'])){
|
298 |
-
|
299 |
-
$emailTemplateVariables['extra_field_three_label'] = $config_change_label['extra_field_three'];
|
300 |
-
}else{
|
301 |
-
$emailTemplateVariables['extra_field_three_label'] = "Extra Field 3";
|
302 |
-
}
|
303 |
}
|
304 |
|
305 |
//load the custom template to the email
|
@@ -356,4 +294,4 @@ class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_
|
|
356 |
}
|
357 |
|
358 |
}
|
359 |
-
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
|
|
8 |
class CapacityWebSolutions_Inquiry_IndexController extends Mage_Core_Controller_Front_Action
|
9 |
{
|
10 |
const OWNER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/admin_email/email_template';
|
11 |
const CUSTOMER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/customer_email/email_template';
|
12 |
const INQUIRY_FORM_TITLE = 'inquiry/general/page_title';
|
13 |
+
const INQUIRY_META_DESC = 'inquiry/general/meta_description';
|
14 |
+
const INQUIRY_META_KEYWORDS = 'inquiry/general/meta_keywords';
|
15 |
|
16 |
public function indexAction() {
|
17 |
$title = Mage::getStoreConfig(self::INQUIRY_FORM_TITLE);
|
18 |
+
//$this->_title($this->__($title));
|
19 |
$page_layout = Mage::helper("inquiry")->getDealerPageLayout();
|
20 |
$this->loadLayout()->getLayout()->getBlock('root')->setTemplate('page/'.$page_layout);
|
21 |
+
//set meta data
|
22 |
+
$this->getLayout()->getBlock('head')->setTitle($this->__($title));
|
23 |
+
$this->getLayout()->getBlock('head')->setDescription($this->__(Mage::getStoreConfig(self::INQUIRY_META_DESC)));
|
24 |
+
$this->getLayout()->getBlock('head')->setKeywords($this->__(Mage::getStoreConfig(self::INQUIRY_META_KEYWORDS)));
|
25 |
$this->renderLayout();
|
26 |
Mage::getSingleton('core/session')->setInquiryFormData(false);
|
27 |
}
|
33 |
|
34 |
$captcha = $this->getRequest()->getParam("captcha");
|
35 |
$captcha_code = Mage::getSingleton('core/session')->getCaptcha();
|
36 |
+
if(!empty($captcha) && $captcha != $captcha_code) {
|
|
|
37 |
Mage::getSingleton('core/session')->addError(Mage::helper('inquiry')->__('Captcha code does not match!'));
|
38 |
Mage::getSingleton('core/session')->setInquiryFormData($data);
|
39 |
+
//$this->_redirect('*/*/');return;
|
40 |
+
$this->_redirectReferer();return;
|
41 |
}
|
42 |
$storeid = Mage::app()->getStore()->getStoreId();
|
43 |
$websiteid = Mage::app()->getWebsite()->getId();
|
93 |
}catch (Exception $e) {
|
94 |
$data['file'] = '';
|
95 |
Mage::getSingleton('core/session')->addError($e->getMessage());
|
96 |
+
//$this->_redirect('*/*/');return;
|
97 |
+
$this->_redirectReferer();return;
|
98 |
}
|
99 |
}
|
100 |
}
|
108 |
{
|
109 |
Mage::getSingleton('core/session')->addError(Mage::helper('inquiry')->__('Email id already exits !'));
|
110 |
Mage::getSingleton('core/session')->setInquiryFormData($data);
|
111 |
+
//$this->_redirect('*/*/');return;
|
112 |
+
$this->_redirectReferer();return;
|
113 |
}
|
114 |
}
|
115 |
+
//$this->_redirect('*/*/success');
|
116 |
+
$success_des = Mage::getStoreConfig('inquiry/general/success_des');
|
117 |
+
Mage::getSingleton('core/session')->addSuccess(Mage::helper('inquiry')->__($success_des));
|
118 |
+
$this->_redirectReferer();
|
119 |
+
return;
|
120 |
}
|
121 |
|
122 |
public function sendOwnerMail($data){
|
190 |
}
|
191 |
|
192 |
//labels
|
193 |
+
$emailTemplateVariables['firstname_label'] = $config_change_label['f_name']?$config_change_label['f_name']:"First Name";
|
|
|
|
|
|
|
|
|
194 |
|
195 |
+
$emailTemplateVariables['lastname_label'] = $config_change_label['l_name']?$config_change_label['l_name']:"Last Name";
|
|
|
|
|
|
|
|
|
196 |
|
197 |
+
$emailTemplateVariables['company_label'] = $config_change_label['company_name']?$config_change_label['company_name']:"Company Name";
|
|
|
|
|
|
|
|
|
198 |
|
199 |
+
$emailTemplateVariables['vat_number_label'] = $config_change_label['vat_number']?$config_change_label['vat_number']:"TAX/VAT Number";
|
200 |
+
|
201 |
+
$emailTemplateVariables['address_label'] = $config_change_label['address']?$config_change_label['address']:"Address";
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
202 |
|
203 |
+
$emailTemplateVariables['city_label'] = $config_change_label['city']?$config_change_label['city']:"City";
|
|
|
|
|
|
|
|
|
204 |
|
205 |
+
$emailTemplateVariables['state_label'] = $config_change_label['state']?$config_change_label['state']:"State/Province";
|
|
|
|
|
|
|
|
|
206 |
|
207 |
+
$emailTemplateVariables['country_label'] = $config_change_label['country']?$config_change_label['country']:"Country";
|
|
|
|
|
|
|
|
|
208 |
|
209 |
+
$emailTemplateVariables['zip_label'] = $config_change_label['postal_code']?$config_change_label['postal_code']:"ZIP/Postal Code";
|
|
|
|
|
|
|
|
|
210 |
|
211 |
+
$emailTemplateVariables['phone_label'] = $config_change_label['contact_number']?$config_change_label['contact_number']:"Contact Number";
|
|
|
|
|
|
|
|
|
212 |
|
213 |
+
$emailTemplateVariables['email_label'] = $config_change_label['email']?$config_change_label['email']:"Email";
|
|
|
|
|
|
|
|
|
214 |
|
215 |
if(!empty($data['website'])){
|
216 |
+
$emailTemplateVariables['website_label'] = $config_change_label['website']?$config_change_label['website']:"Website";
|
|
|
|
|
|
|
|
|
217 |
}
|
218 |
|
219 |
if(!empty($data['desc'])){
|
220 |
+
$emailTemplateVariables['description_label'] = $config_change_label['description']?$config_change_label['description']:"Business Description";
|
|
|
|
|
|
|
|
|
221 |
}
|
222 |
|
223 |
if(!empty($data['date_time'])){
|
224 |
+
$emailTemplateVariables['datetime_label'] = $config_change_label['datetime']?$config_change_label['datetime']:"Date Time";
|
|
|
|
|
|
|
|
|
225 |
}
|
226 |
|
227 |
if(!empty($data['file'])){
|
228 |
+
$emailTemplateVariables['upload_file_label'] = $config_change_label['upload_file']?$config_change_label['upload_file']:"Uploaded File(s)";
|
|
|
|
|
|
|
|
|
229 |
}
|
230 |
|
231 |
if(!empty($data['extra_field_one'])){
|
232 |
+
$emailTemplateVariables['extra_field_one_label'] = $config_change_label['extra_field_one']?$config_change_label['extra_field_one']:"Extra Field 2";
|
|
|
|
|
|
|
|
|
233 |
}
|
234 |
|
235 |
if(!empty($data['extra_field_two'])){
|
236 |
+
$emailTemplateVariables['extra_field_two_label'] = $config_change_label['extra_field_two']?$config_change_label['extra_field_two']:"Extra Field 2";
|
|
|
|
|
|
|
|
|
237 |
}
|
238 |
|
239 |
if(!empty($data['extra_field_three'])){
|
240 |
+
$emailTemplateVariables['extra_field_three_label'] = $config_change_label['extra_field_three']?$config_change_label['extra_field_three']:"Extra Field 3";
|
|
|
|
|
|
|
|
|
241 |
}
|
242 |
|
243 |
//load the custom template to the email
|
294 |
}
|
295 |
|
296 |
}
|
297 |
+
|
app/code/community/CapacityWebSolutions/Inquiry/controllers/TestController.php
ADDED
@@ -0,0 +1,29 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?php
|
2 |
+
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
8 |
+
class CapacityWebSolutions_Inquiry_TestController extends Mage_Core_Controller_Front_Action
|
9 |
+
{
|
10 |
+
const OWNER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/admin_email/email_template';
|
11 |
+
const CUSTOMER_EMAIL_TEMPLATE_XML_PATH = 'inquiry/customer_email/email_template';
|
12 |
+
const INQUIRY_FORM_TITLE = 'inquiry/general/page_title';
|
13 |
+
const INQUIRY_META_DESC = 'inquiry/general/meta_description';
|
14 |
+
const INQUIRY_META_KEYWORDS = 'inquiry/general/meta_keywords';
|
15 |
+
|
16 |
+
|
17 |
+
public function successAction(){
|
18 |
+
$title = Mage::getStoreConfig(self::INQUIRY_FORM_TITLE);
|
19 |
+
$this->_title($this->__($title));
|
20 |
+
//$this->loadLayout(array('default'));
|
21 |
+
$page_layout = Mage::helper("inquiry")->getDealerPageLayout();
|
22 |
+
$this->loadLayout()->getLayout()->getBlock('root')->setTemplate('page/'.$page_layout);
|
23 |
+
$this->renderLayout();
|
24 |
+
}
|
25 |
+
|
26 |
+
|
27 |
+
|
28 |
+
}
|
29 |
+
|
app/code/community/CapacityWebSolutions/Inquiry/etc/adminhtml.xml
ADDED
@@ -0,0 +1,46 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
1 |
+
<?xml version="1.0"?>
|
2 |
+
<config>
|
3 |
+
<menu>
|
4 |
+
<cws module="inquiry">
|
5 |
+
<title>MageBees</title>
|
6 |
+
<sort_order>70</sort_order>
|
7 |
+
<children>
|
8 |
+
<inquiry module="inquiry">
|
9 |
+
<title>Dealer Inquiries</title>
|
10 |
+
<sort_order>71</sort_order>
|
11 |
+
<children>
|
12 |
+
<items module="inquiry">
|
13 |
+
<title>Dealer Management</title>
|
14 |
+
<sort_order>0</sort_order>
|
15 |
+
<action>adminhtml/inquiry/index</action>
|
16 |
+
</items>
|
17 |
+
<dealer_settings module="inquiry">
|
18 |
+
<title>Settings</title>
|
19 |
+
<sort_order>10</sort_order>
|
20 |
+
<action>adminhtml/system_config/edit/section/inquiry</action>
|
21 |
+
</dealer_settings>
|
22 |
+
</children>
|
23 |
+
</inquiry>
|
24 |
+
</children>
|
25 |
+
</cws>
|
26 |
+
</menu>
|
27 |
+
<acl>
|
28 |
+
<resources>
|
29 |
+
<admin>
|
30 |
+
<children>
|
31 |
+
<system>
|
32 |
+
<children>
|
33 |
+
<config>
|
34 |
+
<children>
|
35 |
+
<inquiry>
|
36 |
+
<title>Inquiry</title>
|
37 |
+
</inquiry>
|
38 |
+
</children>
|
39 |
+
</config>
|
40 |
+
</children>
|
41 |
+
</system>
|
42 |
+
</children>
|
43 |
+
</admin>
|
44 |
+
</resources>
|
45 |
+
</acl>
|
46 |
+
</config>
|
app/code/community/CapacityWebSolutions/Inquiry/etc/config.xml
CHANGED
@@ -2,9 +2,9 @@
|
|
2 |
<config>
|
3 |
<modules>
|
4 |
<CapacityWebSolutions_Inquiry>
|
5 |
-
<version>2.1.
|
6 |
</CapacityWebSolutions_Inquiry>
|
7 |
-
|
8 |
<global>
|
9 |
<blocks>
|
10 |
<inquiry>
|
@@ -18,56 +18,56 @@
|
|
18 |
</inquiry>
|
19 |
<inquiry_mysql4>
|
20 |
<class>CapacityWebSolutions_Inquiry_Model_Mysql4</class>
|
21 |
-
|
22 |
-
|
23 |
-
|
24 |
-
|
25 |
-
|
26 |
-
|
27 |
-
|
28 |
-
|
29 |
</inquiry_mysql4>
|
30 |
</models>
|
31 |
<resources>
|
32 |
-
|
33 |
-
|
34 |
-
|
35 |
-
|
36 |
-
|
37 |
-
|
38 |
-
|
39 |
-
|
40 |
-
|
41 |
-
|
42 |
-
|
43 |
-
|
44 |
-
|
45 |
-
|
46 |
-
|
47 |
-
|
48 |
-
|
49 |
-
|
50 |
-
|
51 |
<template>
|
52 |
<email>
|
53 |
-
<inquiry_admin_email_email_template
|
54 |
-
<label>Dealer
|
55 |
<file>inquiry/admin_inquiry.html</file>
|
56 |
<type>html</type>
|
57 |
</inquiry_admin_email_email_template>
|
58 |
<inquiry_customer_email_email_template translate="label" module="inquiry">
|
59 |
-
<label>Dealer
|
60 |
<file>inquiry/customer_inquiry.html</file>
|
61 |
<type>html</type>
|
62 |
</inquiry_customer_email_email_template>
|
63 |
<inquiry_create_account_email_template translate="label" module="inquiry">
|
64 |
-
|
65 |
-
|
66 |
-
|
67 |
-
|
68 |
</email>
|
69 |
</template>
|
70 |
-
<helpers>
|
71 |
<inquiry>
|
72 |
<class>CapacityWebSolutions_Inquiry_Helper</class>
|
73 |
</inquiry>
|
@@ -81,19 +81,29 @@
|
|
81 |
<use>core_setup</use>
|
82 |
</connection>
|
83 |
</inquiry_setup>
|
84 |
-
</resources>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
85 |
</global>
|
86 |
<admin>
|
87 |
<routers>
|
88 |
-
|
89 |
-
|
90 |
-
|
91 |
-
|
92 |
-
|
93 |
-
|
94 |
-
|
95 |
</routers>
|
96 |
-
|
97 |
<frontend>
|
98 |
<routers>
|
99 |
<inquiry>
|
@@ -112,89 +122,48 @@
|
|
112 |
</updates>
|
113 |
</layout>
|
114 |
</frontend>
|
115 |
-
|
116 |
-
<events>
|
117 |
<customer_delete_commit_after>
|
118 |
-
|
119 |
-
|
120 |
-
|
121 |
-
|
122 |
-
|
123 |
-
|
124 |
-
|
125 |
-
|
126 |
<adminhtml_customer_save_after>
|
127 |
<observers>
|
128 |
-
|
129 |
-
|
130 |
-
|
131 |
-
|
132 |
-
|
133 |
-
|
134 |
</adminhtml_customer_save_after>
|
135 |
-
|
136 |
-
<
|
137 |
-
<
|
138 |
-
<
|
139 |
-
<sort_order>70</sort_order>
|
140 |
-
<children>
|
141 |
-
<inquiry module="inquiry">
|
142 |
-
<title>Dealer Inquiries</title>
|
143 |
-
<sort_order>71</sort_order>
|
144 |
-
<children>
|
145 |
-
<items module="inquiry">
|
146 |
-
<title>Dealer Management</title>
|
147 |
-
<sort_order>0</sort_order>
|
148 |
-
<action>inquiry/adminhtml_inquiry/index</action>
|
149 |
-
</items>
|
150 |
-
<dealer_settings module="inquiry">
|
151 |
-
<title>Settings</title>
|
152 |
-
<sort_order>10</sort_order>
|
153 |
-
<action>adminhtml/system_config/edit/section/inquiry</action>
|
154 |
-
</dealer_settings>
|
155 |
-
</children>
|
156 |
-
</inquiry>
|
157 |
-
</children>
|
158 |
-
</cws>
|
159 |
-
</menu>
|
160 |
-
<layout>
|
161 |
-
<updates>
|
162 |
-
<inquiry>
|
163 |
<file>inquiry.xml</file>
|
164 |
-
|
165 |
-
|
166 |
-
|
167 |
-
<acl>
|
168 |
-
<resources>
|
169 |
-
<admin>
|
170 |
-
<children>
|
171 |
-
<system>
|
172 |
-
<children>
|
173 |
-
<config>
|
174 |
-
<children>
|
175 |
-
<inquiry>
|
176 |
-
<title>Inquiry</title>
|
177 |
-
</inquiry>
|
178 |
-
</children>
|
179 |
-
</config>
|
180 |
-
</children>
|
181 |
-
</system>
|
182 |
-
</children>
|
183 |
-
</admin>
|
184 |
-
</resources>
|
185 |
-
</acl>
|
186 |
</adminhtml>
|
187 |
<default>
|
188 |
<inquiry>
|
189 |
<general>
|
190 |
<enabled>1</enabled>
|
|
|
191 |
<enable_toplink>1</enable_toplink>
|
192 |
<heading>Dealer Inquiry</heading>
|
193 |
<page_layout>one_column</page_layout>
|
194 |
<page_title>Dealer Inquiry</page_title>
|
|
|
|
|
195 |
<toplink>Dealer Inquiry</toplink>
|
196 |
<description>Write description here and it will display after Title.</description>
|
197 |
-
<success_tital>Thank You.</success_tital>
|
198 |
<success_des>Thank you for contacting us.</success_des>
|
199 |
<btn_text>Submit</btn_text>
|
200 |
<indicates>Indicates Required.</indicates>
|
2 |
<config>
|
3 |
<modules>
|
4 |
<CapacityWebSolutions_Inquiry>
|
5 |
+
<version>2.1.2</version>
|
6 |
</CapacityWebSolutions_Inquiry>
|
7 |
+
</modules>
|
8 |
<global>
|
9 |
<blocks>
|
10 |
<inquiry>
|
18 |
</inquiry>
|
19 |
<inquiry_mysql4>
|
20 |
<class>CapacityWebSolutions_Inquiry_Model_Mysql4</class>
|
21 |
+
<entities>
|
22 |
+
<inquiry>
|
23 |
+
<table>dealerinquiry</table>
|
24 |
+
</inquiry>
|
25 |
+
<inquiryfiles>
|
26 |
+
<table>dealerinquiry_files</table>
|
27 |
+
</inquiryfiles>
|
28 |
+
</entities>
|
29 |
</inquiry_mysql4>
|
30 |
</models>
|
31 |
<resources>
|
32 |
+
<inquiry_setup>
|
33 |
+
<setup>
|
34 |
+
<module>CapacityWebSolutions_Inquiry</module>
|
35 |
+
</setup>
|
36 |
+
<connection>
|
37 |
+
<use>core_setup</use>
|
38 |
+
</connection>
|
39 |
+
</inquiry_setup>
|
40 |
+
<inquiry_write>
|
41 |
+
<connection>
|
42 |
+
<use>core_write</use>
|
43 |
+
</connection>
|
44 |
+
</inquiry_write>
|
45 |
+
<inquiry_read>
|
46 |
+
<connection>
|
47 |
+
<use>core_read</use>
|
48 |
+
</connection>
|
49 |
+
</inquiry_read>
|
50 |
+
</resources>
|
51 |
<template>
|
52 |
<email>
|
53 |
+
<inquiry_admin_email_email_template translate="label" module="inquiry">
|
54 |
+
<label>Dealer Inquiry-Admin Email</label>
|
55 |
<file>inquiry/admin_inquiry.html</file>
|
56 |
<type>html</type>
|
57 |
</inquiry_admin_email_email_template>
|
58 |
<inquiry_customer_email_email_template translate="label" module="inquiry">
|
59 |
+
<label>Dealer Inquiry-Customer Submit Form Email</label>
|
60 |
<file>inquiry/customer_inquiry.html</file>
|
61 |
<type>html</type>
|
62 |
</inquiry_customer_email_email_template>
|
63 |
<inquiry_create_account_email_template translate="label" module="inquiry">
|
64 |
+
<label>Dealer Inquiry-Create Customer Email</label>
|
65 |
+
<file>inquiry/create_customer.html</file>
|
66 |
+
<type>html</type>
|
67 |
+
</inquiry_create_account_email_template>
|
68 |
</email>
|
69 |
</template>
|
70 |
+
<helpers>
|
71 |
<inquiry>
|
72 |
<class>CapacityWebSolutions_Inquiry_Helper</class>
|
73 |
</inquiry>
|
81 |
<use>core_setup</use>
|
82 |
</connection>
|
83 |
</inquiry_setup>
|
84 |
+
</resources>
|
85 |
+
<events>
|
86 |
+
<controller_front_init_routers>
|
87 |
+
<observers>
|
88 |
+
<inquiry_router>
|
89 |
+
<class>CapacityWebSolutions_Inquiry_Controller_Router</class>
|
90 |
+
<method>initControllerRouters</method>
|
91 |
+
</inquiry_router>
|
92 |
+
</observers>
|
93 |
+
</controller_front_init_routers>
|
94 |
+
</events>
|
95 |
</global>
|
96 |
<admin>
|
97 |
<routers>
|
98 |
+
<adminhtml>
|
99 |
+
<args>
|
100 |
+
<modules>
|
101 |
+
<inquiry after="Mage_Adminhtml">CapacityWebSolutions_Inquiry_Adminhtml</inquiry>
|
102 |
+
</modules>
|
103 |
+
</args>
|
104 |
+
</adminhtml>
|
105 |
</routers>
|
106 |
+
</admin>
|
107 |
<frontend>
|
108 |
<routers>
|
109 |
<inquiry>
|
122 |
</updates>
|
123 |
</layout>
|
124 |
</frontend>
|
125 |
+
<adminhtml>
|
126 |
+
<events>
|
127 |
<customer_delete_commit_after>
|
128 |
+
<observers>
|
129 |
+
<inquiry>
|
130 |
+
<type>singleton</type>
|
131 |
+
<class>inquiry/observer</class>
|
132 |
+
<method>updateStatusAfterDeleteCustomer</method>
|
133 |
+
</inquiry>
|
134 |
+
</observers>
|
135 |
+
</customer_delete_commit_after>
|
136 |
<adminhtml_customer_save_after>
|
137 |
<observers>
|
138 |
+
<inquiry_create>
|
139 |
+
<type>singleton</type>
|
140 |
+
<class>inquiry/observer</class>
|
141 |
+
<method>updateStatusAfterCreateCustomer</method>
|
142 |
+
</inquiry_create>
|
143 |
+
</observers>
|
144 |
</adminhtml_customer_save_after>
|
145 |
+
</events>
|
146 |
+
<layout>
|
147 |
+
<updates>
|
148 |
+
<inquiry>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
149 |
<file>inquiry.xml</file>
|
150 |
+
</inquiry>
|
151 |
+
</updates>
|
152 |
+
</layout>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
153 |
</adminhtml>
|
154 |
<default>
|
155 |
<inquiry>
|
156 |
<general>
|
157 |
<enabled>1</enabled>
|
158 |
+
<url_key>inquiry</url_key>
|
159 |
<enable_toplink>1</enable_toplink>
|
160 |
<heading>Dealer Inquiry</heading>
|
161 |
<page_layout>one_column</page_layout>
|
162 |
<page_title>Dealer Inquiry</page_title>
|
163 |
+
<meta_description>Dealer Inquiry registration form</meta_description>
|
164 |
+
<meta_keywords>dealer,wholesale,inquiry,enquiry</meta_keywords>
|
165 |
<toplink>Dealer Inquiry</toplink>
|
166 |
<description>Write description here and it will display after Title.</description>
|
|
|
167 |
<success_des>Thank you for contacting us.</success_des>
|
168 |
<btn_text>Submit</btn_text>
|
169 |
<indicates>Indicates Required.</indicates>
|
app/code/community/CapacityWebSolutions/Inquiry/etc/system.xml
CHANGED
@@ -2,7 +2,11 @@
|
|
2 |
<config>
|
3 |
<tabs>
|
4 |
<cws translate="label" module="inquiry">
|
5 |
-
<label>
|
|
|
|
|
|
|
|
|
6 |
<sort_order>100</sort_order>
|
7 |
</cws>
|
8 |
</tabs>
|
@@ -43,6 +47,15 @@
|
|
43 |
<show_in_website>1</show_in_website>
|
44 |
<show_in_store>1</show_in_store>
|
45 |
</enable_toplink>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
46 |
<toplink translate="label">
|
47 |
<label>Top Link Label</label>
|
48 |
<comment><![CDATA[Here, We can Set Dealer inquiry Top Link Label.]]></comment>
|
@@ -65,24 +78,42 @@
|
|
65 |
<show_in_website>1</show_in_website>
|
66 |
<show_in_store>1</show_in_store>
|
67 |
</page_layout>
|
68 |
-
<
|
69 |
-
<label>
|
70 |
-
<comment><![CDATA[Here, We can Set Dealer inquiry
|
71 |
<frontend_type>text</frontend_type>
|
72 |
<sort_order>5</sort_order>
|
73 |
<show_in_default>1</show_in_default>
|
74 |
<show_in_website>1</show_in_website>
|
75 |
<show_in_store>1</show_in_store>
|
76 |
-
</
|
77 |
-
<
|
78 |
-
<label>
|
79 |
-
<comment><![CDATA[Here, We can Set Dealer inquiry
|
80 |
<frontend_type>text</frontend_type>
|
81 |
<sort_order>10</sort_order>
|
82 |
<show_in_default>1</show_in_default>
|
83 |
<show_in_website>1</show_in_website>
|
84 |
<show_in_store>1</show_in_store>
|
85 |
-
</
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
86 |
<description translate="label">
|
87 |
<label>Description</label>
|
88 |
<comment><![CDATA[This text will appear under the Dealer inquiry Form title.]]></comment>
|
@@ -101,15 +132,6 @@
|
|
101 |
<show_in_website>1</show_in_website>
|
102 |
<show_in_store>1</show_in_store>
|
103 |
</btn_text>
|
104 |
-
<success_tital translate="label">
|
105 |
-
<label>Success Page Heading</label>
|
106 |
-
<comment><![CDATA[Here, We can Set Dealer inquiry Success Page title.]]></comment>
|
107 |
-
<frontend_type>text</frontend_type>
|
108 |
-
<sort_order>30</sort_order>
|
109 |
-
<show_in_default>1</show_in_default>
|
110 |
-
<show_in_website>1</show_in_website>
|
111 |
-
<show_in_store>1</show_in_store>
|
112 |
-
</success_tital>
|
113 |
<success_des translate="label">
|
114 |
<label>Success Page Description</label>
|
115 |
<comment><![CDATA[This text will be displayed after the Dealer inquiry form submission.]]></comment>
|
2 |
<config>
|
3 |
<tabs>
|
4 |
<cws translate="label" module="inquiry">
|
5 |
+
<label>MageBees</label>
|
6 |
+
<label><![CDATA[<div style="position: absolute;padding: 0 0 0 75px;"><img id="magebees_block" src="" alt="" border="0" /></div> <script>
|
7 |
+
var n = SKIN_URL.indexOf("adminhtml");
|
8 |
+
$('magebees_block').src = SKIN_URL.substring(0, n) + "adminhtml/default/default/images/favicon.ico";
|
9 |
+
</script>]]>MageBees</label>
|
10 |
<sort_order>100</sort_order>
|
11 |
</cws>
|
12 |
</tabs>
|
47 |
<show_in_website>1</show_in_website>
|
48 |
<show_in_store>1</show_in_store>
|
49 |
</enable_toplink>
|
50 |
+
<url_key>
|
51 |
+
<label>URL Key</label>
|
52 |
+
<comment><![CDATA[Relative to Website Base URL.]]></comment>
|
53 |
+
<frontend_type>text</frontend_type>
|
54 |
+
<sort_order>1</sort_order>
|
55 |
+
<show_in_default>1</show_in_default>
|
56 |
+
<show_in_website>1</show_in_website>
|
57 |
+
<show_in_store>1</show_in_store>
|
58 |
+
</url_key>
|
59 |
<toplink translate="label">
|
60 |
<label>Top Link Label</label>
|
61 |
<comment><![CDATA[Here, We can Set Dealer inquiry Top Link Label.]]></comment>
|
78 |
<show_in_website>1</show_in_website>
|
79 |
<show_in_store>1</show_in_store>
|
80 |
</page_layout>
|
81 |
+
<heading translate="label">
|
82 |
+
<label>Heading</label>
|
83 |
+
<comment><![CDATA[Here, We can Set Dealer inquiry Form title.]]></comment>
|
84 |
<frontend_type>text</frontend_type>
|
85 |
<sort_order>5</sort_order>
|
86 |
<show_in_default>1</show_in_default>
|
87 |
<show_in_website>1</show_in_website>
|
88 |
<show_in_store>1</show_in_store>
|
89 |
+
</heading>
|
90 |
+
<page_title>
|
91 |
+
<label>Meta Title</label>
|
92 |
+
<comment><![CDATA[Here, We can Set Dealer inquiry Page title.]]></comment>
|
93 |
<frontend_type>text</frontend_type>
|
94 |
<sort_order>10</sort_order>
|
95 |
<show_in_default>1</show_in_default>
|
96 |
<show_in_website>1</show_in_website>
|
97 |
<show_in_store>1</show_in_store>
|
98 |
+
</page_title>
|
99 |
+
|
100 |
+
<meta_description translate="label comment">
|
101 |
+
<label>Meta Description</label>
|
102 |
+
<frontend_type>textarea</frontend_type>
|
103 |
+
<sort_order>11</sort_order>
|
104 |
+
<show_in_default>1</show_in_default>
|
105 |
+
<show_in_website>1</show_in_website>
|
106 |
+
<show_in_store>1</show_in_store>
|
107 |
+
</meta_description>
|
108 |
+
|
109 |
+
<meta_keywords translate="label comment">
|
110 |
+
<label>Meta Keywords</label>
|
111 |
+
<frontend_type>textarea</frontend_type>
|
112 |
+
<sort_order>12</sort_order>
|
113 |
+
<show_in_default>1</show_in_default>
|
114 |
+
<show_in_website>1</show_in_website>
|
115 |
+
<show_in_store>1</show_in_store>
|
116 |
+
</meta_keywords>
|
117 |
<description translate="label">
|
118 |
<label>Description</label>
|
119 |
<comment><![CDATA[This text will appear under the Dealer inquiry Form title.]]></comment>
|
132 |
<show_in_website>1</show_in_website>
|
133 |
<show_in_store>1</show_in_store>
|
134 |
</btn_text>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
135 |
<success_des translate="label">
|
136 |
<label>Success Page Description</label>
|
137 |
<comment><![CDATA[This text will be displayed after the Dealer inquiry form submission.]]></comment>
|
app/design/adminhtml/default/default/layout/inquiry.xml
CHANGED
@@ -1,8 +1,8 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<layout>
|
3 |
-
<
|
4 |
<reference name="content">
|
5 |
<block type="inquiry/adminhtml_inquiry" name="inquiry" />
|
6 |
</reference>
|
7 |
-
</
|
8 |
</layout>
|
1 |
<?xml version="1.0"?>
|
2 |
<layout>
|
3 |
+
<adminhtml_inquiry_index>
|
4 |
<reference name="content">
|
5 |
<block type="inquiry/adminhtml_inquiry" name="inquiry" />
|
6 |
</reference>
|
7 |
+
</adminhtml_inquiry_index>
|
8 |
</layout>
|
app/design/frontend/base/default/layout/inquiry.xml
CHANGED
@@ -17,7 +17,6 @@
|
|
17 |
<block type="core/html_calendar" name="head.calendar" as="calendar">
|
18 |
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>page/js/calendar.phtml</template></action>
|
19 |
</block>
|
20 |
-
|
21 |
</reference>
|
22 |
<!-- <reference name="root">
|
23 |
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>page/1column.phtml</template></action>
|
@@ -29,17 +28,4 @@
|
|
29 |
</block>
|
30 |
</reference>
|
31 |
</inquiry_index_index>
|
32 |
-
<inquiry_index_success>
|
33 |
-
<reference name="head">
|
34 |
-
<action method="addCss" ifconfig="inquiry/general/enabled"><stylesheet>css/inquiry/inquiry.css</stylesheet></action>
|
35 |
-
</reference>
|
36 |
-
<!-- <reference name="root">
|
37 |
-
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>page/1column.phtml</template></action>
|
38 |
-
</reference> -->
|
39 |
-
<reference name="content">
|
40 |
-
<block type="inquiry/inquiry" name="inquiryThanks">
|
41 |
-
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>inquiry/thanks.phtml</template></action>
|
42 |
-
</block>
|
43 |
-
</reference>
|
44 |
-
</inquiry_index_success>
|
45 |
</layout>
|
17 |
<block type="core/html_calendar" name="head.calendar" as="calendar">
|
18 |
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>page/js/calendar.phtml</template></action>
|
19 |
</block>
|
|
|
20 |
</reference>
|
21 |
<!-- <reference name="root">
|
22 |
<action method="setTemplate" ifconfig="inquiry/general/enabled"><template>page/1column.phtml</template></action>
|
28 |
</block>
|
29 |
</reference>
|
30 |
</inquiry_index_index>
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
31 |
</layout>
|
app/design/frontend/base/default/template/inquiry/inquiry.phtml
CHANGED
@@ -1,13 +1,11 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
***************************************************************************/
|
9 |
?>
|
10 |
-
|
11 |
<?php $code = trim($this->getRandomCode());
|
12 |
$_taxvat = $this->getLayout()->createBlock('customer/widget_taxvat'); ?>
|
13 |
<script>
|
@@ -36,6 +34,11 @@ function clearFileInputField(tagId) {
|
|
36 |
}
|
37 |
</script>
|
38 |
<?php endif; ?>
|
|
|
|
|
|
|
|
|
|
|
39 |
<div id="about-copy" class="inquiryForm">
|
40 |
<h1><img src="<?php echo $this->getSkinUrl('images/inquiry/inquiry-icon.png') ?>" alt="" /><?php if($this->getHeading()): ?><?php echo $this->__($this->getHeading()); ?><?php endif; ?></h1>
|
41 |
<p><?php if($this->getDesc()): ?><?php echo $this->getDesc(); ?><?php endif; ?></p>
|
@@ -48,14 +51,16 @@ function clearFileInputField(tagId) {
|
|
48 |
<ul class="form-list">
|
49 |
<li class="fields">
|
50 |
<div class="field">
|
51 |
-
|
|
|
52 |
<div class="input-box">
|
53 |
<input type="text" name="firstname" id="firstname" size="45" class="input-text required-entry input-box" value="<?php echo $this->escapeHtml($this->getFormData()->getFirstname()) ?>"/>
|
54 |
</div>
|
55 |
</div>
|
56 |
<?php if($this->getLastNameHide()): ?>
|
57 |
<div class="field">
|
58 |
-
|
|
|
59 |
<div class="input-box">
|
60 |
<input type="text" name="lastname" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getLastname()) ?>"/>
|
61 |
</div>
|
@@ -64,7 +69,8 @@ function clearFileInputField(tagId) {
|
|
64 |
</li>
|
65 |
<li class="fields">
|
66 |
<div class="field">
|
67 |
-
|
|
|
68 |
<div class="input-box">
|
69 |
<input type="text" name="company" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getCompany()) ?>"/>
|
70 |
</div>
|
@@ -72,7 +78,8 @@ function clearFileInputField(tagId) {
|
|
72 |
|
73 |
<?php if($this->getVatNumberHide()): ?>
|
74 |
<div class="field">
|
75 |
-
|
|
|
76 |
<div class="input-box">
|
77 |
<input type="text" name="taxvat" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getTaxvat()) ?>"/>
|
78 |
</div>
|
@@ -83,7 +90,8 @@ function clearFileInputField(tagId) {
|
|
83 |
<li class="fields">
|
84 |
<?php if($this->getAddressHide()): ?>
|
85 |
<div class="field">
|
86 |
-
|
|
|
87 |
<div class="input-box">
|
88 |
<textarea name="address" cols="42" rows="1" class="input-text required-entry"><?php echo $this->escapeHtml($this->getFormData()->getAddress()) ?></textarea>
|
89 |
</div>
|
@@ -92,7 +100,8 @@ function clearFileInputField(tagId) {
|
|
92 |
|
93 |
<?php if($this->getCityHide()): ?>
|
94 |
<div class="field">
|
95 |
-
|
|
|
96 |
<div class="input-box">
|
97 |
<input type="text" name="city" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getCity()) ?>"/>
|
98 |
</div>
|
@@ -102,7 +111,8 @@ function clearFileInputField(tagId) {
|
|
102 |
<li class="fields">
|
103 |
<?php if($this->getStateHide()): ?>
|
104 |
<div class="field">
|
105 |
-
|
|
|
106 |
<div class="input-box">
|
107 |
<input type="text" name="state" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getState()) ?>"/>
|
108 |
</div>
|
@@ -111,7 +121,8 @@ function clearFileInputField(tagId) {
|
|
111 |
|
112 |
<?php if($this->getCountryHide()): ?>
|
113 |
<div class="field">
|
114 |
-
|
|
|
115 |
<div class="input-box">
|
116 |
<?php $country_sess = $this->escapeHtml($this->getFormData()->getCountry()) ?>
|
117 |
<select name="country" id="country" class="drop" class="input-text required-entry">
|
@@ -141,7 +152,8 @@ function clearFileInputField(tagId) {
|
|
141 |
<li class="fields">
|
142 |
<?php if($this->getPostalCodeHide()): ?>
|
143 |
<div class="field">
|
144 |
-
|
|
|
145 |
<div class="input-box">
|
146 |
<input type="text" name="zip" id="zip" size="45" maxlength="10" class="required-entry input-text validation-passed" value="<?php echo $this->escapeHtml($this->getFormData()->getZip()) ?>"/>
|
147 |
</div>
|
@@ -149,7 +161,8 @@ function clearFileInputField(tagId) {
|
|
149 |
<?php endif; ?>
|
150 |
|
151 |
<div class="field">
|
152 |
-
|
|
|
153 |
<div class="input-box">
|
154 |
<input type="text" name="phone" size="45" onKeyPress="return isNumberKey(event)" maxlength="15" class="input-text validate required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getPhone()) ?>"/>
|
155 |
</div>
|
@@ -157,14 +170,16 @@ function clearFileInputField(tagId) {
|
|
157 |
</li>
|
158 |
<li class="fields">
|
159 |
<div class="field">
|
160 |
-
|
|
|
161 |
<div class="input-box">
|
162 |
<input type="text" name="email" size="45" class="input-text validate-email required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getEmail()) ?>"/>
|
163 |
</div>
|
164 |
</div>
|
165 |
<?php if($this->getWebsiteHide()): ?>
|
166 |
<div class="field">
|
167 |
-
|
|
|
168 |
<div class="input-box">
|
169 |
<input type="text" name="website" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getWebsite()) ?>"/>
|
170 |
</div>
|
@@ -173,14 +188,16 @@ function clearFileInputField(tagId) {
|
|
173 |
</li>
|
174 |
<li class="fields">
|
175 |
<div class="field">
|
176 |
-
|
|
|
177 |
<div class="input-box">
|
178 |
<textarea name="desc" cols="75" rows="2" class="input-text"><?php echo $this->escapeHtml($this->getFormData()->getDesc()) ?></textarea>
|
179 |
</div>
|
180 |
</div>
|
181 |
<?php if($this->getDateTimeHide()): ?>
|
182 |
<div class="field">
|
183 |
-
|
|
|
184 |
<div class="input-box">
|
185 |
<input type="text" name="date_time" id="date_time" size="45" class="input-text validate-date" placeholder="dd/mm/yyyy HH:MM:SS" value="<?php echo $this->escapeHtml($this->getFormData()->getDateTime()) ?>"/> <img title="Select date" id="date-picker-cal" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_SKIN) . 'adminhtml/default/default/images/grid-cal.gif'; ?>">
|
186 |
</div>
|
@@ -200,7 +217,8 @@ function clearFileInputField(tagId) {
|
|
200 |
<li class="fields">
|
201 |
<?php if($this->getUploadFileHide()): ?>
|
202 |
<div class="field">
|
203 |
-
|
|
|
204 |
<div class="input-box" id="uploadFile_div">
|
205 |
<input type="file" id="file" name="file[]" size="45" class="input-text" multiple/>
|
206 |
<a id="clearfile" onclick="clearFileInputField('uploadFile_div')"
|
@@ -211,7 +229,8 @@ function clearFileInputField(tagId) {
|
|
211 |
|
212 |
<?php if($this->getFieldOneHide()): ?>
|
213 |
<div class="field">
|
214 |
-
|
|
|
215 |
<div class="input-box">
|
216 |
<input type="text" name="extra_field_one" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldOne()) ?>"/>
|
217 |
</div>
|
@@ -222,7 +241,8 @@ function clearFileInputField(tagId) {
|
|
222 |
<li class="fields">
|
223 |
<?php if($this->getFieldTwoHide()): ?>
|
224 |
<div class="field">
|
225 |
-
|
|
|
226 |
<div class="input-box">
|
227 |
<input type="text" name="extra_field_two" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldTwo()) ?>"/>
|
228 |
</div>
|
@@ -230,7 +250,8 @@ function clearFileInputField(tagId) {
|
|
230 |
<?php endif; ?>
|
231 |
<?php if($this->getFieldThreeHide()): ?>
|
232 |
<div class="field">
|
233 |
-
|
|
|
234 |
<div class="input-box">
|
235 |
<input type="text" name="extra_field_three" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldThree()) ?>"/>
|
236 |
</div>
|
@@ -240,11 +261,12 @@ function clearFileInputField(tagId) {
|
|
240 |
<li class="fields last">
|
241 |
<?php if($this->getCaptchaHide()): ?>
|
242 |
<?php //echo $this->getChildHtml('captcha') ?>
|
243 |
-
|
|
|
244 |
<div class="clear"></div>
|
245 |
<div class="captcha-main">
|
246 |
<div id="captcha" class="captcha-left">
|
247 |
-
|
248 |
<img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA)."inquiry/captcha/".$image_name ;?>" id="captcha_image"/>
|
249 |
</div>
|
250 |
</div>
|
@@ -256,7 +278,8 @@ function clearFileInputField(tagId) {
|
|
256 |
</ul>
|
257 |
<div class="clear"></div>
|
258 |
<div class="button-set">
|
259 |
-
|
|
|
260 |
</div>
|
261 |
</div>
|
262 |
</form>
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
|
|
8 |
?>
|
|
|
9 |
<?php $code = trim($this->getRandomCode());
|
10 |
$_taxvat = $this->getLayout()->createBlock('customer/widget_taxvat'); ?>
|
11 |
<script>
|
34 |
}
|
35 |
</script>
|
36 |
<?php endif; ?>
|
37 |
+
<?php $image_name = Mage::helper('inquiry')->createCaptchaImage(); ?>
|
38 |
+
<?php $filename = Mage::getBaseDir(Mage_Core_Model_Store::URL_TYPE_MEDIA).DS."inquiry".DS."captcha".DS.$image_name;?>
|
39 |
+
<?php if ( ! is_writable(dirname($filename))) : ?>
|
40 |
+
<ul class="messages"><li class="notice-msg"><ul><li><span>Your "/media/inquiry" folder does not have sufficient write permissions.</span></li></ul></li></ul>
|
41 |
+
<?php endif; ?>
|
42 |
<div id="about-copy" class="inquiryForm">
|
43 |
<h1><img src="<?php echo $this->getSkinUrl('images/inquiry/inquiry-icon.png') ?>" alt="" /><?php if($this->getHeading()): ?><?php echo $this->__($this->getHeading()); ?><?php endif; ?></h1>
|
44 |
<p><?php if($this->getDesc()): ?><?php echo $this->getDesc(); ?><?php endif; ?></p>
|
51 |
<ul class="form-list">
|
52 |
<li class="fields">
|
53 |
<div class="field">
|
54 |
+
<?php $fname_label = $this->getFirstName()?$this->getFirstName():"First Name"; ?>
|
55 |
+
<label><?php echo $this->__($fname_label); ?><span class="required"><em>*</em></span></label>
|
56 |
<div class="input-box">
|
57 |
<input type="text" name="firstname" id="firstname" size="45" class="input-text required-entry input-box" value="<?php echo $this->escapeHtml($this->getFormData()->getFirstname()) ?>"/>
|
58 |
</div>
|
59 |
</div>
|
60 |
<?php if($this->getLastNameHide()): ?>
|
61 |
<div class="field">
|
62 |
+
<?php $lname_label = $this->getLastName()?$this->getLastName():"Last Name"; ?>
|
63 |
+
<label><?php echo $this->__($lname_label); ?><span class="required"><em>*</em></span></label>
|
64 |
<div class="input-box">
|
65 |
<input type="text" name="lastname" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getLastname()) ?>"/>
|
66 |
</div>
|
69 |
</li>
|
70 |
<li class="fields">
|
71 |
<div class="field">
|
72 |
+
<?php $company_label = $this->getCompanyName()?$this->getCompanyName():"Company Name"; ?>
|
73 |
+
<label><?php echo $this->__($company_label); ?><span class="required"><em>*</em></span></label>
|
74 |
<div class="input-box">
|
75 |
<input type="text" name="company" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getCompany()) ?>"/>
|
76 |
</div>
|
78 |
|
79 |
<?php if($this->getVatNumberHide()): ?>
|
80 |
<div class="field">
|
81 |
+
<?php $tax_label = $this->getVatNumber()?$this->getVatNumber():"Tax/VAT Number"; ?>
|
82 |
+
<label><?php echo $this->__($tax_label); ?></label>
|
83 |
<div class="input-box">
|
84 |
<input type="text" name="taxvat" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getTaxvat()) ?>"/>
|
85 |
</div>
|
90 |
<li class="fields">
|
91 |
<?php if($this->getAddressHide()): ?>
|
92 |
<div class="field">
|
93 |
+
<?php $add_label = $this->getAddress()?$this->getAddress():"Address"; ?>
|
94 |
+
<label><?php echo $this->__($add_label); ?><span class="required"><em>*</em></span></label>
|
95 |
<div class="input-box">
|
96 |
<textarea name="address" cols="42" rows="1" class="input-text required-entry"><?php echo $this->escapeHtml($this->getFormData()->getAddress()) ?></textarea>
|
97 |
</div>
|
100 |
|
101 |
<?php if($this->getCityHide()): ?>
|
102 |
<div class="field">
|
103 |
+
<?php $city_label = $this->getCity()?$this->getCity():"City"; ?>
|
104 |
+
<label><?php echo $this->__($city_label); ?><span class="required"><em>*</em></span></label>
|
105 |
<div class="input-box">
|
106 |
<input type="text" name="city" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getCity()) ?>"/>
|
107 |
</div>
|
111 |
<li class="fields">
|
112 |
<?php if($this->getStateHide()): ?>
|
113 |
<div class="field">
|
114 |
+
<?php $state_label = $this->getState()?$this->getState():"State / Province"; ?>
|
115 |
+
<label><?php echo $this->__($state_label); ?><span class="required"><em>*</em></span></label>
|
116 |
<div class="input-box">
|
117 |
<input type="text" name="state" size="45" class="input-text required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getState()) ?>"/>
|
118 |
</div>
|
121 |
|
122 |
<?php if($this->getCountryHide()): ?>
|
123 |
<div class="field">
|
124 |
+
<?php $country_label = $this->getCountry()?$this->getCountry():"Country"; ?>
|
125 |
+
<label><?php echo $this->__($country_label); ?><span class="required"><em>*</em></span></label>
|
126 |
<div class="input-box">
|
127 |
<?php $country_sess = $this->escapeHtml($this->getFormData()->getCountry()) ?>
|
128 |
<select name="country" id="country" class="drop" class="input-text required-entry">
|
152 |
<li class="fields">
|
153 |
<?php if($this->getPostalCodeHide()): ?>
|
154 |
<div class="field">
|
155 |
+
<?php $zip_label = $this->getPostalCode()?$this->getPostalCode():"ZIP / Postal Code"; ?>
|
156 |
+
<label><?php echo $this->__($zip_label); ?><span class="required"><em>*</em></span></label>
|
157 |
<div class="input-box">
|
158 |
<input type="text" name="zip" id="zip" size="45" maxlength="10" class="required-entry input-text validation-passed" value="<?php echo $this->escapeHtml($this->getFormData()->getZip()) ?>"/>
|
159 |
</div>
|
161 |
<?php endif; ?>
|
162 |
|
163 |
<div class="field">
|
164 |
+
<?php $contact_label = $this->getContactNumber()?$this->getContactNumber():"Contact Number"; ?>
|
165 |
+
<label><?php echo $this->__($contact_label); ?><span class="required"><em>*</em></span></label>
|
166 |
<div class="input-box">
|
167 |
<input type="text" name="phone" size="45" onKeyPress="return isNumberKey(event)" maxlength="15" class="input-text validate required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getPhone()) ?>"/>
|
168 |
</div>
|
170 |
</li>
|
171 |
<li class="fields">
|
172 |
<div class="field">
|
173 |
+
<?php $email_label = $this->getEmail()?$this->getEmail():"Email"; ?>
|
174 |
+
<label><?php echo $this->__($email_label); ?><span class="required"><em>*</em></span></label>
|
175 |
<div class="input-box">
|
176 |
<input type="text" name="email" size="45" class="input-text validate-email required-entry" value="<?php echo $this->escapeHtml($this->getFormData()->getEmail()) ?>"/>
|
177 |
</div>
|
178 |
</div>
|
179 |
<?php if($this->getWebsiteHide()): ?>
|
180 |
<div class="field">
|
181 |
+
<?php $website_label = $this->getWebsite()?$this->getWebsite():"Website"; ?>
|
182 |
+
<label><?php echo $this->__($website_label); ?></label>
|
183 |
<div class="input-box">
|
184 |
<input type="text" name="website" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getWebsite()) ?>"/>
|
185 |
</div>
|
188 |
</li>
|
189 |
<li class="fields">
|
190 |
<div class="field">
|
191 |
+
<?php $desc_label = $this->getDescription()?$this->getDescription():"Business Description"; ?>
|
192 |
+
<label><?php echo $this->__($desc_label); ?></label>
|
193 |
<div class="input-box">
|
194 |
<textarea name="desc" cols="75" rows="2" class="input-text"><?php echo $this->escapeHtml($this->getFormData()->getDesc()) ?></textarea>
|
195 |
</div>
|
196 |
</div>
|
197 |
<?php if($this->getDateTimeHide()): ?>
|
198 |
<div class="field">
|
199 |
+
<?php $datetime_label = $this->getDateTime()?$this->getDateTime():"Date Time"; ?>
|
200 |
+
<label><?php echo $this->__($datetime_label); ?></label>
|
201 |
<div class="input-box">
|
202 |
<input type="text" name="date_time" id="date_time" size="45" class="input-text validate-date" placeholder="dd/mm/yyyy HH:MM:SS" value="<?php echo $this->escapeHtml($this->getFormData()->getDateTime()) ?>"/> <img title="Select date" id="date-picker-cal" src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_SKIN) . 'adminhtml/default/default/images/grid-cal.gif'; ?>">
|
203 |
</div>
|
217 |
<li class="fields">
|
218 |
<?php if($this->getUploadFileHide()): ?>
|
219 |
<div class="field">
|
220 |
+
<?php $upload_label = $this->getUploadFile()?$this->getUploadFile():"Upload File"; ?>
|
221 |
+
<label><?php echo $this->__($upload_label); ?></label>
|
222 |
<div class="input-box" id="uploadFile_div">
|
223 |
<input type="file" id="file" name="file[]" size="45" class="input-text" multiple/>
|
224 |
<a id="clearfile" onclick="clearFileInputField('uploadFile_div')"
|
229 |
|
230 |
<?php if($this->getFieldOneHide()): ?>
|
231 |
<div class="field">
|
232 |
+
<?php $field_one_label = $this->getExtraFieldOne()?$this->getExtraFieldOne():"Extra Field 1"; ?>
|
233 |
+
<label><?php echo $this->__($field_one_label); ?></label>
|
234 |
<div class="input-box">
|
235 |
<input type="text" name="extra_field_one" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldOne()) ?>"/>
|
236 |
</div>
|
241 |
<li class="fields">
|
242 |
<?php if($this->getFieldTwoHide()): ?>
|
243 |
<div class="field">
|
244 |
+
<?php $field_two_label = $this->getExtraFieldTwo()?$this->getExtraFieldTwo():"Extra Field 2"; ?>
|
245 |
+
<label><?php echo $this->__($field_two_label); ?></label>
|
246 |
<div class="input-box">
|
247 |
<input type="text" name="extra_field_two" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldTwo()) ?>"/>
|
248 |
</div>
|
250 |
<?php endif; ?>
|
251 |
<?php if($this->getFieldThreeHide()): ?>
|
252 |
<div class="field">
|
253 |
+
<?php $field_three_label = $this->getExtraFieldThree()?$this->getExtraFieldThree():"Extra Field 3"; ?>
|
254 |
+
<label><?php echo $this->__($field_three_label); ?></label>
|
255 |
<div class="input-box">
|
256 |
<input type="text" name="extra_field_three" size="45" class="input-text" value="<?php echo $this->escapeHtml($this->getFormData()->getExtraFieldThree()) ?>"/>
|
257 |
</div>
|
261 |
<li class="fields last">
|
262 |
<?php if($this->getCaptchaHide()): ?>
|
263 |
<?php //echo $this->getChildHtml('captcha') ?>
|
264 |
+
<?php $captcha_label = $this->getCaptcha()?$this->getCaptcha():"Please type the letters below"; ?>
|
265 |
+
<label><?php echo $this->__($captcha_label)?><span class="required"><em>*</em></span></label>
|
266 |
<div class="clear"></div>
|
267 |
<div class="captcha-main">
|
268 |
<div id="captcha" class="captcha-left">
|
269 |
+
|
270 |
<img src="<?php echo Mage::getBaseUrl(Mage_Core_Model_Store::URL_TYPE_MEDIA)."inquiry/captcha/".$image_name ;?>" id="captcha_image"/>
|
271 |
</div>
|
272 |
</div>
|
278 |
</ul>
|
279 |
<div class="clear"></div>
|
280 |
<div class="button-set">
|
281 |
+
<?php $button_label = $this->getBtnText()?$this->getBtnText():"Submit"; ?>
|
282 |
+
<button id="submit-inquiry" type="submit" name="SUBMIT" class="button" value="SUBMIT"><span><span><?php echo $this->__($button_label); ?></span></span></button>
|
283 |
</div>
|
284 |
</div>
|
285 |
</form>
|
app/design/frontend/base/default/template/inquiry/thanks.phtml
CHANGED
@@ -1,12 +1,12 @@
|
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
-
|
4 |
-
|
5 |
-
|
6 |
-
|
7 |
-
|
8 |
-
|
9 |
-
|
10 |
$success_tital = Mage::getStoreConfig('inquiry/general/success_tital');
|
11 |
$success_des = Mage::getStoreConfig('inquiry/general/success_des');
|
12 |
?>
|
1 |
<?php
|
2 |
/***************************************************************************
|
3 |
+
Extension Name : Dealer Inquiry
|
4 |
+
Extension URL : http://www.magebees.com/magento-dealer-inquiry-extension.html
|
5 |
+
Copyright : Copyright (c) 2015 MageBees, http://www.magebees.com
|
6 |
+
Support Email : support@magebees.com
|
7 |
+
***************************************************************************/
|
8 |
+
?>
|
9 |
+
<?php
|
10 |
$success_tital = Mage::getStoreConfig('inquiry/general/success_tital');
|
11 |
$success_des = Mage::getStoreConfig('inquiry/general/success_des');
|
12 |
?>
|
package.xml
CHANGED
@@ -1,7 +1,7 @@
|
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Dealer_Inquery</name>
|
4 |
-
<version>2.1.
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL 3.0</license>
|
7 |
<channel>community</channel>
|
@@ -10,9 +10,9 @@
|
|
10 |
<description>Dealer filled the details like name, address, contact number, email, website and description inquiry form. It informs to customer and admin by email when customer submits inquiry form. This extension also provides customer listing who submit inquiry form in admin under Dealer Management section. You can view inquiry details of customer and also delete the inquiry information. This extension provides create customer link from dealer listing page.</description>
|
11 |
<notes>Dealer Inquiry</notes>
|
12 |
<authors><author><name>Capacity Web Solutions</name><user>capacitywebsolutions</user><email>magento@capacitywebsolutions.com</email></author></authors>
|
13 |
-
<date>2015-
|
14 |
-
<time>
|
15 |
-
<contents><target name="mageetc"><dir name="modules"><file name="CapacityWebSolutions_Inquiry.xml" hash="02eb95f93a47babe658b8cacd8a79dba"/></dir></target><target name="magecommunity"><dir name="CapacityWebSolutions"><dir name="Inquiry"><dir name="Block"><dir name="Adminhtml"><dir name="Inquiry"><dir name="Edit"><file name="Form.php" hash="
|
16 |
<compatible/>
|
17 |
-
<dependencies><required><php><min>5.0.0</min><max>5.6.
|
18 |
</package>
|
1 |
<?xml version="1.0"?>
|
2 |
<package>
|
3 |
<name>Dealer_Inquery</name>
|
4 |
+
<version>2.1.2</version>
|
5 |
<stability>stable</stability>
|
6 |
<license uri="http://opensource.org/licenses/osl-3.0.php">OSL 3.0</license>
|
7 |
<channel>community</channel>
|
10 |
<description>Dealer filled the details like name, address, contact number, email, website and description inquiry form. It informs to customer and admin by email when customer submits inquiry form. This extension also provides customer listing who submit inquiry form in admin under Dealer Management section. You can view inquiry details of customer and also delete the inquiry information. This extension provides create customer link from dealer listing page.</description>
|
11 |
<notes>Dealer Inquiry</notes>
|
12 |
<authors><author><name>Capacity Web Solutions</name><user>capacitywebsolutions</user><email>magento@capacitywebsolutions.com</email></author></authors>
|
13 |
+
<date>2015-10-30</date>
|
14 |
+
<time>11:26:34</time>
|
15 |
+
<contents><target name="mageetc"><dir name="modules"><file name="CapacityWebSolutions_Inquiry.xml" hash="02eb95f93a47babe658b8cacd8a79dba"/></dir></target><target name="magecommunity"><dir name="CapacityWebSolutions"><dir name="Inquiry"><dir name="Block"><dir name="Adminhtml"><dir name="Inquiry"><dir name="Edit"><file name="Form.php" hash="616ccd08b58c2c688994e9bd037c30f5"/><dir name="Tab"><file name="Form.php" hash="c9837fe84c7f80e5b7c24f545d5ecb33"/></dir><file name="Tabs.php" hash="38e769fead1617cfc8440d6ab47f9c37"/></dir><file name="Edit.php" hash="5b817f8b03c7af07063d542525a74d91"/><file name="Grid.php" hash="937fe5e82e22976df90de238638412c1"/><dir name="Renderer"><file name="Image.php" hash="fc785eedf6aa71062a61f02ff80d70cc"/></dir></dir><file name="Inquiry.php" hash="150b32a515d84e7ab451034971ce9271"/></dir><file name="Inquiry.php" hash="145bdec05e1f557f03632584a28ce13a"/></dir><dir name="Controller"><file name="Router.php" hash="11e413323174188558caec1ebf55c08c"/></dir><dir name="controllers"><dir name="Adminhtml"><file name="InquiryController.php" hash="743d95c74956e476f0b09be7482c6017"/></dir><file name="IndexController.php" hash="6d3f5ddedecf51b9836cdbbb27b148d1"/><file name="TestController.php" hash="7078248876fe0e4c9bf21da4ad9e8d42"/></dir><dir name="etc"><file name="adminhtml.xml" hash="0b229fc89ff2eb5eff1e4e659fedb1e1"/><file name="config.xml" hash="fe5283939b03078a5705d9c5269405cc"/><file name="system.xml" hash="af130b50bceeb458bf59655ef70c0704"/></dir><dir name="Helper"><file name="Data.php" hash="277e70c7af8be11a61d4d06dd8658239"/></dir><dir name="Model"><file name="Inquiryfiles.php" hash="8dd064c4c4fdeb5b8dc5a5ff8a640f00"/><file name="Inquiry.php" hash="508e06f2c6f706906f54636c3ce23128"/><dir name="Mysql4"><dir name="Inquiry"><file name="Collection.php" hash="250fb44b04853e77dc9250c0efe1bc99"/></dir><dir name="Inquiryfiles"><file name="Collection.php" hash="9cfb6b23ec536376ae7f642be2303421"/></dir><file name="Inquiryfiles.php" hash="10bd77452ce65e31b1bcc42206c37607"/><file name="Inquiry.php" hash="22a1244c6f65cfd62e341fbe81ed866f"/></dir><file name="Observer.php" hash="f3e9a748c50c169e9921724191d74204"/><dir name="System"><dir name="Config"><dir name="Source"><file name="Customergroup.php" hash="b37984de49e0be9ca50645a941cb66f7"/><file name="Ownermail.php" hash="f04f98c521c0d530ed879913e8dc2941"/></dir></dir></dir></dir><dir name="sql"><dir name="inquiry_setup"><file name="mysql4-install-0.1.0.php" hash="9a91bba5121b6618130fe56e6d0b01e2"/><file name="mysql4-upgrade-1.2.1-2.0.0.php" hash="944b85aeb8b9ead25a60faf7c2aeb9e9"/><file name="mysql4-upgrade-2.0.0-2.1.0.php" hash="faf3b74c1e2d8d6405498fcf743bb9fa"/></dir></dir></dir></dir></target><target name="magedesign"><dir name="frontend"><dir name="base"><dir name="default"><dir name="layout"><file name="inquiry.xml" hash="abd1e59f4e438af01e26d129fe4f1e72"/></dir><dir name="template"><dir name="inquiry"><file name="inquiry.phtml" hash="6864932b6a3f0637617807a9de2cc10c"/><file name="thanks.phtml" hash="eac0d84f90a9c4cbd4b83ed04936d007"/></dir></dir></dir></dir></dir><dir name="adminhtml"><dir name="default"><dir name="default"><dir name="layout"><file name="inquiry.xml" hash="576b36a0a56f55435bd00016b04d6a18"/></dir></dir></dir></dir></target><target name="magelocale"><dir name="en_US"><dir name="template"><dir name="email"><dir name="inquiry"><file name="admin_inquiry.html" hash="22e95bf5df3ffe8ba171482bae94883d"/><file name="create_customer.html" hash="01c94aac3b06a4e94081d9cc18253ead"/><file name="customer_inquiry.html" hash="6c7ed1f09acca09403dd91f774f8afe1"/></dir></dir></dir></dir></target><target name="mageskin"><dir name="frontend"><dir name="base"><dir name="default"><dir name="css"><dir name="inquiry"><file name="inquiry.css" hash="c445bb2027a6f9d5332d5a805b309f2a"/></dir></dir><dir name="images"><dir name="inquiry"><file name="inquiry-icon.png" hash="2fe54ac19c9baab1c6ac4927b6a034f5"/><file name="refresh.png" hash="cb4184defa247c1b3ebfcf89cd279872"/></dir></dir></dir></dir></dir></target><target name="magemedia"><dir name="inquiry"><file name="create_user.png" hash="7b785ab3b563f8880819404c0382b11e"/><dir name="fonts"><file name="arial.ttf" hash="5995c725ca5a13be62d3dc75c2fc59fc"/></dir></dir></target></contents>
|
16 |
<compatible/>
|
17 |
+
<dependencies><required><php><min>5.0.0</min><max>5.6.14</max></php></required></dependencies>
|
18 |
</package>
|