Page MenuHomePhabricator

Add basic NUX support to SearchEngines
ClosedPublic

Authored by epriestley on Dec 19 2015, 8:44 PM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Nov 23, 9:01 AM
Unknown Object (File)
Wed, Nov 16, 9:58 PM
Unknown Object (File)
Tue, Nov 15, 12:31 PM
Unknown Object (File)
Fri, Nov 11, 7:54 PM
Unknown Object (File)
Thu, Nov 10, 2:39 AM
Unknown Object (File)
Wed, Nov 9, 10:00 PM
Unknown Object (File)
Wed, Nov 9, 7:24 AM
Unknown Object (File)
Oct 31 2022, 3:23 PM
Subscribers
None

Details

Reviewers
chad
Commits
Restricted Diffusion Commit
rPdbb84f1ddc12: Add basic NUX support to SearchEngines
Summary

This is just putting a hook in that pretty much works. Behavior:

  • If you visit /maniphest/?nux=true, it always shows NUX for testing.
  • Otherwise, it shows NUX if there are no objects in the application yet.
Test Plan

Screen Shot 2015-12-19 at 12.44.17 PM.png (787×1 px, 132 KB)

Diff Detail

Repository
rP Phabricator
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

epriestley retitled this revision from to Add basic NUX support to SearchEngines.
epriestley updated this object.
epriestley edited the test plan for this revision. (Show Details)
epriestley added a reviewer: chad.
src/applications/maniphest/query/ManiphestTaskSearchEngine.php
388–394 ↗(On Diff #35851)

I'll delete these before landing if the rest of this seems reasonable.

This revision is now accepted and ready to land.Dec 19 2015, 8:48 PM
epriestley edited edge metadata.
  • Strip out placeholder/demo text so this can go upstream.
This revision was automatically updated to reflect the committed changes.
src/applications/search/controller/PhabricatorApplicationSearchController.php
232

erm, where do I drop this new function? I tried SearchEngine but it complains about being final.

Yeah, the naming is really confusing right now (I'm going to fix that as part of T9979.

SearchEngine is about fulltext search and search indexing. I'm going to rename that to IndexEngine.

ApplicationSearchEngine is what you want.

To get a basic version working:

  • Implement getNewUserHeader() getNewUserBody() in an ApplicationSearchEngine subclass like ManiphestTaskSearchEngine.
  • Visit /maniphest/?nux=true.
  • To get fancier, mess around with PhabricatorApplicationSearchEngine-> renderNewUserView() (see inline).
  • This will be less confusing soon.
src/applications/search/engine/PhabricatorApplicationSearchEngine.php
1357–1371

Mess with this to get a fancier UI.