Questions tagged [beego]

Beego is an open-source, high-performance, modular, full-stack web framework for the Go programming language.

Beego is a Web framework for rapid development of Go applications. It can be used to develop APIs, web apps and backend services quickly. It is a RESTful framework. It is inspired by Tornado, Sinatra and Flask and has integrated some of Go-specific features such as interfaces and struct embedding.

Features

  • RESTful support
  • MVC architecture
  • Modularity
  • Auto API documents
  • Annotation router
  • Namespace
  • Powerful development tools
  • Full stack for Web & API

Useful links

Official documentation

Github repo

Beego community

Beego Books

285 questions
0
votes
1 answer

How get data from database in Go&Beego?

I try create a simple REST service on Go&Beego. I can not understand the logic of Beego. All examples have information on how to retrieve just one item while I need to get all items. In case of API. Controller: package controllers import ( …
0
votes
1 answer

How to constrain range using beego orm

I would like to constrain an attribute to a certain range using beego orm, similar to CHECK(“column” >= 0 AND “column” <= 10) in the table setup. Can I do this with beego, and if yes, how?
Aecturus
  • 163
  • 1
  • 4
0
votes
1 answer

No command 'bee' found

I am trying to run a project that uses beego framework. When I try to run the project I encounter the following problem every time. No command 'bee' found, did you mean: Command 'bel' from package 'belier' (universe) Command 'bbe' from package…
safaer
  • 191
  • 1
  • 2
  • 11
0
votes
1 answer

Login to a website using beego

I think i have a problem with my syntax but i can't find it. I tried to login but it always ended up with 404 pages. this is routers/router.go : beego.Router("/", &controllers.AccController{},"get:Home") beego.Router("/acc/login",…
Ara
  • 1
0
votes
1 answer

Beego and Angular 4

I'm trying to get my head around using beego and Angular4 together. I'm trying to use the angular-cli and generate a new project. Has somebody used the two frameworks together and can share a few insights on setting up their development and…
Tino
  • 3,340
  • 5
  • 44
  • 74
0
votes
0 answers

Beego ORM: RelatedSel with specified columns

I'm using Beego ORM for my database accesses. Currently I'm trying to write a query that joins two tables, user and account, and only returns certain columns of the resulting table. Something like this: SELECT Email, FirstName, LastName,…
Gilrich
  • 305
  • 3
  • 13
0
votes
2 answers

Beego how to access params submitted with multipart/form-data header?

I've ran into a problem as follows: When I make a curl request to my beego app curl http://localhost:8080/controller/path -X POST -H 'Content-Type: multipart/form-data; charset=UTF-8' -F “file=@file.csv;filename=file.csv” -F “name=first” I…
Elmor
  • 4,775
  • 6
  • 38
  • 70
0
votes
0 answers

Cannot connect to PostgreSQL database in Beego

I am playing around with Beego, but I stuck at connects to the PostgreSQL db. Models package models import( "github.com/astaxie/beego/orm" "time" ) type User struct { Id int Username string `orm:"size(100);unique"` Email…
dev-jim
  • 2,404
  • 6
  • 35
  • 61
0
votes
1 answer

Forward server API to another port using Beego

I have two web apps running in the same virtual machine. One is Beego listening to port 443, and another is Centrifugo messaging server at port 8000. If a user is not allowed to connect port 8000 due to his ISP, is it possible that I forward…
Ernie
  • 77
  • 3
  • 9
0
votes
1 answer

Beego ORM with MySQL

I am new to Beego as well as Go. I read its documentation but it puts every ORM operation in the main package instead of model package. I can't understand how to organize the code. I am really very confused.
Manish Champaneri
  • 654
  • 3
  • 8
  • 28
0
votes
0 answers

How to send https request in Go or Beego

if it is just HTTP request to be sent in go then I will use out, err := json.Marshal(ios_push) if err != nil { panic(err) } req, err := http.NewRequest("POST", l_url, bytes.NewBuffer(out)) req.Header.Set("X-Custom-Header",…
gophervk
  • 67
  • 8
0
votes
2 answers

Beego/Golang - Query Values to Struct

I have an API built in Golang using the Beego framework and I have a single query that has multiple joins and then returns a JSON result. I was hoping there is a way for me to cast each row into a struct which has nicer key names, IE rather than…
xXPhenom22Xx
  • 1,265
  • 5
  • 29
  • 63
0
votes
2 answers

Golang duplicate rails Devise gem password encryption

I have to authenticate user in a new app which uses Beego framework for Golang, twist is that DB is from Rails application where authentication is implemented using gem Devise . I've looked at gem Bcrypt…
Elmor
  • 4,775
  • 6
  • 38
  • 70
0
votes
2 answers

Beego not accepting ajax params

I'm trying to make simple POST request using VueJS to an application which is written in Beego framework (GoLang) but the application doesn't see any input request. Everything is ok when I use standard form request (no ajax). This is my VueJS…
Alen
  • 1,750
  • 7
  • 31
  • 62
0
votes
1 answer

Cannot update the timestamp column in mysql using golang

I am using golang in my application.I m using beego framework to create it.I use beego ORM to do the database operations.I do the following num, err := o.Raw("UPDATE apply_leave SET leavestatus=?,resultdate=? WHERE…
rajesh kumar
  • 57
  • 1
  • 9