@@ -1,88 +1,88 @@ |
||
| 1 | 1 | <?php |
| 2 | 2 | $searchdefs ['Documents'] = |
| 3 | 3 | array ( |
| 4 | - 'layout' => |
|
| 5 | - array ( |
|
| 4 | + 'layout' => |
|
| 5 | + array ( |
|
| 6 | 6 | 'basic_search' => |
| 7 | 7 | array ( |
| 8 | - 0 => 'document_name', |
|
| 9 | - 1 => array ('name' => 'favorites_only','label' => 'LBL_FAVORITES_FILTER','type' => 'bool',), |
|
| 8 | + 0 => 'document_name', |
|
| 9 | + 1 => array ('name' => 'favorites_only','label' => 'LBL_FAVORITES_FILTER','type' => 'bool',), |
|
| 10 | 10 | ), |
| 11 | 11 | 'advanced_search' => |
| 12 | 12 | array ( |
| 13 | - 'document_name' => |
|
| 14 | - array ( |
|
| 13 | + 'document_name' => |
|
| 14 | + array ( |
|
| 15 | 15 | 'name' => 'document_name', |
| 16 | 16 | 'default' => true, |
| 17 | 17 | 'width' => '10%', |
| 18 | - ), |
|
| 19 | - 'status' => |
|
| 20 | - array ( |
|
| 18 | + ), |
|
| 19 | + 'status' => |
|
| 20 | + array ( |
|
| 21 | 21 | 'type' => 'varchar', |
| 22 | 22 | 'label' => 'LBL_DOC_STATUS', |
| 23 | 23 | 'width' => '10%', |
| 24 | 24 | 'default' => true, |
| 25 | 25 | 'name' => 'status', |
| 26 | - ), |
|
| 27 | - 'template_type' => |
|
| 28 | - array ( |
|
| 26 | + ), |
|
| 27 | + 'template_type' => |
|
| 28 | + array ( |
|
| 29 | 29 | 'type' => 'enum', |
| 30 | 30 | 'label' => 'LBL_TEMPLATE_TYPE', |
| 31 | 31 | 'width' => '10%', |
| 32 | 32 | 'default' => true, |
| 33 | 33 | 'name' => 'template_type', |
| 34 | - ), |
|
| 35 | - 'category_id' => |
|
| 36 | - array ( |
|
| 34 | + ), |
|
| 35 | + 'category_id' => |
|
| 36 | + array ( |
|
| 37 | 37 | 'name' => 'category_id', |
| 38 | 38 | 'default' => true, |
| 39 | 39 | 'width' => '10%', |
| 40 | - ), |
|
| 41 | - 'subcategory_id' => |
|
| 42 | - array ( |
|
| 40 | + ), |
|
| 41 | + 'subcategory_id' => |
|
| 42 | + array ( |
|
| 43 | 43 | 'name' => 'subcategory_id', |
| 44 | 44 | 'default' => true, |
| 45 | 45 | 'width' => '10%', |
| 46 | - ), |
|
| 47 | - 'assigned_user_id' => |
|
| 48 | - array ( |
|
| 46 | + ), |
|
| 47 | + 'assigned_user_id' => |
|
| 48 | + array ( |
|
| 49 | 49 | 'name' => 'assigned_user_id', |
| 50 | 50 | 'type' => 'enum', |
| 51 | 51 | 'label' => 'LBL_ASSIGNED_TO', |
| 52 | 52 | 'function' => |
| 53 | 53 | array ( |
| 54 | - 'name' => 'get_user_array', |
|
| 55 | - 'params' => |
|
| 56 | - array ( |
|
| 54 | + 'name' => 'get_user_array', |
|
| 55 | + 'params' => |
|
| 56 | + array ( |
|
| 57 | 57 | 0 => false, |
| 58 | - ), |
|
| 58 | + ), |
|
| 59 | 59 | ), |
| 60 | 60 | 'default' => true, |
| 61 | 61 | 'width' => '10%', |
| 62 | - ), |
|
| 63 | - 'active_date' => |
|
| 64 | - array ( |
|
| 62 | + ), |
|
| 63 | + 'active_date' => |
|
| 64 | + array ( |
|
| 65 | 65 | 'name' => 'active_date', |
| 66 | 66 | 'default' => true, |
| 67 | 67 | 'width' => '10%', |
| 68 | - ), |
|
| 69 | - 'exp_date' => |
|
| 70 | - array ( |
|
| 68 | + ), |
|
| 69 | + 'exp_date' => |
|
| 70 | + array ( |
|
| 71 | 71 | 'name' => 'exp_date', |
| 72 | 72 | 'default' => true, |
| 73 | 73 | 'width' => '10%', |
| 74 | - ), |
|
| 74 | + ), |
|
| 75 | + ), |
|
| 75 | 76 | ), |
| 76 | - ), |
|
| 77 | - 'templateMeta' => |
|
| 78 | - array ( |
|
| 77 | + 'templateMeta' => |
|
| 78 | + array ( |
|
| 79 | 79 | 'maxColumns' => '3', |
| 80 | 80 | 'maxColumnsBasic' => '4', |
| 81 | 81 | 'widths' => |
| 82 | 82 | array ( |
| 83 | - 'label' => '10', |
|
| 84 | - 'field' => '30', |
|
| 83 | + 'label' => '10', |
|
| 84 | + 'field' => '30', |
|
| 85 | + ), |
|
| 85 | 86 | ), |
| 86 | - ), |
|
| 87 | 87 | ); |
| 88 | 88 | ?> |
@@ -1,23 +1,23 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | 2 | $searchdefs ['Documents'] = |
| 3 | -array ( |
|
| 3 | +array( |
|
| 4 | 4 | 'layout' => |
| 5 | - array ( |
|
| 5 | + array( |
|
| 6 | 6 | 'basic_search' => |
| 7 | - array ( |
|
| 7 | + array( |
|
| 8 | 8 | 0 => 'document_name', |
| 9 | - 1 => array ('name' => 'favorites_only','label' => 'LBL_FAVORITES_FILTER','type' => 'bool',), |
|
| 9 | + 1 => array('name' => 'favorites_only', 'label' => 'LBL_FAVORITES_FILTER', 'type' => 'bool',), |
|
| 10 | 10 | ), |
| 11 | 11 | 'advanced_search' => |
| 12 | - array ( |
|
| 12 | + array( |
|
| 13 | 13 | 'document_name' => |
| 14 | - array ( |
|
| 14 | + array( |
|
| 15 | 15 | 'name' => 'document_name', |
| 16 | 16 | 'default' => true, |
| 17 | 17 | 'width' => '10%', |
| 18 | 18 | ), |
| 19 | 19 | 'status' => |
| 20 | - array ( |
|
| 20 | + array( |
|
| 21 | 21 | 'type' => 'varchar', |
| 22 | 22 | 'label' => 'LBL_DOC_STATUS', |
| 23 | 23 | 'width' => '10%', |
@@ -25,7 +25,7 @@ discard block |
||
| 25 | 25 | 'name' => 'status', |
| 26 | 26 | ), |
| 27 | 27 | 'template_type' => |
| 28 | - array ( |
|
| 28 | + array( |
|
| 29 | 29 | 'type' => 'enum', |
| 30 | 30 | 'label' => 'LBL_TEMPLATE_TYPE', |
| 31 | 31 | 'width' => '10%', |
@@ -33,27 +33,27 @@ discard block |
||
| 33 | 33 | 'name' => 'template_type', |
| 34 | 34 | ), |
| 35 | 35 | 'category_id' => |
| 36 | - array ( |
|
| 36 | + array( |
|
| 37 | 37 | 'name' => 'category_id', |
| 38 | 38 | 'default' => true, |
| 39 | 39 | 'width' => '10%', |
| 40 | 40 | ), |
| 41 | 41 | 'subcategory_id' => |
| 42 | - array ( |
|
| 42 | + array( |
|
| 43 | 43 | 'name' => 'subcategory_id', |
| 44 | 44 | 'default' => true, |
| 45 | 45 | 'width' => '10%', |
| 46 | 46 | ), |
| 47 | 47 | 'assigned_user_id' => |
| 48 | - array ( |
|
| 48 | + array( |
|
| 49 | 49 | 'name' => 'assigned_user_id', |
| 50 | 50 | 'type' => 'enum', |
| 51 | 51 | 'label' => 'LBL_ASSIGNED_TO', |
| 52 | 52 | 'function' => |
| 53 | - array ( |
|
| 53 | + array( |
|
| 54 | 54 | 'name' => 'get_user_array', |
| 55 | 55 | 'params' => |
| 56 | - array ( |
|
| 56 | + array( |
|
| 57 | 57 | 0 => false, |
| 58 | 58 | ), |
| 59 | 59 | ), |
@@ -61,13 +61,13 @@ discard block |
||
| 61 | 61 | 'width' => '10%', |
| 62 | 62 | ), |
| 63 | 63 | 'active_date' => |
| 64 | - array ( |
|
| 64 | + array( |
|
| 65 | 65 | 'name' => 'active_date', |
| 66 | 66 | 'default' => true, |
| 67 | 67 | 'width' => '10%', |
| 68 | 68 | ), |
| 69 | 69 | 'exp_date' => |
| 70 | - array ( |
|
| 70 | + array( |
|
| 71 | 71 | 'name' => 'exp_date', |
| 72 | 72 | 'default' => true, |
| 73 | 73 | 'width' => '10%', |
@@ -75,11 +75,11 @@ discard block |
||
| 75 | 75 | ), |
| 76 | 76 | ), |
| 77 | 77 | 'templateMeta' => |
| 78 | - array ( |
|
| 78 | + array( |
|
| 79 | 79 | 'maxColumns' => '3', |
| 80 | 80 | 'maxColumnsBasic' => '4', |
| 81 | 81 | 'widths' => |
| 82 | - array ( |
|
| 82 | + array( |
|
| 83 | 83 | 'label' => '10', |
| 84 | 84 | 'field' => '30', |
| 85 | 85 | ), |
@@ -3,36 +3,36 @@ discard block |
||
| 3 | 3 | global $current_user; |
| 4 | 4 | $module_name = "Documents"; |
| 5 | 5 | $searchFields['Documents'] = array ( |
| 6 | - 'document_name' => |
|
| 7 | - array ( |
|
| 6 | + 'document_name' => |
|
| 7 | + array ( |
|
| 8 | 8 | 'query_type' => 'default', |
| 9 | - ), |
|
| 10 | - 'category_id' => |
|
| 11 | - array ( |
|
| 9 | + ), |
|
| 10 | + 'category_id' => |
|
| 11 | + array ( |
|
| 12 | 12 | 'query_type' => 'default', |
| 13 | 13 | 'options' => 'document_category_dom', |
| 14 | 14 | 'template_var' => 'CATEGORY_OPTIONS', |
| 15 | - ), |
|
| 16 | - 'subcategory_id' => |
|
| 17 | - array ( |
|
| 15 | + ), |
|
| 16 | + 'subcategory_id' => |
|
| 17 | + array ( |
|
| 18 | 18 | 'query_type' => 'default', |
| 19 | 19 | 'options' => 'document_subcategory_dom', |
| 20 | 20 | 'template_var' => 'SUBCATEGORY_OPTIONS', |
| 21 | - ), |
|
| 22 | - 'active_date' => |
|
| 23 | - array ( |
|
| 21 | + ), |
|
| 22 | + 'active_date' => |
|
| 23 | + array ( |
|
| 24 | 24 | 'query_type' => 'default', |
| 25 | - ), |
|
| 26 | - 'exp_date' => |
|
| 27 | - array ( |
|
| 25 | + ), |
|
| 26 | + 'exp_date' => |
|
| 27 | + array ( |
|
| 28 | 28 | 'query_type' => 'default', |
| 29 | - ), |
|
| 30 | - 'assigned_user_id' => |
|
| 31 | - array ( |
|
| 29 | + ), |
|
| 30 | + 'assigned_user_id' => |
|
| 31 | + array ( |
|
| 32 | 32 | 'query_type' => 'default', |
| 33 | - ), |
|
| 34 | - 'filename' => |
|
| 35 | - array ( |
|
| 33 | + ), |
|
| 34 | + 'filename' => |
|
| 35 | + array ( |
|
| 36 | 36 | 'query_type' => 'format', |
| 37 | 37 | 'operator' => 'subquery', |
| 38 | 38 | 'subquery' => 'SELECT document_revisions.id FROM document_revisions |
@@ -40,45 +40,45 @@ discard block |
||
| 40 | 40 | AND document_revisions.filename LIKE \'{0}\'', |
| 41 | 41 | 'db_field' => |
| 42 | 42 | array ( |
| 43 | - 0 => 'document_revision_id', |
|
| 43 | + 0 => 'document_revision_id', |
|
| 44 | 44 | ), |
| 45 | - ), |
|
| 46 | - 'range_date_entered' => |
|
| 47 | - array ( |
|
| 45 | + ), |
|
| 46 | + 'range_date_entered' => |
|
| 47 | + array ( |
|
| 48 | 48 | 'query_type' => 'default', |
| 49 | 49 | 'enable_range_search' => true, |
| 50 | 50 | 'is_date_field' => true, |
| 51 | - ), |
|
| 52 | - 'start_range_date_entered' => |
|
| 53 | - array ( |
|
| 51 | + ), |
|
| 52 | + 'start_range_date_entered' => |
|
| 53 | + array ( |
|
| 54 | 54 | 'query_type' => 'default', |
| 55 | 55 | 'enable_range_search' => true, |
| 56 | 56 | 'is_date_field' => true, |
| 57 | - ), |
|
| 58 | - 'end_range_date_entered' => |
|
| 59 | - array ( |
|
| 57 | + ), |
|
| 58 | + 'end_range_date_entered' => |
|
| 59 | + array ( |
|
| 60 | 60 | 'query_type' => 'default', |
| 61 | 61 | 'enable_range_search' => true, |
| 62 | 62 | 'is_date_field' => true, |
| 63 | - ), |
|
| 64 | - 'range_date_modified' => |
|
| 65 | - array ( |
|
| 63 | + ), |
|
| 64 | + 'range_date_modified' => |
|
| 65 | + array ( |
|
| 66 | 66 | 'query_type' => 'default', |
| 67 | 67 | 'enable_range_search' => true, |
| 68 | 68 | 'is_date_field' => true, |
| 69 | - ), |
|
| 70 | - 'start_range_date_modified' => |
|
| 71 | - array ( |
|
| 69 | + ), |
|
| 70 | + 'start_range_date_modified' => |
|
| 71 | + array ( |
|
| 72 | 72 | 'query_type' => 'default', |
| 73 | 73 | 'enable_range_search' => true, |
| 74 | 74 | 'is_date_field' => true, |
| 75 | - ), |
|
| 76 | - 'end_range_date_modified' => |
|
| 77 | - array ( |
|
| 75 | + ), |
|
| 76 | + 'end_range_date_modified' => |
|
| 77 | + array ( |
|
| 78 | 78 | 'query_type' => 'default', |
| 79 | 79 | 'enable_range_search' => true, |
| 80 | 80 | 'is_date_field' => true, |
| 81 | - ), |
|
| 81 | + ), |
|
| 82 | 82 | 'favorites_only' => array( |
| 83 | 83 | 'query_type'=>'format', |
| 84 | 84 | 'operator' => 'subquery', |
@@ -2,79 +2,79 @@ discard block |
||
| 2 | 2 | // created: 2015-02-17 15:14:28 |
| 3 | 3 | global $current_user; |
| 4 | 4 | $module_name = "Documents"; |
| 5 | -$searchFields['Documents'] = array ( |
|
| 5 | +$searchFields['Documents'] = array( |
|
| 6 | 6 | 'document_name' => |
| 7 | - array ( |
|
| 7 | + array( |
|
| 8 | 8 | 'query_type' => 'default', |
| 9 | 9 | ), |
| 10 | 10 | 'category_id' => |
| 11 | - array ( |
|
| 11 | + array( |
|
| 12 | 12 | 'query_type' => 'default', |
| 13 | 13 | 'options' => 'document_category_dom', |
| 14 | 14 | 'template_var' => 'CATEGORY_OPTIONS', |
| 15 | 15 | ), |
| 16 | 16 | 'subcategory_id' => |
| 17 | - array ( |
|
| 17 | + array( |
|
| 18 | 18 | 'query_type' => 'default', |
| 19 | 19 | 'options' => 'document_subcategory_dom', |
| 20 | 20 | 'template_var' => 'SUBCATEGORY_OPTIONS', |
| 21 | 21 | ), |
| 22 | 22 | 'active_date' => |
| 23 | - array ( |
|
| 23 | + array( |
|
| 24 | 24 | 'query_type' => 'default', |
| 25 | 25 | ), |
| 26 | 26 | 'exp_date' => |
| 27 | - array ( |
|
| 27 | + array( |
|
| 28 | 28 | 'query_type' => 'default', |
| 29 | 29 | ), |
| 30 | 30 | 'assigned_user_id' => |
| 31 | - array ( |
|
| 31 | + array( |
|
| 32 | 32 | 'query_type' => 'default', |
| 33 | 33 | ), |
| 34 | 34 | 'filename' => |
| 35 | - array ( |
|
| 35 | + array( |
|
| 36 | 36 | 'query_type' => 'format', |
| 37 | 37 | 'operator' => 'subquery', |
| 38 | 38 | 'subquery' => 'SELECT document_revisions.id FROM document_revisions |
| 39 | 39 | WHERE document_revisions.deleted=0 |
| 40 | 40 | AND document_revisions.filename LIKE \'{0}\'', |
| 41 | 41 | 'db_field' => |
| 42 | - array ( |
|
| 42 | + array( |
|
| 43 | 43 | 0 => 'document_revision_id', |
| 44 | 44 | ), |
| 45 | 45 | ), |
| 46 | 46 | 'range_date_entered' => |
| 47 | - array ( |
|
| 47 | + array( |
|
| 48 | 48 | 'query_type' => 'default', |
| 49 | 49 | 'enable_range_search' => true, |
| 50 | 50 | 'is_date_field' => true, |
| 51 | 51 | ), |
| 52 | 52 | 'start_range_date_entered' => |
| 53 | - array ( |
|
| 53 | + array( |
|
| 54 | 54 | 'query_type' => 'default', |
| 55 | 55 | 'enable_range_search' => true, |
| 56 | 56 | 'is_date_field' => true, |
| 57 | 57 | ), |
| 58 | 58 | 'end_range_date_entered' => |
| 59 | - array ( |
|
| 59 | + array( |
|
| 60 | 60 | 'query_type' => 'default', |
| 61 | 61 | 'enable_range_search' => true, |
| 62 | 62 | 'is_date_field' => true, |
| 63 | 63 | ), |
| 64 | 64 | 'range_date_modified' => |
| 65 | - array ( |
|
| 65 | + array( |
|
| 66 | 66 | 'query_type' => 'default', |
| 67 | 67 | 'enable_range_search' => true, |
| 68 | 68 | 'is_date_field' => true, |
| 69 | 69 | ), |
| 70 | 70 | 'start_range_date_modified' => |
| 71 | - array ( |
|
| 71 | + array( |
|
| 72 | 72 | 'query_type' => 'default', |
| 73 | 73 | 'enable_range_search' => true, |
| 74 | 74 | 'is_date_field' => true, |
| 75 | 75 | ), |
| 76 | 76 | 'end_range_date_modified' => |
| 77 | - array ( |
|
| 77 | + array( |
|
| 78 | 78 | 'query_type' => 'default', |
| 79 | 79 | 'enable_range_search' => true, |
| 80 | 80 | 'is_date_field' => true, |
@@ -85,6 +85,6 @@ discard block |
||
| 85 | 85 | 'subquery' => 'SELECT favorites.parent_id FROM favorites |
| 86 | 86 | WHERE favorites.deleted = 0 |
| 87 | 87 | and favorites.parent_type = "'.$module_name.'" |
| 88 | - and favorites.assigned_user_id = "' .$current_user->id . '") OR NOT ({0}', |
|
| 88 | + and favorites.assigned_user_id = "' .$current_user->id.'") OR NOT ({0}', |
|
| 89 | 89 | 'db_field'=>array('id')), |
| 90 | 90 | ); |
| 91 | 91 | \ No newline at end of file |
@@ -39,140 +39,140 @@ |
||
| 39 | 39 | |
| 40 | 40 | $viewdefs ['Documents'] = |
| 41 | 41 | array ( |
| 42 | - 'DetailView' => |
|
| 43 | - array ( |
|
| 42 | + 'DetailView' => |
|
| 43 | + array ( |
|
| 44 | 44 | 'templateMeta' => |
| 45 | 45 | array ( |
| 46 | - 'maxColumns' => '2', |
|
| 47 | - 'form' => |
|
| 48 | - array ( |
|
| 46 | + 'maxColumns' => '2', |
|
| 47 | + 'form' => |
|
| 48 | + array ( |
|
| 49 | 49 | 'hidden' => |
| 50 | 50 | array ( |
| 51 | - 0 => '<input type="hidden" name="old_id" value="{$fields.document_revision_id.value}">', |
|
| 51 | + 0 => '<input type="hidden" name="old_id" value="{$fields.document_revision_id.value}">', |
|
| 52 | 52 | ), |
| 53 | - ), |
|
| 54 | - 'widths' => |
|
| 55 | - array ( |
|
| 53 | + ), |
|
| 54 | + 'widths' => |
|
| 55 | + array ( |
|
| 56 | 56 | 0 => |
| 57 | 57 | array ( |
| 58 | - 'label' => '10', |
|
| 59 | - 'field' => '30', |
|
| 58 | + 'label' => '10', |
|
| 59 | + 'field' => '30', |
|
| 60 | 60 | ), |
| 61 | 61 | 1 => |
| 62 | 62 | array ( |
| 63 | - 'label' => '10', |
|
| 64 | - 'field' => '30', |
|
| 63 | + 'label' => '10', |
|
| 64 | + 'field' => '30', |
|
| 65 | 65 | ), |
| 66 | - ), |
|
| 67 | - 'useTabs' => true, |
|
| 68 | - 'tabDefs' => |
|
| 69 | - array ( |
|
| 66 | + ), |
|
| 67 | + 'useTabs' => true, |
|
| 68 | + 'tabDefs' => |
|
| 69 | + array ( |
|
| 70 | 70 | 'LBL_DOCUMENT_INFORMATION' => |
| 71 | 71 | array ( |
| 72 | - 'newTab' => true, |
|
| 73 | - 'panelDefault' => 'expanded', |
|
| 72 | + 'newTab' => true, |
|
| 73 | + 'panelDefault' => 'expanded', |
|
| 74 | 74 | ), |
| 75 | 75 | 'LBL_PANEL_ASSIGNMENT' => |
| 76 | 76 | array ( |
| 77 | - 'newTab' => true, |
|
| 78 | - 'panelDefault' => 'expanded', |
|
| 77 | + 'newTab' => true, |
|
| 78 | + 'panelDefault' => 'expanded', |
|
| 79 | + ), |
|
| 79 | 80 | ), |
| 80 | - ), |
|
| 81 | 81 | ), |
| 82 | 82 | 'panels' => |
| 83 | 83 | array ( |
| 84 | - 'lbl_document_information' => |
|
| 85 | - array ( |
|
| 84 | + 'lbl_document_information' => |
|
| 85 | + array ( |
|
| 86 | 86 | 0 => |
| 87 | 87 | array ( |
| 88 | - 0 => |
|
| 89 | - array ( |
|
| 88 | + 0 => |
|
| 89 | + array ( |
|
| 90 | 90 | 'name' => 'filename', |
| 91 | 91 | 'displayParams' => |
| 92 | 92 | array ( |
| 93 | - 'link' => 'filename', |
|
| 94 | - 'id' => 'document_revision_id', |
|
| 93 | + 'link' => 'filename', |
|
| 94 | + 'id' => 'document_revision_id', |
|
| 95 | + ), |
|
| 95 | 96 | ), |
| 96 | - ), |
|
| 97 | - 1 => |
|
| 98 | - array ( |
|
| 97 | + 1 => |
|
| 98 | + array ( |
|
| 99 | 99 | 'name' => 'status_id', |
| 100 | 100 | 'label' => 'LBL_DOC_STATUS', |
| 101 | - ), |
|
| 101 | + ), |
|
| 102 | 102 | ), |
| 103 | 103 | 1 => |
| 104 | 104 | array ( |
| 105 | - 0 => |
|
| 106 | - array ( |
|
| 105 | + 0 => |
|
| 106 | + array ( |
|
| 107 | 107 | 'name' => 'document_name', |
| 108 | 108 | 'label' => 'LBL_DOC_NAME', |
| 109 | - ), |
|
| 110 | - 1 => |
|
| 111 | - array ( |
|
| 109 | + ), |
|
| 110 | + 1 => |
|
| 111 | + array ( |
|
| 112 | 112 | 'name' => 'revision', |
| 113 | 113 | 'label' => 'LBL_DOC_VERSION', |
| 114 | - ), |
|
| 114 | + ), |
|
| 115 | 115 | ), |
| 116 | 116 | 2 => |
| 117 | 117 | array ( |
| 118 | - 0 => |
|
| 119 | - array ( |
|
| 118 | + 0 => |
|
| 119 | + array ( |
|
| 120 | 120 | 'name' => 'template_type', |
| 121 | 121 | 'label' => 'LBL_DET_TEMPLATE_TYPE', |
| 122 | - ), |
|
| 123 | - 1 => |
|
| 124 | - array ( |
|
| 122 | + ), |
|
| 123 | + 1 => |
|
| 124 | + array ( |
|
| 125 | 125 | 'name' => 'is_template', |
| 126 | 126 | 'label' => 'LBL_DET_IS_TEMPLATE', |
| 127 | - ), |
|
| 127 | + ), |
|
| 128 | 128 | ), |
| 129 | 129 | 3 => |
| 130 | 130 | array ( |
| 131 | - 0 => 'active_date', |
|
| 132 | - 1 => 'exp_date', |
|
| 131 | + 0 => 'active_date', |
|
| 132 | + 1 => 'exp_date', |
|
| 133 | 133 | ), |
| 134 | 134 | 4 => |
| 135 | 135 | array ( |
| 136 | - 0 => 'category_id', |
|
| 137 | - 1 => 'subcategory_id', |
|
| 136 | + 0 => 'category_id', |
|
| 137 | + 1 => 'subcategory_id', |
|
| 138 | 138 | ), |
| 139 | 139 | 5 => |
| 140 | 140 | array ( |
| 141 | - 0 => '', |
|
| 142 | - 1 => '', |
|
| 141 | + 0 => '', |
|
| 142 | + 1 => '', |
|
| 143 | 143 | ), |
| 144 | 144 | 6 => |
| 145 | 145 | array ( |
| 146 | - 0 => 'related_doc_name', |
|
| 147 | - 1 => 'related_doc_rev_number', |
|
| 146 | + 0 => 'related_doc_name', |
|
| 147 | + 1 => 'related_doc_rev_number', |
|
| 148 | 148 | ), |
| 149 | 149 | 7 => |
| 150 | 150 | array ( |
| 151 | - 0 => |
|
| 152 | - array ( |
|
| 151 | + 0 => |
|
| 152 | + array ( |
|
| 153 | 153 | 'name' => 'assigned_user_name', |
| 154 | 154 | 'label' => 'LBL_ASSIGNED_TO_NAME', |
| 155 | - ), |
|
| 155 | + ), |
|
| 156 | 156 | ), |
| 157 | - ), |
|
| 158 | - 'LBL_PANEL_ASSIGNMENT' => |
|
| 159 | - array ( |
|
| 157 | + ), |
|
| 158 | + 'LBL_PANEL_ASSIGNMENT' => |
|
| 159 | + array ( |
|
| 160 | 160 | 0 => |
| 161 | 161 | array ( |
| 162 | - 0 => |
|
| 163 | - array ( |
|
| 164 | - 'name' => 'date_entered', |
|
| 165 | - 'customCode' => '{$fields.date_entered.value} {$APP.LBL_BY} {$fields.created_by_name.value}', |
|
| 166 | - ), |
|
| 167 | - 1 => |
|
| 168 | - array ( |
|
| 169 | - 'name' => 'date_modified', |
|
| 170 | - 'label' => 'LBL_DATE_MODIFIED', |
|
| 171 | - 'customCode' => '{$fields.date_modified.value} {$APP.LBL_BY} {$fields.modified_by_name.value}', |
|
| 172 | - ), |
|
| 173 | - ), |
|
| 174 | - ), |
|
| 162 | + 0 => |
|
| 163 | + array ( |
|
| 164 | + 'name' => 'date_entered', |
|
| 165 | + 'customCode' => '{$fields.date_entered.value} {$APP.LBL_BY} {$fields.created_by_name.value}', |
|
| 166 | + ), |
|
| 167 | + 1 => |
|
| 168 | + array ( |
|
| 169 | + 'name' => 'date_modified', |
|
| 170 | + 'label' => 'LBL_DATE_MODIFIED', |
|
| 171 | + 'customCode' => '{$fields.date_modified.value} {$APP.LBL_BY} {$fields.modified_by_name.value}', |
|
| 172 | + ), |
|
| 173 | + ), |
|
| 174 | + ), |
|
| 175 | + ), |
|
| 175 | 176 | ), |
| 176 | - ), |
|
| 177 | 177 | ); |
| 178 | 178 | ?> |
@@ -38,134 +38,134 @@ |
||
| 38 | 38 | ********************************************************************************/ |
| 39 | 39 | |
| 40 | 40 | $viewdefs ['Documents'] = |
| 41 | -array ( |
|
| 41 | +array( |
|
| 42 | 42 | 'DetailView' => |
| 43 | - array ( |
|
| 43 | + array( |
|
| 44 | 44 | 'templateMeta' => |
| 45 | - array ( |
|
| 45 | + array( |
|
| 46 | 46 | 'maxColumns' => '2', |
| 47 | 47 | 'form' => |
| 48 | - array ( |
|
| 48 | + array( |
|
| 49 | 49 | 'hidden' => |
| 50 | - array ( |
|
| 50 | + array( |
|
| 51 | 51 | 0 => '<input type="hidden" name="old_id" value="{$fields.document_revision_id.value}">', |
| 52 | 52 | ), |
| 53 | 53 | ), |
| 54 | 54 | 'widths' => |
| 55 | - array ( |
|
| 55 | + array( |
|
| 56 | 56 | 0 => |
| 57 | - array ( |
|
| 57 | + array( |
|
| 58 | 58 | 'label' => '10', |
| 59 | 59 | 'field' => '30', |
| 60 | 60 | ), |
| 61 | 61 | 1 => |
| 62 | - array ( |
|
| 62 | + array( |
|
| 63 | 63 | 'label' => '10', |
| 64 | 64 | 'field' => '30', |
| 65 | 65 | ), |
| 66 | 66 | ), |
| 67 | 67 | 'useTabs' => true, |
| 68 | 68 | 'tabDefs' => |
| 69 | - array ( |
|
| 69 | + array( |
|
| 70 | 70 | 'LBL_DOCUMENT_INFORMATION' => |
| 71 | - array ( |
|
| 71 | + array( |
|
| 72 | 72 | 'newTab' => true, |
| 73 | 73 | 'panelDefault' => 'expanded', |
| 74 | 74 | ), |
| 75 | 75 | 'LBL_PANEL_ASSIGNMENT' => |
| 76 | - array ( |
|
| 76 | + array( |
|
| 77 | 77 | 'newTab' => true, |
| 78 | 78 | 'panelDefault' => 'expanded', |
| 79 | 79 | ), |
| 80 | 80 | ), |
| 81 | 81 | ), |
| 82 | 82 | 'panels' => |
| 83 | - array ( |
|
| 83 | + array( |
|
| 84 | 84 | 'lbl_document_information' => |
| 85 | - array ( |
|
| 85 | + array( |
|
| 86 | 86 | 0 => |
| 87 | - array ( |
|
| 87 | + array( |
|
| 88 | 88 | 0 => |
| 89 | - array ( |
|
| 89 | + array( |
|
| 90 | 90 | 'name' => 'filename', |
| 91 | 91 | 'displayParams' => |
| 92 | - array ( |
|
| 92 | + array( |
|
| 93 | 93 | 'link' => 'filename', |
| 94 | 94 | 'id' => 'document_revision_id', |
| 95 | 95 | ), |
| 96 | 96 | ), |
| 97 | 97 | 1 => |
| 98 | - array ( |
|
| 98 | + array( |
|
| 99 | 99 | 'name' => 'status_id', |
| 100 | 100 | 'label' => 'LBL_DOC_STATUS', |
| 101 | 101 | ), |
| 102 | 102 | ), |
| 103 | 103 | 1 => |
| 104 | - array ( |
|
| 104 | + array( |
|
| 105 | 105 | 0 => |
| 106 | - array ( |
|
| 106 | + array( |
|
| 107 | 107 | 'name' => 'document_name', |
| 108 | 108 | 'label' => 'LBL_DOC_NAME', |
| 109 | 109 | ), |
| 110 | 110 | 1 => |
| 111 | - array ( |
|
| 111 | + array( |
|
| 112 | 112 | 'name' => 'revision', |
| 113 | 113 | 'label' => 'LBL_DOC_VERSION', |
| 114 | 114 | ), |
| 115 | 115 | ), |
| 116 | 116 | 2 => |
| 117 | - array ( |
|
| 117 | + array( |
|
| 118 | 118 | 0 => |
| 119 | - array ( |
|
| 119 | + array( |
|
| 120 | 120 | 'name' => 'template_type', |
| 121 | 121 | 'label' => 'LBL_DET_TEMPLATE_TYPE', |
| 122 | 122 | ), |
| 123 | 123 | 1 => |
| 124 | - array ( |
|
| 124 | + array( |
|
| 125 | 125 | 'name' => 'is_template', |
| 126 | 126 | 'label' => 'LBL_DET_IS_TEMPLATE', |
| 127 | 127 | ), |
| 128 | 128 | ), |
| 129 | 129 | 3 => |
| 130 | - array ( |
|
| 130 | + array( |
|
| 131 | 131 | 0 => 'active_date', |
| 132 | 132 | 1 => 'exp_date', |
| 133 | 133 | ), |
| 134 | 134 | 4 => |
| 135 | - array ( |
|
| 135 | + array( |
|
| 136 | 136 | 0 => 'category_id', |
| 137 | 137 | 1 => 'subcategory_id', |
| 138 | 138 | ), |
| 139 | 139 | 5 => |
| 140 | - array ( |
|
| 140 | + array( |
|
| 141 | 141 | 0 => '', |
| 142 | 142 | 1 => '', |
| 143 | 143 | ), |
| 144 | 144 | 6 => |
| 145 | - array ( |
|
| 145 | + array( |
|
| 146 | 146 | 0 => 'related_doc_name', |
| 147 | 147 | 1 => 'related_doc_rev_number', |
| 148 | 148 | ), |
| 149 | 149 | 7 => |
| 150 | - array ( |
|
| 150 | + array( |
|
| 151 | 151 | 0 => |
| 152 | - array ( |
|
| 152 | + array( |
|
| 153 | 153 | 'name' => 'assigned_user_name', |
| 154 | 154 | 'label' => 'LBL_ASSIGNED_TO_NAME', |
| 155 | 155 | ), |
| 156 | 156 | ), |
| 157 | 157 | ), |
| 158 | 158 | 'LBL_PANEL_ASSIGNMENT' => |
| 159 | - array ( |
|
| 159 | + array( |
|
| 160 | 160 | 0 => |
| 161 | - array ( |
|
| 161 | + array( |
|
| 162 | 162 | 0 => |
| 163 | - array ( |
|
| 163 | + array( |
|
| 164 | 164 | 'name' => 'date_entered', |
| 165 | 165 | 'customCode' => '{$fields.date_entered.value} {$APP.LBL_BY} {$fields.created_by_name.value}', |
| 166 | 166 | ), |
| 167 | 167 | 1 => |
| 168 | - array ( |
|
| 168 | + array( |
|
| 169 | 169 | 'name' => 'date_modified', |
| 170 | 170 | 'label' => 'LBL_DATE_MODIFIED', |
| 171 | 171 | 'customCode' => '{$fields.date_modified.value} {$APP.LBL_BY} {$fields.modified_by_name.value}', |
@@ -49,42 +49,42 @@ |
||
| 49 | 49 | array('label' => '10', 'field' => '30') |
| 50 | 50 | ), |
| 51 | 51 | 'includes' => |
| 52 | - array ( |
|
| 52 | + array ( |
|
| 53 | 53 | array('file' => 'include/javascript/popup_parent_helper.js'), |
| 54 | 54 | array('file' => 'cache/include/javascript/sugar_grp_jsolait.js'), |
| 55 | 55 | array('file' => 'modules/Documents/documents.js'), |
| 56 | - ), |
|
| 56 | + ), |
|
| 57 | 57 | ), |
| 58 | - 'panels' =>array ( |
|
| 59 | - 'default' => |
|
| 60 | - array ( |
|
| 58 | + 'panels' =>array ( |
|
| 59 | + 'default' => |
|
| 60 | + array ( |
|
| 61 | 61 | |
| 62 | 62 | array ( |
| 63 | - 'status_id', |
|
| 63 | + 'status_id', |
|
| 64 | 64 | ), |
| 65 | 65 | array ( |
| 66 | - array('name'=>'filename', |
|
| 66 | + array('name'=>'filename', |
|
| 67 | 67 | 'displayParams'=>array('required'=>true, 'onchangeSetFileNameTo' => 'document_name'), |
| 68 | 68 | ), |
| 69 | 69 | ), |
| 70 | 70 | |
| 71 | 71 | array ( |
| 72 | - 'document_name', |
|
| 73 | - array('name'=>'revision', |
|
| 72 | + 'document_name', |
|
| 73 | + array('name'=>'revision', |
|
| 74 | 74 | 'customCode' => '<input name="revision" type="text" value="{$fields.revision.value}" {$DISABLED}>' |
| 75 | - ), |
|
| 75 | + ), |
|
| 76 | 76 | ), |
| 77 | 77 | |
| 78 | 78 | array ( |
| 79 | - array('name'=>'active_date','displayParams'=>array('required'=>true)), |
|
| 80 | - 'category_id', |
|
| 79 | + array('name'=>'active_date','displayParams'=>array('required'=>true)), |
|
| 80 | + 'category_id', |
|
| 81 | 81 | ), |
| 82 | 82 | |
| 83 | 83 | |
| 84 | 84 | array ( |
| 85 | - array('name'=>'description', 'displayParams'=>array('rows'=>10, 'cols'=>120)), |
|
| 85 | + array('name'=>'description', 'displayParams'=>array('rows'=>10, 'cols'=>120)), |
|
| 86 | + ), |
|
| 86 | 87 | ), |
| 87 | - ), |
|
| 88 | 88 | ) |
| 89 | 89 | |
| 90 | 90 | ); |
@@ -49,39 +49,39 @@ |
||
| 49 | 49 | array('label' => '10', 'field' => '30') |
| 50 | 50 | ), |
| 51 | 51 | 'includes' => |
| 52 | - array ( |
|
| 52 | + array( |
|
| 53 | 53 | array('file' => 'include/javascript/popup_parent_helper.js'), |
| 54 | 54 | array('file' => 'cache/include/javascript/sugar_grp_jsolait.js'), |
| 55 | 55 | array('file' => 'modules/Documents/documents.js'), |
| 56 | 56 | ), |
| 57 | 57 | ), |
| 58 | - 'panels' =>array ( |
|
| 58 | + 'panels' =>array( |
|
| 59 | 59 | 'default' => |
| 60 | - array ( |
|
| 60 | + array( |
|
| 61 | 61 | |
| 62 | - array ( |
|
| 62 | + array( |
|
| 63 | 63 | 'status_id', |
| 64 | 64 | ), |
| 65 | - array ( |
|
| 65 | + array( |
|
| 66 | 66 | array('name'=>'filename', |
| 67 | 67 | 'displayParams'=>array('required'=>true, 'onchangeSetFileNameTo' => 'document_name'), |
| 68 | 68 | ), |
| 69 | 69 | ), |
| 70 | 70 | |
| 71 | - array ( |
|
| 71 | + array( |
|
| 72 | 72 | 'document_name', |
| 73 | 73 | array('name'=>'revision', |
| 74 | 74 | 'customCode' => '<input name="revision" type="text" value="{$fields.revision.value}" {$DISABLED}>' |
| 75 | 75 | ), |
| 76 | 76 | ), |
| 77 | 77 | |
| 78 | - array ( |
|
| 79 | - array('name'=>'active_date','displayParams'=>array('required'=>true)), |
|
| 78 | + array( |
|
| 79 | + array('name'=>'active_date', 'displayParams'=>array('required'=>true)), |
|
| 80 | 80 | 'category_id', |
| 81 | 81 | ), |
| 82 | 82 | |
| 83 | 83 | |
| 84 | - array ( |
|
| 84 | + array( |
|
| 85 | 85 | array('name'=>'description', 'displayParams'=>array('rows'=>10, 'cols'=>120)), |
| 86 | 86 | ), |
| 87 | 87 | ), |
@@ -42,16 +42,16 @@ discard block |
||
| 42 | 42 | |
| 43 | 43 | |
| 44 | 44 | $listViewDefs['Documents'] = array( |
| 45 | - 'DOCUMENT_NAME' => |
|
| 46 | - array ( |
|
| 45 | + 'DOCUMENT_NAME' => |
|
| 46 | + array ( |
|
| 47 | 47 | 'width' => '20%', |
| 48 | 48 | 'label' => 'LBL_NAME', |
| 49 | 49 | 'link' => true, |
| 50 | 50 | 'default' => true, |
| 51 | 51 | 'bold' => true, |
| 52 | - ), |
|
| 53 | - 'FILENAME' => |
|
| 54 | - array ( |
|
| 52 | + ), |
|
| 53 | + 'FILENAME' => |
|
| 54 | + array ( |
|
| 55 | 55 | 'width' => '20%', |
| 56 | 56 | 'label' => 'LBL_FILENAME', |
| 57 | 57 | 'link' => true, |
@@ -66,45 +66,45 @@ discard block |
||
| 66 | 66 | 2 => 'doc_type', |
| 67 | 67 | 3 => 'doc_url', |
| 68 | 68 | ), |
| 69 | - ), |
|
| 70 | - 'CATEGORY_ID' => |
|
| 71 | - array ( |
|
| 69 | + ), |
|
| 70 | + 'CATEGORY_ID' => |
|
| 71 | + array ( |
|
| 72 | 72 | 'width' => '10%', |
| 73 | 73 | 'label' => 'LBL_LIST_CATEGORY', |
| 74 | 74 | 'default' => true, |
| 75 | - ), |
|
| 76 | - 'SUBCATEGORY_ID' => |
|
| 77 | - array ( |
|
| 75 | + ), |
|
| 76 | + 'SUBCATEGORY_ID' => |
|
| 77 | + array ( |
|
| 78 | 78 | 'width' => '15%', |
| 79 | 79 | 'label' => 'LBL_LIST_SUBCATEGORY', |
| 80 | 80 | 'default' => true, |
| 81 | - ), |
|
| 82 | - 'LAST_REV_CREATE_DATE' => |
|
| 83 | - array ( |
|
| 81 | + ), |
|
| 82 | + 'LAST_REV_CREATE_DATE' => |
|
| 83 | + array ( |
|
| 84 | 84 | 'width' => '10%', |
| 85 | 85 | 'label' => 'LBL_LIST_LAST_REV_DATE', |
| 86 | 86 | 'default' => true, |
| 87 | 87 | 'sortable' => false, |
| 88 | 88 | 'related_fields' => |
| 89 | 89 | array ( |
| 90 | - 0 => 'document_revision_id', |
|
| 90 | + 0 => 'document_revision_id', |
|
| 91 | + ), |
|
| 91 | 92 | ), |
| 92 | - ), |
|
| 93 | - 'EXP_DATE' => |
|
| 94 | - array ( |
|
| 93 | + 'EXP_DATE' => |
|
| 94 | + array ( |
|
| 95 | 95 | 'width' => '10%', |
| 96 | 96 | 'label' => 'LBL_LIST_EXP_DATE', |
| 97 | 97 | 'default' => true, |
| 98 | - ), |
|
| 99 | - 'ASSIGNED_USER_NAME' => |
|
| 100 | - array( |
|
| 98 | + ), |
|
| 99 | + 'ASSIGNED_USER_NAME' => |
|
| 100 | + array( |
|
| 101 | 101 | 'width' => '10', |
| 102 | 102 | 'label' => 'LBL_LIST_ASSIGNED_USER', |
| 103 | 103 | 'module' => 'Employees', |
| 104 | 104 | 'id' => 'ASSIGNED_USER_ID', |
| 105 | 105 | 'default' => true), |
| 106 | - 'MODIFIED_BY_NAME' => |
|
| 107 | - array ( |
|
| 106 | + 'MODIFIED_BY_NAME' => |
|
| 107 | + array ( |
|
| 108 | 108 | 'width' => '10%', |
| 109 | 109 | 'label' => 'LBL_MODIFIED_USER', |
| 110 | 110 | 'module' => 'Users', |
@@ -113,13 +113,13 @@ discard block |
||
| 113 | 113 | 'sortable' => false, |
| 114 | 114 | 'related_fields' => |
| 115 | 115 | array ( |
| 116 | - 0 => 'modified_user_id', |
|
| 116 | + 0 => 'modified_user_id', |
|
| 117 | 117 | ), |
| 118 | 118 | ), |
| 119 | - 'DATE_ENTERED' => array ( |
|
| 119 | + 'DATE_ENTERED' => array ( |
|
| 120 | 120 | 'width' => '10%', |
| 121 | 121 | 'label' => 'LBL_DATE_ENTERED', |
| 122 | 122 | 'default' => true, |
| 123 | - ) |
|
| 123 | + ) |
|
| 124 | 124 | ); |
| 125 | 125 | ?> |
| 126 | 126 | \ No newline at end of file |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 3 | 3 | /********************************************************************************* |
| 4 | 4 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 5 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -43,7 +43,7 @@ discard block |
||
| 43 | 43 | |
| 44 | 44 | $listViewDefs['Documents'] = array( |
| 45 | 45 | 'DOCUMENT_NAME' => |
| 46 | - array ( |
|
| 46 | + array( |
|
| 47 | 47 | 'width' => '20%', |
| 48 | 48 | 'label' => 'LBL_NAME', |
| 49 | 49 | 'link' => true, |
@@ -51,16 +51,16 @@ discard block |
||
| 51 | 51 | 'bold' => true, |
| 52 | 52 | ), |
| 53 | 53 | 'FILENAME' => |
| 54 | - array ( |
|
| 54 | + array( |
|
| 55 | 55 | 'width' => '20%', |
| 56 | 56 | 'label' => 'LBL_FILENAME', |
| 57 | 57 | 'link' => true, |
| 58 | 58 | 'default' => true, |
| 59 | 59 | 'bold' => false, |
| 60 | - 'displayParams' => array ( 'module' => 'Documents', ), |
|
| 60 | + 'displayParams' => array('module' => 'Documents',), |
|
| 61 | 61 | 'sortable' => false, |
| 62 | 62 | 'related_fields' => |
| 63 | - array ( |
|
| 63 | + array( |
|
| 64 | 64 | 0 => 'document_revision_id', |
| 65 | 65 | 1 => 'doc_id', |
| 66 | 66 | 2 => 'doc_type', |
@@ -68,30 +68,30 @@ discard block |
||
| 68 | 68 | ), |
| 69 | 69 | ), |
| 70 | 70 | 'CATEGORY_ID' => |
| 71 | - array ( |
|
| 71 | + array( |
|
| 72 | 72 | 'width' => '10%', |
| 73 | 73 | 'label' => 'LBL_LIST_CATEGORY', |
| 74 | 74 | 'default' => true, |
| 75 | 75 | ), |
| 76 | 76 | 'SUBCATEGORY_ID' => |
| 77 | - array ( |
|
| 77 | + array( |
|
| 78 | 78 | 'width' => '15%', |
| 79 | 79 | 'label' => 'LBL_LIST_SUBCATEGORY', |
| 80 | 80 | 'default' => true, |
| 81 | 81 | ), |
| 82 | 82 | 'LAST_REV_CREATE_DATE' => |
| 83 | - array ( |
|
| 83 | + array( |
|
| 84 | 84 | 'width' => '10%', |
| 85 | 85 | 'label' => 'LBL_LIST_LAST_REV_DATE', |
| 86 | 86 | 'default' => true, |
| 87 | 87 | 'sortable' => false, |
| 88 | 88 | 'related_fields' => |
| 89 | - array ( |
|
| 89 | + array( |
|
| 90 | 90 | 0 => 'document_revision_id', |
| 91 | 91 | ), |
| 92 | 92 | ), |
| 93 | 93 | 'EXP_DATE' => |
| 94 | - array ( |
|
| 94 | + array( |
|
| 95 | 95 | 'width' => '10%', |
| 96 | 96 | 'label' => 'LBL_LIST_EXP_DATE', |
| 97 | 97 | 'default' => true, |
@@ -104,7 +104,7 @@ discard block |
||
| 104 | 104 | 'id' => 'ASSIGNED_USER_ID', |
| 105 | 105 | 'default' => true), |
| 106 | 106 | 'MODIFIED_BY_NAME' => |
| 107 | - array ( |
|
| 107 | + array( |
|
| 108 | 108 | 'width' => '10%', |
| 109 | 109 | 'label' => 'LBL_MODIFIED_USER', |
| 110 | 110 | 'module' => 'Users', |
@@ -112,11 +112,11 @@ discard block |
||
| 112 | 112 | 'default' => false, |
| 113 | 113 | 'sortable' => false, |
| 114 | 114 | 'related_fields' => |
| 115 | - array ( |
|
| 115 | + array( |
|
| 116 | 116 | 0 => 'modified_user_id', |
| 117 | 117 | ), |
| 118 | 118 | ), |
| 119 | - 'DATE_ENTERED' => array ( |
|
| 119 | + 'DATE_ENTERED' => array( |
|
| 120 | 120 | 'width' => '10%', |
| 121 | 121 | 'label' => 'LBL_DATE_ENTERED', |
| 122 | 122 | 'default' => true, |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -37,20 +37,20 @@ |
||
| 37 | 37 | * display the words "Powered by SugarCRM" and "Supercharged by SuiteCRM". |
| 38 | 38 | ********************************************************************************/ |
| 39 | 39 | |
| 40 | -require_once 'modules/ModuleBuilder/Module/StudioModule.php' ; |
|
| 40 | +require_once 'modules/ModuleBuilder/Module/StudioModule.php'; |
|
| 41 | 41 | |
| 42 | 42 | class EmployeesStudioModule extends StudioModule { |
| 43 | - function getProvidedSubpanels () |
|
| 43 | + function getProvidedSubpanels() |
|
| 44 | 44 | { |
| 45 | 45 | // Much like pointy haired bosses, other modules should not be able to relate to Employees. |
| 46 | 46 | return false; |
| 47 | 47 | } |
| 48 | 48 | |
| 49 | - function getModule () |
|
| 49 | + function getModule() |
|
| 50 | 50 | { |
| 51 | 51 | $normalModules = parent::getModule(); |
| 52 | 52 | |
| 53 | - if(isset($normalModules[translate('LBL_RELATIONSHIPS')])) { |
|
| 53 | + if (isset($normalModules[translate('LBL_RELATIONSHIPS')])) { |
|
| 54 | 54 | unset($normalModules[translate('LBL_RELATIONSHIPS')]); |
| 55 | 55 | } |
| 56 | 56 | |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 3 | 3 | /********************************************************************************* |
| 4 | 4 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 5 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -45,7 +45,7 @@ discard block |
||
| 45 | 45 | /** |
| 46 | 46 | * This builds an EmployeesSearchForm from a classic search form. |
| 47 | 47 | */ |
| 48 | - function __construct( SearchForm $oldSearchForm ) { |
|
| 48 | + function __construct(SearchForm $oldSearchForm) { |
|
| 49 | 49 | parent::SearchForm($oldSearchForm->seed, $oldSearchForm->module, $oldSearchForm->action); |
| 50 | 50 | $this->setup( |
| 51 | 51 | // $searchdefs |
@@ -66,14 +66,14 @@ discard block |
||
| 66 | 66 | public function generateSearchWhere($add_custom_fields = false, $module = '') { |
| 67 | 67 | $onlyActive = false; |
| 68 | 68 | if (isset($this->searchFields['open_only_active_users']['value'])) { |
| 69 | - if ( $this->searchFields['open_only_active_users']['value'] == 1) { |
|
| 69 | + if ($this->searchFields['open_only_active_users']['value'] == 1) { |
|
| 70 | 70 | $onlyActive = true; |
| 71 | 71 | } |
| 72 | 72 | unset($this->searchFields['open_only_active_users']['value']); |
| 73 | 73 | } |
| 74 | 74 | $where_clauses = parent::generateSearchWhere($add_custom_fields, $module); |
| 75 | 75 | |
| 76 | - if ( $onlyActive ) { |
|
| 76 | + if ($onlyActive) { |
|
| 77 | 77 | $where_clauses[] = "users.employee_status = 'Active'"; |
| 78 | 78 | } |
| 79 | 79 | |
@@ -1,5 +1,7 @@ |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -79,46 +79,46 @@ |
||
| 79 | 79 | //$opp_query1 .= " and deleted=0"; |
| 80 | 80 | $opp_result1=$campaign->db->query($opp_query1); |
| 81 | 81 | $opp_data1=$campaign->db->fetchByAssoc($opp_result1); |
| 82 | - //get the click-throughs |
|
| 83 | - $query_click = "SELECT count(*) hits "; |
|
| 84 | - $query_click.= " FROM campaign_log "; |
|
| 85 | - $query_click.= " WHERE campaign_id = '$campaign_id' AND activity_type='link' AND related_type='CampaignTrackers' AND archived=0 AND deleted=0"; |
|
| 82 | + //get the click-throughs |
|
| 83 | + $query_click = "SELECT count(*) hits "; |
|
| 84 | + $query_click.= " FROM campaign_log "; |
|
| 85 | + $query_click.= " WHERE campaign_id = '$campaign_id' AND activity_type='link' AND related_type='CampaignTrackers' AND archived=0 AND deleted=0"; |
|
| 86 | 86 | |
| 87 | 87 | //if $marketing id is specified, then lets filter the chart by the value |
| 88 | 88 | if (!empty($marketing_id)){ |
| 89 | 89 | $query_click.= " AND marketing_id ='$marketing_id'"; |
| 90 | 90 | } |
| 91 | 91 | |
| 92 | - $query_click.= " GROUP BY activity_type, target_type"; |
|
| 93 | - $query_click.= " ORDER BY activity_type, target_type"; |
|
| 94 | - $result = $campaign->db->query($query_click); |
|
| 92 | + $query_click.= " GROUP BY activity_type, target_type"; |
|
| 93 | + $query_click.= " ORDER BY activity_type, target_type"; |
|
| 94 | + $result = $campaign->db->query($query_click); |
|
| 95 | 95 | |
| 96 | 96 | |
| 97 | - $xtpl->assign("OPP_COUNT", $opp_data1['opp_count']); |
|
| 98 | - $xtpl->assign("ACTUAL_COST",$opp_data1['actual_cost']); |
|
| 99 | - $xtpl->assign("PLANNED_BUDGET",$opp_data1['budget']); |
|
| 100 | - $xtpl->assign("EXPECTED_REVENUE",$opp_data1['expected_revenue']); |
|
| 97 | + $xtpl->assign("OPP_COUNT", $opp_data1['opp_count']); |
|
| 98 | + $xtpl->assign("ACTUAL_COST",$opp_data1['actual_cost']); |
|
| 99 | + $xtpl->assign("PLANNED_BUDGET",$opp_data1['budget']); |
|
| 100 | + $xtpl->assign("EXPECTED_REVENUE",$opp_data1['expected_revenue']); |
|
| 101 | 101 | |
| 102 | 102 | |
| 103 | 103 | |
| 104 | 104 | |
| 105 | - $currency = new Currency(); |
|
| 105 | + $currency = new Currency(); |
|
| 106 | 106 | if(isset($focus->currency_id) && !empty($focus->currency_id)) |
| 107 | 107 | { |
| 108 | - $currency->retrieve($focus->currency_id); |
|
| 109 | - if( $currency->deleted != 1){ |
|
| 110 | - $xtpl->assign("CURRENCY", $currency->iso4217 .' '.$currency->symbol ); |
|
| 111 | - }else $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 108 | + $currency->retrieve($focus->currency_id); |
|
| 109 | + if( $currency->deleted != 1){ |
|
| 110 | + $xtpl->assign("CURRENCY", $currency->iso4217 .' '.$currency->symbol ); |
|
| 111 | + }else $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 112 | 112 | }else{ |
| 113 | 113 | |
| 114 | - $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 114 | + $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 115 | 115 | |
| 116 | 116 | } |
| 117 | 117 | |
| 118 | 118 | global $current_user; |
| 119 | 119 | if(is_admin($current_user) && $_REQUEST['module'] != 'DynamicLayout' && !empty($_SESSION['editinplace'])){ |
| 120 | 120 | |
| 121 | - $xtpl->assign("ADMIN_EDIT","<a href='index.php?action=index&module=DynamicLayout&from_action=".$_REQUEST['action'] ."&from_module=".$_REQUEST['module'] ."&record=".$_REQUEST['record']. "'>".SugarThemeRegistry::current()->getImage("EditLayout","border='0' align='bottom'",null,null,'.gif',$mod_strings['LBL_EDIT_LAYOUT'])."</a>"); |
|
| 121 | + $xtpl->assign("ADMIN_EDIT","<a href='index.php?action=index&module=DynamicLayout&from_action=".$_REQUEST['action'] ."&from_module=".$_REQUEST['module'] ."&record=".$_REQUEST['record']. "'>".SugarThemeRegistry::current()->getImage("EditLayout","border='0' align='bottom'",null,null,'.gif',$mod_strings['LBL_EDIT_LAYOUT'])."</a>"); |
|
| 122 | 122 | |
| 123 | 123 | } |
| 124 | 124 | |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 3 | 3 | /********************************************************************************* |
| 4 | 4 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 5 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -65,60 +65,60 @@ discard block |
||
| 65 | 65 | |
| 66 | 66 | $GLOBALS['log']->info("Campaign detail view"); |
| 67 | 67 | |
| 68 | -$xtpl=new XTemplate ('modules/Campaigns/PopupCampaignRoi.html'); |
|
| 68 | +$xtpl = new XTemplate('modules/Campaigns/PopupCampaignRoi.html'); |
|
| 69 | 69 | |
| 70 | 70 | //_pp($_REQUEST['id']); |
| 71 | -$campaign_id=$_REQUEST['id']; |
|
| 71 | +$campaign_id = $_REQUEST['id']; |
|
| 72 | 72 | $campaign = new Campaign(); |
| 73 | -$opp_query1 = "select camp.name, camp.actual_cost,camp.budget,camp.expected_revenue,count(*) opp_count,SUM(opp.amount) as Revenue, SUM(camp.actual_cost) as Investment, |
|
| 73 | +$opp_query1 = "select camp.name, camp.actual_cost,camp.budget,camp.expected_revenue,count(*) opp_count,SUM(opp.amount) as Revenue, SUM(camp.actual_cost) as Investment, |
|
| 74 | 74 | ROUND((SUM(opp.amount) - SUM(camp.actual_cost))/(SUM(camp.actual_cost)), 2)*100 as ROI"; |
| 75 | 75 | $opp_query1 .= " from opportunities opp"; |
| 76 | 76 | $opp_query1 .= " right join campaigns camp on camp.id = opp.campaign_id"; |
| 77 | 77 | $opp_query1 .= " where opp.sales_stage = 'Closed Won' and camp.id='$campaign_id'"; |
| 78 | 78 | $opp_query1 .= " group by camp.name"; |
| 79 | 79 | //$opp_query1 .= " and deleted=0"; |
| 80 | - $opp_result1=$campaign->db->query($opp_query1); |
|
| 81 | - $opp_data1=$campaign->db->fetchByAssoc($opp_result1); |
|
| 80 | + $opp_result1 = $campaign->db->query($opp_query1); |
|
| 81 | + $opp_data1 = $campaign->db->fetchByAssoc($opp_result1); |
|
| 82 | 82 | //get the click-throughs |
| 83 | 83 | $query_click = "SELECT count(*) hits "; |
| 84 | - $query_click.= " FROM campaign_log "; |
|
| 85 | - $query_click.= " WHERE campaign_id = '$campaign_id' AND activity_type='link' AND related_type='CampaignTrackers' AND archived=0 AND deleted=0"; |
|
| 84 | + $query_click .= " FROM campaign_log "; |
|
| 85 | + $query_click .= " WHERE campaign_id = '$campaign_id' AND activity_type='link' AND related_type='CampaignTrackers' AND archived=0 AND deleted=0"; |
|
| 86 | 86 | |
| 87 | 87 | //if $marketing id is specified, then lets filter the chart by the value |
| 88 | - if (!empty($marketing_id)){ |
|
| 89 | - $query_click.= " AND marketing_id ='$marketing_id'"; |
|
| 88 | + if (!empty($marketing_id)) { |
|
| 89 | + $query_click .= " AND marketing_id ='$marketing_id'"; |
|
| 90 | 90 | } |
| 91 | 91 | |
| 92 | - $query_click.= " GROUP BY activity_type, target_type"; |
|
| 93 | - $query_click.= " ORDER BY activity_type, target_type"; |
|
| 92 | + $query_click .= " GROUP BY activity_type, target_type"; |
|
| 93 | + $query_click .= " ORDER BY activity_type, target_type"; |
|
| 94 | 94 | $result = $campaign->db->query($query_click); |
| 95 | 95 | |
| 96 | 96 | |
| 97 | 97 | $xtpl->assign("OPP_COUNT", $opp_data1['opp_count']); |
| 98 | - $xtpl->assign("ACTUAL_COST",$opp_data1['actual_cost']); |
|
| 99 | - $xtpl->assign("PLANNED_BUDGET",$opp_data1['budget']); |
|
| 100 | - $xtpl->assign("EXPECTED_REVENUE",$opp_data1['expected_revenue']); |
|
| 98 | + $xtpl->assign("ACTUAL_COST", $opp_data1['actual_cost']); |
|
| 99 | + $xtpl->assign("PLANNED_BUDGET", $opp_data1['budget']); |
|
| 100 | + $xtpl->assign("EXPECTED_REVENUE", $opp_data1['expected_revenue']); |
|
| 101 | 101 | |
| 102 | 102 | |
| 103 | 103 | |
| 104 | 104 | |
| 105 | - $currency = new Currency(); |
|
| 106 | -if(isset($focus->currency_id) && !empty($focus->currency_id)) |
|
| 105 | + $currency = new Currency(); |
|
| 106 | +if (isset($focus->currency_id) && !empty($focus->currency_id)) |
|
| 107 | 107 | { |
| 108 | 108 | $currency->retrieve($focus->currency_id); |
| 109 | - if( $currency->deleted != 1){ |
|
| 110 | - $xtpl->assign("CURRENCY", $currency->iso4217 .' '.$currency->symbol ); |
|
| 111 | - }else $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 112 | -}else{ |
|
| 109 | + if ($currency->deleted != 1) { |
|
| 110 | + $xtpl->assign("CURRENCY", $currency->iso4217.' '.$currency->symbol); |
|
| 111 | + } else $xtpl->assign("CURRENCY", $currency->getDefaultISO4217().' '.$currency->getDefaultCurrencySymbol()); |
|
| 112 | +} else { |
|
| 113 | 113 | |
| 114 | - $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 114 | + $xtpl->assign("CURRENCY", $currency->getDefaultISO4217().' '.$currency->getDefaultCurrencySymbol()); |
|
| 115 | 115 | |
| 116 | 116 | } |
| 117 | 117 | |
| 118 | 118 | global $current_user; |
| 119 | -if(is_admin($current_user) && $_REQUEST['module'] != 'DynamicLayout' && !empty($_SESSION['editinplace'])){ |
|
| 119 | +if (is_admin($current_user) && $_REQUEST['module'] != 'DynamicLayout' && !empty($_SESSION['editinplace'])) { |
|
| 120 | 120 | |
| 121 | - $xtpl->assign("ADMIN_EDIT","<a href='index.php?action=index&module=DynamicLayout&from_action=".$_REQUEST['action'] ."&from_module=".$_REQUEST['module'] ."&record=".$_REQUEST['record']. "'>".SugarThemeRegistry::current()->getImage("EditLayout","border='0' align='bottom'",null,null,'.gif',$mod_strings['LBL_EDIT_LAYOUT'])."</a>"); |
|
| 121 | + $xtpl->assign("ADMIN_EDIT", "<a href='index.php?action=index&module=DynamicLayout&from_action=".$_REQUEST['action']."&from_module=".$_REQUEST['module']."&record=".$_REQUEST['record']."'>".SugarThemeRegistry::current()->getImage("EditLayout", "border='0' align='bottom'", null, null, '.gif', $mod_strings['LBL_EDIT_LAYOUT'])."</a>"); |
|
| 122 | 122 | |
| 123 | 123 | } |
| 124 | 124 | |
@@ -171,23 +171,23 @@ discard block |
||
| 171 | 171 | */ |
| 172 | 172 | |
| 173 | 173 | //add chart |
| 174 | -$seps = array("-", "/"); |
|
| 175 | -$dates = array(date($GLOBALS['timedate']->dbDayFormat), $GLOBALS['timedate']->dbDayFormat); |
|
| 176 | -$dateFileNameSafe = str_replace($seps, "_", $dates); |
|
| 177 | -$cache_file_name_roi = $current_user->getUserPrivGuid()."_campaign_response_by_roi_".$dateFileNameSafe[0]."_".$dateFileNameSafe[1].".xml"; |
|
| 178 | -$chart= new campaign_charts(); |
|
| 174 | +$seps = array("-", "/"); |
|
| 175 | +$dates = array(date($GLOBALS['timedate']->dbDayFormat), $GLOBALS['timedate']->dbDayFormat); |
|
| 176 | +$dateFileNameSafe = str_replace($seps, "_", $dates); |
|
| 177 | +$cache_file_name_roi = $current_user->getUserPrivGuid()."_campaign_response_by_roi_".$dateFileNameSafe[0]."_".$dateFileNameSafe[1].".xml"; |
|
| 178 | +$chart = new campaign_charts(); |
|
| 179 | 179 | |
| 180 | 180 | //ob_start(); |
| 181 | 181 | |
| 182 | 182 | //if marketing id has been selected, then set "latest_marketing_id" to the selected value |
| 183 | 183 | //latest marketing id will be passed in to filter the charts and subpanels |
| 184 | 184 | |
| 185 | - if(!empty($selected_marketing_id)){$latest_marketing_id = $selected_marketing_id;} |
|
| 186 | - if(empty($latest_marketing_id) || $latest_marketing_id === 'all'){ |
|
| 187 | - $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'],$app_list_strings['roi_type_dom'],$campaign_id,sugar_cached("xml/") . $cache_file_name_roi,true)); |
|
| 188 | - }else{ |
|
| 185 | + if (!empty($selected_marketing_id)) {$latest_marketing_id = $selected_marketing_id; } |
|
| 186 | + if (empty($latest_marketing_id) || $latest_marketing_id === 'all') { |
|
| 187 | + $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'], $app_list_strings['roi_type_dom'], $campaign_id, sugar_cached("xml/").$cache_file_name_roi, true)); |
|
| 188 | + } else { |
|
| 189 | 189 | |
| 190 | - $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'],$app_list_strings['roi_type_dom'],$campaign_id,sugar_cached("xml/") .$cache_file_name_roi,true)); |
|
| 190 | + $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'], $app_list_strings['roi_type_dom'], $campaign_id, sugar_cached("xml/").$cache_file_name_roi, true)); |
|
| 191 | 191 | } |
| 192 | 192 | |
| 193 | 193 | //$output_html .= ob_get_contents(); |
@@ -1,5 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -108,8 +110,10 @@ discard block |
||
| 108 | 110 | $currency->retrieve($focus->currency_id); |
| 109 | 111 | if( $currency->deleted != 1){ |
| 110 | 112 | $xtpl->assign("CURRENCY", $currency->iso4217 .' '.$currency->symbol ); |
| 111 | - }else $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 112 | -}else{ |
|
| 113 | + } else { |
|
| 114 | + $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
|
| 115 | + } |
|
| 116 | + } else{ |
|
| 113 | 117 | |
| 114 | 118 | $xtpl->assign("CURRENCY", $currency->getDefaultISO4217() .' '.$currency->getDefaultCurrencySymbol() ); |
| 115 | 119 | |
@@ -185,7 +189,7 @@ discard block |
||
| 185 | 189 | if(!empty($selected_marketing_id)){$latest_marketing_id = $selected_marketing_id;} |
| 186 | 190 | if(empty($latest_marketing_id) || $latest_marketing_id === 'all'){ |
| 187 | 191 | $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'],$app_list_strings['roi_type_dom'],$campaign_id,sugar_cached("xml/") . $cache_file_name_roi,true)); |
| 188 | - }else{ |
|
| 192 | + } else{ |
|
| 189 | 193 | |
| 190 | 194 | $xtpl->assign("MY_CHART_ROI", $chart->campaign_response_roi_popup($app_list_strings['roi_type_dom'],$app_list_strings['roi_type_dom'],$campaign_id,sugar_cached("xml/") .$cache_file_name_roi,true)); |
| 191 | 195 | } |
@@ -85,7 +85,7 @@ discard block |
||
| 85 | 85 | //perform this if the option to create new mail box has been checked |
| 86 | 86 | if(isset($_REQUEST['wiz_new_mbox']) && ($_REQUEST['wiz_new_mbox']=='1')){ |
| 87 | 87 | |
| 88 | - //Populate the Request variables that inboundemail expects |
|
| 88 | + //Populate the Request variables that inboundemail expects |
|
| 89 | 89 | $_REQUEST['mark_read'] = 1; |
| 90 | 90 | $_REQUEST['only_since'] = 1; |
| 91 | 91 | $_REQUEST['mailbox_type'] = 'bounce'; |
@@ -114,18 +114,18 @@ discard block |
||
| 114 | 114 | function clean_up_post($prefix){ |
| 115 | 115 | |
| 116 | 116 | foreach ($_REQUEST as $key => $val) { |
| 117 | - if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 118 | - $newkey =substr($key, strlen($prefix)) ; |
|
| 119 | - $_REQUEST[$newkey] = $val; |
|
| 120 | - } |
|
| 117 | + if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 118 | + $newkey =substr($key, strlen($prefix)) ; |
|
| 119 | + $_REQUEST[$newkey] = $val; |
|
| 120 | + } |
|
| 121 | 121 | } |
| 122 | 122 | |
| 123 | 123 | foreach ($_POST as $key => $val) { |
| 124 | - if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 125 | - $newkey =substr($key, strlen($prefix)) ; |
|
| 126 | - $_POST[$newkey] = $val; |
|
| 124 | + if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 125 | + $newkey =substr($key, strlen($prefix)) ; |
|
| 126 | + $_POST[$newkey] = $val; |
|
| 127 | 127 | |
| 128 | - } |
|
| 128 | + } |
|
| 129 | 129 | } |
| 130 | 130 | } |
| 131 | 131 | |
@@ -1,5 +1,5 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if (!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 3 | 3 | /********************************************************************************* |
| 4 | 4 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 5 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -60,22 +60,22 @@ discard block |
||
| 60 | 60 | //name is used as key in post, it is also used in creation of summary page for wizard, |
| 61 | 61 | //so let's clean up the posting so we can reuse the save functionality for inbound emails and |
| 62 | 62 | //from existing save.php's |
| 63 | - foreach($camp_steps as $step){ |
|
| 63 | + foreach ($camp_steps as $step) { |
|
| 64 | 64 | clean_up_post($step); |
| 65 | 65 | } |
| 66 | 66 | /**************************** Save general Email Setup *****************************/ |
| 67 | 67 | |
| 68 | 68 | //we do not need to track location if location type is not set |
| 69 | -if(isset($_POST['tracking_entities_location_type'])) { |
|
| 69 | +if (isset($_POST['tracking_entities_location_type'])) { |
|
| 70 | 70 | if ($_POST['tracking_entities_location_type'] != '2') { |
| 71 | 71 | unset($_POST['tracking_entities_location']); |
| 72 | 72 | unset($_POST['tracking_entities_location_type']); |
| 73 | 73 | } |
| 74 | 74 | } |
| 75 | 75 | //if the check box is empty, then set it to 0 |
| 76 | -if(!isset($_POST['mail_smtpauth_req'])) { $_POST['mail_smtpauth_req'] = 0; } |
|
| 76 | +if (!isset($_POST['mail_smtpauth_req'])) { $_POST['mail_smtpauth_req'] = 0; } |
|
| 77 | 77 | //default ssl use to false |
| 78 | -if(!isset($_POST['mail_smtpssl'])) { $_POST['mail_smtpssl'] = 0; } |
|
| 78 | +if (!isset($_POST['mail_smtpssl'])) { $_POST['mail_smtpssl'] = 0; } |
|
| 79 | 79 | //reuse existing saveconfig functionality |
| 80 | 80 | $focus->saveConfig(); |
| 81 | 81 | |
@@ -83,7 +83,7 @@ discard block |
||
| 83 | 83 | |
| 84 | 84 | /**************************** Add New Monitored Box *****************************/ |
| 85 | 85 | //perform this if the option to create new mail box has been checked |
| 86 | -if(isset($_REQUEST['wiz_new_mbox']) && ($_REQUEST['wiz_new_mbox']=='1')){ |
|
| 86 | +if (isset($_REQUEST['wiz_new_mbox']) && ($_REQUEST['wiz_new_mbox'] == '1')) { |
|
| 87 | 87 | |
| 88 | 88 | //Populate the Request variables that inboundemail expects |
| 89 | 89 | $_REQUEST['mark_read'] = 1; |
@@ -96,11 +96,11 @@ discard block |
||
| 96 | 96 | require_once('modules/InboundEmail/Save.php'); |
| 97 | 97 | |
| 98 | 98 | } |
| 99 | - if (!empty($_REQUEST['error'])){ |
|
| 99 | + if (!empty($_REQUEST['error'])) { |
|
| 100 | 100 | //an error was found during inbound save. This means the save was allowed but the inbound box had problems, return user to wizard |
| 101 | 101 | //and display error message |
| 102 | 102 | header("Location: index.php?action=WizardEmailSetup&module=Campaigns&error=true"); |
| 103 | - }else{ |
|
| 103 | + } else { |
|
| 104 | 104 | //set navigation details |
| 105 | 105 | header("Location: index.php?action=index&module=Campaigns"); |
| 106 | 106 | } |
@@ -111,18 +111,18 @@ discard block |
||
| 111 | 111 | * which does not expect the prefix, and still use the generic create summary functionality in wizard, which |
| 112 | 112 | * does expect the prefix. |
| 113 | 113 | */ |
| 114 | -function clean_up_post($prefix){ |
|
| 114 | +function clean_up_post($prefix) { |
|
| 115 | 115 | |
| 116 | 116 | foreach ($_REQUEST as $key => $val) { |
| 117 | - if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 118 | - $newkey =substr($key, strlen($prefix)) ; |
|
| 117 | + if ((strstr($key, $prefix)) && (strpos($key, $prefix) == 0)) { |
|
| 118 | + $newkey = substr($key, strlen($prefix)); |
|
| 119 | 119 | $_REQUEST[$newkey] = $val; |
| 120 | 120 | } |
| 121 | 121 | } |
| 122 | 122 | |
| 123 | 123 | foreach ($_POST as $key => $val) { |
| 124 | - if((strstr($key, $prefix )) && (strpos($key, $prefix )== 0)){ |
|
| 125 | - $newkey =substr($key, strlen($prefix)) ; |
|
| 124 | + if ((strstr($key, $prefix)) && (strpos($key, $prefix) == 0)) { |
|
| 125 | + $newkey = substr($key, strlen($prefix)); |
|
| 126 | 126 | $_POST[$newkey] = $val; |
| 127 | 127 | |
| 128 | 128 | } |
@@ -1,5 +1,7 @@ discard block |
||
| 1 | 1 | <?php |
| 2 | -if(!defined('sugarEntry') || !sugarEntry) die('Not A Valid Entry Point'); |
|
| 2 | +if(!defined('sugarEntry') || !sugarEntry) { |
|
| 3 | + die('Not A Valid Entry Point'); |
|
| 4 | +} |
|
| 3 | 5 | /********************************************************************************* |
| 4 | 6 | * SugarCRM Community Edition is a customer relationship management program developed by |
| 5 | 7 | * SugarCRM, Inc. Copyright (C) 2004-2013 SugarCRM Inc. |
@@ -100,7 +102,7 @@ discard block |
||
| 100 | 102 | //an error was found during inbound save. This means the save was allowed but the inbound box had problems, return user to wizard |
| 101 | 103 | //and display error message |
| 102 | 104 | header("Location: index.php?action=WizardEmailSetup&module=Campaigns&error=true"); |
| 103 | - }else{ |
|
| 105 | + } else{ |
|
| 104 | 106 | //set navigation details |
| 105 | 107 | header("Location: index.php?action=index&module=Campaigns"); |
| 106 | 108 | } |