Dnn module construction PA package production

Source: Internet
Author: User
Tags add time dnn

I am a newbie to dnn. When I first started into the company, I positioned myself very high. I always felt that the problem was very simple and I would be able to finish it soon. However, when a problem occurs on your own, your requirements are too high, and the supervisor keeps urging you.

I always put more pressure on myself, but there are many very simple problems. The same problem occurs many times, the more urgent the error, the more unable to keep up with the progress, the more busy. Over time, I lost confidence in myself.

To sum up these problems, there are several aspects:

1. The time cannot be displayed, and the Time Button cannot be clicked. The following sorting is messy (the storage process is faulty ())

 

 

Sorting is messy (stored procedures are not) (this problem usually occurs when loading, we do not determine whether the stored procedure exists)

 

 

 

The specific method is:

Link to the add time button ::

 

 

2. When the database query time is empty, how can we determine the problem? By default, getnull (time field) is used)

 

Getnull ()

  Public OverrideIdatareader getallbydescription (datetime startdate, datetime enddate,BoolIsadmin)
{
Return(Idatareader) sqlhelper. executereader (connectionstring, getfullyqualifiedname ("Getallbydescriptionttt"),Getnull (startdate), getnull (enddate), isadmin );
}

 

 

3. If your dnn has a new version, such a problem may occur when the original version is not uninstalled.

4. When we copy the dnn project to dotnetnuke04.09.05 (we usually copy the project to our new site first)

Add the class library to the appcode and modify the webconfig configuration file.

 

  <Codesubdirectories>
<AddDirectoryname= "Html" />
</Codesubdirectories>    

Modify the default connection

 

Connectionstring connection Modification

    <  Connectionstrings  >  
<! -- Connection string for SQL Server 2005 Express
<Add
Name = "sitesqlserver"
Connectionstring = "Data Source =. \ sqlexpress; Integrated Security = true; User instance = true; attachdbfilename = | datadirectory | database. MDF ;"
Providername = "system. Data. sqlclient"/> -->
<! -- Connection string for SQL Server 2000/2005 -->
< Add Name = "Sitesqlserver" Connectionstring = "Server = (local); database = joblisttest; uid = sa; Pwd = ;"   Providername = "System. Data. sqlclient" />
</ Connectionstrings >

Each time a version module is created, three sites are created. Now, joblist is used as an example.

Create (Source code site) To add a dnn site that contains admin, extract a dnnnuke4.9.5 module, name it joblist, and create a new website (joblist directory) on vs2008.

Then, modify the link and so on. webconfig is the same as above. Then, create a site that can generate the DLL.Bin site). Open vs2008 to create a project and select a web application.ProgramProject, the project name and the DLL file name you finally want to package. Then addTest siteDifferent from the source code site, there is no source code for the module built on its own. It is best not to load the self-packaged Pa on the source code site, otherwise, overwrite your source code and add a DLL in the Bing directory. the advantage of building these three sites is that the source site is easy to test, the bin site (insideCodeMust be consistent with the source code for later upgrade and maintenance.) note that when the resources source code file is copied, the project file must be converted to a web application.

All controls on the Desgin. CS page are added to the design. codebehind of the source code file is changed to codefile.

 

After writing the stored procedure, you must execute the correct SQL statement on the page host.

In addition, to determine whether the stored procedure exists, Unmount and delete the stored procedure if it exists, or directly create the stored procedure.

The statement is as follows:

 

Stored Procedure

  If     Exists  (  Select     *     From  DBO. sysobjects  Where ID  =     Object_id  (N  '  {Databaseowner} [{objectqualifier} addhtmltext]  '  )     And     Objectproperty  (ID, n  '  Isprocedure  ' )  =     1  )
Drop Procedure {Databaseowner} [ {Objectqualifier} addhtmltext ]
Go

Create Procedure {Databaseowner} [ {Objectqualifier} addhtmltext ]

@ Field 1 ...

As

Select ...

Go  

 

 

The most important thing is that the @ variable name defined by the module during fuzzy query must be the default one.Given a lengthOtherwise, there will be many problems (all of them are queried during each query)   Add the following code in 02.00.04sqldateaprovider to change the stored procedure (as shown above) and in Uninstall. sqldataprovider:

Drop procedure {databaseowner} [{objectqualifier} addhtmltext]
Go

 

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.