Update db migration and remove unused files
This commit is contained in:
@@ -1,3 +0,0 @@
|
||||
.gravityflow_workflow_detail #postbox-container-1 > div:last-child:not(.detail-view-print) {
|
||||
display: none;
|
||||
}
|
||||
@@ -16,7 +16,6 @@ class Wiaas_Admin_Delivery_Process {
|
||||
$plugin_url = untrailingslashit( plugins_url( '/', WIAAS_FILE ) );
|
||||
|
||||
wp_enqueue_script( 'wiaas_admin_delivery_process', $plugin_url . '/assets/js/wiaas-admin-delivery-process.js' );
|
||||
wp_enqueue_style( 'wiaas_admin_delivery_process', $plugin_url . '/assets/css/wiaas-admin-delivery-process.css' );
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
@@ -24,7 +24,8 @@ class Wiaas_DB_Update {
|
||||
'20191020014650' => 'wiaas_create_organization_roles_capabilities',
|
||||
'20191030162450' => 'wiaas_db_update_update_supplier_order_capabilities',
|
||||
'20191102112451' => 'wiaas_disable_processing_order_email_delivery',
|
||||
'20191031172850' => 'update_delivery_forms'
|
||||
'20191131172850' => 'wiaas_db_update_update_delivery_forms',
|
||||
'20191131182856' => 'wiaas_db_update_enable_workflow_inbox_for_roles'
|
||||
);
|
||||
|
||||
public static function execute() {
|
||||
|
||||
@@ -88,7 +88,7 @@ function wiaas_disable_processing_order_email_delivery() {
|
||||
}
|
||||
|
||||
|
||||
function update_delivery_forms() {
|
||||
function wiaas_db_update_update_delivery_forms() {
|
||||
|
||||
$forms = GFAPI::get_forms();
|
||||
foreach ($forms as $form) {
|
||||
|
||||
@@ -315,4 +315,12 @@ function wiaas_admin_create_role_access_groups() {
|
||||
function wiaas_db_update_update_supplier_order_capabilities() {
|
||||
// add supplier role to view orders
|
||||
wp_roles()->add_cap( 'supplier', 'edit_shop_orders' );
|
||||
}
|
||||
|
||||
function wiaas_db_update_enable_workflow_inbox_for_roles() {
|
||||
// add workflow inbox for supplier
|
||||
wp_roles()->add_cap( 'supplier', 'gravityflow_inbox' );
|
||||
// add workflow inbox for commercial lead
|
||||
wp_roles()->add_cap( 'commercial_lead', 'gravityflow_inbox' );
|
||||
|
||||
}
|
||||
Reference in New Issue
Block a user