https://discord.umbraco.com
Join Discord
Disable user in code
d

Domitnator

about 1 year ago
Hi Everyone, My main goal is to disable the user when our customer disabled the user in the external identity provider (Azure B2C). We implemented this according the docs: https://docs.umbraco.com/umbraco-cms/v/10.latest-lts/reference/security/auto-linking. All works well (users are linked, roles are assigned). But how can i disable a user when the user in the identity provider is "disabled" (we have a seperate property in Azure B2C for this: IsUmbracoBackofficeUser)? I tried setting the user.IsApproved in the OnExternalLogin method
OnExternalLogin = (user, loginInfo) =>
                {
                    // You can customize the member before it's saved whenever they have
                    // logged in with the external provider.
                    // i.e. Sync the member's name based on the Claims returned
                    // in the externalLogin info
                    user.IsApproved = false;
                    return true; //returns a boolean indicating if sign in should continue or not.
                }
but this doesnt seem to be saved to the database. Whenever i try to login again the user.IsApproved is true again. this DOES work in the OnAutoLinking method, but that method is only called the first time a user logins (and this does not exist in the umbraco database yet). Any ideas?
d
m
  • 2
  • 3
  • 23
Umbraco 14 for new projects?
r

Rene Truelsen (slyngel)

over 1 year ago
Hey - we're currently starting new web projects designed to go into production this fall. Would you consider Umbraco 14 being ready for production purposes? Or is it still too unstable for this? Our concern is that if go with Umbraco 13, we will encounter an unnecessary tecnical investment of time when we upgrade to Umbraco v14.x or v15, especially upgrading the custom properties we intend to build. Furthermore, we're not strong with Angular and thus building custom properties in Umbraco 14 should be easier and more in line with our strengths. Still - all this considered, I'm still not sure that v14 is stable is enough for production. What are your thoughts?
r
k
+7
  • 9
  • 13
  • 23
DateTime conversion issue after Partial Restore of page
k

knightyknight

over 1 year ago
I have performed a partial restore of a page in my local CMS from the dev environment on Umbraco cloud. The same exact page when viewed on the dev site displays the content just fine, but when I try and view the same pulled down content on my local copy I get a DateTime conversion error (see below). Has anyone else experienced this and if so what was the resolution? An error occurred Cannot assign value "23/06/2023 00:00:00" of type "System.String" to property "effectiveDate" expecting type "System.DateTime". Exception Details System.InvalidOperationException, System.Private.CoreLib, Version=8.0.0.0, Culture=neutral, PublicKeyToken=7cec85d7bea7798e: Cannot assign value "23/06/2023 00:00:00" of type "System.String" to property "effectiveDate" expecting type "System.DateTime".
k
k
  • 2
  • 4
  • 23
Umbraco onprem vs Umbraco Cloud questions
s

Steffen Nielsen

over 1 year ago
Hi everyone 😄 Im looking into Umbraco Cloud for one of our biggest customers that currently uses a onprem hosting model for Umbraco V13. I have come by some questions, that i would love to get your inputs on, as i don't want to be painten by the salesspeach that umbraco is so good at. These questions are all related to a pros/cons list i have, that i later on will present for our customer, so any input is relevant 😄 Note that if we decide to make the change from onprem to umbraco cloud, then we will need to go with the Enterprise plan. Questions 😄 1. Support: I have head both good and bad about the Umbraco support on their cloud product. So i will love to hear what your experience is. 2. Is it possible to disable major upgrades? Sometimes our customer can be a bit slow in changing deprecated components and that means that major updates that are made on the go, can be a danger for the website. 3. In a team of 10+ developers, how would a repo setup and deployment work? I would love some kind of diagram of the workflow for both PR, merge and deployment. I have found some online, but i don't feel that they explain it very well. Most documentation is about cloning the project to your local machine, but i rather have a github repo for all the development code, that can later be released. I might come up with more questions, but this is what i have for now 😄
s
s
+3
  • 5
  • 13
  • 23
sql server requirement for Umbraco
o

Onasi

over 1 year ago
Hello Umbraco community ! I'm trying to create a brand new project with visual studio, with the umbraco project template. I get an error 'cannot connect to the database'. I checked the error log and it says " database requires upgrade' The SQL server is the 2016 developer version, is upgrading the SQL server required to install umbraco? Which version does it support? Like minimal SQL server 2019? Thank you!
o
k
  • 2
  • 3
  • 23
TreeNodesRenderingNotification equivalent in 14?
m

Mark Drake

over 1 year ago
I have a package I'm trying to prepare for Umbraco 14 but a little lost on how I would transition from the C# api for this notification to whatever frontend management API exists to hook into a rendering event.
m
n
+2
  • 4
  • 18
  • 23
Multisite and Content Delivery API
a

ash_hitch

over 1 year ago
When using the Content Delivery API in a multi site setup whats the best way to filter just one sites nodes? Using decendants? but then doing a single call for the home node? http://localhost:59503/umbraco/delivery/api/v2/content?fetch=descendants:fe081cf5-376e-4aad-9f69-a0b627a3b660 Or have I missed a better option?
a
m
  • 2
  • 1
  • 23
Registering my own IApiContentResponseBuilder for Delivery API
p

ProNotion

almost 2 years ago
With v12 and the Delivery API - If I want to register my own
IApiContentResponseBuilder
- do I need to remove the default one first or will mine override the default when registered via an
IComposer
?
p
s
s
  • 3
  • 10
  • 23
[Solved] TinyMCE Codesample plugin - syntax highlighting not working
o

Owain Jones

almost 2 years ago
Hi all, I used to use the codesample plugin on TinyMCE, for codesamples in rich text, and prism.js on the frontend for sytax hylighting, in Umbraco 8. But I can't seem to get syntax highlighting working on Umbraco 12... I've enabled the plugin with the following app settings:
json
  "Umbraco": {
    "CMS": {
      "RichTextEditor": {
        "Commands": [
          {
            "Alias": "blockquote",
            "Name": "BlockQuote",
            "Mode": "Selection"
          },
          {
            "Alias": "codesample",
            "Name": "Code Sample",
            "Mode": "Insert"
          },
          {
            "Alias": "fullscreen",
            "Name": "Full Screen",
            "Mode": "Selection"
          }
        ],
        "Plugins": [
          "codesample",
          "fullscreen"
        ]
      }
    }
  }
Which makes it available in the rich text editor (see screenshot). I then downloaded the css and js files from: https://prismjs.com/download.html#themes=prism-okaidia&languages=markup+css+clike+javascript+csharp+css-extras+csv+docker+git+json+log+markdown+powershell+python+jsx+tsx+regex+scss+scheme+solution-file+sql+typescript+xml-doc+yaml&plugins=line-highlight+line-numbers+show-language+highlight-keywords+inline-color+toolbar+treeview and added them to my frontend. But syntax highlighting is just not working on the frontend, every guide online says it should "just work"... does anyone have any ideas?
o
h
+3
  • 5
  • 25
  • 23
Replacing Umbraco forms with Microsoft Forms
i

Ian Robinson

over 1 year ago
I have a client who has just started using Office 365 and is asking whether they should stop using Umbraco forms and use Microsoft forms instead. Then embed the MS form inside the page of their Umbraco website. I have suggested they do a small feasiblity study and check that MS forms supports all the Umbraco forms features they are using, but I haven't looked at Microsoft forms and wondered if anyone else any experience of the advantages and disadvantages of either solution?
i
h
d
  • 3
  • 3
  • 23
Previous828384Next

Umbraco

A hub and casual space for you to interact with fellow community members and learn more about Umbraco!

Powered by