Support for Drupal 7 is ending on 5 January 2025—it’s time to migrate to Drupal 10! Learn about the many benefits of Drupal 10 and find migration tools in our resource center.
Image 1: Flow Chart.
Proposed Solution
- URL format: ows-vwuds-[bundle or user]-[function: info/edit/data]
Remaining Tasks
Image 2: Navigation.
Develop and deploy dh_perms - contact based permissions.Migrate dh module.Migrate dh_wsp module.Migrate om module.Create Outline of screensMonthly/Annual data widget from dh_properties class- User Facilities screen or section in Dashboard
- Organization Facilities screen (see Image 3) - indicates reporting status, shows messages (approvals, status change, review needed)
- Facility screen (see Image 4) - link to facility attributes/contacts, list MPs and their reporting status
- MP Screen - sub-screens, MP attributes, and annual/monthly reporting data entry
Intakes - ex: http://deq1.bse.vt.edu/d.alpha/ows-vwuds-intake-monthly/58760
Wells - ex: d.alpha/ows-vwuds-well-monthly/58741
Transfer Release - d.alpha/ows-vwuds-transfer-monthly/283568/2016
Transfer Delivery - d.alpha/ows-vwuds-transfer-monthly/283621/ - Do final migrations of withdrawal monthly data (only annual and daily summary data has been migrated) - see http://deq1.bse.vt.edu/sifnwiki/index.php/Drupal_hydro_vwuds_measuring_p...
- Migrate transfer features (see related issue for data model)
Transfer MPs: /files/vwuds/vwuds_tfr.tsv
Conveyance Features: /var/www/html/files/vwuds/vwuds_transfer_feature-sample.tsv and files/vwuds/vwuds_transfer_features.tsv
Transfer Data (release): files/vwuds/vwuds.tw-release.tsv
Transfer Data (delivery): files/vwuds/vwuds.tw-delivery.tsv - Update MPs with fstatus = 8 and 9 to proper value (be sure that "active" is what it should be)
- create a view to accept transfer hydroid as input and give a from feature or a to feature entity reference erefid as result for use by string to entity id tamper in feeds import http://deq1.bse.vt.edu/d.alpha/admin/structure/feeds/dh_vwuds_transfer
- Review Records where old system had multiple releases to another facility intended for separate service areas underneath the recipient facility -- some cases we may not have created multiple recipient? see table 1: Duplicates.
- Investigate the 3 conveyance features that are in the ‘vwuds_transfer_features.tsv’ twice
vwuds_conv-0282-0288
vwuds_conv-0283-0476
vwuds_conv-0232-2039 - Import new features from updated NHD impoundment layer.
All orgs attached to user (contact or eref), facilities attached to orgs
Image 3: Organization/Owner Status.
Image 4: Facility info page shows status of reporting on associated MPs.
Table 1: Duplicates that maybe should be actual duplicates.
vwuds=# select name, src, dest, hydrocode from vwuds_to_dh_tfr_mps where hydrocode in ('vwuds_tfr-0282-0288-TW-RL', 'vwuds_tfr-0283-0476-TW-DL');
name | src | dest | hydrocode
-----------------------------------------+------+------+---------------------------
TO PR WILLIAM CO-GMSD | 0282 | 0288 | vwuds_tfr-0282-0288-TW-RL
TO PR WILLIAM CO-GMSD | 0282 | 0288 | vwuds_tfr-0282-0288-TW-RL
TO GMSD SERVICE AREA | 0282 | 0288 | vwuds_tfr-0282-0288-TW-RL
TO GMSD SERVICE AREA | 0282 | 0288 | vwuds_tfr-0282-0288-TW-RL
FROM FAIRFAX CO WA - POTOMAC | 0283 | 0476 | vwuds_tfr-0283-0476-TW-DL
FROM FAIRFAX CO WA - SOUTHSIDE - BYPASS | 0283 | 0476 | vwuds_tfr-0283-0476-TW-DL
(6 rows)
Views to Migrate:
Done 12/7 - d.alpha/admin/structure/views/view/vwuds_measuring_point_dashboard/editDone 12/7 - d.alpha/admin/structure/views/view/vwuds_facility_dashboard/editDone 12/7 - d.alpha/admin/structure/views/view/vwuds_breadcrumbs/edit- d.alpha/admin/structure/views/view/vwuds_organization_dashboard/edit
- d.alpha/admin/structure/views/view/vwuds_organization_page/edit
Done 12/7 - d.alpha/admin/structure/views/view/ows_vwuds_mp_status/edit- d.alpha/admin/structure/views/view/vwuds_user_dashboard/edit/default
- d.alpha/admin/structure/views/view/vwuds_hardcopy_template/edit/page
- d.alpha/admin/structure/views/view/vwuds_facility_mail_merge/edit
Panels to Migrate:
Done 12/7 - d.alpha/admin/structure/pages/edit/page-vwuds_facility_dashboard- d.alpha/admin/structure/pages/edit/page-vwuds_intake_dashboard
Done 12/7 - d.alpha/admin/structure/pages/edit/page-vwuds_measuring_point_dashboard- d.alpha/admin/structure/pages/edit/page-vwuds_transfer_dashboard
- d.alpha/admin/structure/pages/edit/page-ows_vwuds_transfer_monthly
- d.alpha/admin/structure/pages/edit/page-vwwr_intake_monthly
Done 12/7 - d.alpha/admin/structure/pages/edit/page-vwwr_well_monthly- d.alpha/admin/structure/pages/edit/page-ows_vwuds_dashboard
- d.alpha/admin/structure/pages/edit/page-vwuds_facility_contacts
Comment | File | Size | Author |
---|---|---|---|
#38 | vahydro-vwuds-org-status.png | 12.19 KB | robertwb |
#34 | vahydro-vwuds-fac-info.png | 16.24 KB | robertwb |
#27 | dh_vwuds_nav-flow.png | 59.82 KB | robertwb |
#2 | v1.0-mp-panel.png | 64.09 KB | robertwb |
#2 | v1.0-facility-panel.png | 43.38 KB | robertwb |
Comments
Comment #2
robertwb CreditAttribution: robertwb commentedComment #3
robertwb CreditAttribution: robertwb commentedComment #4
robertwb CreditAttribution: robertwb commentedCode for forms:
Comment #5
c_thomas CreditAttribution: c_thomas commentedThere is an option to use a Select List widget, as well as checklists, in the Flexiform Drupal UI. However, it is not enabled for all field types. I'm not fully familiar with how the field types are set but it seems like that has to do with if you can select the List widget. For example, check out this flexiform I created on d.beta: http://deq1.bse.vt.edu/d.beta/admin/structure/flexiforms/manage/wsp_sour.... You are able to use the Select List widget with both of the entity reference fields (Link to WSP System and VWUDS Source) but none of the others. It looks like this code below would pretty easily let you add any type of form element into a flexiform though, this being checkbox:
$form[$this->element_namespace] = array(
'#type' => 'checkbox',
'#parents' => $parents,
'#title' => $this->label(),
'#default_value' => !empty($entity->status) ? $entity->status : FALSE,
);
Comment #6
robertwb CreditAttribution: robertwb commentedComment #7
c_thomas CreditAttribution: c_thomas commentedThis is the Drupal page explaining how to add a Flexiform Element: https://www.drupal.org/node/2097817
Comment #8
robertwb CreditAttribution: robertwb commentedA sample grid editor can be seen here: http://deq1.bse.vt.edu/d.alpha/node/59/64697
Comment #9
robertwb CreditAttribution: robertwb commentedComment #10
robertwb CreditAttribution: robertwb commentedComment #11
robertwb CreditAttribution: robertwb commentedComment #12
robertwb CreditAttribution: robertwb commentedComment #13
jkleiner CreditAttribution: jkleiner commentedUsed R to create a file of ‘conveyance features’ for import using feeds, complete with line geometries and entity references. The entity IDs of the transfer features need to be used for setting entity references NOT the hydrocodes of those features.
Conveyance Feature Importer: http://deq1.bse.vt.edu/d.alpha/import/vwuds_import_conveyance_feature
Table of conveyance features: http://deq1.bse.vt.edu/d.alpha/vwuds-transfers-import-table?hydrocode
Map of conveyance features: http://deq1.bse.vt.edu/d.alpha/vwuds_transfers_map
Conveyance feature type: http://deq1.bse.vt.edu/d.alpha/admin/structure/dh_feature_type/manage/co...
Table of vwuds features themselves: http://deq1.bse.vt.edu/d.alpha/vwuds-transfers
Outstanding issues resulting in some transfer features not importing:
1. There’s at least one case where the same hydrocode (vwuds_0401) is used for 2 separate features in VAHydro
a. See here: http://deq1.bse.vt.edu/d.alpha/vwuds-transfers?hydrocode_1=vwuds_0401
2. Features that are part of a transfer but DON’T currently exist in VAHydro
3. Features that are part of a transfer and DO exist in VAHydro BUT have bogus geometries (these transfers DO import properly, they just render on a map funky)
a. Ex: -99,99 point location or no lat/long at all
Comment #14
robertwb CreditAttribution: robertwb commentedComment #15
robertwb CreditAttribution: robertwb commentedComment #16
robertwb CreditAttribution: robertwb commentedAdded link to export for transfer MPs: http://deq1.bse.vt.edu/files/vwuds/vwuds_tfr.tsv
Comment #17
jkleiner CreditAttribution: jkleiner commentedComment #18
jkleiner CreditAttribution: jkleiner commentedComment #19
jkleiner CreditAttribution: jkleiner commentedComment #20
robertwb CreditAttribution: robertwb commentedDebugging these joins:
Results:
Comment #21
robertwb CreditAttribution: robertwb commentedComment #22
robertwb CreditAttribution: robertwb commentedComment #23
robertwb CreditAttribution: robertwb commentedComment #24
jkleiner CreditAttribution: jkleiner commentedComment #25
robertwb CreditAttribution: robertwb commentedComment #26
robertwb CreditAttribution: robertwb commentedComment #27
robertwb CreditAttribution: robertwb commentedComment #28
robertwb CreditAttribution: robertwb commentedComment #29
robertwb CreditAttribution: robertwb commentedComment #30
c_thomas CreditAttribution: c_thomas commentedExample Facility Dashboard: d.alpha/ows-vwuds-facility-info/66943
Example Owner Dashboard: d.alpha/ows-vwuds-organization-info/65670
Comment #31
robertwb CreditAttribution: robertwb commentedComment #32
robertwb CreditAttribution: robertwb commentedComment #33
robertwb CreditAttribution: robertwb commentedComment #34
robertwb CreditAttribution: robertwb commentedComment #35
robertwb CreditAttribution: robertwb commentedComment #36
robertwb CreditAttribution: robertwb commentedComment #37
robertwb CreditAttribution: robertwb commentedComment #38
robertwb CreditAttribution: robertwb commentedComment #39
robertwb CreditAttribution: robertwb commentedAdded the method, max day columns to the monthly reporting record: http://deq1.bse.vt.edu/d.alpha/ows-vwuds-well-monthly/59840/2016-01-01?d...
Comment #40
robertwb CreditAttribution: robertwb commentedComment #41
robertwb CreditAttribution: robertwb commentedComment #42
c_thomas CreditAttribution: c_thomas commentedComment #43
c_thomas CreditAttribution: c_thomas commentedComment #44
robertwb CreditAttribution: robertwb commentedComment #45
robertwb CreditAttribution: robertwb commentedComment #46
c_thomas CreditAttribution: c_thomas commentedComment #47
c_thomas CreditAttribution: c_thomas commentedComment #48
c_thomas CreditAttribution: c_thomas commentedComment #49
c_thomas CreditAttribution: c_thomas commented