惯性聚合 高效追踪和阅读你感兴趣的博客、新闻、科技资讯
阅读原文 在惯性聚合中打开

推荐订阅源

T
The Exploit Database - CXSecurity.com
A
Arctic Wolf
K
Kaspersky official blog
T
Threat Research - Cisco Blogs
PCI Perspectives
PCI Perspectives
www.infosecurity-magazine.com
www.infosecurity-magazine.com
P
Privacy International News Feed
K
KPMG report finds enterprise disconnect between AI and its ROI | CIO
U
Unit 42
cs.CL updates on arXiv.org
cs.CL updates on arXiv.org
Simon Willison's Weblog
Simon Willison's Weblog
P
Privacy & Cybersecurity Law Blog
O
OpenAI News
量子位
奇客Solidot–传递最新科技情报
奇客Solidot–传递最新科技情报
C
Cisco Blogs
AWS News Blog
AWS News Blog
Vercel News
Vercel News
Microsoft Security Blog
Microsoft Security Blog
Threat Intelligence Blog | Flashpoint
Threat Intelligence Blog | Flashpoint
美团技术团队
T
Threatpost
S
Schneier on Security
Cyber Security Advisories - MS-ISAC
Cyber Security Advisories - MS-ISAC
C
Cyber Attacks, Cyber Crime and Cyber Security
Last Week in AI
Last Week in AI
C
CERT Recently Published Vulnerability Notes
Blog — PlanetScale
Blog — PlanetScale
C
Cybersecurity and Infrastructure Security Agency CISA
F
Full Disclosure
博客园_首页
N
Netflix TechBlog - Medium
Security Latest
Security Latest
有赞技术团队
有赞技术团队
Google DeepMind News
Google DeepMind News
钛媒体:引领未来商业与生活新知
钛媒体:引领未来商业与生活新知
The Register - Security
The Register - Security
Application and Cybersecurity Blog
Application and Cybersecurity Blog
Recent Announcements
Recent Announcements
博客园 - Franky
P
Palo Alto Networks Blog
Project Zero
Project Zero
CTFtime.org: upcoming CTF events
CTFtime.org: upcoming CTF events
H
Help Net Security
Hacker News: Ask HN
Hacker News: Ask HN
Cisco Talos Blog
Cisco Talos Blog
H
Heimdal Security Blog
The Hacker News
The Hacker News
博客园 - 【当耐特】
GbyAI
GbyAI

博客园 - Michael Zhang

MacBook Home End SLES Install cucumber soapui test web services S/4 HANA Solution Manager Linux下创建新用户 su with hyphen and without - su带横杠和不带横杠 2008 R2中的无线连接 wireless 不实用,还小有点意思-IE6 UI测试中的小发现 [转载]一个回收站小工具---RecycleBin Gotcha 尝试改变Survey完成后的默认行为(JavaScript) SharePoint开发中的小点滴 Document Library的URL 完全控制SharePoint站点菜单(Get full control of SharePoint ActionMenus) Part 1 从WSS 3.0到MOSS 2007 WSS文档库备份及复制 如何备份sharepoint中的文档库? Document Library中Server Menu问题(New和Upload菜单消失) 站点迁移 从单机到服务器场 从上海到大连 又出现两个问题 关于Alert和WebDAV Sharepoint 2007 Forms认证与File Not Found错误
添加新的站点栏目类型(New Custom Field (Column) Type)
Michael Zhang · 2009-02-06 · via 博客园 - Michael Zhang

Site Column是根据数据类型SPField创建的,创建页面如右图所示

SharePoint提供了比较丰富的数据类型,不过在有些项目中,会存在更复杂的业务逻辑,所以本文将介绍创建自定义的数据类型(Custom SPField).

SPField有3个基本要素,分别是SPField的定义, SPField创建页面, SPField编辑控制,这些最后都会在FLDTYPES_(YourCustomName).XML中配置.

Contact Initials是一个提供建议的控件,根据输入提示出用户全名和简称,类似于Google搜索建议.

首先Field定义ContactInitialField.cs继承自SPFieldText,并有几个自己的属性,这些属性定义了从哪里取用户全名和简称数据,有数据库连接字符串, 表名,字段名.

这些属性需要在创建Site Column时填入数值.

ContactInitialFieldEditControl.ascx和ContactInitialFieldEditControl.cs定义了创建Site Column时的界面和动作

ContactInitialFieldControl.ascx和ContactInitialFieldControl.cs定义了在编辑属性是Site Column的显示,这里面包含了ajaxToolkit的AutoCompleteExtender.

最后在FLDTYPES_(YourCustomName).XML中配置我们编写的SPField.

最终效果:

下面是级联菜单的截图,field1是英文,field2是相对应的中文,当field1变化时,field2相应变化,另外还有人给出了无限级联菜单的解决方案, SharePoint Cascading Dropdown - Unlimited siblings.

下面是ajaxToolkit DropDownExtender的截图, 点击TextBox时,出现多选下拉菜单,选择后,只有再次点击TextBox(点击其他区域无效),菜单隐藏.

 代码下载链接