datasource as cfg: enable editable ds's

This commit is contained in:
bergquist
2017-10-26 14:23:31 +02:00
parent b72cdae563
commit 0f136a940c
6 changed files with 12 additions and 2 deletions

View File

@@ -159,6 +159,7 @@ func UpdateDataSource(cmd *m.UpdateDataSourceCommand) error {
sess.UseBool("is_default")
sess.UseBool("basic_auth")
sess.UseBool("with_credentials")
sess.UseBool("read_only")
var updateSession *xorm.Session
if cmd.Version != 0 {

View File

@@ -45,6 +45,7 @@ func TestDataAccess(t *testing.T) {
Access: m.DS_ACCESS_DIRECT,
Url: "http://test",
Database: "site",
ReadOnly: true,
})
So(err, ShouldBeNil)
@@ -59,6 +60,7 @@ func TestDataAccess(t *testing.T) {
So(ds.OrgId, ShouldEqual, 10)
So(ds.Database, ShouldEqual, "site")
So(ds.ReadOnly, ShouldBeTrue)
})
Convey("Given a datasource", func() {