1. 30 Mar, 2021 1 commit
  2. 29 Jul, 2020 2 commits
  3. 28 Jun, 2020 2 commits
  4. 22 Jun, 2020 35 commits
    • Ana Rute Mendes's avatar
      CCU: handle snipe-IT exceptions and ticket transactions · 049a98f2
      Ana Rute Mendes authored
      After creating items in Snipe-It we need to save in the ticket
      (maniphest task) the created ids and tags. So instead of receiving only
      the ids list, the SnipeIt extension will return transactions or
      validation errors.
      If it returns an errror, append it to the list. If not, it's
      an array of transactions so add them to the results array to update the
      purchasing request.
    • Ana Rute Mendes's avatar
      CCU: change progress bar color · 10dfb5e9
      Ana Rute Mendes authored
      in progress points were hard to spot
    • Ana Rute Mendes's avatar
      CCU: snipe-it: add asset tag field · 7a6ff002
      Ana Rute Mendes authored
      every item has an asset tag that can now be mannually edited from phab
    • Ana Rute Mendes's avatar
      CCU: create progress bar only if task has children · ab0e7264
      Ana Rute Mendes authored
      If the task has no children it doesn't make much sense
      to display the progress bar as the progress can only be 0 or 100%
    • Daniel Stone's avatar
      CCU: Ignore restricted child tasks for progress bar · 46b61d7b
      Daniel Stone authored
      If we have a child task which we can't access, ManiphestTaskQuery will
      raise an exception; trying to view the workboard, this will bubble up as
      a policy exception which will (incorrectly) tell the viewer they can't
      access the project.
      Catch any exceptions whilst trying to calculate overall progress, and
      ignore those restricted child tasks.
    • Ana Rute Mendes's avatar
      CCU: display RAG indicator and progress bar in task card · edf4171f
      Ana Rute Mendes authored
      Based on the custom field `std:maniphest:collabora:rag-status`
      display the RAG indicator in the task card as well as a progress
      bar that exposes the task children points.
    • Ana Rute Mendes's avatar
      CCU: snipe-it: add choices.js to items list in purchase request · 3f0cfde4
      Ana Rute Mendes authored
      To make the assets field searchable, add choices.js lib to the field,
      adapt its style to look like a native phabricator field and dynamically
      display the items details.
    • Ana Rute Mendes's avatar
      CCU: snipe-it: remove fields from purchasing form validation · ef3868ba
      Ana Rute Mendes authored
      The fields item dimensions and weight won't be used anymore in the
      purchasing ticket.
    • Ana Rute Mendes's avatar
    • Ana Rute Mendes's avatar
      CCU: purchasing: Support for multiple items · 53b83eb2
      Ana Rute Mendes authored
      Allows a ticket to have up to 5 items in the same
      purchasing request.
      Handle the hiding/displaying of a mini form for each asset and
      control display of properties that are used only in Snipe-IT.
    • Ana Rute Mendes's avatar
      LOCAL:Maniphest:Apply approver rule to event type · eb96b097
      Ana Rute Mendes authored
      Replicate the logic to auto-fill approver for `event` subtype.
      Until now event and purchasing forms used the same template but
      they were split in two - `purchasing` and `event` - after the
      Snipe-IT integration that applied major changes in the purchasing
      request form.
    • Ana Rute Mendes's avatar
      Add snipe-it custom JavaScript validation · e096541e
      Ana Rute Mendes authored
      The only way I found to add a custom js file was directly in the
      webroot folder. To make sure it never generate conflicts when updaitng
      phab, I created an extensions folder in the js directory.
      This file is called by the SnipeHelper class.
    • Ana Rute Mendes's avatar
      LOCAL: Validate variables before calling functions · d1178006
      Ana Rute Mendes authored
      Some customization are not being used in Phabricator Apertis
      instance. So some features were breaking when calling functions
      in variables that were null
    • Ana Rute Mendes's avatar
      Add try/catch in the SnipeHelper calls · 32def70e
      Ana Rute Mendes authored
      Make sure phab won't raise errors if the SnipeHelper methods
      or API requests fail.
    • Ana Rute Mendes's avatar
      LOCAL: Maniphest: trigger Shipping Req. autofill · 78e46c5e
      Ana Rute Mendes authored
      If a Shipping Request is edited and it has the asset id field
      filled, trigger the method that will fetch the data from Snipe-IT
      and fill the item details in the task.
    • Ana Rute Mendes's avatar
      LOCAL: Maniphest: trigger asset item creation · 6f8f0e14
      Ana Rute Mendes authored
      When a Purchasing Request changes status to "To Relase" an asset
      must be created in the inventory system, external from Phabricator.
      Trigger the create asset method that is placed in the extensions folder.
    • Ana Rute Mendes's avatar
      Nit pick: replace if statements with switch · 5996c6a9
      Ana Rute Mendes authored
      These conditions will increase, to keep the code cleaner replace 3
      if statements with a switch
    • Ana Rute Mendes's avatar
      Update sysadmin ticket project · f34303d3
      Ana Rute Mendes authored
    • Ana Rute Mendes's avatar
      LOCAL/POLICY: set sysadmin requests policies · 50084152
      Ana Rute Mendes authored
      Set sysadmin resquests policies according to confidentiality
      chosen by the user.
    • Ana Rute Mendes's avatar
      LOCAL: Restrict All users policy for top-level docs · 787875e2
      Ana Rute Mendes authored
      Restrict the creation of a new top-level document if visibility or
      edition policies are set to "All users".
      See T4759
    • Daniel Stone's avatar
      LOCAL: Make 'All Users' space extremely magic · 446c73ce
      Daniel Stone authored
      Phriction's view policy is ancestral: in order to access /w/foo/bar/baz,
      you must be able to access /w/foo and /w/bar in addition to
      /w/foo/bar/baz itself.
      This is fine and makes life easy: by setting restrictive policies on
      top-level pages, we can lessen the risk of someone exposing information
      they shouldn't, by accidentally making
      /w/cold-fusion/secret-research/funding-meeting/2018-09-14 public, when
      the rest of the hierarchy is super locked down.
      Phriction also recently gained Spaces support, which is nice: rather
      than trying to lock down with groups and harmonise permissions, we can
      just move top-level wiki pages to a particular Space, and then we don't
      need to worry about groups.
      Our clients don't know Spaces even exist, which is great since it avoids
      us having to explain the two-tier permission model to them. The reason
      they don't know it exists is because if you can only see a single Space,
      then Phabricator hides the entire Spaces UI away from you. Great!
      Unfortunately one detail ruins everything: /w/ is a top-level page
      itself, it counts for permission checks, and it _must be in a Space_.
      So, there is no way to have wiki documents in mutually-invisible Spaces
      unless you also have a common Space, at which point the whole Spaces UI
      suddenly becomes very visible everywhere.
      In order to try to keep our wiki partitioned, but to not confuse our
      clients (and give them the chance to potentially expose confidential
      information!), we:
        - have a magic 'Visible to Everyone' space
        - actually hide that space from everyone with policies
        - hack policy filters to make this space visible to everyone _only
          for the purpose of checking policies on wiki objects_
        - only allow admins to change view/edit policies on the root wiki
          page (see comment for reason why)
      This actual patch can obviously never go anywhere near upstream, but on
      the other hand we should probably make them aware of the problem and see
      if they're interested in discussing a solution, which is probably just
      to bless the root page with magic semantics.
      Signed-off-by: Daniel Stone's avatarDaniel Stone <daniels@collabora.com>
    • Daniel Stone's avatar
      LOCAL/UI: PHUI: Add custom Collabora colour scheme · e82bd97d
      Daniel Stone authored
      Add a colour scheme for tagging objects in lists.
    • Daniel Stone's avatar
      LOCAL/UI: Project: Reorder profile tabs · 006bd155
      Daniel Stone authored
      This is a UI tweak.
    • Daniel Stone's avatar
      LOCAL/UI: Diffusion: Set default autoclose to 'master' · be2c4b36
      Daniel Stone authored
      Encode policy, allowing patches to land on feature branches without
      closing tasks.
    • Daniel Stone's avatar
      LOCAL/UI: Differential: Use tab width of 8 rather than 2 · 3d2aa478
      Daniel Stone authored
      It would be nice, as the comment notes, to have this customisable perhaps
      per-repository, but for the meantime this is unambiguously the better
    • Evan Priestley's avatar
      LOCAL/UI: PHUIHandleTagListView: Sort alphabetically · e330ed58
      Evan Priestley authored
      Sort tags alphabetically, rather than order of (PHID) appearance in the
      From https://secure.phabricator.com/p/epriestley at:
    • Daniel Stone's avatar
      LOCAL/UI: Maniphest: Show points and review status in task queries · fa756098
      Daniel Stone authored
      In the Maniphest query result view, show the story points as well as the
      review/CI status on each task as we currently show them in workboard
      column cards, along with the project tags.
      This is local UI policy; the correct fix (of rewriting hover/card views
      to be more generic and extensible) is pretty much impossible to achieve,
      and isn't approachable by non-Phacility contributors.
    • Daniel Stone's avatar
      LOCAL/UI: Project: Show task status in workboard cards · 4dcef812
      Daniel Stone authored
      Show the status of every task in workboard cards using the icons
      explicitly, rather than just differentiating between closed and
      This is a local UI choice.
    • Daniel Stone's avatar
      LOCAL/UI: Project: Show review/CI status on workboard · ecb1b12d
      Daniel Stone authored
      On project workboard cards, also show the status of linked code reviews;
      both the review itself, and any attached Harbormaster CI buildables.
      This is already taken care of in the task-detail view by 45c740ac,
      and extends it to the workboard view. It should probably share more code
      with the task-detail view.
      It will not be accepted upstream in its current form; it was felt in
      https://secure.phabricator.com/T7076 discussion that performing multiple
      queries for each revision to get the current state was too much. This
      makes it exceedingly unlikely that doing the same number of queries for
      every task in a workboard would be acceptable.
      There was discussion of how to fix that, but it was essentially
      impossible, and explicitly discouraged for anyone to even try.
    • Daniel Stone's avatar
      LOCAL/POLICY: Maniphest: Auto-assign purchasing tasks to approver · 0e82e784
      Daniel Stone authored
      Enforce a local policy, that on purchasing tasks, the approver will be
      auto-assigned if there is no assignee.
      The 'correct' fix would probably be a Herald rule, if it were actually
      possible to implement. An EditEngine extension might work as well, but
      this was easier.
    • Daniel Stone's avatar
      LOCAL/POLICY: Project: Make project field required for Maniphest · a3382d93
      Daniel Stone authored
      Enforce a local policy that all tasks must have an associated project.
    • Daniel Stone's avatar
      LOCAL/POLICY: Differential: Clear 'Depends On' when attaching new diff · f3aefef7
      Daniel Stone authored
      When we attach a new diff to a Differential revision, clear out its
      'Depends On' field. This is so we don't end up with dependency cycles
      when we rebase/cherry-pick commits out of order.
      As upstream do not use rebasing/chery-picking/multi-patch-branch
      workflows, this is unlikely to be accepted.
    • Daniel Stone's avatar
      HACK: Conduit: Accept OAuth2 Authorization header · ceb5d374
      Daniel Stone authored
      This is really lame. The Ruby OAuth2 client can only pass its token in
      the form data (which Phab is not prepared to accept), or as part of the
      Authorization header (which PHP strips out).
      Use a function only available in newer PHP to scrape the Authorization
      header from the raw stream.
      I have no idea what the correct fix is.
    • Daniel Stone's avatar
      HACK: OAuth: Accept Mattermost double-URI · 3c392731
      Daniel Stone authored
      Mattermost OAuth requires two separate URIs, whereas the Phabricator
      OAuth server only allows returning to a single URI. Special case
      Mattermost and get on with life.
      The correct fix is to actually allow multiple values in the OAuth
      configuration. I don't know off the top of my head how this would work,
      e.g. a tokenising field, or a multi-line field (which I don't know how
      to achieve without Remarkup), or ... ?
    • Daniel Stone's avatar
      HACK: Reverse add/remove transaction application order · f403b20b
      Daniel Stone authored
      PhabricatorApplicationTransactionEditor contains logic (inside
      combineTransactions -> mergeTransactions ->
      mergePHIDOrEdgeTransactions), which will combine two transactions of the
      same edge type and author, then apply the operations in a deterministic
      This breaks our change to remove dependencies when updating a
      Differential revision, since we (acting as the user who uploaded the
      revision) remove the DifferentialRevisionDependsOn edge, then have the
      Remarkup block parser add the dependencies from the commit message
      The two (simplified) transactions of:
          "1-from-our-change-to-differential": {
              "type": "edge",
              "-": {
      	    "PHID-DREV-1234": [...], // remove previous dep
          "2-from-remarkup-parsing": {
              "type": "edge",
              "+": {
      	    "PHID-DREV-1234": [...], // add dep from commit message
      get merged into:
          "1-combined": {
              "type": "edge",
      	"-": {
      	    "PHID-DREV-1234": [...], // remove previous dep
      	"+": {
      	    "PHID-DREV-1234": [...], // add dep from commit message
      getPHIDTransactionNewValue() then returns an empty dictionary, because
      it always executes the add before the remove, regardless of ordering.
      The correct fix would be quite invasive to the transaction editor
      (making the combine function considerably less naïve, and always
      preserving order of operation WRT identical PHIDs); the quick fix for
      now (at least) is to just make add operations execute after remove, thus
      'fixing' it for the only case we really care about.
      The correct fix is more time than worthwhile to achieve, especially
      since it's extremely difficult to achieve without code modifications.