Questions tagged [yii2-module]

28 questions
0
votes
1 answer

How to use one module in two different application/project in yii2

I have module created in the basic project of yii2 and now i want to access or use that module another project/application of mine.... How can I achieve this. please help me out here.
0
votes
1 answer

Yii 2 Module wise configuration setting

I have setup Yii2 nested module and I want to set different configuration and each modules has own component and other settings with there own models Like in School Management System, I have created a nested module like V1 is my API (main module)…
Jitendra Y
  • 25
  • 11
0
votes
1 answer

I cant access yii2 survey extension to create form

I'm using survey module for Yii2 application, but I cant access the create page of this extension. In the page of this extension there is: Now go to /survey in your backend and create a survey I also I've changed my backend to fcadmin in my…
Mohammad Aghayari
  • 1,010
  • 3
  • 15
  • 38
0
votes
2 answers

Yii2: Override 3rd party mail views

How do we override mail view files of a 3rd party module/component? Let's assume a module is using the following code to send an email: Yii::$app->mailer->compose([ 'html' => '@myvendor/mymodule/mail/email-html', 'text' =>…
mae
  • 14,947
  • 8
  • 32
  • 47
0
votes
2 answers

Yii2 Module with different database

I want to combine two applications. One of these as module. There are two different databases. The Module use another database as the base appliaction. I have created the db connection, which is a component in config.php return [ 'class' =>…
Shorty
  • 55
  • 1
  • 7
0
votes
0 answers

Yii2 - Create module using Advanced template

I understand building a module is like a mini Yii2 application. I am trying to build a Blog module to reuse on different projects. I would like to create a module containing backend and frontend and then being able to access each side. In Yii2…
Eduardo
  • 1,781
  • 3
  • 26
  • 61
0
votes
1 answer

Lost in yii2 module i18n translation

I am trying to add multilanguage functionality to a module I found in Russian, but I am getting problems when I try to implement it probably the configuration, no sure. I did the text replacement as I normaly do in the applications: 'department' =>…
0
votes
1 answer

Yii2 Assets: How to use image asset inside CSS file?

I want to create an extension which contains an AssetBundle, which provides a simple static CSS file. In that static CSS file, I want to use an image file, which is also part of the extension. How can I know the image file's URL so I can use it…
mae
  • 14,947
  • 8
  • 32
  • 47
0
votes
1 answer

Routing in module doesn't work Yii 2

I am new in Yii 2 and my problem is about routing inside a module. I have a module in my app which is a profile cabinet both for users and admins. I created a CabinetController instead of DefaultController and also I created a AdminController and…
Timur Gilauri
  • 824
  • 8
  • 13
0
votes
1 answer

Realize a multi-tenant application (structure)

(This question is not about databases. I know databases are often regarded when it comes to multi-tenancy. But this is not my question.) I create an application that will be used by different customers. They can see and do mostly the same things.…
robsch
  • 9,358
  • 9
  • 63
  • 104
0
votes
2 answers

When to create a module in Yii2 Advanced template?

I am little confused before starting a new project in Yii2 advanced template. So, i am asking this question. I have done some projects in "Yii2 basic" app in which we use modules for different parts of our application like for adminpanel, api we…
Ninja Turtle
  • 1,293
  • 2
  • 24
  • 50
0
votes
2 answers

Yii2: Add/remove validation rules in Model from 3rd party module

In the main Yii2 application, how can we add validation rules to a Module (or an ActiveRecord) that comes with a 3rd party module? Can we modify existing rules? Say we have the following rule: ['currency', 'in', 'range' => ['USD', 'GBP',…
mae
  • 14,947
  • 8
  • 32
  • 47
0
votes
1 answer

YII2 RESTFUL 404

I search for this get less infomesion while I doing my config (rest.php) 'rest-api', 'basePath' => dirname(__DIR__), 'language' => 'zh-CN', 'controllerNamespace'…
1
2