Exemple #1
0
	public function uninstall() {
		Utils_RecordBrowserCommon::delete_addon('company', 'Tests/Bugtrack', 'company_bugtrack_addon');
		Utils_AttachmentCommon::delete_addon('bugtrack');
		Utils_RecordBrowserCommon::uninstall_recordset('bugtrack');
		Utils_CommonDataCommon::remove('Bugtrack_Status');
		return true;
	}
 public function uninstall()
 {
     $ret = true;
     Utils_RecordBrowserCommon::uninstall_recordset('quick_search');
     Utils_RecordBrowserCommon::unregister_processing_callback('quick_search', array('Applets_QuickSearchCommon', 'parse_values'));
     return $ret;
 }
Exemple #3
0
 public function uninstall()
 {
     CRM_CalendarCommon::delete_event_handler('Tasks');
     CRM_RoundcubeCommon::delete_addon('task');
     Utils_AttachmentCommon::delete_addon('task');
     Base_ThemeCommon::uninstall_default_theme(CRM_TasksInstall::module_name());
     Utils_RecordBrowserCommon::unregister_processing_callback('task', array('CRM_TasksCommon', 'submit_task'));
     Utils_RecordBrowserCommon::uninstall_recordset('task');
     return true;
 }
Exemple #4
0
 public function uninstall()
 {
     CRM_CalendarCommon::delete_event_handler('Phonecalls');
     CRM_RoundcubeCommon::delete_addon('phonecall');
     Base_ThemeCommon::uninstall_default_theme(CRM_PhoneCallInstall::module_name());
     Utils_AttachmentCommon::delete_addon('phonecall');
     Utils_AttachmentCommon::persistent_mass_delete('phonecall/');
     Utils_RecordBrowserCommon::unregister_processing_callback('phonecall', array('CRM_PhoneCallCommon', 'submit_phonecall'));
     Utils_RecordBrowserCommon::uninstall_recordset('phonecall');
     return true;
 }
Exemple #5
0
 public function uninstall()
 {
     Utils_AttachmentCommon::delete_addon('crm_meeting');
     Utils_RecordBrowserCommon::delete_addon('crm_meeting', CRM_MeetingInstall::module_name(), 'messanger_addon');
     CRM_RoundcubeCommon::delete_addon('crm_meeting');
     CRM_CalendarCommon::delete_event_handler('Meetings');
     Base_ThemeCommon::uninstall_default_theme(CRM_MeetingInstall::module_name());
     Utils_RecordBrowserCommon::uninstall_recordset('crm_meeting');
     Utils_RecordBrowserCommon::unregister_processing_callback('crm_meeting', array('CRM_MeetingCommon', 'submit_meeting'));
     return true;
 }
Exemple #6
0
 public function uninstall()
 {
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     Utils_CommonDataCommon::remove('crm_assets_category');
     Utils_CommonDataCommon::remove('crm_assets_monitor_type');
     Utils_CommonDataCommon::remove('crm_assets_printer_type');
     Utils_RecordBrowserCommon::delete_addon('company', 'CRM/Assets', 'assets_addon');
     Utils_AttachmentCommon::delete_addon('crm_assets');
     Utils_AttachmentCommon::persistent_mass_delete('crm_assets');
     Utils_RecordBrowserCommon::uninstall_recordset('crm_assets');
     Utils_RecordBrowserCommon::unregister_processing_callback('crm_assets', array('CRM_AssetsCommon', 'process_request'));
     return true;
 }
Exemple #7
0
	public function uninstall() {
		Base_AclCommon::delete_permission('Attachments - view full download history');
		$ret = true;
		Variable::delete('utils_attachments_google_user');
		Variable::delete('utils_attachments_google_pass');

		DB::DropTable('utils_attachment_googledocs');
		$ret &= DB::DropTable('utils_attachment_download');
		$ret &= DB::DropTable('utils_attachment_file');
		$ret &= DB::DropTable('utils_attachment_local');
        Utils_RecordBrowserCommon::uninstall_recordset('utils_attachment');
		Base_ThemeCommon::uninstall_default_theme($this->get_type());
		return $ret;
	}
Exemple #8
0
 public function uninstall()
 {
     Base_AclCommon::remove_clearance_callback(array('CRM_ContactsCommon', 'crm_clearance'));
     Base_ThemeCommon::uninstall_default_theme(CRM_ContactsInstall::module_name());
     Utils_RecordBrowserCommon::unregister_datatype('crm_company');
     Utils_RecordBrowserCommon::unregister_datatype('crm_contact');
     Utils_RecordBrowserCommon::unregister_datatype('crm_company_contact');
     Utils_RecordBrowserCommon::unregister_datatype('email');
     Utils_RecordBrowserCommon::delete_addon('company', CRM_ContactsInstall::module_name(), 'company_addon');
     Utils_AttachmentCommon::delete_addon('company');
     Utils_AttachmentCommon::delete_addon('contact');
     Utils_RecordBrowserCommon::uninstall_recordset('company');
     Utils_RecordBrowserCommon::uninstall_recordset('contact');
     Utils_CommonDataCommon::remove('Contacts_Groups');
     Utils_CommonDataCommon::remove('Companies_Groups');
     Utils_RecordBrowserCommon::unregister_processing_callback('contact', array('CRM_ContactsCommon', 'submit_contact'));
     return true;
 }
Exemple #9
0
 /**
  * Uninstall recordset.
  * @return bool success
  */
 public function uninstall()
 {
     return Utils_RecordBrowserCommon::uninstall_recordset($this->tab);
 }
Exemple #10
0
 public function uninstall()
 {
     Utils_RecordBrowserCommon::uninstall_recordset('data_tax_rates');
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     return true;
 }
Exemple #11
0
         print 'done<br>';
     }
 }
 Utils_RecordBrowserCommon::wipe_access('contact');
 Utils_RecordBrowserCommon::add_access('contact', 'view', 'ACCESS:employee', array('(!permission' => 2, '|:Created_by' => 'USER_ID'), array('birth_date', 'ssn', 'home_phone', 'home_address_1', 'home_address_2', 'home_city', 'home_country', 'home_zone', 'home_postal_code', 'view', 'edit', 'add', 'delete'));
 Utils_RecordBrowserCommon::add_access('contact', 'view', 'ALL', array('login' => 'USER_ID'), array('view', 'edit', 'add', 'delete'));
 Utils_RecordBrowserCommon::add_access('contact', 'view', array('ACCESS:employee', 'ACCESS:mrm'), array('(!permission' => 2, '|:Created_by' => 'USER_ID'), array('view', 'edit', 'add', 'delete'));
 Utils_RecordBrowserCommon::add_access('contact', 'add', array('ACCESS:employee', 'ACCESS:manager'));
 Utils_RecordBrowserCommon::add_access('contact', 'edit', 'ACCESS:employee', array('(permission' => 0, '|:Created_by' => 'USER_ID', '!group' => array('patient', 'ex_patient')), array('access', 'login'));
 Utils_RecordBrowserCommon::add_access('contact', 'edit', 'ALL', array('login' => 'USER_ID'), array('access', 'login'));
 Utils_RecordBrowserCommon::add_access('contact', 'edit', array('ACCESS:employee', 'ACCESS:mrm'), array());
 Utils_RecordBrowserCommon::add_access('contact', 'delete', array('ACCESS:employee', 'ACCESS:mrm'));
 Utils_RecordBrowserCommon::add_access('contact', 'view', 'ALL', array('view' => 'USER'), array('view', 'edit', 'add', 'delete'));
 Utils_RecordBrowserCommon::add_access('contact', 'edit', 'ALL', array('edit' => 'USER'));
 Utils_RecordBrowserCommon::add_access('contact', 'delete', 'ALL', array('delete' => 'USER'));
 Utils_RecordBrowserCommon::uninstall_recordset('cades_access_control');
 Utils_CommonDataCommon::remove('CADES/AccessLevel');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_appointments');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_allergies');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_behavior');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_behavior_log');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_diagnosis', 'patient');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_diet');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_hospitalizations');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_immunizations');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_insurance');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_issues', 'patient');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_medicaltests');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_medications');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_reviews');
 Custom_CADES_AccessRestrictionsCommon::add_default_cades_permissions('cades_seizures');
Exemple #12
0
 public function uninstall()
 {
     $this->drop_all_rc_tables();
     Utils_RecordBrowserCommon::delete_addon('rc_mails', 'CRM/Roundcube', 'attachments_addon');
     Utils_RecordBrowserCommon::delete_addon('contact', 'CRM/Roundcube', 'addon');
     Utils_RecordBrowserCommon::delete_addon('company', 'CRM/Roundcube', 'addon');
     DB::DropTable('rc_mails_attachments');
     DB::DropTable('rc_mails_attachments_download');
     Utils_RecordBrowserCommon::uninstall_recordset('rc_mails');
     Utils_RecordBrowserCommon::uninstall_recordset('rc_accounts');
     Utils_RecordBrowserCommon::uninstall_recordset('rc_multiple_emails');
     Utils_CommonDataCommon::remove('CRM/Roundcube/Security');
     Utils_RecordBrowserCommon::unregister_processing_callback('rc_accounts', array('CRM_RoundcubeCommon', 'submit_account'));
     Utils_RecordBrowserCommon::unregister_processing_callback('rc_mails', array('CRM_RoundcubeCommon', 'submit_mail'));
     Base_ThemeCommon::uninstall_default_theme($this->get_type());
     Variable::delete('crm_roundcube_global_signature');
     return true;
 }
<?php

defined("_VALID_ACCESS") || die('Direct access forbidden');
@ini_set('memory_limit', '256M');
@ini_set('memory_limit', '512M');
Utils_WatchdogCommon::dont_notify();
$rs_checkpoint = Patch::checkpoint('recordset');
if (!$rs_checkpoint->is_done()) {
    Patch::require_time(5);
    Utils_RecordBrowserCommon::uninstall_recordset('utils_attachment');
    $fields = array(array('name' => _M('Edited on'), 'type' => 'timestamp', 'extra' => false, 'visible' => true, 'required' => false, 'display_callback' => array('Utils_AttachmentCommon', 'display_date'), 'QFfield_callback' => array('Utils_AttachmentCommon', 'QFfield_date')), array('name' => _M('Title'), 'type' => 'text', 'param' => 255, 'required' => false, 'extra' => false, 'visible' => true), array('name' => _M('Note'), 'type' => 'long text', 'required' => false, 'extra' => false, 'visible' => true, 'display_callback' => array('Utils_AttachmentCommon', 'display_note'), 'QFfield_callback' => array('Utils_AttachmentCommon', 'QFfield_note')), array('name' => _M('Permission'), 'type' => 'commondata', 'required' => true, 'param' => array('order_by_key' => true, 'CRM/Access'), 'extra' => false), array('name' => _M('Sticky'), 'type' => 'checkbox', 'visible' => true, 'extra' => false), array('name' => _M('Crypted'), 'type' => 'checkbox', 'extra' => false, 'QFfield_callback' => array('Utils_AttachmentCommon', 'QFfield_crypted')), array('name' => _M('Func'), 'type' => 'text', 'param' => 255, 'required' => true, 'extra' => false, 'visible' => false), array('name' => _M('Args'), 'type' => 'text', 'param' => 255, 'required' => true, 'extra' => false, 'visible' => false));
    Utils_RecordBrowserCommon::install_new_recordset('utils_attachment', $fields);
    Utils_RecordBrowserCommon::add_access('utils_attachment', 'view', 'ACCESS:employee', array('(!permission' => 2, '|employees' => 'USER'), array('func', 'args'));
    Utils_RecordBrowserCommon::add_access('utils_attachment', 'delete', 'ACCESS:employee', array(':Created_by' => 'USER_ID'));
    Utils_RecordBrowserCommon::add_access('utils_attachment', 'delete', array('ACCESS:employee', 'ACCESS:manager'));
    Utils_RecordBrowserCommon::add_access('utils_attachment', 'add', 'ACCESS:employee');
    Utils_RecordBrowserCommon::add_access('utils_attachment', 'edit', 'ACCESS:employee', array('(permission' => 0, '|employees' => 'USER', '|customer' => 'USER'), array('edited_on'));
    Utils_RecordBrowserCommon::register_processing_callback('utils_attachment', array('Utils_AttachmentCommon', 'submit_attachment'));
    Utils_RecordBrowserCommon::set_tpl('utils_attachment', Base_ThemeCommon::get_template_filename(Utils_Attachment::module_name(), 'View_entry'));
    $ret = DB::CreateTable('utils_attachment_local', '
			local C(255) NOTNULL,
			attachment I4 NOTNULL,
			func C(255),
			args C(255)', array('constraints' => ', FOREIGN KEY (attachment) REFERENCES utils_attachment_data_1(ID)'));
    if (!$ret) {
        print 'Unable to create table utils_attachment_link.<br>';
        return false;
    }
    DB::CreateIndex('utils_attachment_local__idx', 'utils_attachment_local', 'local');
    $rs_checkpoint->done();
}
Exemple #14
0
        Utils_RecordBrowserCommon::new_record('rc_related', array('recordset' => $r['recordset']));
        unset($old[$i]);
        $old_checkpoint->set('old', $old);
    }
    $old_checkpoint->done();
}
Patch::set_message('Processing related');
$related_checkpoint = Patch::checkpoint('related');
if (!$related_checkpoint->is_done()) {
    while (1) {
        $related = $related_checkpoint->get('related', array());
        if (empty($related)) {
            $related = Utils_RecordBrowserCommon::get_records('rc_mails_assoc', array(), array(), array(), 10);
            if (empty($related)) {
                break;
            }
        }
        foreach ($related as $i => $r) {
            $related_checkpoint->require_time(5);
            $mail = Utils_RecordBrowserCommon::get_record('rc_mails', $r['mail']);
            $mail['related'][] = $r['recordset'] . '/' . $r['record_id'];
            Utils_RecordBrowserCommon::update_record('rc_mails', $r['mail'], array('related' => $mail['related']));
            Utils_RecordBrowserCommon::delete_record('rc_mails_assoc', $r['id']);
            unset($related[$i]);
            $related_checkpoint->set('related', $related);
        }
    }
    $related_checkpoint->done();
}
Utils_RecordBrowserCommon::uninstall_recordset('rc_mails_assoc');
Utils_RecordBrowserCommon::delete_addon('rc_mails', CRM_Roundcube::module_name(), 'assoc_addon');