亚洲免费在线-亚洲免费在线播放-亚洲免费在线观看-亚洲免费在线观看视频-亚洲免费在线看-亚洲免费在线视频

.NET EXT-JS

系統 2023 0

基本流程:

一、數據庫配置:

1、在通知單QMIH里添加一些檢測網值班日志字段。

二、頁面定義:

1、新建(5個tab頁面: LM111列表G、LM112編輯E、LM113交通檢修機具G+E、LM114次日工作計劃G+E、考勤)

列表:一個頁面LM111?

頁面維護:表名 (彈出框選擇對應數據庫中的表)

字典信息:更多操作--- 同步數據字典

三、系統管理-- 配置:

1、功能頁面組合--新建一個功能頁面 110111頁面-- 功能頁面 (關聯一些/WebGroup/lm/lm114.js)-- 配置tab頁面(G+E、G模式)-- 頁面明細(每個tab頁面對應的頁面序號以及設置改頁面的類型、tab頁面激活事件、與主表關系)

.NET EXT-JS

?

2、首先,系統管理-- 配置-- 功能菜單-- 檢測網檢修管理-- 值班日志-- 新建列表

3、新建時所要配置序號、父代碼、功能代碼、頁面位置/Bsf/Web/Form/MainForm.aspx?PKID=110111(對應的是功能頁面組合里的頁面)

lm113.cs 后臺代碼:

using ?System;
using ?System.Collections.Generic;
using ?System.Data;
using ?Bsf;

namespace ?EAM.WebGroup.LM
{
???? public ? class ? lm113 ?:? BI
????{
???????? public ? override ? string ?insertBefore( DataRow ?drOld,? DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? Dictionary < string ,? object >?result?=?Json;
???????????? string ?WCQK_ID?=?Json[ "wcqk_id__lm113" ]?==? null ??? string .Empty?:?Json[ "wcqk_id__lm113" ].ToString();
???????????? string ?QMIH_ID?=?Json[ "qmih_id__lm113" ]?==? null ??? string .Empty?:?Json[ "qmih_id__lm113" ].ToString();
???????????? string ?MSKH_ID?=?Json[ "mskh_id__lm113" ]?==? null ??? string .Empty?:?Json[ "mskh_id__lm113" ].ToString();
???????????? string ?WCGZL?=?Json[ "wcgzl__lm113" ]?==? null ??? string .Empty?:?Json[ "wcgzl__lm113" ].ToString();
???????????? if ?(WCQK_ID?==? string .Empty)
????????????{
????????????????WCQK_ID?=? Guid .NewGuid().ToString().Replace( "-" ,? "" );
???????????????? string []?names?=? new ? string [4];
???????????????? string []?values?=? new ? string [4];
????????????????names[0]?=? "WCQK_ID" ;
????????????????values[0]?=?WCQK_ID;

????????????????names[1]?=? "QMIH_ID" ;
????????????????values[1]?=?QMIH_ID;

????????????????names[2]?=? "MSKH_ID" ;
????????????????values[2]?=?MSKH_ID;

????????????????names[3]?=? "WCGZL" ;
????????????????values[3]?=?WCGZL;

???????????????? return ? Dal .Update( "WCQK" ,?WCQK_ID,?names,?values);
????????????}
???????????? else
????????????{
???????????????? DataSet ?ds?=?( DataSet ) Dal .Initialization( "wcqk" ,? "" ,? string .Format( "WCQK_ID='{0}'" ,?WCQK_ID));
???????????????? if ?(ds.Tables[0].Rows.Count?>?0)
????????????????{
????????????????????ds.Tables[0].Rows[0][ "wcgzl" ]?=?WCGZL;
???????????????????? return ? Dal .Update( "WCQK" ,?ds);
????????????????}
???????????????? return ? "error" ;
????????????}
????????}
????}
}
lm114.cs:

using ?System.Collections.Generic;
using ?Bsf;

namespace ?EAM.WebGroup.LM
{
???? public ? class ? lm114 ?:? BI
????{
???????? public ? override ? string ?updateBefore(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? return ?BeforOperator(drOld,?drNew,?Json);
????????}

???????? public ? override ? string ?updateAfter(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? return ?AfterOperator(drOld,?drNew,?Json);
????????}

???????? //判斷數據數據的合法性
???????? public ? override ? string ?insertBefore(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? return ?BeforOperator(drOld,?drNew,?Json);
????????}

???????? public ? override ? string ?insertAfter(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? return ?AfterOperator(drOld,?drNew,?Json);
????????}

???????? private ? string ?AfterOperator(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? //出勤人數=現員人數-病假人數-事假人數。
???????????? //出工人數=出勤人數-調休人數-其它人數。
???????????? //上網人數:?當天執行的第一種工作票上的總人數。
???????????? //出勤率=出勤人數/現員人數×100%。
???????????? //出工率=出工人數/出勤人數×100%。
???????????? //上網率=?上網人數/(工區現員數-病假人數-事假人數-出差人數-調休人數)×100%?。
???????????? string ?INDENTITY_ID?=?drNew[ "qmih_id" ].ToString();
???????????? string ?XYRS?=?Json[ "xyrs__lm114" ]?==? null ??? string .Empty?:?Json[ "xyrs__lm114" ].ToString();
???????????? string ?BJRS?=?Json[ "bjrs__lm114" ]?==? null ??? string .Empty?:?Json[ "bjrs__lm114" ].ToString();
???????????? string ?CGRS?=?Json[ "cgrs__lm114" ]?==? null ??? string .Empty?:?Json[ "cgrs__lm114" ].ToString();
???????????? string ?CCRS?=?Json[ "ccrs__lm114" ]?==? null ??? string .Empty?:?Json[ "ccrs__lm114" ].ToString();
???????????? string ?CQRS?=?Json[ "cqrs__lm114" ]?==? null ??? string .Empty?:?Json[ "cqrs__lm114" ].ToString();
???????????? string ?QTRS?=?Json[ "qtrs__lm114" ]?==? null ??? string .Empty?:?Json[ "qtrs__lm114" ].ToString();
???????????? string ?SJRS?=?Json[ "sjrs__lm114" ]?==? null ??? string .Empty?:?Json[ "sjrs__lm114" ].ToString();
???????????? string ?SWRS?=?Json[ "swrs__lm114" ]?==? null ??? string .Empty?:?Json[ "swrs__lm114" ].ToString();
???????????? string ?TXRS?=?Json[ "txrs__lm114" ]?==? null ??? string .Empty?:?Json[ "txrs__lm114" ].ToString();

???????????? int ?cqrs?=? int .Parse(XYRS)?-? int .Parse(BJRS)?-? int .Parse(SJRS);
???????????? int ?cgrs?=?cqrs?-? int .Parse(TXRS)?-? int .Parse(QTRS);

???????????? double ?swl?=?( double .Parse(SWRS)?/?( int .Parse(XYRS)?-? int .Parse(BJRS)?-? int .Parse(TXRS)?-? int .Parse(SJRS)?-? int .Parse(CCRS)))?*?100;
???????????? double ?cql?=?(( double )cqrs?/? double .Parse(XYRS))?*?100;
???????????? double ?cgl?=?(( double )cgrs?/?cgrs)?*?100;

???????????? string []?names?=? new ? string [4];
???????????? string []?values?=? new ? string [4];

????????????names[0]?=? "SWL" ;
????????????values[0]?=?swl.ToString( "##.##" )?+? "%" ;

????????????names[1]?=? "CQL" ;
????????????values[1]?=?cql.ToString( "##.##" )?+? "%" ;?;

????????????names[2]?=? "CGL" ;
????????????values[2]?=?cgl.ToString( "##.##" )?+? "%" ;

????????????names[3]?=? "CQRS" ;
????????????values[3]?=?( int .Parse(XYRS)?-? int .Parse(BJRS)?-? int .Parse(SJRS)).ToString();

???????????? Dal .Update( "rztable" ,?drNew[ "RZTABLE_ID" ].ToString(),?names,?values);

???????????? return ? "e|reloadRZTABLE('" ?+?INDENTITY_ID?+? "')" ;
????????}

???????? private ? string ?BeforOperator(System.Data. DataRow ?drOld,?System.Data. DataRow ?drNew,? Dictionary < string ,? object >?Json)
????????{
???????????? string ?INDENTITY_ID;
???????????? if ?(drNew?==? null )?{?INDENTITY_ID?=?Json[ "qmih_id__lm114" ].ToString();?}
???????????? else ?{?INDENTITY_ID?=?drNew[ "qmih_id" ].ToString();?}

???????????? string ?XYRS?=?Json[ "xyrs__lm114" ]?==? null ??? string .Empty?:?Json[ "xyrs__lm114" ].ToString();
???????????? string ?BJRS?=?Json[ "bjrs__lm114" ]?==? null ??? string .Empty?:?Json[ "bjrs__lm114" ].ToString();
???????????? string ?CGRS?=?Json[ "cgrs__lm114" ]?==? null ??? string .Empty?:?Json[ "cgrs__lm114" ].ToString();
???????????? string ?CCRS?=?Json[ "ccrs__lm114" ]?==? null ??? string .Empty?:?Json[ "ccrs__lm114" ].ToString();
???????????? string ?CQRS?=?Json[ "cqrs__lm114" ]?==? null ??? string .Empty?:?Json[ "cqrs__lm114" ].ToString();
???????????? string ?QTRS?=?Json[ "qtrs__lm114" ]?==? null ??? string .Empty?:?Json[ "xyrs__lm114" ].ToString();
???????????? string ?SJRS?=?Json[ "sjrs__lm114" ]?==? null ??? string .Empty?:?Json[ "sjrs__lm114" ].ToString();
???????????? string ?SWRS?=?Json[ "swrs__lm114" ]?==? null ??? string .Empty?:?Json[ "swrs__lm114" ].ToString();
???????????? string ?TXRS?=?Json[ "txrs__lm114" ]?==? null ??? string .Empty?:?Json[ "txrs__lm114" ].ToString();

???????????? if ?(XYRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入現員人數" ;
????????????}
???????????? if ?(BJRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入病假人數" ;
????????????}
???????????? if ?(SJRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入事假人數" ;
????????????}
???????????? if ?(CCRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入出差人數" ;
????????????}
???????????? if ?(TXRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入調休人數" ;
????????????}
???????????? if ?(QTRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入其他人數" ;
????????????}
???????????? if ?(SWRS?==? string .Empty)
????????????{
???????????????? return ? "請輸入上網人數" ;
????????????}

???????????? //出勤人數
???????????? int ?cqrs;

???????????? //出勤人數數值的檢測
???????????? if ?( int .Parse(XYRS)?>? int .Parse(BJRS)?&&? int .Parse(XYRS)?-? int .Parse(BJRS)?-? int .Parse(SJRS)?>?0)
????????????{
????????????????cqrs?=? int .Parse(XYRS)?-? int .Parse(BJRS)?-? int .Parse(SJRS);
????????????}
???????????? else
????????????{
???????????????? return ? "數值范圍有誤" ;
????????????}
???????????? if ?( double .Parse(XYRS)?!=?0)
????????????{
???????????????? double ?swl?=?( double .Parse(SWRS)?/?( double .Parse(XYRS)?-? double .Parse(BJRS)?-? double .Parse(TXRS)))?*?100;
????????????}
?????????
???????????? else
????????????{
???????????????? return ? "除數不能為零" ;
????????????}

???????????? return ? base .insertBefore(drOld,?drNew,?Json);
????????}
????}
}

lm.js:

function ?loadRZTABLE()?{
???? var ?record?=?myApp.rcRecord( 'lm111' );
???? var ?para?=? "upper(qmih_id)?='" ?+?record.data[ 'qmih_id__lm111' ].toUpperCase()?+? "'" ;
???? var ?store?=?myApp.rcFormStore( 'lm114' );
????store.reload({?params:?{?start:?0,?limit:?1,?pkid:? 'lm114' ,?para:?para,?filter:? '' ?},?callback:? function ?()?{
???????? if ?(store.data.length?==?0)?{
???????????? var ?newrecord?=?myApp.createNewRecord( 'lm114' ,? 'qmih_id' );
????????????myApp.rcForm( 'lm114' ).loadRecord(newrecord);
????????}
???????? else ?{
????????????myApp.rcForm( 'lm114' ).loadRecord(store.data.items[0]);
????????}
????}
????});
}

function ?reloadRZTABLE(qmih_id)?{
???? var ?para?=? "upper(qmih_id)?='" ?+?qmih_id.toUpperCase()?+? "'" ;
???? var ?store?=?myApp.rcFormStore( 'lm114' );
????store.reload({?params:?{?start:?0,?limit:?1,?pkid:? 'lm114' ,?para:?para,?filter:? '' ?},?callback:? function ?()?{
????????myApp.rcForm( 'lm114' ).loadRecord(store.data.items[0]);
????}
????});
}

//新增代碼后(設置默認值)
SetDefault_lm113?=? function ?(rec)?{
???? var ?qmih_id?=?myApp.rcRecord( "lm111" ).data[ "qmih_id__lm111" ];
????rec.data[ "qmih_id__lm113" ]?=?qmih_id;
}

isNew_lm114?=? function ?()?{
????MessageBox( "警告" ,? "該處不允許此操作!" );
???? return ? false ;
}

isDelete_lm114?=? function ?()?{
????MessageBox( "警告" ,? "該處不允許此操作!" );
???? return ? false ;
}

?

?

.NET EXT-JS


更多文章、技術交流、商務合作、聯系博主

微信掃碼或搜索:z360901061

微信掃一掃加我為好友

QQ號聯系: 360901061

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描下面二維碼支持博主2元、5元、10元、20元等您想捐的金額吧,狠狠點擊下面給點支持吧,站長非常感激您!手機微信長按不能支付解決辦法:請將微信支付二維碼保存到相冊,切換到微信,然后點擊微信右上角掃一掃功能,選擇支付二維碼完成支付。

【本文對您有幫助就好】

您的支持是博主寫作最大的動力,如果您喜歡我的文章,感覺我的文章對您有幫助,請用微信掃描上面二維碼支持博主2元、5元、10元、自定義金額等您想捐的金額吧,站長會非常 感謝您的哦?。?!

發表我的評論
最新評論 總共0條評論
主站蜘蛛池模板: 五月婷婷激情综合网 | 香蕉视频黄色在线观看 | 99伦理| 久热爱免费精品视频在线播放 | 欧美成人免费 | 香蕉视频影院 | 日日狠狠久久偷偷四色综合免费 | 51国产午夜精品免费视频 | 亚洲成人综合视频 | 亚洲国产欧美在线不卡中文 | 久久99精品国产 | 久久是免费只精品热在线 | 国产精品人成在线播放新网站 | japanese国产高清麻豆 | 五月天婷婷在线免费观看 | 欧美日韩一区二区在线观看 | 一级毛片短视频 | 另类亚洲图片 | 欧美中文字幕在线看 | 天天爱夜夜爽 | 一级一级 a爱片免费视频 | 精品无码久久久久久国产 | 亚洲欧美日韩一区二区 | 日本毛片在线观看 | 精品夜夜春夜夜爽久久 | 亚洲福利社 | 亚洲欧美中文日韩综合 | 成人精品 | 日本一级在线观看视频播放 | 亚洲图片 中文字幕 | 国产不卡视频在线 | 91亚洲区国产区精品区 | 一区二区精品久久 | 性欧美另类老妇高清 | 久久99精品这里精品3 | 性xxx免费视频 | 久久这里只有精品99 | 中文字幕不卡在线播放 | 国产一区二区三区乱码网站 | 国产精品视频一区国模私拍 | 女人与女zzzoooxxxx |