Description
Properties
| Name | Value |
|---|---|
| ANSI Nulls ON | True |
| Quoted Identifier ON | True |
| Encrypted | False |
| Execute As | |
| Assembly |
Parameters
20| Name | Data Type | Length | Description |
|---|---|---|---|
| @accion | varchar | 50 | |
| @p_web_id | int | 4 | |
| @web_name | varchar | 100 | |
| @web_title | varchar | 100 | |
| @http_host | varchar | 100 | |
| @uri_logo | varchar | 100 | |
| @uri_css1 | varchar | 100 | |
| @uri_css2 | varchar | 100 | |
| @uri_js1 | varchar | 100 | |
| @active | varchar | 100 | |
| @uri_icon | varchar | 100 | |
| @app_id | int | 4 | |
| @is_default | bit | 1 | |
| @cliente | int | 4 | |
| @sender | varchar | 100 | |
| @uri_email_logo | varchar | 100 | |
| @servicio_contratado | int | 4 | |
| @copyright | varchar | 100 | |
| @id_plataforma | varchar | 10 | |
| @id_menu_plataforma | varchar | 100 |
SQL Script
Copy
SET QUOTED_IDENTIFIER, ANSI_NULLS ON
GO
CREATE OR ALTER PROCEDURE dbo.multi_web_config
@accion varchar(50) = null, /*ALTA / ACTUALIZAR / LISTBYID */
@p_web_id int = null,
@web_name VARCHAR(100) = null,
@web_title VARCHAR(100) = null,
@http_host VARCHAR(100) = null,
@uri_logo VARCHAR(100) = null,
@uri_css1 VARCHAR(100) = null,
@uri_css2 VARCHAR(100) = null,
@uri_js1 VARCHAR(100) = null,
@active VARCHAR(100) = null,
@uri_icon VARCHAR(100) = null,
@app_id int = null,
@is_default bit = null,
@cliente int = null,
@sender VARCHAR(100) = null,
@uri_email_logo VARCHAR(100) = null,
@servicio_contratado int = null,
@copyright VARCHAR(100) = null,
@id_plataforma VARCHAR(10) = null,
@id_menu_plataforma VARCHAR(100) = null
AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;
if (upper(@accion) = 'ALTA')
begin
insert into multi_web (web_name, web_title, http_host, uri_logo, uri_css1, uri_css2, uri_js1, active, uri_icon, app_id, is_default,
cliente, sender, uri_email_logo, servicio_contratado, copyright, id_plataforma,id_menu_plataforma)
VALUES (@web_name, @web_title, @http_host, @uri_logo, @uri_css1, @uri_css2, @uri_js1, @active, @uri_icon, @app_id, @is_default, @cliente, @sender,
@uri_email_logo, @servicio_contratado, @copyright, @id_plataforma,@id_menu_plataforma)
SELECT @@IDENTITY
return
end
if (upper(@accion) = 'ACTUALIZAR')
begin
UPDATE multi_web
SET
web_name = @web_name ,
web_title = @web_title ,
http_host = @http_host ,
uri_logo = @uri_logo ,
uri_css1 = @uri_css1 ,
uri_css2 = @uri_css2 ,
uri_js1 = @uri_js1 ,
active = @active ,
uri_icon = @uri_icon ,
app_id = @app_id ,
is_default = @is_default ,
cliente = @cliente ,
sender = @sender ,
uri_email_logo = @uri_email_logo ,
servicio_contratado = @servicio_contratado,
copyright = @copyright ,
id_plataforma = @id_plataforma ,
id_menu_plataforma = @id_menu_plataforma
WHERE web_id = @p_web_id
return
end
if (@accion = 'LISTBYID')
begin
select * from multi_web where web_id = @p_web_id
end
end
GO
GO
CREATE OR ALTER PROCEDURE dbo.multi_web_config
@accion varchar(50) = null, /*ALTA / ACTUALIZAR / LISTBYID */
@p_web_id int = null,
@web_name VARCHAR(100) = null,
@web_title VARCHAR(100) = null,
@http_host VARCHAR(100) = null,
@uri_logo VARCHAR(100) = null,
@uri_css1 VARCHAR(100) = null,
@uri_css2 VARCHAR(100) = null,
@uri_js1 VARCHAR(100) = null,
@active VARCHAR(100) = null,
@uri_icon VARCHAR(100) = null,
@app_id int = null,
@is_default bit = null,
@cliente int = null,
@sender VARCHAR(100) = null,
@uri_email_logo VARCHAR(100) = null,
@servicio_contratado int = null,
@copyright VARCHAR(100) = null,
@id_plataforma VARCHAR(10) = null,
@id_menu_plataforma VARCHAR(100) = null
AS
BEGIN
-- SET NOCOUNT ON added to prevent extra result sets from
-- interfering with SELECT statements.
SET NOCOUNT ON;
if (upper(@accion) = 'ALTA')
begin
insert into multi_web (web_name, web_title, http_host, uri_logo, uri_css1, uri_css2, uri_js1, active, uri_icon, app_id, is_default,
cliente, sender, uri_email_logo, servicio_contratado, copyright, id_plataforma,id_menu_plataforma)
VALUES (@web_name, @web_title, @http_host, @uri_logo, @uri_css1, @uri_css2, @uri_js1, @active, @uri_icon, @app_id, @is_default, @cliente, @sender,
@uri_email_logo, @servicio_contratado, @copyright, @id_plataforma,@id_menu_plataforma)
SELECT @@IDENTITY
return
end
if (upper(@accion) = 'ACTUALIZAR')
begin
UPDATE multi_web
SET
web_name = @web_name ,
web_title = @web_title ,
http_host = @http_host ,
uri_logo = @uri_logo ,
uri_css1 = @uri_css1 ,
uri_css2 = @uri_css2 ,
uri_js1 = @uri_js1 ,
active = @active ,
uri_icon = @uri_icon ,
app_id = @app_id ,
is_default = @is_default ,
cliente = @cliente ,
sender = @sender ,
uri_email_logo = @uri_email_logo ,
servicio_contratado = @servicio_contratado,
copyright = @copyright ,
id_plataforma = @id_plataforma ,
id_menu_plataforma = @id_menu_plataforma
WHERE web_id = @p_web_id
return
end
if (@accion = 'LISTBYID')
begin
select * from multi_web where web_id = @p_web_id
end
end
GO
Depends On
1Used By
No items found