Reset page number and add data-pinyin to options

This commit is contained in:
RB 2025-09-01 11:58:03 +08:00
parent 6c8176c238
commit 883fbb823a
3 changed files with 3 additions and 1 deletions

View file

@ -2347,6 +2347,7 @@ const CategoryWidget = {
onItemClick={(query) => {
if (!query || query[0] === CategoryWidget.__ALL) wpc.protocolFilter = null
else wpc.protocolFilter = `category:${wpc.entity[0]}:${query.join('$$$$')}`
_RbList().pageNo = 1
RbListPage.reload()
}}
/>,

View file

@ -312,6 +312,7 @@ $(document).ready(() => {
// v4.1 AI
window.attachAibotPageData = function (cb) {
renderRbcomp(
// eslint-disable-next-line react/jsx-no-undef
<DlgAttachRecordList
onConfirm={(s) => {
const qe = RbListPage._RbList.getLastQueryEntry()

View file

@ -810,7 +810,7 @@ class CompCategoryItem extends React.Component {
<select className="form-control form-control-sm" ref={(c) => (this._$field = c)}>
{this.props.fields.map((item) => {
return (
<option key={item.name} value={item.name}>
<option key={item.name} value={item.name} data-pinyin={item.quickCode}>
{item.label}
</option>
)