New legislation that would create California’s first comprehensive attempt to regulate the medical marijuana industry would give Long Beach and other cities considerable leeway to regulate the sales and cultivation of cannabis.

Local governments could even enact outright bans on dispensaries and cultivation sites.

Such is the view of the Long Beach City Attorney’s office, where lawyers had roughly one week to examine a trio of bills that passed before the state’s Sept. 11 deadline on new laws ran out.

“The MMRSA (Medical Marijuana Regulation and Safety Act) makes clear that local public entities retain their current right to ban medical marijuana dispensaries, cultivation sites, and related medical marijuana activities within their respective jurisdictions,” Long Beach assistant city attorney Michael Mais wrote in an analysis released Friday afternoon.

• Medical marijuana in Long Beach: What you need to know

“The MMRSA also makes clear that cities are fully empowered to adopt regulatory ordinances related to medical marijuana.”

Long Beach officials have spent much of the past year attempting to write a medical marijuana law for the city. Dispensaries are generally banned within city limits.

The term Medical Marijuana Regulation and Safety Act refers to three bills — A.B. 243, A.B. 266 and S.B. 643 — drafted through what’s known in government lingo as the “gut and amend” process. That means lawmakers substantially rewrote existing bills at a late point in the legislative calendar.

Gov. Jerry Brown has yet to sign the bills, but was involved in the negotiations to write the legislation.

Key provisions of the bills include the establishment of a statewide Bureau of Medical Marijuana Regulation and a licensing system for people involved in the medical marijuana industry. The legislation also calls for state officials to draft regulations on such matters as the lab testing of cannabis products and use of pesticides by marijuana cultivators.

In Long Beach, the city’s Planning Commission approved a draft medical marijuana ordinance last October and the City Council commissioned a special committee to recommend possible amendments to that ordinance.

The Planning Commission’s version of the law would allow up to 18 dispensaries in the city and include such restrictions as requiring dispensaries to obtain conditional use permits and operating 1,500 feet from any high school or 1,000 feet away from other kinds of schools.

The special committee generally recommended other restrictions, including assessing a fee on dispensaries and requiring providers to submit marijuana products for laboratory testing. The panel also, however, voted to allow marijuana deliveries and to let providers share product.

The city attorney’s office analysis notes the new legislation would regulate testing at the state, instead of the local level, but would otherwise allow cities like Long Beach to establish zoning rules in which many proposed restrictions would be allowed.

The analysis also holds that cities would have power to levy marijuana-related taxes under the new bills.

In April 2014, 74 percent of Long Beach voters passed Measure A, which would allow City Hall to tax dispensaries. First, however, the city would actually have to allow dispensaries to collect any such taxes.

The assistant city attorney’s report is scheduled to be discussed when the Long Beach council meets on Tuesday. The council had put its considerations of a medical marijuana law for the city on hold at Mayor Robert Garcia’s suggestion in order to find out how Sacramento lawmakers would attempt to deal with the issue.

That decision was made during the council’s Sept. 1 meeting, which attracted people on both sides of the medical marijuana issue, with some calling for a continuation of a ban and others who pointed to marijuana as an effective treatment for medical problems.

“I’m appalled to hear the word ‘ban’ all over again,” medical marijuana supporter Larry King said during that meeting. King was a member of the city’s medical marijuana committee.

At least one council member wants Long Beach to keep its ban, at least for the time being. Councilwoman Stacy Rose Mungo wants the city to refuse dispensaries until the state’s regulatory framework is in effect.

“I hope my colleagues will support a ban until protections are in place for patients and neighbors,” she said.

The City Council is scheduled to meet at 5 p.m. Tuesday at City Hall, 333 W. Ocean Blvd.w

Contact Andrew Edwards at 562-499-1274.