...代码,如需要中断添加请提前返回 false // ... return parent::beforeSubmit($index); } public function afterSubmit(XSIndex $index) { // 在此编写您的代码,只有加入索引成功后才会执行 // ... } } $doc = new MyDocument...
...ptoms of a migraine. It is not for everyday use. If your migraine headache returns after one dose, you can take another dose as directed. You must leave at least 2 hours between doses, and do not take more than 30 mg total in 24 hours. If there is no improvement at all after the first dose, do not t...
...search\ActiveRecord { /*public static function projectName() { return 'another_name'; // 这将使用 @app/config/another_name.ini 作为项目名 }*/ } ``` 由此可见,如果命名规范模型类几乎不需要任何额外代码,上述代码会自动采用 `demo.ini` 并自动...
...XSDataFilter { public function process($data, $cs) { print_r($data); return $data; } public function processDoc($doc) { // $doc->addTerm('subject', '特殊词'); } } ~~~ 自定义数据源 ----------- 目前数据源有两种类型,一种是文件数据源(如 JSON、CSV),另...
...$result)){ $doc->setFields($result); $res = $index->add($doc); return false; } 返回$res值为 object(XSIndex)#42 (9) { ["_buf":"XSIndex":private]=> string(0) "" ["_bufSize":"XSIndex":private]=> int(0) ["_rebuild":"XSIndex":private]=> bool(false) ["xs"]=> ...