Recent Work – Start of June Edition

My date titles continue to get blurrier. The range of stuff covered gets wider.

VCU is moving any course with over 50 students to the online format. We’re supporting that move in a variety of ways. Our little R&D group is trying to answer the non-standard problems, questions, media desires. To some degree we are trying to create those desires.

Chemistry/Pharmacy

Like my brief foray into protein molecules, I found there are lots of chemistry options out there.

My first round was with Kekule.js1 and I have a little CodePen demo of the editor here.

My next attempt was with Chemdoodle. I’ve got a functioning editor and interactive molecule up on CodePen.

These clearly aren’t feats of programming on my end. I’m just exploring the libraries and trying to get a feel for how hard/easy it is to use them. I also figure putting them up in CodePen might help other amature people get something working more quickly than some of the documentation allows.

Now that I have a bit of background understanding I’ll be able to provide examples and make suggestions if the faculty need arises.2 That is some of what’s difficult in this scenario. I have to be able to move pretty quickly but have no clear idea where people will want to go or even if they will want anything beyond standard LMS interactions. It’d be pretty easy to tie these into a WordPress plugin.

GitHub 3D Files in Canvas Tool

Another generator-ish tool to let you stick 3D things from GitHub into anything that lets you have iframes. Since GitHub automatically supports interactive 3D files (up to 10MB) you can embed them into anything that will let you post HTML. You can see the results below.

All the tool does is generate the iframe pattern and the inline CSS. I’m looking into adding some CSS classes to Canvas that will enable me to do a lot of this without all the mess inline CSS. No question it can be done, more the politics of doing it here at VCU.

It’s kind of fun as this is revisiting something I did with Bernard Means (Anthropology and king of 3d stuff) around passenger pigeon bones when I first started at VCU.

Google Sheets Function

We needed to better understand what’s going on with the faculty that are taking some of the PD we’re offering. We managed to get a download of all the courses being offered in Excel. Unfortunately, they are listed by names rather than eID/email/whatever. That makes life much harder.

What I ended up having to do is use the QUERY option and then wrote a way to make an extended OR this name OR this name OR this name based on a column of names. So this function takes the name list from A2 through A359 and uses it to look on the main class list sheet and finds the matches.

It’s ugly but it works.3

=QUERY(vcu_all_courses_fall_2020.xls!A1:AG9162,”SELECT * WHERE AG = ‘” & join(“‘ or AG = ‘”, A2:A359) & “‘”)

Video/Presentation Window – 100% Switcher

Here’s the video window site. No idea if this will end up satisfying the people who seem unhappy with their options but it was only five minutes of work to make this expansion. The page shows Google Slides alongside your video camera capture. It now allows you switch between 100% video/100% presentation and a 50/50 split.

Early Engineers WordPress Theme

This WordPress theme is for a K12/VCU School of Engineering partnership for sharing lessons. It’ll be tied into VA SOLs, a shared Google Drive folder etc. You can see the ugliest possible version4 of what that looks like here. This represents me cramming an hour of work into a meeting where I wasn’t fully engaged.

Generic Lab Custom Post Types

Working on making it possible for faculty to expand whatever WordPress theme they want to have faculty and publication custom post types. This is a plugin that will add that and give you some shortcodes. It’s about 80% done but has been on the back burner because of all the other stuff. You can see the faculty layout below which is calling all faculty and then a particular category of faculty in the second row.

View of the faculty page using the shortcode.

ACF Form Knowledge

I had used the ACF Form plugin because I hadn’t looked at the built in ACF options. If you can do a bit of programming this is so very powerful and awesome without any additional plugins. Here’s a simple example that creates a custom post type called “course” with the form being composed of the ACF fields with IDs 6 and 22 and then publishes it.

<?php 
		if(is_user_logged_in()){
		acf_form(array(
			'post_title' 	=> true,
		        'post_id'       => 'new_post',//make a new post
		        'new_post'      => array(
			        'post_type'     => 'course',//custom post type
		                'post_status'   => 'publish',//post status
			        ),
		    'field_groups' => array(6,22), // get the acf field groups you want
	            'form' => true,
	            'return' => '%post_url%' , // Redirect to new post url         
		        'submit_value'  => 'Create new course'//button text
		    )); 
			} else {
				echo '<a href="'. wp_login_url( get_permalink() ).'">Please login to create new courses.</a>';//provide login button if not logged in
			}
			
	    ?>

And then I can create a custom page template that has the ACF field accessible at the bottom so people can update via the same methodology. This is really nice in that it deals with repeater fields, auto-fills the form elements with the existing information etc. I will use this a million times in the near future.


<?php if (current_user_can( 'edit_post', $post->ID )) //if the user is logged in : ?> 
				<button class="btn btn-primary" type="button" data-toggle="collapse" data-target="#editCourse" aria-expanded="false" aria-controls="collapseExample">
			    	Edit/Update Your Course
			  	</button>
			  	<div class="collapse" id="editCourse">
		            <?php             
		            $post_id = get_the_ID();
		            acf_form(array(
				        'post_id'       => $post_id,//current post 
				        'post_title'    => false,
				        'post_content'  => false,
				        'submit_value'  => __('Update Course Information'),
				        'updated_message' => __("Course successfully updated", 'acf'),
				        'html_updated_message'  => '<div id="message" class="updated"><p>%s</p></div>',
				    )); ?>
				</div>
			<?php endif; ?>

1 I also found out Kekule was a German chemist. Initially I thought it was a weird joke related to molecule.

2 That sounds kind of like a horror movie line — The faculty need arises.

3 That’s close to my motto. Except sometimes my stuff doesn’t work.

4 I’m replacing “least viable product” with this new phrase.

Comments on this post

  1. carpetbomberz said on June 15, 2020 at 12:48 pm

    So in the hierarchy of “possible products” I’m guessing it might ranks somewhat like:
    1.) Minimum Viable Product (MVP) – very scant features but “works”
    2.) Least Viable Product (LVP) – almost achieves the one feature you want
    3.) Ugliest Possible Version (UPV) – achieves the feature but in a brute force, tedious, unscaleable way.

    :^)

    And then there’s Broken and Ugly (B&U) – not a viable/possible product

    • Tom Woodward said on June 23, 2020 at 10:45 am

      I’ll have to add these to my project management book.

      • carpetbomberz said on June 24, 2020 at 7:05 am

        I’m certain with the right publisher these would be adopted by every Ted Talk presenter within a year. Everyone’s still pursuing Agile, but the next big thing will be Pragmatic programming.

        • Tom Woodward said on June 26, 2020 at 6:02 am

          Please get me a publisher. I would like to cash in on the TED Talk money train.

Leave a Reply

Trackbacks and Pingbacks on this post

No trackbacks.

TrackBack URL